You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
NewEduCoderBuild/p__Paths__New__index.0a34c8...

1255 lines
2.2 MiB

(self.webpackChunk=self.webpackChunk||[]).push([[8982],{91034:function(jn,li,De){"use strict";De.d(li,{Z:function(){return $e}});var Ne=De(87462),dt=De(67294),Ut={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z"}}]},name:"right",theme:"outlined"},$t=Ut,kt=De(17207),Ie=function(Pt,wt){return dt.createElement(kt.Z,(0,Ne.Z)({},Pt,{ref:wt,icon:$t}))},$e=dt.forwardRef(Ie)},71749:function(){"use strict"},30483:function(){"use strict"},71736:function(jn,li){"use strict";li.Z={lists:"lists___xhHyq",item:"item___pWJAA",children:"children___sDG61",diamond:"diamond___FwgzD",button:"button___WPN6r",mathWrap:"mathWrap___FmnMJ",mathFillWrap:"mathFillWrap___PmY3H"}},18023:function(){"use strict";function jn(Re,ne,te,he){te===void 0&&(te=0),he===void 0&&(he=1/0),this._name=Re,this._defaultValue=ne,this._minimum=te,this._maximum=he}Object.defineProperty(jn.prototype,"name",{get:function(){return this._name},set:function(Re){if(typeof Re!="string"||Re==="")throw new Error("Shape name must be a valid string.");this._name=Re}}),Object.defineProperty(jn.prototype,"defaultValue",{get:function(){return this._defaultValue},set:function(Re){if(typeof Re!="number"||isNaN(Re))throw new Error("The default value must be a real number, not: "+Re);this._defaultValue=Re}}),Object.defineProperty(jn.prototype,"minimum",{get:function(){return this._minimum},set:function(Re){if(typeof Re!="number"||isNaN(Re))throw new Error("Minimum must be a real number, not: "+Re);this._minimum=Re}}),Object.defineProperty(jn.prototype,"maximum",{get:function(){return this._maximum},set:function(Re){if(typeof Re!="number"||isNaN(Re))throw new Error("Maximum must be a real number, not: "+Re);this._maximum=Re}}),go.Shape._FigureParameters={},go.Shape.getFigureParameter=function(Re,ne){var te=go.Shape._FigureParameters[Re];return te?te[ne]:null},go.Shape.setFigureParameter=function(Re,ne,te){if(!(te instanceof jn))throw new Error("Third argument to Shape.setFigureParameter is not FigureParameter: "+te);if(te.defaultValue<te.minimum||te.defaultValue>te.maximum)throw new Error("defaultValue must be between minimum and maximum, not: "+te.defaultValue);var he=go.Shape._FigureParameters[Re];he||(he=[],go.Shape._FigureParameters[Re]=he),he[ne]=te};var li=[];function De(Re,ne){var te=li.pop();return te===void 0?new go.Point(Re,ne):(te.x=Re,te.y=ne,te)}function Ne(){var Re=li.pop();return Re===void 0?new go.Point:Re}function dt(Re){li.push(Re)}function Ut(Re,ne,te,he,le,pe,me,xe,Ee){Ee||(Ee=new go.Point);var Ge=Re-te,et=le-me,ut=NaN,st=NaN;if(Ge===0)if(et===0)Re===te&&(ut=Re,st=ne);else{var it=(pe-xe)/et,Nt=pe-it*le;ut=Re,st=it*ut+Nt}else if(et===0){var St=(ne-he)/Ge,Ft=ne-St*Re;ut=le,st=St*ut+Ft}else{var St=(ne-he)/Ge,it=(pe-xe)/et,Ft=ne-St*Re,Nt=pe-it*le;ut=(Nt-Ft)/(St-it),st=St*ut+Ft}return Ee.x=ut,Ee.y=st,Ee}function $t(Re,ne,te,he,le,pe,me,xe,Ee,Ge,et,ut,st,it){var Nt=1-Ee,St=Ee,Ft=Re*Nt+te*St,cn=ne*Nt+he*St,Tt=te*Nt+le*St,hi=he*Nt+pe*St,di=le*Nt+me*St,zn=pe*Nt+xe*St,Dn=Ft*Nt+Tt*St,nt=cn*Nt+hi*St,ze=Tt*Nt+di*St,ke=hi*Nt+zn*St,Wt=Dn*Nt+ze*St,On=nt*Nt+ke*St;Ge.x=Ft,Ge.y=cn,et.x=Dn,et.y=nt,ut.x=Wt,ut.y=On,st.x=ze,st.y=ke,it.x=di,it.y=zn}var kt=new go.Spot(.156,.156),Ie=new go.Spot(.844,.844),$e=4*((Math.sqrt(2)-1)/3);go.Shape.setFigureParameter("RoundedRectangle",0,new jn("CornerRounding",5)),go.Shape.defineFigureGenerator("RoundedRectangle",function(Re,ne,te){var he=Re?Re.parameter1:NaN;(isNaN(he)||he<0)&&(he=5),he=Math.min(he,ne/3),he=Math.min(he,te/3);var le=he*$e,pe=new go.Geometry().add(new go.PathFigure(he,0,!0).add(new go.PathSegment(go.PathSegment.Line,ne-he,0)).add(new go.PathSegment(go.PathSegment.Bezier,ne,he,ne-le,0,ne,le)).add(new go.PathSegment(go.PathSegment.Line,ne,te-he)).add(new go.PathSegment(go.PathSegment.Bezier,ne-he,te,ne,te-le,ne-le,te)).add(new go.PathSegment(go.PathSegment.Line,he,te)).add(new go.PathSegment(go.PathSegment.Bezier,0,te-he,le,te,0,te-le)).add(new go.PathSegment(go.PathSegment.Line,0,he)).add(new go.PathSegment(go.PathSegment.Bezier,he,0,0,le,le,0).close()));return le>1&&(pe.spot1=new go.Spot(0,0,le,le),pe.spot2=new go.Spot(1,1,-le,-le)),pe}),go.Shape.defineFigureGenerator("Border","RoundedRectangle"),go.Shape.defineFigureGenerator("TriangleRight",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())).setSpots(0,.25,.5,.75)}),go.Shape.defineFigureGenerator("TriangleDown",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,.5*ne,te).close())).setSpots(.25,0,.75,.5)}),go.Shape.defineFigureGenerator("TriangleLeft",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(ne,te).add(new go.PathSegment(go.PathSegment.Line,0,.5*te)).add(new go.PathSegment(go.PathSegment.Line,ne,0).close())).setSpots(.5,.25,1,.75)}),go.Shape.defineFigureGenerator("TriangleUp",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(ne,te).add(new go.PathSegment(go.PathSegment.Line,0,te)).add(new go.PathSegment(go.PathSegment.Line,.5*ne,0).close())).setSpots(.25,.5,.75,1)}),go.Shape.defineFigureGenerator("Triangle","TriangleUp"),go.Shape.defineFigureGenerator("Diamond",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(.5*ne,0).add(new go.PathSegment(go.PathSegment.Line,0,.5*te)).add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te).close())).setSpots(.25,.25,.75,.75)}),go.Shape.defineFigureGenerator("LineH",function(Re,ne,te){var he=new go.Geometry(go.Geometry.Line);return he.startX=0,he.startY=te/2,he.endX=ne,he.endY=te/2,he}),go.Shape.defineFigureGenerator("LineV",function(Re,ne,te){var he=new go.Geometry(go.Geometry.Line);return he.startX=ne/2,he.startY=0,he.endX=ne/2,he.endY=te,he}),go.Shape.defineFigureGenerator("BarH","Rectangle"),go.Shape.defineFigureGenerator("BarV","Rectangle"),go.Shape.defineFigureGenerator("MinusLine","LineH"),go.Shape.defineFigureGenerator("PlusLine",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,te/2,!1).add(new go.PathSegment(go.PathSegment.Line,ne,te/2)).add(new go.PathSegment(go.PathSegment.Move,ne/2,0)).add(new go.PathSegment(go.PathSegment.Line,ne/2,te)))}),go.Shape.defineFigureGenerator("XLine",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,te,!1).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Move,0,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te)))}),go.Shape.defineFigureGenerator("LineRight",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(.25*ne,0,!1).add(new go.PathSegment(go.PathSegment.Line,.75*ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,.25*ne,te)))}),go.Shape.defineFigureGenerator("LineDown",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,.25*te,!1).add(new go.PathSegment(go.PathSegment.Line,.5*ne,.75*te)).add(new go.PathSegment(go.PathSegment.Line,ne,.25*te)))}),go.Shape.defineFigureGenerator("LineLeft",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(.75*ne,0,!1).add(new go.PathSegment(go.PathSegment.Line,.25*ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,.75*ne,te)))}),go.Shape.defineFigureGenerator("LineUp",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,.75*te,!1).add(new go.PathSegment(go.PathSegment.Line,.5*ne,.25*te)).add(new go.PathSegment(go.PathSegment.Line,ne,.75*te)))}),go.Shape.defineFigureGenerator("AsteriskLine",function(Re,ne,te){var he=.2/Math.SQRT2;return new go.Geometry().add(new go.PathFigure(he*ne,(1-he)*te,!1).add(new go.PathSegment(go.PathSegment.Line,(1-he)*ne,he*te)).add(new go.PathSegment(go.PathSegment.Move,he*ne,he*te)).add(new go.PathSegment(go.PathSegment.Line,(1-he)*ne,(1-he)*te)).add(new go.PathSegment(go.PathSegment.Move,0,te/2)).add(new go.PathSegment(go.PathSegment.Line,ne,te/2)).add(new go.PathSegment(go.PathSegment.Move,ne/2,0)).add(new go.PathSegment(go.PathSegment.Line,ne/2,te)))}),go.Shape.defineFigureGenerator("CircleLine",function(Re,ne,te){var he=ne/2,le=new go.Geometry().add(new go.PathFigure(ne,ne/2,!1).add(new go.PathSegment(go.PathSegment.Arc,0,360,he,he,he,he).close()));return le.spot1=kt,le.spot2=Ie,le.defaultStretch=go.GraphObject.Uniform,le}),go.Shape.defineFigureGenerator("Line1",function(Re,ne,te){var he=new go.Geometry(go.Geometry.Line);return he.startX=0,he.startY=0,he.endX=ne,he.endY=te,he}),go.Shape.defineFigureGenerator("Line2",function(Re,ne,te){var he=new go.Geometry(go.Geometry.Line);return he.startX=ne,he.startY=0,he.endX=0,he.endY=te,he}),go.Shape.defineFigureGenerator("Curve1",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Bezier,ne,te,$e*ne,0,ne,(1-$e)*te)))}),go.Shape.defineFigureGenerator("Curve2",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Bezier,ne,te,0,$e*te,(1-$e)*ne,te)))}),go.Shape.defineFigureGenerator("Curve3",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(ne,0,!1).add(new go.PathSegment(go.PathSegment.Bezier,0,te,ne,$e*te,$e*ne,te)))}),go.Shape.defineFigureGenerator("Curve4",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(ne,0,!1).add(new go.PathSegment(go.PathSegment.Bezier,0,te,(1-$e)*ne,0,0,(1-$e)*te)))}),go.Shape.defineFigureGenerator("TriangleDownLeft",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())).setSpots(0,.5,.5,1)}),go.Shape.defineFigureGenerator("TriangleDownRight",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(ne,0,!0).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())).setSpots(.5,.5,1,1)}),go.Shape.defineFigureGenerator("TriangleUpLeft",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())).setSpots(0,0,.5,.5)}),go.Shape.defineFigureGenerator("TriangleUpRight",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te).close())).setSpots(.5,0,1,.5)}),go.Shape.defineFigureGenerator("RightTriangle","TriangleDownLeft"),go.Shape.setFigureParameter("Parallelogram1",0,new jn("Indent",.1,-.99,.99)),go.Shape.defineFigureGenerator("Parallelogram1",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)?he=.1:he<-1?he=-1:he>1&&(he=1);var le=Math.abs(he)*ne;if(he===0){var pe=new go.Geometry(go.Geometry.Rectangle);return pe.startX=0,pe.startY=0,pe.endX=ne,pe.endY=te,pe}else{var pe=new go.Geometry;return he>0?pe.add(new go.PathFigure(le,0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne-le,te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())):pe.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,ne-le,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,le,te).close())),le<ne/2&&pe.setSpots(le/ne,0,(ne-le)/ne,1),pe}}),go.Shape.defineFigureGenerator("Parallelogram","Parallelogram1"),go.Shape.setFigureParameter("Parallelogram2",0,new jn("Indent",10,-1/0,1/0)),go.Shape.defineFigureGenerator("Parallelogram2",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)?he=10:he<-ne?he=-ne:he>ne&&(he=ne);var le=Math.abs(he);if(he===0){var pe=new go.Geometry(go.Geometry.Rectangle);return pe.startX=0,pe.startY=0,pe.endX=ne,pe.endY=te,pe}else{var pe=new go.Geometry;return he>0?pe.add(new go.PathFigure(le,0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne-le,te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())):pe.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,ne-le,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,le,te).close())),le<ne/2&&pe.setSpots(le/ne,0,(ne-le)/ne,1),pe}}),go.Shape.setFigureParameter("Trapezoid1",0,new jn("Indent",.2,-.99,.99)),go.Shape.defineFigureGenerator("Trapezoid1",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)?he=.2:he<.5?he=-.5:he>.5&&(he=.5);var le=Math.abs(he)*ne;if(he===0){var pe=new go.Geometry(go.Geometry.Rectangle);return pe.startX=0,pe.startY=0,pe.endX=ne,pe.endY=te,pe}else{var pe=new go.Geometry;return he>0?pe.add(new go.PathFigure(le,0).add(new go.PathSegment(go.PathSegment.Line,ne-le,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())):pe.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne-le,te)).add(new go.PathSegment(go.PathSegment.Line,le,te).close())),le<ne/2&&pe.setSpots(le/ne,0,(ne-le)/ne,1),pe}}),go.Shape.defineFigureGenerator("Trapezoid","Trapezoid1"),go.Shape.setFigureParameter("Trapezoid2",0,new jn("Indent",20,-1/0,1/0)),go.Shape.defineFigureGenerator("Trapezoid2",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)?he=20:he<-ne?he=-ne/2:he>ne&&(he=ne/2);var le=Math.abs(he);if(he===0){var pe=new go.Geometry(go.Geometry.Rectangle);return pe.startX=0,pe.startY=0,pe.endX=ne,pe.endY=te,pe}else{var pe=new go.Geometry;return he>0?pe.add(new go.PathFigure(le,0).add(new go.PathSegment(go.PathSegment.Line,ne-le,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())):pe.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne-le,te)).add(new go.PathSegment(go.PathSegment.Line,le,te).close())),le<ne/2&&pe.setSpots(le/ne,0,(ne-le)/ne,1),pe}}),go.Shape.setFigureParameter("ManualOperation",0,new jn("Indent",10,-1/0,1/0)),go.Shape.defineFigureGenerator("ManualOperation",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)?he=10:he<-ne?he=-ne/2:he>ne&&(he=ne/2);var le=Math.abs(he);if(he===0){var pe=new go.Geometry(go.Geometry.Rectangle);return pe.startX=0,pe.startY=0,pe.endX=ne,pe.endY=te,pe}else{var pe=new go.Geometry;return he>0?pe.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne-le,te)).add(new go.PathSegment(go.PathSegment.Line,le,te).close())):pe.add(new go.PathFigure(le,0).add(new go.PathSegment(go.PathSegment.Line,ne-le,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close())),le<ne/2&&pe.setSpots(le/ne,0,(ne-le)/ne,1),pe}});var Mt=[];function Pt(){var Re=Mt.pop();return Re===void 0?[]:Re}function wt(Re){Re.length=0,Mt.push(Re)}function Qt(Re){for(var ne=Pt(),te=.5,he=.5,le=Math.PI*1.5,pe=0,me=0;me<Re;me++)pe=2*Math.PI/Re*me+le,ne[me]=new go.Point(he+te*Math.cos(pe),he+te*Math.sin(pe));return ne.push(ne[0]),ne}function It(Re){var ne=sn(Re),te=Pt();te[0]=ne[0];for(var he=1,le=1;he<ne.length;he+=2,le+=3)te[le]=ne[he],te[le+1]=ne[he],te[le+2]=ne[he+1];return wt(ne),te}function sn(Re){for(var ne=Qt(Re),te=Pt(),he=Math.floor(ne.length/2),le=ne.length-1,pe=Re%2===0?2:1,me=0;me<le;me++){var xe=ne[me],Ee=ne[me+1],Ge=ne[(he+me-1)%le],et=ne[(he+me+pe)%le];te[me*2]=xe,te[me*2+1]=Ut(xe.x,xe.y,Ge.x,Ge.y,Ee.x,Ee.y,et.x,et.y,new go.Point)}return te[te.length]=te[0],wt(ne),te}go.Shape.defineFigureGenerator("Pentagon",function(Re,ne,te){var he=Qt(5),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<5;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.2,.22),le.spot2=new go.Spot(.8,.9),le}),go.Shape.defineFigureGenerator("Hexagon",function(Re,ne,te){var he=Qt(6),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<6;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.07,.25),le.spot2=new go.Spot(.93,.75),le}),go.Shape.defineFigureGenerator("Heptagon",function(Re,ne,te){var he=Qt(7),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<7;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.2,.15),le.spot2=new go.Spot(.8,.85),le}),go.Shape.defineFigureGenerator("Octagon",function(Re,ne,te){var he=Qt(8),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<8;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.15,.15),le.spot2=new go.Spot(.85,.85),le}),go.Shape.defineFigureGenerator("Nonagon",function(Re,ne,te){var he=Qt(9),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<9;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.17,.13),le.spot2=new go.Spot(.82,.82),le}),go.Shape.defineFigureGenerator("Decagon",function(Re,ne,te){var he=Qt(10),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<10;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.16,.16),le.spot2=new go.Spot(.84,.84),le}),go.Shape.defineFigureGenerator("Dodecagon",function(Re,ne,te){var he=Qt(12),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<12;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.16,.16),le.spot2=new go.Spot(.84,.84),le}),go.Shape.defineFigureGenerator("FivePointedStar",function(Re,ne,te){var he=sn(5),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<10;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.266,.333),le.spot2=new go.Spot(.733,.733),le}),go.Shape.defineFigureGenerator("SixPointedStar",function(Re,ne,te){var he=sn(6),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<12;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.17,.25),le.spot2=new go.Spot(.83,.75),le}),go.Shape.defineFigureGenerator("SevenPointedStar",function(Re,ne,te){var he=sn(7),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<14;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.222,.277),le.spot2=new go.Spot(.777,.666),le}),go.Shape.defineFigureGenerator("EightPointedStar",function(Re,ne,te){var he=sn(8),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<16;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.25,.25),le.spot2=new go.Spot(.75,.75),le}),go.Shape.defineFigureGenerator("NinePointedStar",function(Re,ne,te){var he=sn(9),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<18;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.222,.277),le.spot2=new go.Spot(.777,.666),le}),go.Shape.defineFigureGenerator("TenPointedStar",function(Re,ne,te){var he=sn(10),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<20;me++)pe.add(new go.PathSegment(go.PathSegment.Line,he[me].x*ne,he[me].y*te));return pe.add(new go.PathSegment(go.PathSegment.Line,he[0].x*ne,he[0].y*te).close()),wt(he),le.spot1=new go.Spot(.281,.261),le.spot2=new go.Spot(.723,.748),le}),go.Shape.defineFigureGenerator("FivePointedBurst",function(Re,ne,te){var he=It(5),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<he.length;me+=3)pe.add(new go.PathSegment(go.PathSegment.Bezier,he[me+2].x*ne,he[me+2].y*te,he[me].x*ne,he[me].y*te,he[me+1].x*ne,he[me+1].y*te));return pe.segments.last().close(),wt(he),le.spot1=new go.Spot(.222,.277),le.spot2=new go.Spot(.777,.777),le}),go.Shape.defineFigureGenerator("SixPointedBurst",function(Re,ne,te){var he=It(6),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<he.length;me+=3)pe.add(new go.PathSegment(go.PathSegment.Bezier,he[me+2].x*ne,he[me+2].y*te,he[me].x*ne,he[me].y*te,he[me+1].x*ne,he[me+1].y*te));return pe.segments.last().close(),wt(he),le.spot1=new go.Spot(.17,.222),le.spot2=new go.Spot(.833,.777),le}),go.Shape.defineFigureGenerator("SevenPointedBurst",function(Re,ne,te){var he=It(7),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<he.length;me+=3)pe.add(new go.PathSegment(go.PathSegment.Bezier,he[me+2].x*ne,he[me+2].y*te,he[me].x*ne,he[me].y*te,he[me+1].x*ne,he[me+1].y*te));return pe.segments.last().close(),wt(he),le.spot1=new go.Spot(.222,.222),le.spot2=new go.Spot(.777,.777),le}),go.Shape.defineFigureGenerator("EightPointedBurst",function(Re,ne,te){var he=It(8),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<he.length;me+=3)pe.add(new go.PathSegment(go.PathSegment.Bezier,he[me+2].x*ne,he[me+2].y*te,he[me].x*ne,he[me].y*te,he[me+1].x*ne,he[me+1].y*te));return pe.segments.last().close(),wt(he),le.spot1=new go.Spot(.222,.222),le.spot2=new go.Spot(.777,.777),le}),go.Shape.defineFigureGenerator("NinePointedBurst",function(Re,ne,te){var he=It(9),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<he.length;me+=3)pe.add(new go.PathSegment(go.PathSegment.Bezier,he[me+2].x*ne,he[me+2].y*te,he[me].x*ne,he[me].y*te,he[me+1].x*ne,he[me+1].y*te));return pe.segments.last().close(),wt(he),le.spot1=new go.Spot(.222,.222),le.spot2=new go.Spot(.777,.777),le}),go.Shape.defineFigureGenerator("TenPointedBurst",function(Re,ne,te){var he=It(10),le=new go.Geometry,pe=new go.PathFigure(he[0].x*ne,he[0].y*te,!0);le.add(pe);for(var me=1;me<he.length;me+=3)pe.add(new go.PathSegment(go.PathSegment.Bezier,he[me+2].x*ne,he[me+2].y*te,he[me].x*ne,he[me].y*te,he[me+1].x*ne,he[me+1].y*te));return pe.segments.last().close(),wt(he),le.spot1=new go.Spot(.222,.222),le.spot2=new go.Spot(.777,.777),le}),go.Shape.setFigureParameter("FramedRectangle",0,new jn("ThicknessX",8)),go.Shape.setFigureParameter("FramedRectangle",1,new jn("ThicknessY",8)),go.Shape.defineFigureGenerator("FramedRectangle",function(Re,ne,te){var he=Re?Re.parameter1:NaN,le=Re?Re.parameter2:NaN;isNaN(he)&&(he=8),isNaN(le)&&(le=8);var pe=new go.Geometry,me=new go.PathFigure(0,0,!0);return pe.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he<ne/2&&le<te/2&&(me.add(new go.PathSegment(go.PathSegment.Move,he,le)),me.add(new go.PathSegment(go.PathSegment.Line,he,te-le)),me.add(new go.PathSegment(go.PathSegment.Line,ne-he,te-le)),me.add(new go.PathSegment(go.PathSegment.Line,ne-he,le).close())),pe.setSpots(0,0,1,1,he,le,-he,-le),pe}),go.Shape.setFigureParameter("Ring",0,new jn("Thickness",8)),go.Shape.defineFigureGenerator("Ring",function(Re,ne,te){var he=Re?Re.parameter1:NaN;(isNaN(he)||he<0)&&(he=8);var le=ne/2,pe=new go.Geometry,me=new go.PathFigure(ne,ne/2,!0);pe.add(me),me.add(new go.PathSegment(go.PathSegment.Arc,0,360,le,le,le,le).close());var xe=Math.max(le-he,0);return xe>0&&(me.add(new go.PathSegment(go.PathSegment.Move,ne/2+xe,ne/2)),me.add(new go.PathSegment(go.PathSegment.Arc,0,-360,le,le,xe,xe).close())),pe.spot1=kt,pe.spot2=Ie,pe.defaultStretch=go.GraphObject.Uniform,pe}),go.Shape.defineFigureGenerator("Cloud",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(.08034461*ne,.1944299*te,!0).add(new go.PathSegment(go.PathSegment.Bezier,.2008615*ne,.05349299*te,-.09239631*ne,.07836421*te,.1406031*ne,-.0542823*te)).add(new go.PathSegment(go.PathSegment.Bezier,.4338609*ne,.074219*te,.2450511*ne,-.00697547*te,.3776197*ne,-.01112067*te)).add(new go.PathSegment(go.PathSegment.Bezier,.6558228*ne,.07004196*te,.4539471*ne,0,.6066018*ne,-.02526587*te)).add(new go.PathSegment(go.PathSegment.Bezier,.8921095*ne,.08370865*te,.6914277*ne,-.01904177*te,.8921095*ne,-.01220843*te)).add(new go.PathSegment(go.PathSegment.Bezier,.9147671*ne,.3194596*te,1.036446*ne,.04105738*te,1.020377*ne,.3022052*te)).add(new go.PathSegment(go.PathSegment.Bezier,.9082935*ne,.562044*te,1.04448*ne,.360238*te,.992256*ne,.5219009*te)).add(new go.PathSegment(go.PathSegment.Bezier,.9212406*ne,.8217117*te,1.032337*ne,.5771781*te,1.018411*ne,.8120651*te)).add(new go.PathSegment(go.PathSegment.Bezier,.7592566*ne,.9156953*te,1.028411*ne,.9571472*te,.8556702*ne,1.052487*te)).add(new go.PathSegment(go.PathSegment.Bezier,.5101666*ne,.9310455*te,.7431877*ne,1.009325*te,.5624123*ne,1.021761*te)).add(new go.PathSegment(go.PathSegment.Bezier,.2609328*ne,.9344623*te,.4820677*ne,1.031761*te,.3030112*ne,1.002796*te)).add(new go.PathSegment(go.PathSegment.Bezier,.08034461*ne,.870098*te,.2329994*ne,1.01518*te,.03213784*ne,1.01518*te)).add(new go.PathSegment(go.PathSegment.Bezier,.06829292*ne,.6545475*te,-.02812061*ne,.9032597*te,-.01205169*ne,.6835638*te)).add(new go.PathSegment(go.PathSegment.Bezier,.06427569*ne,.4265613*te,-.01812061*ne,.6089503*te,-.00606892*ne,.4555777*te)).add(new go.PathSegment(go.PathSegment.Bezier,.08034461*ne,.1944299*te,-.01606892*ne,.3892545*te,-.01205169*ne,.1944299*te))).setSpots(.1,.1,.9,.9)}),go.Shape.defineFigureGenerator("StopSign",function(Re,ne,te){var he=1/(Math.SQRT2+2);return new go.Geometry().add(new go.PathFigure(he*ne,0,!0).add(new go.PathSegment(go.PathSegment.Line,(1-he)*ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne,he*te)).add(new go.PathSegment(go.PathSegment.Line,ne,(1-he)*te)).add(new go.PathSegment(go.PathSegment.Line,(1-he)*ne,te)).add(new go.PathSegment(go.PathSegment.Line,he*ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,(1-he)*te)).add(new go.PathSegment(go.PathSegment.Line,0,he*te).close())).setSpots(he/2,he/2,1-he/2,1-he/2)}),go.Shape.setFigureParameter("Pie",0,new jn("Start",0,-360,360)),go.Shape.setFigureParameter("Pie",1,new jn("Sweep",315,-360,360)),go.Shape.defineFigureGenerator("Pie",function(Re,ne,te){var he=Re?Re.parameter1:NaN,le=Re?Re.parameter2:NaN;isNaN(he)&&(he=0),isNaN(le)&&(le=315);var pe=he%360;pe<0&&(pe+=360);var me=le%360,xe=Math.min(ne,te)/2;return new go.Geometry().add(new go.PathFigure(xe,xe).add(new go.PathSegment(go.PathSegment.Arc,pe,me,xe,xe,xe,xe).close()))}),go.Shape.defineFigureGenerator("PiePiece",function(Re,ne,te){var he=$e/Math.SQRT2*.5,le=Math.SQRT2/2,pe=1-Math.SQRT2/2;return new go.Geometry().add(new go.PathFigure(ne,te,!0).add(new go.PathSegment(go.PathSegment.Bezier,le*ne,pe*te,ne,(1-he)*te,(le+he)*ne,(pe+he)*te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close()))}),go.Shape.setFigureParameter("ThickCross",0,new jn("Thickness",30)),go.Shape.defineFigureGenerator("ThickCross",function(Re,ne,te){var he=Re?Re.parameter1:NaN;(isNaN(he)||he<0)&&(he=30);var le=Math.min(he,ne)/2,pe=ne/2,me=te/2;return new go.Geometry().add(new go.PathFigure(pe-le,0,!0).add(new go.PathSegment(go.PathSegment.Line,pe+le,0)).add(new go.PathSegment(go.PathSegment.Line,pe+le,me-le)).add(new go.PathSegment(go.PathSegment.Line,ne,me-le)).add(new go.PathSegment(go.PathSegment.Line,ne,me+le)).add(new go.PathSegment(go.PathSegment.Line,pe+le,me+le)).add(new go.PathSegment(go.PathSegment.Line,pe+le,te)).add(new go.PathSegment(go.PathSegment.Line,pe-le,te)).add(new go.PathSegment(go.PathSegment.Line,pe-le,me+le)).add(new go.PathSegment(go.PathSegment.Line,0,me+le)).add(new go.PathSegment(go.PathSegment.Line,0,me-le)).add(new go.PathSegment(go.PathSegment.Line,pe-le,me-le).close()))}),go.Shape.setFigureParameter("ThinCross",0,new jn("Thickness",10)),go.Shape.defineFigureGenerator("ThinCross",function(Re,ne,te){var he=Re?Re.parameter1:NaN;(isNaN(he)||he<0)&&(he=10);var le=Math.min(he,ne)/2,pe=ne/2,me=te/2;return new go.Geometry().add(new go.PathFigure(pe-le,0,!0).add(new go.PathSegment(go.PathSegment.Line,pe+le,0)).add(new go.PathSegment(go.PathSegment.Line,pe+le,me-le)).add(new go.PathSegment(go.PathSegment.Line,ne,me-le)).add(new go.PathSegment(go.PathSegment.Line,ne,me+le)).add(new go.PathSegment(go.PathSegment.Line,pe+le,me+le)).add(new go.PathSegment(go.PathSegment.Line,pe+le,te)).add(new go.PathSegment(go.PathSegment.Line,pe-le,te)).add(new go.PathSegment(go.PathSegment.Line,pe-le,me+le)).add(new go.PathSegment(go.PathSegment.Line,0,me+le)).add(new go.PathSegment(go.PathSegment.Line,0,me-le)).add(new go.PathSegment(go.PathSegment.Line,pe-le,me-le).close()))}),go.Shape.setFigureParameter("ThickX",0,new jn("Thickness",30)),go.Shape.defineFigureGenerator("ThickX",function(Re,ne,te){var he=Re?Re.parameter1:NaN;if((isNaN(he)||he<0)&&(he=30),ne===0||te===0){var le=new go.Geometry(go.Geometry.Rectangle);return le.startX=0,le.startY=0,le.endX=ne,le.endY=te,le}else{var pe=ne/2,me=te/2,xe=Math.atan2(te,ne),Ee=he-Math.min(Math.cos(xe)*he/2,pe),Ge=he-Math.min(Math.sin(xe)*he/2,me),le=new go.Geometry,et=new go.PathFigure(Ee,0,!0);return le.add(et),et.add(new go.PathSegment(go.PathSegment.Line,pe,.2*te)),et.add(new go.PathSegment(go.PathSegment.Line,ne-Ee,0)),et.add(new go.PathSegment(go.PathSegment.Line,ne,Ge)),et.add(new go.PathSegment(go.PathSegment.Line,.8*ne,me)),et.add(new go.PathSegment(go.PathSegment.Line,ne,te-Ge)),et.add(new go.PathSegment(go.PathSegment.Line,ne-Ee,te)),et.add(new go.PathSegment(go.PathSegment.Line,pe,.8*te)),et.add(new go.PathSegment(go.PathSegment.Line,Ee,te)),et.add(new go.PathSegment(go.PathSegment.Line,0,te-Ge)),et.add(new go.PathSegment(go.PathSegment.Line,.2*ne,me)),et.add(new go.PathSegment(go.PathSegment.Line,0,Ge).close()),le}}),go.Shape.setFigureParameter("ThinX",0,new jn("Thickness",10)),go.Shape.defineFigureGenerator("ThinX",function(Re,ne,te){var he=Re?Re.parameter1:NaN;(isNaN(he)||he<0)&&(he=10);var le=new go.Geometry,pe=new go.PathFigure(.1*ne,0,!0);return le.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.9*ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.1*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.9*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.9*ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.1*ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,.9*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,.1*te).close()),le}),go.Shape.setFigureParameter("SquareIBeam",0,new jn("BeamWidth",.2,.1,.9)),go.Shape.defineFigureGenerator("SquareIBeam",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.2);var le=new go.Geometry,pe=new go.PathFigure(0,0,!0);return le.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,he*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(.5+he/2)*ne,he*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(.5+he/2)*ne,(1-he)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,(1-he)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,(1-he)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(.5-he/2)*ne,(1-he)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(.5-he/2)*ne,he*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,he*te).close()),le}),go.Shape.setFigureParameter("RoundedIBeam",0,new jn("Curviness",.5,.05,.65)),go.Shape.defineFigureGenerator("RoundedIBeam",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.5);var le=new go.Geometry,pe=new go.PathFigure(0,0,!0);return le.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Bezier,ne,te,Math.abs(1-he)*ne,.25*te,Math.abs(1-he)*ne,.75*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,0,0,he*ne,.75*te,he*ne,.25*te).close()),le}),go.Shape.defineFigureGenerator("HalfEllipse",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,$e*ne,0,ne,(.5-$e/2)*te)).add(new go.PathSegment(go.PathSegment.Bezier,0,te,ne,(.5+$e/2)*te,$e*ne,te).close())).setSpots(0,.156,.844,.844)}),go.Shape.defineFigureGenerator("Crescent",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Bezier,0,te,ne,0,ne,te)).add(new go.PathSegment(go.PathSegment.Bezier,0,0,.5*ne,.75*te,.5*ne,.25*te).close())).setSpots(.311,.266,.744,.744)}),go.Shape.defineFigureGenerator("Heart",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(.5*ne,te,!0).add(new go.PathSegment(go.PathSegment.Bezier,0,.3*te,.1*ne,.8*te,0,.5*te)).add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.3*te,0,0,.45*ne,0)).add(new go.PathSegment(go.PathSegment.Bezier,ne,.3*te,.55*ne,0,ne,0)).add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te,ne,.5*te,.9*ne,.8*te).close())).setSpots(.14,.29,.86,.78)}),go.Shape.defineFigureGenerator("Spade",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(.5*ne,0,!0).add(new go.PathSegment(go.PathSegment.Line,.51*ne,.01*te)).add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,.6*ne,.2*te,ne,.25*te)).add(new go.PathSegment(go.PathSegment.Bezier,.55*ne,.7*te,ne,.8*te,.6*ne,.8*te)).add(new go.PathSegment(go.PathSegment.Bezier,.75*ne,te,.5*ne,.75*te,.55*ne,.95*te)).add(new go.PathSegment(go.PathSegment.Line,.25*ne,te)).add(new go.PathSegment(go.PathSegment.Bezier,.45*ne,.7*te,.45*ne,.95*te,.5*ne,.75*te)).add(new go.PathSegment(go.PathSegment.Bezier,0,.5*te,.4*ne,.8*te,0,.8*te)).add(new go.PathSegment(go.PathSegment.Bezier,.49*ne,.01*te,0,.25*te,.4*ne,.2*te).close())).setSpots(.14,.26,.86,.78)}),go.Shape.defineFigureGenerator("Club",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.4*ne,.6*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Bezier,.15*ne,te,.5*ne,.75*te,.45*ne,.95*te)),le.add(new go.PathSegment(go.PathSegment.Line,.85*ne,te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.6*ne,.6*te,.55*ne,.95*te,.5*ne,.75*te));var pe=.2,me=.3,xe=0,Ee=pe*$e;return le.add(new go.PathSegment(go.PathSegment.Bezier,(.5+me)*ne,(.5+pe+xe)*te,(.5-pe+me)*ne,(.5+Ee+xe)*te,(.5-Ee+me)*ne,(.5+pe+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,(1-.5+pe+me)*ne,(.5+xe)*te,(.5+Ee+me)*ne,(.5+pe+xe)*te,(.5+pe+me)*ne,(.5+Ee+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,(.5+me)*ne,(.5-pe+xe)*te,(1-.5+pe+me)*ne,(.5-Ee+xe)*te,(.5+Ee+me)*ne,(.5-pe+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.65*ne,.36771243*te,(.5-Ee+me)*ne,(.5-pe+xe)*te,(.5-pe+me+.05)*ne,(.5-Ee+xe-.02)*te)),pe=.2,me=0,xe=-.3,Ee=pe*$e,le.add(new go.PathSegment(go.PathSegment.Bezier,(1-.5+pe+me)*ne,(.5+xe)*te,(.5+Ee+me)*ne,(.5+pe+xe)*te,(.5+pe+me)*ne,(.5+Ee+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,(.5+me)*ne,(.5-pe+xe)*te,(1-.5+pe+me)*ne,(.5-Ee+xe)*te,(.5+Ee+me)*ne,(.5-pe+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,(.5-pe+me)*ne,(.5+xe)*te,(.5-Ee+me)*ne,(.5-pe+xe)*te,(.5-pe+me)*ne,(.5-Ee+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,(.5-Ee+me)*ne,(.5+pe+xe)*te,(.5-pe+me)*ne,(.5+Ee+xe)*te,(.5-Ee+me)*ne,(.5+pe+xe)*te)),pe=.2,me=-.3,xe=0,Ee=pe*$e,le.add(new go.PathSegment(go.PathSegment.Bezier,(.5+me)*ne,(.5-pe+xe)*te,(1-.5+pe+me-.05)*ne,(.5-Ee+xe-.02)*te,(.5+Ee+me)*ne,(.5-pe+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,(.5-pe+me)*ne,(.5+xe)*te,(.5-Ee+me)*ne,(.5-pe+xe)*te,(.5-pe+me)*ne,(.5-Ee+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,(.5+me)*ne,(.5+pe+xe)*te,(.5-pe+me)*ne,(.5+Ee+xe)*te,(.5-Ee+me)*ne,(.5+pe+xe)*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.4*ne,.6*te,(.5+Ee+me)*ne,(.5+pe+xe)*te,(.5+pe+me)*ne,(.5+Ee+xe)*te).close()),he.setSpots(.06,.33,.93,.68),he}),go.Shape.defineFigureGenerator("YinYang",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*.5,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Arc,270,180,ne*.5,ne*.5,ne*.5,ne*.5)),le.add(new go.PathSegment(go.PathSegment.Arc,90,-180,ne*.5,ne*.75,ne*.25,ne*.25)),le.add(new go.PathSegment(go.PathSegment.Arc,90,180,ne*.5,ne*.25,ne*.25,ne*.25));var pe=.1,me=.5,xe=.25;return le.add(new go.PathSegment(go.PathSegment.Move,(me+pe)*ne,xe*te)),le.add(new go.PathSegment(go.PathSegment.Arc,0,-360,ne*me,te*xe,pe*ne,pe*ne).close()),le=new go.PathFigure(ne*.5,0,!1),he.add(le),le.add(new go.PathSegment(go.PathSegment.Arc,270,-180,ne*.5,ne*.5,ne*.5,ne*.5)),xe=.75,le=new go.PathFigure((me+pe)*ne,xe*te,!0),he.add(le),le.add(new go.PathSegment(go.PathSegment.Arc,0,360,ne*me,te*xe,pe*ne,pe*ne).close()),he.defaultStretch=go.GraphObject.Uniform,he}),go.Shape.defineFigureGenerator("Peace",function(Re,ne,te){var he=.8535533905932737,le=.5*ne,pe=.5*te;return new go.Geometry().add(new go.PathFigure(le,0,!1).add(new go.PathSegment(go.PathSegment.Arc,270,360,le,pe,le,pe)).add(new go.PathSegment(go.PathSegment.Line,le,te)).add(new go.PathSegment(go.PathSegment.Move,le,pe)).add(new go.PathSegment(go.PathSegment.Line,(1-he)*ne,he*te)).add(new go.PathSegment(go.PathSegment.Move,le,pe)).add(new go.PathSegment(go.PathSegment.Line,he*ne,he*te)))}),go.Shape.defineFigureGenerator("NotAllowed",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=.5,me=.5,xe=.5,Ee=new go.PathFigure(me*ne,(xe-pe)*te);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me-pe)*ne,xe*te,(me-le)*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+pe)*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,xe*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-pe)*te,(me+pe)*ne,(xe-le)*te,(me+le)*ne,(xe-pe)*te)),pe=.4,le=$e*.4;var Ge=Ne(),et=Ne(),ut=Ne(),st=Ne();$t(me,xe-pe,me+le,xe-pe,me+pe,xe-le,me+pe,xe,.42,Ge,et,ut,st,st);var it=Ne(),Nt=Ne(),St=Ne();$t(me,xe-pe,me+le,xe-pe,me+pe,xe-le,me+pe,xe,.58,st,st,St,it,Nt);var Ft=Ne(),cn=Ne(),Tt=Ne();$t(me,xe+pe,me-le,xe+pe,me-pe,xe+le,me-pe,xe,.42,Ft,cn,Tt,st,st);var hi=Ne(),di=Ne(),zn=Ne();return $t(me,xe+pe,me-le,xe+pe,me-pe,xe+le,me-pe,xe,.58,st,st,zn,hi,di),Ee.add(new go.PathSegment(go.PathSegment.Move,zn.x*ne,zn.y*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me-pe)*ne,xe*te,hi.x*ne,hi.y*te,di.x*ne,di.y*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,ut.x*ne,ut.y*te,Ge.x*ne,Ge.y*te,et.x*ne,et.y*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,zn.x*ne,zn.y*te).close()),Ee.add(new go.PathSegment(go.PathSegment.Move,Tt.x*ne,Tt.y*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,St.x*ne,St.y*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,xe*te,it.x*ne,it.y*te,Nt.x*ne,Nt.y*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,Tt.x*ne,Tt.y*te,Ft.x*ne,Ft.y*te,cn.x*ne,cn.y*te).close()),dt(Ge),dt(et),dt(ut),dt(st),dt(it),dt(Nt),dt(St),dt(Ft),dt(cn),dt(Tt),dt(hi),dt(di),dt(zn),he.defaultStretch=go.GraphObject.Uniform,he}),go.Shape.defineFigureGenerator("Fragile",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,.25*ne,0)).add(new go.PathSegment(go.PathSegment.Line,.2*ne,.15*te)).add(new go.PathSegment(go.PathSegment.Line,.3*ne,.25*te)).add(new go.PathSegment(go.PathSegment.Line,.29*ne,.33*te)).add(new go.PathSegment(go.PathSegment.Line,.35*ne,.25*te)).add(new go.PathSegment(go.PathSegment.Line,.3*ne,.15*te)).add(new go.PathSegment(go.PathSegment.Line,.4*ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Bezier,.55*ne,.5*te,ne,.25*te,.75*ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,.55*ne,.9*te)).add(new go.PathSegment(go.PathSegment.Line,.7*ne,.9*te)).add(new go.PathSegment(go.PathSegment.Line,.7*ne,te)).add(new go.PathSegment(go.PathSegment.Line,.3*ne,te)).add(new go.PathSegment(go.PathSegment.Line,.3*ne,.9*te)).add(new go.PathSegment(go.PathSegment.Line,.45*ne,.9*te)).add(new go.PathSegment(go.PathSegment.Line,.45*ne,.5*te)).add(new go.PathSegment(go.PathSegment.Bezier,0,0,.25*ne,.5*te,0,.25*te).close()))}),go.Shape.setFigureParameter("HourGlass",0,new jn("Thickness",30)),go.Shape.defineFigureGenerator("HourGlass",function(Re,ne,te){var he=Re?Re.parameter1:NaN;(isNaN(he)||he<0)&&(he=30),he>ne&&(he=ne);var le=(ne-he)/2,pe=le+he;return new go.Geometry().add(new go.PathFigure(pe,.5*te).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,te)).add(new go.PathSegment(go.PathSegment.Line,le,.5*te)).add(new go.PathSegment(go.PathSegment.Line,0,0)).add(new go.PathSegment(go.PathSegment.Line,ne,0).close()))}),go.Shape.defineFigureGenerator("Lightning",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,.55*te).add(new go.PathSegment(go.PathSegment.Line,.6*ne,0)).add(new go.PathSegment(go.PathSegment.Line,.3*ne,.45*te)).add(new go.PathSegment(go.PathSegment.Line,ne,.45*te)).add(new go.PathSegment(go.PathSegment.Line,.4*ne,te)).add(new go.PathSegment(go.PathSegment.Line,.7*ne,.55*te).close()))}),go.Shape.defineFigureGenerator("GenderMale",function(Re,ne,te){var he=new go.Geometry,le=$e*.4,pe=.4,me=.5,xe=.5,Ee=Ne(),Ge=Ne(),et=Ne(),ut=Ne(),st=new go.PathFigure((me-pe)*ne,xe*te,!1);he.add(st),st.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te)),$t(me,xe-pe,me+le,xe-pe,me+pe,xe-le,me+pe,xe,.44,et,ut,Ge,Ee,Ee),st.add(new go.PathSegment(go.PathSegment.Bezier,Ge.x*ne,Ge.y*te,et.x*ne,et.y*te,ut.x*ne,ut.y*te));var it=De(Ge.x,Ge.y);$t(me,xe-pe,me+le,xe-pe,me+pe,xe-le,me+pe,xe,.56,Ee,Ee,Ge,et,ut);var Nt=De(Ge.x,Ge.y);st.add(new go.PathSegment(go.PathSegment.Line,(it.x*.1+.95*.9)*ne,it.y*.1*te)),st.add(new go.PathSegment(go.PathSegment.Line,.85*ne,it.y*.1*te)),st.add(new go.PathSegment(go.PathSegment.Line,.85*ne,0)),st.add(new go.PathSegment(go.PathSegment.Line,ne,0)),st.add(new go.PathSegment(go.PathSegment.Line,ne,.15*te)),st.add(new go.PathSegment(go.PathSegment.Line,(Nt.x*.1+.9)*ne,.15*te)),st.add(new go.PathSegment(go.PathSegment.Line,(Nt.x*.1+.9)*ne,(Nt.y*.1+.05*.9)*te)),st.add(new go.PathSegment(go.PathSegment.Line,Nt.x*ne,Nt.y*te)),st.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,xe*te,et.x*ne,et.y*te,ut.x*ne,ut.y*te)),st.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te)),st.add(new go.PathSegment(go.PathSegment.Bezier,(me-pe)*ne,xe*te,(me-le)*ne,(xe+pe)*te,(me-pe)*ne,(xe+le)*te)),pe=.35,le=$e*.35;var St=new go.PathFigure(me*ne,(xe-pe)*te,!1);he.add(St),St.add(new go.PathSegment(go.PathSegment.Bezier,(me-pe)*ne,xe*te,(me-le)*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te)),St.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+pe)*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te)),St.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,xe*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),St.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-pe)*te,(me+pe)*ne,(xe-le)*te,(me+le)*ne,(xe-pe)*te));var Ft=new go.PathFigure((me-pe)*ne,xe*te,!1);return he.add(Ft),dt(Ee),dt(Ge),dt(et),dt(ut),dt(it),dt(Nt),he.spot1=new go.Spot(.202,.257),he.spot2=new go.Spot(.792,.739),he.defaultStretch=go.GraphObject.Uniform,he}),go.Shape.defineFigureGenerator("GenderFemale",function(Re,ne,te){var he=new go.Geometry,le=.375,pe=0,me=-.125,xe=le*$e,Ee=new go.PathFigure((.525+pe)*ne,(.5+le+me)*te,!1);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(1-.5+le+pe)*ne,(.5+me)*te,(.5+xe+pe)*ne,(.5+le+me)*te,(.5+le+pe)*ne,(.5+xe+me)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(.5+pe)*ne,(.5-le+me)*te,(1-.5+le+pe)*ne,(.5-xe+me)*te,(.5+xe+pe)*ne,(.5-le+me)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(.5-le+pe)*ne,(.5+me)*te,(.5-xe+pe)*ne,(.5-le+me)*te,(.5-le+pe)*ne,(.5-xe+me)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(.475+pe)*ne,(.5+le+me)*te,(.5-le+pe)*ne,(.5+xe+me)*te,(.5-xe+pe)*ne,(.5+le+me)*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.475*ne,.85*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.425*ne,.85*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.425*ne,.9*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.475*ne,.9*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.475*ne,te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.525*ne,te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.525*ne,.9*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.575*ne,.9*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.575*ne,.85*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.525*ne,.85*te).close()),le=.325,pe=0,me=-.125,xe=le*$e;var Ee=new go.PathFigure((1-.5+le+pe)*ne,(.5+me)*te,!1);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(.5+pe)*ne,(.5+le+me)*te,(.5+le+pe)*ne,(.5+xe+me)*te,(.5+xe+pe)*ne,(.5+le+me)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(.5-le+pe)*ne,(.5+me)*te,(.5-xe+pe)*ne,(.5+le+me)*te,(.5-le+pe)*ne,(.5+xe+me)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(.5+pe)*ne,(.5-le+me)*te,(.5-le+pe)*ne,(.5-xe+me)*te,(.5-xe+pe)*ne,(.5-le+me)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(1-.5+le+pe)*ne,(.5+me)*te,(.5+xe+pe)*ne,(.5-le+me)*te,(1-.5+le+pe)*ne,(.5-xe+me)*te));var Ee=new go.PathFigure((.525+pe)*ne,(.5+le+me)*te,!1);return he.add(Ee),he.spot1=new go.Spot(.232,.136),he.spot2=new go.Spot(.682,.611),he.defaultStretch=go.GraphObject.Uniform,he}),go.Shape.defineFigureGenerator("LogicImplies",function(Re,ne,te){var he=Re?Re.parameter1:NaN;return isNaN(he)&&(he=.2),new go.Geometry().add(new go.PathFigure((1-he)*ne,0,!1).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,(1-he)*ne,te)).add(new go.PathSegment(go.PathSegment.Move,0,.5*te)).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te))).setSpots(0,0,.8,.5)}),go.Shape.defineFigureGenerator("LogicIff",function(Re,ne,te){var he=Re?Re.parameter1:NaN;return isNaN(he)&&(he=.2),new go.Geometry().add(new go.PathFigure((1-he)*ne,0,!1).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,(1-he)*ne,te)).add(new go.PathSegment(go.PathSegment.Move,0,.5*te)).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)).add(new go.PathSegment(go.PathSegment.Move,he*ne,0)).add(new go.PathSegment(go.PathSegment.Line,0,.5*te)).add(new go.PathSegment(go.PathSegment.Line,he*ne,te))).setSpots(.2,0,.8,.5)}),go.Shape.defineFigureGenerator("LogicNot",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te)))}),go.Shape.defineFigureGenerator("LogicAnd",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,te,!1).add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te))).setSpots(.25,.5,.75,1)}),go.Shape.defineFigureGenerator("LogicOr",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)).add(new go.PathSegment(go.PathSegment.Line,ne,0))).setSpots(.219,0,.78,.409)}),go.Shape.defineFigureGenerator("LogicXor",function(Re,ne,te){var he=new go.Geometry().add(new go.PathFigure(.5*ne,0,!1).add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)).add(new go.PathSegment(go.PathSegment.Move,0,.5*te)).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)).add(new go.PathSegment(go.PathSegment.Arc,0,360,.5*ne,.5*te,.5*ne,.5*te)));return he.defaultStretch=go.GraphObject.Uniform,he}),go.Shape.defineFigureGenerator("LogicTruth",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Move,.5*ne,0)).add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)))}),go.Shape.defineFigureGenerator("LogicFalsity",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,te,!1).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Move,.5*ne,te)).add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)))}),go.Shape.defineFigureGenerator("LogicThereExists",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,0,.5*te)).add(new go.PathSegment(go.PathSegment.Move,ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,te)))}),go.Shape.defineFigureGenerator("LogicForAll",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Move,.25*ne,.5*te)).add(new go.PathSegment(go.PathSegment.Line,.75*ne,.5*te))).setSpots(.25,0,.75,.5)}),go.Shape.defineFigureGenerator("LogicIsDefinedAs",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Move,0,.5*te)).add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)).add(new go.PathSegment(go.PathSegment.Move,0,te)).add(new go.PathSegment(go.PathSegment.Line,ne,te))).setSpots(.01,.01,.99,.49)}),go.Shape.defineFigureGenerator("LogicIntersect",function(Re,ne,te){var he=.5;return new go.Geometry().add(new go.PathFigure(0,te,!1).add(new go.PathSegment(go.PathSegment.Line,0,he*te)).add(new go.PathSegment(go.PathSegment.Arc,180,180,he*ne,he*te,he*ne,he*te)).add(new go.PathSegment(go.PathSegment.Line,ne,te))).setSpots(0,.5,1,1)}),go.Shape.defineFigureGenerator("LogicUnion",function(Re,ne,te){var he=.5;return new go.Geometry().add(new go.PathFigure(ne,0,!1).add(new go.PathSegment(go.PathSegment.Line,ne,he*te)).add(new go.PathSegment(go.PathSegment.Arc,0,180,he*ne,he*te,he*ne,he*te)).add(new go.PathSegment(go.PathSegment.Line,0,0))).setSpots(0,0,1,.5)}),go.Shape.setFigureParameter("Arrow",0,new jn("ArrowheadWidth",.3,.01,.99)),go.Shape.setFigureParameter("Arrow",1,new jn("TailHeight",.3,.01,.99)),go.Shape.defineFigureGenerator("Arrow",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.3);var le=Re?Re.parameter2:NaN;isNaN(le)&&(le=.3);var pe=(1-he)*ne,me=(.5-le/2)*te,xe=(.5+le/2)*te,Ee=new go.Geometry,Ge=new go.PathFigure(0,me,!0);Ee.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Line,pe,me)),Ge.add(new go.PathSegment(go.PathSegment.Line,pe,0)),Ge.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),Ge.add(new go.PathSegment(go.PathSegment.Line,pe,te)),Ge.add(new go.PathSegment(go.PathSegment.Line,pe,xe)),Ge.add(new go.PathSegment(go.PathSegment.Line,0,xe).close()),Ee.spot1=new go.Spot(0,me/te);var et=Ut(0,xe/te,1,xe/te,pe/ne,1,1,.5,Ne());return Ee.spot2=new go.Spot(et.x,et.y),dt(et),Ee}),go.Shape.setFigureParameter("Arrow2",0,new jn("ArrowheadWidth",30)),go.Shape.setFigureParameter("Arrow2",0,new jn("TailHeight",30)),go.Shape.defineFigureGenerator("Arrow2",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=30),he>ne&&(he=ne);var le=Re?Re.parameter2:NaN;isNaN(le)&&(le=30),le=Math.min(le,te/2);var pe=ne-he,me=(te-le)/2,xe=me+le,Ee=new go.Geometry,Ge=new go.PathFigure(0,me,!0);Ee.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Line,pe,me)),Ge.add(new go.PathSegment(go.PathSegment.Line,pe,0)),Ge.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),Ge.add(new go.PathSegment(go.PathSegment.Line,pe,te)),Ge.add(new go.PathSegment(go.PathSegment.Line,pe,xe)),Ge.add(new go.PathSegment(go.PathSegment.Line,0,xe).close()),Ee.spot1=new go.Spot(0,me/te);var et=Ut(0,xe/te,1,xe/te,pe/ne,1,1,.5,Ne());return Ee.spot2=new go.Spot(et.x,et.y),dt(et),Ee}),go.Shape.defineFigureGenerator("Chevron",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te).close()),he}),go.Shape.defineFigureGenerator("DoubleArrow",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,.214*te)),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,1*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,1*te)),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,.786*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,1*te).close()),he}),go.Shape.setFigureParameter("DoubleEndArrow",0,new jn("ConnecterHeight",.3,.01,.99)),go.Shape.defineFigureGenerator("DoubleEndArrow",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.3);var le=(.5-he/2)*te,pe=(.5+he/2)*te,me=new go.Geometry,xe=new go.PathFigure(ne,.5*te,!0);me.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,.3*ne,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,.3*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Line,0,.5*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.3*ne,0)),xe.add(new go.PathSegment(go.PathSegment.Line,.3*ne,le)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,le)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,0).close());var Ee=Ut(0,.5,.3,0,0,le/te,.1,le/te,Ne());return me.spot1=new go.Spot(Ee.x,Ee.y),Ee=Ut(.7,1,1,.5,0,pe/te,1,pe/te,Ee),me.spot2=new go.Spot(Ee.x,Ee.y),dt(Ee),me}),go.Shape.setFigureParameter("DoubleEndArrow2",0,new jn("ConnecterHeight",40)),go.Shape.setFigureParameter("DoubleEndArrow2",1,new jn("ArrowHeight",100)),go.Shape.defineFigureGenerator("DoubleEndArrow2",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=40);var le=Re?Re.parameter2:NaN;isNaN(le)&&(le=100);var pe=(te-he)/2,me=pe+he,xe=(te-le)/2,Ee=xe+le;(he>te||le>te)&&(le>he?(he=he*te/le,pe=(te-he)/2,me=pe+he,xe=0,Ee=te):(pe=0,me=te,xe=0,Ee=te));var Ge=new go.Geometry,et=new go.PathFigure(ne,.5*te,!0);Ge.add(et),et.add(new go.PathSegment(go.PathSegment.Line,.7*ne,Ee)),et.add(new go.PathSegment(go.PathSegment.Line,.7*ne,me)),et.add(new go.PathSegment(go.PathSegment.Line,.3*ne,me)),et.add(new go.PathSegment(go.PathSegment.Line,.3*ne,Ee)),et.add(new go.PathSegment(go.PathSegment.Line,0,.5*te)),et.add(new go.PathSegment(go.PathSegment.Line,.3*ne,xe)),et.add(new go.PathSegment(go.PathSegment.Line,.3*ne,pe)),et.add(new go.PathSegment(go.PathSegment.Line,.7*ne,pe)),et.add(new go.PathSegment(go.PathSegment.Line,.7*ne,xe).close());var ut=Ut(0,.5,.3,xe/te,0,pe/te,1,pe/te,Ne());return Ge.spot1=new go.Spot(ut.x,ut.y),ut=Ut(.7,Ee/te,1,.5,0,me/te,1,me/te,ut),Ge.spot2=new go.Spot(ut.x,ut.y),dt(ut),Ge}),go.Shape.setFigureParameter("IBeamArrow",0,new jn("ConnectorHeight",.7,.51,.97)),go.Shape.defineFigureGenerator("IBeamArrow",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.3);var le=(.5-he/2)*te,pe=(.5+he/2)*te,me=new go.Geometry,xe=new go.PathFigure(ne,.5*te,!0);me.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,.2*ne,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,.2*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Line,0,te)),xe.add(new go.PathSegment(go.PathSegment.Line,0,0)),xe.add(new go.PathSegment(go.PathSegment.Line,.2*ne,0)),xe.add(new go.PathSegment(go.PathSegment.Line,.2*ne,le)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,le)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,0).close()),me.spot1=new go.Spot(0,le/te);var Ee=Ut(.7,1,1,.5,0,pe/te,1,pe/te,Ne());return me.spot2=new go.Spot(Ee.x,Ee.y),dt(Ee),me}),go.Shape.setFigureParameter("IBeamArrow2",0,new jn("ConnectorHeight",40)),go.Shape.setFigureParameter("IBeamArrow2",1,new jn("BeamArrowHeight",100)),go.Shape.defineFigureGenerator("IBeamArrow2",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=40);var le=Re?Re.parameter2:NaN;isNaN(le)&&(le=100);var pe=(te-he)/2,me=pe+he,xe=(te-le)/2,Ee=xe+le;(he>te||le>te)&&(le>he?(he=he*te/le,pe=(te-he)/2,me=pe+he,xe=0,Ee=te):(pe=0,me=te,xe=0,Ee=te));var Ge=new go.Geometry,et=new go.PathFigure(ne,.5*te,!0);Ge.add(et),et.add(new go.PathSegment(go.PathSegment.Line,.7*ne,Ee)),et.add(new go.PathSegment(go.PathSegment.Line,.7*ne,me)),et.add(new go.PathSegment(go.PathSegment.Line,.2*ne,me)),et.add(new go.PathSegment(go.PathSegment.Line,.2*ne,Ee)),et.add(new go.PathSegment(go.PathSegment.Line,0,Ee)),et.add(new go.PathSegment(go.PathSegment.Line,0,xe)),et.add(new go.PathSegment(go.PathSegment.Line,.2*ne,xe)),et.add(new go.PathSegment(go.PathSegment.Line,.2*ne,pe)),et.add(new go.PathSegment(go.PathSegment.Line,.7*ne,pe)),et.add(new go.PathSegment(go.PathSegment.Line,.7*ne,xe).close()),Ge.spot1=new go.Spot(0,pe/te);var ut=Ut(.7,Ee/te,1,.5,0,me/te,1,me/te,Ne());return Ge.spot2=new go.Spot(ut.x,ut.y),dt(ut),Ge}),go.Shape.setFigureParameter("Pointer",0,new jn("BackPoint",.1,0,.2)),go.Shape.defineFigureGenerator("Pointer",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.1);var le=new go.Geometry,pe=new go.PathFigure(ne,.5*te,!0);le.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,0,te)),pe.add(new go.PathSegment(go.PathSegment.Line,he*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,0).close()),le.spot1=new go.Spot(he,.35);var me=Ut(.2,.65,1,.65,0,1,1,.5,Ne());return le.spot2=new go.Spot(me.x,me.y),dt(me),le}),go.Shape.setFigureParameter("RoundedPointer",0,new jn("RoundedEdge",.3,0,.5)),go.Shape.defineFigureGenerator("RoundedPointer",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.3);var le=new go.Geometry,pe=new go.PathFigure(ne,.5*te,!0);le.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,0,te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,0,0,he*ne,.75*te,he*ne,.25*te).close()),le.spot1=new go.Spot(he,.35);var me=Ut(0,.65,1,.65,0,1,1,.5,Ne());return le.spot2=new go.Spot(me.x,me.y),dt(me),le}),go.Shape.setFigureParameter("SplitEndArrow",0,new jn("TailHeight",.4,.01,.99)),go.Shape.defineFigureGenerator("SplitEndArrow",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.4);var le=(.5-he/2)*te,pe=(.5+he/2)*te,me=new go.Geometry,xe=new go.PathFigure(ne,.5*te,!0);me.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,0,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.5*te)),xe.add(new go.PathSegment(go.PathSegment.Line,0,le)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,le)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,0).close()),me.spot1=new go.Spot(.2,.3);var Ee=Ut(.7,1,1,.5,0,pe/te,1,pe/te,Ne());return me.spot2=new go.Spot(Ee.x,Ee.y),dt(Ee),me}),go.Shape.setFigureParameter("SplitEndArrow2",0,new jn("TailThickness",50)),go.Shape.defineFigureGenerator("SplitEndArrow2",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=50);var le=(te-he)/2,pe=le+he;he>te&&(le=0,pe=te);var me=new go.Geometry,xe=new go.PathFigure(ne,.5*te,!0);me.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,0,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.5*te)),xe.add(new go.PathSegment(go.PathSegment.Line,0,le)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,le)),xe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,0).close()),me.spot1=new go.Spot(.2,le/te);var Ee=Ut(.7,1,1,.5,0,pe/te,1,pe/te,Ne());return me.spot2=new go.Spot(Ee.x,Ee.y),dt(Ee),me}),go.Shape.setFigureParameter("SquareArrow",0,new jn("ArrowPoint",.7,.2,.9)),go.Shape.defineFigureGenerator("SquareArrow",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.7);var le=new go.Geometry,pe=new go.PathFigure(ne,.5*te,!0);return le.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,he*ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,0)),pe.add(new go.PathSegment(go.PathSegment.Line,he*ne,0).close()),le.spot1=go.Spot.TopLeft,le.spot2=new go.Spot(he,1),le}),go.Shape.defineFigureGenerator("Cone1",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=$e*.1,me=new go.PathFigure(0,.9*te,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,ne,.9*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te,ne,(.9+pe)*te,(.5+le)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,.9*te,(.5-le)*ne,te,0,(.9+pe)*te).close()),he.spot1=new go.Spot(.25,.5),he.spot2=new go.Spot(.75,.97),he}),go.Shape.defineFigureGenerator("Cone2",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.9*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Bezier,ne,.9*te,(1-.85/.9)*ne,te,.85/.9*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,0,.9*te).close());var pe=new go.PathFigure(0,.9*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Bezier,ne,.9*te,(1-.85/.9)*ne,.8*te,.85/.9*ne,.8*te)),he.spot1=new go.Spot(.25,.5),he.spot2=new go.Spot(.75,.82),he}),go.Shape.defineFigureGenerator("Cube1",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.85*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.15*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,0,.15*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.85*te).close());var pe=new go.PathFigure(.5*ne,te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.3*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,.15*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.3*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.15*te)),he.spot1=new go.Spot(0,.3),he.spot2=new go.Spot(.5,.85),he}),go.Shape.defineFigureGenerator("Cube2",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.3*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,.7*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,0).close());var pe=new go.PathFigure(0,.3*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,.3*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Move,.7*ne,.3*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,te)),he.spot1=new go.Spot(0,.3),he.spot2=new go.Spot(.7,1),he}),go.Shape.defineFigureGenerator("Cylinder1",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=5),he=Math.min(he,te/3);var le=new go.Geometry,pe=$e*.5,me=new go.PathFigure(0,he,!0);le.add(me),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,0,0,$e*he,(.5-pe)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,1*ne,he,(.5+pe)*ne,0,1*ne,$e*he)),me.add(new go.PathSegment(go.PathSegment.Line,ne,te-he)),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,1*te,1*ne,te-$e*he,(.5+pe)*ne,1*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,te-he,(.5-pe)*ne,1*te,0,te-$e*he)),me.add(new go.PathSegment(go.PathSegment.Line,0,he));var xe=new go.PathFigure(ne,he,!1);return le.add(xe),xe.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,2*he,1*ne,2*he-$e*he,(.5+pe)*ne,2*he)),xe.add(new go.PathSegment(go.PathSegment.Bezier,0,he,(.5-pe)*ne,2*he,0,2*he-$e*he)),le.spot1=new go.Spot(0,0,0,2*he),le.spot2=new go.Spot(1,1),le}),go.Shape.defineFigureGenerator("Cylinder2",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=5),he=Math.min(he,te/3);var le=new go.Geometry,pe=$e*.5,me=new go.PathFigure(0,te-he,!0);le.add(me),me.add(new go.PathSegment(go.PathSegment.Line,0,he)),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,0,0,$e*he,(.5-pe)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,he,(.5+pe)*ne,0,ne,$e*he)),me.add(new go.PathSegment(go.PathSegment.Line,ne,te-he)),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te,ne,te-$e*he,(.5+pe)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,te-he,(.5-pe)*ne,te,0,te-$e*he));var xe=new go.PathFigure(0,te-he,!1);return le.add(xe),xe.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te-2*he,0,te-he-$e*he,(.5-pe)*ne,te-2*he)),xe.add(new go.PathSegment(go.PathSegment.Bezier,ne,te-he,(.5+pe)*ne,te-2*he,ne,te-he-$e*he)),le.spot1=new go.Spot(0,0),le.spot2=new go.Spot(1,1,0,-2*he),le}),go.Shape.defineFigureGenerator("Cylinder3",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=5),he=Math.min(he,ne/3);var le=new go.Geometry,pe=$e*.5,me=new go.PathFigure(he,0,!0);le.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne-he,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,ne-$e*he,0,ne,(.5-pe)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne-he,te,ne,(.5+pe)*te,ne-$e*he,te)),me.add(new go.PathSegment(go.PathSegment.Line,he,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*te,$e*he,te,0,(.5+pe)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,he,0,0,(.5-pe)*te,$e*he,0));var xe=new go.PathFigure(he,0,!1);return le.add(xe),xe.add(new go.PathSegment(go.PathSegment.Bezier,2*he,.5*te,he+$e*he,0,2*he,(.5-pe)*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,he,te,2*he,(.5+pe)*te,he+$e*he,te)),le.spot1=new go.Spot(0,0,2*he,0),le.spot2=new go.Spot(1,1),le}),go.Shape.defineFigureGenerator("Cylinder4",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=5),he=Math.min(he,ne/3);var le=new go.Geometry,pe=$e*.5,me=new go.PathFigure(ne-he,0,!0);le.add(me),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,ne-$e*he,0,ne,(.5-pe)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne-he,te,ne,(.5+pe)*te,ne-$e*he,te)),me.add(new go.PathSegment(go.PathSegment.Line,he,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*te,$e*he,te,0,(.5+pe)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,he,0,0,(.5-pe)*te,$e*he,0)),me.add(new go.PathSegment(go.PathSegment.Line,ne-he,0));var xe=new go.PathFigure(ne-he,0,!1);return le.add(xe),xe.add(new go.PathSegment(go.PathSegment.Bezier,ne-2*he,.5*te,ne-he-$e*he,0,ne-2*he,(.5-pe)*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,ne-he,te,ne-2*he,(.5+pe)*te,ne-he-$e*he,te)),le.spot1=new go.Spot(0,0),le.spot2=new go.Spot(1,1,-2*he,0),le}),go.Shape.defineFigureGenerator("Prism1",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.25*ne,.25*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var pe=new go.PathFigure(.25*ne,.25*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),he.spot1=new go.Spot(.408,.172),he.spot2=new go.Spot(.833,.662),he}),go.Shape.defineFigureGenerator("Prism2",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.25*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.25*te)),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,.75*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var pe=new go.PathFigure(0,te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.25*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.25*te)),pe.add(new go.PathSegment(go.PathSegment.Move,0,.25*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.25*ne,.5*te)),he.spot1=new go.Spot(.25,.5),he.spot2=new go.Spot(.75,.75),he}),go.Shape.defineFigureGenerator("Pyramid1",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.75*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.75*te).close());var pe=new go.PathFigure(.5*ne,0,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),he.spot1=new go.Spot(.25,.367),he.spot2=new go.Spot(.75,.875),he}),go.Shape.defineFigureGenerator("Pyramid2",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.85*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.85*te).close());var pe=new go.PathFigure(.5*ne,0,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.7*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,.85*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.7*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.85*te)),he.spot1=new go.Spot(.25,.367),he.spot2=new go.Spot(.75,.875),he}),go.Shape.defineFigureGenerator("Actor",function(Re,ne,te){var he=new go.Geometry,le=.2,pe=.1,me=$e*le,xe=$e*pe,Ee=.5,Ge=.1,et=new go.PathFigure(Ee*ne,(Ge+pe)*te,!0);he.add(et),et.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-le)*ne,Ge*te,(Ee-me)*ne,(Ge+pe)*te,(Ee-le)*ne,(Ge+xe)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge-pe)*te,(Ee-le)*ne,(Ge-xe)*te,(Ee-me)*ne,(Ge-pe)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+le)*ne,Ge*te,(Ee+me)*ne,(Ge-pe)*te,(Ee+le)*ne,(Ge-xe)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge+pe)*te,(Ee+le)*ne,(Ge+xe)*te,(Ee+me)*ne,(Ge+pe)*te));var ut=.05,st=$e*ut;Ee=.05,Ge=.25;var it=new go.PathFigure(.5*ne,.2*te,!0);return he.add(it),it.add(new go.PathSegment(go.PathSegment.Line,.95*ne,.2*te)),Ee=.95,Ge=.25,it.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+ut)*ne,Ge*te,(Ee+st)*ne,(Ge-ut)*te,(Ee+ut)*ne,(Ge-st)*te)),it.add(new go.PathSegment(go.PathSegment.Line,ne,.6*te)),it.add(new go.PathSegment(go.PathSegment.Line,.85*ne,.6*te)),it.add(new go.PathSegment(go.PathSegment.Line,.85*ne,.35*te)),ut=.025,st=$e*ut,Ee=.825,Ge=.35,it.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge-ut)*te,(Ee+ut)*ne,(Ge-st)*te,(Ee+st)*ne,(Ge-ut)*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-ut)*ne,Ge*te,(Ee-st)*ne,(Ge-ut)*te,(Ee-ut)*ne,(Ge-st)*te)),it.add(new go.PathSegment(go.PathSegment.Line,.8*ne,te)),it.add(new go.PathSegment(go.PathSegment.Line,.55*ne,te)),it.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.7*te)),ut=.05,st=$e*ut,Ee=.5,Ge=.7,it.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge-ut)*te,(Ee+ut)*ne,(Ge-st)*te,(Ee+st)*ne,(Ge-ut)*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-ut)*ne,Ge*te,(Ee-st)*ne,(Ge-ut)*te,(Ee-ut)*ne,(Ge-st)*te)),it.add(new go.PathSegment(go.PathSegment.Line,.45*ne,te)),it.add(new go.PathSegment(go.PathSegment.Line,.2*ne,te)),it.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.35*te)),ut=.025,st=$e*ut,Ee=.175,Ge=.35,it.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge-ut)*te,(Ee+ut)*ne,(Ge-st)*te,(Ee+st)*ne,(Ge-ut)*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-ut)*ne,Ge*te,(Ee-st)*ne,(Ge-ut)*te,(Ee-ut)*ne,(Ge-st)*te)),it.add(new go.PathSegment(go.PathSegment.Line,.15*ne,.6*te)),it.add(new go.PathSegment(go.PathSegment.Line,0,.6*te)),it.add(new go.PathSegment(go.PathSegment.Line,0,.25*te)),ut=.05,st=$e*ut,Ee=.05,Ge=.25,it.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge-ut)*te,(Ee-ut)*ne,(Ge-st)*te,(Ee-st)*ne,(Ge-ut)*te)),it.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.2*te)),he.spot1=new go.Spot(.2,.2),he.spot2=new go.Spot(.8,.65),he}),go.Shape.setFigureParameter("Card",0,new jn("CornerCutoutSize",.2,.1,.9)),go.Shape.defineFigureGenerator("Card",function(Re,ne,te){var he=Re?Re.parameter1:NaN;isNaN(he)&&(he=.2);var le=new go.Geometry,pe=new go.PathFigure(ne,0,!0);return le.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,he*te)),pe.add(new go.PathSegment(go.PathSegment.Line,he*ne,0).close()),le.spot1=new go.Spot(0,he),le.spot2=go.Spot.BottomRight,le}),go.Shape.defineFigureGenerator("Collate",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,.5*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te));var pe=new go.PathFigure(.5*ne,.5*te,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te)),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te)),he.spot1=new go.Spot(.25,0),he.spot2=new go.Spot(.75,.25),he}),go.Shape.defineFigureGenerator("CreateRequest",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)&&(le=.1);var pe=new go.PathFigure(0,0,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var me=new go.PathFigure(0,le*te,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,le*te)),me.add(new go.PathSegment(go.PathSegment.Move,0,(1-le)*te)),me.add(new go.PathSegment(go.PathSegment.Line,ne,(1-le)*te)),he}),go.Shape.defineFigureGenerator("Database",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=$e*.1,me=new go.PathFigure(ne,.1*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,.9*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te,ne,(.9+pe)*te,(.5+le)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,.9*te,(.5-le)*ne,te,0,(.9+pe)*te)),me.add(new go.PathSegment(go.PathSegment.Line,0,.1*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,0,0,(.1-pe)*te,(.5-le)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,.1*te,(.5+le)*ne,0,ne,(.1-pe)*te));var xe=new go.PathFigure(ne,.1*te,!1);return he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.2*te,ne,(.1+pe)*te,(.5+le)*ne,.2*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,0,.1*te,(.5-le)*ne,.2*te,0,(.1+pe)*te)),xe.add(new go.PathSegment(go.PathSegment.Move,ne,.2*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.3*te,ne,(.2+pe)*te,(.5+le)*ne,.3*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,0,.2*te,(.5-le)*ne,.3*te,0,(.2+pe)*te)),xe.add(new go.PathSegment(go.PathSegment.Move,ne,.3*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.4*te,ne,(.3+pe)*te,(.5+le)*ne,.4*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,0,.3*te,(.5-le)*ne,.4*te,0,(.3+pe)*te)),he.spot1=new go.Spot(0,.4),he.spot2=new go.Spot(1,.9),he}),go.Shape.defineFigureGenerator("DataStorage",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Bezier,.75*ne,te,ne,0,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,0,.25*ne,.9*te,.25*ne,.1*te).close()),he.spot1=new go.Spot(.226,0),he.spot2=new go.Spot(.81,1),he}),go.Shape.defineFigureGenerator("DiskStorage",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=$e*.1,me=new go.PathFigure(ne,.1*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,.9*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te,ne,(.9+pe)*te,(.5+le)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,.9*te,(.5-le)*ne,te,0,(.9+pe)*te)),me.add(new go.PathSegment(go.PathSegment.Line,0,.1*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,0,0,(.1-pe)*te,(.5-le)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,.1*te,(.5+le)*ne,0,ne,(.1-pe)*te));var xe=new go.PathFigure(ne,.1*te,!1);return he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.2*te,ne,(.1+pe)*te,(.5+le)*ne,.2*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,0,.1*te,(.5-le)*ne,.2*te,0,(.1+pe)*te)),xe.add(new go.PathSegment(go.PathSegment.Move,ne,.2*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.3*te,ne,(.2+pe)*te,(.5+le)*ne,.3*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,0,.2*te,(.5-le)*ne,.3*te,0,(.2+pe)*te)),he.spot1=new go.Spot(0,.3),he.spot2=new go.Spot(1,.9),he}),go.Shape.defineFigureGenerator("Display",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.25*ne,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Bezier,.75*ne,te,ne,0,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.25*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.5*te).close()),he.spot1=new go.Spot(.25,0),he.spot2=new go.Spot(.75,1),he}),go.Shape.defineFigureGenerator("DividedEvent",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)?le=.2:le<.15&&(le=.15);var pe=$e*.2,me=new go.PathFigure(0,.2*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Bezier,.2*ne,0,0,(.2-pe)*te,(.2-pe)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,.8*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,.2*te,(.8+pe)*ne,0,ne,(.2-pe)*te)),me.add(new go.PathSegment(go.PathSegment.Line,ne,.8*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,.8*ne,te,ne,(.8+pe)*te,(.8+pe)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,.2*ne,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,.8*te,(.2-pe)*ne,te,0,(.8+pe)*te)),me.add(new go.PathSegment(go.PathSegment.Line,0,.2*te));var xe=new go.PathFigure(0,le*te,!1);return he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne,le*te)),he}),go.Shape.defineFigureGenerator("DividedProcess",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;(isNaN(le)||le<.1)&&(le=.1);var pe=new go.PathFigure(0,0,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var me=new go.PathFigure(0,le*te,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,le*te)),he}),go.Shape.defineFigureGenerator("Document",function(Re,ne,te){var he=new go.Geometry;te=te/.8;var le=new go.PathFigure(0,.7*te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,.7*te,.5*ne,.4*te,.5*ne,te).close()),he.spot1=go.Spot.TopLeft,he.spot2=new go.Spot(1,.6),he}),go.Shape.defineFigureGenerator("ExternalOrganization",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;(isNaN(le)||le<.2)&&(le=.2);var pe=new go.PathFigure(0,0,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var me=new go.PathFigure(le*ne,0,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,0,le*te)),me.add(new go.PathSegment(go.PathSegment.Move,ne,le*te)),me.add(new go.PathSegment(go.PathSegment.Line,(1-le)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Move,0,(1-le)*te)),me.add(new go.PathSegment(go.PathSegment.Line,le*ne,te)),me.add(new go.PathSegment(go.PathSegment.Move,(1-le)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,ne,(1-le)*te)),he}),go.Shape.defineFigureGenerator("ExternalProcess",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.5*te).close());var pe=new go.PathFigure(.1*ne,.4*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.9*ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.6*ne,.1*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.1*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.4*ne,.9*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.9*te)),he.spot1=new go.Spot(.25,.25),he.spot2=new go.Spot(.75,.75),he}),go.Shape.defineFigureGenerator("File",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.25*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var pe=new go.PathFigure(.75*ne,0,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.75*ne,.25*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.25*te)),he.spot1=new go.Spot(0,.25),he.spot2=go.Spot.BottomRight,he}),go.Shape.defineFigureGenerator("Interrupt",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne,.5*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te));var pe=new go.PathFigure(ne,.5*te,!1);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te));var me=new go.PathFigure(ne,.5*te,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,0)),he.spot1=new go.Spot(0,.25),he.spot2=new go.Spot(.5,.75),he}),go.Shape.defineFigureGenerator("InternalStorage",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN,pe=Re?Re.parameter2:NaN;isNaN(le)&&(le=.1),isNaN(pe)&&(pe=.1);var me=new go.PathFigure(0,0,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var xe=new go.PathFigure(le*ne,0,!1);return he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,le*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Move,0,pe*te)),xe.add(new go.PathSegment(go.PathSegment.Line,ne,pe*te)),he}),go.Shape.defineFigureGenerator("Junction",function(Re,ne,te){var he=new go.Geometry,le=1/Math.SQRT2,pe=(1-1/Math.SQRT2)/2,me=$e*.5,xe=.5,Ee=new go.PathFigure(ne,xe*te,!0);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,xe*ne,te,ne,(xe+me)*te,(xe+me)*ne,te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,0,xe*te,(xe-me)*ne,te,0,(xe+me)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,xe*ne,0,0,(xe-me)*te,(xe-me)*ne,0)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,ne,xe*te,(xe+me)*ne,0,ne,(xe-me)*te));var Ge=new go.PathFigure((pe+le)*ne,(pe+le)*te,!1);return he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Line,pe*ne,pe*te)),Ge.add(new go.PathSegment(go.PathSegment.Move,pe*ne,(pe+le)*te)),Ge.add(new go.PathSegment(go.PathSegment.Line,(pe+le)*ne,pe*te)),he}),go.Shape.defineFigureGenerator("LinedDocument",function(Re,ne,te){var he=new go.Geometry;te=te/.8;var le=new go.PathFigure(0,.7*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,.7*te,.5*ne,.4*te,.5*ne,te).close());var pe=new go.PathFigure(.1*ne,0,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.75*te)),he.spot1=new go.Spot(.1,0),he.spot2=new go.Spot(1,.6),he}),go.Shape.defineFigureGenerator("LoopLimit",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,.25*te)),le.add(new go.PathSegment(go.PathSegment.Line,.25*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.25*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te).close()),he.spot1=new go.Spot(0,.25),he.spot2=go.Spot.BottomRight,he}),go.Shape.defineFigureGenerator("MagneticTape",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=.5,me=new go.PathFigure(.5*ne,te,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Bezier,0,pe*te,(pe-le)*ne,te,0,(pe+le)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,pe*ne,0,0,(pe-le)*te,(pe-le)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,pe*te,(pe+le)*ne,0,ne,(pe-le)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,(pe+.1)*ne,.9*te,ne,(pe+le)*te,(pe+le)*ne,.9*te)),me.add(new go.PathSegment(go.PathSegment.Line,ne,.9*te)),me.add(new go.PathSegment(go.PathSegment.Line,ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),he.spot1=new go.Spot(.15,.15),he.spot2=new go.Spot(.85,.8),he}),go.Shape.defineFigureGenerator("ManualInput",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.25*te).close()),he.spot1=new go.Spot(0,.25),he.spot2=go.Spot.BottomRight,he}),go.Shape.defineFigureGenerator("MessageFromUser",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)&&(le=.7);var pe=new go.PathFigure(0,0,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,le*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he.spot1=go.Spot.TopLeft,he}),go.Shape.defineFigureGenerator("MicroformProcessing",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)&&(le=.25);var pe=new go.PathFigure(0,0,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,le*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,(1-le)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he}),go.Shape.defineFigureGenerator("MicroformRecording",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,.25*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.15*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.85*te)),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,.75*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he.spot1=new go.Spot(0,.25),he.spot2=new go.Spot(1,.75),he}),go.Shape.defineFigureGenerator("MultiDocument",function(Re,ne,te){var he=new go.Geometry;te=te/.8;var le=new go.PathFigure(ne,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.9*ne,.44*te,.96*ne,.47*te,.93*ne,.45*te)),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.8*ne,.54*te,.86*ne,.57*te,.83*ne,.55*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,.7*te,.4*ne,.4*te,.4*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.1*te)),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.1*te)),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,0).close());var pe=new go.PathFigure(.1*ne,.2*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.2*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.54*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.1*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.1*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.44*te)),he.spot1=new go.Spot(0,.25),he.spot2=new go.Spot(.8,.77),he}),go.Shape.defineFigureGenerator("MultiProcess",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.1*ne,.1*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.1*te)),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.9*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.9*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.2*te).close());var pe=new go.PathFigure(.2*ne,.1*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.1*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.8*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.1*ne,.2*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.2*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.9*te)),he.spot1=new go.Spot(0,.2),he.spot2=new go.Spot(.8,1),he}),go.Shape.defineFigureGenerator("OfflineStorage",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)&&(le=.1);var pe=1-le,me=new go.PathFigure(0,0,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te).close());var xe=new go.PathFigure(.5*le*ne,le*te,!1);return he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,(1-.5*le)*ne,le*te)),he}),go.Shape.defineFigureGenerator("OffPageConnector",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he.spot1=go.Spot.TopLeft,he.spot2=new go.Spot(.75,1),he}),go.Shape.defineFigureGenerator("Or",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=.5,me=new go.PathFigure(ne,pe*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Bezier,pe*ne,te,ne,(pe+le)*te,(pe+le)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,pe*te,(pe-le)*ne,te,0,(pe+le)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,pe*ne,0,0,(pe-le)*te,(pe-le)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,pe*te,(pe+le)*ne,0,ne,(pe-le)*te));var xe=new go.PathFigure(ne,.5*te,!1);return he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,0,.5*te)),xe.add(new go.PathSegment(go.PathSegment.Move,.5*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),he}),go.Shape.defineFigureGenerator("PaperTape",function(Re,ne,te){var he=new go.Geometry;te=te/.8;var le=new go.PathFigure(0,.7*te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,.3*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,ne,.3*te,.5*ne,.6*te,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,.7*te,.5*ne,.4*te,.5*ne,te).close()),he.spot1=new go.Spot(0,.49),he.spot2=new go.Spot(1,.75),he}),go.Shape.defineFigureGenerator("PrimitiveFromCall",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN,pe=Re?Re.parameter2:NaN;isNaN(le)&&(le=.1),isNaN(pe)&&(pe=.3);var me=new go.PathFigure(0,0,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,(1-pe)*ne,.5*te)),me.add(new go.PathSegment(go.PathSegment.Line,ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he}),go.Shape.defineFigureGenerator("PrimitiveToCall",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN,pe=Re?Re.parameter2:NaN;isNaN(le)&&(le=.1),isNaN(pe)&&(pe=.3);var me=new go.PathFigure(0,0,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,(1-pe)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),me.add(new go.PathSegment(go.PathSegment.Line,(1-pe)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he}),go.Shape.defineFigureGenerator("Procedure",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)&&(le=.1);var pe=new go.PathFigure(0,0,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var me=new go.PathFigure((1-le)*ne,0,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,(1-le)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Move,le*ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,le*ne,te)),he}),go.Shape.defineFigureGenerator("Process",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)&&(le=.1);var pe=new go.PathFigure(0,0,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var me=new go.PathFigure(le*ne,0,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,le*ne,te)),he.spot2=go.Spot.BottomRight,he}),go.Shape.defineFigureGenerator("Sort",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.5*te).close());var pe=new go.PathFigure(0,.5*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),he.spot1=new go.Spot(.25,.25),he.spot2=new go.Spot(.75,.5),he}),go.Shape.defineFigureGenerator("Start",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)&&(le=.25);var pe=new go.PathFigure(le*ne,0,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Arc,270,180,.75*ne,.5*te,.25*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Arc,90,180,.25*ne,.5*te,.25*ne,.5*te));var me=new go.PathFigure(le*ne,0,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,le*ne,te)),me.add(new go.PathSegment(go.PathSegment.Move,(1-le)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,(1-le)*ne,te)),he.spot1=new go.Spot(le,0),he.spot2=new go.Spot(1-le,1),he}),go.Shape.defineFigureGenerator("Terminator",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.25*ne,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Arc,270,180,.75*ne,.5*te,.25*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Arc,90,180,.25*ne,.5*te,.25*ne,.5*te)),he.spot1=new go.Spot(.23,0),he.spot2=new go.Spot(.77,1),he}),go.Shape.defineFigureGenerator("TransmittalTape",function(Re,ne,te){var he=new go.Geometry,le=Re?Re.parameter1:NaN;isNaN(le)&&(le=.1);var pe=new go.PathFigure(0,0,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,.75*ne,(1-le)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,(1-le)*te).close()),he.spot1=go.Spot.TopLeft,he}),go.Shape.defineFigureGenerator("AndGate",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=new go.PathFigure(0,0,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),pe.add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,(.5+le)*ne,0,ne,(.5-le)*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te,ne,(.5+le)*te,(.5+le)*ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he.spot1=go.Spot.TopLeft,he.spot2=new go.Spot(.55,1),he}),go.Shape.defineFigureGenerator("Buffer",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he.spot1=new go.Spot(0,.25),he.spot2=new go.Spot(.5,.75),he}),go.Shape.defineFigureGenerator("Clock",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=.5,me=new go.PathFigure(ne,pe*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Bezier,pe*ne,te,ne,(pe+le)*te,(pe+le)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,pe*te,(pe-le)*ne,te,0,(pe+le)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,pe*ne,0,0,(pe-le)*te,(pe-le)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,pe*te,(pe+le)*ne,0,ne,(pe-le)*te));var xe=new go.PathFigure(ne,pe*te,!1);he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne,pe*te));var Ee=new go.PathFigure(.8*ne,.75*te,!1);return he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.25*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.25*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.75*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.75*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.25*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.25*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.75*te)),he}),go.Shape.defineFigureGenerator("Ground",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Move,.3*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.7*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Move,.4*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,te)),he}),go.Shape.defineFigureGenerator("Inverter",function(Re,ne,te){var he=new go.Geometry,le=$e*.1,pe=.1,me=.9,xe=.5,Ee=new go.PathFigure(.8*ne,.5*te,!0);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Line,0,te)),Ee.add(new go.PathSegment(go.PathSegment.Line,0,0)),Ee.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.5*te));var Ge=new go.PathFigure((me+pe)*ne,xe*te,!0);return he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,(me-pe)*ne,xe*te,(me-le)*ne,(xe+pe)*te,(me-pe)*ne,(xe+le)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,xe*te,(me+le)*ne,(xe-pe)*te,(me+pe)*ne,(xe-le)*te)),he.spot1=new go.Spot(0,.25),he.spot2=new go.Spot(.4,.75),he}),go.Shape.defineFigureGenerator("NandGate",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=$e*.4,me=$e*.1,xe=.1,Ee=.9,Ge=.5,et=new go.PathFigure(.8*ne,.5*te,!0);he.add(et),et.add(new go.PathSegment(go.PathSegment.Bezier,.4*ne,te,.8*ne,(.5+pe)*te,(.4+le)*ne,te)),et.add(new go.PathSegment(go.PathSegment.Line,0,te)),et.add(new go.PathSegment(go.PathSegment.Line,0,0)),et.add(new go.PathSegment(go.PathSegment.Line,.4*ne,0)),et.add(new go.PathSegment(go.PathSegment.Bezier,.8*ne,.5*te,(.4+le)*ne,0,.8*ne,(.5-pe)*te));var ut=new go.PathFigure((Ee+xe)*ne,Ge*te,!0);return he.add(ut),ut.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge+xe)*te,(Ee+xe)*ne,(Ge+me)*te,(Ee+me)*ne,(Ge+xe)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-xe)*ne,Ge*te,(Ee-me)*ne,(Ge+xe)*te,(Ee-xe)*ne,(Ge+me)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge-xe)*te,(Ee-xe)*ne,(Ge-me)*te,(Ee-me)*ne,(Ge-xe)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+xe)*ne,Ge*te,(Ee+me)*ne,(Ge-xe)*te,(Ee+xe)*ne,(Ge-me)*te)),he.spot1=new go.Spot(0,.05),he.spot2=new go.Spot(.55,.95),he}),go.Shape.defineFigureGenerator("NorGate",function(Re,ne,te){var he=new go.Geometry,le=.5,pe=$e*le,me=0,xe=.5,Ee=new go.PathFigure(.8*ne,.5*te,!0);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,0,te,.7*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,0,0,.25*ne,.75*te,.25*ne,.25*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,.8*ne,.5*te,(me+pe)*ne,(xe-le)*te,.7*ne,(xe-pe)*te)),le=.1,pe=$e*.1,me=.9,xe=.5;var Ge=new go.PathFigure((me-le)*ne,xe*te,!0);return he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,(me+le)*ne,xe*te,(me+pe)*ne,(xe-le)*te,(me+le)*ne,(xe-pe)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,(me-le)*ne,xe*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te)),he.spot1=new go.Spot(.2,.25),he.spot2=new go.Spot(.6,.75),he}),go.Shape.defineFigureGenerator("OrGate",function(Re,ne,te){var he=new go.Geometry,le=.5,pe=$e*le,me=0,xe=.5,Ee=new go.PathFigure(0,0,!0);return he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,(me+pe+pe)*ne,(xe-le)*te,.8*ne,(xe-pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,0,te,.8*ne,(xe+pe)*te,(me+pe+pe)*ne,(xe+le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,0,0,.25*ne,.75*te,.25*ne,.25*te).close()),he.spot1=new go.Spot(.2,.25),he.spot2=new go.Spot(.75,.75),he}),go.Shape.defineFigureGenerator("XnorGate",function(Re,ne,te){var he=new go.Geometry,le=.5,pe=$e*le,me=.2,xe=.5,Ee=new go.PathFigure(.1*ne,0,!1);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,.1*ne,te,.35*ne,.25*te,.35*ne,.75*te));var Ge=new go.PathFigure(.8*ne,.5*te,!0);he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Bezier,.2*ne,te,.7*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,.2*ne,0,.45*ne,.75*te,.45*ne,.25*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,.8*ne,.5*te,(me+pe)*ne,(xe-le)*te,.7*ne,(xe-pe)*te)),le=.1,pe=$e*.1,me=.9,xe=.5;var et=new go.PathFigure((me-le)*ne,xe*te,!0);return he.add(et),et.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,(me+le)*ne,xe*te,(me+pe)*ne,(xe-le)*te,(me+le)*ne,(xe-pe)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,(me-le)*ne,xe*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te)),he.spot1=new go.Spot(.4,.25),he.spot2=new go.Spot(.65,.75),he}),go.Shape.defineFigureGenerator("XorGate",function(Re,ne,te){var he=new go.Geometry,le=.5,pe=$e*le,me=.2,xe=.5,Ee=new go.PathFigure(.1*ne,0,!1);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,.1*ne,te,.35*ne,.25*te,.35*ne,.75*te));var Ge=new go.PathFigure(.2*ne,0,!0);return he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,(me+pe)*ne,(xe-le)*te,.9*ne,(xe-pe)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,.2*ne,te,.9*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,.2*ne,0,.45*ne,.75*te,.45*ne,.25*te).close()),he.spot1=new go.Spot(.4,.25),he.spot2=new go.Spot(.8,.75),he}),go.Shape.defineFigureGenerator("Capacitor",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Move,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),he}),go.Shape.defineFigureGenerator("Resistor",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.5*te,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.4*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.7*ne,.5*te)),he}),go.Shape.defineFigureGenerator("Inductor",function(Re,ne,te){var he=new go.Geometry,le=$e*.1,pe=.1,me=.1,xe=.5,Ee=new go.PathFigure((me-le*.5)*ne,te,!1);return he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,0,(me-le)*ne,te,(me-pe)*ne,0)),me=.3,Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,te,(me+pe)*ne,0,(me+le)*ne,te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,0,(me-le)*ne,te,(me-pe)*ne,0)),me=.5,Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,te,(me+pe)*ne,0,(me+le)*ne,te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,0,(me-le)*ne,te,(me-pe)*ne,0)),me=.7,Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,te,(me+pe)*ne,0,(me+le)*ne,te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,0,(me-le)*ne,te,(me-pe)*ne,0)),me=.9,Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+le*.5)*ne,te,(me+pe)*ne,0,(me+le)*ne,te)),he}),go.Shape.defineFigureGenerator("ACvoltageSource",function(Re,ne,te){var he=new go.Geometry,le=$e*.5,pe=.5,me=.5,xe=.5,Ee=new go.PathFigure((me-pe)*ne,xe*te,!1);return he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,xe*te,(me+le)*ne,(xe-pe)*te,(me+pe)*ne,(xe-le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me-pe)*ne,xe*te,(me-le)*ne,(xe+pe)*te,(me-pe)*ne,(xe+le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Move,(me-pe+.1)*ne,xe*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe-.1)*ne,xe*te,me*ne,(xe-pe)*te,me*ne,(xe+pe)*te)),he}),go.Shape.defineFigureGenerator("DCvoltageSource",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.75*te,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,.25*te)),le.add(new go.PathSegment(go.PathSegment.Move,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),he}),go.Shape.defineFigureGenerator("Diode",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne,0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),he.spot1=new go.Spot(0,.25),he.spot2=new go.Spot(.5,.75),he}),go.Shape.defineFigureGenerator("Wifi",function(Re,ne,te){var he=new go.Geometry,le=ne,pe=te;ne=ne*.38,te=te*.6;var me=$e*.8,xe=.8,Ee=0,Ge=.5,et=(le-ne)/2,ut=(pe-te)/2,st=new go.PathFigure(Ee*ne+et,(Ge+xe)*te+ut,!0);he.add(st),st.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-xe)*ne+et,Ge*te+ut,(Ee-me)*ne+et,(Ge+xe)*te+ut,(Ee-xe)*ne+et,(Ge+me)*te+ut)),st.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge-xe)*te+ut,(Ee-xe)*ne+et,(Ge-me)*te+ut,(Ee-me)*ne+et,(Ge-xe)*te+ut)),st.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-xe+me*.5)*ne+et,Ge*te+ut,Ee*ne+et,(Ge-xe)*te+ut,(Ee-xe+me*.5)*ne+et,(Ge-me)*te+ut)),st.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge+xe)*te+ut,(Ee-xe+me*.5)*ne+et,(Ge+me)*te+ut,Ee*ne+et,(Ge+xe)*te+ut).close()),me=$e*.4,xe=.4,Ee=.2,Ge=.5;var it=new go.PathFigure(Ee*ne+et,(Ge+xe)*te+ut,!0);he.add(it),it.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-xe)*ne+et,Ge*te+ut,(Ee-me)*ne+et,(Ge+xe)*te+ut,(Ee-xe)*ne+et,(Ge+me)*te+ut)),it.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge-xe)*te+ut,(Ee-xe)*ne+et,(Ge-me)*te+ut,(Ee-me)*ne+et,(Ge-xe)*te+ut)),it.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-xe+me*.5)*ne+et,Ge*te+ut,Ee*ne+et,(Ge-xe)*te+ut,(Ee-xe+me*.5)*ne+et,(Ge-me)*te+ut)),it.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge+xe)*te+ut,(Ee-xe+me*.5)*ne+et,(Ge+me)*te+ut,Ee*ne+et,(Ge+xe)*te+ut).close()),me=$e*.2,xe=.2,Ee=.5,Ge=.5;var Nt=new go.PathFigure((Ee-xe)*ne+et,Ge*te+ut,!0);he.add(Nt),Nt.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge-xe)*te+ut,(Ee-xe)*ne+et,(Ge-me)*te+ut,(Ee-me)*ne+et,(Ge-xe)*te+ut)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+xe)*ne+et,Ge*te+ut,(Ee+me)*ne+et,(Ge-xe)*te+ut,(Ee+xe)*ne+et,(Ge-me)*te+ut)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge+xe)*te+ut,(Ee+xe)*ne+et,(Ge+me)*te+ut,(Ee+me)*ne+et,(Ge+xe)*te+ut)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-xe)*ne+et,Ge*te+ut,(Ee-me)*ne+et,(Ge+xe)*te+ut,(Ee-xe)*ne+et,(Ge+me)*te+ut)),me=$e*.4,xe=.4,Ee=.8,Ge=.5;var St=new go.PathFigure(Ee*ne+et,(Ge-xe)*te+ut,!0);he.add(St),St.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+xe)*ne+et,Ge*te+ut,(Ee+me)*ne+et,(Ge-xe)*te+ut,(Ee+xe)*ne+et,(Ge-me)*te+ut)),St.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge+xe)*te+ut,(Ee+xe)*ne+et,(Ge+me)*te+ut,(Ee+me)*ne+et,(Ge+xe)*te+ut)),St.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+xe-me*.5)*ne+et,Ge*te+ut,Ee*ne+et,(Ge+xe)*te+ut,(Ee+xe-me*.5)*ne+et,(Ge+me)*te+ut)),St.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge-xe)*te+ut,(Ee+xe-me*.5)*ne+et,(Ge-me)*te+ut,Ee*ne+et,(Ge-xe)*te+ut).close()),me=$e*.8,xe=.8,Ee=1,Ge=.5;var Ft=new go.PathFigure(Ee*ne+et,(Ge-xe)*te+ut,!0);return he.add(Ft),Ft.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+xe)*ne+et,Ge*te+ut,(Ee+me)*ne+et,(Ge-xe)*te+ut,(Ee+xe)*ne+et,(Ge-me)*te+ut)),Ft.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge+xe)*te+ut,(Ee+xe)*ne+et,(Ge+me)*te+ut,(Ee+me)*ne+et,(Ge+xe)*te+ut)),Ft.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+xe-me*.5)*ne+et,Ge*te+ut,Ee*ne+et,(Ge+xe)*te+ut,(Ee+xe-me*.5)*ne+et,(Ge+me)*te+ut)),Ft.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne+et,(Ge-xe)*te+ut,(Ee+xe-me*.5)*ne+et,(Ge-me)*te+ut,Ee*ne+et,(Ge-xe)*te+ut).close()),he}),go.Shape.defineFigureGenerator("Email",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,0).close());var pe=new go.PathFigure(0,0,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,0)),pe.add(new go.PathSegment(go.PathSegment.Move,0,te)),pe.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.54*te)),pe.add(new go.PathSegment(go.PathSegment.Move,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.54*te)),he}),go.Shape.defineFigureGenerator("Ethernet",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.35*ne,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.65*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.65*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,.35*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,.35*ne,0).close());var pe=new go.PathFigure(.1*ne,te,!0,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.4*ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.1*ne,te).close());var me=new go.PathFigure(.6*ne,te,!0,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.9*ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.6*te)),me.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.6*te)),me.add(new go.PathSegment(go.PathSegment.Line,.6*ne,te).close());var xe=new go.PathFigure(0,.5*te,!1);return he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),xe.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.5*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.4*te)),xe.add(new go.PathSegment(go.PathSegment.Move,.75*ne,.5*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.75*ne,.6*te)),xe.add(new go.PathSegment(go.PathSegment.Move,.25*ne,.5*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.25*ne,.6*te)),he}),go.Shape.defineFigureGenerator("Power",function(Re,ne,te){var he=new go.Geometry,le=$e*.4,pe=.4,me=.5,xe=.5,Ee=Ne(),Ge=Ne(),et=Ne(),ut=Ne();$t(me,xe-pe,me+le,xe-pe,me+pe,xe-le,me+pe,xe,.5,Ee,Ee,Ge,et,ut);var st=De(Ge.x,Ge.y),it=new go.PathFigure(Ge.x*ne,Ge.y*te,!0);he.add(it),it.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,xe*te,et.x*ne,et.y*te,ut.x*ne,ut.y*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,(me-pe)*ne,xe*te,(me-le)*ne,(xe+pe)*te,(me-pe)*ne,(xe+le)*te)),$t(me-pe,xe,me-pe,xe-le,me-le,xe-pe,me,xe-pe,.5,et,ut,Ge,Ee,Ee),it.add(new go.PathSegment(go.PathSegment.Bezier,Ge.x*ne,Ge.y*te,et.x*ne,et.y*te,ut.x*ne,ut.y*te)),le=$e*.3,pe=.3,$t(me-pe,xe,me-pe,xe-le,me-le,xe-pe,me,xe-pe,.5,et,ut,Ge,Ee,Ee),it.add(new go.PathSegment(go.PathSegment.Line,Ge.x*ne,Ge.y*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,(me-pe)*ne,xe*te,ut.x*ne,ut.y*te,et.x*ne,et.y*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+pe)*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,(me+pe)*ne,xe*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),$t(me,xe-pe,me+le,xe-pe,me+pe,xe-le,me+pe,xe,.5,Ee,Ee,Ge,et,ut),it.add(new go.PathSegment(go.PathSegment.Bezier,Ge.x*ne,Ge.y*te,ut.x*ne,ut.y*te,et.x*ne,et.y*te).close());var it=new go.PathFigure(.45*ne,0,!0);return he.add(it),it.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.5*te)),it.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.5*te)),it.add(new go.PathSegment(go.PathSegment.Line,.55*ne,0).close()),dt(Ee),dt(Ge),dt(et),dt(ut),dt(st),he.spot1=new go.Spot(.25,.45),he.spot2=new go.Spot(.75,.8),he}),go.Shape.defineFigureGenerator("Fallout",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te/2,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Arc,180,360,ne/2,te/2,ne/2,te/2));function pe(me,xe,Ee){me.add(new go.PathSegment(go.PathSegment.Move,(.3+xe)*ne,(.8+Ee)*te)),me.add(new go.PathSegment(go.PathSegment.Line,(.5+xe)*ne,(.5+Ee)*te)),me.add(new go.PathSegment(go.PathSegment.Line,(.1+xe)*ne,(.5+Ee)*te)),me.add(new go.PathSegment(go.PathSegment.Line,(.3+xe)*ne,(.8+Ee)*te).close())}return pe(le,0,0),pe(le,.4,0),pe(le,.2,-.3),he}),go.Shape.defineFigureGenerator("IrritationHazard",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.2*ne,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.3*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,.7*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.2*te).close()),he.spot1=new go.Spot(.3,.3),he.spot2=new go.Spot(.7,.7),he}),go.Shape.defineFigureGenerator("ElectricalHazard",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.37*ne,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.11*te)),le.add(new go.PathSegment(go.PathSegment.Line,.77*ne,.04*te)),le.add(new go.PathSegment(go.PathSegment.Line,.33*ne,.49*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.37*te)),le.add(new go.PathSegment(go.PathSegment.Line,.63*ne,.86*te)),le.add(new go.PathSegment(go.PathSegment.Line,.77*ne,.91*te)),le.add(new go.PathSegment(go.PathSegment.Line,.34*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.34*ne,.78*te)),le.add(new go.PathSegment(go.PathSegment.Line,.44*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.65*ne,.56*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.68*te).close()),he}),go.Shape.defineFigureGenerator("FireHazard",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.1*ne,te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Bezier,.29*ne,0,-.25*ne,.63*te,.45*ne,.44*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.51*ne,.42*te,.48*ne,.17*te,.54*ne,.35*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.59*ne,.18*te,.59*ne,.29*te,.58*ne,.28*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.75*ne,.6*te,.8*ne,.34*te,.88*ne,.43*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.88*ne,.31*te,.87*ne,.48*te,.88*ne,.43*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.9*ne,te,1.17*ne,.76*te,.82*ne,.8*te).close()),he.spot1=new go.Spot(.07,.445),he.spot2=new go.Spot(.884,.958),he}),go.Shape.defineFigureGenerator("BpmnActivityLoop",function(Re,ne,te){var he=new go.Geometry,le=.5,pe=0,me=0,xe=le*$e,Ee=.4*Math.SQRT2/2+.5,Ge=.5-.5*Math.SQRT2/2,et=1,ut=.5,st=.5,it=0,Nt=new go.PathFigure(Ee*ne,(1-Ge)*te,!1);return he.add(Nt),Nt.add(new go.PathSegment(go.PathSegment.Bezier,et*ne,ut*te,et*ne,.7*te,et*ne,ut*te)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,(st+pe)*ne,(it+pe)*te,(.5+le+pe)*ne,(.5-xe+pe)*te,(.5+xe+pe)*ne,(.5-le+pe)*te)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,(.5-le+pe)*ne,(.5+me)*te,(.5-xe+pe)*ne,(.5-le+me)*te,(.5-le+pe)*ne,(.5-xe+me)*te)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,(.35+pe)*ne,.9*te,(.5-le+pe)*ne,(.5+xe+me)*te,(.5-xe+pe)*ne,.9*te)),Nt.add(new go.PathSegment(go.PathSegment.Move,(.25+pe)*ne,.8*te)),Nt.add(new go.PathSegment(go.PathSegment.Line,(.35+pe)*ne,.9*te)),Nt.add(new go.PathSegment(go.PathSegment.Line,(.2+pe)*ne,.95*te)),he}),go.Shape.defineFigureGenerator("BpmnActivityParallel",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Move,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Move,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),he}),go.Shape.defineFigureGenerator("BpmnActivitySequential",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Move,0,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Move,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),he}),go.Shape.defineFigureGenerator("BpmnActivityAdHoc",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!1);he.add(le);var pe=new go.PathFigure(ne,te,!1);he.add(pe);var me=new go.PathFigure(0,.5*te,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.5*te,.2*ne,.35*te,.3*ne,.35*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,.7*ne,.65*te,.8*ne,.65*te)),he}),go.Shape.defineFigureGenerator("BpmnActivityCompensation",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.5*te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te).close()),he}),go.Shape.defineFigureGenerator("BpmnTaskMessage",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.2*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.8*te).close());var le=new go.PathFigure(0,.2*te,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.2*te)),he}),go.Shape.defineFigureGenerator("BpmnTaskScript",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.7*ne,te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.3*ne,0,.6*ne,.5*te,0,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.7*ne,0)),le.add(new go.PathSegment(go.PathSegment.Bezier,.7*ne,te,.4*ne,.5*te,ne,.5*te).close());var pe=new go.PathFigure(.45*ne,.73*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.7*ne,.73*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.38*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.63*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.31*ne,.27*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.56*ne,.27*te)),he}),go.Shape.defineFigureGenerator("BpmnTaskUser",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!1);he.add(le);var pe=new go.PathFigure(.335*ne,(1-.555)*te,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.335*ne,(1-.405)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(1-.335)*ne,(1-.405)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(1-.335)*ne,(1-.555)*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,ne,.68*te,(1-.12)*ne,.46*te,(1-.02)*ne,.54*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,.68*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,.335*ne,(1-.555)*te,.02*ne,.54*te,.12*ne,.46*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.365*ne,(1-.595)*te));var me=.5-.285,xe=.5,Ee=me,Ge=Math.PI/4,et=4*(1-Math.cos(Ge))/(3*Math.sin(Ge)),ut=et*.5,st=me,it=me,Nt=et*st,St=et*it;pe.add(new go.PathSegment(go.PathSegment.Bezier,(xe-st)*ne,Ee*te,(xe-(Nt+st)/2)*ne,(Ee+(it+St)/2)*te,(xe-st)*ne,(Ee+St)*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,xe*ne,(Ee-it)*te,(xe-st)*ne,(Ee-St)*te,(xe-Nt)*ne,(Ee-it)*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,(xe+st)*ne,Ee*te,(xe+Nt)*ne,(Ee-it)*te,(xe+st)*ne,(Ee-St)*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,(1-.365)*ne,(1-.595)*te,(xe+st)*ne,(Ee+St)*te,(xe+(Nt+st)/2)*ne,(Ee+(it+St)/2)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(1-.365)*ne,(1-.595)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(1-.335)*ne,(1-.555)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,(1-.335)*ne,(1-.405)*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.335*ne,(1-.405)*te));var Ft=new go.PathFigure(.2*ne,te,!1);he.add(Ft),Ft.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.8*te));var cn=new go.PathFigure(.8*ne,te,!1);return he.add(cn),cn.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.8*te)),he}),go.Shape.defineFigureGenerator("BpmnEventConditional",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.1*ne,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,te).close());var pe=new go.PathFigure(.2*ne,.2*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.2*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.8*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.8*te)),he}),go.Shape.defineFigureGenerator("BpmnEventError",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.33*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.66*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.66*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.33*ne,.5*te).close()),he}),go.Shape.defineFigureGenerator("BpmnEventEscalation",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!1);he.add(le);var pe=new go.PathFigure(ne,te,!1);he.add(pe);var me=new go.PathFigure(.1*ne,te,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),me.add(new go.PathSegment(go.PathSegment.Line,.9*ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te).close()),he}),go.Shape.defineFigureGenerator("Caution",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.05*ne,te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Bezier,.1*ne,.8*te,0,te,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.1*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.55*ne,.1*te,.5*ne,0,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.95*ne,.9*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.9*ne,te,ne,te,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.05*ne,te));var pe=.05;return le.add(new go.PathSegment(go.PathSegment.Move,(.5-pe)*ne,.875*te)),le.add(new go.PathSegment(go.PathSegment.Arc,180,-360,.5*ne,.875*te,pe*ne,pe*te)),le.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.75*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.325*te,.575*ne,.725*te,.625*ne,.375*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.75*te,.375*ne,.375*te,.425*ne,.725*te)),he}),go.Shape.defineFigureGenerator("Recycle",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.45*ne,.95*te,!1);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.95*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.185*ne,.85*te,.17*ne,.95*te,.15*ne,.9*te)),le.add(new go.PathSegment(go.PathSegment.Line,.235*ne,.75*te)),le.add(new go.PathSegment(go.PathSegment.Line,.3*ne,.625*te)),le.add(new go.PathSegment(go.PathSegment.Line,.35*ne,.65*te)),le.add(new go.PathSegment(go.PathSegment.Line,.275*ne,.45*te)),le.add(new go.PathSegment(go.PathSegment.Line,.05*ne,.45*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.05*ne,.575*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.1875*ne,.95*te,0,.675*te,0,.7*te)),le.add(new go.PathSegment(go.PathSegment.Move,.45*ne,.95*te)),le.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.775*te)),le.add(new go.PathSegment(go.PathSegment.Line,.22*ne,.775*te));var pe=new go.PathFigure(.475*ne,.2*te,!1);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.225*ne,.3*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.275*ne,.175*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.325*ne,.05*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,.4*ne,.05*te,.35*ne,0,.375*ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,.575*ne,.375*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.525*ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.75*ne,.475*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.85*ne,.315*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.32*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.65*ne,.05*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,.575*ne,0,.65*ne,.05*te,.625*ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,.38*ne,.0105*te));var me=new go.PathFigure(.675*ne,.575*te,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.875*ne,.525*te)),me.add(new go.PathSegment(go.PathSegment.Line,ne,.775*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,.85*ne,.95*te,ne,.8*te,ne,.85*te)),me.add(new go.PathSegment(go.PathSegment.Line,.65*ne,.95*te)),me.add(new go.PathSegment(go.PathSegment.Line,.65*ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.85*te)),me.add(new go.PathSegment(go.PathSegment.Line,.65*ne,.725*te)),me.add(new go.PathSegment(go.PathSegment.Line,.65*ne,.775*te)),me.add(new go.PathSegment(go.PathSegment.Line,.7*ne,.775*te)),me.add(new go.PathSegment(go.PathSegment.Line,ne,.775*te)),me.add(new go.PathSegment(go.PathSegment.Move,.675*ne,.575*te)),me.add(new go.PathSegment(go.PathSegment.Line,.775*ne,.775*te)),he}),go.Shape.defineFigureGenerator("BpmnEventTimer",function(Re,ne,te){var he=new go.Geometry,le=.5,pe=$e*.5,me=new go.PathFigure(ne,le*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Bezier,le*ne,te,ne,(le+pe)*te,(le+pe)*ne,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,le*te,(le-pe)*ne,te,0,(le+pe)*te)),me.add(new go.PathSegment(go.PathSegment.Bezier,le*ne,0,0,(le-pe)*te,(le-pe)*ne,0)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne,le*te,(le+pe)*ne,0,ne,(le-pe)*te));var xe=new go.PathFigure(le*ne,0,!1);return he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,le*ne,.15*te)),xe.add(new go.PathSegment(go.PathSegment.Move,le*ne,te)),xe.add(new go.PathSegment(go.PathSegment.Line,le*ne,.85*te)),xe.add(new go.PathSegment(go.PathSegment.Move,0,le*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.15*ne,le*te)),xe.add(new go.PathSegment(go.PathSegment.Move,ne,le*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.85*ne,le*te)),xe.add(new go.PathSegment(go.PathSegment.Move,le*ne,le*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.58*ne,.1*te)),xe.add(new go.PathSegment(go.PathSegment.Move,le*ne,le*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.78*ne,.54*te)),he}),go.Shape.defineFigureGenerator("Package",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.15*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,.15*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close());var pe=new go.PathFigure(0,.15*te,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,0,0)),pe.add(new go.PathSegment(go.PathSegment.Line,.6*ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,.65*ne,.15*te).close()),he.spot1=new go.Spot(0,.1),he.spot2=new go.Spot(1,1),he}),go.Shape.defineFigureGenerator("Class",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,0).close());var pe=new go.PathFigure(0,.2*te,!1);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.2*te).close());var me=new go.PathFigure(0,.5*te,!1);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te).close()),he}),go.Shape.defineFigureGenerator("Component",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne,te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.15*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.15*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te).close());var pe=new go.PathFigure(0,.2*te,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.2*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,.2*te).close());var me=new go.PathFigure(0,.6*te,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.6*te)),me.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.8*te)),me.add(new go.PathSegment(go.PathSegment.Line,0,.8*te)),me.add(new go.PathSegment(go.PathSegment.Line,0,.6*te).close()),he}),go.Shape.defineFigureGenerator("Boat Shipment",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.15*ne,.6*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.15*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,.15*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.85*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,.85*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.15*ne,.6*te));var pe=new go.PathFigure(.15*ne,.6*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.85*ne,.6*te)),he}),go.Shape.defineFigureGenerator("Customer/Supplier",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne,te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.66*ne,.33*te)),le.add(new go.PathSegment(go.PathSegment.Line,.66*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.33*ne,.33*te)),le.add(new go.PathSegment(go.PathSegment.Line,.33*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,0,.33*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te).close()),he}),go.Shape.defineFigureGenerator("Workcell",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.65*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.65*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,.35*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,.35*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),he}),go.Shape.defineFigureGenerator("Supermarket",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.33*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.33*te)),le.add(new go.PathSegment(go.PathSegment.Move,ne,.33*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.66*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.66*te)),le.add(new go.PathSegment(go.PathSegment.Move,ne,.66*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),he}),go.Shape.defineFigureGenerator("TruckShipment",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,0).close());var pe=new go.PathFigure(ne,.8*te,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.8*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.8*te).close());var me=.1,xe=$e*.1,Ee=.2,Ge=.9,et=new go.PathFigure((Ee-me)*ne,Ge*te,!0);he.add(et),et.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge-me)*te,(Ee-me)*ne,(Ge-xe)*te,(Ee-xe)*ne,(Ge-me)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+me)*ne,Ge*te,(Ee+xe)*ne,(Ge-me)*te,(Ee+me)*ne,(Ge-xe)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge+me)*te,(Ee+me)*ne,(Ge+xe)*te,(Ee+xe)*ne,(Ge+me)*te)),et.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-me)*ne,Ge*te,(Ee-xe)*ne,(Ge+me)*te,(Ee-me)*ne,(Ge+xe)*te).close()),me=.1,xe=$e*.1,Ee=.8,Ge=.9;var ut=new go.PathFigure((Ee-me)*ne,Ge*te,!0);return he.add(ut),ut.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge-me)*te,(Ee-me)*ne,(Ge-xe)*te,(Ee-xe)*ne,(Ge-me)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,(Ee+me)*ne,Ge*te,(Ee+xe)*ne,(Ge-me)*te,(Ee+me)*ne,(Ge-xe)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,Ee*ne,(Ge+me)*te,(Ee+me)*ne,(Ge+xe)*te,(Ee+xe)*ne,(Ge+me)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,(Ee-me)*ne,Ge*te,(Ee-xe)*ne,(Ge+me)*te,(Ee-me)*ne,(Ge+xe)*te).close()),he}),go.Shape.defineFigureGenerator("KanbanPost",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.2*ne,0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,0)),le.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,te)),le.add(new go.PathSegment(go.PathSegment.Move,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,te)),he}),go.Shape.defineFigureGenerator("Forklift",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,.4*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,0,0));var pe=new go.PathFigure(0,.5*te,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,0,.8*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.8*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,0,.5*te));var me=new go.PathFigure(.5*ne,.8*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.1*te)),me.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.1*te)),me.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.8*te)),me.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.8*te));var xe=new go.PathFigure(.5*ne,.7*te,!1);he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne,.7*te));var Ee=.1,Ge=$e*.1,et=.1,ut=.9,st=new go.PathFigure((et-Ee)*ne,ut*te,!0);he.add(st),st.add(new go.PathSegment(go.PathSegment.Bezier,et*ne,(ut-Ee)*te,(et-Ee)*ne,(ut-Ge)*te,(et-Ge)*ne,(ut-Ee)*te)),st.add(new go.PathSegment(go.PathSegment.Bezier,(et+Ee)*ne,ut*te,(et+Ge)*ne,(ut-Ee)*te,(et+Ee)*ne,(ut-Ge)*te)),st.add(new go.PathSegment(go.PathSegment.Bezier,et*ne,(ut+Ee)*te,(et+Ee)*ne,(ut+Ge)*te,(et+Ge)*ne,(ut+Ee)*te)),st.add(new go.PathSegment(go.PathSegment.Bezier,(et-Ee)*ne,ut*te,(et-Ge)*ne,(ut+Ee)*te,(et-Ee)*ne,(ut+Ge)*te)),Ee=.1,Ge=$e*.1,et=.4,ut=.9;var it=new go.PathFigure((et-Ee)*ne,ut*te,!0);return he.add(it),it.add(new go.PathSegment(go.PathSegment.Bezier,et*ne,(ut-Ee)*te,(et-Ee)*ne,(ut-Ge)*te,(et-Ge)*ne,(ut-Ee)*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,(et+Ee)*ne,ut*te,(et+Ge)*ne,(ut-Ee)*te,(et+Ee)*ne,(ut-Ge)*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,et*ne,(ut+Ee)*te,(et+Ee)*ne,(ut+Ge)*te,(et+Ge)*ne,(ut+Ee)*te)),it.add(new go.PathSegment(go.PathSegment.Bezier,(et-Ee)*ne,ut*te,(et-Ge)*ne,(ut+Ee)*te,(et-Ee)*ne,(ut+Ge)*te)),he}),go.Shape.defineFigureGenerator("RailShipment",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.1*ne,.4*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,.45*ne,.9*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.9*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.4*te).close());var pe=new go.PathFigure(.45*ne,.7*te,!1);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.7*te));var me=new go.PathFigure(.55*ne,.4*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.4*te)),me.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.9*te)),me.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.9*te)),me.add(new go.PathSegment(go.PathSegment.Line,.55*ne,.4*te).close());var et=.05,ut=$e*.05,st=.175,it=.95,xe=new go.PathFigure((st-et)*ne,it*te,!0);he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Bezier,st*ne,(it-et)*te,(st-et)*ne,(it-ut)*te,(st-ut)*ne,(it-et)*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,(st+et)*ne,it*te,(st+ut)*ne,(it-et)*te,(st+et)*ne,(it-ut)*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,st*ne,(it+et)*te,(st+et)*ne,(it+ut)*te,(st+ut)*ne,(it+et)*te)),xe.add(new go.PathSegment(go.PathSegment.Bezier,(st-et)*ne,it*te,(st-ut)*ne,(it+et)*te,(st-et)*ne,(it+ut)*te));var et=.05,ut=$e*.05,st=.375,it=.95,Ee=new go.PathFigure((st-et)*ne,it*te,!0);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,st*ne,(it-et)*te,(st-et)*ne,(it-ut)*te,(st-ut)*ne,(it-et)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(st+et)*ne,it*te,(st+ut)*ne,(it-et)*te,(st+et)*ne,(it-ut)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,st*ne,(it+et)*te,(st+et)*ne,(it+ut)*te,(st+ut)*ne,(it+et)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(st-et)*ne,it*te,(st-ut)*ne,(it+et)*te,(st-et)*ne,(it+ut)*te));var et=.05,ut=$e*.05,st=.625,it=.95,Ge=new go.PathFigure((st-et)*ne,it*te,!0);he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Bezier,st*ne,(it-et)*te,(st-et)*ne,(it-ut)*te,(st-ut)*ne,(it-et)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,(st+et)*ne,it*te,(st+ut)*ne,(it-et)*te,(st+et)*ne,(it-ut)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,st*ne,(it+et)*te,(st+et)*ne,(it+ut)*te,(st+ut)*ne,(it+et)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,(st-et)*ne,it*te,(st-ut)*ne,(it+et)*te,(st-et)*ne,(it+ut)*te));var et=.05,ut=$e*.05,st=.825,it=.95,Nt=new go.PathFigure((st-et)*ne,it*te,!0);he.add(Nt),Nt.add(new go.PathSegment(go.PathSegment.Bezier,st*ne,(it-et)*te,(st-et)*ne,(it-ut)*te,(st-ut)*ne,(it-et)*te)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,(st+et)*ne,it*te,(st+ut)*ne,(it-et)*te,(st+et)*ne,(it-ut)*te)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,st*ne,(it+et)*te,(st+et)*ne,(it+ut)*te,(st+ut)*ne,(it+et)*te)),Nt.add(new go.PathSegment(go.PathSegment.Bezier,(st-et)*ne,it*te,(st-ut)*ne,(it+et)*te,(st-et)*ne,(it+ut)*te).close());var St=new go.PathFigure(0,te,!1);return he.add(St),St.add(new go.PathSegment(go.PathSegment.Line,ne,te).close()),he}),go.Shape.defineFigureGenerator("Warehouse",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,0).close());var pe=new go.PathFigure(0,.2*te,!1);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.2*te).close());var me=new go.PathFigure(.15*ne,te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.15*ne,.5*te)),me.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.5*te)),me.add(new go.PathSegment(go.PathSegment.Line,.4*ne,te)),me.add(new go.PathSegment(go.PathSegment.Line,.15*ne,te).close());var xe=.05,Ee=$e*.05,Ge=.35,et=.775,ut=new go.PathFigure((Ge-xe)*ne,et*te,!0);return he.add(ut),ut.add(new go.PathSegment(go.PathSegment.Bezier,Ge*ne,(et-xe)*te,(Ge-xe)*ne,(et-Ee)*te,(Ge-Ee)*ne,(et-xe)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,(Ge+xe)*ne,et*te,(Ge+Ee)*ne,(et-xe)*te,(Ge+xe)*ne,(et-Ee)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,Ge*ne,(et+xe)*te,(Ge+xe)*ne,(et+Ee)*te,(Ge+Ee)*ne,(et+xe)*te)),ut.add(new go.PathSegment(go.PathSegment.Bezier,(Ge-xe)*ne,et*te,(Ge-Ee)*ne,(et+xe)*te,(Ge-xe)*ne,(et+Ee)*te).close()),he}),go.Shape.defineFigureGenerator("ControlCenter",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Move,.1*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.8*te).close()),he}),go.Shape.defineFigureGenerator("Bluetooth",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.75*te,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,.75*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.25*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.75*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.25*te)),he}),go.Shape.defineFigureGenerator("Bookmark",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,0,0)),le.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.4*te)),he}),go.Shape.defineFigureGenerator("Bookmark",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,0,0)),le.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.4*te)),he}),go.Shape.defineFigureGenerator("Globe",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Move,0,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Move,.5*ne,0)),le.add(new go.PathSegment(go.PathSegment.Bezier,ne,.5*te,.75*ne,0,ne,.25*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te,ne,.75*te,.75*ne,te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*te,.25*ne,te,0,.75*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,0,0,.25*te,.25*ne,0)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,te,.15*ne,.25*te,.15*ne,.75*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,0,.85*ne,.75*te,.85*ne,.25*te)),le.add(new go.PathSegment(go.PathSegment.Move,.1675*ne,.15*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.8325*ne,.15*te,.35*ne,.3*te,.65*ne,.3*te)),le.add(new go.PathSegment(go.PathSegment.Move,.1675*ne,.85*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.8325*ne,.85*te,.35*ne,.7*te,.65*ne,.7*te)),he}),go.Shape.defineFigureGenerator("Wave",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.25*te,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Bezier,.3*ne,.25*te,.1*ne,0,.2*ne,0)),le.add(new go.PathSegment(go.PathSegment.Bezier,.7*ne,.25*te,.425*ne,.5*te,.575*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,ne,.25*te,.8*ne,0,.9*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.75*te)),le.add(new go.PathSegment(go.PathSegment.Move,0,.25*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.75*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.3*ne,.75*te,.1*ne,.5*te,.2*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.7*ne,.75*te,.425*ne,te,.575*ne,te)),le.add(new go.PathSegment(go.PathSegment.Bezier,ne,.75*te,.8*ne,.5*te,.9*ne,.5*te)),he}),go.Shape.defineFigureGenerator("Operator",function(Re,ne,te){var he=new go.Geometry,le=.3,pe=$e*.3,me=.5,xe=.7,Ee=new go.PathFigure((me-le)*ne,xe*te,!0);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+le)*ne,xe*te,(me+pe)*ne,(xe-le)*te,(me+le)*ne,(xe-pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me-le)*ne,xe*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te));var Ge=new go.PathFigure(0,.7*te,!1);return he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Bezier,ne,.7*te,0,0,ne,0)),he}),go.Shape.defineFigureGenerator("TripleFanBlades",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.5*ne,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.65*te,.65*ne,.3*te,.65*ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,0,.35*ne,.5*te,.35*ne,.3*te)),le.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.65*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,te,.3*ne,.6*te,.1*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.65*te,.2*ne,te,.35*ne,.95*te)),le.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.65*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,ne,te,.7*ne,.6*te,.9*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.65*te,.8*ne,te,.65*ne,.95*te)),he}),go.Shape.defineFigureGenerator("CentrifugalPump",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne,0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.4*ne,0)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*te,0,.075*te,0,.5*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.4*ne,te,0,te,.4*ne,te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.8*ne,.4*te,.8*ne,te,.85*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,0)),he}),go.Shape.defineFigureGenerator("Battery",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,.1*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.1*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Move,.4*ne,.1*te)),le.add(new go.PathSegment(go.PathSegment.Line,.4*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.1*te));var pe=new go.PathFigure(0,.6*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Move,0,.4*te)),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.4*te)),he}),go.Shape.defineFigureGenerator("Delete",function(Re,ne,te){var he=new go.Geometry,le=.5,pe=$e*.5,me=.5,xe=.5,Ee=new go.PathFigure((me-le)*ne,xe*te,!0);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+le)*ne,xe*te,(me+pe)*ne,(xe-le)*te,(me+le)*ne,(xe-pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me-le)*ne,xe*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te));var Ge=new go.PathFigure(.15*ne,.5*te,!1);return he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Line,.85*ne,.5*te)),he}),go.Shape.defineFigureGenerator("Flag",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.1*te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Move,0,.1*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.1*te,.15*ne,0,.35*ne,0)),le.add(new go.PathSegment(go.PathSegment.Bezier,ne,.1*te,.65*ne,.2*te,.85*ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.5*te,.85*ne,.6*te,.65*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*te,.35*ne,.4*te,.15*ne,.4*te).close()),he}),go.Shape.defineFigureGenerator("Help",function(Re,ne,te){var he=new go.Geometry,le=.5,pe=$e*.5,me=.5,xe=.5,Ee=new go.PathFigure((me-le)*ne,xe*te,!1);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me+le)*ne,xe*te,(me+pe)*ne,(xe-le)*te,(me+le)*ne,(xe-pe)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ee.add(new go.PathSegment(go.PathSegment.Bezier,(me-le)*ne,xe*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te).close()),le=.05,pe=$e*.05,me=.5,xe=.8;var Ge=new go.PathFigure((me-le)*ne,xe*te,!1);return he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe-le)*te,(me-le)*ne,(xe-pe)*te,(me-pe)*ne,(xe-le)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,(me+le)*ne,xe*te,(me+pe)*ne,(xe-le)*te,(me+le)*ne,(xe-pe)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,me*ne,(xe+le)*te,(me+le)*ne,(xe+pe)*te,(me+pe)*ne,(xe+le)*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,(me-le)*ne,xe*te,(me-pe)*ne,(xe+le)*te,(me-le)*ne,(xe+pe)*te).close()),Ge.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.7*te)),Ge.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.5*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,.2*te,.75*ne,.475*te,.75*ne,.225*te)),Ge.add(new go.PathSegment(go.PathSegment.Bezier,.3*ne,.35*te,.4*ne,.2*te,.3*ne,.25*te)),he}),go.Shape.defineFigureGenerator("Location",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(.5*ne,te,!0).add(new go.PathSegment(go.PathSegment.Line,.75*ne,.5*te)).add(new go.PathSegment(go.PathSegment.Bezier,.5*ne,0,.975*ne,.025*te,.5*ne,0)).add(new go.PathSegment(go.PathSegment.Bezier,.25*ne,.5*te,.5*ne,0,.025*ne,.025*te).close()).add(new go.PathSegment(go.PathSegment.Move,.5*ne,.2*te)).add(new go.PathSegment(go.PathSegment.Arc,270,360,.5*ne,.3*te,.1*ne,.1*te).close()))}),go.Shape.defineFigureGenerator("Lock",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.5*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.5*te));var pe=new go.PathFigure(.2*ne,.5*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.3*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,.8*ne,.3*te,.25*ne,0,.75*ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.3*te)),he}),go.Shape.defineFigureGenerator("Unlocked",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.5*te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.5*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.5*te));var pe=new go.PathFigure(.2*ne,.5*te,!1);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Move,.2*ne,.5*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.3*te)),pe.add(new go.PathSegment(go.PathSegment.Bezier,.8*ne,.3*te,.25*ne,0,.75*ne,0)),pe.add(new go.PathSegment(go.PathSegment.Line,.8*ne,.35*te)),he}),go.Shape.defineFigureGenerator("Gear",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(.9375*ne,.56246875*te,!0).add(new go.PathSegment(go.PathSegment.Line,.9375*ne,.4375*te)).add(new go.PathSegment(go.PathSegment.Line,.80621875*ne,.4375*te)).add(new go.PathSegment(go.PathSegment.Bezier,.763*ne,.3316875*te,.79840625*ne,.39915625*te,.7834375*ne,.3635*te)).add(new go.PathSegment(go.PathSegment.Line,.8566875*ne,.23796875*te)).add(new go.PathSegment(go.PathSegment.Line,.76825*ne,.14959375*te)).add(new go.PathSegment(go.PathSegment.Line,.67596875*ne,.24184375*te)).add(new go.PathSegment(go.PathSegment.Bezier,.5625*ne,.19378125*te,.64228125*ne,.2188125*te,.603875*ne,.2021875*te)).add(new go.PathSegment(go.PathSegment.Line,.5625*ne,.0625*te)).add(new go.PathSegment(go.PathSegment.Line,.4375*ne,.0625*te)).add(new go.PathSegment(go.PathSegment.Line,.4375*ne,.19378125*te)).add(new go.PathSegment(go.PathSegment.Bezier,.32775*ne,.239375*te,.39759375*ne,.20190625*te,.36053125*ne,.2176875*te)).add(new go.PathSegment(go.PathSegment.Line,.2379375*ne,.14959375*te)).add(new go.PathSegment(go.PathSegment.Line,.14953125*ne,.2379375*te)).add(new go.PathSegment(go.PathSegment.Line,.23934375*ne,.3278125*te)).add(new go.PathSegment(go.PathSegment.Bezier,.19378125*ne,.4375*te,.21765625*ne,.36059375*te,.201875*ne,.397625*te)).add(new go.PathSegment(go.PathSegment.Line,.0625*ne,.4375*te)).add(new go.PathSegment(go.PathSegment.Line,.0625*ne,.5625*te)).add(new go.PathSegment(go.PathSegment.Line,.1938125*ne,.5625*te)).add(new go.PathSegment(go.PathSegment.Bezier,.241875*ne,.67596875*te,.20221875*ne,.603875*te,.21884375*ne,.64228125*te)).add(new go.PathSegment(go.PathSegment.Line,.1495625*ne,.76825*te)).add(new go.PathSegment(go.PathSegment.Line,.238*ne,.8566875*te)).add(new go.PathSegment(go.PathSegment.Line,.3316875*ne,.76296875*te)).add(new go.PathSegment(go.PathSegment.Bezier,.43753125*ne,.80621875*te,.36353125*ne,.78340625*te,.3991875*ne,.79840625*te)).add(new go.PathSegment(go.PathSegment.Line,.43753125*ne,.9375*te)).add(new go.PathSegment(go.PathSegment.Line,.5625*ne,.9375*te)).add(new go.PathSegment(go.PathSegment.Line,.5625*ne,.80621875*te)).add(new go.PathSegment(go.PathSegment.Bezier,.67225*ne,.760625*te,.602375*ne,.79809375*te,.63946875*ne,.78234375*te)).add(new go.PathSegment(go.PathSegment.Line,.76828125*ne,.8566875*te)).add(new go.PathSegment(go.PathSegment.Line,.85671875*ne,.76825*te)).add(new go.PathSegment(go.PathSegment.Line,.76065625*ne,.67221875*te)).add(new go.PathSegment(go.PathSegment.Bezier,.80621875*ne,.56246875*te,.78234375*ne,.63940625*te,.798125*ne,.602375*te)).add(new go.PathSegment(go.PathSegment.Line,.9375*ne,.56246875*te).close()).add(new go.PathSegment(go.PathSegment.Move,.5*ne,.6*te)).add(new go.PathSegment(go.PathSegment.Arc,90,360,.5*ne,.5*te,.1*ne,.1*te).close()))}),go.Shape.defineFigureGenerator("Hand",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.5*te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Bezier,.1*ne,.3*te,0,.375*te,.05*ne,.325*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.45*ne,.075*te,.3*ne,.225*te,.4*ne,.175*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.525*ne,.075*te,.46*ne,.05*te,.525*ne,.05*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.3*ne,.4*te,.525*ne,.275*te,.475*ne,.325*te)),le.add(new go.PathSegment(go.PathSegment.Line,.9*ne,.4*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.9*ne,.55*te,ne,.4*te,ne,.55*te)),le.add(new go.PathSegment(go.PathSegment.Line,.425*ne,.55*te)),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.55*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.6*ne,.7*te,.675*ne,.55*te,.675*ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Line,.575*ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.575*ne,.85*te,.65*ne,.7*te,.65*ne,.85*te)),le.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.85*te)),le.add(new go.PathSegment(go.PathSegment.Line,.525*ne,.85*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.535*ne,te,.61*ne,.85*te,.61*ne,te)),le.add(new go.PathSegment(go.PathSegment.Bezier,0,.9*te,.435*ne,te,0,te).close()),he}),go.Shape.defineFigureGenerator("Map",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,.2*te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.25*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,.25*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,te).close()),le.add(new go.PathSegment(go.PathSegment.Move,.25*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.25*ne,.8*te)),le.add(new go.PathSegment(go.PathSegment.Move,.5*ne,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te)),le.add(new go.PathSegment(go.PathSegment.Move,.75*ne,0)),le.add(new go.PathSegment(go.PathSegment.Line,.75*ne,.8*te)),he}),go.Shape.defineFigureGenerator("Eject",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne,te)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te*.7)),le.add(new go.PathSegment(go.PathSegment.Line,0,te*.7).close());var pe=new go.PathFigure(0,te*.6,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne,.6*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.5*ne,0).close()),he}),go.Shape.defineFigureGenerator("Pencil",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,.2*ne,.1*te)).add(new go.PathSegment(go.PathSegment.Line,ne,.9*te)).add(new go.PathSegment(go.PathSegment.Line,.9*ne,te)).add(new go.PathSegment(go.PathSegment.Line,.1*ne,.2*te).close()))}),go.Shape.defineFigureGenerator("Building",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*1,te*1,!1);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,0,te*.85)),le.add(new go.PathSegment(go.PathSegment.Line,.046*ne,te*.85)),le.add(new go.PathSegment(go.PathSegment.Line,.046*ne,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,0,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,0,te*.3)),le.add(new go.PathSegment(go.PathSegment.Line,.046*ne,te*.3)),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,(1-.046)*ne,te*.3)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te*.3)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,(1-.046)*ne,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,(1-.046)*ne,te*.85)),le.add(new go.PathSegment(go.PathSegment.Line,ne,te*.85).close());var pe=new go.PathFigure(.126*ne,.85*te,!1);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,.126*ne,.45*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.322*ne,.45*te)),pe.add(new go.PathSegment(go.PathSegment.Line,.322*ne,.85*te).close());var me=new go.PathFigure(.402*ne,.85*te,!1);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.402*ne,.45*te)),me.add(new go.PathSegment(go.PathSegment.Line,.598*ne,.45*te)),me.add(new go.PathSegment(go.PathSegment.Line,.598*ne,.85*te).close());var xe=new go.PathFigure(.678*ne,.85*te,!1);he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,.678*ne,.45*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.874*ne,.45*te)),xe.add(new go.PathSegment(go.PathSegment.Line,.874*ne,.85*te).close());var Ee=new go.PathFigure(.5*ne,.1*te,!1);return he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Line,(.046+.15)*ne,.3*te)),Ee.add(new go.PathSegment(go.PathSegment.Line,(1-(.046+.15))*ne,.3*te).close()),he}),go.Shape.defineFigureGenerator("Staircase",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te*1,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne*.2,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.2,te*.8)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.4,te*.8)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.4,te*.6)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.6,te*.6)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.6,te*.4)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.8,te*.4)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.8,te*.2)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*.2)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*.15)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.75,te*.15)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.75,te*.35)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.55,te*.35)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.55,te*.55)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.35,te*.55)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.35,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.15,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.15,te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,0,te*.95).close()),he}),go.Shape.defineFigureGenerator("5Bars",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,te*1,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne*.184,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.184,te*(1-.184)).close());var pe=new go.PathFigure(ne*.204,te,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.204,te*(1-.184))),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.388,te*(1-.184*2))),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.388,te*1).close());var me=new go.PathFigure(ne*.408,te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne*.408,te*(1-.184*2))),me.add(new go.PathSegment(go.PathSegment.Line,ne*.592,te*(1-.184*3))),me.add(new go.PathSegment(go.PathSegment.Line,ne*.592,te*1).close());var xe=new go.PathFigure(ne*.612,te,!0);he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.612,te*(1-.184*3))),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.796,te*(1-.184*4))),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.796,te*1).close());var Ee=new go.PathFigure(ne*.816,te,!0);return he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*.816,te*(1-.184*4))),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*(1-.184*5))),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*1).close()),he}),go.Shape.defineFigureGenerator("PC",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,0,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.3,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.3,0).close());var pe=new go.PathFigure(ne*.055,.07*te,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.245,te*.07)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.245,te*.1)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.055,te*.1).close());var me=new go.PathFigure(ne*.055,.13*te,!0);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne*.245,te*.13)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.245,te*.16)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.055,te*.16).close());var xe=new go.PathFigure(ne*.055,.18*te,!0);he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.245,te*.18)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.245,te*.21)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.055,te*.21).close());var Ee=new go.PathFigure(ne*1,0,!0);return he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*.4,0)),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*.4,te*.65)),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*.65).close()),he}),go.Shape.defineFigureGenerator("Plane",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(.55*ne,te,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,.5*ne,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.7*te)),le.add(new go.PathSegment(go.PathSegment.Line,.1*ne,.475*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.35*ne,.525*te,0,.4*te,.225*ne,.45*te)),le.add(new go.PathSegment(go.PathSegment.Line,.4*ne,.475*te)),le.add(new go.PathSegment(go.PathSegment.Line,.15*ne,.35*te)),le.add(new go.PathSegment(go.PathSegment.Line,.2*ne,.325*te)),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.325*te)),le.add(new go.PathSegment(go.PathSegment.Line,.85*ne,.1*te)),le.add(new go.PathSegment(go.PathSegment.Bezier,.9*ne,.2*te,.975*ne,0,ne,.08*te)),le.add(new go.PathSegment(go.PathSegment.Line,.7*ne,.45*te)),le.add(new go.PathSegment(go.PathSegment.Line,.6*ne,.95*te)),le.add(new go.PathSegment(go.PathSegment.Line,.55*ne,te).close()),he}),go.Shape.defineFigureGenerator("Key",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*1,te*.5,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne*.9,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,.4*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,.35*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.45,.35*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.3,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.15,.2*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.35*te)),le.add(new go.PathSegment(go.PathSegment.Line,0,.65*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.15,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.3,.8*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.45,.65*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,.65*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.6,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.65,.55*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.7,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.75,.55*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.8,.6*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.85,.575*te)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.9,.6*te).close()),le.add(new go.PathSegment(go.PathSegment.Move,.17*ne,.425*te)),le.add(new go.PathSegment(go.PathSegment.Arc,270,360,.17*ne,.5*te,.075*ne,.075*te).close()),he}),go.Shape.defineFigureGenerator("FilmTape",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(0,0,!1);he.add(le),le.add(new go.PathSegment(go.PathSegment.Arc,270,180,ne*0,ne*.3,ne*.055)),le.add(new go.PathSegment(go.PathSegment.Line,0,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.08,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.08,te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*1),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*1),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*2),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*2),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*3),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*3),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*4),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*4),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*5),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*5),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*6),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*6),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*7),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*7),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*8),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*8),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*9),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*9),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*10),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*10),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*11),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*11),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*12),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*12),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*13),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*13),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*14),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*14),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*15),te*.95)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(.08+.056*15),te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*1));var pe=new go.PathFigure(0,0,!1);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*0)),pe.add(new go.PathSegment(go.PathSegment.Arc,270,-180,ne*1,ne*.3,ne*.055)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*1));var me=new go.PathFigure(ne*.11,te*.1,!1);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne*(.11+.24133333*1+.028*0),te*.1)),me.add(new go.PathSegment(go.PathSegment.Line,ne*(.11+.24133333*1+.028*0),te*.8)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.11,te*.8).close());var xe=new go.PathFigure(ne*(.11+.24133333*1+.028*1),te*.1,!1);he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne*(.11+.24133333*2+.028*1),te*.1)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*(.11+.24133333*2+.028*1),te*.8)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*(.11+.24133333*1+.028*1),te*.8).close());var Ee=new go.PathFigure(ne*(.11+.24133333*2+.028*2),te*.1,!1);return he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*(.11+.24133333*3+.028*2),te*.1)),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*(.11+.24133333*3+.028*2),te*.8)),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*(.11+.24133333*2+.028*2),te*.8).close()),he}),go.Shape.defineFigureGenerator("FloppyDisk",function(Re,ne,te){var he=new go.Geometry,le=8,pe=le*$e,me=new go.PathFigure(le,0,!1);he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne*.86,0)),me.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*.14)),me.add(new go.PathSegment(go.PathSegment.Line,ne,te-le)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne-le,te,ne,te-pe,ne-pe,te)),me.add(new go.PathSegment(go.PathSegment.Line,le,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,te-le,pe,te,0,te-pe)),me.add(new go.PathSegment(go.PathSegment.Line,0,le)),me.add(new go.PathSegment(go.PathSegment.Bezier,le,0,0,pe,pe,0).close());var xe=new go.PathFigure(ne*.83,0,!1);he.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.83,te*.3)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.17,te*.3)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.17,te*0).close());var Ee=new go.PathFigure(ne*.83,te*1,!1);he.add(Ee),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*.83,te*.5)),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*.17,te*.5)),Ee.add(new go.PathSegment(go.PathSegment.Line,ne*.17,te*1).close());var Ge=new go.PathFigure(ne*.78,te*.05,!1);return he.add(Ge),Ge.add(new go.PathSegment(go.PathSegment.Line,ne*.66,te*.05)),Ge.add(new go.PathSegment(go.PathSegment.Line,ne*.66,te*.25)),Ge.add(new go.PathSegment(go.PathSegment.Line,ne*.78,te*.25).close()),he}),go.Shape.defineFigureGenerator("SpeechBubble",function(Re,ne,te){var he=Re?Re.parameter1:NaN;(isNaN(he)||he<0)&&(he=15),he=Math.min(he,ne/3),he=Math.min(he,te/3);var le=he*$e,pe=te*.8,me=new go.Geometry,xe=new go.PathFigure(he,0,!0);return me.add(xe),xe.add(new go.PathSegment(go.PathSegment.Line,ne-he,0)),xe.add(new go.PathSegment(go.PathSegment.Bezier,ne,he,ne-le,0,ne,le)),xe.add(new go.PathSegment(go.PathSegment.Line,ne,pe-he)),xe.add(new go.PathSegment(go.PathSegment.Bezier,ne-he,pe,ne,pe-le,ne-le,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.7,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.7,te)),xe.add(new go.PathSegment(go.PathSegment.Line,ne*.55,pe)),xe.add(new go.PathSegment(go.PathSegment.Line,he,pe)),xe.add(new go.PathSegment(go.PathSegment.Bezier,0,pe-he,le,pe,0,pe-le)),xe.add(new go.PathSegment(go.PathSegment.Line,0,he)),xe.add(new go.PathSegment(go.PathSegment.Bezier,he,0,0,le,le,0).close()),le>1?(me.spot1=new go.Spot(0,0,le,le),me.spot2=new go.Spot(1,.8,-le,-le)):(me.spot1=go.Spot.TopLeft,me.spot2=new go.Spot(1,.8)),me}),go.Shape.defineFigureGenerator("Repeat",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*0,te*.45,!0);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne*.25,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.3,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.3,te*.9)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.6,te*.9)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.65,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.2,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.2,te*.45).close());var pe=new go.PathFigure(ne*1,te*.55,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.75,te*1)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.5,te*.55)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.7,te*.55)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.7,te*.1)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.4,te*.1)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.35,te*0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.8,te*0)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.8,te*.55).close()),he}),go.Shape.defineFigureGenerator("Windows",function(Re,ne,te){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,ne,0)).add(new go.PathSegment(go.PathSegment.Line,ne,te)).add(new go.PathSegment(go.PathSegment.Line,0,te).close()).add(new go.PathSegment(go.PathSegment.Move,.4*ne,.4*te)).add(new go.PathSegment(go.PathSegment.Line,.4*ne,.8*te)).add(new go.PathSegment(go.PathSegment.Line,.9*ne,.8*te)).add(new go.PathSegment(go.PathSegment.Line,.9*ne,.4*te).close()).add(new go.PathSegment(go.PathSegment.Move,.2*ne,.1*te)).add(new go.PathSegment(go.PathSegment.Line,.2*ne,.6*te)).add(new go.PathSegment(go.PathSegment.Line,.7*ne,.6*te)).add(new go.PathSegment(go.PathSegment.Line,.7*ne,.1*te).close()).add(new go.PathSegment(go.PathSegment.Move,.1*ne,.6*te)).add(new go.PathSegment(go.PathSegment.Line,.1*ne,.9*te)).add(new go.PathSegment(go.PathSegment.Line,.5*ne,.9*te)).add(new go.PathSegment(go.PathSegment.Line,.5*ne,.6*te).close()))}),go.Shape.defineFigureGenerator("Terminal",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*0,te*.1,!1);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*.1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*.9)),le.add(new go.PathSegment(go.PathSegment.Line,ne*0,te*.9).close());var pe=new go.PathFigure(ne*.1,te*.2,!0);he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.1,te*.25)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.22,te*.285)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.1,te*.32)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.1,te*.37)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.275,te*.32)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.275,te*.25).close());var me=new go.PathFigure(ne*.28,te*.37,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne*.45,te*.37)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.45,te*.41)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.28,te*.41).close()),he}),go.Shape.defineFigureGenerator("Beaker",function(Re,ne,te){var he=new go.Geometry,le=15,pe=le*$e,me=new go.PathFigure(ne*.62,te*.475,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne,te-le)),me.add(new go.PathSegment(go.PathSegment.Bezier,ne-le,te,ne,te-pe,ne-pe,te)),me.add(new go.PathSegment(go.PathSegment.Line,le,te)),me.add(new go.PathSegment(go.PathSegment.Bezier,0,te-le,pe,te,0,te-pe)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.38,te*.475)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.38,te*.03)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.36,te*0)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.64,te*0)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.62,te*.03).close()),pe>1?(he.spot1=new go.Spot(0,0,pe,pe),he.spot2=new go.Spot(1,1,-pe,-pe)):(he.spot1=go.Spot.TopLeft,he.spot2=go.Spot.BottomRight),he}),go.Shape.defineFigureGenerator("Download",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*0,te*1,!0);he.add(le);var pe=.1/.3;le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.8,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.66,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.66,te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.755,te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.93,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.64,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.61,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.39,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.36,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.07,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.755),te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.66),te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.66),te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.8),te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*0,te*(1-pe)).close());var me=new go.PathFigure(ne*.4,te*0,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne*.4,te*.44)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.26,te*.44)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.5,te*.66)),me.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.26),te*.44)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.6,te*.44)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.6,te*0).close()),he}),go.Shape.defineFigureGenerator("Bin",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*0,te*1,!0);he.add(le);var pe=.1/.3;return le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.8,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.66,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.66,te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.755,te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.93,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.64,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.61,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.39,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.36,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.07,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.755),te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.66),te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.66),te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.8),te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*0,te*(1-pe)).close()),he}),go.Shape.defineFigureGenerator("Upload",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*0,te*1,!0);he.add(le);var pe=.1/.3;le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.8,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.66,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.66,te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.755,te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.93,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.64,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.61,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.39,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.36,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*.07,te*(1-pe))),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.755),te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.66),te*.055)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.66),te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*(1-.8),te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*0,te*(1-pe)).close());var me=new go.PathFigure(ne*.5,te*0,!0);return he.add(me),me.add(new go.PathSegment(go.PathSegment.Line,ne*.26,te*.25)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.4,te*.25)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.4,te*.63)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.6,te*.63)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.6,te*.25)),me.add(new go.PathSegment(go.PathSegment.Line,ne*.74,te*.25).close()),he}),go.Shape.defineFigureGenerator("EmptyDrink",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*.15,te*0,!1);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne*.85,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.7,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.3,te*1).close()),he}),go.Shape.defineFigureGenerator("Drink",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*.15,te*0,!1);he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne*.85,te*0)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.7,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.3,te*1).close());var pe=new go.PathFigure(ne*.235,te*.28,!0);return he.add(pe),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.765,te*.28)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.655,te*.97)),pe.add(new go.PathSegment(go.PathSegment.Line,ne*.345,te*.97).close()),he}),go.Shape.defineFigureGenerator("4Arrows",function(Re,ne,te){var he=new go.Geometry,le=new go.PathFigure(ne*.5,te*0,!0);return he.add(le),le.add(new go.PathSegment(go.PathSegment.Line,ne*.65,te*.25)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.55,te*.25)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.55,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.75,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.75,te*.35)),le.add(new go.PathSegment(go.PathSegment.Line,ne*1,te*.5)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.75,te*.65)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.75,te*.55)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.55,te*.55)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.55,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.65,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.5,te*1)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.35,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.45,te*.75)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.45,te*.55)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.25,te*.55)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.25,te*.65)),le.add(new go.PathSegment(go.PathSegment.Line,ne*0,te*.5)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.25,te*.35)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.25,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.45,te*.45)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.45,te*.25)),le.add(new go.PathSegment(go.PathSegment.Line,ne*.35,te*.25).close()),he}),go.Shape.defineFigureGenerator("Connector","Ellipse"),go.Shape.defineFigureGenerator("Alternative","TriangleUp"),go.Shape.defineFigureGenerator("Merge","TriangleUp"),go.Shape.defineFigureGenerator("Decision","Diamond"),go.Shape.defineFigureGenerator("DataTransmissions","Hexagon"),go.Shape.defineFigureGenerator("Gate","Crescent"),go.Shape.defineFigureGenerator("Delay","HalfEllipse"),go.Shape.defineFigureGenerator("Input","Parallelogram1"),go.Shape.defineFigureGenerator("ManualLoop","ManualOperation"),go.Shape.defineFigureGenerator("ISOProcess","Chevron"),go.Shape.defineFigureGenerator("MessageToUser","SquareArrow"),go.Shape.defineFigureGenerator("MagneticData","Cylinder1"),go.Shape.defineFigureGenerator("DirectData","Cylinder4"),go.Shape.defineFigureGenerator("StoredData","DataStorage"),go.Shape.defineFigureGenerator("SequentialData","MagneticTape"),go.Shape.defineFigureGenerator("Subroutine","Procedure")},61016:function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_ARRAY__,__WEBPACK_AMD_DEFINE_RESULT__;(function(){if(typeof window.GGBApplet=="function"){console.warn("deployggb.js was loaded twice");return}var isRenderGGBElementEnabled=!1,scriptLoadStarted=!1,html5AppletsToProcess=null,ggbHTML5LoadedCodebaseIsWebSimple=!1,ggbHTML5LoadedCodebaseVersion=null,ggbHTML5LoadedScript=null,GGBApplet=function(){"use strict";for(var jn={},li="5.0",De={},Ne=null,dt=!1,Ut=!1,$t=null,kt=!1,Ie=null,$e=null,Mt=0;Mt<arguments.length;Mt++){var Pt=arguments[Mt];if(Pt!==null)switch(typeof Pt){case"number":li=Pt.toFixed(1);break;case"string":Pt.match(new RegExp("^[0-9]\\.[0-9]+$"))?li=Pt:$t=Pt;break;case"object":typeof Pt.is3D!="undefined"?Ne=Pt:De=Pt;break;case"boolean":dt=Pt,Ut=!0;break}}Ne===null&&(Ne={is3D:!1,AV:!1,SV:!1,CV:!1,EV2:!1,CP:!1,PC:!1,DA:!1,FI:!1,PV:!1,macro:!1},De.material_id!==void 0&&!Ut&&(dt=!0)),$t!==null&&De.id===void 0&&(De.id=$t);var wt="",Qt="",It=!1,sn=null,Re=null,ne=null,te=!1,he=null,le=null,pe=null,me=null,xe=null;De.height!==void 0&&(De.height=Math.round(De.height)),De.width!==void 0&&(De.width=Math.round(De.width));var Ee=function(Lt){return parseFloat(Lt)>4?parseFloat(Lt):5};jn.setHTML5Codebase=function(Lt,xn){$e=Lt,ke(Lt,xn)},jn.setJavaCodebase=jn.setJavaCodebaseVersion=jn.isCompiledInstalled=jn.setPreCompiledScriptPath=jn.setPreCompiledResourcePath=function(){},jn.setHTML5CodebaseVersion=function(Lt,xn){var vn=parseFloat(Lt);if(vn!==NaN&&vn<5){console.log("The GeoGebra HTML5 codebase version "+vn+" is deprecated. Using version latest instead.");return}Ie=Lt,ze(Lt,xn)},jn.getHTML5CodebaseVersion=function(){return Re},jn.getParameters=function(){return De},jn.setFontsCSSURL=function(Lt){me=Lt},jn.setGiacJSURL=function(Lt){},jn.setJNLPFile=function(Lt){wt=Lt},jn.setJNLPBaseDir=function(Lt){},jn.inject=function(){function Lt(){return window.frameElement&&window.frameElement.getAttribute("data-singleton")}for(var xn="auto",vn=De.id,Xn,Ot=!1,ft=0;ft<arguments.length;ft++){var Gt=arguments[ft];typeof Gt=="string"?(Gt=Gt.toLowerCase(),Gt.match(/^(prefer)?(java|html5|compiled|auto|screenshot)$/)?xn=Gt:vn=arguments[ft]):typeof Gt=="boolean"?Ot=Gt:Gt instanceof HTMLElement&&(Xn=Gt)}an();function an(){if(!kt){setTimeout(an,200);return}xn=Dn(xn);var Jt=Xn||document.getElementById(vn);if(!Jt){console.log("possibly bug on ajax loading? ");return}if(jn.removeExistingApplet(Jt,!1),De.width===void 0&&Jt.clientWidth&&(De.width=Jt.clientWidth),De.height===void 0&&Jt.clientHeight&&(De.height=Jt.clientHeight),!(De.width&&De.height)&&xn==="html5"&&(delete De.width,delete De.height),sn=xn,xn==="screenshot")cn(Jt,De);else{var Ve=!1;De.hasOwnProperty("playButton")&&De.playButton||De.hasOwnProperty("clickToLoad")&&De.clickToLoad?Ve=!0:De.hasOwnProperty("playButtonAutoDecide")&&De.playButtonAutoDecide&&(Ve=(!Ge()||Lt())&&et()),Ve?(sn="screenshot",hi(Jt,De,Ot,xn)):Ft(Jt,De,Ot)}}};function Ge(){try{return window.self!==window.top}catch(Lt){return!0}}function et(){return De.hasOwnProperty("screenshotGenerator")&&De.screenshotGenerator?!1:Math.max(screen.width,screen.height)<800}jn.getViews=function(){return Ne},jn.isJavaInstalled=function(){return!1};var ut=function(Lt){var xn=function(ft){var Gt=JSON.parse(ft),an=function(be){return be.type=="G"||be.type=="E"},Jt=Gt.elements?Gt.elements.filter(an)[0]:Gt;if(!Jt||!Jt.url){vn();return}De.fileName=Jt.url,st(Jt.settings||{}),Ne.is3D=!0;var Ve="https://www.geogebra.org/images/";jn.setPreviewImage(he||Jt.previewUrl,Ve+"GeoGebra_loading.png",Ve+"applet_play.png"),Lt()},vn=function(){De.onError&&De.onError(),Wt("Error: Fetching material (id "+De.material_id+") failed.",De)},Xn=location.host.match(/(www|stage|beta|groot|alpha).geogebra.(org|net)/)?location.host:"www.geogebra.org",Ot="/materials/"+De.material_id+"?scope=basic";it("https://"+Xn+"/api/proxy.php?path="+encodeURIComponent(Ot),xn,vn)};function st(Lt){var xn=["width","height","showToolBar","showMenuBar","showAlgebraInput","allowStyleBar","showResetIcon","enableLabelDrags","enableShiftDragZoom","enableRightClick","appName"];["enableLabelDrags","enableShiftDragZoom","enableRightClick"].forEach(function(vn){Lt[vn]=!!Lt[vn]}),xn.forEach(function(vn){De[vn]===void 0&&Lt[vn]!==void 0&&(De[vn]=Lt[vn])}),De.showToolBarHelp===void 0&&(De.showToolBarHelp=De.showToolBar)}function it(Lt,xn,vn){var Xn=new XMLHttpRequest;Xn.open("GET",Lt),Xn.onload=function(){xn(Xn.responseText)},Xn.onerror=vn,Xn.send()}jn.isHTML5Installed=function(){return!0},jn.getLoadedAppletType=function(){return sn},jn.setPreviewImage=function(Lt,xn,vn){he=Lt,le=xn,pe=vn},jn.removeExistingApplet=function(Lt,xn){var vn;typeof Lt=="string"&&(Lt=document.getElementById(Lt)),sn=null;var Xn=null;for(vn=0;vn<Lt.childNodes.length;vn++){var Ot=Lt.childNodes[vn],ft=Ot.className;ft==="applet_screenshot"?xn?(Ot.style.display="block",sn="screenshot"):Ot.style.display="none":ft!=="applet_scaler prerender"&&(Lt.removeChild(Ot),Xn=ft&&ft.indexOf("appletParameters")!=-1?Ot.id:null,vn--)}var Gt=De.id!==void 0?De.id:Xn,an=window[Gt];an&&typeof an.getBase64=="function"&&(an.remove(),window[Gt]=null)},jn.refreshHitPoints=function(){if(Ee(ggbHTML5LoadedCodebaseVersion)>=5)return!0;var Lt=jn.getAppletObject();return Lt&&typeof Lt.recalculateEnvironments=="function"?(Lt.recalculateEnvironments(),!0):!1},jn.startAnimation=function(){var Lt=jn.getAppletObject();return Lt&&typeof Lt.startAnimation=="function"?(Lt.startAnimation(),!0):!1},jn.stopAnimation=function(){var Lt=jn.getAppletObject();return Lt&&typeof Lt.stopAnimation=="function"?(Lt.stopAnimation(),!0):!1},jn.getAppletObject=function(){var Lt=De.id!==void 0?De.id:"ggbApplet";return window[Lt]},jn.resize=function(){};var Nt=function(Lt,xn,vn){var Xn=document.createElement("param");Xn.setAttribute("name",xn),Xn.setAttribute("value",vn),Lt.appendChild(Xn)},St=function(Lt){return Lt&&Lt!=="false"},Ft=function(Lt,xn,vn){Ee(Re)<=4.2&&(vn=!0);var Xn=!isRenderGGBElementEnabled&&!scriptLoadStarted;(!isRenderGGBElementEnabled&&!scriptLoadStarted||ggbHTML5LoadedCodebaseVersion!==Re||ggbHTML5LoadedCodebaseIsWebSimple&&!te)&&(Xn=!0,isRenderGGBElementEnabled=!1,scriptLoadStarted=!1);var Ot=document.createElement("div");Ot.classList.add("appletParameters","notranslate");var ft=xn.width,Gt=xn.height;if(xn.disableAutoScale=xn.disableAutoScale===void 0?GGBAppletUtils.isFlexibleWorksheetEditor():xn.disableAutoScale,xn.width!==void 0)if(Ee(Re)<=4.4)St(xn.showToolBar)&&(xn.height-=7),St(xn.showAlgebraInput)&&(xn.height-=37),xn.width<605&&St(xn.showToolBar)&&(xn.width=605,ft=605);else{var an=100;(St(xn.showToolBar)||St(xn.showMenuBar))&&(xn.hasOwnProperty("customToolBar")&&(xn.customToolbar=xn.customToolBar),an=St(xn.showMenuBar)?245:155),ft<an&&(xn.width=an,ft=an)}Ot.style.border="none",Ot.style.display="inline-block";for(var Jt in xn)xn.hasOwnProperty(Jt)&&Jt!=="appletOnLoad"&&Ot.setAttribute("data-param-"+Jt,xn[Jt]);me&&Ot.setAttribute("data-param-fontscssurl",me),jn.resize=function(){GGBAppletUtils.responsiveResize(Lt,xn)},window.addEventListener("resize",function(Zt){jn.resize()});var Ve=typeof xn.appletOnLoad=="function"?xn.appletOnLoad:function(){};if(!vn&&xn.width!==void 0){xn.hasOwnProperty("showSplash")||Ot.setAttribute("data-param-showSplash","false");var be=Lt.querySelector(".applet_scaler.prerender"),Pe=be!==null;if(Pe)var Be=be.querySelector(".ggb_preview");else{var Be=zn(ft,Gt,xn.borderColor,!1);be=document.createElement("div"),be.className="applet_scaler",be.style.position="relative",be.style.display="block",be.style.width=ft+"px",be.style.height=Gt+"px"}window.GGBT_spinner&&window.GGBT_spinner.attachSpinner(be,"66%"),Ee(Re)>=5?(xn.appletOnLoad=function(Zt){var _n=Lt.querySelector(".ggb_preview");_n&&_n.parentNode.removeChild(_n),window.GGBT_spinner&&window.GGBT_spinner.removeSpinner(be),window.GGBT_wsf_view&&$(window).trigger("resize"),Ve(Zt)},Pe||be.appendChild(Be)):Ot.appendChild(Be),be.appendChild(Ot),Pe||Lt.appendChild(be),setTimeout(function(){jn.resize()},1)}else{var Ze=document.createElement("div");Ze.className="applet_scaler",Ze.style.position="relative",Ze.style.display="block",Ze.appendChild(Ot),Lt.appendChild(Ze),xn.appletOnLoad=function(Zt){jn.resize(),Ve(Zt)}}function Fe(Zt,_n){_n&&typeof _n.appletOnLoad=="function"&&typeof renderGGBElement=="function"?renderGGBElement(Zt,_n.appletOnLoad):renderGGBElement(Zt),Wt("GeoGebra HTML5 applet injected and rendered with previously loaded codebase.",_n)}function qe(Zt,_n){typeof renderGGBElement=="undefined"?(html5AppletsToProcess===null&&(html5AppletsToProcess=[]),html5AppletsToProcess.push({article:Zt,params:_n}),window.renderGGBElementReady=function(){isRenderGGBElementEnabled=!0,html5AppletsToProcess!==null&&html5AppletsToProcess.length&&(html5AppletsToProcess.forEach(function(ti){Fe(ti.article,ti.params)}),html5AppletsToProcess=null)},Ee(Re)<5&&(Zt.className+=" geogebraweb")):Fe(Zt,_n)}if(Xn){scriptLoadStarted=!0;for(var dn=0;dn<Ot.childNodes.length;dn++){var ui=Ot.childNodes[dn].tagName;ui==="TABLE"&&(Ot.removeChild(Ot.childNodes[dn]),dn--)}if(ggbHTML5LoadedScript!==null){var $n=document.querySelector('script[src="'+ggbHTML5LoadedScript+'"]');$n!=null&&$n.parentNode.removeChild($n)}var rn=document.createElement("script"),Hn=function(){qe(Ot,xn)};rn.src=Qt+ne,ggbHTML5LoadedCodebaseIsWebSimple=te,ggbHTML5LoadedCodebaseVersion=Re,ggbHTML5LoadedScript=rn.src,Wt("GeoGebra HTML5 codebase loaded: '"+Qt+"'.",xn),!$e&&(!Ie||Ie=="5.0")?(te?webSimple.succeeded=webSimple.succeeded||webSimple():web3d.succeeded=web3d.succeeded||web3d(),Hn()):Qt.requirejs?__webpack_require__.e(12).then(function(){var Zt=[__webpack_require__(12)];Hn.apply(null,Zt)}.bind(this)).catch(__webpack_require__.oe):(rn.onload=Hn,Lt.appendChild(rn))}else qe(Ot,xn);xn.height=Gt,xn.width=ft},cn=function(Lt,xn,vn){var Xn=zn(xn.width,xn.height,xn.borderColor,vn),Ot=document.createElement("div");Ot.style.position="relative",Ot.style.display="block",Ot.style.width=xn.width+"px",Ot.style.height=xn.height+"px",Ot.className="applet_screenshot applet_scaler"+(vn?" applet_screenshot_play":""),Ot.appendChild(Xn);var ft=GGBAppletUtils.getScale(xn,Lt,vn);vn?(Lt.appendChild(di()),window.GGBT_wsf_view||(Lt.style.position="relative")):window.GGBT_spinner&&window.GGBT_spinner.attachSpinner(Ot,"66%"),Lt.appendChild(Ot),ft!==1&&!isNaN(ft)&&(GGBAppletUtils.scaleElement(Ot,ft),Ot.style.width=xn.width+"px",Ot.style.height=xn.height+"px",Ot.parentNode.style.width=xn.width*ft+"px",Ot.parentNode.style.height=xn.height*ft+"px"),jn.resize=function(){Tt(Lt,Xn,Ot,vn)},window.addEventListener("resize",function(Gt){jn.resize()}),jn.resize()};function Tt(Lt,xn,vn,Xn){if(Lt.contains(xn)){if(typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){if(Lt.id!=="fullscreencontent")return;window.GGBT_wsf_view.setCloseBtnPosition(Lt)}var Ot=GGBAppletUtils.getScale(De,Lt,Xn);vn.parentNode!==null&&(!isNaN(Ot)&&Ot!==1?(GGBAppletUtils.scaleElement(vn,Ot),vn.parentNode.style.width=De.width*Ot+"px",vn.parentNode.style.height=De.height*Ot+"px"):(GGBAppletUtils.scaleElement(vn,1),vn.parentNode.style.width=De.width+"px",vn.parentNode.style.height=De.height+"px")),typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&GGBAppletUtils.positionCenter(Lt),typeof window.GGBT_ws_header_footer=="object"&&window.GGBT_ws_header_footer.setWsScrollerHeight()}}jn.onExitFullscreen=function(Lt,xn){xn.appendChild(Lt)};var hi=function(Lt,xn,vn,Xn){cn(Lt,xn,!0);for(var Ot=function(){var an=[];for(Gt=0;Gt<Lt.childNodes.length;Gt++)an.push(Lt.childNodes[Gt]);if(window.GGBT_wsf_view){var Jt=window.GGBT_wsf_view.renderFullScreen(Lt,xn.id),Ve=document.getElementById("fullscreencontainer"),be=jQuery(Lt).find(".fullscreencontent");be.length>0?(Jt.remove(),be.attr("id","fullscreencontent").show(),jQuery(Ve).append(be),window.dispatchEvent(new Event("resize"))):Ft(Jt,xn,!1),window.GGBT_wsf_view.launchFullScreen(Ve)}else sn=Xn,Ft(Lt,xn,!1);if(!window.GGBT_wsf_view)for(Gt=0;Gt<an.length;Gt++)Lt.removeChild(an[Gt])},ft=Lt.getElementsByClassName("ggb_preview_play"),Gt=0;Gt<ft.length;Gt++)ft[Gt].addEventListener("click",Ot,!1),ft[Gt].addEventListener("ontouchstart",Ot,!1);typeof window.ggbAppletPlayerOnload=="function"&&window.ggbAppletPlayerOnload(Lt),et()&&window.GGBT_wsf_view&&$(".wsf-element-fullscreen-button").remove()},di=function(){var Lt=document.createElement("div");if(Lt.className="ggb_preview_play icon-applet-play",!window.GGBT_wsf_view){var xn='.icon-applet-play { width: 100%; height: 100%;box-sizing: border-box;position: absolute;z-index: 1001;cursor: pointer;border-width: 0px; background-color: transparent;background-repeat: no-repeat;left: 0;top: 0;background-position: center center; background-image: url("https://www.geogebra.org/images/worksheet/icon-start-applet.png");}.icon-applet-play:hover {background-image: url("https://www.geogebra.org/images/worksheet/icon-start-applet-hover.png");}',vn=document.createElement("style");vn.styleSheet?vn.styleSheet.cssText=xn:vn.appendChild(document.createTextNode(xn)),document.getElementsByTagName("head")[0].appendChild(vn)}return Lt},zn=function(Lt,xn,vn,Xn){var Ot=document.createElement("div");Ot.className="ggb_preview",Ot.style.position="absolute",Ot.style.zIndex="90",Ot.style.width=Lt-2+"px",Ot.style.height=xn-2+"px",Ot.style.top="0px",Ot.style.left="0px",Ot.style.overflow="hidden",Ot.style.backgroundColor="white";var ft="lightgrey";vn!==void 0&&(vn==="none"?ft="transparent":ft=vn),Ot.style.border="1px solid "+ft;var Gt=document.createElement("img");if(Gt.style.position="relative",Gt.style.zIndex="1000",Gt.style.top="-1px",Gt.style.left="-1px",he!==null&&Gt.setAttribute("src",he),Gt.style.opacity=.7,le!==null){var an,Jt,Ve;if(!Xn){an=document.createElement("img"),an.style.position="absolute",an.style.zIndex="1001",an.style.opacity=1,Gt.style.opacity=.3,Jt=360,Jt>Lt/4*3&&(Jt=Lt/4*3),Ve=Jt/5.8,an.setAttribute("src",le),an.setAttribute("width",Jt),an.setAttribute("height",Ve);var be=(Lt-Jt)/2,Pe=(xn-Ve)/2;an.style.left=be+"px",an.style.top=Pe+"px",Ot.appendChild(an)}}return Ot.appendChild(Gt),Ot},Dn=function(Lt){return Lt=Lt.toLowerCase(),Lt==="html5"||Lt==="screenshot"?Lt:"html5"},nt=["web","webSimple","web3d","tablet","tablet3d","phone"],ze=function(Lt,xn){if(Re=Lt,xn){ke(Re,!0);return}var vn=!dt;if(vn){var Xn=Ee(Re);!isNaN(Xn)&&Xn<4.4&&(vn=!1)}var Ot,ft;window.location.protocol.substr(0,4)==="http"?Ot=window.location.protocol:Ot="http:";var Gt=Re.indexOf("//");Gt>0?ft=Re:Gt===0?ft=Ot+Re:ft="https://www.geogebra.org/apps/5.2.814.0/";for(var an in nt)if(Re.slice(nt[an].length*-1)===nt[an]||Re.slice((nt[an].length+1)*-1)===nt[an]+"/"){ke(ft,!1);return}!GGBAppletUtils.isFlexibleWorksheetEditor()&&vn&&!Ne.is3D&&!Ne.AV&&!Ne.SV&&!Ne.CV&&!Ne.EV2&&!Ne.CP&&!Ne.PC&&!Ne.DA&&!Ne.FI&&!Ne.PV&&!St(De.showToolBar)&&!St(De.showMenuBar)&&!St(De.showAlgebraInput)&&!St(De.enableRightClick)&&(!De.appName||De.appName=="classic")?ft+="webSimple/":ft+="web3d/",ke(ft,!1)},ke=function(Lt,xn){if(Lt.requirejs){Qt=Lt;return}Lt.slice(-1)!=="/"&&(Lt+="/"),Qt=Lt,xn===null&&(xn=Lt.indexOf("http")===-1),It=xn,ne="web.nocache.js",te=!1;var vn=Qt.split("/");vn.length>1&&(!xn&&vn[vn.length-2]==="webSimple"?(ne="webSimple.nocache.js",te=!0):nt.indexOf(vn[vn.length-2])>=0&&(ne=vn[vn.length-2]+".nocache.js")),vn=Lt.split("/"),Re=vn[vn.length-3],Re.substr(0,4)==="test"?Re=Re.substr(4,1)+"."+Re.substr(5,1):(Re.substr(0,3)==="war"||Re.substr(0,4)==="beta")&&(Re="5.0");var Xn=parseFloat(Re);Xn!==NaN&&Xn<5&&Lt.indexOf("geogebra.org")>=0&&(console.log("The GeoGebra HTML5 codebase version "+Xn+" is deprecated. Using version latest instead."),ze("5.0",xn))},Wt=function(Lt,xn){window.console&&window.console.log&&(!xn||typeof xn.showLogging=="undefined"||xn.showLogging&&xn.showLogging!=="false")&&console.log(Lt)};De.material_id!==void 0?ut(On):On();function On(){var Lt=li;Ie!==null?Lt=Ie:parseFloat(Lt)<5&&(Lt="5.0"),ze(Lt,!1),$e!==null&&ke($e,It),kt=!0}return jn},GGBAppletUtils=function(){"use strict";function jn(){return window.GGBT_wsf_edit!==void 0}function li(kt,Ie){Ie!=1?(kt.style.transformOrigin="0% 0% 0px",kt.style.webkitTransformOrigin="0% 0% 0px",kt.style.transform="scale("+Ie+","+Ie+")",kt.style.webkitTransform="scale("+Ie+","+Ie+")",kt.style.maxWidth="initial",kt.querySelector(".ggb_preview")!==null&&(kt.querySelector(".ggb_preview").style.maxWidth="initial"),kt.querySelectorAll(".ggb_preview img")[0]!==void 0&&(kt.querySelectorAll(".ggb_preview img")[0].style.maxWidth="initial"),kt.querySelectorAll(".ggb_preview img")[1]!==void 0&&(kt.querySelectorAll(".ggb_preview img")[1].style.maxWidth="initial")):(kt.style.transform="none",kt.style.webkitTransform="none")}function De(kt,Ie,$e,Mt,Pt,wt){var Qt=null;if(wt!=null&&wt!="")for(var It=kt.parentNode;It!=null;)if((" "+It.className+" ").indexOf(" "+wt+" ")>-1){Qt=It;break}else It=It.parentNode;var sn=0,Re=0,ne=0,te=0,he=0,le=0,pe=0;if(Qt)sn=Qt.offsetWidth,Re=Math.max(Mt?Qt.offsetWidth:0,Qt.offsetHeight);else{if(window.innerWidth&&document.documentElement.clientWidth?(sn=Math.min(window.innerWidth,document.documentElement.clientWidth),Re=Math.min(window.innerHeight,document.documentElement.clientHeight),ne=sn):(sn=window.innerWidth,Re=window.innerHeight,ne=window.innerWidth),kt){var me=kt.getBoundingClientRect();me.left>0&&me.left<=sn&&(Pt===void 0||!Pt)&&(document.dir==="rtl"?(he=sn-me.width-me.left,le=ne<=480?10:30):(le=me.left,he=ne<=480?10:30),te=le+he)}if(kt&&typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){var xe=kt.getBoundingClientRect();window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionRight"?(te=40,pe=0):window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionTop"&&(te=0,pe=40)}}return kt&&(($e===void 0||!$e)&&Ie>0&&Ie+te<sn?sn=Ie:sn-=te,typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&($e===void 0||!$e)&&(Re-=pe)),{width:sn,height:Re}}function Ne(kt,Ie,$e,Mt,Pt){if(kt.isScreenshoGenerator)return 1;var wt=Mt!==void 0&&Mt,Qt=kt.noScaleMargin!=null&&kt.noScaleMargin,It=function(xe){return xe&&xe!=="false"},sn=It(kt.autoHeight),Re=De(Ie,kt.width,$e,sn,wt&&window.GGBT_wsf_view||Qt,Pt),ne=parseInt(Re.width),te=kt.width,he=kt.height;if(te===void 0){var le=Ie.querySelector(".appletParameters");le&&(te=le.offsetWidth,he=le.offsetHeight)}var pe=ne/te,me=wt?1:Re.height/he;return $e!==void 0&&!$e&&(pe=Math.min(1,pe),me=Math.min(1,me)),Math.min(pe,me)}function dt(kt,Ie,$e){var Mt=1,Pt,wt=!1;if(kt.hasOwnProperty("allowUpscale")&&(wt=kt.allowUpscale),kt.hasOwnProperty("scale")&&(Mt=parseFloat(kt.scale),(isNaN(Mt)||Mt===null||Mt===0)&&(Mt=1),Mt>1&&(wt=!0)),Ie&&typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&(wt=!0),!(kt.hasOwnProperty("disableAutoScale")&&kt.disableAutoScale))Pt=Ne(kt,Ie,wt,$e,kt.scaleContainerClass);else return Mt;return wt&&(!kt.hasOwnProperty("scale")||Mt===1)?Pt:Math.min(Mt,Pt)}function Ut(kt){var Ie=Math.min(window.innerWidth,document.documentElement.clientWidth),$e=Math.min(window.innerHeight,document.documentElement.clientHeight),Mt=kt.getBoundingClientRect(),Pt=(Ie-Mt.width)/2,wt=($e-Mt.height)/2;wt<0&&(wt=0),kt.style.position="relative",window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionRight"?(Pt<40?kt.style.left="40px":kt.style.left=Pt+"px",kt.style.top=wt+"px"):window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionTop"&&(wt<40?kt.style.top="40px":kt.style.top=wt+"px",kt.style.left=Pt+"px")}function $t(kt,Ie){var $e=kt.querySelector(".appletParameters");if($e){if(typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){if(Ie.id!==$e.getAttribute("data-param-id"))return;window.GGBT_wsf_view.setCloseBtnPosition(kt)}if($e.parentElement&&/fullscreen/.test($e.parentElement.className))return;var Mt=dt(Ie,kt);jn()&&$e.setAttribute("data-param-scale",Mt);for(var Pt=null,wt=0;wt<kt.childNodes.length;wt++)if(kt.childNodes[wt].className!==void 0&&kt.childNodes[wt].className.match(/^applet_scaler/)){Pt=kt.childNodes[wt];break}if(Pt!==null&&Pt.querySelector(".noscale")!==null)return;var Qt=Ie.id!==void 0?Ie.id:"ggbApplet",It=window[Qt];(It==null||!It.recalculateEnvironments)&&Pt!==null&&!Pt.className.match(/fullscreen/)&&(Pt.parentNode.style.transform="",!isNaN(Mt)&&Mt!==1?(Pt.parentNode.style.width=Ie.width*Mt+"px",Pt.parentNode.style.height=Ie.height*Mt+"px",li(Pt,Mt)):(li(Pt,1),Pt.parentNode.style.width=Ie.width+"px",Pt.parentNode.style.height=Ie.height+"px")),typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&Ut(kt),window.GGBT_wsf_view&&!window.GGBT_wsf_view.isFullscreen()&&window.GGBT_wsf_general.adjustContentToResize($($e).parents(".content-added-content"))}}return{responsiveResize:$t,isFlexibleWorksheetEditor:jn,positionCenter:Ut,getScale:dt,scaleElement:li}}();__WEBPACK_AMD_DEFINE_ARRAY__=[],__WEBPACK_AMD_DEFINE_RESULT__=function(){return GGBApplet}.apply(exports,__WEBPACK_AMD_DEFINE_ARRAY__),__WEBPACK_AMD_DEFINE_RESULT__!==void 0&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__),GGBAppletUtils.makeModule=function(name,permutation){function webModule(){var H="bootstrap",I="begin",J="gwt.codesvr."+name+"=",K="gwt.codesvr=",L=name,M="startup",N="DUMMY",O=0,P=1,Q="iframe",R="position:absolute; width:0; height:0; border:none; left: -1000px;",S=" top: -1000px;",T="Chrome",U="CSS1Compat",V="<!doctype html>",W="",X="<html><head></head><body></body></html>",Y="undefined",Z="readystatechange",$=10,_="script",ab="javascript",bb="Failed to load ",cb="moduleStartup",db="scriptTagAdded",eb="moduleRequested",fb="meta",gb="name",hb=name+"::",ib="::",jb="gwt:property",kb="content",lb="=",mb="gwt:onPropertyErrorFn",nb='Bad handler "',ob='" for "gwt:onPropertyErrorFn"',pb="gwt:onLoadErrorFn",qb='" for "gwt:onLoadErrorFn"',rb="#",sb="?",tb="/",ub="img",vb="clear.cache.gif",wb="baseUrl",xb=name+".nocache.js",yb="base",zb="//",Ab="selectingPermutation",Bb=name+".devmode.js",Cb=permutation,Db=":",Eb=".cache.js",Fb="loadExternalRefs",Gb="end",n=window,o=document;function p(){var jn=n.location.search;return jn.indexOf(J)!=-1||jn.indexOf(K)!=-1}function q(jn,li){}webModule.__sendStats=q,webModule.__moduleName=L,webModule.__errFn=null,webModule.__moduleBase=N,webModule.__softPermutationId=O,webModule.__computePropValue=null,webModule.__getPropMap=null,webModule.__installRunAsyncCode=function(){},webModule.__gwtStartLoadingFragment=function(){return null},webModule.__gwt_isKnownPropertyValue=function(){return!1},webModule.__gwt_getMetaProperty=function(){return null};var r=null,s=n.__gwt_activeModules=n.__gwt_activeModules||{};s[L]={moduleName:L},webModule.__moduleStartupDone=function(jn){var li=s[L].bindings;s[L].bindings=function(){for(var De=li?li():{},Ne=jn[webModule.__softPermutationId],dt=O;dt<Ne.length;dt++){var Ut=Ne[dt];De[Ut[O]]=Ut[P]}return De}};var t;function u(){return v(),t}function v(){if(!t){var jn=o.createElement(Q);if(jn.id=L,jn.style.cssText=R+S,jn.tabIndex=-1,o.body.appendChild(jn),t=jn.contentWindow.document,navigator.userAgent.indexOf(T)==-1){t.open();var li=document.compatMode==U?V:W;t.write(li+X),t.close()}}}function w(jn){function li(Ne){function dt(){return typeof o.readyState==Y?typeof o.body!=Y&&o.body!=null:/loaded|complete/.test(o.readyState)}var Ut=dt();if(Ut){Ne();return}function $t(){if(!Ut){if(!dt())return;Ut=!0,Ne(),o.removeEventListener&&o.removeEventListener(Z,$t,!1),kt&&clearInterval(kt)}}o.addEventListener&&o.addEventListener(Z,$t,!1);var kt=setInterval(function(){$t()},$)}function De(Ne){var dt=u(),Ut=dt.body,$t=dt.createElement(_);$t.language=ab,$t.crossOrigin=W,$t.src=Ne,webModule.__errFn&&($t.onerror=function(){webModule.__errFn(L,new Error(bb+Ne))}),Ut.appendChild($t)}li(function(){De(jn)})}webModule.__startLoadingFragment=function(jn){return C(jn)},webModule.__installRunAsyncCode=function(jn){var li=u(),De=li.body,Ne=li.createElement(_);Ne.language=ab,Ne.text=jn,De.appendChild(Ne),De.removeChild(Ne)};function A(){for(var c={},d,e,f=o.getElementsByTagName(fb),g=O,h=f.length;g<h;++g){var i=f[g],j=i.getAttribute(gb),k;if(j){if(j=j.replace(hb,W),j.indexOf(ib)>=O)continue;if(j==jb){if(k=i.getAttribute(kb),k){var l,m=k.indexOf(lb);m>=O?(j=k.substring(O,m),l=k.substring(m+P)):(j=k,l=W),c[j]=l}}else if(j==mb){if(k=i.getAttribute(kb),k)try{d=eval(k)}catch(jn){alert(nb+k+ob)}}else if(j==pb&&(k=i.getAttribute(kb),k))try{e=eval(k)}catch(jn){alert(nb+k+qb)}}}__gwt_getMetaProperty=function(jn){var li=c[jn];return li==null?null:li},r=d,webModule.__errFn=e}function B(){function jn(kt){var Ie=kt.lastIndexOf(rb);Ie==-1&&(Ie=kt.length);var $e=kt.indexOf(sb);$e==-1&&($e=kt.length);var Mt=kt.lastIndexOf(tb,Math.min($e,Ie));return Mt>=O?kt.substring(O,Mt+P):W}function li(kt){if(!kt.match(/^\w+:\/\//)){var Ie=o.createElement(ub);Ie.src=kt+vb,kt=jn(Ie.src)}return kt}function De(){var kt=__gwt_getMetaProperty(wb);return kt!=null?kt:W}function Ne(){for(var kt=o.getElementsByTagName(_),Ie=O;Ie<kt.length;++Ie)if(kt[Ie].src.indexOf(xb)!=-1)return jn(kt[Ie].src);return W}function dt(){var kt=o.getElementsByTagName(yb);return kt.length>O?kt[kt.length-P].href:W}function Ut(){var kt=o.location;return kt.href==kt.protocol+zb+kt.host+kt.pathname+kt.search+kt.hash}var $t=De();return $t==W&&($t=Ne()),$t==W&&($t=dt()),$t==W&&Ut()&&($t=jn(o.location.href)),$t=li($t),$t}function C(jn){return jn.match(/^\//)||jn.match(/^[a-zA-Z]+:\/\//)?jn:webModule.__moduleBase+jn}function D(){var jn=[],li=O,De=[],Ne=[];function dt(kt){var Ie=Ne[kt](),$e=De[kt];if(Ie in $e)return Ie;var Mt=[];for(var Pt in $e)Mt[$e[Pt]]=Pt;throw r&&r(kt,Mt,Ie),null}if(__gwt_isKnownPropertyValue=function(kt,Ie){return Ie in De[kt]},webModule.__getPropMap=function(){var kt={};for(var Ie in De)De.hasOwnProperty(Ie)&&(kt[Ie]=dt(Ie));return kt},webModule.__computePropValue=dt,n.__gwt_activeModules[L].bindings=webModule.__getPropMap,p())return C(Bb);var Ut;try{Ut=Cb;var $t=Ut.indexOf(Db);$t!=-1&&(li=parseInt(Ut.substring($t+P),$),Ut=Ut.substring(O,$t))}catch(kt){}return webModule.__softPermutationId=li,C(Ut+Eb)}function F(){n.__gwt_stylesLoaded||(n.__gwt_stylesLoaded={})}A(),webModule.__moduleBase="/js/mathematicalGraphics/"+name+"/",s[L].moduleBase=webModule.__moduleBase;var G=D();return F(),w(G),!0}return webModule},typeof window.web3d!="function"&&(window.web3d=GGBAppletUtils.makeModule("web3d","A18F540516513B1292CA7CEF2F6AFC7E")),typeof window.webSimple!="function"&&(window.webSimple=GGBAppletUtils.makeModule("webSimple","96B09BF1B436BF53F0DF54116700F16A")),window.GGBApplet=GGBApplet})()},15476:function(jn,li,De){"use strict";De.d(li,{Ax:function(){return $t},Ds:function(){return kt},KI:function(){return $e},SI:function(){return Ut},f1:function(){return dt}});var Ne=De(11320);function dt(Mt){let Pt=!0;if(Mt.length>0){for(let wt=0;wt<Mt.length;wt++)if(Mt[wt].compile_success==0||!Mt[wt].compile_success){Pt=!1;break}}else Pt=!1;return Pt}function Ut(Mt,Pt=""){let wt=[];for(let Qt=0;Qt<Mt.length;Qt++){let It=Mt[Qt],sn=Pt?`${Pt}/${It.name}`:`${It.name}`;wt.push({title:It.name,type:It.type,isLeaf:It.type!=="tree",key:sn})}return wt}function $t(Mt,Pt,wt){for(let Qt=0;Qt<Mt.length;Qt++){let It=Mt[Qt];if(It.key===Pt){It.children=wt;break}It.children&&$t(It.children,Pt,wt)}return Mt}function kt(Mt,Pt,wt){let Qt;return function(){let It=this,sn=arguments,Re=function(){Qt=null,wt||Mt.apply(It,sn)},ne=wt&&!Qt;clearTimeout(Qt),Qt=setTimeout(Re,Pt),ne&&Mt.apply(It,sn)}}const Ie=!0,$e=Ne.Z.API_SERVER},63205:function(jn,li,De){"use strict";De.d(li,{Z:function(){return Qt}});var Ne=De(67294),dt={imageDimensions:"imageDimensions___a7crR",img:"img___Kroat",fullWidth:"fullWidth___c492T"},Ut=De(94184),$t=De.n(Ut),kt=De(74330),Ie=De(15979),$e=De(33170),Mt=De(28706),Pt=(It,sn,Re)=>new Promise((ne,te)=>{var he=me=>{try{pe(Re.next(me))}catch(xe){te(xe)}},le=me=>{try{pe(Re.throw(me))}catch(xe){te(xe)}},pe=me=>me.done?ne(me.value):Promise.resolve(me.value).then(he,le);pe((Re=Re.apply(It,sn)).next())}),Qt=({data:It,className:sn,fullWidth:Re,style:ne={},onClose:te,onOk:he,showFullTools:le,noAssociationId:pe})=>{const me=(0,Ne.useRef)(null),xe=(0,Ne.useRef)(null),Ee=(0,Ne.useRef)(null),Ge=(0,Ne.useRef)(null),[et,ut]=(0,Ne.useState)(!1),[st,it]=(0,Ne.useState)("\u6B63\u5728\u52A0\u8F7D\u4E2D");(0,Ne.useEffect)(()=>(Ee.current||(Ee.current=document.createElement("style"),document.head.appendChild(Ee.current)),It!=null&&It.visible?(document.body.setAttribute("data-custom","y-hidden"),Ee.current.innerHTML=" html { overflow-y: hidden; }",It!=null&&It.src&&Nt()):(document.body.removeAttribute("data-custom"),Ee.current&&(document.head.removeChild(Ee.current),Ee.current=null)),()=>{document.body.removeAttribute("data-custom"),Ee.current&&(document.head.removeChild(Ee.current),Ee.current=null)}),[It==null?void 0:It.visible]);const Nt=()=>Pt(void 0,null,function*(){ut(!0),it("\u6B63\u5728\u52A0\u8F7D\u4E2D");const Tt=yield(0,Mt.ZJ)(It==null?void 0:It.src);me.current.src="",me.current.src=Tt,me.current.onload=function(){cn()},ut(!1),it("")}),St=Tt=>Pt(void 0,null,function*(){ut(!0),it("\u6B63\u5728\u4FDD\u5B58\u4E2D");const hi=yield(0,$e.ZP)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:It.title,file:Tt.dataUrl}});hi!=null&&hi.id&&!pe?(yield(0,$e.ZP)(`/api/attachments/${It.id}/add_subitem.json`,{method:"post",body:{subitem_id:hi==null?void 0:hi.id,settings:JSON.stringify(Tt.state)}})).status===0&&he():hi!=null&&hi.id&&he(hi),ut(!1),it("")}),Ft=()=>{const Tt=document.querySelector('a[href="https://markerjs.com/"]');Tt&&Tt.parentNode&&(Tt.parentNode.style.display="none"),[{name:'[data-action="select"]',title:"\u9009\u62E9"},{name:'[data-action="delete"]',title:"\u5220\u9664\u5143\u7D20"},{name:'[data-action="undo"]',title:"\u64A4\u9500"},{name:'[data-type-name="FrameMarker"]',title:"\u77E9\u5F62"},{name:'[data-type-name="FreehandMarker"]',title:"\u753B\u7EBF"},{name:'[data-type-name="ArrowMarker"]',title:"\u7BAD\u5934"},{name:'[data-type-name="TextMarker"]',title:"\u6587\u672C"},{name:'[data-type-name="EllipseMarker"]',title:"\u692D\u5706"},{name:'[data-type-name="HighlightMarker"]',title:"\u65B9\u5757"},{name:'[data-type-name="CalloutMarker"]',title:"\u6CE8\u91CA"},{name:'[data-action="render"]',title:"\u4FDD\u5B58"},{name:'[data-action="close"]',title:"\u9000\u51FA"}].forEach(di=>{const zn=document.querySelector(di.name);zn&&zn.setAttribute("title",di.title)})},cn=()=>{xe.current=new Ie.hP(me.current),xe.current.targetRoot=Ge.current,xe.current.addEventListener("render",St),xe.current.addEventListener("beforeclose",te),le&&(xe.current.availableMarkerTypes=xe.current.ALL_MARKER_TYPES,xe.current.uiStyleSettings.redoButtonVisible=!0,xe.current.uiStyleSettings.notesButtonVisible=!0,xe.current.uiStyleSettings.zoomButtonVisible=!0,xe.current.uiStyleSettings.zoomOutButtonVisible=!0,xe.current.uiStyleSettings.clearButtonVisible=!0),window.markerArea=xe.current.uiStyleSettings,xe.current.show(),It!=null&&It.snapshotData&&xe.current.restoreState(It.snapshotData),setTimeout(()=>{window.scrollTo(0,0),Ft()},300)};return Ne.createElement(Ne.Fragment,null,(It==null?void 0:It.visible)&&Ne.createElement(kt.Z,{spinning:et,tip:st,style:{position:"absolute",width:"100vw"}},Ne.createElement("div",{ref:Ge,className:$t()(dt.imageDimensions,sn,Re?dt.fullWidth:""),style:ne},Ne.createElement("img",{className:dt.img,ref:me}))))}},36527:function(jn,li,De){"use strict";var Ne=De(67294),dt=De(71230),Ut=De(15746),$t=De(55238),kt=De(85804),Ie=De(65226),$e=De(71736),Mt=De(84279),Pt=De(67294);const wt=(0,Ne.forwardRef)(({callback:Qt,showSaveButton:It,value:sn=""},Re)=>{const ne=(0,Ne.useRef)(),te=[{name:"\u5206\u6570\u5F97\u5206",value:"\\frac{x}{y}",children:[{name:"\u5206\u6570 Fractions",data:[{value:"\\frac{a}{b}"},{value:"x\\tfrac{x}{a} "},{value:"\\mathrm{d}t"},{value:"\\partial t"},{value:"\\frac{\\partial y}{\\partial x}"},{value:"\\nabla\\psi"},{value:"\\frac{\\partial^2}{\\partial x_1\\partial x_2}y"},{value:"\\cfrac{1}{a + \\cfrac{7}{b + \\cfrac{2}{9}}} = c"}]},{name:"\u5BFC\u6570 Derivative",data:[{value:"\\dot{a} "},{value:"\\ddot{a}"},{value:"{f}^{\\prime}"},{value:"{f}^{\\prime\\prime}"},{value:"{f}^{(n)}"}]},{name:"\u6A21\u7B97\u672F Modular arithmetic",data:[{value:"a \\bmod b"},{value:"a \\equiv b \\pmod{m} "},{value:"\\gcd(m, n) "},{value:"\\operatorname{lcm}(m, n) "}]}]},{name:"\u6839\u5F0F\u89D2\u6807",value:"\\sqrt{x}",children:[{name:"\u6839\u5F0F Radicals",data:[{value:"\\sqrt{x}"},{value:"\\sqrt[y]{x}"}]},{name:"\u4E0A\u4E0B\u6807 Sub&Super",data:[{value:"x^{a}"},{value:"x_{a}"},{value:"x_{a}^{b} "},{value:"_{a}^{b} x"},{value:"x_{a}^{b} "}]},{name:"\u91CD\u97F3\u7B26\u53CA\u5176\u4ED6 Accents and Others",data:[{value:"\\hat{a} "},{value:"\\sqrt[y]{x}"},{value:"\\check{} "},{value:"\\grave{a} "},{value:"\\acute{a}"},{value:"\\tilde{a}"},{value:"\\breve{a}"},{value:"\\bar{a}"},{value:"\\vec{a}"},{value:"\\not{a}"},{value:"\\widetilde{abc}"},{value:"\\widehat{abc}"},{value:"\\overleftarrow{abc} "},{value:"\\overrightarrow{abc}"},{value:"\\overline{abc}"},{value:"\\underline{abc}"},{value:"\\overbrace{abc}"},{value:"\\underbrace{abc}"},{value:"\\overset{a}{abc}"},{value:"\\underset{a}{abc} \\stackrel\\frown{ab}"},{value:"\\overline{ab} "},{value:"\\overleftrightarrow{ab}"},{value:"\\overset{a}{\\leftarrow}"},{value:"\\overset{a}{\\rightarrow}"},{value:"\\xleftarrow[abc]{a}"},{value:"\\xrightarrow[abc]{a} "}]}]},{name:"\u6781\u9650\u5BF9\u6570",value:"\\lim_{x \\to 0}",children:[{name:"\u6781\u9650 Limits",data:[{value:"\\lim a"},{value:"\\lim_{x \\to 0}"},{value:"\\lim_{x \\to \\infty}"},{value:"\\max_b{a}"},{value:"\\min_a{b}"}]},{name:"\u5BF9\u6570\u6307\u6570 Logarithms and exponentials",data:[{value:"\\log_{a}{b}"},{value:"\\lg_{a}{b}"},{value:"\\ln_{a}{b}"},{value:"\\exp a"}]},{name:"\u754C\u9650 Bounds",data:[{value:"\\min x"},{value:"\\sup t"},{value:"\\inf s"},{value:"\\lim u"},{value:"\\limsup w"},{value:"\\dim p"},{value:"\\ker\\phi "}]}]},{name:"\u4E09\u89D2\u51FD\u6570",value:"\\sin a",children:[{name:"\u4E09\u89D2\u51FD\u6570 Trigonometric functions",data:[{value:"\\sin a"},{value:"\\cos a"},{value:"\\tan a"},{value:"\\cot a "},{value:"\\sec a "},{value:"\\csc a "}]},{name:"\u53CD\u4E09\u89D2\u51FD\u6570 Inverse trigonometric functions",data:[{value:"\\sin^{-1}"},{value:"\\cos^{-1}"},{value:"\\tan^{-1}"},{value:"\\cot^{-1}"},{value:"\\sec^{-1}"},{value:"\\csc^{-1}"},{value:"\\arcsin a"},{value:"\\arccos a"},{value:"\\arctan a"},{value:"\\operatorname{arccot} a"},{value:"\\operatorname{arcsec} a"},{value:"\\operatorname{arccsc} a"}]},{name:"\u53CC\u66F2\u51FD\u6570 Hyperblic functions",data:[{value:"\\sinh a"},{value:"\\cosh a"},{value:"\\tanh a"},{value:"\\coth a"},{value:"\\operatorname{sech} a"},{value:"\\operatorname{csch} a"}]},{name:"\u53CD\u53CC\u66F2\u51FD\u6570 Inverse hyperbolic functions",data:[{value:"\\sinh^{-1}"},{value:"a\\cosh^{-1} a"},{value:"\\tanh^{-1} a"},{value:"\\coth^{-1} a"},{value:"\\operatorname{sech}^{-1} a"},{value:"\\operatorname{csch}^{-1} a"}]}]},{name:"\u79EF\u5206\u8FD0\u7B97",value:"\\int_{a}^{b}",children:[{name:"\u79EF\u5206 Integral",data:[{value:"\\int"},{value:"\\int_{a}^{b}"},{value:"\\int\\limits_{a}^{b}"}]},{name:"\u53CC\u91CD\u79EF\u5206 Double integral",data:[{value:"\\iint"},{value:"\\iint_{a}^{b} "},{value:"\\iint\\limits_{a}^{b} "}]},{name:"\u4E09\u91CD\u79EF\u5206 Triple integral",data:[{value:"\\iiint"},{value:"\\iiint_{a}^{b}"},{value:"\\iiint\\limits_{a}^{b} "}]},{name:"\u66F2\u7EBF\u79EF\u5206 Closed line or path integral",data:[{value:"\\oint"},{value:"\\oint_{a}^{b} "}]}]},{name:"\u5927\u578B\u8FD0\u7B97",value:"\\sum_{a}^{b}",children:[{name:"\u6C42\u548C Summation",data:[{value:"\\sum"},{value:"\\sum_{a}^{b}"},{value:"{\\textstyle \\sum_{a}^{b}} "}]},{name:"\u4E58\u79EF\u4F59\u79EF Product and coproduct",data:[{value:"\\prod"},{value:"\\prod_{a}^{b}"},{value:"{\\textstyle \\prod_{a}^{b}}"},{value:"\\coprod"},{value:"\\coprod_{a}^{b}"},{value:"{\\textstyle \\coprod_{a}^{b}} "}]},{name:"\u5E76\u96C6\u4EA4\u96C6 Union and intersection",data:[{value:"\\bigcup"},{value:"\\bigcup_{a}^{b}"},{value:"{\\textstyle \\bigcup_{a}^{b}}"},{value:"\\bigcap"},{value:"\\bigcap_{a}^{b}"}]},{name:"\u6790\u53D6\u5408\u53D6 Disjunction and conjunction",data:[{value:"\\bigvee"},{value:"\\bigvee_{a}^{b}"},{value:"\\bigwedge"},{value:"\\bigwedge_{a}^{b}"}]}]},{name:"\u62EC\u53F7\u53D6\u6574",value:"\\left [ \\left ( \\right ) \\right ] ",children:[{name:"\u62EC\u53F7 Brackets",data:[{value:"\\left ( \\right )"},{value:"\\left [ \\right ]"},{value:"\\left \\langle \\right \\rangle "},{value:"\\left | \\right | "},{value:"\\left \\lfloor \\right \\rfloor "},{value:"\\left \\lceil \\right \\rceil "}]}]}],he=[{name:"\u4EE3\u6570",value:"\\sqrt{a^2+b^2}",children:[{data:[{value:"\\left(x-1\\right)\\left(x+3\\right) "},{value:"\\sqrt{a^2+b^2}"},{value:"\\left ( \\frac{a}{b}\\right )^{n}= \\frac{a^{n}}{b^{n}}"},{value:"\\frac{a}{b}\\pm \\frac{c}{d}= \\frac{ad \\pm bc}{bd} "},{value:"\\frac{x^{2}}{a^{2}}-\\frac{y^{2}}{b^{2}}=1 "},{value:"\\frac{1}{\\sqrt{a}}=\\frac{\\sqrt{a}}{a},a\\ge 0\\frac{1}{\\sqrt{a}}=\\frac{\\sqrt{a}}{a},a\\ge 0 "},{value:"\\sqrt[n]{a^{n}}=\\left ( \\sqrt[n]{a}\\right )^{n} "},{value:"x ={-b \\pm \\sqrt{b^2-4ac}\\over 2a} "},{value:"y-y_{1}=k \\left( x-x_{1}\\right) "},{value:`\\left\\{\\begin{matrix} \r
x=a + r\\text{cos}\\theta \\ \r
y=b + r\\text{sin}\\theta \r
\\end{matrix}\\right. `},{value:`\\begin{array}{l} \r
\\text{\u5BF9\u4E8E\u65B9\u7A0B\u5F62\u5982\uFF1A}x^{3}-1=0 \\ \r
\\text{\u8BBE}\\text{:}\\omega =\\frac{-1+\\sqrt{3}i}{2} \\ \r
x_{1}=1,x_{2}= \\omega =\\frac{-1+\\sqrt{3}i}{2} \\ \r
x_{3}= \\omega ^{2}=\\frac{-1-\\sqrt{3}i}{2} \r
\\end{array} `},{value:`\\begin{array}{l} \r
a\\mathop{{x}}\\nolimits^{{2}}+bx+c=0 \\ \r
\\Delta =\\mathop{{b}}\\nolimits^{{2}}-4ac \\ \r
\\left\\{\\begin{matrix} \r
\\Delta \\gt 0\\text{\u65B9\u7A0B\u6709\u4E24\u4E2A\u4E0D\u76F8\u7B49\u7684\u5B9E\u6839} \\ \r
\\Delta = 0\\text{\u65B9\u7A0B\u6709\u4E24\u4E2A\u76F8\u7B49\u7684\u5B9E\u6839} \\ \r
\\Delta \\lt 0\\text{\u65B9\u7A0B\u65E0\u5B9E\u6839} \r
\\end{matrix}\\right. \r
\\end{array} `},{value:`\\begin{array}{l} \r
a\\mathop{{x}}\\nolimits^{{2}}+bx+c=0 \\ \r
\\Delta =\\mathop{{b}}\\nolimits^{{2}}-4ac \\ \r
\\mathop{{x}}\\nolimits_{{1,2}}=\\frac{{-b \\pm \r
\\sqrt{{\\mathop{{b}}\\nolimits^{{2}}-4ac}}}}{{2a}} \\ \r
\\mathop{{x}}\\nolimits_{{1}}+\\mathop{{x}}\\nolimits_{{2}}=-\\frac{{b}}{{a}} \\ \r
\\mathop{{x}}\\nolimits_{{1}}\\mathop{{x}}\\nolimits_{{2}}=\\frac{{c}}{{a}} \r
\\end{array} `}]}]},{name:"\u51E0\u4F55",value:"\\Delta A B C ",children:[{data:[{value:"\\Delta A B C "},{value:"a \\parallel c,b \\parallel c \\Rightarrow a \\parallel b "},{value:"l \\perp \\beta ,l \\subset \\alpha \\Rightarrow \\alpha \\perp \\beta"},{value:`\\left.\\begin{matrix} \r
a \\perp \\alpha \\ \r
b \\perp \\alpha \r
\\end{matrix}\\right\\}\\Rightarrow a \\parallel b`},{value:"P \\in \\alpha ,P \\in \\beta , \\alpha \\cap \\beta =l \\Rightarrow P \\in l "},{value:`\\alpha \\perp \\beta , \\alpha \\cap \\beta =l,a \\subset \\alpha ,a \\perp l \r
\\Rightarrow a \\perp \\beta `},{value:`\\left.\\begin{matrix} \r
a \\subset \\beta ,b \\subset \\beta ,a \\cap b=P \\ \r
a \\parallel \\partial ,b \\parallel \\partial \r
\\end{matrix}\\right\\}\\Rightarrow \\beta \\parallel \\alpha `},{value:"\\alpha \\parallel \\beta , \\gamma \\cap \\alpha =a, \\gamma \\cap \\beta =b \\Rightarrow a \\parallel b "},{value:"A \\in l,B \\in l,A \\in \\alpha ,B \\in \\alpha \\Rightarrow l \\subset \\alpha "},{value:`\\left.\\begin{matrix} \r
m \\subset \\alpha ,n \\subset \\alpha ,m \\cap n=P \\ \r
a \\perp m,a \\perp n \r
\\end{matrix}\\right\\}\\Rightarrow a \\perp \\alpha `},{value:`\\begin{array}{c} \r
\\text{\u76F4\u89D2\u4E09\u89D2\u5F62\u4E2D,\u76F4\u89D2\u8FB9\u957Fa,b,\u659C\u8FB9\u8FB9\u957Fc} \\ \r
a^{2}+b^{2}=c^{2} \r
\\end{array}`}]}]},{name:"\u4E0D\u7B49\u5F0F",value:"a > b",children:[{data:[{value:"a > b,b > c \\Rightarrow a > c "},{value:"a > b,c > d \\Rightarrow a+c > b+d "},{value:"a > b > 0,c > d > 0 \\Rightarrow ac bd "},{value:`\\begin{array}{c} \r
a \\gt b,c \\gt 0 \\Rightarrow ac \\gt bc \\ \r
a \\gt b,c \\lt 0 \\Rightarrow ac \\lt bc \r
\\end{array}`},{value:"\\left | a-b \\right | \\geqslant \\left | a \\right | -\\left | b \\right | "},{value:"-\\left | a \\right |\\leq a\\leqslant \\left | a \\right | "},{value:"\\left | a \\right |\\leqslant b \\Rightarrow -b \\leqslant a \\leqslant \\left | b \\right | "},{value:"\\left | a+b \\right | \\leqslant \\left | a \\right | + \\left | b \\right | "},{value:`\\begin{array}{c} \r
a \\gt b \\gt 0,n \\in N^{\\ast},n \\gt 1 \\ \r
\\Rightarrow a^{n}\\gt b^{n}, \\sqrt[n]{a}\\gt \\sqrt[n]{b} \r
\\end{array}`},{value:`\\left( \\sum_{k=1}^n a_k b_k \\right)^{\\!\\!2}\\leq \r
\\left( \\sum_{k=1}^n a_k^2 \\right) \\left( \\sum_{k=1}^n b_k^2 \\right) `},{value:`\\begin{array}{c} \r
a,b \\in R^{+} \\ \r
\\Rightarrow \\frac{a+b}{{2}}\\ge \\sqrt{ab} \\ \r
\\left( \\text{\u5F53\u4E14\u4EC5\u5F53}a=b\\text{\u65F6\u53D6\u201C}=\\text{\u201D\u53F7}\\right) \r
\\end{array}`},{value:`\\begin{array}{c} \r
a,b \\in R \\ \r
\\Rightarrow a^{2}+b^{2}\\gt 2ab \\ \r
\\left( \\text{\u5F53\u4E14\u4EC5\u5F53}a=b\\text{\u65F6\u53D6\u201C}=\\text{\u201D\u53F7}\\right) \r
\\end{array}`},{value:`\\begin{array}{c} \r
H_{n}=\\frac{n}{\\sum \\limits_{i=1}^{n}\\frac{1}{x_{i}}}= \\frac{n}{\\frac{1}{x_{1}}+ \\frac{1}{x_{2}}+ \\cdots + \\frac{1}{x_{n}}} \\ G_{n}=\\sqrt[n]{\\prod \\limits_{i=1}^{n}x_{i}}= \\sqrt[n]{x_{1}x_{2}\\cdots x_{n}} \\ A_{n}=\\frac{1}{n}\\sum \\limits_{i=1}^{n}x_{i}=\\frac{x_{1}+ x_{2}+ \\cdots + x_{n}}{n} \\ Q_{n}=\\sqrt{\\sum \\limits_{i=1}^{n}x_{i}^{2}}= \\sqrt{\\frac{x_{1}^{2}+ x_{2}^{2}+ \\cdots + x_{n}^{2}}{n}} \\ H_{n}\\leq G_{n}\\leq A_{n}\\leq Q_{n} \r
\\end{array}`}]}]},{name:"\u79EF\u5206",value:"\\frac{\\mathrm{d}\\partial}{\\partial x}",children:[{data:[{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}x^n=nx^{n-1} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}e^{ax}=a\\,e^{ax} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\ln(x)=\\frac{1}{x} "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\sin x=\\cos x "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\cos x=-\\sin x "},{value:"\\int k\\mathrm{d}x = kx+C "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\tan x=\\sec^2 x "},{value:"\\frac{\\mathrm{d}}{\\mathrm{d}x}\\cot x=-\\csc^2 x "},{value:"\\int \\frac{1}{x}\\mathrm{d}x= \\ln \\left| x \\right| +C "},{value:"\\int \\frac{1}{\\sqrt{1-x^{2}}}\\mathrm{d}x= \\arcsin x +C "},{value:"\\int \\frac{1}{1+x^{2}}\\mathrm{d}x= \\arctan x +C "},{value:"\\int u \\frac{\\mathrm{d}v}{\\mathrm{d}x}\\,\\mathrm{d}x=uv-\\int \\frac{\\mathrm{d}u}{\\mathrm{d}x}v\\,\\mathrm{d}x "},{value:"f(x) = \\int_{-\\infty}^\\infty \\hat f(x)\\xi\\,e^{2 \\pi i \\xi x} \\,\\mathrm{d}\\xi "},{value:"\\int x^{\\mu}\\mathrm{d}x=\\frac{x^{\\mu +1}}{\\mu +1}+C, \\left({\\mu \\neq -1}\\right) "}]}]},{name:"\u4E09\u89D2",value:"e^{i \\theta}",children:[{name:"\u6C42\u548C Summation",data:[{value:"e^{i \\theta} "},{value:"\\left(\\frac{\\pi}{2}-\\theta \\right ) "},{value:"\\text{sin}^{2}\\frac{\\alpha}{2}=\\frac{1- \\text{cos}\\alpha}{2} "},{value:"\\text{cos}^{2}\\frac{\\alpha}{2}=\\frac{1+ \\text{cos}\\alpha}{2} "},{value:"\\text{tan}\\frac{\\alpha}{2}=\\frac{\\text{sin}\\alpha}{1+ \\text{cos}\\alpha} "},{value:"\\sin \\alpha + \\sin \\beta =2 \\sin \\frac{\\alpha + \\beta}{2}\\cos \\frac{\\alpha - \\beta}{2} "},{value:"\\sin \\alpha - \\sin \\beta =2 \\cos \\frac{\\alpha + \\beta}{2}\\sin \\frac{\\alpha - \\beta}{2} "},{value:"\\cos \\alpha + \\cos \\beta =2 \\cos \\frac{\\alpha + \\beta}{2}\\cos \\frac{\\alpha - \\beta}{2} "},{value:"\\cos \\alpha - \\cos \\beta =-2\\sin \\frac{\\alpha + \\beta}{2}\\sin \\frac{\\alpha - \\beta}{2} "},{value:"a^{2}=b^{2}+c^{2}-2bc\\cos A "},{value:"\\frac{\\sin A}{a}=\\frac{\\sin B}{b}=\\frac{\\sin C}{c}=\\frac{1}{2R} "},{value:"\\sin \\left ( \\frac{\\pi}{2}-\\alpha \\right ) = \\cos \\alpha "},{value:"\\sin \\left ( \\frac{\\pi}{2}+\\alpha \\right ) = \\cos \\alpha "}]}]},{name:"\u7EDF\u8BA1",value:"C_{r}^{n}",children:[{data:[{value:"C_{r}^{n} "},{value:"\\frac{n!}{r!(n-r)!} "},{value:"\\sum_{i=1}^{n}{X_i} "},{value:"\\sum_{i=1}^{n}{X_i^2} "},{value:"X_1, \\cdots,X_n "},{value:"\\frac{x-\\mu}{\\sigma} "},{value:"\\sum_{i=1}^{n}{(X_i - \\overline{X})^2} "},{value:`\\begin{array}{c} \r
\\text{\u82E5}P \\left( AB \\right) =P \\left( A \\right) P \\left( B \\right) \\\\ \r
\\text{\u5219}P \\left( A \\left| B\\right. \\right) =P \\left({B}\\right) \r
\\end{array}`},{value:"P(E) ={n \\choose k}p^k (1-p)^{n-k} "},{value:"P \\left( A \\right) = \\lim \\limits_{n \\to \\infty}f_{n}\\left ( A \\right ) "},{value:"P \\left( \\bigcup \\limits_{i=1}^{+ \\infty}A_{i}\\right) = \\prod \\limits_{i=1}^{+ \\infty}P{\\left( A_{i}\\right)} "},{value:`\\begin{array}{c} \r
P \\left( \\emptyset \\right) =0 \\\\ \r
P \\left( S \\right) =1 \r
\\end{array}`},{value:`\\begin{array}{c} \r
\\forall A \\in S \\\\ \r
P \\left( A \\right) \\ge 0 \r
\\end{array}`},{value:"P \\left( \\bigcup \\limits_{i=1}^{n}A_{i}\\right) = \\prod \\limits_{i=1}^{n}P \\left( A_{i}\\right) "},{value:`\\begin{array}{c} \r
S= \\binom{N}{n},A_{k}=\\binom{M}{k}\\cdot \\binom{N-M}{n-k} \\\\ \r
P\\left ( A_{k}\\right ) = \\frac{\\binom{M}{k}\\cdot \\binom{N-M}{n-k}}{\\binom{N}{n}} \r
\\end{array}`},{value:`\\begin{array}{c} \r
P_{n}=n! \\\\ \r
A_{n}^{k}=\\frac{n!}{\\left( n-k \\left) !\\right. \\right.} \r
\\end{array}`}]}]}],le=xe=>{ne.current.setValue(ne.current.getValue()+" "+xe.value+" ")},pe=[{key:"1",label:"\u5FEB\u6377\u6A21\u677F",children:Pt.createElement(dt.Z,{className:$e.Z.lists,gutter:[10,10]},te.map((xe,Ee)=>Pt.createElement(Ut.Z,{flex:"110px",className:$e.Z.item},Pt.createElement("div",null,Pt.createElement(Ie.Z,{value:`$$${xe.value}$$`}),xe.name),Pt.createElement("div",{className:$e.Z.children},xe.children.map((Ge,et)=>Pt.createElement("div",{key:et},Pt.createElement("h1",null,Ge.name),Pt.createElement(dt.Z,{gutter:[10,10]},Ge.data.map((ut,st)=>Pt.createElement(Ut.Z,{key:st,onClick:()=>le(ut),className:$e.Z.diamond},Pt.createElement(Ie.Z,{value:"`$$"+ut.value+"$$`"}))))))))))},{key:"2",label:"\u516C\u5F0F\u6A21\u677F",children:Pt.createElement(dt.Z,{className:$e.Z.lists,gutter:[10,10]},he.map((xe,Ee)=>Pt.createElement(Ut.Z,{flex:"110px",className:$e.Z.item},Pt.createElement("div",null,Pt.createElement(Ie.Z,{value:"`$$"+xe.value+"$$`"}),xe.name),Pt.createElement("div",{className:$e.Z.children},xe.children.map((Ge,et)=>Pt.createElement("div",{key:et},Ge.name&&Pt.createElement("h1",null,Ge.name),Pt.createElement(dt.Z,{gutter:[10,10]},Ge.data.map((ut,st)=>Pt.createElement(Ut.Z,{key:st,onClick:()=>le(ut),className:$e.Z.diamond},Pt.createElement(Ie.Z,{value:"`$$"+ut.value+"$$`"}))))))))))}],me=()=>{var xe=document.createElement("div");xe.innerHTML=ne.current.getValue();var Ee=xe.innerText;return Qt&&Qt(Ee),Ee};return(0,Ne.useImperativeHandle)(Re,()=>({getData:me})),Pt.createElement("div",{className:$e.Z.mathWrap},Pt.createElement($t.default,{defaultActiveKey:"1",items:pe}),Pt.createElement("math-field",{locale:"zh_cn",className:$e.Z.mathField,placeholder:"\u8BF7\u6253\u5F00\u952E\u76D8\uFF0C\u8F93\u5165\u516C\u5F0F",ref:ne,style:{width:800,marginTop:30,fontSize:18}},sn||""),It&&Pt.createElement("div",{className:$e.Z.button},Pt.createElement(kt.ZP,{size:"large",onClick:me,style:{zIndex:8,marginTop:10},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668")))});li.Z=wt},65866:function(jn,li,De){"use strict";De.d(li,{z:function(){return Dn},Z:function(){return nt}});var Ne=De(67294),dt=De(35059),Ut=De(2453),$t=De(62844),kt=De(85804),Ie=De(11320),$e=De(4440),Mt=Object.defineProperty,Pt=Object.getOwnPropertySymbols,wt=Object.prototype.hasOwnProperty,Qt=Object.prototype.propertyIsEnumerable,It=(ze,ke,Wt)=>ke in ze?Mt(ze,ke,{enumerable:!0,configurable:!0,writable:!0,value:Wt}):ze[ke]=Wt,sn=(ze,ke)=>{for(var Wt in ke||(ke={}))wt.call(ke,Wt)&&It(ze,Wt,ke[Wt]);if(Pt)for(var Wt of Pt(ke))Qt.call(ke,Wt)&&It(ze,Wt,ke[Wt]);return ze},Re=(ze,ke,Wt)=>new Promise((On,Lt)=>{var xn=Ot=>{try{Xn(Wt.next(Ot))}catch(ft){Lt(ft)}},vn=Ot=>{try{Xn(Wt.throw(Ot))}catch(ft){Lt(ft)}},Xn=Ot=>Ot.done?On(Ot.value):Promise.resolve(Ot.value).then(xn,vn);Xn((Wt=Wt.apply(ze,ke)).next())});const ne="\u3000\u3000";function te(ze){var ke=["Bytes","KB","MB","GB","TB"];if(ze==0)return"0 Byte";var Wt=parseInt(""+Math.floor(Math.log(ze)/Math.log(1024)),10);return(ze/Math.pow(1024,Wt)).toFixed(1)+" "+ke[Wt]}var he=({value:ze=[],action:ke,onChange:Wt,className:On,maxSize:Lt=150,title:xn="\u6587\u4EF6\u4E0A\u4F20",accept:vn=null})=>{const Xn={multiple:!1,fileList:ze,accept:vn,withCredentials:!0,beforeUpload:ft=>ft.size/1024/1024<Lt?!0:(message.error(`\u8BE5\u6587\u4EF6\u65E0\u6CD5\u4E0A\u4F20\u3002\u8D85\u8FC7\u6587\u4EF6\u5927\u5C0F\u9650\u5236(${Lt}MB),\u5EFA\u8BAE\u4E0A\u4F20\u5230\u767E\u5EA6\u4E91\u7B49\u5176\u5B83\u5171\u4EAB\u5DE5\u5177\u91CC\uFF0C\u7136\u540E\u518Dtxt\u6587\u6863\u91CC\u7ED9\u51FA\u94FE\u63A5\u4EE5\u53CA\u5171\u4EAB\u5BC6\u7801\u5E76\u4E0A\u4F20`),Promise.reject()),action:`${ENV.API_SERVER}/api/attachments.json`,onChange(ft){var Gt,an,Jt,Ve;let be=[...ft.fileList];if(be=be.map(Pe=>(Pe.name.indexOf(ne)===-1&&(Pe.name=`${Pe.name}${ne}${te(Pe.size)}`),sn({},Pe))),ft.file.status==="done"&&((an=(Gt=ft.file)==null?void 0:Gt.response)==null?void 0:an.status)===-1){message.error((Ve=(Jt=ft.file)==null?void 0:Jt.response)==null?void 0:Ve.message),Wt([]);return}Wt(be)},onRemove:ft=>Re(void 0,null,function*(){const Gt=ft.size/1024/1024;return ft.status==="uploading"?!0:Gt<Lt&&(ft.response?ft.response.id:ft.uid)?yield removeAttachment(ft.response?ft.response.id:ft.id):!0})};function Ot(ft){ft.preventDefault(),ft.stopPropagation()}return React.createElement("div",{className:`single-upload ${On||""}`},React.createElement(Upload,sn({},Xn),React.createElement(Button,{type:"primary",title:ze.length>0?"\u6BCF\u6B21\u53EA\u80FD\u4E0A\u4F20\u4E00\u4E2A\u8D44\u6E90\uFF0C \u5220\u9664\u4E0B\u9762\u8D44\u6E90\u53EF\u91CD\u65B0\u4E0A\u4F20 ":"",disabled:ze.length>0,ghost:!0},xn),React.createElement("span",{onClick:Ot,style:{marginLeft:10}},"(\u5355\u4E2A\u6587\u4EF6\u6700\u5927",Lt,"M)"," ")))},le=De(33859),pe=De(96486),me=Object.defineProperty,xe=Object.getOwnPropertySymbols,Ee=Object.prototype.hasOwnProperty,Ge=Object.prototype.propertyIsEnumerable,et=(ze,ke,Wt)=>ke in ze?me(ze,ke,{enumerable:!0,configurable:!0,writable:!0,value:Wt}):ze[ke]=Wt,ut=(ze,ke)=>{for(var Wt in ke||(ke={}))Ee.call(ke,Wt)&&et(ze,Wt,ke[Wt]);if(xe)for(var Wt of xe(ke))Ge.call(ke,Wt)&&et(ze,Wt,ke[Wt]);return ze};const st=ze=>React.createElement("svg",ut({width:14,height:14,xmlns:"http://www.w3.org/2000/svg"},ze),React.createElement("title",null,"\u5F62\u72B6"),React.createElement("path",{d:"M10.354 3.5h-2.77v8.167H6.416V3.5H3.646L7 0l3.354 3.5ZM14 7h-1.167v5.833H1.167V7H0v7h14V7Z",fill:"#3061D0",fillRule:"nonzero"}));var it="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTQiIGhlaWdodD0iMTQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEwLjM1NCAzLjVoLTIuNzd2OC4xNjdINi40MTZWMy41SDMuNjQ2TDcgMGwzLjM1NCAzLjVaTTE0IDdoLTEuMTY3djUuODMzSDEuMTY3VjdIMHY3aDE0VjdaIiBmaWxsPSIjMzA2MUQwIiBmaWxsLXJ1bGU9Im5vbnplcm8iLz48L3N2Zz4=",Nt=Object.defineProperty,St=Object.getOwnPropertySymbols,Ft=Object.prototype.hasOwnProperty,cn=Object.prototype.propertyIsEnumerable,Tt=(ze,ke,Wt)=>ke in ze?Nt(ze,ke,{enumerable:!0,configurable:!0,writable:!0,value:Wt}):ze[ke]=Wt,hi=(ze,ke)=>{for(var Wt in ke||(ke={}))Ft.call(ke,Wt)&&Tt(ze,Wt,ke[Wt]);if(St)for(var Wt of St(ke))cn.call(ke,Wt)&&Tt(ze,Wt,ke[Wt]);return ze},di=(ze,ke,Wt)=>new Promise((On,Lt)=>{var xn=Ot=>{try{Xn(Wt.next(Ot))}catch(ft){Lt(ft)}},vn=Ot=>{try{Xn(Wt.throw(Ot))}catch(ft){Lt(ft)}},Xn=Ot=>Ot.done?On(Ot.value):Promise.resolve(Ot.value).then(xn,vn);Xn((Wt=Wt.apply(ze,ke)).next())});const{Dragger:zn}=dt.default;function Dn(ze){let ke=[];return ze&&ze.length>0&&(ke=ze.map(Wt=>({uid:Wt.id,id:Wt.id,name:Wt.title+ne+Wt.filesize,url:Wt.url,filesize:Wt.filesize,status:"done",response:{id:Wt.id}}))),ke}var nt=({value:ze,onChange:ke,action:Wt,data:On,className:Lt,maxSize:xn=150,title:vn="\u4E0A\u4F20\u9644\u4EF6",showRemoveModal:Xn=!1,accept:Ot="",additionalText:ft,isDragger:Gt,number:an=1e3,aloneClear:Jt=!1,realTimeRemove:Ve=!0,uploadText:be,setFileProgress:Pe,showFileProgress:Be})=>{const[Ze,Fe]=(0,Ne.useState)(!1);let[qe,dn]=(0,Ne.useState)(ze||[]),[ui,$n]=(0,Ne.useState)(1);(0,Ne.useEffect)(()=>{ze&&(ui===1&&dn([...ze]),$n(2),an===(ze==null?void 0:ze.length)&&Fe(!0))},[ze]);const rn=()=>{setTimeout(()=>{qe.pop(),dn([...qe])},500)};Be&&Pe(qe.some(_n=>_n.status==="uploading"));const Hn={multiple:!0,disabled:Ze,accept:Ot,withCredentials:!0,fileList:qe,beforeUpload:(_n,ti)=>{const Ri=_n.size/1024/1024;return qe.concat(ti).length>an?(qe.pop(),dn([...qe]),Ut.ZP.error(`\u6700\u591A\u53EA\u80FD\u4E0A\u4F20${an}\u4E2A\u6587\u4EF6`),Jt?Promise.reject():(rn(),!1)):Ri<xn?!0:(Ut.ZP.error(`\u8BE5\u6587\u4EF6\u65E0\u6CD5\u4E0A\u4F20\u3002\u8D85\u8FC7\u6587\u4EF6\u5927\u5C0F\u9650\u5236(${xn}MB).`),Jt?Promise.reject():(rn(),!1))},data:On,action:Wt||`${Ie.Z.API_SERVER}/api/attachments.json`,onChange(_n){var ti,Ri,oi,wr;if(_n.file.status==="removed"?qe=_n.fileList:qe=(0,pe.uniqBy)([..._n.fileList,...qe],"uid"),_n.file.status==="done"&&((Ri=(ti=_n.file)==null?void 0:ti.response)==null?void 0:Ri.status)===-1){Ut.ZP.error((wr=(oi=_n.file)==null?void 0:oi.response)==null?void 0:wr.message);return}qe.length>=an?Fe(!0):Fe(!1),dn([...qe]),qe=qe.map(fr=>{var Ei,Di;return(Ei=fr==null?void 0:fr.response)!=null&&Ei.id&&(fr.url=(Di=fr==null?void 0:fr.response)==null?void 0:Di.url),fr.name.indexOf(ne)===-1&&(fr.name=`${fr.name}${ne}${te(fr.size)}`),hi({},fr)}),console.log("info:",_n,qe),ke(qe)},onRemove:_n=>di(void 0,null,function*(){if(!Ve)return!0;const ti=()=>di(void 0,null,function*(){if(_n.response?_n.response.id:_n.id){let oi=yield(0,$e.JZ)(_n.response?_n.response.id:_n.uid);return Promise.resolve(oi)}else return!0});return Xn?new Promise((Ri,oi)=>{$t.default.confirm({centered:!0,width:530,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u63D0\u793A",content:Ne.createElement("div",{className:"tc font16"},"\u662F\u5426\u786E\u8BA4\u5220\u9664?"),onOk:()=>di(void 0,null,function*(){const wr=yield ti();Ut.ZP.success("\u5220\u9664\u6210\u529F"),Ri(!0)}),onCancel:()=>Ri(!1)})}):yield ti()})};function Zt(_n){_n.preventDefault(),_n.stopPropagation()}return Ne.createElement("div",{className:`multi-upload ${Lt||""}`},Gt&&Ne.createElement(zn,hi({},Hn),Ne.createElement("p",{className:"ant-upload-drag-icon"},Ne.createElement(le.Z,null)),Ne.createElement("p",{className:"ant-upload-text"},"\u70B9\u51FB\u4E0A\u4F20\u56FE\u6807\uFF0C\u9009\u62E9\u8981\u4E0A\u4F20\u7684\u6587\u4EF6\u6216\u5C06\u6587\u4EF6\u62D6\u62FD\u5230\u6B64",Ne.createElement("br",null),"(\u5355\u4E2A\u6587\u4EF6\u6700\u5927\u9650\u5236\u4E3A",xn,"MB)"," "),ft),!Gt&&Ne.createElement(dt.default,hi({},Hn),Ne.createElement(kt.ZP,{disabled:Ze,className:"upload_button"},Ne.createElement("img",{className:"aBtn_img",src:it}),vn),Ne.createElement("span",{onClick:Zt,className:"upload_text"},be||`(\u5355\u4E2A\u6587\u4EF6\u6700\u5927${xn}MB)`)))}},26194:function(jn,li,De){"use strict";var Ne=De(67294),dt=De(4977),Ut=De(85804),$t=Object.defineProperty,kt=Object.defineProperties,Ie=Object.getOwnPropertyDescriptors,$e=Object.getOwnPropertySymbols,Mt=Object.prototype.hasOwnProperty,Pt=Object.prototype.propertyIsEnumerable,wt=(Re,ne,te)=>ne in Re?$t(Re,ne,{enumerable:!0,configurable:!0,writable:!0,value:te}):Re[ne]=te,Qt=(Re,ne)=>{for(var te in ne||(ne={}))Mt.call(ne,te)&&wt(Re,te,ne[te]);if($e)for(var te of $e(ne))Pt.call(ne,te)&&wt(Re,te,ne[te]);return Re},It=(Re,ne)=>kt(Re,Ie(ne));const sn=({img:Re,buttonProps:ne={},styles:te={},customText:he,ButtonText:le,ButtonClick:pe,Buttonclass:me,ButtonTwo:xe,imgStyles:Ee,loading:Ge=!1,className:et=""})=>Ne.createElement("section",{className:`tc animated fadeIn ${et}`,style:Qt({color:"#999",margin:"100px auto",visibility:Ge?"hidden":"visible"},te)},Ne.createElement("img",{src:Re||dt,style:It(Qt({},Ee),{pointerEvents:"none",userSelect:"none"})}),Ne.createElement("p",{className:"mt20 font14"},he||"\u6682\u65F6\u8FD8\u6CA1\u6709\u76F8\u5173\u6570\u636E\u54E6!"),le&&Ne.createElement(Ut.ZP,Qt({className:me,onClick:pe},ne),le),xe&&xe);li.Z=sn},20819:function(jn,li,De){"use strict";De.d(li,{Z:function(){return me}});var Ne=De(67294),dt={wrp:"wrp___dq7YK",bgBlack:"bgBlack___ARIUV",monaco:"monaco___VnZC3",darkBlue:"darkBlue___UprA9",close:"close___LKoWu",embed:"embed___hvpEJ"},Ut=De(85804),$t=De(30153),kt=De(36295),Ie=De(83062),$e=De(28706),Mt=De(15835),Pt=De(26194),wt=De(11320),Qt=De(66540),It=De(67294),sn=Object.defineProperty,Re=Object.getOwnPropertySymbols,ne=Object.prototype.hasOwnProperty,te=Object.prototype.propertyIsEnumerable,he=(xe,Ee,Ge)=>Ee in xe?sn(xe,Ee,{enumerable:!0,configurable:!0,writable:!0,value:Ge}):xe[Ee]=Ge,le=(xe,Ee)=>{for(var Ge in Ee||(Ee={}))ne.call(Ee,Ge)&&he(xe,Ge,Ee[Ge]);if(Re)for(var Ge of Re(Ee))te.call(Ee,Ge)&&he(xe,Ge,Ee[Ge]);return xe},pe=(xe,Ee,Ge)=>new Promise((et,ut)=>{var st=St=>{try{Nt(Ge.next(St))}catch(Ft){ut(Ft)}},it=St=>{try{Nt(Ge.throw(St))}catch(Ft){ut(Ft)}},Nt=St=>St.done?et(St.value):Promise.resolve(St.value).then(st,it);Nt((Ge=Ge.apply(xe,Ee)).next())}),me=({editOffice:xe="view",data:Ee,issaver:Ge,onSaver:et,theme:ut,type:st,filename:it,monacoEditor:Nt,className:St,style:Ft,close:cn,onClose:Tt,hasMask:hi,disabledDownload:di,onImgDimensions:zn,showNodata:Dn,recordInfo:nt})=>{const[ze,ke]=(0,Ne.useState)("https://view.officeapps.live.com/op/view.aspx?src=http://testgs.educoder.net//rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBCZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--03541f6234b93d7ac3b2d84e7eb0e6594a952945/1.ppt"),[Wt,On]=(0,Ne.useState)(""),[Lt,xn]=(0,Ne.useState)(),vn=window.ENV==="build"?"/react/build":"",Xn=location.host.startsWith("localhost")?wt.Z.PROXY_SERVER:wt.Z.API_SERVER,ft=10*(1024*1024),Gt=(0,Ne.useRef)();Ee!=null&&Ee.startsWith("/api")&&st!=="txt"&&(Ee=wt.Z.API_SERVER+Ee);const an=Be=>Be.substring(Be.lastIndexOf("/")+1).split(".").pop();it&&Nt&&(Nt.filename=it),(0,Ne.useEffect)(()=>{var Be,Ze;const Fe=(Ze=(Be=document.cookie)==null?void 0:Be.replace(/\s/g,""))==null?void 0:Ze.split(";");Fe==null||Fe.map(qe=>{let dn=qe.split("=");dn[0]==="_educoder_session"&&On(dn[1])})},[]),(0,Ne.useEffect)(()=>{st==="office"&&(Ee.indexOf("bigfilescdn.")>-1||Ee.indexOf("bigfiles1")>-1?xn({url:Ee,fileType:an(Ee),model:Ee.indexOf("model=edit")?"edit":"view"}):Ve())},[st,Ee]);function Jt(Be){return pe(this,null,function*(){Be.data.type==="pdfdata"&&(et(Be.data.data),window.removeEventListener("message",Jt,!1)),console.log("mess---:",Be.data)})}const Ve=()=>pe(void 0,null,function*(){console.log("data:",Ee);let Be=Ee;Ee.startsWith("http")||(Be=location.origin+Be);let Ze=new URL(Be).pathname.split("/").pop();const Fe=yield(0,Mt.gJ)({attachment_id:Ze});Fe.url=Xn+Fe.url,xn(Fe)}),be=()=>{if(Ee.startsWith("http")||Ee.startsWith("blob:")){Pe();return}(0,$e.Sv)(it||"educoder",Ee,it)},Pe=()=>{nt&&(0,Qt.fc)({id:nt==null?void 0:nt.id,watch_type:1,course_id:nt==null?void 0:nt.course_id}),(0,$e.Nd)(it||"educoder",decodeURIComponent(Ee))};return It.createElement("div",{style:le({},Ft||{}),className:`${hi&&dt.bgBlack} ${st?dt.wrp:"hide"}`},cn&&It.createElement("div",{className:dt.close,ref:Gt},!!zn&&It.createElement(Ie.Z,{title:"\u70B9\u51FB\u5BF9\u56FE\u7247\u8FDB\u884C\u6279\u6CE8",getPopupContainer:()=>Gt.current},It.createElement("span",{onClick:()=>{Tt(),zn()}},It.createElement("i",{className:"icon-yulanpizhu"}))),!di&&It.createElement(Ie.Z,{title:"\u70B9\u51FB\u4E0B\u8F7D\u6B64\u6587\u4EF6",getPopupContainer:()=>Gt.current},It.createElement("span",{onClick:Pe},It.createElement("i",{className:"icon-quxiaozhiding"}))),Ge&&It.createElement(Ie.Z,{title:"\u4FDD\u5B58pdf\u5E76\u9000\u51FA",getPopupContainer:()=>Gt.current},It.createElement("span",{className:"",onClick:()=>{const Be=document.getElementById("pdfiframe");window.addEventListener("message",Jt,!1),setTimeout(()=>{Be.contentWindow.postMessage("getData","*")},300)}},It.createElement("i",{className:"icon-baocun"}))),It.createElement(Ie.Z,{title:"\u5173\u95ED",getPopupContainer:()=>Gt.current},It.createElement("span",{className:"",onClick:()=>{Tt()}},It.createElement("i",{className:"icon-guanbi1"})))),It.createElement("div",{className:`${dt[St]} ${St} ${dt.monaco} ${st==="txt"?"show":"hide"}`},st==="txt"&&It.createElement(It.Fragment,null,It.createElement(kt.ZP,le({},Nt)))),st==="audio"&&It.createElement("audio",{src:`${(Ee==null?void 0:Ee.indexOf("http://"))>-1||(Ee==null?void 0:Ee.indexOf("https://"))>-1?"":"data:audio/mp3;base64,"}${Ee}`,autoPlay:!0}),st==="video"&&It.createElement(It.Fragment,null,(Ee==null?void 0:Ee.indexOf("http"))>-1?It.createElement("video",{controls:!0,src:`${Ee}`,autoPlay:!0}):It.createElement("video",{controls:!0,src:`data:video/mp4;base64,${Ee}`,autoPlay:!0})),st==="office"&&Lt&&It.createElement("iframe",{src:`${vn}/office.html?key=${Lt.key}&url=${btoa(Lt.url)}&callbackUrl=${Xn+(Lt.callbackUrl||"")}&fileType=${Lt.fileType}&title=${Lt.title||""}&model=${xe}&officeServer=${wt.Z.ONLYOFFICE}&disabledDownload=${!!di}`}),st==="html"&&It.createElement("iframe",{src:Ee+"&disposition=inline"}),st==="pdf"&&It.createElement("iframe",{id:"pdfiframe",src:`${vn}/js/pdfview/index.html?filename=${it||"educoder.pdf"}&url=${encodeURIComponent(Ee)}&disabledDownload=${!!di}&model=${xe}`}),st==="image"&&It.createElement("img",{src:`${(Ee==null?void 0:Ee.indexOf("http://"))>-1||(Ee==null?void 0:Ee.indexOf("https://"))>-1?"":"data:image/png;base64,"}${Ee}`}),(st==="other"||st==="download")&&It.createElement(It.Fragment,null,Dn?It.createElement(Pt.Z,{customText:"\u5F53\u524D\u6587\u4EF6\u4E0D\u652F\u6301\u9884\u89C8\uFF0C\u53EF\u70B9\u51FB\u4E0B\u8F7D\u67E5\u770B",ButtonTwo:It.createElement(Ut.ZP,{icon:It.createElement("i",{className:"iconfont icon-xiazai4 font14"}),type:"primary",size:"middle",onClick:be,disabled:di},"\u4E0B\u8F7D")}):It.createElement(Ut.ZP,{type:"primary",size:"middle",onClick:be,disabled:di},It.createElement($t.Z,null),"\u70B9\u51FB\u4E0B\u8F7D")))}},65226:function(jn,li,De){"use strict";De.d(li,{z:function(){return st},Z:function(){return it}});var Ne=De(67294),dt=De(81897),Ut=De(51161),$t=De(11771),kt=De(67631),Ie=De.n(kt),$e=De(11320),Mt=De(28706),Pt=De(20527),wt=De(25934),Qt=De(20819),It=De(67294),Re=({html:Nt})=>{const St=(0,Ne.useRef)(null),Ft=(0,Ne.useRef)(null),cn=`.markdown-body p {
margin: 0 0 16px 0 !important;
line-height: 28px;
white-space: pre-wrap;
}
ol,
ul,
li {
list-style-type: none
}
ol,
ul,
dl {
margin-bottom: 0px;
}
.markdown-body {
-ms-text-size-adjust: 100%;
-webkit-text-size-adjust: 100%;
color: #333;
overflow: hidden;
font-family: "Microsoft YaHei", Helvetica, "Meiryo UI", "Malgun Gothic", "Segoe UI", "Trebuchet MS", "Monaco", monospace, Tahoma, STXihei, "\u534E\u6587\u7EC6\u9ED1", STHeiti, "Helvetica Neue", "Droid Sans", "wenquanyi micro hei", FreeSans, Arimo, Arial, SimSun, "\u5B8B\u4F53", Heiti, "\u9ED1\u4F53", sans-serif;
word-break: break-word;
font-size: 16px;
line-height: 1.6;
white-space: normal;
word-wrap: break-word;
position: relative;
}
.markdown-body ul>li {
list-style-type: disc;
}
.markdown-body ol>li {
list-style-type: decimal;
}
.markdown-body a {
background: transparent;
}
.markdown-body a:active,
.markdown-body a:hover {
outline: 0;
}
.markdown-body strong {
font-weight: bold;
}
.markdown-body h1 {
font-size: 2em;
margin: 0.67em 0;
}
.markdown-body img {
border: 0;
}
.markdown-body hr {
-moz-box-sizing: content-box;
box-sizing: content-box;
height: 0;
}
.markdown-body pre {
overflow: auto;
}
.markdown-body code,
.markdown-body kbd,
.markdown-body pre {
font-family: "Meiryo UI", "YaHei Consolas Hybrid", Consolas, "Malgun Gothic", "Segoe UI", "Trebuchet MS", Helvetica, monospace, monospace;
font-size: 1em;
}
.markdown-body input {
color: inherit;
font: inherit;
margin: 0;
}
.markdown-body html input[disabled] {
cursor: default;
}
.markdown-body input {
line-height: normal;
}
.markdown-body input[type="checkbox"] {
-moz-box-sizing: border-box;
box-sizing: border-box;
padding: 0;
}
.markdown-body table {
border-collapse: collapse;
border-spacing: 0;
}
.markdown-body td,
.markdown-body th {
padding: 0;
}
.markdown-body * {
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.markdown-body input {
font: 13px/1.4 Helvetica, arial, freesans, clean, sans-serif, "Segoe UI Emoji", "Segoe UI Symbol";
}
.markdown-body a {
color: #4183c4;
text-decoration: none;
}
.markdown-body a:hover,
.markdown-body a:active {
text-decoration: underline;
}
.markdown-body hr {
height: 0;
margin: 15px 0;
overflow: hidden;
background: transparent;
border: 0;
border-bottom: 1px solid #ddd;
}
.markdown-body hr:before {
display: table;
content: "";
}
.markdown-body hr:after {
display: table;
clear: both;
content: "";
}
.markdown-body h1,
.markdown-body h2,
.markdown-body h3,
.markdown-body h4,
.markdown-body h5,
.markdown-body h6 {
margin-top: 15px;
margin-bottom: 15px;
line-height: 1.1;
}
.markdown-body h1 {
font-size: 30px;
}
.markdown-body h2 {
font-size: 21px;
}
.markdown-body h3 {
font-size: 16px;
}
.markdown-body h4 {
font-size: 14px;
}
.markdown-body h5 {
font-size: 12px;
}
.markdown-body h6 {
font-size: 11px;
}
.markdown-body blockquote {
margin: 0;
}
.markdown-body ul,
.markdown-body ol {
padding: 0;
margin-top: 0;
margin-bottom: 0;
}
ul.linenums,
ol.linenums {
padding: 16px 0 0 56px !important;
}
.markdown-body ul,
.markdown-body ol {
padding-left: 2em;
}
.markdown-body ol ol,
.markdown-body ul ol {
list-style-type: lower-roman;
}
.markdown-body ul ul ol,
.markdown-body ul ol ol,
.markdown-body ol ul ol,
.markdown-body ol ol ol {
list-style-type: lower-alpha;
}
.markdown-body dd {
margin-left: 0;
}
.markdown-body code {
font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace;
font-size: 12px;
}
.markdown-body pre {
margin-top: 0;
margin-bottom: 0;
font: 12px Consolas, "Liberation Mono", Menlo, Courier, monospace;
}
.markdown-body .octicon {
font: normal normal 16px octicons-anchor;
line-height: 1;
display: inline-block;
text-decoration: none;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.markdown-body .octicon-link:before {
content: '\f05c';
}
.markdown-body>*:first-child {
margin-top: 0 !important;
}
.markdown-body>*:last-child {
margin-bottom: 0 !important;
}
.markdown-body .anchor {
position: absolute;
top: 0;
left: 0;
display: block;
padding-right: 6px;
padding-left: 30px;
margin-left: -30px;
}
.markdown-body .anchor:focus {
outline: none;
}
.markdown-body h1,
.markdown-body h2,
.markdown-body h3,
.markdown-body h4,
.markdown-body h5,
.markdown-body h6 {
position: relative;
margin-top: 1em;
margin-bottom: 16px;
font-weight: bold;
line-height: 1.4;
}
.markdown-body h1 .octicon-link,
.markdown-body h2 .octicon-link,
.markdown-body h3 .octicon-link,
.markdown-body h4 .octicon-link,
.markdown-body h5 .octicon-link,
.markdown-body h6 .octicon-link {
display: none;
color: #000;
vertical-align: middle;
}
.markdown-body h1:hover .anchor,
.markdown-body h2:hover .anchor,
.markdown-body h3:hover .anchor,
.markdown-body h4:hover .anchor,
.markdown-body h5:hover .anchor,
.markdown-body h6:hover .anchor {
padding-left: 8px;
margin-left: -30px;
text-decoration: none;
}
.markdown-body h1:hover .anchor .octicon-link,
.markdown-body h2:hover .anchor .octicon-link,
.markdown-body h3:hover .anchor .octicon-link,
.markdown-body h4:hover .anchor .octicon-link,
.markdown-body h5:hover .anchor .octicon-link,
.markdown-body h6:hover .anchor .octicon-link {
display: inline-block;
}
.markdown-body h1 {
padding-bottom: 0.3em;
font-size: 2.25em;
line-height: 1.2;
border-bottom: 1px solid #eee;
}
.markdown-body h1 .anchor {
line-height: 1;
}
.markdown-body h2 {
padding-bottom: 0.3em;
font-size: 1.75em;
line-height: 1.225;
border-bottom: 1px solid #eee;
}
.markdown-body h2 .anchor {
line-height: 1;
}
.markdown-body h3 {
font-size: 1.5em;
line-height: 1.43;
}
.markdown-body h3 .anchor {
line-height: 1.2;
}
.markdown-body h4 {
font-size: 1.25em;
}
.markdown-body h4 .anchor {
line-height: 1.2;
}
.markdown-body h5 {
font-size: 1em;
}
.markdown-body h5 .anchor {
line-height: 1.1;
}
.markdown-body h6 {
font-size: 1em;
color: #777;
}
.markdown-body h6 .anchor {
line-height: 1.1;
}
.markdown-body p,
.markdown-body blockquote,
.markdown-body ul,
.markdown-body ol,
.markdown-body dl,
.markdown-body table,
.markdown-body pre {
margin-top: 0;
margin-bottom: 16px;
}
.markdown-body ul ul,
.markdown-body ul ol,
.markdown-body ol ol,
.markdown-body ol ul {
margin-top: 0;
margin-bottom: 0;
}
.markdown-body li>p {
margin-top: 16px;
}
.markdown-body dl {
padding: 0;
}
.markdown-body dl dt {
padding: 0;
margin-top: 16px;
font-size: 1em;
font-style: italic;
font-weight: bold;
}
.markdown-body dl dd {
padding: 0 16px;
margin-bottom: 16px;
}
.markdown-body blockquote {
padding: 0 15px;
color: #777;
border-left: 4px solid #ddd;
}
.markdown-body blockquote> :first-child {
margin-top: 0;
}
.markdown-body blockquote> :last-child {
margin-bottom: 0;
}
.markdown-body table {
display: block;
width: 100%;
overflow: auto;
word-break: normal;
word-break: keep-all;
}
.markdown-body table th {
font-weight: bold;
text-align: revert;
}
.markdown-body table th,
.markdown-body table td {
padding: 6px 13px;
border: 1px solid #ddd;
}
.markdown-body table tr {
background-color: #fff;
border-top: 1px solid #ccc;
}
.markdown-body table tr:nth-child(2n) {
background-color: #f8f8f8;
}
.markdown-body img {
max-width: 100%;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.markdown-body code {
padding: 0;
padding-top: 0.2em;
padding-bottom: 0.2em;
margin: 0;
font-size: 85%;
background-color: rgba(0, 0, 0, 0.04);
border-radius: 3px;
}
.markdown-body code:has(.katex) {
background-color: transparent;
}
.markdown-body code:before,
.markdown-body code:after {
letter-spacing: -0.2em;
content: "\\00a0";
}
.markdown-body pre>code {
padding: 0;
margin: 0;
font-size: 100%;
word-break: normal;
white-space: pre;
background: transparent;
border: 0;
}
.markdown-body .highlight {
margin-bottom: 16px;
}
.markdown-body .highlight pre,
.markdown-body pre {
padding: 16px;
overflow: auto;
font-size: 85%;
line-height: 1.45;
background-color: #f7f7f7;
border-radius: 3px;
}
.markdown-body .highlight pre {
margin-bottom: 0;
word-break: normal;
}
.markdown-body pre {
word-wrap: normal;
}
.markdown-body pre code {
display: inline;
max-width: initial;
padding: 0;
margin: 0;
overflow: initial;
line-height: inherit;
word-wrap: normal;
background-color: transparent;
border: 0;
}
.markdown-body pre code:before,
.markdown-body pre code:after {
content: normal;
}
.markdown-body kbd {
display: inline-block;
padding: 3px 5px;
font-size: 11px;
line-height: 10px;
color: #555;
vertical-align: middle;
background-color: #fcfcfc;
border: solid 1px #ccc;
border-bottom-color: #bbb;
border-radius: 3px;
box-shadow: inset 0 -1px 0 #bbb;
}
.markdown-body .pl-c {
color: #969896;
}
.markdown-body .pl-c1,
.markdown-body .pl-mdh,
.markdown-body .pl-mm,
.markdown-body .pl-mp,
.markdown-body .pl-mr,
.markdown-body .pl-s1 .pl-v,
.markdown-body .pl-s3,
.markdown-body .pl-sc,
.markdown-body .pl-sv {
color: #0086b3;
}
.markdown-body .pl-e,
.markdown-body .pl-en {
color: #795da3;
}
.markdown-body .pl-s1 .pl-s2,
.markdown-body .pl-smi,
.markdown-body .pl-smp,
.markdown-body .pl-stj,
.markdown-body .pl-vo,
.markdown-body .pl-vpf {
color: #333;
}
.markdown-body .pl-ent {
color: #63a35c;
}
.markdown-body .pl-k,
.markdown-body .pl-s,
.markdown-body .pl-st {
color: #a71d5d;
}
.markdown-body .pl-pds,
.markdown-body .pl-s1,
.markdown-body .pl-s1 .pl-pse .pl-s2,
.markdown-body .pl-sr,
.markdown-body .pl-sr .pl-cce,
.markdown-body .pl-sr .pl-sra,
.markdown-body .pl-sr .pl-sre,
.markdown-body .pl-src {
color: #df5000;
}
.markdown-body .pl-mo,
.markdown-body .pl-v {
color: #1d3e81;
}
.markdown-body .pl-id {
color: #b52a1d;
}
.markdown-body .pl-ii {
background-color: #b52a1d;
color: #f8f8f8;
}
.markdown-body .pl-sr .pl-cce {
color: #63a35c;
font-weight: bold;
}
.markdown-body .pl-ml {
color: #693a17;
}
.markdown-body .pl-mh,
.markdown-body .pl-mh .pl-en,
.markdown-body .pl-ms {
color: #1d3e81;
font-weight: bold;
}
.markdown-body .pl-mq {
color: #008080;
}
.markdown-body .pl-mi {
color: #333;
font-style: italic;
}
.markdown-body .pl-mb {
color: #333;
font-weight: bold;
}
.markdown-body .pl-md,
.markdown-body .pl-mdhf {
background-color: #ffecec;
color: #bd2c00;
}
.markdown-body .pl-mdht,
.markdown-body .pl-mi1 {
background-color: #eaffea;
color: #55a532;
}
.markdown-body .pl-mdr {
color: #795da3;
font-weight: bold;
}
.markdown-body kbd {
display: inline-block;
padding: 3px 5px;
font: 11px Consolas, "Liberation Mono", Menlo, Courier, monospace;
line-height: 10px;
color: #555;
vertical-align: middle;
background-color: #fcfcfc;
border: solid 1px #ccc;
border-bottom-color: #bbb;
border-radius: 3px;
box-shadow: inset 0 -1px 0 #bbb;
}
.markdown-body .task-list-item {
list-style-type: none;
}
.markdown-body .task-list-item+.task-list-item {
margin-top: 3px;
}
.markdown-body .task-list-item input {
float: left;
margin: 0.3em 0 0.25em -1.6em;
vertical-align: middle;
}
.markdown-body :checked+.radio-label {
z-index: 1;
position: relative;
border-color: #4183c4;
}
/*! Pretty printing styles. Used with prettify.js. */
/* SPAN elements with the classes below are added by prettyprint. */
.pln {
color: #000
}
/* plain text */
@media screen {
.str {
color: #080
}
/* string content */
.kwd {
color: #008
}
/* a keyword */
.com {
color: #800
}
/* a comment */
.typ {
color: #606
}
/* a type name */
.lit {
color: #066
}
/* a literal value */
/* punctuation, lisp open bracket, lisp close bracket */
.pun,
.opn,
.clo {
color: #660
}
.tag {
color: #008
}
/* a markup tag name */
.atn {
color: #606
}
/* a markup attribute name */
.atv {
color: #080
}
/* a markup attribute value */
.dec,
.var {
color: #606
}
/* a declaration; a variable name */
.fun {
color: red
}
/* a function name */
}
/* Use higher contrast and text-weight for printable form. */
@media print,
projection {
.str {
color: #060
}
.kwd {
color: #006;
font-weight: bold
}
.com {
color: #600;
font-style: italic
}
.typ {
color: #404;
font-weight: bold
}
.lit {
color: #044
}
.pun,
.opn,
.clo {
color: #440
}
.tag {
color: #006;
font-weight: bold
}
.atn {
color: #404
}
.atv {
color: #060
}
}
/* Put a border around prettyprinted code snippets. */
pre.prettyprint {
padding: 2px;
/* border: 1px solid #888 */
}
/* Specify class=linenums on a pre to get line numbering */
ol.linenums {
margin-top: 0;
margin-bottom: 0
}
/* IE indents via margin-left */
li.L0,
li.L1,
li.L2,
li.L3,
li.L5,
li.L6,
li.L7,
li.L8 {
list-style-type: none
}
/* Alternate shading for lines */
li.L1,
li.L3,
li.L5,
li.L7,
li.L9 {
background: #eee
}
.markdown-body p,
.markdown-body blockquote,
.markdown-body ul,
.markdown-body ol,
.markdown-body dl,
.markdown-body table,
.markdown-body pre {
margin-top: 0;
margin-bottom: 16px;
}`;return(0,Ne.useEffect)(()=>{const Tt=St.current.attachShadow({mode:"open"});Ft.current=document.createElement("div"),Ft.current.className="markdown-body",Ft.current.innerHTML=Nt,Tt.appendChild(Ft.current);const hi=document.createElement("style");return hi.textContent=cn,Tt.appendChild(hi),()=>{Tt.innerHTML=""}},[]),(0,Ne.useEffect)(()=>{Ft.current&&(Ft.current.innerHTML=Nt)},[Nt]),It.createElement("div",{ref:St})};function ne(Nt){const St=["onabort","onanimationend","onanimationiteration","onanimationstart","onauxclick","onblur","oncancel","oncanplay","oncanplaythrough","onchange","onclick","onclose","oncontextmenu","oncopy","oncut","ondblclick","ondrag","ondragend","ondragenter","ondragleave","ondragover","ondragstart","ondrop","ondurationchange","onemptied","onended","onerror","onfocus","onformdata","ongotpointercapture","oninput","oninvalid","onkeydown","onkeypress","onkeyup","onload","onloadeddata","onloadedmetadata","onloadstart","onlostpointercapture","onmousedown","onmousemove","onmouseout","onmouseover","onmouseup","onpaste","onpause","onplay","onplaying","onpointercancel","onpointerdown","onpointerenter","onpointerleave","onpointermove","onpointerout","onpointerover","onpointerup","onprogress","onratechange","onreset","onresize","onscroll","onsecuritypolicyviolation","onseeked","onseeking","onselect","onslotchange","onstalled","onsubmit","onsuspend","ontimeupdate","ontoggle","ontouchcancel","ontouchend","ontouchmove","ontouchstart","ontransitionend","onvolumechange","onwaiting","onwheel"],Ft=new RegExp(`\\b(${St.join("|")})\\s*=\\s*(?:"[^"]*"|'[^']*'|[^\\s>]*)`,"gi");return Nt.replace(Ft,"").trim()}var te=Object.defineProperty,he=Object.getOwnPropertySymbols,le=Object.prototype.hasOwnProperty,pe=Object.prototype.propertyIsEnumerable,me=(Nt,St,Ft)=>St in Nt?te(Nt,St,{enumerable:!0,configurable:!0,writable:!0,value:Ft}):Nt[St]=Ft,xe=(Nt,St)=>{for(var Ft in St||(St={}))le.call(St,Ft)&&me(Nt,Ft,St[Ft]);if(he)for(var Ft of he(St))pe.call(St,Ft)&&me(Nt,Ft,St[Ft]);return Nt};const Ee="@\u2581\u2581@",Ge="@\u2581@",et=/<pre[^>]*>/g;function ut(Nt){let St=document.createElement("div");return St.innerHTML=Nt,St.childNodes.length===0?"":St.childNodes[0].nodeValue}const st=(Nt,St)=>{Nt=Nt||"";const Ft=/(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?\)|(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,cn=/\"(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,Tt=/\(\s+(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,hi=/(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g;return St?Nt.replaceAll("https://www.educoder.net","").replaceAll("https://www-cdn.educoder.net","").replaceAll("//api/attachments","/api/attachments").replace(Ft,(di,zn,Dn,nt,ze,ke,Wt)=>{const On=zn||nt||ke,Lt=Dn||ze||Wt||"?";return $e.Z.API_SERVER+"/api/attachments/"+On+Lt+"&t="+(0,Mt.Jn)(On,Date.now())+(di.indexOf(")")>-1?")":"&")}).replaceAll('src="(','src="').replaceAll("src='(",'src="'):(Nt=Nt.replace(hi,(di,zn,Dn,nt,ze,ke,Wt)=>{const On=zn||nt||ke,Lt=Dn||ze||Wt||"?";return $e.Z.API_SERVER+"/attachments/download/"+On+Lt+"&t="+(0,Mt.Jn)(On,Date.now())+(di.indexOf(")")>-1?")":"&")}).replace(Ft,(di,zn,Dn,nt,ze,ke,Wt)=>{const On=zn||nt||ke,Lt=Dn||ze||Wt||"?";return $e.Z.API_SERVER+"/api/attachments/"+On+Lt+"&t="+(0,Mt.Jn)(On,Date.now())+(di.indexOf(")")>-1?")":"&")}).replace(cn,(di,zn,Dn,nt,ze)=>{const ke=zn||nt,Wt=Dn||ze||"";return'"'+$e.Z.API_SERVER+"/api/attachments/"+ke+Wt+ke+Wt+"&t="+(0,Mt.Jn)(ke,Date.now())}).replace(Tt,(di,zn,Dn,nt,ze)=>{const ke=zn||nt,Wt=Dn||ze||"";return"("+$e.Z.API_SERVER+"/files/uploads/"+ke+Wt+ke+Wt+"&t="+(0,Mt.Jn)(ke,Date.now())}).replaceAll('src="(','src="').replaceAll("src='(",'src="').replaceAll("http://video.educoder","https://video.educoder").replaceAll("http://www.educoder.net/api","https://data.educoder.net/api").replaceAll("https://www.educoder.net/api","https://data.educoder.net/api").replace(/\r\n/g,`
`),Nt)};var it=({value:Nt="",className:St,showTextOnly:Ft,showLines:cn,style:Tt={},stylesPrev:hi={},highlightKeywords:di,showProgramFill:zn,isProgramFill:Dn,disabledFill:nt=!1,programFillValue:ze,onFillChange:ke=Lt=>{},onFillBlur:Wt=()=>{},onFillFocus:On=()=>{}})=>{let Lt=ne(String(Nt||""));const[xn,vn]=(0,Ne.useState)(""),[Xn,Ot]=(0,Ne.useState)("office"),[ft,Gt]=(0,Ne.useState)([]),an=(0,Ne.useRef)("a"+(0,wt.Z)()),Jt={},Ve=Zt=>/<style[\s\S]*?>/i.test(Zt||""),be=(Zt,_n,ti)=>{const Ri=document.createElement(Zt===Ge?"input":"textarea");Ri.style.width="100%",Ri.style.height=Zt===Ge?"40px":"151px",Ri.rows=5,Ri.spellcheck=!1,Ri.name="edu-program-fill",Ri.placeholder="\u8BF7\u8F93\u5165",Ri.dataset.id=_n;const oi=Object.keys(Jt).length;return Jt[oi]=Ri,`<span class="edu-program-fill-wrap ${Zt===Ge?"":"show"}" style="width:${Zt===Ge?"600px":"100%"}" title=${ti||""}><span>${Ri.outerHTML}<span class="edu-program-fill-score" style="margin:0 6px"></span></span></span>`};function Pe(Zt){return Zt=Zt.replace(/!\[.*?\]\(.*?\)/g,""),Zt=Zt.replace(/\[.*?\]\(.*?\)/g,""),Zt=Zt.replace(new RegExp("<iframe.*?<\\/iframe>","gs"),""),Zt=Zt.replace(/<embed.*?>/g,""),Zt=Zt.replace(/<img.*?>/g,""),Zt=Zt.replace(new RegExp("<video.*?>.*?<\\/video>","gs"),""),Zt=Zt.replace(new RegExp("<audio.*?>.*?<\\/audio>","gs"),""),Zt=Zt.replace(new RegExp("<style.*?>.*?<\\/style>","gs"),""),Zt=Zt.replace(new RegExp("<script.*?>.*?<\\/script>","gs"),""),Zt}const Be=Zt=>!Ft&&Ve(Lt)?Zt:Zt.replace(/<style.*?>([\s\S]+?)<\/style>/gim,function(_n,ti){let Ri=ti.replace(/(\n|\r)/g,"").split("}"),oi=[];return Ri.map(wr=>{wr!=""&&oi.push(`.${an.current} ${wr}`)}),`<style>${oi.join("}")}</style>`}),Ze=(0,Ne.useMemo)(()=>{try{const Ri=/\(\s+\/api\/attachments\/|\(\/api\/attachments\//g,oi=/\"\/api\/attachments\/|\"\/attachments\/download\//g,wr=/\(\s+\/files\/uploads\/|\"\/files\/uploads\//g,fr=/\(\/attachments\/download\//g;Lt=Lt.replace(fr,"("+$e.Z.API_SERVER+"/attachments/download/").replace(Ri,"("+$e.Z.API_SERVER+"/api/attachments/").replace(oi,'"'+$e.Z.API_SERVER+"/api/attachments/").replace(wr,'"'+$e.Z.API_SERVER+"/files/uploads/").replaceAll("http://video.educoder","https://video.educoder").replaceAll("http://www.educoder.net/api","https://data.educoder.net/api").replaceAll("https://www.educoder.net/api","https://data.educoder.net/api").replace(/\r\n/g,`
`)}catch(Ri){}if(zn){let Ri=-1;return Lt=Lt.replaceAll("<","&lt;").replaceAll(">","&gt;").replace(/(@▁▁@|@▁@)/g,function(oi,wr,fr){var Ei;return++Ri,be(oi,Ri,(Ei=ze==null?void 0:ze[Ri])==null?void 0:Ei.value.replaceAll("<","&lt;").replaceAll(">","&gt;"))}),`<pre style="background:#fff;padding:4px">${Be(Lt||"")}</pre>`}let Zt=Be(Lt);Zt=(0,Ut.ZP)(Zt);const _n=(0,Ut.ez)();Lt.match(/\[TOC\]/)&&(Zt=Zt.replace("<p>[TOC]</p>",(0,Ut.Qv)()),(0,Ut.Iy)()),Zt=Zt.replace(/(__special_katext_id_\d+__)/g,(Ri,oi)=>{const{type:wr,expression:fr}=_n[oi];return(0,Pt.renderToString)(ut(fr)||"",{displayMode:wr==="block",throwOnError:!1,output:"html"})}),Zt=Zt.replace(/▁/g,"\u2581\u2581\u2581\u2581\u2581"),(0,Ut.AL)();const ti=document.createElement("div");if(ti.innerHTML=Zt,Ft)return ti.innerText;if(di){const Ri=di.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return ui(ti,Ri),ti.innerHTML}return setTimeout(()=>Hn(),500),ti.innerHTML},[Lt,di]);(0,Ne.useEffect)(()=>{$n.current&&$n.current.querySelectorAll(["input","textarea"]).forEach(_n=>{_n.oninput=Fe,_n.onblur=qe,_n.onfocus=dn})},[ft]),(0,Ne.useEffect)(()=>{var Zt,_n,ti,Ri,oi;if(ze!=null&&ze.length)try{const wr=$n.current.querySelectorAll(".edu-program-fill-score"),fr=$n.current.querySelectorAll('[name="edu-program-fill"]');for(const[Ei,Di]of fr.entries())Di.value=((Zt=ze==null?void 0:ze[Ei])==null?void 0:Zt.value)||"",((_n=ze==null?void 0:ze[Ei])==null?void 0:_n.type)==="warning"?Di.className="program-fill-warning":((ti=ze==null?void 0:ze[Ei])==null?void 0:ti.type)==="success"?Di.className="program-fill-success":Di.className="";for(const[Ei,Di]of wr.entries())Di.innerHTML=(Ri=ze==null?void 0:ze[Ei])!=null&&Ri.score?`${(oi=ze==null?void 0:ze[Ei])==null?void 0:oi.score}\u5206`:"";Gt(ze)}catch(wr){console.log(wr,"error")}},[ze]);const Fe=Zt=>{ft[Zt.target.dataset.id]=ft[Zt.target.dataset.id]||{},ft[Zt.target.dataset.id].value=Zt.target.value,Gt([...ft]),ke(ft,Zt.target.dataset.id)},qe=Zt=>{ft[Zt.target.dataset.id]=ft[Zt.target.dataset.id]||{},ft[Zt.target.dataset.id].value=Zt.target.value,Gt([...ft]),Wt(ft,Zt.target.dataset.id)},dn=Zt=>{ft[Zt.target.dataset.id]=ft[Zt.target.dataset.id]||{},ft[Zt.target.dataset.id].value=Zt.target.value,Gt([...ft]),On(ft,Zt.target.dataset.id)};function ui(Zt,_n){return Zt.childNodes.forEach(ti=>{var Ri;if(ti.childNodes.length>0)ui(ti,_n);else if(ti.nodeName!=="IMG")if(ti.innerHTML)ti.innerHTML=(Ri=ti.innerHTML)==null?void 0:Ri.replace(new RegExp(_n,"gi"),'<span style="color:#0152d9;background-color:#1890ff33">$&</span>');else{const oi=document.createElement("span");oi.innerHTML=ti.textContent.replace(new RegExp(_n,"gi"),'<span style="color:#0152d9;background-color:#1890ff33">$&</span>'),ti.replaceWith(oi)}})}const $n=(0,Ne.useRef)();Ut.jb.WebkitLineClamp=cn,cn&&(Tt=xe(xe({},Tt),Ut.jb));function rn(Zt){let _n=Zt.target;if(_n.tagName.toUpperCase()==="A"){let ti=_n.getAttribute("href");if(ti.indexOf("office")>-1)Zt.preventDefault(),vn(ti),Ot("office");else if(ti.indexOf("application/pdf")>-1)Zt.preventDefault(),vn(ti),Ot("pdf");else if(ti.indexOf("text/html")>-1)Zt.preventDefault(),vn(ti),Ot("html");else if(ti.startsWith("#")){Zt.preventDefault();let Ri=document.getElementById(ti.replace("#",""));Ri&&Ri.scrollIntoView(!0)}}}const Hn=()=>{var Zt;const _n=(Zt=$n.current)==null?void 0:Zt.querySelectorAll("video");_n==null||_n.forEach(ti=>{if(ti.oncontextmenu=()=>!1,ti.src.indexOf(".m3u8")>-1&&!ti.canPlayType("application/vnd.apple.mpegurl")){if(Ie().isSupported()){var Ri=new(Ie());Ri.loadSource(ti.src),Ri.attachMedia(ti)}}})};return(0,Ne.useEffect)(()=>{if($n.current&&Ze&&Ze.match(et)&&window.PR.prettyPrint(),$n.current)return $n.current.addEventListener("click",rn),()=>{var Zt;(Zt=$n.current)==null||Zt.removeEventListener("click",rn),(0,Ut.AL)(),(0,Ut.Iy)()}},[Ze,$n.current,rn]),(0,Ne.useEffect)(()=>{var Zt;const _n=ti=>{ti.preventDefault(),ti.clipboardData.setData("text",window.getSelection().toString())};return(Zt=$n.current)==null||Zt.addEventListener("copy",_n),()=>{var ti;(ti=$n.current)==null||ti.removeEventListener("copy",_n)}},[$n.current]),Ne.createElement(Ne.Fragment,null,Ft&&Ne.createElement("div",{ref:$n},Ze),!Ft&&!Ve(Ze)&&Ne.createElement("div",{ref:$n,style:xe({},Tt),className:`${St||""} ${nt?"disabled-fill":""} markdown-body ${an.current}`,dangerouslySetInnerHTML:{__html:Ze}}),!Ft&&Ve(Ze)&&Ne.createElement(Re,{html:Ze}),Ne.createElement(Qt.Z,{close:!0,data:xn,type:xn!=null&&xn.length?Xn:"",style:xe({},hi),onClose:()=>vn("")}))}},57444:function(jn,li,De){"use strict";De.d(li,{h:function(){return xe}});var Ne=De(67294),dt=De(88044),Ut=De(91773),$t=De(85804),kt=De(4631),Ie=De.n(kt),$e=De(71749),Mt=De(30483),Pt=Object.defineProperty,wt=Object.defineProperties,Qt=Object.getOwnPropertyDescriptors,It=Object.getOwnPropertySymbols,sn=Object.prototype.hasOwnProperty,Re=Object.prototype.propertyIsEnumerable,ne=(Ee,Ge,et)=>Ge in Ee?Pt(Ee,Ge,{enumerable:!0,configurable:!0,writable:!0,value:et}):Ee[Ge]=et,te=(Ee,Ge)=>{for(var et in Ge||(Ge={}))sn.call(Ge,et)&&ne(Ee,et,Ge[et]);if(It)for(var et of It(Ge))Re.call(Ge,et)&&ne(Ee,et,Ge[et]);return Ee},he=(Ee,Ge)=>wt(Ee,Qt(Ge));const le=dt.default.Option,pe={labelCol:{span:4},wrapperCol:{span:20}},me={asp:["ASP","vbscript"],actionscript:["ActionScript(3.0)/Flash/Flex","clike"],bash:["Bash/Bat","shell"],css:["CSS","css"],c:["C","clike"],cpp:["C++","clike"],csharp:["C#","clike"],coffeescript:["CoffeeScript","coffeescript"],d:["D","d"],dart:["Dart","dart"],delphi:["Delphi/Pascal","pascal"],erlang:["Erlang","erlang"],go:["Golang","go"],groovy:["Groovy","groovy"],html:["HTML","text/html"],java:["Java","clike"],json:["JSON","text/json"],javascript:["Javascript","javascript"],lua:["Lua","lua"],less:["LESS","css"],markdown:["Markdown","gfm"],"objective-c":["Objective-C","clike"],php:["PHP","php"],perl:["Perl","perl"],python:["Python","python"],r:["R","r"],rst:["reStructedText","rst"],ruby:["Ruby","ruby"],sql:["SQL","sql"],sass:["SASS/SCSS","sass"],shell:["Shell","shell"],scala:["Scala","clike"],swift:["Swift","clike"],vb:["VB/VBScript","vb"],xml:["XML","text/xml"],yaml:["YAML","yaml"]};li.Z=({callback:Ee,onCancel:Ge})=>{const[et,ut]=(0,Ne.useState)("python");function st(Nt){ut(me[Nt][1])}function it(Nt){Ee(Nt)}return Ne.createElement(Ut.default,he(te({},pe),{className:"code-block-panel",initialValues:{language:"python",content:""},onFinish:it,style:{width:500}}),Ne.createElement(Ut.default.Item,{label:"\u4EE3\u7801\u8BED\u8A00",name:"language"},Ne.createElement(dt.default,{getPopupContainer:Nt=>Nt.parentNode,onChange:st},Object.keys(me).map(Nt=>Ne.createElement(le,{key:Nt,value:Nt},me[Nt][0])))),Ne.createElement(Ut.default.Item,{label:"\u4EE3\u7801\u5185\u5BB9",name:"content",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u4EE3\u7801\u5185\u5BB9"}]},Ne.createElement(xe,{mode:et})),Ne.createElement("div",{className:"flex-container flex-end"},Ne.createElement($t.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),Ne.createElement($t.ZP,{type:"ghost",onClick:Ge},"\u53D6\u6D88")))};function xe({value:Ee,onChange:Ge,mode:et,options:ut={}}){const st=(0,Ne.useRef)(),[it,Nt]=(0,Ne.useState)();return(0,Ne.useEffect)(()=>{if(it){let St=function(Ft){const cn=Ft.getValue();Ge&&Ge(cn)};return it.on("change",St),()=>{it.off("change",St)}}},[it,Ge]),(0,Ne.useEffect)(()=>{it&&it.setOption("mode",et)},[it,et]),(0,Ne.useEffect)(()=>{it&&(Ee!==it.getValue()||Ee==="")&&setTimeout(()=>{it.setValue(Ee||"")},300)},[it,Ee]),(0,Ne.useEffect)(()=>{if(st.current&&!it){const St=Ie().fromTextArea(st.current,te({mode:et,lineNumbers:!0,lineWrapping:!0,autoCloseBrackets:!0,tabSize:4,autofocus:!0,autoCloseTags:!0,matchBrackets:!0,styleActiveLine:!0},ut));Nt(St)}},[st.current,it]),Ne.createElement("div",{className:"my-codemirror-container"},Ne.createElement("textarea",{ref:st}))}},35567:function(jn,li,De){"use strict";De.d(li,{Z:function(){return _i}});var Ne=De(67294),dt=De(4631),Ut=De.n(dt),$t=De(91033),kt=De(71749),Ie=De(57341),$e=De(82801),Mt=De(88386),Pt=De(49047),wt=De(80785),Qt=De(65226),It=({value:jt="",className:zt,showTextOnly:Ct,showLines:Yt,style:ci={}})=>{const vi=(0,Ne.useMemo)(()=>"",[jt]);return Ne.createElement(Ne.Fragment,null,Ne.createElement("div",{dangerouslySetInnerHTML:{__html:vi}}))},sn=Object.defineProperty,Re=Object.defineProperties,ne=Object.getOwnPropertyDescriptors,te=Object.getOwnPropertySymbols,he=Object.prototype.hasOwnProperty,le=Object.prototype.propertyIsEnumerable,pe=(jt,zt,Ct)=>zt in jt?sn(jt,zt,{enumerable:!0,configurable:!0,writable:!0,value:Ct}):jt[zt]=Ct,me=(jt,zt)=>{for(var Ct in zt||(zt={}))he.call(zt,Ct)&&pe(jt,Ct,zt[Ct]);if(te)for(var Ct of te(zt))le.call(zt,Ct)&&pe(jt,Ct,zt[Ct]);return jt},xe=(jt,zt)=>Re(jt,ne(zt));let Ee=[{title:"\u7C97\u4F53",icon:"md-iconfont icon-bold",actionName:"bold"},{title:"\u659C\u4F53",icon:"md-iconfont icon-italic",actionName:"italic"},"|",{title:"\u65E0\u5E8F\u5217\u8868",icon:"md-iconfont icon-unorder-list",actionName:"list-ul"},{title:"\u6709\u5E8F\u5217\u8868",icon:"md-iconfont icon-order-list",actionName:"list-ol"},"|",{title:"\u884C\u5185\u4EE3\u7801",icon:"md-iconfont icon-code",actionName:"code"},{title:"\u4EE3\u7801\u5757\uFF08\u591A\u8BED\u8A00\u98CE\u683C\uFF09",icon:"md-iconfont icon-file-code",actionName:"code-block"},{title:"\u94FE\u63A5",icon:"md-iconfont icon-link",actionName:"link"},"|",{title:"\u884C\u5185\u516C\u5F0F",icon:"md-iconfont icon-sum",actionName:"inline-latex"},{title:"\u6570\u5B66\u516C\u5F0F",icon:"iconfont icon-shuxuetuxiang2",actionName:"maths-latex"},{title:"\u591A\u884C\u516C\u5F0F",icon:"md-iconfont icon-formula",actionName:"latex"},"|",{title:"\u6DFB\u52A0\u56FE\u7247",icon:"md-iconfont icon-picture",actionName:"upload-image"},{title:"\u63D2\u5165\u753B\u56FE",icon:"iconfont icon-sheji",actionName:"draw-image"},{title:"\u63D2\u5165\u6D41\u7A0B\u56FE",icon:"iconfont icon-liucheng",actionName:"add-flowchart"},{title:"\u8868\u683C",icon:"md-iconfont icon-table",actionName:"add-table"},"|",{title:"\u6362\u884C",icon:"md-iconfont icon-minus",actionName:"line-break"},{title:"\u6E05\u7A7A",icon:"md-iconfont icon-eraser",actionName:"eraser"}];function Ge({onActionCallback:jt,title:zt,icon:Ct,actionName:Yt,className:ci="",children:vi}){function ai(){jt(Yt)}return Ne.createElement("a",{title:zt,className:ci,onClick:ai},Ne.createElement("i",{className:`${Ct}`}),vi)}var et=({watch:jt,showNullButton:zt,showNullProgramButton:Ct,onActionCallback:Yt,fullScreen:ci,insertTemp:vi,hidetoolBar:ai,extraUse:Kt})=>{const wn=[...Ee,{title:`${jt?"\u5173\u95ED\u5B9E\u65F6\u9884\u89C8":"\u5F00\u542F\u5B9E\u65F6\u9884\u89C8"}`,icon:`${jt?"md-iconfont icon-eye-slash":"md-iconfont icon-eye"}`,actionName:"trigger-watch"}];return Ne.createElement("ul",{className:"markdown-toolbar-container"},!ai&&wn.map((pi,ji)=>Ne.createElement("li",{key:ji},pi.actionName?Ne.createElement(Ge,xe(me({},pi),{onActionCallback:Yt})):Ne.createElement("span",{className:"v-line"}))),zt?Ne.createElement("li",null,Ne.createElement(Ge,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-null-ch",onActionCallback:Yt},Ne.createElement("span",{className:"fill-tip"},"\u70B9\u51FB\u63D2\u5165\b\u586B\u7A7A\u9879"))):null,Ct?Ne.createElement(Ne.Fragment,null,Ne.createElement("li",null,Ne.createElement(Ge,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-signal",onActionCallback:Yt},Ne.createElement("span",{className:"fill-tip"},"\u6DFB\u52A0\u5355\u884C\u586B\u7A7A\u9879"))),Ne.createElement("li",null,Ne.createElement(Ge,{icon:"md-iconfont icon-uniE900 insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-multiple",onActionCallback:Yt},Ne.createElement("span",{className:"fill-tip"},"\u6DFB\u52A0\u591A\u884C\u586B\u7A7A\u9879")))):null,vi&&Ne.createElement("li",null,Ne.createElement(Ge,{icon:"md-iconfont icon-edit",className:"btn-null",title:"\u63D2\u5165\u6A21\u677F",actionName:`inster-template-${vi}`,onActionCallback:Yt},Ne.createElement("span",{className:"fill-tip"},"\u63D2\u5165\u6A21\u677F"))),Kt&&Ne.createElement("li",null,Kt),Ne.createElement("li",{className:"btn-full-screen"},Ne.createElement(Ge,{icon:`${ci?"md-iconfont icon-shrink":"md-iconfont icon-enlarge"}`,title:ci?"\u5173\u95ED\u5168\u5C4F":"\u5F00\u542F\u5168\u5C4F",actionName:"trigger-full-screen",onActionCallback:Yt})))},ut=De(76621),st=De(91773),it=De(28802),Nt=De(85804),St=Object.defineProperty,Ft=Object.defineProperties,cn=Object.getOwnPropertyDescriptors,Tt=Object.getOwnPropertySymbols,hi=Object.prototype.hasOwnProperty,di=Object.prototype.propertyIsEnumerable,zn=(jt,zt,Ct)=>zt in jt?St(jt,zt,{enumerable:!0,configurable:!0,writable:!0,value:Ct}):jt[zt]=Ct,Dn=(jt,zt)=>{for(var Ct in zt||(zt={}))hi.call(zt,Ct)&&zn(jt,Ct,zt[Ct]);if(Tt)for(var Ct of Tt(zt))di.call(zt,Ct)&&zn(jt,Ct,zt[Ct]);return jt},nt=(jt,zt)=>Ft(jt,cn(zt));const ze={labelCol:{span:4},wrapperCol:{span:20}};var ke=({callback:jt,onCancel:zt})=>{function Ct(Yt){jt(Yt)}return Ne.createElement(st.default,nt(Dn({},ze),{initialValues:{link:"http://",title:""},className:"link-panel",onFinish:Ct,style:{width:500}}),Ne.createElement(st.default.Item,{label:"\u94FE\u63A5\u5730\u5740",name:"link",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u5730\u5740"}]},Ne.createElement(it.default,null)),Ne.createElement(st.default.Item,{label:"\u94FE\u63A5\u6807\u9898",name:"title",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u6807\u9898"}]},Ne.createElement(it.default,null)),Ne.createElement("div",{className:"flex-container flex-end"},Ne.createElement(Nt.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),Ne.createElement(Nt.ZP,{type:"ghost",onClick:zt},"\u53D6\u6D88")))},Wt=De(57444),On=De(70859),Lt=De(62844),xn=De(71230),vn=De(63205),Xn=De(67294),Ot=({callback:jt,onCancel:zt})=>{const Ct=document.createElement("canvas"),Yt=Ct.getContext("2d");Ct.width=1e3,Ct.height=800,Yt.fillStyle="#ffffff",Yt.fillRect(0,0,Ct.width,Ct.height);const ci=Ct.toDataURL("image/png");return Xn.createElement(Lt.default,{open:!0,width:"100vw",style:{height:"100vh",top:0},footer:null,title:null,closable:!1},Xn.createElement(xn.Z,{style:{height:"100vh"}},Xn.createElement(vn.Z,{fullWidth:!0,noAssociationId:!0,showFullTools:!0,data:{src:ci,visible:!0,title:String(Date.now())},onOk:vi=>{jt({src:vi.url})},onClose:zt})))},ft=De(23495);function Gt(){go.CommandHandler.call(this),this._arrowKeyBehavior="move",this._pasteOffset=new go.Point(10,10),this._lastPasteOffset=new go.Point(0,0)}go.Diagram.inherit(Gt,go.CommandHandler),Gt.prototype.canAlignSelection=function(){var jt=this.diagram;return!(jt===null||jt.isReadOnly||jt.isModelReadOnly||jt.selection.count<2)},Gt.prototype.alignLeft=function(){var jt=this.diagram;jt.startTransaction("aligning left");var zt=1/0;jt.selection.each(function(Ct){Ct instanceof go.Link||(zt=Math.min(Ct.position.x,zt))}),jt.selection.each(function(Ct){Ct instanceof go.Link||Ct.move(new go.Point(zt,Ct.position.y))}),jt.commitTransaction("aligning left")},Gt.prototype.alignRight=function(){var jt=this.diagram;jt.startTransaction("aligning right");var zt=-1/0;jt.selection.each(function(Ct){if(!(Ct instanceof go.Link)){var Yt=Ct.actualBounds.x+Ct.actualBounds.width;zt=Math.max(Yt,zt)}}),jt.selection.each(function(Ct){Ct instanceof go.Link||Ct.move(new go.Point(zt-Ct.actualBounds.width,Ct.position.y))}),jt.commitTransaction("aligning right")},Gt.prototype.alignTop=function(){var jt=this.diagram;jt.startTransaction("alignTop");var zt=1/0;jt.selection.each(function(Ct){Ct instanceof go.Link||(zt=Math.min(Ct.position.y,zt))}),jt.selection.each(function(Ct){Ct instanceof go.Link||Ct.move(new go.Point(Ct.position.x,zt))}),jt.commitTransaction("alignTop")},Gt.prototype.alignBottom=function(){var jt=this.diagram;jt.startTransaction("aligning bottom");var zt=-1/0;jt.selection.each(function(Ct){if(!(Ct instanceof go.Link)){var Yt=Ct.actualBounds.y+Ct.actualBounds.height;zt=Math.max(Yt,zt)}}),jt.selection.each(function(Ct){Ct instanceof go.Link||Ct.move(new go.Point(Ct.actualBounds.x,zt-Ct.actualBounds.height))}),jt.commitTransaction("aligning bottom")},Gt.prototype.alignCenterX=function(){var jt=this.diagram,zt=jt.selection.first();if(zt){jt.startTransaction("aligning Center X");var Ct=zt.actualBounds.x+zt.actualBounds.width/2;jt.selection.each(function(Yt){Yt instanceof go.Link||Yt.move(new go.Point(Ct-Yt.actualBounds.width/2,Yt.actualBounds.y))}),jt.commitTransaction("aligning Center X")}},Gt.prototype.alignCenterY=function(){var jt=this.diagram,zt=jt.selection.first();if(zt){jt.startTransaction("aligning Center Y");var Ct=zt.actualBounds.y+zt.actualBounds.height/2;jt.selection.each(function(Yt){Yt instanceof go.Link||Yt.move(new go.Point(Yt.actualBounds.x,Ct-Yt.actualBounds.height/2))}),jt.commitTransaction("aligning Center Y")}},Gt.prototype.alignColumn=function(jt){var zt=this.diagram;zt.startTransaction("align Column"),jt===void 0&&(jt=0),jt=parseFloat(jt);var Ct=new Array;zt.selection.each(function(Kt){Kt instanceof go.Link||Ct.push(Kt)});for(var Yt=0;Yt<Ct.length-1;Yt++){var ci=Ct[Yt],vi=ci.actualBounds.y+ci.actualBounds.height+jt,ai=Ct[Yt+1];ai.move(new go.Point(ci.actualBounds.x,vi))}zt.commitTransaction("align Column")},Gt.prototype.alignRow=function(jt){jt===void 0&&(jt=0),jt=parseFloat(jt);var zt=this.diagram;zt.startTransaction("align Row");var Ct=new Array;zt.selection.each(function(Kt){Kt instanceof go.Link||Ct.push(Kt)});for(var Yt=0;Yt<Ct.length-1;Yt++){var ci=Ct[Yt],vi=ci.actualBounds.x+ci.actualBounds.width+jt,ai=Ct[Yt+1];ai.move(new go.Point(vi,ci.actualBounds.y))}zt.commitTransaction("align Row")},Gt.prototype.canRotate=function(jt){var zt=this.diagram;return!(zt===null||zt.isReadOnly||zt.isModelReadOnly||zt.selection.count<1)},Gt.prototype.rotate=function(jt){jt===void 0&&(jt=90);var zt=this.diagram;zt.startTransaction("rotate "+jt.toString());var zt=this.diagram;zt.selection.each(function(Ct){Ct instanceof go.Link||Ct instanceof go.Group||(Ct.angle+=jt)}),zt.commitTransaction("rotate "+jt.toString())},Gt.prototype.pullToFront=function(){var jt=this.diagram;jt.startTransaction("pullToFront");var zt=new go.Map;jt.selection.each(function(Ct){zt.set(Ct.layer,0)}),zt.iteratorKeys.each(function(Ct){var Yt=0;Ct.parts.each(function(ci){if(!ci.isSelected){var vi=ci.zOrder;isNaN(vi)?ci.zOrder=0:Yt=Math.max(Yt,vi)}}),zt.set(Ct,Yt)}),jt.selection.each(function(Ct){Gt._assignZOrder(Ct,zt.get(Ct.layer)+1)}),jt.commitTransaction("pullToFront")},Gt.prototype.pushToBack=function(){var jt=this.diagram;jt.startTransaction("pushToBack");var zt=new go.Map;jt.selection.each(function(Ct){zt.set(Ct.layer,0)}),zt.iteratorKeys.each(function(Ct){var Yt=0;Ct.parts.each(function(ci){if(!ci.isSelected){var vi=ci.zOrder;isNaN(vi)?ci.zOrder=0:Yt=Math.min(Yt,vi)}}),zt.set(Ct,Yt)}),jt.selection.each(function(Ct){Gt._assignZOrder(Ct,zt.get(Ct.layer)-1-Gt._findGroupDepth(Ct))}),jt.commitTransaction("pushToBack")},Gt._assignZOrder=function(jt,zt,Ct){Ct===void 0&&(Ct=jt),jt.layer===Ct.layer&&(jt.zOrder=zt),jt instanceof go.Group&&jt.memberParts.each(function(Yt){Gt._assignZOrder(Yt,zt+1,Ct)})},Gt._findGroupDepth=function(jt){if(jt instanceof go.Group){var zt=0;return jt.memberParts.each(function(Ct){zt=Math.max(zt,Gt._findGroupDepth(Ct))}),zt+1}else return 0},Gt.prototype.doKeyDown=function(){var jt=this.diagram;if(jt!==null){var zt=jt.lastInput;if(zt.key==="Up"||zt.key==="Down"||zt.key==="Left"||zt.key==="Right"){var Ct=this.arrowKeyBehavior;if(Ct==="none")return;if(Ct==="select"){this._arrowKeySelect();return}else if(Ct==="move"){this._arrowKeyMove();return}else if(Ct==="tree"){this._arrowKeyTree();return}}go.CommandHandler.prototype.doKeyDown.call(this)}},Gt.prototype._getAllParts=function(){var jt=new Array;return this.diagram.nodes.each(function(zt){jt.push(zt)}),this.diagram.parts.each(function(zt){jt.push(zt)}),jt},Gt.prototype._arrowKeyMove=function(){var jt=this.diagram,zt=jt.lastInput,Ct=0,Yt=0;if(zt.control||zt.meta)Ct=1,Yt=1;else if(jt.grid!==null){var ci=jt.grid.gridCellSize;Yt=ci.width,Ct=ci.height}jt.startTransaction("arrowKeyMove"),jt.selection.each(function(vi){zt.key==="Up"?vi.move(new go.Point(vi.actualBounds.x,vi.actualBounds.y-Ct)):zt.key==="Down"?vi.move(new go.Point(vi.actualBounds.x,vi.actualBounds.y+Ct)):zt.key==="Left"?vi.move(new go.Point(vi.actualBounds.x-Yt,vi.actualBounds.y)):zt.key==="Right"&&vi.move(new go.Point(vi.actualBounds.x+Yt,vi.actualBounds.y))}),jt.commitTransaction("arrowKeyMove")},Gt.prototype._arrowKeySelect=function(){var jt=this.diagram,zt=jt.lastInput,Ct=null;zt.key==="Up"?Ct=this._findNearestPartTowards(270):zt.key==="Down"?Ct=this._findNearestPartTowards(90):zt.key==="Left"?Ct=this._findNearestPartTowards(180):zt.key==="Right"&&(Ct=this._findNearestPartTowards(0)),Ct!==null&&(zt.shift?Ct.isSelected=!0:zt.control||zt.meta?Ct.isSelected=!Ct.isSelected:jt.select(Ct))},Gt.prototype._findNearestPartTowards=function(jt){var zt=this.diagram.selection.first();if(zt===null)return null;for(var Ct=zt.actualBounds.center,Yt=this._getAllParts(),ci=1/0,vi=zt,ai=0;ai<Yt.length;ai++){var Kt=Yt[ai];if(Kt!==zt&&Kt.canSelect()){var wn=Kt.actualBounds.center,pi=Ct.directionPoint(wn),ji=this._angleCloseness(pi,jt);if(ji<=45){var Rn=Ct.distanceSquaredPoint(wn);Rn*=1+Math.sin(ji*Math.PI/180),Rn<ci&&(ci=Rn,vi=Kt)}}}return vi},Gt.prototype._angleCloseness=function(jt,zt){return Math.min(Math.abs(zt-jt),Math.min(Math.abs(zt+360-jt),Math.abs(zt-360-jt)))},Gt.prototype._arrowKeyTree=function(){var jt=this.diagram,zt=jt.selection.first();if(zt instanceof go.Node){var Ct=jt.lastInput;if(Ct.key==="Right"){if(!zt.isTreeLeaf)if(!zt.isTreeExpanded)jt.commandHandler.canExpandTree(zt)&&jt.commandHandler.expandTree(zt);else{var Yt=this._sortTreeChildrenByY(zt).first();Yt!==null&&jt.select(Yt)}}else if(Ct.key==="Left")if(!zt.isTreeLeaf&&zt.isTreeExpanded)jt.commandHandler.canCollapseTree(zt)&&jt.commandHandler.collapseTree(zt);else{var ci=zt.findTreeParentNode();ci!==null&&jt.select(ci)}else if(Ct.key==="Up"){var ci=zt.findTreeParentNode();if(ci!==null){var vi=this._sortTreeChildrenByY(ci),ai=vi.indexOf(zt);if(ai>0){for(var Kt=vi.elt(ai-1);Kt!==null&&Kt.isTreeExpanded&&!Kt.isTreeLeaf;){var wn=this._sortTreeChildrenByY(Kt);Kt=wn.last()}Kt!==null&&jt.select(Kt)}else jt.select(ci)}}else if(Ct.key==="Down")if(zt.isTreeExpanded&&!zt.isTreeLeaf){var Yt=this._sortTreeChildrenByY(zt).first();Yt!==null&&jt.select(Yt)}else for(;zt!==null;){var ci=zt.findTreeParentNode();if(ci===null)break;var vi=this._sortTreeChildrenByY(ci),ai=vi.indexOf(zt);if(ai<vi.length-1){jt.select(vi.elt(ai+1));break}else zt=ci}var pi=jt.selection.first();pi!==null&&jt.scrollToRect(pi.actualBounds)}},Gt.prototype._sortTreeChildrenByY=function(jt){var zt=new go.List().addAll(jt.findTreeChildrenNodes());return zt.sort(function(Ct,Yt){var ci=Ct.location,vi=Yt.location;return ci.y<vi.y?-1:ci.y>vi.y?1:ci.x<vi.x?-1:ci.x>vi.x?1:0}),zt},Gt.prototype.copyToClipboard=function(jt){go.CommandHandler.prototype.copyToClipboard.call(this,jt),this._lastPasteOffset.set(this.pasteOffset)},Gt.prototype.pasteFromClipboard=function(){var jt=go.CommandHandler.prototype.pasteFromClipboard.call(this);return this.diagram.moveParts(jt,this._lastPasteOffset),this._lastPasteOffset.add(this.pasteOffset),jt},Object.defineProperty(Gt.prototype,"arrowKeyBehavior",{get:function(){return this._arrowKeyBehavior},set:function(jt){if(jt!=="move"&&jt!=="select"&&jt!=="scroll"&&jt!=="tree"&&jt!=="none")throw new Error('DrawCommandHandler.arrowKeyBehavior must be either "move", "select", "scroll", "tree", or "none", not: '+jt);this._arrowKeyBehavior=jt}}),Object.defineProperty(Gt.prototype,"pasteOffset",{get:function(){return this._pasteOffset},set:function(jt){if(!(jt instanceof go.Point))throw new Error("DrawCommandHandler.pasteOffset must be a Point, not: "+jt);this._pasteOffset.set(jt)}});var an=Gt,Jt=De(18023),Ve=De(15746),be=De(33170),Pe={myPaletteDiv:"myPaletteDiv___Xjz2I",flowChartWrp:"flowChartWrp____f45r",maxH60:"maxH60___Pd4Re"},Be=De(52262),Ze=De(67294),Fe=(jt,zt,Ct)=>new Promise((Yt,ci)=>{var vi=wn=>{try{Kt(Ct.next(wn))}catch(pi){ci(pi)}},ai=wn=>{try{Kt(Ct.throw(wn))}catch(pi){ci(pi)}},Kt=wn=>wn.done?Yt(wn.value):Promise.resolve(wn.value).then(vi,ai);Kt((Ct=Ct.apply(jt,zt)).next())});function qe({onCancel:jt,callback:zt}){let Ct=(0,Ne.useRef)(),Yt=(0,Ne.useRef)(),ci=(0,Ne.useRef)(),vi=(0,Ne.useRef)(!1);const ai=(0,Ne.useRef)(!1),[Kt,wn]=(0,Ne.useState)(0);function pi(){const Rn=ft.bx.make,Dt={red:"#ff3333",blue:"#3358ff",green:"#25ad23",magenta:"#d533ff",purple:"#7d33ff",orange:"#ff6233",brown:"#8e571e",white:"#ffffff",black:"#000000",beige:"#fffcd5",extralightblue:"#d5ebff",extralightred:"#f2dfe0",lightblue:"#a5d2fa",lightgray:"#cccccc",lightgreen:"#b3e6b3",lightred:"#fcbbbd"};Ct.current=new ft.S0(Yt.current,{padding:20,grid:Rn(ft.s_,"Grid",Rn(ft.bn,"LineH",{stroke:"lightgray",strokeWidth:.5}),Rn(ft.bn,"LineV",{stroke:"lightgray",strokeWidth:.5})),"draggingTool.isGridSnapEnabled":!0,handlesDragDropForTopLevelParts:!0,mouseDrop:Vt=>{var Kr=Vt.diagram.commandHandler.addTopLevelParts(Vt.diagram.selection,!0);Kr||Vt.diagram.currentTool.doCancel()},commandHandler:Rn(an),"clickCreatingTool.archetypeNodeData":{text:"\u672A\u547D\u540D",fill:null,stroke:null,borderColor:"rgba(0,0,0,0)"},PartCreated:Vt=>{var Kr=Vt.subject;Kr.location=Kr.location.copy().snapToGridPoint(Vt.diagram.grid.gridOrigin,Vt.diagram.grid.gridCellSize),setTimeout(()=>{Vt.diagram.commandHandler.editTextBlock()},20)},"commandHandler.archetypeGroupData":{isGroup:!0,text:"NEW GROUP"},SelectionGrouped:Vt=>{var Kr=Vt.subject;setTimeout(()=>{Vt.diagram.commandHandler.editTextBlock()})},LinkRelinked:Vt=>{var Kr=Vt.parameter.part;Kr.invalidateConnectedLinks();var Ko=Vt.subject;Vt.diagram.toolManager.linkingTool.isForwards?Ko.toNode.invalidateConnectedLinks():Ko.fromNode.invalidateConnectedLinks()},"undoManager.isEnabled":!0}),Ct.current.nodeTemplate=Rn(ft.NB,"Auto",{locationSpot:ft.z6.Center,locationObjectName:"SHAPE",desiredSize:new ft.$u(120,60),minSize:new ft.$u(40,40),resizable:!0,resizeCellSize:new ft.$u(10,10),rotatable:!0},new ft.KX("location","loc",ft.E9.parse).makeTwoWay(ft.E9.stringify),new ft.KX("desiredSize","size",ft.$u.parse).makeTwoWay(ft.$u.stringify),Rn(ft.bn,{name:"SHAPE",fill:Dt.white,cursor:"pointer",portId:"",fromLinkable:!0,toLinkable:!0,fromLinkableDuplicates:!0,toLinkableDuplicates:!0,fromSpot:ft.z6.AllSides,toSpot:ft.z6.AllSides},new ft.KX("figure"),new ft.KX("fill"),new ft.KX("stroke","borderColor"),new ft.KX("strokeWidth","thickness"),new ft.KX("strokeDashArray","dash")),Rn(ft.bn,{width:100,height:20,strokeWidth:0,fill:"transparent"}),Rn(ft.al,{margin:1,textAlign:"center",overflow:ft.al.OverflowEllipsis,editable:!0},new ft.KX("text").makeTwoWay(),new ft.KX("stroke","color"))),Ct.current.nodeTemplate.toolTip=Rn("ToolTip",Rn(ft.s_,"Vertical",{maxSize:new ft.$u(200,NaN)},Rn(ft.al,{font:"bold 10pt sans-serif",textAlign:"center"},new ft.KX("text")),Rn(ft.al,{font:"10pt sans-serif",textAlign:"center"},new ft.KX("text","details"))));function wi(Vt,Kr){var Ko=(Er,Wa)=>{Er.handled=!0,Er.diagram.model.commit(Wo=>{var ea=Wa.part.adornedPart,fo=new ft.E9().setRectSpot(ea.actualBounds,Vt);fo.subtract(ea.location),fo.scale(2,2),fo.x+=Math.sign(fo.x)*130,fo.y+=Math.sign(fo.y)*130,fo.add(ea.location),fo.snapToGridPoint(Er.diagram.grid.gridOrigin,Er.diagram.grid.gridCellSize);var Oo=Wo.copyNodeData(ea.data);Wo.setGroupKeyForNodeData(Oo,Wo.getGroupKeyForNodeData(ea.data)),Wo.addNodeData(Oo);var xa={from:ea.key,to:Wo.getKeyForNodeData(Oo)};Wo.addLinkData(xa);var An=Er.diagram.findNodeForData(Oo);An.location=fo,Er.diagram.select(An),setTimeout(()=>{Er.diagram.commandHandler.editTextBlock()},20)})};return Rn(ft.bn,{figure:Kr,alignment:Vt,alignmentFocus:Vt.opposite(),width:Vt.equals(ft.z6.Top)||Vt.equals(ft.z6.Bottom)?25:18,height:Vt.equals(ft.z6.Top)||Vt.equals(ft.z6.Bottom)?18:25,fill:"orange",stroke:Dt.white,strokeWidth:4,mouseEnter:(Er,Wa)=>Wa.fill="dodgerblue",mouseLeave:(Er,Wa)=>Wa.fill="orange",isActionable:!0,click:Ko,contextClick:Ko})}function gr(Vt){return Rn(ft.bn,{fill:"orange",stroke:"rgba(0, 0, 0, 0)",strokeWidth:15,background:"transparent",geometryString:"F1 M0 0 b 0 360 -4 0 4 z M10 0 b 0 360 -4 0 4 z M20 0 b 0 360 -4 0 4",isActionable:!0,cursor:"context-menu",mouseEnter:(Kr,Ko)=>Ko.fill="dodgerblue",mouseLeave:(Kr,Ko)=>Ko.fill="orange",click:(Kr,Ko)=>{Kr.diagram.commandHandler.showContextMenu(Ko.part.adornedPart)}},Vt||{})}Ct.current.nodeTemplate.selectionAdornmentTemplate=Rn(ft.uz,"Spot",Rn(ft.Vm,{padding:10}),wi(ft.z6.Top,"TriangleUp"),wi(ft.z6.Left,"TriangleLeft"),wi(ft.z6.Right,"TriangleRight"),wi(ft.z6.Bottom,"TriangleDown"),gr({alignment:new ft.z6(.75,0)}));function eo(Vt,Kr){return(Ko,Er)=>{Ko.handled=!0,Ko.diagram.model.commit(Wa=>{Wa.set(Er.part.adornedPart.data,Vt,Kr)})}}function kn(Vt,Kr){return Kr||(Kr="color"),Rn(ft.bn,{width:16,height:16,stroke:"lightgray",fill:Vt,margin:1,background:"transparent",mouseEnter:(Ko,Er)=>Er.stroke="dodgerblue",mouseLeave:(Ko,Er)=>Er.stroke="lightgray",click:eo(Kr,Vt),contextClick:eo(Kr,Vt)})}function Xi(){return[Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",kn(Dt.white,"fill"),kn(Dt.beige,"fill"),kn(Dt.extralightblue,"fill"),kn(Dt.extralightred,"fill"))),Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",kn(Dt.lightgray,"fill"),kn(Dt.lightgreen,"fill"),kn(Dt.lightblue,"fill"),kn(Dt.lightred,"fill")))]}function Lo(){return[Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",kn(Dt.black),kn(Dt.green),kn(Dt.blue),kn(Dt.red))),Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",kn(Dt.white),kn(Dt.magenta),kn(Dt.purple),kn(Dt.orange)))]}function La(Vt,Kr){return Kr||(Kr="thickness"),Rn(ft.bn,"LineH",{width:16,height:16,strokeWidth:Vt,margin:1,background:"transparent",mouseEnter:(Ko,Er)=>Er.background="dodgerblue",mouseLeave:(Ko,Er)=>Er.background="transparent",click:eo(Kr,Vt),contextClick:eo(Kr,Vt)})}function $o(Vt,Kr){return Kr||(Kr="dash"),Rn(ft.bn,"LineH",{width:24,height:16,strokeWidth:2,strokeDashArray:Vt,margin:1,background:"transparent",mouseEnter:(Ko,Er)=>Er.background="dodgerblue",mouseLeave:(Ko,Er)=>Er.background="transparent",click:eo(Kr,Vt),contextClick:eo(Kr,Vt)})}function qi(){return[Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",La(1),La(2),La(3),La(4))),Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",$o(null),$o([2,4]),$o([4,4])))]}function Zi(Vt,Kr){return Kr||(Kr="figure"),Rn(ft.bn,{width:32,height:32,scale:.5,fill:"lightgray",figure:Vt,margin:1,background:"transparent",mouseEnter:(Ko,Er)=>Er.fill="dodgerblue",mouseLeave:(Ko,Er)=>Er.fill="lightgray",click:eo(Kr,Vt),contextClick:eo(Kr,Vt)})}Ct.current.nodeTemplate.contextMenu=Rn("ContextMenu",Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",Zi("Rectangle"),Zi("RoundedRectangle"),Zi("Ellipse"),Zi("Diamond"))),Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",Zi("Parallelogram2"),Zi("ManualOperation"),Zi("Procedure"),Zi("Cylinder1"))),Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",Zi("Terminator"),Zi("CreateRequest"),Zi("Document"),Zi("TriangleDown"))),Xi(),Lo(),qi()),Ct.current.groupTemplate=Rn(ft.ZA,"Spot",{layerName:"Background",ungroupable:!0,locationSpot:ft.z6.Center,selectionObjectName:"BODY",computesBoundsAfterDrag:!0,handlesDragDropForMembers:!0,mouseDrop:(Vt,Kr)=>{var Ko=Kr.addMembers(Kr.diagram.selection,!0);Ko||Kr.diagram.currentTool.doCancel()},avoidable:!1},new ft.KX("location","loc",ft.E9.parse).makeTwoWay(ft.E9.stringify),Rn(ft.s_,"Auto",{name:"BODY"},Rn(ft.bn,{parameter1:10,fill:Dt.white,strokeWidth:2,cursor:"pointer",fromLinkable:!0,toLinkable:!0,fromLinkableDuplicates:!0,toLinkableDuplicates:!0,fromSpot:ft.z6.AllSides,toSpot:ft.z6.AllSides},new ft.KX("fill"),new ft.KX("stroke","color"),new ft.KX("strokeWidth","thickness"),new ft.KX("strokeDashArray","dash")),Rn(ft.Vm,{background:"transparent",margin:20})),Rn(ft.al,{alignment:ft.z6.Top,alignmentFocus:ft.z6.Bottom,font:"bold 12pt sans-serif",editable:!0},new ft.KX("text"),new ft.KX("stroke","color"))),Ct.current.groupTemplate.selectionAdornmentTemplate=Rn(ft.uz,"Spot",Rn(ft.s_,"Auto",Rn(ft.bn,{fill:null,stroke:"dodgerblue",strokeWidth:3}),Rn(ft.Vm,{margin:1.5})),gr({alignment:ft.z6.TopRight,alignmentFocus:ft.z6.BottomRight})),Ct.current.groupTemplate.contextMenu=Rn("ContextMenu",Xi(),Lo(),qi()),Ct.current.linkTemplate=Rn(ft.rU,{layerName:"Foreground",routing:ft.rU.AvoidsNodes,corner:10,fromShortLength:10,toShortLength:15,relinkableFrom:!0,relinkableTo:!0,reshapable:!0,resegmentable:!0},new ft.KX("fromSpot","fromSpot",ft.z6.parse),new ft.KX("toSpot","toSpot",ft.z6.parse),new ft.KX("fromShortLength","dir",Vt=>Vt>=1?10:0),new ft.KX("toShortLength","dir",Vt=>Vt>=1?10:0),new ft.KX("points").makeTwoWay(),Rn(ft.bn,{strokeWidth:2},new ft.KX("stroke","color"),new ft.KX("strokeWidth","thickness"),new ft.KX("strokeDashArray","dash")),Rn(ft.bn,{segmentIndex:0,segmentOffset:new ft.E9(15,0),segmentOrientation:ft.rU.OrientAlong,alignmentFocus:ft.z6.Right,figure:"circle",width:10,strokeWidth:0},new ft.KX("fill","color"),new ft.KX("visible","dir",Vt=>Vt===1)),Rn(ft.bn,{segmentIndex:-1,segmentOffset:new ft.E9(-10,6),segmentOrientation:ft.rU.OrientPlus90,alignmentFocus:ft.z6.Right,figure:"triangle",width:12,height:12,strokeWidth:0},new ft.KX("fill","color"),new ft.KX("visible","dir",Vt=>Vt>=1),new ft.KX("width","thickness",Vt=>7+3*Vt),new ft.KX("height","thickness",Vt=>7+3*Vt),new ft.KX("segmentOffset","thickness",Vt=>new ft.E9(-15,4+1.5*Vt))),Rn(ft.bn,{segmentIndex:0,segmentOffset:new ft.E9(15,-6),segmentOrientation:ft.rU.OrientMinus90,alignmentFocus:ft.z6.Right,figure:"triangle",width:12,height:12,strokeWidth:0},new ft.KX("fill","color"),new ft.KX("visible","dir",Vt=>Vt===2),new ft.KX("width","thickness",Vt=>7+3*Vt),new ft.KX("height","thickness",Vt=>7+3*Vt),new ft.KX("segmentOffset","thickness",Vt=>new ft.E9(-15,4+1.5*Vt))),Rn(ft.al,{alignmentFocus:new ft.z6(0,1,-4,0),editable:!0},new ft.KX("text").makeTwoWay(),new ft.KX("stroke","color"))),Ct.current.linkTemplate.selectionAdornmentTemplate=Rn(ft.uz,Rn(ft.bn,{isPanelMain:!0,stroke:"transparent",strokeWidth:6,pathPattern:cr(2)},new ft.KX("pathPattern","thickness",cr)),gr({alignmentFocus:new ft.z6(0,0,-6,-4)}));function cr(Vt){return Rn(ft.bn,{stroke:"dodgerblue",strokeWidth:2,strokeCap:"square",geometryString:"M0 0 M4 2 H3 M4 "+(Vt+4).toString()+" H3"})}function Co(Vt){var Kr="M0 0 M8 16 M0 8 L16 8 M12 11 L16 8 L12 5";return Vt===0?Kr="M0 0 M16 16 M0 8 L16 8":Vt===2&&(Kr="M0 0 M16 16 M0 8 L16 8 M12 11 L16 8 L12 5 M4 11 L0 8 L4 5"),Rn(ft.bn,{geometryString:Kr,margin:2,background:"transparent",mouseEnter:(Ko,Er)=>Er.background="dodgerblue",mouseLeave:(Ko,Er)=>Er.background="transparent",click:eo("dir",Vt),contextClick:eo("dir",Vt)})}function Zo(Vt){var Kr=(Ko,Er)=>{Ko.handled=!0,Ko.diagram.model.commit(Wa=>{var Wo=Er.part.adornedPart;Wa.set(Wo.data,Vt?"toSpot":"fromSpot",ft.z6.stringify(ft.z6.AllSides)),(Vt?Wo.toNode:Wo.fromNode).invalidateConnectedLinks()})};return Rn(ft.bn,{width:12,height:12,fill:"transparent",mouseEnter:(Ko,Er)=>Er.background="dodgerblue",mouseLeave:(Ko,Er)=>Er.background="transparent",click:Kr,contextClick:Kr})}function ri(Vt,Kr){var Ko=0,Er=ft.z6.RightSide;Vt.equals(ft.z6.Top)?(Ko=270,Er=ft.z6.TopSide):Vt.equals(ft.z6.Left)?(Ko=180,Er=ft.z6.LeftSide):Vt.equals(ft.z6.Bottom)&&(Ko=90,Er=ft.z6.BottomSide),Kr||(Ko-=180);var Wa=(Wo,ea)=>{Wo.handled=!0,Wo.diagram.model.commit(fo=>{var Oo=ea.part.adornedPart;fo.set(Oo.data,Kr?"toSpot":"fromSpot",ft.z6.stringify(Er)),(Kr?Oo.toNode:Oo.fromNode).invalidateConnectedLinks()})};return Rn(ft.bn,{alignment:Vt,alignmentFocus:Vt.opposite(),geometryString:"M0 0 M12 12 M12 6 L1 6 L4 4 M1 6 L4 8",angle:Ko,background:"transparent",mouseEnter:(Wo,ea)=>ea.background="dodgerblue",mouseLeave:(Wo,ea)=>ea.background="transparent",click:Wa,contextClick:Wa})}Ct.current.linkTemplate.contextMenu=Rn("ContextMenu",Lo(),qi(),Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",Co(0),Co(1),Co(2))),Rn("ContextMenuButton",Rn(ft.s_,"Horizontal",Rn(ft.s_,"Spot",Zo(!1),ri(ft.z6.Top,!1),ri(ft.z6.Left,!1),ri(ft.z6.Right,!1),ri(ft.z6.Bottom,!1)),Rn(ft.s_,"Spot",{margin:new ft.Zt(0,0,0,2)},Zo(!0),ri(ft.z6.Top,!0),ri(ft.z6.Left,!0),ri(ft.z6.Right,!0),ri(ft.z6.Bottom,!0)))));const Lr=`{ "class": "GraphLinksModel",
"nodeDataArray": [
{"text":"Find Problem","key":-9,"loc":"-20 -140","color":"#3358ff","fill":"white","figure":"Procedure","thickness":3},
{"text":"What do we want?","key":-10,"loc":"-65 -324.305","group":-16,"figure":"Ellipse","fill":"white"},
{"text":"What do our users want?","key":-11,"loc":"105 -334.305","group":-20,"figure":"Ellipse","fill":"#ffffff","color":"black"},
{"text":"Meetings","key":-12,"loc":"-65 -444.305","group":-16,"figure":"TriangleDown","fill":"#ffffff"},
{"text":"Reviews","key":-13,"loc":"105 -454.305","group":-20,"figure":"TriangleDown","fill":"#ffffff","color":"black"},
{"text":"Can we solve it?","key":-14,"loc":"190 -140","color":"#7d33ff","fill":"#ffffff","figure":"Diamond","size":"140 80","thickness":3},
{"isGroup":true,"text":"Internal","key":-16,"loc":"-65 -384.305","fill":"#d5ebff","dash":null,"thickness":1,"group":-22},
{"isGroup":true,"text":"External","key":-20,"loc":"105 -394.305","fill":"#d5ebff","dash":null,"thickness":1,"group":-22},
{"isGroup":true,"text":"Sources","key":-22,"loc":"20 -400","fill":"#a5d2fa","dash":[4,4],"color":"#3358ff"}
],
"linkDataArray": [
{"from":-12,"to":-10,"points":[-65,-414.305,-65,-404.305,-65,-384.305,-65,-384.305,-65,-364.305,-65,-354.305],"dash":null,"dir":1},
{"from":-13,"to":-11,"points":[105,-424.305,105,-414.305,105,-394.305,105,-394.305,105,-374.305,105,-364.305],"dash":null,"color":"#000000","dir":1},
{"from":-10,"to":-9,"points":[-65,-294.305,-65,-284.305,-65,-232.1525,-40,-232.1525,-40,-180,-40,-170],"dir":2,"dash":[4,4]},
{"from":-11,"to":-9,"points":[105,-304.305,105,-294.305,105,-237.1525,0,-237.1525,0,-180,0,-170],"dash":[4,4],"dir":2},
{"from":-9,"to":-14,"points":[40,-150,58,-150,80,-150,80,-153.33333333333331,102,-153.33333333333331,120,-153.33333333333331],"dir":1,"color":"#3358ff"},
{"from":-14,"to":-9,"points":[190,-100,190,-90,-20,-90,-20,-95,-20,-100,-20,-110],"fromSpot":"BottomSide","toSpot":"BottomSide","text":"No","color":"#ff3333","thickness":2,"dir":1},
{"from":-9,"to":-14,"points":[40,-130,58,-130,80,-130,80,-126.66666666666666,102,-126.66666666666666,120,-126.66666666666666]}
]}`;var ml=["Rectangle","Square","RoundedRectangle","Border","Ellipse","Circle","TriangleRight","TriangleDown","TriangleLeft","TriangleUp","Triangle","Diamond","LineH","LineV","None","BarH","BarV","MinusLine","PlusLine","XLine","LineRight","LineDown","LineLeft","LineUp"];function Fs(Vt){return console.log("shapeName:",Vt),ml.indexOf(Vt)>=0}var gs=new ft.YI(ci.current,{maxSelectionCount:1,linkTemplate:Rn(ft.rU,{locationSpot:ft.z6.Center,selectionAdornmentTemplate:Rn(ft.uz,"Link",{locationSpot:ft.z6.Center},Rn(ft.bn,{isPanelMain:!0,fill:null,stroke:"deepskyblue",strokeWidth:0}),Rn(ft.bn,{toArrow:"Standard",stroke:null}))},{routing:ft.rU.AvoidsNodes,curve:ft.rU.JumpOver,corner:5,toShortLength:4},new ft.KX("points"),Rn(ft.bn,{isPanelMain:!0,strokeWidth:2}),Rn(ft.bn,{toArrow:"Standard",stroke:null})),model:new ft.FJ([{text:"\u672A\u547D\u540D",size:"100 100",fill:null,stroke:"#000"},...ft.bn.getFigureGenerators().toArray().map(Vt=>({text:"\u672A\u547D\u540D",size:"100 100",figure:Vt.key,fill:"white",stroke:"#666",borderColor:"#000"}))])});return Ct.current.addDiagramListener("TextEdited",function(Vt){var Kr;const Ko=Vt.subject.part;var Er=(Kr=document.activeElement)==null?void 0:Kr.value;typeof Er=="string"&&Er.trim()===""&&Ct.current.model.commit(function(Wa){Wa.set(Ko.data,"text","\u672A\u547D\u540D"),Ct.current.commandHandler.stopCommand()},"increment")}),gs.nodeTemplate=Rn(ft.NB,"Auto",{locationSpot:ft.z6.Center},new ft.KX("location","location",ft.E9.parse).makeTwoWay(ft.E9.stringify),Rn(ft.bn,"Circle",{fill:"white",stroke:"gray",strokeWidth:2,width:20,height:20,portId:"",fromLinkable:!0,toLinkable:!0,fromLinkableDuplicates:!0,toLinkableDuplicates:!0,fromLinkableSelfNode:!0,toLinkableSelfNode:!0},new ft.KX("stroke").makeTwoWay(),new ft.KX("fill").makeTwoWay(),new ft.KX("figure")),Rn(ft.al,{margin:new ft.Zt(5,5,3,5),font:"10pt sans-serif",minSize:new ft.$u(16,16),maxSize:new ft.$u(10,NaN),textAlign:"center",editable:!0},new ft.KX("key").makeTwoWay())),setTimeout(()=>{Ct.current.grid=Rn(ft.s_,"Grid",Rn(ft.bn,"LineH",{stroke:"lightgray",strokeWidth:.5}),Rn(ft.bn,"LineV",{stroke:"lightgray",strokeWidth:.5})),Ct.current.grid.visible=!0,Ct.current.grid.gridCellStroke="darkgray",Ct.current.grid.gridCellStrokeWidth=1},300),window.myDiagrams=Ct.current,Ct.current}const ji=()=>Fe(this,null,function*(){var Rn,Dt=Ct.current.makeImage();const wi=yield(0,be.ZP)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:Date.now(),file:Dt.src,file_data:JSON.stringify({login:(Rn=(0,Be.eY)())==null?void 0:Rn.login,data:JSON.parse(Ct.current.model.toJson())})}});zt({src:wi.url})});return(0,Ne.useEffect)(()=>(setTimeout(()=>{pi()},500),wn(Kt+1),()=>{Ct.current=null}),[]),Ze.createElement("div",{ref:ai,className:"body-overflow-initial"},Ze.createElement(Lt.default,{width:1200,icon:null,footer:null,closable:!0,visible:!!Kt,destroyOnClose:!0,maskClosable:!1,rootClassName:"zIndex-9999",title:Ze.createElement(xn.Z,null,Ze.createElement(Ve.Z,{flex:1},"\u63D2\u5165\u6D41\u7A0B\u56FE"),Ze.createElement(Ve.Z,{onClick:()=>{var Rn,Dt,wi=Ct.current.selection.first();if(vi.current=!vi.current,document.activeElement&&wi){let gr=(Dt=(Rn=document.activeElement)==null?void 0:Rn.value)==null?void 0:Dt.trim();typeof gr=="string"&&Ct.current.model.commit(function(eo){eo.set(wi.data,"text",gr||"\u672A\u547D\u540D"),Ct.current.commandHandler.stopCommand()},"increment")}wn(Kt+1)}},Ze.createElement("span",{className:"current c-blue mr30",style:{fontWeight:400}},"\u5C55\u5F00/\u6536\u8D77"))),onCancel:jt},Ze.createElement("div",{style:{width:"100%",height:"80vh",overflow:"hidden",position:"relative",display:vi.current?"none":"block"},className:Pe.flowChartWrp},Ze.createElement("div",{style:{display:"flex",height:"100%"}},Ze.createElement("div",{style:{width:"300px",height:"100%"}},Ze.createElement("div",{style:{background:"#fff",position:"relative",zIndex:12,fontSize:16,color:"#3061d0"}},"\u56FE\u5F62\u5E93"),Ze.createElement("div",{style:{height:"calc(100% - 50px)"},className:Pe.myPaletteDiv,ref:ci})),Ze.createElement("div",{style:{flex:1,position:"relative"}},Ze.createElement("div",{ref:Yt,style:{height:"80vh"}}))),Ze.createElement("div",{className:"tr"},Ze.createElement(Nt.ZP,{size:"large",onClick:ji,style:{position:"absolute",right:0,bottom:0,zIndex:8},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668")))))}var dn=qe,ui=De(98813),$n=De(37720);const rn=ui.ZP.Group,Hn={margin:"0 8px"};var Zt=({callback:jt,onCancel:zt})=>{function Ct(Yt){jt(Yt)}return Ne.createElement(st.default,{className:"add-table-panel",initialValues:{row:3,col:2,align:"default"},onFinish:Ct},Ne.createElement("div",{className:"flex-container",style:{alignItems:"baseline"}},Ne.createElement("span",{style:Hn},"\u5355\u5143\u683C\u6570\uFF1A"),Ne.createElement("span",{style:Hn},"\u884C\u6570"),Ne.createElement(st.default.Item,{name:"row",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u884C\u6570"}]},Ne.createElement($n.Z,null)),Ne.createElement("span",{style:Hn},"\u5217\u6570"),Ne.createElement(st.default.Item,{name:"col",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5217\u6570"}]},Ne.createElement($n.Z,null))),Ne.createElement("div",{className:"flex-container",style:{marginTop:12,alignItems:"baseline"}},Ne.createElement("span",{style:Hn},"\u5BF9\u9F50\u65B9\u5F0F\uFF1A"),Ne.createElement(st.default.Item,{name:"align"},Ne.createElement(rn,null,Ne.createElement(ui.ZP,{value:"default"},Ne.createElement("i",{className:"fa fa-align-justify"})),Ne.createElement(ui.ZP,{value:"left"},Ne.createElement("i",{className:"fa fa-align-left"})),Ne.createElement(ui.ZP,{value:"center"},Ne.createElement("i",{className:"fa fa-align-center"})),Ne.createElement(ui.ZP,{value:"right"},Ne.createElement("i",{className:"fa fa-align-right"}))))),Ne.createElement("div",{className:"flex-container flex-end"},Ne.createElement(Nt.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),Ne.createElement(Nt.ZP,{type:"ghost",onClick:zt},"\u53D6\u6D88")))},_n=De(59637),ti=De(61016),Ri=De.n(ti),wr=(0,Ne.forwardRef)(({use3d:jt,width:zt,height:Ct,callback:Yt,showSaveButton:ci},vi)=>{const ai=(0,Ne.useRef)(),Kt=(0,Ne.useRef)(),[wn,pi]=(0,Ne.useState)(!1),ji=(0,Ne.useRef)({id:ai,appName:"graphing",width:zt||1e3,height:Ct||600,showToolBar:!0,showMenuBar:!0,allowStyleBar:!0,showAlgebraInput:!0,enableLabelDrags:!1,enableShiftDragZoom:!0,showToolBarHelp:!1,errorDialogsActive:!0,showTutorialLink:!0,showLogging:!0,useBrowserForJS:!1});(0,Ne.useEffect)(()=>{Kt.current=new(Ri())(ji.current,!0),window.onload=function(){Kt.current.inject("applet_container")}},[]);const Rn=()=>{var Dt=window.ggbApplet.getPNGBase64(1,!0,72);return Yt&&Yt(Dt),Dt};return(0,Ne.useEffect)(()=>{ji.current.appName=wn?"3D":"graphing",Kt.current.inject("applet_container")},[wn]),(0,Ne.useEffect)(()=>{pi(jt)},[jt]),(0,Ne.useImperativeHandle)(vi,()=>({getImgData:Rn})),Ne.createElement(Ne.Fragment,null,Ne.createElement("div",{style:{width:"100%",height:"100%"},id:"applet_container",ref:ai}),Ne.createElement(xn.Z,{align:"middle"},Ne.createElement(Ve.Z,{flex:1},Ne.createElement(_n.Z,{size:"default",checkedChildren:"\u5173\u95ED3D\u56FE\u50CF",unCheckedChildren:"\u5F00\u542F3D\u56FE\u50CF",checked:wn,onChange:Dt=>pi(Dt)})),Ne.createElement(Ve.Z,null,Ne.createElement(Nt.ZP,{size:"large",onClick:Rn,style:{zIndex:8,marginTop:10},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668"))))}),fr=De(36527),Ei=De(2453);const Di="link",uo="upload-image",vt="add-flowchart",ei="draw-image",co="add-flowchart",bo="code-block",Ui="add-table",yo="------------",ha={default:yo,left:`:${yo}`,center:`:${yo}:`,right:`${yo}:`};var Ka=De(99914);function Ra(){}let ca=0;const ma=1e4,Ho="\u2581",_r="@\u2581\u2581@",Fn="@\u2581@",we=`
**\u6A21\u677F\u6807\u9898**
\u6A21\u677F\u6B63\u6587\u5185\u5BB9\uFF0C\u53EF\u8F93\u5165\u6587\u672C\u5185\u5BB9\u548C\u7C98\u8D34\u56FE\u7247\u7B49\u64CD\u4F5C`,Qn=["pptm","pptx","ppt","pot","pps","ppa","potx","ppsx","ppam","pptm","potm","ppsm","doc","docx","dot","dotx","docm","dotm","xls","xlsx","csv","xlt","xla","xltx","xlsm","xltm","xlam","xlsb"];function bn(jt){return/^\d+$/.test(jt)?`${jt}px`:jt}const ln=navigator.platform.toUpperCase().indexOf("MAC")>=0?"Cmd":"Ctrl",gn={[ln+"-B"]:"bold",[ln+"-I"]:"italic"},Vn={[Di]:"\u6DFB\u52A0\u94FE\u63A5",[bo]:"\u6DFB\u52A0\u4EE3\u7801\u5757",[uo]:"\u6DFB\u52A0\u56FE\u7247",[ei]:"\u6DFB\u52A0\u753B\u56FE",[vt]:"\u63D2\u5165\u6D41\u7A0B\u56FE",[Ui]:"\u6DFB\u52A0\u8868\u683C","maths-latex":"\u6570\u5B66\u56FE\u50CF","inline-latex":"LATEX\u516C\u5F0F"};var _i=({defaultValue:jt="",onChange:zt,width:Ct="100%",height:Yt=400,miniToolbar:ci=!1,isFocus:vi=!1,watch:ai,insertTemp:Kt,mode:wn="markdown",id:pi="markdown-editor-id",showResizeBar:ji=!1,noStorage:Rn=!1,showNullButton:Dt=!1,showNullProgramButton:wi=!1,hidetoolBar:gr=!1,fullScreen:eo=!1,onBlur:kn,onCMBeforeChange:Xi,onFullScreen:Lo,className:La="",disablePaste:$o=!1,disabled:qi=!1,disabledFill:Zi=!1,placeholder:cr="",values:Co="",extraUse:Zo})=>{const[ri,Lr]=(0,Ne.useState)(null),[ml,Fs]=(0,Ne.useState)(jt),[gs,Vt]=(0,Ne.useState)(ai),[Kr,Ko]=(0,Ne.useState)(eo),[Er,Wa]=(0,Ne.useState)(""),[Wo,ea]=(0,Ne.useState)(0),[fo,Oo]=(0,Ne.useState)(Yt),[xa,An]=(0,Ne.useState)(!1),[Ya,Pn]=(0,Ne.useState)(0),[jo,Ws]=(0,Ne.useState)(0),qa=(0,Ne.useRef)(),bl=(0,Ne.useRef)(),Xa=(0,Ne.useRef)(),_o=(0,Ne.useRef)();(0,Ne.useEffect)(()=>{const Or=window.scrollY||window.pageYOffset;Fs(Co),ri==null||ri.setValue(Co),window.scrollTo(0,Or)},[Co]),(0,Ne.useEffect)(()=>{Lo==null||Lo(Kr)},[Kr]),(0,Ne.useEffect)(()=>{if(qa.current){let Or=function(so,fn){var jr;if($o){fn.preventDefault();return}const Ao=fn.clipboardData;if(Ao){const $a=Ao.types.toString(),Ia=Ao.items;if($a==="Files"||Ao.types.indexOf("Files")>-1){if(fn.preventDefault(),wn=="stex")return;try{let ms=Ia[1];((jr=Ia[0])==null?void 0:jr.kind)==="file"&&(ms=Ia[0]);const Vs=ms.getAsFile(),el=Vs.name.split(".").pop();(0,On.I)(Vs,vl=>{var Gu,Fu,Xt;vl.id?((Gu=Vs==null?void 0:Vs.type)==null?void 0:Gu.indexOf("image"))>-1?Pr.replaceSelection(`<img width="100%" src="/api/attachments/${vl.id}?type=${vl.content_type})" alt="" />`):((Fu=Vs==null?void 0:Vs.type)==null?void 0:Fu.indexOf("video"))>-1?Pr.replaceSelection(`<video width="100%" controls src="/api/attachments/${vl.id}"></video>`):((Xt=Vs==null?void 0:Vs.type)==null?void 0:Xt.indexOf("pdf"))>-1?Pr.replaceSelection(`<a href="/api/attachments/${vl.id}?type=${Vs.type}&disposition=inline" target="_blank">${Vs.name}</a>`):Qn.includes(el)?Pr.replaceSelection(`<a href="/api/attachments/${vl.id}?type=office&disposition=inline" target="_blank">${Vs.name}</a>`):Pr.replaceSelection(`[${Vs.name}](/api/attachments/${vl.id}?type=${vl.content_type})`):(vl==null?void 0:vl.status)===401&&(document.location.href="/user/login")})}catch(ms){Ei.ZP.warning("\u8BF7\u4F7F\u7528chrome\u6D4F\u89C8\u5668\u7C98\u8D34")}return!0}else return!0}return!0};const Pr=Ut().fromTextArea(qa.current,{mode:wn,lineNumbers:!ci,lineWrapping:!0,value:jt,autoCloseTags:!0,autoCloseBrackets:!0});return Pr.on("keyup",function(so,fn){fn.keyCode===8&&(so.getValue()==""?Pr.setOption("placeholder",cr):Pr.setOption("placeholder",null))}),Pr.on("keydown",function(so,fn){if(fn.keyCode===8){var jr=il(so);jr&&fn.preventDefault()}}),vi&&Pr.focus(),Pr.on("paste",Or),qi&&Pr.on("beforeChange",function(so,fn){(fn.origin==="paste"||fn.origin==="+input")&&fn.cancel()}),Lr(Pr),()=>{Pr.off("paste",Or)}}},[]);const Va=(0,Ne.useCallback)(()=>{if(bl.current)try{}catch(Or){console.log(Or,"---- to set md editor body height")}},[fo,bl,Kr]);(0,Ne.useEffect)(()=>{function Or(){let Pr=new $t.Z(so=>{for(let fn of so)(fn.target.offsetHeight>0||fn.target.offsetWidth>0)&&(Va(),ri.setSize("100%","100%"),ri.refresh())});return Pr.observe(qa.current.parentElement),Pr}if(ri){const Pr=Or();return()=>{var so,fn;(so=qa.current)!=null&&so.parentElement&&Pr.unobserve((fn=qa.current)==null?void 0:fn.parentElement)}}},[ri,Va]),(0,Ne.useEffect)(()=>{if(ri){let Or=[];for(const[Pr,so]of Object.entries(gn)){let fn={[Pr]:()=>{Na(so)}};Or.push(fn),ri.addKeyMap(fn)}return()=>{for(let Pr of Or)ri.removeKeyMap(Pr)}}},[ri]),(0,Ne.useEffect)(()=>{eo!==Kr&&Ko(eo)},[eo]),(0,Ka.Z)(()=>{if(!Rn&&Wo>0){let Or=new Date().getTime(),Pr=window.sessionStorage.getItem(pi);Or>=Wo+ma&&(!Pr||Pr!==ml)&&(window.sessionStorage.setItem(pi,ml),An(!0))}},ma),(0,Ne.useEffect)(()=>{Vt(ai)},[ri,ai]),(0,Ne.useEffect)(()=>{ri&&vi&&ri.focus()},[ri,vi]),(0,Ne.useEffect)(()=>{if(gs&&ri){let Or=function(so){let fn=so.target;if(_o.current){let jr=fn.scrollTop/fn.scrollHeight;_o.current.scrollTop=_o.current.scrollHeight*jr}};const Pr=ri.getScrollerElement();return Pr.addEventListener("scroll",Or),()=>{Pr.removeEventListener("scroll",Or)}}},[ri,gs]),(0,Ne.useEffect)(()=>{if(ri&&Xi){let Or=function(Pr,so){Xi(Pr,so)};return ri.on("beforeChange",Or),()=>{ri.off("beforeChange",Or)}}},[ri,Xi]),(0,Ne.useEffect)(()=>{if(ri&&kn){let Or=function(){kn(ri.getValue())};return ri.on("blur",Or),()=>{ri.off("blur",Or)}}},[ri,kn]);function il(Or,Pr){var so=Or.getDoc(),fn=so.getCursor(),jr=so.getLine(fn.line),Ao=jr.charAt(fn.ch-1),$a=jr.lastIndexOf("@\u2581@",fn.ch),Ia=jr.lastIndexOf("@\u2581\u2581@",fn.ch),ms=$a>Ia?$a:Ia,Vs=$a>Ia?3:4;if(_r.indexOf(Ao)===-1)return null;if(console.log("change1:",Pr,Or,jr,fn,ms,$a,Ia,Ao),ms>=0&&fn.ch-ms<5){var el=ms+Vs;return so.replaceRange("",{line:fn.line,ch:ms},{line:fn.line,ch:el}),{line:fn.line,ch:el}}return null}(0,Ne.useEffect)(()=>{if(ri){let Or=function(Pr,so){const fn=Pr.getValue();Fs(fn),ea(new Date().getTime()),Pr.getScrollerElement().dispatchEvent(new CustomEvent("scroll")),zt&&(wi?zt(fn,Il(fn)):zt(fn))};return ri.on("change",Or),()=>{ri.off("change",Or)}}},[ri,zt]),(0,Ne.useEffect)(()=>{if(ri)if(jt==null)ri.setValue(""),Fs("");else{const Or=window.scrollY||window.pageYOffset;jt!==ri.getValue()&&(ri.setValue(jt),Fs(jt),ri.setCursor(qi?1:ri.lineCount(),0),window.scrollTo(0,Or))}},[ri,jt]);const Na=(0,Ne.useCallback)(Or=>{const Pr=ri.getCursor(),so=ri.getSelection();let fn=so.split(`
`);switch(Or){case"bold":return ri.replaceSelection("**"+so+"**"),so===""&&ri.setCursor(Pr.line,Pr.ch+2),ri.focus();case"italic":return ri.replaceSelection("*"+so+"*"),so===""&&ri.setCursor(Pr.line,Pr.ch+1),ri.focus();case"code":return ri.replaceSelection("`"+so+"`"),so===""&&ri.setCursor(Pr.line,Pr.ch+1),ri.focus();case"inline-latex":return Wa("inline-latex"),ri.focus();case"latex":return ri.replaceSelection("```latex\n"+so+"\n```"),ri.setCursor(Pr.line+1,so.length+1),ri.focus();case"line-break":return ri.replaceSelection(`<br/>
`),ri.focus();case"list-ul":return so===""?ri.replaceSelection("- "+so):ri.replaceSelection(fn.map(jr=>jr===""?"":`- ${jr}`).join(`
`)),ri.focus();case"list-ol":return so===""?ri.replaceSelection("1. "+so):ri.replaceSelection(fn.map((jr,Ao)=>jr===""?"":`${Ao+1}. ${jr}`).join(`
`)),ri.focus();case"add-null-ch":return so===""&&ri.setCursor(Pr.line,Pr.ch),ri.replaceSelection(Ho),ri.focus();case"add-signal":return so===""&&ri.setCursor(Pr.line,Pr.ch),ri.replaceSelection(Fn),ri.focus();case"add-multiple":return so===""&&ri.setCursor(Pr.line,Pr.ch),ri.replaceSelection(_r),ri.focus();case"inster-template-1":return so===""&&ri.setCursor(Pr.line,Pr.ch),ri.replaceSelection(we),ri.focus();case"eraser":return ri.setValue(""),ri.focus();case"trigger-watch":return Vt(!gs),ri.focus();case"trigger-full-screen":return Ko(!Kr),ri.focus();case Di:Wa(Di);return;case bo:Wa(bo);return;case uo:Wa(uo);return;case ei:Wa(ei);return;case"maths-latex":Wa("maths-latex");return;case vt:Wa(vt);return;case Ui:Wa(Ui);return;default:throw new Error}},[ri,gs,Kr]),Li=(0,Ne.useCallback)((Or,Pr)=>{var so,fn,jr,Ao,$a,Ia;switch(Wa(""),Er){case Di:const{title:Gu,link:Fu}=Or;return ri.replaceSelection(`[${Gu}](${Fu})`),ri.focus();case bo:const{language:Xt,content:Ll}=Or;return ri.replaceSelection(["```"+Xt,Ll,"```"].join(`
`)),ri.focus();case"maths-latex":for(var ms=atob(Or),Vs=new Uint8Array(ms.length),el=0;el<ms.length;el++)Vs[el]=ms.charCodeAt(el);var vl=new Blob([Vs],{type:"image/png"});(0,On.I)(vl,Mo=>{Mo.id?ri.replaceSelection(`![,](/api/attachments/${Mo.id}?type=${Mo.content_type})`):(Mo==null?void 0:Mo.status)===401&&(document.location.href="/user/login")});break;case"inline-latex":ri.replaceSelection("`$$"+Or+"$$`");break;case uo:case ei:case co:const{src:zl,alt:fu}=Or,As=Pr,gu=(jr=(fn=(so=As==null?void 0:As.name)==null?void 0:so.split("."))==null?void 0:fn.pop)==null?void 0:jr.call(fn);return((Ao=As==null?void 0:As.type)==null?void 0:Ao.indexOf("image"))>-1||!(As!=null&&As.type)?As!=null&&As.align||As!=null&&As.width?ri.replaceSelection(`<p style="text-align:${As.align||"initial"}"><img width="${As.width?As.width+"%":"initial"}" src="${zl}" alt="${fu||""}" /></p>`):ri.replaceSelection(`<img width="100%" src="${zl}" alt="${fu||""}" />`):(($a=As==null?void 0:As.type)==null?void 0:$a.indexOf("video"))>-1?ri.replaceSelection(`<video width="100%" controls src="${zl}"></video>`):((Ia=As==null?void 0:As.type)==null?void 0:Ia.indexOf("pdf"))>-1?ri.replaceSelection(`<a href="${zl}?type=${As.type}&disposition=inline" target="_blank">${As.name}</a>`):Qn.includes(gu)?ri.replaceSelection(`<a href="${zl}?type=office&disposition=inline" target="_blank">${As.name}</a>`):ri.replaceSelection(`[${As.name}](${zl})`),ri.focus();case Ui:const{row:xh,col:Xu,align:es}=Or;let Ds=`
`;for(let Mo=0;Mo<xh;Mo++){let Ro=[],Ma=[];for(let Ls=0;Ls<Xu;Ls++)Mo===1&&Ma.push(ha[es]),Ro.push(" ");Mo===1&&(Ds+=`| ${Ma.join(" | ")} |
`),Ds+=`| ${Ro.join(Xu===1?"":" | ")} |
`}return ri.replaceSelection(Ds+`
`),ri.focus();default:throw new Error}},[ri,Er]),Qe=(0,Ne.useMemo)(()=>{switch(Er){case Di:return Ne.createElement(ke,{callback:Li,onCancel:bs});case bo:return Ne.createElement(Wt.Z,{callback:Li,onCancel:bs});case uo:return Ne.createElement(On.Z,{callback:Li,onCancel:bs});case vt:return Ne.createElement(dn,{callback:Li,onCancel:bs});case Ui:return Ne.createElement(Zt,{callback:Li,onCancel:bs});case"maths-latex":return Ne.createElement(wr,{showSaveButton:!0,callback:Li});case"inline-latex":return Ne.createElement(fr.Z,{showSaveButton:!0,callback:Li});default:return null}},[Er]);function bs(){Wa("")}(0,Ne.useEffect)(()=>{if(Xa.current){let Or=function($a){jr=!0,Ao=$a.pageY},Pr=function(){jr=!1},so=function($a){if(jr){let Ia=$a.pageY-Ao;Ia<0&&(Ia=0),Ia>300&&(Ia=300);let ms=Yt+Ia+"px";Oo(ms)}},fn=Xa.current,jr=!1,Ao=0;return fn.addEventListener("mousedown",Or),document.addEventListener("mousemove",so),document.addEventListener("mouseup",Pr),()=>{fn.removeEventListener("mousedown",Or),document.removeEventListener("mousemove",so),document.removeEventListener("mouseup",Pr)}}},[ri,Xa]),(0,Ne.useEffect)(()=>{Oo(Yt)},[Yt]);const Ul=bn(Ct),Zl=bn(fo),rl={width:Ul,height:Zl},tu=(0,Ne.useMemo)(()=>{if(Wo){let Or=new Date(Wo),Pr=Or.getHours(),so=Or.getMinutes(),fn=Or.getSeconds();return Pr=Pr<10?"0"+Pr:Pr,so=so<10?"0"+so:so,fn=fn<10?"0"+fn:fn,`${Pr}:${so}:${fn}`}return 0},[Wo]),Il=Or=>{const Pr=[];if(wi){let so=-1;Or=Or.replace(/(@▁▁@|@▁@)/g,function(fn,jr,Ao){Pr.push({multiLine:fn!==Fn})})}return Pr};function Hu(){window.sessionStorage.removeItem(pi),An(!1),ea(0)}function nu(){An(!1),ea(0),ri.setValue(window.sessionStorage.getItem(pi))}(0,Ne.useEffect)(()=>{Vn[Er]&&Er!==ei&&Er!==vt&&setTimeout(()=>{const Or=document.getElementsByClassName("markdown-popup-form")[0],Pr=window.innerWidth/2-Or.offsetWidth/2,so=window.innerHeight/2-Or.offsetHeight/2;Pn(Pr),Ws(so)},0)},[Er]);const Ua=Or=>{Or.preventDefault();const Pr=Or.clientX-Ya,so=Or.clientY-jo;document.body.onmousemove=fn=>{let jr=fn.clientX-Pr,Ao=fn.clientY-so;const $a=document.getElementsByClassName("markdown-popup-form")[0],Ia=window.innerWidth-$a.offsetWidth,ms=window.innerHeight-$a.offsetHeight;jr=Math.max(0,Math.min(jr,Ia)),Ao=Math.max(0,Math.min(Ao,ms)),ps(fn.clientX,fn.clientY,Pr,so)&&(Pn(jr),Ws(Ao))},document.body.onmouseup=function(){document.body.onmousemove=null}},ps=(Or,Pr,so,fn)=>{const jr=document.body.clientHeight,Ao=document.body.clientWidth;return Or<20&&so>Or||Or>Ao-20&&so<Or||Pr<20&&fn>Pr||Pr>jr-20&&fn<Pr?(document.body.onmousemove=null,document.body.onmouseup=null,!1):!0};return Ne.createElement(Ne.Fragment,null,Ne.createElement("div",{className:"markdown-editor-wrapper",ref:bl},Ne.createElement("div",{className:`markdown-editor-container ${La} ${gs?"on-preview":""} ${ci?"mini":""} ${Kr?"full-screen":""}`,style:rl},Ne.createElement(et,{insertTemp:Kt,watch:gs,fullScreen:Kr,showNullButton:Dt,showNullProgramButton:wi,onActionCallback:Na,hidetoolBar:gr,extraUse:Zo}),Ne.createElement("div",{className:"markdown-editor-body"},Ne.createElement("div",{className:"codemirror-container"},Ne.createElement("textarea",{ref:qa,placeholder:cr})),gs?Ne.createElement("div",{ref:_o,className:"preview-container"},wn==="stex"&&Ne.createElement(It,{value:ml}),wn!=="stex"&&Ne.createElement(Qt.Z,{disabledFill:Zi,showProgramFill:wi,value:ml})):null))),ji?Ne.createElement("a",{ref:Xa,className:"editor-resize"}):null,Er===ei&&Ne.createElement(Ot,{callback:Li,onCancel:bs}),Er===vt&&Ne.createElement(dn,{callback:Li,onCancel:bs}),Ne.createElement(ut.Z,null,Vn[Er]&&Er!==ei&&Er!==vt?Ne.createElement(Lt.default,{maskClosable:!1,centered:!0,style:{position:"absolute",left:Ya,top:jo},title:Ne.createElement("div",{style:{cursor:"move"},onMouseDown:Ua},Vn[Er]),open:!0,onCancel:bs,footer:null,destroyOnClose:!0,width:Er===vt?"1200px":null,height:Er===vt?"80vh":null,className:"markdown-popup-form"},Qe):null))}},70859:function(jn,li,De){"use strict";De.d(li,{Z:function(){return Ge},I:function(){return ut}});var Ne=De(91773),dt=De(2453),Ut=De(28802),$t=De(78957),kt=De(37720),Ie=De(98813),$e=De(85804),Mt=De(15476),Pt=De(67294),wt=De(67294),Qt=Object.defineProperty,It=Object.defineProperties,sn=Object.getOwnPropertyDescriptors,Re=Object.getOwnPropertySymbols,ne=Object.prototype.hasOwnProperty,te=Object.prototype.propertyIsEnumerable,he=(st,it,Nt)=>it in st?Qt(st,it,{enumerable:!0,configurable:!0,writable:!0,value:Nt}):st[it]=Nt,le=(st,it)=>{for(var Nt in it||(it={}))ne.call(it,Nt)&&he(st,Nt,it[Nt]);if(Re)for(var Nt of Re(it))te.call(it,Nt)&&he(st,Nt,it[Nt]);return st},pe=(st,it)=>It(st,sn(it));const{useForm:me}=Ne.default,xe={width:280,marginRight:10},Ee={labelCol:{span:5},wrapperCol:{span:19}};var Ge=({callback:st,onCancel:it})=>{const[Nt]=me();let St=(0,Pt.useRef)();function Ft(hi){St.current.width=Nt.getFieldValue("width"),St.current.align=Nt.getFieldValue("align"),st(hi,St.current)}function cn(hi,di){if(hi.status===-1){dt.ZP.error(hi.message);return}Nt.setFieldsValue({src:`/api/attachments/${hi.id}`,type:di.type})}function Tt(hi){let di=hi.target.files[0];St.current=di,ut(di,cn)}return wt.createElement(Ne.default,pe(le({form:Nt},Ee),{className:"upload-image-panel",onFinish:Ft,style:{width:470,overflow:"hidden"}}),wt.createElement(Ne.default.Item,{label:"\u56FE\u7247\u5730\u5740",required:!0},wt.createElement("div",{className:"flex-container"},wt.createElement(Ne.default.Item,{noStyle:!0,name:"src",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u56FE\u7247\u5730\u5740"}]},wt.createElement(Ut.default,{style:xe})),wt.createElement(et,{onFileChange:Tt}))),wt.createElement(Ne.default.Item,{label:"\u56FE\u7247\u63CF\u8FF0",name:"alt"},wt.createElement(Ut.default,{style:{width:264}})),wt.createElement(Ne.default.Item,{label:"\u56FE\u7247\u5BBD\u5EA6",name:"width"},wt.createElement($t.Z,null,wt.createElement(Ne.default.Item,{name:"width",style:{margin:0}},wt.createElement(kt.Z,{style:{width:264}})),wt.createElement("span",{className:"ml8"},"%"))),wt.createElement(Ne.default.Item,{label:"\u5BF9\u9F50\u65B9\u5F0F",name:"align"},wt.createElement(Ie.ZP.Group,{name:"align",defaultValue:1,options:[{value:"left",label:"\u5DE6\u5BF9\u9F50"},{value:"center",label:"\u5C45\u4E2D\u5BF9\u9F50"},{value:"right",label:"\u53F3\u5BF9\u9F50"}]})),wt.createElement("aside",null,wt.createElement(Ne.default.Item,{style:{textAlign:"right",position:"relative",right:-98}},wt.createElement($e.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),wt.createElement($e.ZP,{type:"default",onClick:it},"\u53D6\u6D88"))))};function et({onFileChange:st}){return wt.createElement("label",{className:"upload-button",style:{cursor:"pointer"}},"\u672C\u5730\u4E0A\u4F20",wt.createElement("input",{type:"file",onChange:st}))}function ut(st,it){if(!st)throw new String("\u6CA1\u6709\u6587\u4EF6");let Nt=new FormData;Nt.append("editormd-image-file",st),Nt.append("file_param_name","editormd-image-file"),Nt.append("byxhr","true");var St=new window.XMLHttpRequest;St.withCredentials=!0,St.addEventListener("load",function(Ft){it(JSON.parse(Ft.target.responseText),st)},!1),St.addEventListener("error",function(Ft){console.error(Ft)},!1),St.open("POST",`${Mt.KI}/api/attachments.json`),St.send(Nt)}},76621:function(jn,li,De){"use strict";De.d(li,{Z:function(){return Ut}});var Ne=De(67294),dt=De(73935);class Ut extends Ne.Component{constructor(kt){super(kt);const Ie=window.document;this.node=Ie.createElement("div"),Ie.body.appendChild(this.node)}render(){const{children:kt}=this.props;return(0,dt.createPortal)(kt,this.node)}componentWillUnmount(){window.document.body.removeChild(this.node)}}},36295:function(jn,li,De){"use strict";De.d(li,{SV:function(){return ft},ZP:function(){return Ot}});var Ne=De(67294),dt=De(91033);const Ut={keywords:["print","auto","break","case","char","const","continue","default","do","double","else","enum","extern","float","for","goto","if","int","long","register","return","short","signed","sizeof","static","struct","switch","typedef","union","unsigned","void","volatile","while"]},$t={quickKey:[{label:"main",content:["public static void main(String[] args) {"," $0","}"].join(`
`)},{label:"System.out.println",content:["System.out.println($0)"].join(`
`)},{label:"System.out.print",content:["System.out.print($0)"].join(`
`)}],keywords:["abstract","continue","for","new","switch","assert","default","goto","package","synchronized","boolean","do","if","private","this","break","double","implements","protected","throw","byte","else","import","public","throws","case","enum","instanceof","return","transient","catch","extends","int","short","try","char","final","interface","static","void","class","finally","long","strictfp","volatile","const","float","native","super","while","true","false"]},kt={keywords:["abstract","amp","array","auto","bool","break","case","catch","char","class","const","constexpr","const_cast","continue","cpu","decltype","default","delegate","delete","do","double","dynamic_cast","each","else","enum","event","explicit","export","extern","false","final","finally","float","friend","gcnew","generic","goto","in","initonly","inline","int","interface","interior_ptr","internal","literal","long","mutable","namespace","new","noexcept","nullptr","__nullptr","operator","override","partial","pascal","pin_ptr","private","property","protected","public","ref","register","reinterpret_cast","restrict","return","safe_cast","sealed","short","signed","sizeof","static","static_assert","static_cast","struct","switch","template","this","thread_local","throw","tile_static","true","try","typedef","typeid","typename","union","unsigned","using","virtual","void","volatile","wchar_t","where","while","_asm","_based","_cdecl","_declspec","_fastcall","_if_exists","_if_not_exists","_inline","_multiple_inheritance","_pascal","_single_inheritance","_stdcall","_virtual_inheritance","_w64","__abstract","__alignof","__asm","__assume","__based","__box","__builtin_alignof","__cdecl","__clrcall","__declspec","__delegate","__event","__except","__fastcall","__finally","__forceinline","__gc","__hook","__identifier","__if_exists","__if_not_exists","__inline","__int128","__int16","__int32","__int64","__int8","__interface","__leave","__m128","__m128d","__m128i","__m256","__m256d","__m256i","__m64","__multiple_inheritance","__newslot","__nogc","__noop","__nounwind","__novtordisp","__pascal","__pin","__pragma","__property","__ptr32","__ptr64","__raise","__restrict","__resume","__sealed","__single_inheritance","__stdcall","__super","__thiscall","__try","__try_cast","__typeof","__unaligned","__unhook","__uuidof","__value","__virtual_inheritance","__w64","__wchar_t"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],quickKey:[{label:"ifelse",content:["if (${1:condition}) {"," $0","} else {"," ","}"].join(`
`)},{label:"include",content:"include<$0>"},{label:"printf",content:"printf($0)"},{label:"system",content:'system("$0")'},{label:"main",content:["int main () {"," $0","}"].join(`
`)},{label:"if",content:["if () {"," $0","}"].join(`
`)},{label:"for",content:["for(int j=0 ; j<10; j++){"," $0","}"].join(`
`)},{label:"trycatch",content:["try{"," $0","}catch(ExceptionName e){","}"].join(`
`)},{label:"using namespace std;",content:["using namespace std;"].join(`
`)},{label:"include <iostream>",content:["#include <iostream>"].join(`
`)},{label:"include <vector>",content:["#include <vector>"].join(`
`)},{label:"include <cstdio>",content:["#include <cstdio>"].join(`
`)},{label:"include <cstring>",content:["#include <cstring>"].join(`
`)},{label:"include <sstream>",content:["#include <sstream>"].join(`
`)},{label:"include <fstream>",content:["#include <fstream>"].join(`
`)},{label:"include <map>",content:["#include <map>"].join(`
`)},{label:"include <string>",content:["#include <string>"].join(`
`)},{label:"include <cmath>",content:["#include <cmath>"].join(`
`)}]},Ie={keywords:["and","as","assert","break","class","continue","def","del","elif","else","except","exec","finally","for","from","global","if","import","in","is","lambda","None","not","or","pass","raise","return","self","try","while","with","yield","int","float","long","complex","hex","abs","all","any","apply","basestring","bin","bool","buffer","bytearray","callable","chr","classmethod","cmp","coerce","compile","complex","delattr","dict","dir","divmod","enumerate","eval","execfile","file","filter","format","frozenset","getattr","globals","hasattr","hash","help","id","input","intern","isinstance","issubclass","iter","len","locals","list","map","max","memoryview","min","next","object","oct","open","ord","pow","print","property","reversed","range","raw_input","reduce","reload","repr","reversed","round","set","setattr","slice","sorted","staticmethod","str","sum","super","tuple","type","unichr","unicode","vars","xrange","zip","True","False","__dict__","__methods__","__members__","__class__","__bases__","__name__","__mro__","__subclasses__","__init__","__import__"],quickKey:[{label:"print",content:["print($0)"].join(`
`)}]},$e={keywords:["asInstanceOf","catch","class","classOf","def","do","else","extends","finally","for","foreach","forSome","if","import","isInstanceOf","macro","match","new","object","package","return","throw","trait","try","type","until","val","var","while","with","yield","given","enum","then"],quickKey:[{label:"println",content:["println($0)"].join(`
`)}]};var Mt=De(84204),Pt=De.n(Mt),wt=(Gt,an,Jt)=>new Promise((Ve,be)=>{var Pe=Fe=>{try{Ze(Jt.next(Fe))}catch(qe){be(qe)}},Be=Fe=>{try{Ze(Jt.throw(Fe))}catch(qe){be(qe)}},Ze=Fe=>Fe.done?Ve(Fe.value):Promise.resolve(Fe.value).then(Pe,Be);Ze((Jt=Jt.apply(Gt,an)).next())});const Qt={languages:["c","abap","apex","azcli","bat","cameligo","clojure","coffee","cpp","csharp","csp","css","dockerfile","fsharp","go","graphql","handlebars","html","ini","java","javascript","json","kotlin","less","lua","markdown","mips","msdax","mysql","objective-c","pascal","pascaligo","perl","pgsql","php","postiats","powerquery","powershell","pug","python","r","razor","redis","redshift","restructuredtext","ruby","rust","sb","scheme","scss","shell","solidity","sophia","sql","st","swift","tcl","twig","vb","xml","yaml'"],tables:{users:["name","id","email","phone","password"],roles:["id","name","order","created_at","updated_at","deleted_at"]}},It=(Gt,an,Jt,Ve)=>{const be=an.getValueInRange({startLineNumber:1,startColumn:1,endLineNumber:Jt.lineNumber,endColumn:Jt.column});return Array.from(new Set(be.match(/\b\w{2,}\b/g)||[])).map(Be=>({label:Be,kind:Gt.languages.CompletionItemKind.Text,insertText:Be,range:Ve}))},sn=(Gt,an,Jt,Ve)=>{Gt.languages.registerCompletionItemProvider(an,{provideCompletionItems(be,Pe){const Be=be.getWordUntilPosition(Pe),Ze={startLineNumber:Pe.lineNumber,endLineNumber:Pe.lineNumber,startColumn:Be.startColumn,endColumn:Be.endColumn},Fe=be.getLineContent(Pe.lineNumber).substring(Be.startColumn-2,Be.endColumn);return{suggestions:[...It(Gt,be,Pe,Ze),...Jt.map(dn=>({label:dn,kind:Gt.languages.CompletionItemKind.Keyword,documentation:dn,insertText:dn,insertTextRules:Gt.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:Ze})),...Ve.map(dn=>({label:dn.label,kind:Gt.languages.CompletionItemKind.Snippet,documentation:dn.content,insertText:Fe.startsWith("#")?dn.content.replace(/#/,""):dn.content,insertTextRules:Gt.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:Ze}))]}}})};var Re=Gt=>{Qt.languages.forEach(an=>{Gt.languages.registerDocumentFormattingEditProvider(an,{provideDocumentFormattingEdits(Jt){return wt(this,null,function*(){const Ve=Pt()(Jt.getValue(),{indent_size:2,indent_char:" ",max_preserve_newlines:2,preserve_newlines:!0,keep_array_indentation:!0,break_chained_methods:!1,indent_scripts:"normal",brace_style:"collapse",space_before_conditional:!0,unescape_strings:!1,jslint_happy:!1,end_with_newline:!0,wrap_line_length:0,indent_inner_html:!1,comma_first:!1,e4x:!1,indent_empty_lines:!1});return[{range:Jt.getFullModelRange(),text:Ve}]})}})}),sn(Gt,"java",$t.keywords,$t.quickKey),sn(Gt,"cpp",kt.keywords,kt.quickKey),sn(Gt,"c",Ut.keywords,[]),sn(Gt,"python",Ie.keywords,Ie.quickKey),sn(Gt,"scala",$e.keywords,$e.quickKey)};const ne="\u8BE5\u4EFB\u52A1\u5173\u5361\u8BBE\u7F6E\u4E86\u7981\u6B62\u590D\u5236\u7C98\u8D34\uFF0C\u8BF7\u624B\u52A8\u8F93\u5165\u4EE3\u7801\u3002";var te=Object.defineProperty,he=(Gt,an,Jt)=>an in Gt?te(Gt,an,{enumerable:!0,configurable:!0,writable:!0,value:Jt}):Gt[an]=Jt,le=(Gt,an,Jt)=>he(Gt,typeof an!="symbol"?an+"":an,Jt);const pe=class px{constructor(an,Jt,Ve){this.placeholder=an,this.editor=Jt,this.monaco=Ve,Jt.onDidChangeModelContent(()=>this.onDidChangeModelContent()),this.onDidChangeModelContent()}onDidChangeModelContent(){this.editor.getValue()===""?this.editor.addContentWidget(this):this.editor.removeContentWidget(this)}getId(){return px.ID}getDomNode(){return this.domNode||(this.domNode=document.createElement("div"),this.domNode.style.width="max-content",this.domNode.textContent=this.placeholder,this.domNode.style.fontStyle="initial",this.domNode.style.color="#D7D7D7",this.domNode.style.pointerEvents="none",this.editor.applyFontInfo(this.domNode)),this.domNode}getPosition(){return{position:{lineNumber:1,column:1},preference:[this.monaco.editor.ContentWidgetPositionPreference.EXACT]}}dispose(){this.editor.removeContentWidget(this)}};le(pe,"ID","editor.widget.placeholderHint");var xe=pe,Ee=De(84144),Ge=De(2453),et=De(83062),ut=De(96486),st=De(33054),it=De(74855),Nt=Object.defineProperty,St=Object.defineProperties,Ft=Object.getOwnPropertyDescriptors,cn=Object.getOwnPropertySymbols,Tt=Object.prototype.hasOwnProperty,hi=Object.prototype.propertyIsEnumerable,di=(Gt,an,Jt)=>an in Gt?Nt(Gt,an,{enumerable:!0,configurable:!0,writable:!0,value:Jt}):Gt[an]=Jt,zn=(Gt,an)=>{for(var Jt in an||(an={}))Tt.call(an,Jt)&&di(Gt,Jt,an[Jt]);if(cn)for(var Jt of cn(an))hi.call(an,Jt)&&di(Gt,Jt,an[Jt]);return Gt},Dn=(Gt,an)=>St(Gt,Ft(an)),nt=(Gt,an)=>{var Jt={};for(var Ve in Gt)Tt.call(Gt,Ve)&&an.indexOf(Ve)<0&&(Jt[Ve]=Gt[Ve]);if(Gt!=null&&cn)for(var Ve of cn(Gt))an.indexOf(Ve)<0&&hi.call(Gt,Ve)&&(Jt[Ve]=Gt[Ve]);return Jt},ze=(Gt,an,Jt)=>new Promise((Ve,be)=>{var Pe=Fe=>{try{Ze(Jt.next(Fe))}catch(qe){be(qe)}},Be=Fe=>{try{Ze(Jt.throw(Fe))}catch(qe){be(qe)}},Ze=Fe=>Fe.done?Ve(Fe.value):Promise.resolve(Fe.value).then(Pe,Be);Ze((Jt=Jt.apply(Gt,an)).next())});function ke(Gt){return/^\d+$/.test(Gt)?`${Gt}px`:Gt}function Wt(){}let On=!1;const Lt={"Python3.6":"python","Python2.7":"python",Dynamips:"cpp",Java:"java",Web:"php",Html:"html",Hive:"sql",Hadoop:"java",SDL:"cpp",PHP:"php",Matlab:"python",Git:"python",Python:"python","C/C++":"cpp","C++":"cpp",C:"cpp",Ruby:"ruby",Shell:"shell",JavaScript:"javascript",Perl6:"perl",Kotlin:"kotlin",Elixir:"elixir",Android:"java",JavaWeb:"java",Go:"go",Spark:"sql",MachineLearning:"python",Verilog:"xml","Verilog/VNC":"xml",Docker:"dockerfile","C#":"csharp",SQLite3:"sql",Oracle:"sql",Vhdl:"vhdl",R:"r",Swift:"swift",SQLServer:"mysql",MySQL:"mysql",Mongo:"sql",PostgreSql:"pgsql",Hbase:"powershell",Sqoop:"sql",Nasm:"cpp",Kafka:"java",Flink:"java",Sml:"javascript",OpenGL:"cpp",Perl5:"perl",Orange:"python",Scala:"scale",solidity:"sol"};function xn(Gt=[]){let an=Gt;if(Array.isArray(Gt)){for(let Jt=0;Jt<Gt.length;Jt++){let Ve=Lt[Gt[Jt]];if(Ve)return Ve}return an[0]}return Lt[an]||an}let vn=null;const Xn=()=>ze(void 0,null,function*(){try{yield navigator.clipboard.writeText(" "),console.log("\u5185\u5BB9\u5DF2\u81EA\u52A8\u590D\u5236\u5230\u526A\u8D34\u677F:")}catch(Gt){console.error("\u81EA\u52A8\u590D\u5236\u5931\u8D25:",Gt)}});var Ot=Gt=>{var an=Gt,{width:Jt="100%",height:Ve="100%",value:be,language:Pe="javascript",style:Be={},options:Ze={},overrideServices:Fe={},theme:qe="vs-dark",onEditBlur:dn,isCopy:ui=!1,onSave:$n,autoHeight:rn=!1,forbidCopy:Hn=!1,onChange:Zt=Wt,editorDidMount:_n=Wt,onFocus:ti=Wt,onBreakPoint:Ri=Wt,breakPointValue:oi=[],filename:wr="educoder.txt",errorLine:fr,errorContent:Ei="",highlightLine:Di,openBreakPoint:uo=!1,placeholder:vt="",showMiniMap:ei=!0}=an,co=nt(an,["width","height","value","language","style","options","overrideServices","theme","onEditBlur","isCopy","onSave","autoHeight","forbidCopy","onChange","editorDidMount","onFocus","onBreakPoint","breakPointValue","filename","errorLine","errorContent","highlightLine","openBreakPoint","placeholder","showMiniMap"]);const bo=(0,Ne.useRef)(),Ui=(0,Ne.useRef)({}),yo=(0,Ne.useRef)(),ha=(0,Ne.useRef)(),Ka=(0,Ne.useRef)([]),Ra=(0,Ne.useRef)(!1),ca=(0,Ne.useRef)(),ma=(0,Ne.useRef)(),Ho=(0,Ne.useRef)(!1),[_r,Fn]=(0,Ne.useState)(!1);function we(){let Kt;return bo.current&&(Kt=new dt.Z(wn=>{for(let pi of wn)(pi.target.offsetHeight>0||pi.target.offsetWidth>0)&&Ui.current.instance.layout()}),Kt.observe(bo.current)),Kt}function Qn(){Ge.ZP.warning({content:decodeURIComponent(ne),key:"monaco-editor-tip"})}const bn=()=>{let Kt=Ui.current.instance;if(be!=null&&Kt&&_r){const wn=Kt.getModel();wn&&be!==wn.getValue()&&(On=!0,wn.setValue(be),Kt.layout(),On=!1)}};(0,Ne.useEffect)(()=>{const Kt=st.Z.subscribe("formatDocument",wn=>{var pi;let ji=Ui.current.instance;(pi=ji==null?void 0:ji.getAction)==null||pi.call(ji,"editor.action.formatDocument").run()});return window.updateMonacoValue=wn=>{Zt(wn)},Kt},[]),(0,Ne.useEffect)(()=>{var Kt;let wn=Ui.current.instance;ha.current&&clearTimeout(ha.current),ha.current=setTimeout(()=>{bn()},500),be&&(be!=null&&be.length)&&((Kt=wn==null?void 0:wn.updateOptions)==null||Kt.call(wn,{lineNumbersMinChars:Math.max(Math.floor(Math.log10(be.split(/\r\n|\r|\n/g).length))+3,5)}))},[be,_r,Ui.current]),(0,Ne.useEffect)(()=>{if(fr&&Ui.current&&Ui.current.instance){let wn=Ui.current.instance;wn.changeViewZones(function(pi){var ji=document.createElement("div");ji.style.padding="10px 20px",ji.style.width="calc(100% - 20px)",ji.className="my-error-line-wrp",ji.innerHTML=Ei,pi.addZone({afterLineNumber:fr||11,heightInLines:3,domNode:ji})});var Kt={domNode:null,getId:function(){return"my.overlay.widget"},getDomNode:function(){return this.domNode||(this.domNode=document.createElement("div"),this.domNode.innerHTML="",this.domNode.style.width="100%",this.domNode.style.padding="20px 100px",this.domNode.style.right="0px",this.domNode.style.top="50px",this.domNode.style.position="relative",this.domNode.style.color="#333"),this.domNode},getPosition:function(){return null}};wn.addOverlayWidget(Kt),wn.revealPositionInCenter({lineNumber:20,column:1})}},[fr,Ui.current,_r]);const on=(Kt="",wn)=>{if(!Kt||Kt.trim()==="")return!0;const ji=Ui.current.instance.getModel().getLineTokens(wn);let Rn=!1;for(let Dt=0;Dt<2;Dt++)ji.getStandardTokenType(Dt)===1&&(Rn=!0);return Rn};(0,Ne.useEffect)(()=>{var Kt;const wn=(Kt=Ui.current)==null?void 0:Kt.instance;if(wn&&_r&&Hn){const pi=wn.onDidBlurEditorWidget(()=>{Ho.current=!1}),ji=wn.onDidFocusEditorText(()=>{Ho.current=!0});return()=>{pi.dispose(),ji.dispose()}}},[Ui.current,_r,Hn]),(0,Ne.useEffect)(()=>{var Kt;if((Kt=Ui.current)!=null&&Kt.instance&&_r&&uo){let wn=Ui.current.instance,pi=wn.getModel();if(!pi)return;(()=>{var qi;let Zi=[],cr=[];const Co=pi.getAllDecorations();for(let ri of Co)ri.options.className==="highlighted-line"&&(Zi.push((qi=ri==null?void 0:ri.range)==null?void 0:qi.startLineNumber),cr.push(ri==null?void 0:ri.id));if(Di===Zi[0])return;pi.deltaDecorations(cr,[]);const Zo=pi.getLineCount();Di&&Di<=Zo&&(wn.deltaDecorations([],[{range:new vn.Range(Di,1,Di,pi.getLineMaxColumn(Di)),options:{isWholeLine:!0,className:"highlighted-line"}}]),wn.revealLineInCenter(Di))})();const Rn=(qi=!1)=>{var Zi;let cr=[],Co=[];const Zo=pi.getAllDecorations();for(let ri of Zo)ri.options.linesDecorationsClassName==="breakpoints-select"&&(cr.push((Zi=ri==null?void 0:ri.range)==null?void 0:Zi.startLineNumber),Co.push(ri==null?void 0:ri.id));if(qi)return{lines:cr,ids:Co};Ri(cr)},Dt=qi=>ze(void 0,null,function*(){let Zi={range:new vn.Range(qi,1,qi,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-select"}};yield pi.deltaDecorations([],[Zi]),Rn()}),wi=qi=>ze(void 0,null,function*(){let Zi=[];const cr=wn.getLineDecorations(qi);for(let Co of cr)Co.options.linesDecorationsClassName==="breakpoints-select"&&Zi.push(Co.id);yield pi.deltaDecorations(Zi,[]),Rn()}),gr=qi=>{let Zi=wn.getLineDecorations(qi);for(let cr of Zi)if(cr.options.linesDecorationsClassName==="breakpoints-select")return!0;return!1};if(!(0,ut.isEqual)(oi,Rn(!0).lines)){pi.deltaDecorations(Rn(!0).ids,[]);const qi=oi.map(Zi=>({range:new vn.Range(Zi,1,Zi,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-select"}}));pi.deltaDecorations([],qi)}const eo=wn.onDidChangeModelContent(qi=>{let Zi=wn.getPosition();if(Zi){let cr=Zi.lineNumber;clearTimeout(ma.current),ma.current=setTimeout(()=>{on(pi.getLineContent(cr),cr)?wi(cr):gr(cr)?(wi(cr),Dt(cr)):Rn()},100)}}),kn=wn.onMouseDown(qi=>{var Zi,cr,Co;if(qi.target.detail&&((Co=(cr=(Zi=qi.target)==null?void 0:Zi.element)==null?void 0:cr.className)!=null&&Co.includes("line-numbers"))){let Zo=qi.target.position.lineNumber;if(on(pi.getLineContent(Zo),Zo))return;gr(Zo)?wi(Zo):Dt(Zo)}}),Xi=qi=>{let Zi={range:new vn.Range(qi,1,qi,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-fake"}};Ka.current=wn.deltaDecorations(Ka.current,[Zi])},Lo=()=>{Ka.current=wn.deltaDecorations(Ka.current,[])},La=wn.onMouseMove(qi=>{var Zi,cr,Co;if(Lo(),qi.target.detail&&((Co=(cr=(Zi=qi.target)==null?void 0:Zi.element)==null?void 0:cr.className)!=null&&Co.includes("line-numbers"))){let Zo=qi.target.position.lineNumber;if(on(pi.getLineContent(Zo),Zo))return;Xi(Zo)}}),$o=wn.onMouseLeave(()=>{Lo()});return()=>{eo.dispose(),kn.dispose(),La.dispose(),$o.dispose()}}},[Ui.current,_r,oi,Di,uo,Pe]),(0,Ne.useEffect)(()=>{var Kt;(Kt=Ui.current)!=null&&Kt.instance&&uo&&Ui.current.instance.setPosition({lineNumber:0,column:0})},[Di]);function ln(){let Kt=Ui.current.instance;if(Kt){const wn=Kt.getSelection(),pi=Ui.current.pastePos||{},ji=new vn.Range(pi.startLineNumber||wn.endLineNumber,pi.startColumn||wn.endColumn,pi.endLineNumber||wn.endLineNumber,pi.endColumn||wn.endColumn);setTimeout(()=>{Kt.executeEdits("",[{range:ji,text:""}])},300)}}function gn(Kt){(window.navigator.platform.match("Mac")?Kt.metaKey:Kt.ctrlKey)&&Kt.keyCode==83&&(Kt.preventDefault(),$n())}const Vn=()=>{if(rn&&Ui.current.instance){const Kt=Ui.current.instance.getContentHeight();vi(Kt<Ve?Ve:Kt)}else vi(Ve)};function _i(Kt){var wn=document.createEvent("MouseEvents");wn.initMouseEvent("click",!0,!1,window,0,0,0,0,0,!1,!1,!1,!1,0,null),Kt.dispatchEvent(wn)}const jt=Kt=>{if(!Ho.current)return;const{keyCode:wn,ctrlKey:pi,metaKey:ji,target:Rn,type:Dt}=Kt;return(Dt==="paste"||(wn===67||wn===86)&&(ji||pi))&&Rn.nodeName==="TEXTAREA"&&(Qn(),Kt.preventDefault()),!1};function zt(Kt,wn){var pi=window.URL||window.webkitURL||window,ji=new Blob([wn]),Rn=document.createElementNS("http://www.w3.org/1999/xhtml","a");Rn.href=pi.createObjectURL(ji),Rn.download=Kt,_i(Rn)}(0,Ne.useEffect)(()=>{Vn()},[Vn]),(0,Ne.useEffect)(()=>{bo.current&&!_r&&Promise.all([De.e(5552),De.e(9651)]).then(De.bind(De,55826)).then(Kt=>{try{vn=Kt,Ui.current.instance=vn.editor.create(bo.current,{value:be,language:xn(Pe),theme:qe,requireConfig:{"vs/nls":{availableLanguages:{"*":"zh-cn"}}},wordWrap:!0,autoIndent:!0,contextmenu:!0,formatOnType:!0,minimap:{enabled:ei||!1}},Fe);const wn=Ui.current.instance;let Rn=[...Ee.BH._menuItems].find(eo=>eo[0]._debugName=="EditorContext")[1],Dt=["editor.action.clipboardCopyWithSyntaxHighlightingAction","editor.action.quickCommand","editor.action.clipboardCopyAction","editor.action.clipboardPasteAction","editor.action.clipboardCutAction"],wi=(eo,kn)=>{var Xi,Lo;let La=eo._first;do kn.includes((Lo=(Xi=La.element)==null?void 0:Xi.command)==null?void 0:Lo.id)&&eo._remove(La);while(La=La.next)};if(_n(wn,vn),setTimeout(()=>{Vn(),Ui.current.instance.addAction({id:"d123123",label:"Download File",contextMenuGroupId:"9_cutcopypaste",run:()=>{zt(wr||"educoder.txt",wn.getValue())}})},500),Ui.current.subscription=wn.onDidChangeModelContent(eo=>{Ra.current?clearTimeout(ca.current):(Vn(),Zt(wn.getValue(),eo)),ca.current=setTimeout(()=>{Ra.current=!1},500)}),window.Monaco||Re(vn,xn(Pe)),Hn&&(wi(Rn,Dt),bo.current.classList.add("noCopyPaste"),window.removeEventListener("keydown",jt),window.removeEventListener("paste",jt),window.addEventListener("keydown",jt),window.addEventListener("paste",jt)),window.Monaco=vn,dn&&wn.onDidBlurEditorWidget(()=>{dn(wn.getValue())}),ti&&wn.onDidFocusEditorText(()=>{Hn&&Xn(),ti(wn.getValue())}),Hn){Xn();try{wn.onDidPaste(eo=>{const kn=wn.getSelection(),Xi=Ui.current.pastePos||{},Lo=new vn.Range(Xi.startLineNumber||kn.endLineNumber,Xi.startColumn||kn.endColumn,Xi.endLineNumber||kn.endLineNumber,Xi.endColumn||kn.endColumn);wn.executeEdits("",[{range:eo.range,text:""}])})}catch(eo){}}let gr=we();return vt&&typeof vt=="string"&&new xe(vt,wn,vn),Fn(!0),()=>{const eo=Ui.current.instance;eo.dispose();const kn=eo.getModel();kn&&kn.dispose(),Ui.current.subscription&&Ui.current.subscription.dispose(),gr.unobserve(bo.current)}}catch(wn){}})},[]),(0,Ne.useEffect)(()=>{if(Ui.current.instance&&_r)return document.addEventListener("keydown",gn,!1),()=>{document.removeEventListener("keydown",gn)}},[$n,_r]),(0,Ne.useEffect)(()=>{let Kt=Ui.current.instance;if(Kt&&_r){let wn=xn(Pe);vn.editor.setModelLanguage(Kt.getModel(),wn)}},[Pe,_r]),(0,Ne.useEffect)(()=>{Ui.current.instance&&_r&&vn.editor.setTheme(qe)},[qe,_r]),(0,Ne.useEffect)(()=>{let Kt=Ui.current.instance;yo.current=Ze,Kt&&_r&&(Kt.updateOptions(zn({},Ze)),setTimeout(()=>{Kt.getModel().updateOptions(zn({},Ze))},200))},[JSON.stringify(Ze),_r]),(0,Ne.useEffect)(()=>{let Kt=Ui.current.instance;Kt&&_r&&Kt.layout()},[Jt,Ve,_r]);const[Ct,Yt]=(0,Ne.useState)(ke(Jt)),[ci,vi]=(0,Ne.useState)(ke(Ve)),ai=Dn(zn({},Be),{width:Ct,height:ci,position:"relative"});return Ne.createElement("div",{className:"my-monaco-editor",ref:bo,style:ai},ui&&Ne.createElement(it.CopyToClipboard,{text:be,onCopy:()=>Ge.ZP.success("\u590D\u5236\u6210\u529F")},Ne.createElement(et.Z,{title:"\u590D\u5236\u4EE3\u7801"},Ne.createElement("div",{style:{position:"absolute",top:0,right:10,cursor:"pointer",zIndex:10,color:"#165DFF"}},Ne.createElement("i",{className:"iconfont icon-fuzhi8",style:{fontSize:14}})," \u590D\u5236\u4EE3\u7801"))))};function ft({width:Gt="100%",height:an="100%",original:Jt,modified:Ve,language:be,options:Pe={}}){const Be=(0,Ne.useRef)(),[Ze,Fe]=(0,Ne.useState)(null);function qe(rn){let Hn;return Be.current&&(Hn=new dt.Z(Zt=>{for(let _n of Zt)(_n.target.offsetHeight>0||_n.target.offsetWidth>0)&&rn.layout()}),Hn.observe(Be.current)),Hn}(0,Ne.useEffect)(()=>(Be.current&&Promise.all([De.e(5552),De.e(9404)]).then(De.bind(De,50048)).then(rn=>{vn=rn;const Hn=vn.editor.createDiffEditor(Be.current,Dn(zn({enableSplitViewResizing:!1,scrollBeyondLastLine:!1,roundedSelection:!1,renderIndicators:!1,useShadows:!1,horizontal:"hidden",lineNumbers:"off",wordWrap:"off",ignoreTrimWhitespace:!1,"semanticHighlighting.enabled":!0,followsCaret:!0,ignoreCharChanges:!0,minimap:{enabled:!1},readOnly:!0},Pe),{wordWrap:!0}));Fe(Hn);let Zt=qe(Hn);return()=>{Hn.dispose();const _n=Hn.getModel();_n&&_n.dispose(),Zt.unobserve(Be.current)}}),()=>{window.removeEventListener("keydown",checkPaste),window.removeEventListener("paste",checkPaste)}),[]),(0,Ne.useEffect)(()=>{Ze&&Ze.setModel({original:vn.editor.createModel(Jt,be),modified:vn.editor.createModel(Ve,be)})},[Jt,Ve,be,Ze]);const dn=ke(Gt),ui=ke(an),$n={width:dn,height:ui};return Ne.createElement("div",{className:"my-diff-editor",ref:Be,style:$n})}},5476:function(jn,li,De){"use strict";De.d(li,{Z:function(){return Qt}});var Ne={flex_box_center:"flex_box_center___AQ53o",flex_space_between:"flex_space_between___i2aIa",flex_box_vertical_center:"flex_box_vertical_center___sPEKB",flex_box_center_end:"flex_box_center_end___GhSSH",flex_box_column:"flex_box_column___R9_Hb",list:"list___jb2Ay",wrap:"wrap___VsQDr",lockWrap:"lockWrap___g1k1T",li:"li___IxCLC",cover:"cover___Mu8wr",img:"img___IpFLA",movebq:"movebq___mF7wt",bq:"bq___Bil0T",sign:"sign___DXJ4d",name:"name___l7FoJ",e:"e___pXQUG",unit:"unit___wCIFR",tags:"tags___w_Mil",tag1:"tag1___dxm7r",tag2:"tag2___llZkf"},dt=De(74330),Ut=De(83062),$t=De(94184),kt=De.n($t),Ie=De(28706),$e=De(26194),Mt=De(52262),Pt=De(67294),Qt=({className:It,dataSource:sn=[],col:Re=4,right:ne,bottom:te=23,precision:he=0,wrapWidth:le=1200,trackEventItems:pe,loading:me,onRemove:xe=()=>{},isCurrent:Ee=!0,showAlias:Ge=!1})=>{const et=Math.floor((le-(Re-1)*ne)/Re),ut=[{name:"\u63A8\u8350\u81EA\u5B66",ptimg:"/images/tjzx.png",swimg:"/images/sw_tjzx.png"},{name:"101\u8BA1\u5212",ptimg:"/images/jh.png",swimg:"/images/sw_jh.png"},{name:"\u56FD\u5BB6\u4E00\u6D41",ptimg:"/images/gjyl.png",swimg:"/images/sw_gjyl.png"},{name:"\u7701\u7EA7\u4E00\u6D41",ptimg:"/images/sjyl.png",swimg:"/images/sw_sjyl.png"},{name:"\u7CBE\u54C1\u8BFE\u7A0B",ptimg:"/images/jpkc.png",swimg:"/images/sw_jpkc.png"},{name:"\u519B\u961F\u4E00\u6D41",ptimg:"/images/jdyl.png",swimg:"/images/sw_jdyl.png"},{name:"\u65B0\u578B\u6559\u6750",ptimg:"/images/xxjc.png",swimg:"/images/sw_xxjc.png"}];return Pt.createElement(dt.Z,{spinning:me},Pt.createElement("div",{className:kt()(Ne.list,It)},!!(sn!=null&&sn.length)&&(sn==null?void 0:sn.map((st,it)=>{var Nt;const{name:St,id:Ft,identifier:cn,featured:Tt,school_name:hi,image_url:di,excellent:zn,is_plan:Dn}=st;return Pt.createElement("div",{key:Ft,className:Ne.wrap,style:{width:et,marginRight:(1+it)%Re===0?0:ne+he,marginBottom:te}},Pt.createElement("a",{className:Ne.li,onClick:nt=>{nt.preventDefault(),nt.stopPropagation(),pe&&(0,Ie.L9)([pe]),(0,Ie.xg)(`/paths/${cn}`)}},Pt.createElement("div",{className:Ne.img},Pt.createElement("img",{className:Ne.cover,src:`${di}`}),Ee&&(0,Mt.bg)()&&(st==null?void 0:st.studying)&&Pt.createElement("div",{className:`${Ne.movebq} user-path-items`,onClick:nt=>{nt.stopPropagation(),xe(st)}},Pt.createElement("i",{className:"iconfont icon-yichu1 mr5 c-red"}),Pt.createElement("span",{className:"c-red"},"\u79FB\u9664")),(Nt=st==null?void 0:st.subject_tags)==null?void 0:Nt.map((nt,ze)=>{var ke,Wt;if(ze===0){const Lt=(ke=ut.find(xn=>xn.name==nt))==null?void 0:ke.swimg;return Pt.createElement("img",{className:Ne.sign,src:Lt,style:{left:"-4px"}})}const On=(Wt=ut.find(Lt=>Lt.name==nt))==null?void 0:Wt.ptimg;return Pt.createElement("img",{className:Ne.sign,src:On,style:{left:`${48+52*(ze-1)+2*ze}px`}})}),Pt.createElement("div",{style:{position:"absolute",top:"150px",left:"4px"}},(st==null?void 0:st.excellent)&&Pt.createElement("div",{className:Ne.bq},"\u5F00\u653E\u8BFE\u7A0B"))),Pt.createElement("div",{className:Ne.name},Pt.createElement(Ut.Z,{title:Ge&&(st!=null&&st.excellent_alias_name)?Pt.createElement("span",null,`\u8BFE\u7A0B\u539F\u540D\uFF1A${St}`,Pt.createElement("br",null),Pt.createElement("span",null,`\u8BFE\u7A0B\u522B\u540D\uFF1A${st==null?void 0:st.excellent_alias_name}`)):St},Pt.createElement("span",{className:Ne.e},Ge&&(st==null?void 0:st.excellent_alias_name)||St))),Pt.createElement(Ut.Z,{title:`\u53D1\u5E03\u5355\u4F4D\uFF1A${hi}`},Pt.createElement("div",{className:Ne.unit},Pt.createElement("i",{className:"iconfont icon-danwei1 font14 mr3"}),hi)),Pt.createElement("div",{className:Ne.tags},Pt.createElement("div",null,Pt.createElement(Ut.Z,{placement:"bottom",title:"\u7AE0\u8282\u6570"},Pt.createElement("span",null,Pt.createElement("i",{className:"iconfont icon-zhangjie1 font14 mr3"}),Pt.createElement("span",null,st.stages_count))),Pt.createElement(Ut.Z,{placement:"bottom",title:"\u5B66\u4E60\u4EBA\u6570"},Pt.createElement("span",null,Pt.createElement("i",{className:"iconfont icon-chengyuan font14 mr3"}),Pt.createElement("span",null,st.members_count)))))))})),!sn.length&&Pt.createElement($e.Z,null)))}},30001:function(jn,li,De){"use strict";De.d(li,{jL:function(){return kt},w9:function(){return ke},QD:function(){return fr},cQ:function(){return di.Z},op:function(){return Zt},O5:function(){return bn},_b:function(){return co},t7:function(){return le},Gi:function(){return Xn},YG:function(){return xn},qp:function(){return Qt},vr:function(){return uo},qE:function(){return Ri},Je:function(){return xe},wb:function(){return hi},cq:function(){return Ve},tp:function(){return Re}});var Ne=De(67294),dt={flex_box_center:"flex_box_center___NeSU8",flex_space_between:"flex_space_between___ImTGl",flex_box_vertical_center:"flex_box_vertical_center___BtRd9",flex_box_center_end:"flex_box_center_end___qcLe3",flex_box_column:"flex_box_column___Ze_3q",banner:"banner___PoUBO",content:"content___XoDjy",btns:"btns___Pb35j"},Ut="data:image/png;base64,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",kt=({dataSource:on=[],img:ln,imgWidth:gn=346,title:Vn,sunTitle:_i,bannerExtraContent:jt})=>Ne.createElement("div",{className:dt.banner},Ne.createElement("div",{className:dt.content},Ne.createElement("aside",null,Ne.createElement("p",null,Ne.createElement("b",null,Vn),Ne.createElement("span",null,_i)),on.length>0&&Ne.createElement("div",{className:dt.btns},on.map((zt,Ct)=>Ne.createElement("div",{key:Ct,onClick:zt.click},zt.name,zt.sign?Ne.createElement("img",{src:Ut,width:39}):null))),jt),ln&&Ne.createElement("img",{style:{marginTop:33,marginRight:38},src:ln,width:gn}))),Ie={flex_box_center:"flex_box_center___hG6RI",flex_space_between:"flex_space_between___ss3Fh",flex_box_vertical_center:"flex_box_vertical_center___K80p9",flex_box_center_end:"flex_box_center_end___qmXX3",flex_box_column:"flex_box_column___GFV8F",row:"row___aXJjm",title:"title___HUKL0",tagsWrap:"tagsWrap___XB2W3",action:"action___VdHb1",bar:"bar___t1kKC",tag:"tag___V7Eft",name:"name___Hk1Ip",num:"num___xQpcH",active:"active___XryTX",tagsBorderWrap:"tagsBorderWrap___OMxjs"},$e=De(94184),Mt=De.n($e),Pt=De(96486),Qt=({dataSource:on=[],value:ln,onChange:gn,onTitleChange:Vn,className:_i,title:jt,titleWidth:zt=41,style:Ct={},fontColor:Yt="#6A7283",showCount:ci})=>{const[vi,ai]=(0,Ne.useState)(0),[Kt,wn]=(0,Ne.useState)(!1),pi=(0,Ne.useRef)(null),ji=(0,Ne.useRef)(null);return(0,Ne.useEffect)(()=>{var Rn;on.length!==0&&(((Rn=pi==null?void 0:pi.current)==null?void 0:Rn.clientHeight)>97?ai(1):ai(0)),on.length===0&&ai(0),wn(!1)},[on]),Ne.createElement("div",{className:Mt()(Ie.row,_i),style:Ct},Ne.createElement("div",{onClick:(0,Pt.throttle)(()=>Vn==null?void 0:Vn(),2e3),style:{width:zt,marginTop:Kt?12:4},className:`${Ie.title} ${Vn?"current":""}`},jt),Ne.createElement("div",{className:Kt?`${Ie.tagsWrap} ${Ie.tagsBorderWrap}`:Ie.tagsWrap},Ne.createElement("div",{className:Ie.bar,ref:ji,style:vi>0?{height:vi===1?97:"auto",overflow:vi===1?"hidden":"auto",paddingRight:55}:{paddingRight:0}},Ne.createElement("div",{className:Ie.tag,ref:pi},on==null?void 0:on.map(Rn=>Ne.createElement("span",{onClick:()=>gn(Rn.id),key:Rn.id,style:{color:Yt},className:ln===Rn.id?Ie.active:""},Ne.createElement("span",{title:Rn.name,className:Ie.name},Rn.name),!!ci&&Ne.createElement("span",{className:Ie.num},Rn.count))))),!!vi&&Ne.createElement(Ne.Fragment,null,vi===1?Ne.createElement("div",{onClick:()=>{var Rn;ai(2),((Rn=pi==null?void 0:pi.current)==null?void 0:Rn.clientHeight)>245?wn(!0):wn(!1)},className:Ie.action},"\u5C55\u5F00",Ne.createElement("i",{style:{transform:"translateY(1px) scale(0.6)"},className:"iconfont icon-zhankai4"})):Ne.createElement("div",{onClick:()=>{ji.current.scrollTop=0,ai(1),wn(!1)},className:Ie.action},"\u6536\u8D77",Ne.createElement("i",{style:{transform:"translateY(0px) scale(0.6)"},className:"iconfont icon-shouqi3"})))))},It={flex_box_center:"flex_box_center___aK2n3",flex_space_between:"flex_space_between___HX0Oh",flex_box_vertical_center:"flex_box_vertical_center___LJOJr",flex_box_center_end:"flex_box_center_end___SCakF",flex_box_column:"flex_box_column___AYv4m",tabs:"tabs___GTqPV",active:"active___F26E8"},Re=({dataSource:on=[],value:ln,onChange:gn,className:Vn,style:_i={}})=>Ne.createElement("div",{style:_i,className:Mt()(It.tabs,Vn)},on.map(jt=>Ne.createElement("span",{onClick:()=>gn(jt.id),className:ln===jt.id?It.active:"",key:jt.id},jt.name))),ne={flex_box_center:"flex_box_center___yX6Oa",flex_space_between:"flex_space_between___t7oqF",flex_box_vertical_center:"flex_box_vertical_center___dEIHy",flex_box_center_end:"flex_box_center_end___taQDF",flex_box_column:"flex_box_column___xY_Lr",input:"input___PW2zI",dropdown:"dropdown___vSy8B",menu:"menu___NiyBu",text:"text___Grueu",b1:"b1___ZKryM",b2:"b2___aKyGa"},te=De(28802),le=({dataSource:on=[],value:ln="",onChange:gn,onInputChange:Vn=()=>{},className:_i,style:jt={},placeholder:zt,allowClear:Ct=!1})=>{var Yt;const[ci,vi]=(0,Ne.useState)(""),[ai,Kt]=(0,Ne.useState)("");(0,Ne.useEffect)(()=>{var ji;let Rn=ln;(ji=JSON.stringify(ln))!=null&&ji.includes("{")&&(vi(ln.id),Rn=ln.value||"");try{Kt(decodeURIComponent(Rn||""))}catch(Dt){Kt(decodeURIComponent(Rn||""))}},[ln]);const wn=()=>{gn(encodeURIComponent(ai),ci||null)},pi=ji=>{ji!==ci&&(vi(ji),gn(encodeURIComponent(ai),ji))};return Ne.createElement("div",{className:Mt()(ne.input,_i),style:jt},!!on.length&&Ne.createElement("div",{className:ne.dropdown},Ne.createElement("div",{className:ne.text},(Yt=on.find(ji=>ji.id===ci))==null?void 0:Yt.name,Ne.createElement("i",{className:"iconfont icon-zhankai4"}),Ne.createElement("b",{className:ne.b1}),Ne.createElement("b",{className:ne.b2})),Ne.createElement("div",{className:ne.menu},on.map((ji,Rn)=>Ne.createElement("div",{key:Rn,onClick:()=>pi(ji.id)},ji.name)))),Ne.createElement(te.default,{onPressEnter:wn,value:ai,onChange:ji=>{Kt(ji.target.value),Vn(encodeURIComponent(ji.target.value),ci||null)},bordered:!1,placeholder:zt}),Ne.createElement("i",{onClick:wn,className:"iconfont icon-sousuo9 font14 pl10 current"}))},pe={flex_box_center:"flex_box_center___tol8o",flex_space_between:"flex_space_between___Z235C",flex_box_vertical_center:"flex_box_vertical_center___Wq1sZ",flex_box_center_end:"flex_box_center_end___LLxom",flex_box_column:"flex_box_column___DbMSN",quickPager:"quickPager___GM30J",disabled:"disabled___Ozc8I"},xe=({value:on,onChange:ln,className:gn,total:Vn,pageSize:_i,style:jt={}})=>{const zt=on<2,Ct=on>=Math.ceil(Vn/_i);return Vn<=_i?Ne.createElement(Ne.Fragment,null):Ne.createElement("div",{className:Mt()(pe.quickPager,gn),style:jt},Ne.createElement("div",{onClick:()=>{zt||ln(on-1,"prev")},className:zt?pe.disabled:""},"\u4E0A\u4E00\u9875"),Ne.createElement("div",{onClick:()=>{Ct||ln(on+1,"next")},className:Ct?pe.disabled:""},"\u4E0B\u4E00\u9875"))},Ee={flex_box_center:"flex_box_center___FO7TP",flex_space_between:"flex_space_between___LotYx",flex_box_vertical_center:"flex_box_vertical_center___bWdaw",flex_box_center_end:"flex_box_center_end___mVJ1o",flex_box_column:"flex_box_column___M83Mm",list:"list___oOsiS",wrap:"wrap___G6T7F",lockWrap:"lockWrap___Rl79E",li:"li___oZZ7l",cover:"cover___b2bYW",img:"img___IQX7w",sign:"sign___HkT6C",name:"name___SsJx8",e:"e___TMqq0",tags:"tags___bcjyo",rate:"rate___YACg7"},Ge=De(74330),et=De(83062),ut=De(57097),st=De(11320),it=De(28706),Nt=De(96908),St=De(57177),Ft=De(81378),cn=De(26194),hi=({className:on,dataSource:ln=[],col:gn=4,right:Vn,bottom:_i=23,precision:jt=0,wrapWidth:zt=1200,trackEventItems:Ct,loading:Yt})=>{const ci=Math.floor((zt-(gn-1)*Vn)/gn);return Ne.createElement(Ge.Z,{spinning:Yt},Ne.createElement("div",{className:Mt()(Ee.list,on)},!!ln.length&&ln.map((vi,ai)=>{const{name:Kt,id:wn,identifier:pi,power:ji,cover_image_id:Rn,pic:Dt}=vi;return Ne.createElement("div",{className:Ee.wrap,key:wn,style:{width:ci,marginRight:(1+ai)%gn===0?0:Vn+jt,marginBottom:_i}},Ne.createElement("a",{target:"_blank",href:`/shixuns/${pi}/challenges`,className:Ee.li,onClick:wi=>{wi.preventDefault(),Ct&&(0,it.L9)([Ct]),ji&&(0,it.xg)(`/shixuns/${pi}/challenges`)}},Ne.createElement("div",{className:Ee.img},Ne.createElement("img",{className:Ee.cover,src:`${Dt}`}),vi.is_jupyter&&Ne.createElement("img",{className:Ee.sign,src:Nt}),vi.is_jupyter_lab&&Ne.createElement("img",{className:Ee.sign,src:St}),vi.is_unity_3d&&Ne.createElement("img",{className:Ee.sign,src:Ft})),Ne.createElement("div",{className:Ee.name},Ne.createElement(et.Z,{title:Kt||"\u5B9E\u8DF5\u9879\u76EE\u540D\u79F0-\u672A\u586B\u5199"},Ne.createElement("span",{className:Ee.e},Kt||"\u5B9E\u8DF5\u9879\u76EE\u540D\u79F0-\u672A\u586B\u5199"))),Ne.createElement("div",{className:Ee.tags},Ne.createElement(et.Z,{placement:"bottom",title:"\u5173\u5361\u6570"},Ne.createElement("span",null,Ne.createElement("i",{className:"iconfont icon-shixunguanqia font14 mr2"}),Ne.createElement("span",null,vi.challenges_count))),!!vi.myshixuns_count&&Ne.createElement(et.Z,{placement:"bottom",title:"\u5B66\u4E60\u4EBA\u6570"},Ne.createElement("span",null,Ne.createElement("i",{className:"iconfont icon-chengyuan font14 mr2"}),Ne.createElement("span",null,vi.myshixuns_count))),Ne.createElement(et.Z,{placement:"bottom",title:"\u96BE\u5EA6\u7B49\u7EA7"},Ne.createElement("span",null,Ne.createElement("span",null,vi.level))),Ne.createElement("div",{className:Ee.rate},Ne.createElement(ut.Z,{allowHalf:!0,disabled:!0,defaultValue:vi.score_info}),Ne.createElement("span",null,"\xA0",vi.score_info?`${vi.score_info}\u5206`:"5\u5206")))),!ji&&Ne.createElement("div",{className:Ee.lockWrap},Ne.createElement("img",{src:`${st.Z.IMG_SERVER}/images/educoder/icon/lockclose.svg`}),Ne.createElement("span",{className:"mt15 font16 c-white"},"\u5B9A\u5411\u5F00\u653E\u5185\u5BB9\uFF0C\u9700\u8981\u6388\u6743")))}),!ln.length&&Ne.createElement(cn.Z,null)))},di=De(5476),zn={flex_box_center:"flex_box_center___eMcr7",flex_space_between:"flex_space_between___HcNca",flex_box_vertical_center:"flex_box_vertical_center___ZnvVN",flex_box_center_end:"flex_box_center_end___fdgDf",flex_box_column:"flex_box_column___SEKvd",list:"list___L1hmU",wrap:"wrap___pKgcW",lockWrap:"lockWrap___SMhkK",top:"top___udHSB",sign:"sign___uwRpq",name:"name___Fpf90",img:"img___AMLhL",text:"text___KiTb7",btns:"btns___i6IuZ",bottom:"bottom____k2sh"},Dn="data:image/png;base64,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",nt=De(67294),ke=({className:on,dataSource:ln=[],col:gn=4,right:Vn,bottom:_i=23,precision:jt=0,wrapWidth:zt=1200,trackEventItems:Ct,loading:Yt,handleVery:ci=()=>!0})=>{const vi=Math.floor((zt-(gn-1)*Vn)/gn);return nt.createElement(Ge.Z,{spinning:Yt},nt.createElement("div",{className:Mt()(zn.list,on)},!!ln.length&&ln.map((ai,Kt)=>{const{subject_identifier:wn,id:pi,identifier:ji,power:Rn}=ai,Dt=ai.is_public!=0&&ai.is_public;return nt.createElement("div",{className:zn.wrap,key:pi,style:{width:vi,marginRight:(1+Kt)%gn===0?0:Vn+jt,marginBottom:_i}},nt.createElement("a",{className:zn.li,onClick:wi=>{wi.preventDefault(),ci(ai==null?void 0:ai.first_category_url)&&(Ct&&(0,it.L9)([Ct]),(0,it.xg)(ai.first_category_url))}},nt.createElement("div",{className:zn.top},nt.createElement(et.Z,{title:ai.name},nt.createElement("div",{className:zn.name},ai.name)),nt.createElement("img",{className:zn.img,src:st.Z.IMG_SERVER+"/images/"+ai.avatar_url}),nt.createElement("div",{className:zn.text,title:ai.creator},ai.creator),wn&&nt.createElement("div",{className:zn.btns},nt.createElement("div",null,"\u5F00\u653E\u8BFE\u7A0B"),nt.createElement("aside",null,"\u5F00\u653E\u8BFE\u5802")),Dt&&nt.createElement("div",{className:zn.sign},"\u516C\u5F00")),nt.createElement("div",{className:zn.bottom},ai.visits>0&&nt.createElement(et.Z,{title:"\u8BBF\u95EE\u91CF",placement:"bottom"},nt.createElement("span",null,nt.createElement("i",{className:"iconfont icon-liulanyan"}),nt.createElement("span",null,ai.visits))),ai.course_members_count>0&&nt.createElement(et.Z,{title:"\u6210\u5458",placement:"bottom"},nt.createElement("span",null,nt.createElement("i",{className:"iconfont icon-chengyuan"}),ai.course_members_count)),ai.tasks_count>0&&nt.createElement(et.Z,{title:"\u4F5C\u4E1A",placement:"bottom"},nt.createElement("span",null,nt.createElement("i",{className:"iconfont icon-zuoye"}),ai.tasks_count)),ai.is_end?nt.createElement("div",{style:{color:"#6B758B"}},"\u5DF2\u7ED3\u675F"):nt.createElement("div",{style:{color:"#00B187"}},"\u8FDB\u884C\u4E2D"))),!ai.is_accessible&&nt.createElement("div",{className:zn.lockWrap},nt.createElement("img",{src:`${st.Z.IMG_SERVER}/images/educoder/icon/lockclose.svg`}),nt.createElement("span",{className:"mt15 font16 c-white"},"\u975E\u8BFE\u5802\u6210\u5458\u4E0D\u53EF\u8FDB\u5165")))}),!ln.length&&nt.createElement(cn.Z,null)))},Wt={flex_box_center:"flex_box_center___d27mZ",flex_space_between:"flex_space_between___qfRU9",flex_box_vertical_center:"flex_box_vertical_center___fCRld",flex_box_center_end:"flex_box_center_end___ORMV8",flex_box_column:"flex_box_column___PNKtZ",tabs:"tabs___alpa7",tabsWrap:"tabsWrap___aCQjw",tab:"tab___MKLr4",active:"active___nl_4v"},On=De(35973),xn=({dataSource:on=[],value:ln,onChange:gn,className:Vn,style:_i={},tabBarExtraContent:jt})=>Ne.createElement("div",{className:Mt()(Wt.tabs,Vn),style:_i},Ne.createElement("div",{className:Wt.tabsWrap},on.map((zt,Ct)=>!(zt!=null&&zt.hide)&&Ne.createElement("aside",{className:Wt.tab,onClick:()=>{gn(zt.id),zt.link&&On.history.push(zt.link)},key:Ct},Ne.createElement("div",{className:ln===zt.id?Wt.active:""},zt.name),(zt==null?void 0:zt.resetCount)==null&&(zt==null?void 0:zt.total)!==void 0&&Ne.createElement("span",null,"\uFF08",zt==null?void 0:zt.total,"\uFF09"),(zt==null?void 0:zt.resetCount)!==void 0&&(zt==null?void 0:zt.total)!==void 0&&Ne.createElement(et.Z,{title:(zt==null?void 0:zt.tip)!=null?zt==null?void 0:zt.tip:""},Ne.createElement("span",{style:{color:"#9096A3"}},"\uFF08",Ne.createElement("span",{style:{color:"#000"}},zt==null?void 0:zt.resetCount),"/",Ne.createElement("span",null,zt==null?void 0:zt.total),"\uFF09"))))),Ne.createElement("div",{className:Wt.tabBar},jt)),Xn=({className:on,style:ln={},children:gn})=>Ne.createElement("div",{className:Mt()(on),style:ln},gn),Ot={flex_box_center:"flex_box_center___e6HxQ",flex_space_between:"flex_space_between___RnXYe",flex_box_vertical_center:"flex_box_vertical_center___lVxPk",flex_box_center_end:"flex_box_center_end___bu8yv",flex_box_column:"flex_box_column___JczGj",orderWrap:"orderWrap___ZfyGX",orderIconWrap:"orderIconWrap___XTB_O",orderAsc:"orderAsc___KWHmA",orderDesc:"orderDesc___rHdbB",active:"active___a7eSP",cursorPointer:"cursorPointer___gs9kL",orderTextWrap:"orderTextWrap___teAKn"},ft=De(85418),Gt=De(50136);const an=[{id:"updated_at",name:"\u6700\u65B0\u52A8\u6001"},{id:"created_at",name:"\u6700\u65B0\u521B\u5EFA"},{id:"name",name:"\u540D\u79F0\u6392\u5E8F"}];var Ve=({sortValue:on,dropValue:ln,className:gn,onSort:Vn,onDrop:_i,dataSource:jt=an})=>{var zt;return Ne.createElement("div",{className:Mt()(Ot.orderWrap,gn)},Ne.createElement(ft.Z,{dropdownRender:()=>Ne.createElement(Gt.default,null,jt.map((Ct,Yt)=>Ne.createElement(Gt.default.Item,{key:Yt,onClick:()=>_i(Ct.id)},Ct.name)))},Ne.createElement("span",{className:Ot.orderTextWrap},(zt=jt.find(Ct=>ln===Ct.id))==null?void 0:zt.name)),Ne.createElement("span",{className:Ot.orderIconWrap},Ne.createElement("span",{className:Ot.orderAsc},Ne.createElement("i",{className:on==="asc"?`iconfont icon-sanjiaoxing-up font12 ${Ot.cursorPointer} ${Ot.active}`:`iconfont icon-sanjiaoxing-up font12 ${Ot.cursorPointer}`,onClick:()=>Vn(on==="asc"?"desc":"asc")})),Ne.createElement("span",{className:Ot.orderDesc},Ne.createElement("i",{className:on==="desc"?`iconfont icon-sanjiaoxing-down font12 ${Ot.cursorPointer} ${Ot.active}`:`iconfont icon-sanjiaoxing-down font12 ${Ot.cursorPointer}`,onClick:()=>Vn(on==="asc"?"desc":"asc")}))))},be={flex_box_center:"flex_box_center___LCi0B",flex_space_between:"flex_space_between___hzONe",flex_box_vertical_center:"flex_box_vertical_center___ZyQRE",flex_box_center_end:"flex_box_center_end___XKM74",flex_box_column:"flex_box_column___p8LCU",btn:"btn___In02G","mediacy-round":"mediacy-round___uveEv","mediacy-default":"mediacy-default___dDxsd",default:"default___K791v"},Pe=De(85804),Be=Object.defineProperty,Ze=Object.getOwnPropertySymbols,Fe=Object.prototype.hasOwnProperty,qe=Object.prototype.propertyIsEnumerable,dn=(on,ln,gn)=>ln in on?Be(on,ln,{enumerable:!0,configurable:!0,writable:!0,value:gn}):on[ln]=gn,ui=(on,ln)=>{for(var gn in ln||(ln={}))Fe.call(ln,gn)&&dn(on,gn,ln[gn]);if(Ze)for(var gn of Ze(ln))qe.call(ln,gn)&&dn(on,gn,ln[gn]);return on},$n=(on,ln)=>{var gn={};for(var Vn in on)Fe.call(on,Vn)&&ln.indexOf(Vn)<0&&(gn[Vn]=on[Vn]);if(on!=null&&Ze)for(var Vn of Ze(on))ln.indexOf(Vn)<0&&qe.call(on,Vn)&&(gn[Vn]=on[Vn]);return gn},rn=(on,ln,gn)=>new Promise((Vn,_i)=>{var jt=Yt=>{try{Ct(gn.next(Yt))}catch(ci){_i(ci)}},zt=Yt=>{try{Ct(gn.throw(Yt))}catch(ci){_i(ci)}},Ct=Yt=>Yt.done?Vn(Yt.value):Promise.resolve(Yt.value).then(jt,zt);Ct((gn=gn.apply(on,ln)).next())}),Zt=on=>{var ln=on,{className:gn,style:Vn,children:_i,loading:jt=!1,openLoading:zt,onClick:Ct=()=>{},size:Yt="middle",shape:ci="round"}=ln,vi=$n(ln,["className","style","children","loading","openLoading","onClick","size","shape"]);const[ai,Kt]=(0,Ne.useState)(!1);return Ne.createElement(Pe.ZP,ui({onClick:(0,Pt.throttle)(wn=>rn(void 0,null,function*(){zt&&Kt(!0);try{yield Ct(wn)}catch(pi){console.log("error",pi)}zt&&Kt(!1)}),2e3,{leading:!0,trailing:!1}),className:Mt()(be.btn,be[`${Yt}-${ci}`],gn),style:Vn,size:Yt,shape:ci,loading:ai||jt},vi),_i)},_n={flex_box_center:"flex_box_center___TB7bQ",flex_space_between:"flex_space_between___oBlTb",flex_box_vertical_center:"flex_box_vertical_center___b5XbB",flex_box_center_end:"flex_box_center_end___CNhe7",flex_box_column:"flex_box_column___yHXKW",head:"head___ghH72",node:"node___mjPEy"},Ri=({className:on,style:ln,children:gn=null,onClick:Vn,title:_i})=>Ne.createElement("div",{className:Mt()(_n.head,on),style:ln},Ne.createElement("span",{className:"primary-hover",onClick:Vn},Ne.createElement("i",{className:"iconfont icon-fanhui2 font12"}),"\u8FD4\u56DE"),Ne.createElement("b",{title:_i},_i),Ne.createElement("div",{className:_n.node},gn)),oi={flex_box_center:"flex_box_center___AlHuF",flex_space_between:"flex_space_between___vN2LW",flex_box_vertical_center:"flex_box_vertical_center___Ac7D2",flex_box_center_end:"flex_box_center_end___y38I7",flex_box_column:"flex_box_column___iQE6P",btns:"btns___sNgTb",confirm:"confirm___Ozirl",cancel:"cancel___aiq1I"},fr=({confirmShow:on=!0,confirmTitle:ln,confirmClick:gn,cancelShow:Vn=!0,cancelTitle:_i,cancelClick:jt,className:zt,style:Ct,confirmLoading:Yt=!1})=>Ne.createElement("div",{className:Mt()(oi.btns,zt),style:Ct},on&&Ne.createElement(Pe.ZP,{loading:Yt,onClick:gn,type:"primary",className:oi.confirm},ln),Vn&&Ne.createElement(Pe.ZP,{onClick:jt,className:oi.cancel},_i)),Ei={flex_box_center:"flex_box_center___jkpdr",flex_space_between:"flex_space_between___OtsL8",flex_box_vertical_center:"flex_box_vertical_center___rbcb_",flex_box_center_end:"flex_box_center_end___zBR21",flex_box_column:"flex_box_column___nS_eP",fixedBottom:"fixedBottom___oJl7m",wrap:"wrap___A3Oq1",center:"center____VL1y"},uo=({className:on,style:ln={},LeftContent:gn,children:Vn,RightContent:_i})=>Ne.createElement("div",{className:Mt()(Ei.fixedBottom,on),style:ln},Ne.createElement("div",{className:Ei.wrap},Ne.createElement("div",{className:Ei.left},gn),Ne.createElement("div",{className:Ei.center},Vn),Ne.createElement("div",{className:Ei.right},_i))),vt={flex_box_center:"flex_box_center___tY8Yn",flex_space_between:"flex_space_between___vHdYA",flex_box_vertical_center:"flex_box_vertical_center___pa61F",flex_box_center_end:"flex_box_center_end___HyDXt",flex_box_column:"flex_box_column___UjZek",crumbs:"crumbs___V41Oe",hover:"hover___bEIVd"},co=({className:on,style:ln={},dataSource:gn=[]})=>Ne.createElement("div",{className:Mt()(vt.crumbs,on),style:ln},gn.map((Vn,_i)=>_i<gn.length-1?Ne.createElement(Ne.Fragment,{key:_i},Vn.path||Vn.onClick?Ne.createElement("span",{className:vt.hover,onClick:Vn!=null&&Vn.onClick?Vn.onClick:()=>On.history.push(Vn.path)},Vn.name):Ne.createElement("span",null,Vn.name),Ne.createElement("span",null,"\xA0",">","\xA0")):Ne.createElement("span",{key:_i,style:{color:"#5F6368"}},Vn.name))),bo=De(55054),Ui=Object.defineProperty,yo=Object.defineProperties,ha=Object.getOwnPropertyDescriptors,Ka=Object.getOwnPropertySymbols,Ra=Object.prototype.hasOwnProperty,ca=Object.prototype.propertyIsEnumerable,ma=(on,ln,gn)=>ln in on?Ui(on,ln,{enumerable:!0,configurable:!0,writable:!0,value:gn}):on[ln]=gn,Ho=(on,ln)=>{for(var gn in ln||(ln={}))Ra.call(ln,gn)&&ma(on,gn,ln[gn]);if(Ka)for(var gn of Ka(ln))ca.call(ln,gn)&&ma(on,gn,ln[gn]);return on},_r=(on,ln)=>yo(on,ha(ln)),Fn=(on,ln)=>{var gn={};for(var Vn in on)Ra.call(on,Vn)&&ln.indexOf(Vn)<0&&(gn[Vn]=on[Vn]);if(on!=null&&Ka)for(var Vn of Ka(on))ln.indexOf(Vn)<0&&ca.call(on,Vn)&&(gn[Vn]=on[Vn]);return gn};const{Countdown:we}=bo.default;var bn=on=>{var ln=on,{onChange:gn}=ln,Vn=Fn(ln,["onChange"]);const[_i,jt]=(0,Ne.useState)(null);(0,Ne.useEffect)(()=>{typeof _i=="number"&&_i>=0&&gn(_i)},[_i]);const zt=Ct=>{const Yt=Math.floor(Ct/1e3);jt(Yt)};return Ne.createElement(we,_r(Ho({},Vn),{onChange:zt}))}},99914:function(jn,li,De){"use strict";De.d(li,{Z:function(){return dt}});var Ne=De(67294);function dt(Ut,$t){const kt=(0,Ne.useRef)();(0,Ne.useEffect)(()=>{kt.current=Ut}),(0,Ne.useEffect)(()=>{function Ie(){kt.current()}if($t!==null){let $e=setInterval(Ie,$t);return()=>clearInterval($e)}},[$t])}},4440:function(jn,li,De){"use strict";De.d(li,{$J:function(){return Ut},JZ:function(){return kt},bN:function(){return $e},jP:function(){return Ie},rO:function(){return $t}});var Ne=De(33170),dt=(Mt,Pt,wt)=>new Promise((Qt,It)=>{var sn=te=>{try{ne(wt.next(te))}catch(he){It(he)}},Re=te=>{try{ne(wt.throw(te))}catch(he){It(he)}},ne=te=>te.done?Qt(te.value):Promise.resolve(te.value).then(sn,Re);ne((wt=wt.apply(Mt,Pt)).next())});function Ut(Mt){return(0,Ne.U2)(`libraries/${Mt}.json`)}function $t(){return(0,Ne.U2)("library_tags.json")}function kt(Mt){return dt(this,null,function*(){return(yield(0,Ne.IV)(`attachments/${Mt}.json`)).status===0})}function Ie(Mt){return(0,Ne.v_)("libraries.json",Mt)}function $e(Mt,Pt){return(0,Ne.gz)(`libraries/${Mt}.json`,Pt)}},99640:function(jn,li,De){"use strict";De.d(li,{Z:function(){return wt}});var Ne=De(62844),dt={ul:"ul___TdfYY"},Ut=De(32637),$t=De(67294),kt=Object.getOwnPropertySymbols,Ie=Object.prototype.hasOwnProperty,$e=Object.prototype.propertyIsEnumerable,Mt=(Qt,It)=>{var sn={};for(var Re in Qt)Ie.call(Qt,Re)&&It.indexOf(Re)<0&&(sn[Re]=Qt[Re]);if(Qt!=null&&kt)for(var Re of kt(Qt))It.indexOf(Re)<0&&$e.call(Qt,Re)&&(sn[Re]=Qt[Re]);return sn},wt=Qt=>{var It=Qt,{open:sn,onCancel:Re}=It,ne=Mt(It,["open","onCancel"]);return $t.createElement(Ne.default,{centered:!0,open:sn,title:$t.createElement("div",{style:{fontWeight:"bold"}},"\u8054\u7CFB\u6559\u7814\u52A9\u7406"),width:"696px",onCancel:Re,footer:null},$t.createElement("div",null,$t.createElement("div",{className:"tc"},$t.createElement("img",{className:"mt10",src:Ut,width:"182px",height:"181px",style:{borderRadius:"2px",border:"1px solid #D8E3E9"}})),$t.createElement("div",{style:{color:"#191919",fontWeight:"bold"},className:"tc font16 mt10"},"\u514D\u8D39\u6559\u7814\u52A9\u7406"),$t.createElement("div",{style:{color:"#191919",fontWeight:"bold"},className:"tc font16"},"\u5FAE\u4FE1\u626B\u4E00\u626B\u6DFB\u52A0"),$t.createElement("div",{style:{color:"#333"},className:"pt30 font14"},$t.createElement("ul",{className:dt.ul},$t.createElement("li",null,"1\u3001\u89E3\u7B54\u8001\u5E08\u7591\u60D1\u3001\u5E2E\u52A9\u8001\u5E08\u66F4\u5FEB\u719F\u6089\u548C\u4F7F\u7528\u5E73\u53F0\u6559\u5B66\u3002"),$t.createElement("li",null,"2\u3001\u534F\u52A9\u8001\u5E08\u521B\u5EFA\u8BFE\u5802\u3001\u8BFE\u7A0B\u8BBE\u8BA1\u3001\u505A\u597D\u6559\u5B66\u5DE5\u4F5C\u3002"),$t.createElement("li",null,"3\u3001\u6839\u636E\u8001\u5E08\u6559\u5B66\u65B9\u5411\uFF0C\u5206\u4EAB\u5934\u6B4C\u5E73\u53F0C9\u9662\u6821\u3001985\u9AD8\u6821\u3001211\u9AD8\u6821\u3001\u53CC\u4E00\u6D41\u9AD8\u6821\u8001\u5E08\u7ECF\u5178\u5B9E\u8DF5\u6559\u5B66\u6848\u4F8B\u3002")))))}},40957:function(jn,li,De){"use strict";De.r(li),De.d(li,{default:function(){return bn}});var Ne=De(67294),dt=De(35973),Ut=De(28802),$t=De(60024),kt=De(88044),Ie=De(91773),$e=De(2453),Mt=De(62844),Pt=De(63960),wt=De(71230),Qt=De(15746),It=De(59637),sn=De(98813),Re=De(84567),ne=De(51380),te=De(35059),he=De(85804),le=De(74330),pe=De(35567),me={bg:"bg____raBL",wrap:"wrap___HeK2P",crumbs:"crumbs___bamBY",titleWrap:"titleWrap___UpC0c",flexRow:"flexRow___WjoyK",flexJustifyCenter:"flexJustifyCenter___V6ndk",flexAlignEnd:"flexAlignEnd___So64w",flexAlignCenter:"flexAlignCenter___WWRXs",flexColumn:"flexColumn___b0Fz8",formWrap:"formWrap___Bmhgz",fieldWrap:"fieldWrap___pR4UB",mdWrap:"mdWrap___FPskk",tree:"tree___bVp9O",backgroundFa:"backgroundFa___ghlCO",aBtn:"aBtn___M7dWu",bBtn:"bBtn___XycZO",cascaderWrap:"cascaderWrap___CPNAV",listItem:"listItem____eV5T",right:"right___x8wr7",one:"one___wdYdi",schoolHintWrap:"schoolHintWrap___AWsQj",colorCDCDCD:"colorCDCDCD___xguLh",color0152d9:"color0152d9___MEYYd",spanText:"spanText___Srs_u",addTypeRadio:"addTypeRadio___JTRkP",add_ai:"add_ai___JGWFe",paths_content:"paths_content___Rzg9i",content_header:"content_header___LvvU1",header_box:"header_box___c05Gw",header_bj:"header_bj____CaVY",header_text:"header_text___jNO1N",lianjie:"lianjie___vtxBe",buzou_box:"buzou_box___qkXlL",no_start_style:"no_start_style___ONC9T",start_style:"start_style___vWVZl"},xe=De(28706),Ee=De(11320),Ge=De(33170),et=De(32983),ut={cascaderContainer:"cascaderContainer___uz26h",valueWrap:"valueWrap___zTHXb",valueItem:"valueItem___vBNoA",placeholder:"placeholder___bJTkn",modalWrap:"modalWrap___uhROO",left:"left___oZrbl",right:"right___y9QjL",disabled:"disabled___LVx0f",emptyWrap:"emptyWrap___KG5pK"},st=De(73475),it=De(91034),Nt=Object.defineProperty,St=Object.defineProperties,Ft=Object.getOwnPropertyDescriptors,cn=Object.getOwnPropertySymbols,Tt=Object.prototype.hasOwnProperty,hi=Object.prototype.propertyIsEnumerable,di=(on,ln,gn)=>ln in on?Nt(on,ln,{enumerable:!0,configurable:!0,writable:!0,value:gn}):on[ln]=gn,zn=(on,ln)=>{for(var gn in ln||(ln={}))Tt.call(ln,gn)&&di(on,gn,ln[gn]);if(cn)for(var gn of cn(ln))hi.call(ln,gn)&&di(on,gn,ln[gn]);return on},Dn=(on,ln)=>St(on,Ft(ln)),nt=(on,ln)=>{var gn={};for(var Vn in on)Tt.call(on,Vn)&&ln.indexOf(Vn)<0&&(gn[Vn]=on[Vn]);if(on!=null&&cn)for(var Vn of cn(on))ln.indexOf(Vn)<0&&hi.call(on,Vn)&&(gn[Vn]=on[Vn]);return gn};const ze=(0,Ne.createRef)();var Wt=({dataSource:on,placeholder:ln,defaultValue:gn,onChange:Vn})=>{const[_i,jt]=(0,Ne.useState)(!1),[zt,Ct]=(0,Ne.useState)({data:[],objData:{},ids:[]}),[Yt,ci]=(0,Ne.useState)({});(0,Ne.useEffect)(()=>{window.addEventListener("click",()=>{jt(!1),ci({})})},[]),(0,Ne.useEffect)(()=>{if(gn){let pi={},ji=[];gn.forEach(Rn=>{const Dt=Rn,{sub_discipline:wi}=Dt,gr=nt(Dt,["sub_discipline"]);wi&&(pi[wi.id]=Dn(zn({},gr),{sub_disciplines:[wi]}),ji.push(wi.id))}),Ct({ids:ji,data:Object.values(pi),objData:pi}),Vn(ji)}},[gn]);const vi=()=>Ne.createElement("div",{className:ut.emptyWrap},Ne.createElement(et.Z,{image:et.Z.PRESENTED_IMAGE_SIMPLE})),ai=pi=>{if(zt.ids.includes(pi.id))return!1;const ji=Yt,{sub_disciplines:Rn}=ji,Dt=nt(ji,["sub_disciplines"]),wi=Dn(zn({},zt.objData),{[pi.id]:Dn(zn({},Dt),{sub_disciplines:[pi]})});Ct({ids:[...zt.ids,pi.id],data:Object.values(wi),objData:wi}),Vn([...zt.ids,pi.id])},Kt=pi=>{const ji=zt.objData;delete ji[pi];const Rn=zt.ids.filter(Dt=>Dt!==pi);Ct({data:Object.values(ji),objData:ji,ids:Rn}),Vn(Rn)};let wn=45;return ze&&ze.current&&ze.current.clientHeight>45&&(wn=ze.current.clientHeight+5),Ne.createElement("div",{className:ut.cascaderContainer,onClick:pi=>{pi.stopPropagation()}},Ne.createElement("div",{ref:ze,className:ut.valueWrap,onClick:()=>jt(!_i)},zt.data.length===0&&Ne.createElement("span",{className:ut.placeholder},ln||"\u8BF7\u9009\u62E9\u65B9\u5411&\u8BFE\u7A0B"),zt.data.map(pi=>Ne.createElement("div",{className:ut.valueItem,key:pi.id},Ne.createElement("span",null,pi.name),Ne.createElement("span",null,"/"),Ne.createElement("span",null,pi.sub_disciplines[0].name),Ne.createElement("span",{onClick:ji=>{ji.stopPropagation(),ji.preventDefault(),Kt(pi.sub_disciplines[0].id)}},Ne.createElement(st.Z,null))))),_i&&Ne.createElement("div",{className:ut.modalWrap,style:{top:wn}},Ne.createElement("div",{className:ut.left},on.length===0&&vi(),on.length>0&&on.map(pi=>Ne.createElement("div",{key:pi.id,onClick:()=>{ci(pi)}},Ne.createElement("span",null,pi.name),Ne.createElement("span",null,Ne.createElement(it.Z,null))))),Yt.sub_disciplines&&Ne.createElement("div",{className:ut.right},Yt.sub_disciplines.length===0&&vi(),Yt.sub_disciplines.length>0&&Yt.sub_disciplines.map(pi=>{const ji=zt.ids.includes(pi.id);return Ne.createElement("div",{key:pi.id,className:ji?ut.disabled:"",onClick:()=>{ai(pi),jt(!1)}},pi.name)}))))},On=De(57399),Lt=De(38089),xn=De(94699),vn=De.n(xn),Xn=De(87725),Ot=De(16646),ft=De(70757),Gt={flexRow:"flexRow___qY1Ro",flexColumn:"flexColumn___xTKsc",formWrap:"formWrap___OJ1NZ",example:"example___XZnZv",footerWrap:"footerWrap___DSZCv"},an=De(67294),Jt=Object.defineProperty,Ve=Object.getOwnPropertySymbols,be=Object.prototype.hasOwnProperty,Pe=Object.prototype.propertyIsEnumerable,Be=(on,ln,gn)=>ln in on?Jt(on,ln,{enumerable:!0,configurable:!0,writable:!0,value:gn}):on[ln]=gn,Ze=(on,ln)=>{for(var gn in ln||(ln={}))be.call(ln,gn)&&Be(on,gn,ln[gn]);if(Ve)for(var gn of Ve(ln))Pe.call(ln,gn)&&Be(on,gn,ln[gn]);return on},Fe=(on,ln)=>{var gn={};for(var Vn in on)be.call(on,Vn)&&ln.indexOf(Vn)<0&&(gn[Vn]=on[Vn]);if(on!=null&&Ve)for(var Vn of Ve(on))ln.indexOf(Vn)<0&&Pe.call(on,Vn)&&(gn[Vn]=on[Vn]);return gn},qe=(on,ln,gn)=>new Promise((Vn,_i)=>{var jt=Yt=>{try{Ct(gn.next(Yt))}catch(ci){_i(ci)}},zt=Yt=>{try{Ct(gn.throw(Yt))}catch(ci){_i(ci)}},Ct=Yt=>Yt.done?Vn(Yt.value):Promise.resolve(Yt.value).then(jt,zt);Ct((gn=gn.apply(on,ln)).next())});const dn=(on,ln)=>ln.some(gn=>gn.label.toLowerCase().indexOf(on.toLowerCase())>-1),ui=Ut.default.TextArea,$n=on=>{var ln=on,{newCourse:gn,globalSetting:Vn,loading:_i,dispatch:jt,schoolName:zt,onSuccess:Ct=()=>{}}=ln,Yt=Fe(ln,["newCourse","globalSetting","loading","dispatch","schoolName","onSuccess"]);const[ci]=Ie.default.useForm();(0,Ne.useEffect)(()=>{ci.setFieldsValue({name:zt})},[zt]);const vi=ai=>qe(void 0,null,function*(){const{name:Kt,city:wn=[],address:pi,remarks:ji}=ai||{},Rn=yield jt({type:"newCourse/appplySchool",payload:{name:Kt,province:wn[0],city:wn[1],address:pi,remarks:ji}});if((Rn==null?void 0:Rn.status)==2){const Dt=Mt.default.confirm({icon:null,width:600,centered:!0,okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",title:"\u63D0\u793A",content:an.createElement(an.Fragment,null,an.createElement("p",null,"\u7CFB\u7EDF\u68C0\u6D4B\u5230\u60A8\u7533\u8BF7\u65B0\u589E\u7684\u5355\u4F4D\u5DF2\u5B58\u5728\uFF0C\u8BF7\u786E\u8BA4\u662F\u5426\u4E3A\u8BE5\u5355\u4F4D\uFF1F"),an.createElement(On.default,{columns:[{title:"\u5B66\u6821/\u5355\u4F4D",dataIndex:"name"},{title:"\u7528\u6237\u6570",width:150,dataIndex:"users_count"}],dataSource:[Ze({},Rn)],pagination:!1})),onOk:()=>qe(void 0,null,function*(){yield Ct(Kt),Dt.destroy(),jt({type:"newCourse/setActionTabs",payload:{}})}),onCancel:()=>{Dt.destroy()}});return}jt({type:"newCourse/setActionTabs",payload:{}}),Rn.status==0&&($e.ZP.success("\u65B0\u589E\u53D1\u5E03\u5355\u4F4D\u6210\u529F\uFF01"),Ct(Kt))});return an.createElement(Mt.default,{centered:!0,keyboard:!1,closable:!1,destroyOnClose:!0,open:gn.actionTabs.key==="NewCourse-AppplySchool",title:"\u7533\u8BF7\u53D1\u5E03\u5355\u4F4D",width:"600px",footer:null},an.createElement(Ie.default,{className:Gt.formWrap,form:ci,labelCol:{span:4},wrapperCol:{span:20},onFinish:vi},an.createElement(Ie.default.Item,{label:"\u53D1\u5E03\u5355\u4F4D\uFF1A",name:"name",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5B66\u6821\u6216\u5DE5\u4F5C\u5355\u4F4D"}]},an.createElement(Ut.default,{placeholder:"\u8BF7\u8F93\u5165\u53D1\u5E03\u5355\u4F4D"})),an.createElement("div",{className:`${Gt.flexRow} ${Gt.example}`},an.createElement("div",null,"\u793A\u4F8B\uFF1A"),an.createElement("div",{className:Gt.flexColumn},an.createElement("div",null,an.createElement(Xn.Z,{style:{color:"rgb(82, 196, 26)"}}),an.createElement("span",{className:"font14 ml5"},"\u6B63\u786E\u793A\u4F8B\uFF1A\u6570\u636E\u7ED3\u6784")),an.createElement("div",null,an.createElement(Ot.Z,{style:{color:"red"}}),an.createElement("span",{className:"font14 ml5"},"\u9519\u8BEF\u793A\u4F8B\uFF1A\u6570\u636E\u7ED3\u6784",vn()().format("YYYY"),"\u6625")))),an.createElement(Ie.default.Item,{label:"\u5730\u533A\uFF1A",name:"city"},an.createElement(Lt.Z,{allowClear:!0,size:"middle",options:ft.P,placeholder:"\u8BF7\u9009\u62E9\u6240\u5728\u5730",showSearch:{matchInputWidth:!0,filter:dn}})),an.createElement(Ie.default.Item,{label:"\u8BE6\u7EC6\u5730\u5740\uFF1A",name:"address"},an.createElement(Ut.default,{placeholder:"\u8BF7\u586B\u5199\u5B8C\u6574\u7684\u5730\u5740\u4FE1\u606F"})),an.createElement(Ie.default.Item,{label:"\u8BF4\u660E\uFF1A",name:"remarks"},an.createElement(ui,{placeholder:"\u518D\u6B21\u8BF4\u660E\u7279\u522B\u60C5\u51B5\uFF08\u9009\u586B\uFF09"})),an.createElement("div",{className:Gt.footerWrap},an.createElement(Ie.default.Item,null,an.createElement(he.ZP,{className:"mr5",size:"middle",onClick:()=>{jt({type:"newCourse/setActionTabs",payload:{}})}},"\u53D6\u6D88"),an.createElement(he.ZP,{size:"middle",type:"primary",htmlType:"submit",loading:_i["newCourse/appplySchool"]},"\u4FDD\u5B58")))))};var rn=(0,dt.connect)(({newCourse:on,loading:ln,globalSetting:gn})=>({newCourse:on,globalSetting:gn,loading:ln.effects}))($n),Hn=De(99640),Zt=De(65866),_n="data:image/png;base64,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",ti="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAYIAAAAoCAYAAADzCv21AAAAAXNSR0IArs4c6QAAApFJREFUeF7t3TFO42AQgFEiQSIKKrgEiJqb0HI4Wm5CjeASUFGgBArkSInixPY/rWfetqHIPI80+tjdZPHw9HH9e/6zOvOHAAECBFIJrL+Xn+8v95vWUIu7x7fl6mpz0/pBrxMgQIDAvAQu/i7Xr8+3X613veh+QBW0mLxOgACBeQpEqmB7CFTBPB+wd02AAIGWQKQKtodAFbQovU6AAIH5CrSqYH8IVMF8H7J3ToAAgSmBVhXsD4EqsEgECBDIKzBVBb1DoAryLoHJCBCoLTBVBb1DoApqL4rpCRDILTBWBSeHQBXkXgTTESBQV2CsCk4OgSqouyQmJ0Agv8BQFQweAlWQfxlMSIBATYGhKhg8BKqg5oKYmgCBGgLHVTB6CFRBjYUwJQEC9QSOq2D0EKiCesthYgIE6ggcVsHkIVAFdZbCpAQI1BI4rILJQ6AKai2GaQkQqCWwq4LmIVAFtRbDtAQI1BHYVUHzEKiCOkthUgIE6gl0VRA6BKqg3nKYmACBGgJdFTgENZ61KQkQIDAoED4EvsrSBhEgQCCnQOhXQ34tlPPhm4oAAQLhvyxWA5aFAAECOQVC/3xUDeR8+KYiQIBA+D+UqQHLQoAAgZwCoY+YUAM5H76pCBAgEP7QOTVgWQgQIJBTIPQx1Gog58M3FQECBMJfTKMGLAsBAgRyCoS+qlIN5Hz4piJAgED4y+vVgGUhQIBAToGhGugm7X3WkBrI+fBNRYAAgbEaODkEasCyECBAIKfAWA30DoEayPnwTUWAAIGpGugdAjVgWQgQIJBTYKoG9odADeR8+KYiQIBAqwb2h0ANWBYCBAjkFGjVwPYQqIGcD99UBAgQiNTA9hCoActCgACBnAKRGugm/wceYDXmz1T+uAAAAABJRU5ErkJggg==",Ri="data:image/png;base64,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",oi="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOkAAACzCAYAAABsIjtyAAAAAXNSR0IArs4c6QAAIABJREFUeF7svQl0HNd5JvrVraquru5Go7vBJhaBIEFwJyWKIkWRlGmJjCJbUmw5jiVPEslRFtuT2M7J8nJe8s5MZM15b3Iy2fwUz/g5zot1nOQ5oTyKE0+8xIq10JJoiRR3iqsAkBC2xtrorbqq7n3+760CmiBAAiToiDHrHImN7urqqnvvd//t+/9fw83j5ghcpxEQQmgLeWlN0wRdr/a6M713pd8Mv3Ol894tny/oIL5bHurmfbw7RmChQbpQT3UTpAs1kjevc8OPgBCCzfMhpKQMjlCA1L43z8vNfvqNBNSbknTBpv3mhaaPwFWA9Ec1iOImSH9UQ33zd97VIyCE0Odwg9dFUl7hd2+CdA4Tc/OUf+cjENijs4H0RwVM+p2ZtEV+U5L+O1+ANx/vyiMQgNS48plzOiMENQFuIQBOktSf0y+/C066aZO+Cybh3+MtBCA1Z5Fkl5ivcxiDcK3yGa45X+CSJL0J0jkM+s1T/h2PQABSaw4gnSvAruTtnY+09TVN826U4b8pSW+UmbrB7jMAqT0bSAdmeZ7G2dXZMJzD+4LvNgOoeT0fkHqaprk3ypDeBOmNMlM32H0G4ZfY5STpUPBMi4J/6e9FM4A0ByALkH1LQJRqKr1HR7bmde0QZQGRC5xG9Dr8jN7LAlVN06o3ypDeBOmNMlM32H0GII0TSEcDsKQDsNDf4evgsS6ryo4AyABk3xLY3JFpHttMcN3a98P3Zhk2AqlzowzpTZDeKDN1g90ngXQUqEsHgBoDkAIQ/hs+TvB3qMr6YzUATAGC/qZ/i0VERRwiAVwWXKMA0jVjRX9PP9KAo2la5UYZ0psgvVFm6ga7zxCkDLgsNbBeSUFSZWktuuMzxDXpnBJgiyJEPI6FABeBtHyjDOlNkN4oM3WD3SeBdAxIXgmkAiBakqkB5G6t0r/0qHkASaXfSnvSJJAC3LuCJJ3LMNUDlZsgnctI3Tzn3/UI1IKUwEagm+1ggEHg9AHpcSVgDkxAZxq0bGLcA+olSEslCDOGSgjkqx3AIlBp0bTS1X7/R/29m5L0Rz3iPya/RyAdB+rnIkkZQPRBjefhnStBf+U8lpaquFUX0DN1ODFeKpa2tOr54xecjFf1y+9bGxlc3JTwNUxoedShDhATgHZL8C+BPNwYQkDTOeFGkVSS9CZIf0zW4s3HnGUE5grS4OtSWPyPV9A4WsbGqIVMXIdmEcIZoRflpgQOjZfGMTYh6lwh3GVp1veeVfVjdXWgzPJ5CZs6oHwTpDf40j127Fhk8eLFkfAxstkscjkVmaPXIX80l5t5cWSz0o6i3fqGoZ4t9JRdAaQXcXCLhQL71onEXaM+lvYXwUwGWDpgBP/qBFQBYWp+QfjOIOfVou9D0wxWXp+J9G1dFy3Q/QdgvSK/9yZIF3q2/w2u19nZGU2lUtHZfjqVSklnxtjYzCBNpSRIizcS9Wyhh/lyINUKYCIB4uDKo1gA+5e3sFtnWEy+4O4ykCsBCVMFRwmspA8b5GHSwRn8cc2rDHDuVstVMFP3Jja2LOrbsgplOjVwNs1KN7wJ0oWe7X+D6wkhiHM6K0hHR1U0Ll0bkKu9T/XxTZDOYpNqACMgkbeWPEr787Av9OFeQyBDaCRQFjlwchxwORAjtVdXsRySqhSvMXV4Oq8ORbXqUNX1RIXcS5YY2dEeHe5otavy2rMcN0H6bwCqhf5JAuno6OisIE2n03KXHh2dWZKmBWi5EUh/rNXd2UIwJBA54J0YLBqHz5mLix7PNNjRDl0DMZQmD8MA+srA6bySpKGNKsGqS8AKA75jwRmM+1VyA4O+Ux8VQ9vXmAOLE+RcunSOSkClSdOKC71urtf15mVwX6+bWKjrPrJHRB55BP6j1wiOQJKSNK05AnIagJER9TqTmfnO6fNMJnMTpDPESUmCuiXY3zlVTfXmeYNlUPhFpO2I3WgIKSSRjAEJA+jPS4lJ+i2O5oG+AmAHUpVAS2Alx1KEcXGLni9CsL64JVwPBvKVaqUtyfof2FwvSUfk7aWDvMA3JelCIW4e1/nMN4W1ajFWlR1s1lwM/2/34DvXQqCeGaQX3VBtxsVMd0qfl37cJel0WqA2Du1bnZX6CjeWFAoVUxjM5h6amKbbEd3UGBgakkDKAsZKQEsS6M0DYw5AO2bOA46OA2Wu/qaDQKqDY10sDy4Ej0UjY7pwhqpupFzmYJrGi6uzkYGd66ITdD5J1ptx0nmA65pPFUL7P19FW8rEXaMTaOwdA+IWSp/cjmdXNmiXi59f9qcJpCMjk+vgknMzGcWCmU70Dk8MyN0/9iAFkBjDGBOjQuwdtOJdObPZ5X68qU6LjxdF1hUiGQG0ElmPvgVLZ8gmgJgFFBzFbCAVN2EBNLdkjxIoXx0DRh31t88B7nNknQLWZIF4lP4WbtkTg9AwIgQESVbd9/J3NJt9t6+PV1KKu3uTFnjNALzCBX7vmyLb3oA7+ovoGCpA575Sf6ImSr/zEPZkNU3unFdznDkjrBUrMBmCmX6NoSFgUZhfNcMPBClXN0EKxF5/B9br56otDmf1pumZQohFSYMtqnBuuD5wYoDhZD/H3a0WkjGGZSmg7AGWATgeYBrKecQ54ARzfLAM9JTUfBO+HYcjMZaXoN7axtCYAEquL8BYWRNavyb4BNegcV/4EcscWdFc7XlwZcNVb+JXs6au5Ts3nE365AsimmS4Q2PYcH4cluMqp4JUfQKQfvzaJSkBVIJ0aKjW8aDgt2iRlKSXGzv6nALmP9aOo/9nX6VtvCRaYpamw+MpD2gmjkLSBs7lGF7t5KhwNX+bWyykpWcIaE0CNK/DjlJ9CYgE0lC9PewAA456nwDs0ivuwO12pNRtSADrGlUIxwMV/9Xy0LV3DI078DWzLh4Z794WO/SUps3qAb4WUC30d28YkH5ivzCX57EqGcOm3hGkc2WlCtEkke1Co50rADETpYUAaS43JUkVf2HqIF5DQFi43Pj9WIP0m2eENZ6vbC36WjxfFFRwoU7XoQ0XgPMjDKdzHDFDgc/PGrjV0mGDrFKlxmZiQNEBHt4InB8G9vcARHKguOlhDuRcNecEcvLq2o0KybF+B6W+klSXV2V1bGxVIR1w4Tck9BE7qhUMTe//mU2xN7WbIF2g/UQI7TPfwi1LE9hWctHUl4dGOy/ZIkkLWJpWqlFvARjIK5D+7w/h2QbtmmxSkqK0HmqQWSM5FaNopqOW7fJjzTg60i3Sbw1Xd3Mhmkjx7B/n2NcFdA4D9TbglgE/xaC3m/AthnQBaM+rGCgPYqI0wPd0QNqaew6SCquAegLAsKdsVlKBKcE03aSmwzIBXnJROleGQ+LWYrivw8TGtkA95sw1NP/tj95V/9KNkvj9rpakv/GCSDVwbDUFVnaPB9ssTYQOtKfUhJAUjVvA9zuVJCWb9Pe249mGa3McXQrSeew5AwNAY6NUd28IdWoej3bFU4UQEdfF2oqPO77zlpMgeUeq7blhjtEycD7nw4qbAIGTEtmk0wjwAmC25oEmshbJKRSAbmlKhWPKBFIAp00gR2quD5D3h7SpLElSCsCGdiqFXQou2sbKEs2mBWxoBNIxoM42xU+uiuQ0TX89GkX3u32e3pUg/c09wm5IYKMAbs1zRPNltYPS0ZxUNkfKBlY0QE58Tx7oGQUGKI4WQfk/bsezHRlt/IorapYThBA017WS9KJxoiJatCYuc4Tc3R8bkAqxRwceaSuXcafvo5HrHM8ddnCgm6FAjiDGJfBY1kAuYaJHsm0Vk4gGOknAqygpavnAygHFeKDvkEpsW0pq0nvnTGCQJCg5kwJ1t7FZXaPA1fVabfU3BwcbduH1Oih5HNk4w90rGB5al4Av4DMdXdzCG3WaFpZNutplc92+964C6SN7hL46hlWGh03v9KPBtYBESqm2DTbQWK+C3O0NCrSdYwqstjklSRcQpGFh5+ljVKvSzjZ+7yqQUruHFwFt13UsY+k4Yl3Vw73QlB9vXzfHF/e6SMfUPsUyBthiEpdKepKKer40FUoJV7g0H3WgZRTIFqc8uARSkqQ0KacY0E+SNPD40i82UelADrTGgEZL2anhBMo7oEU04MDJOXB8A//poQTaAlqnpiEfj+Kb2rsUqO8akP7G/xTNi23c1dOL1t6AuN68NCBWW8CtjUqKNiWAkzkF0o4GJUXJGUE7M9mkCwRSmt+wpMf0HXIuY0YgpVjcu0KSDg6KhG/DHiyitLERJQR9Phdq69+zR+jvexD3gfHVDEw2gHnuKMffH3DQkiV3rSltQ+mh9ZW5QvYkAbLoA2cLSiKG2hLdV6EIbM8Db9pA2gQ2OEDeCWxSBvSSTeoCsRQQTwCLLaDVUiR8+hmSpmExJJrIsMguc10MnPTwW3fb2NQajICQAvelujrt2PQx+WyviJ07Cu2v3/dvRyOcy4JbqLmc8Tqf+RuRjFu4wy1jTfcgTDmRgWq7bh1QdpRtsmUpkLWB/iKwKqMmlZwQ4W74UjcwEqi7ZJNmrk3dDUFae8/zHasZQUr1aOfSh0QIYXz2s+BPPXXtQB8UIpEvgMprQnPhLE8jP5d7mOvEU8bLyLj3E5EIW6u48xRC4dhzBtgHBiq+K+PYgd1JgKEpJiCFYCUfT29FATFXDIgMAdBoSWxMAo0FIFsADuvAiA3EkyrMspRe6wqIxESi9UKqcSzYDOj7NKH0Hr2+vwX4QEPN0wnOixPey01N1tHpz/zwy2LduQlsbopUDy1PR07+xZYffb3e+S68uc7bFc/7zNPCii/BBsPF7Z0DiJHdSSEVj+wXC9i8Emj94WAe6FaDvq5Jqbnk0SVJmqadMwWcG4a0ec6PKudCIoryr+3A19rTGhWiu6qDABKsIxqfcIzmM1a0UKls5EWSlAB6ADC2zKEwc2AXU6X1a5bGtSClAcm4cNILCNQ9e/bod939wd3gfG0yYQjLMuWcUSiF0s6e6QZ6yspG9Hwl7eiofR2G0E7mgQGqmRCcE6c1QZ588uB7wBoi4VImjAkssYCMjIVOqbbTr08bg5TMLrC1AfhIM5DWg+K94CiTJ7gErmvay0uWzAzSCxXs0gSYpaOvLY79q7fh/I8yxjqfhXdVC376l558UrDSKnRETdzZP4IGUlXlEbBKVjYDrQ0AN4FkCjjaq3a/zUuUPUoSdFUDMFgAcg6wIqUoZPt6gFweiEZQ+dR78Ow1gpSmNuRI1AJ1PmNwCUjn8+UApFIIXGuoYDpI6T5iCRQWqs5PCFLu8bWMQTDGkEiYMAL9lR7ilVHgG31KmpG6OxOw6LzhkuLqdpP54gArE0CRbFGZUCpDbGgJ7M5wPEkqh9K59jVJ6lEXWJoAHm0FVllT4HQcH+WSJ0MGJGA1fhmQVrErKkCuL+mIjup4e0UKb375jh+Ns+lHCtJPfFEsSsZwFxja3x6EFtK6yLYgj+2GVqUWkUOAAJqIAcd6leqzoQVYT6QCpiQp2aeLE8DZYaUeUcCbHAsLCNKwFGX473zHaiFAel0kKS1udxz+mlswshBqb60k7c0xkUgAmTiHbhqIJ1S+Cv2fBORzvcD3c8rZF1o24Tqgv0ldLfgAaVa0CZ8jP4MNtJME5UC7rQAbgjLY31V8NfgvvAaB9NGlwLYgBYbuwfU5CoT6H352giR8L3D/NnDuzQzSR0jdrWJXJAApESPod4QGpy6CI8ujOPIXW65vvaT5Lrz5CIPJcx94WiTvWITbSh42DJdgFoKQClG/KGS2pgUgqhhJRLJJV7YAuq0m6nC/Gnky8snDR5vz0gZFuCanUf84MEBewCB737LgfPpu7LlGSSqJL8EDzKTuXmncZKX1a1FVr6e6S88lChDjTRibi+p9pUkPQco0vva5lw3xxZc8PHE/8OEtTJowdozBIvEZgLXXBb7WA5wsKKlaC9ZaiUibLsXCzxWAkg8sjSmVOTxq3Bdyc5fgDUoO3tcE3J8BaI+Q3Eyfo1h24bvKwfilV128cBD48AYLn3qYzwpSsknPVrDr4QzYK+NKk5O7NlOvDYGxTBQHPhTDmU9eJ3v1SovtSvNz2c83f2K/ufX2zWsXpXHHYAl1pI4SyMgbToPZkQXasoFzKLC8CKTtjYr2RXmFR3vUrrmpBVjXHNifw8qjez6vpC4xjqggKw2cZcD59HsXFKT0jFej8pIknWvHsEvG8XqDFEVANGJ85QK0W6gF6ddfM8Rf7SXHgot0kuFXd+rYuYpJ4kEyYcI0pXop7dUTBeBvzgMjtFnPIB1DFYZCNcMu0DENpKEUlXmlVM7GBTalgI+2AFmzRrUt+Sg7XK6VPa+7+PpBLgWCyU08tNrAr37gCiCdwK6fagR7lSpFhLtIzQ5R9SEiOnqXxPGDdd/5bN9TTz11zX6E2gVx3UD6H/5ALFu3HO95p4A0MYHCDZCkZzapVFt6YPpbPnfAICEpOVwG7KSyP8gmlSBtVRNBg0vOotBOIdCvaQLyJaB7DIjZcH7hVjx721JqQXJ1R9DHhH6udnxmez3bj0yC9JgQkQ3zbBC0UCAlJ1guh2jeVt7d2sNKYGLJAqRsTQfpX+71kPccuI6PhoyJdU0Mv/2QiWaqu6ADSSkOpwrb78sDf9ut1kjo6Km1N7tmAGmIAlJz8y7QZAO/tBRoD+xO2gQcx0U+z6WT6dtHOb70kiuBOpBzwQ0djTFrTiA9Po5dP7MYbO+wCuvI3yaJGqi+DaayfdfUw08IdK25Ba/+ZvvVOy6nz9OCg/SJPxOphnrcZdhYcW4IjB6GBowASQ91ayuQSQD50GFE7BByFAUu+twwwImgYAGxKHCYHEe+skmJUdQzNpWRT4NF+Yf0fbJryX61bTi/eQ+eXZq6ZpCG0vNy4Aw/m0likroryKP7NpA8ABSuVDGiNjxzNSANvNIXdbHeI/bo9+IROwzByAVAWc8MzM9iYuMClBGZSZLm4SDPGTqkN5aBMrA/vNnEz25nsA0OyzJgU4wkUIHJDv1aH7BvVNmlIVgJygTSQRdYNU2SSgYSgIdbgHtqQiqUXxranWf6gS+84OJkL0ecyjpwjvO09oh9ZF0ZpA88L9adGMOujywBe3EAKPsqM2dFAniTQMuBD5EA0YG+kpLeQqC0OIn/+blNCwPUBQXpL/ypWN/ajJ1dozApvkm5gDIplyu1ltRbymzwfWXwyQyWlPLKEogJjHQkG5QtQjvgwe6pTZdc8QR0uQfTdZmKk6YpEEfZEQOSzLAQIKVxCSXpTGN0pXEj0FIPTAnSk0CmDsAtwDhVEBRCUP0kAvElqWyBFNeOA/p6dY05qU70veOAsZ48ldOYRccGRSJaK0mLQDGJCGyM/khAapvgWQtuXwmWy/GxHSY+sFGRG+KJi+3Vfhf4ag9wgpIlKNSiByClrJaEsklJdaa18BONwAebpmKjtCiKBWV3kjPxv7/o4rUzXPo7Jg1fYjqN0eLBnED6E98U694ax64Pt4G92A/c3QQcHAZ2ZoGvd6uE9MdXKDINgV+2ftPA4xnsWSjv75UW25z1xQeeFtbGevz8yRHEyVkgDWvKBwy8tiRNSwEFJMxiISDSAA4E0jFcjS0tQP8ocCYHsEBPpu+QdF2ZVaSF/oKaqLaU8gwT4I/1S+lb/fhmPLthiUaFiGY9aFEHAKil+cnzgwa4tV7d6eN0pXG7BKQmlZosQCCB/Aq1AZA6PGu+aSBJ5e3McRKkqSfXyLTr9goRKxWQCKVoXocxkYCVimLw+oHUlTxa8srSFPphDprPJUGlNQ18+n5LakgkfhJJE4wWSWCvHs4DX+lRHnsKxQxSuC2h4qEE1ifapuxOKp9SCkIqHAx//zrH37/hSg1OpjNaJniSgY25YE4gScGR1a8sSQmkx4ew6+FlYHt7gPvagX29wLYm4KULQEsCuKdFeaFXNwBH+oEJHzwVw54vv3dhQjRXWmxzXB/AJz4rYokOPN41gkg4H+taAtV2WkF/2kEJkCRZzw2ofD9JojaU/dlZBsplVflt8tCBX94GvN6pJCyRF8aKQGMSaGtQGTBdw7L0RvXjW+cE0sgQYA0ch7NhA0V5ppw8M4CUbmO+Y3WRJCWQymcpgIjdfFUdxi5XlzdQXUkqzkmSBpuLbLQ7HaT0PENAYnwAtgSoqUrDpOqvI0h1B3mXoYPyYLIWmM8lSAixTrMNfcxDKediazvDp+8zkY0rlTFJ7v4ArHSPL40CnzsDdBaAe7LApyl1LaE0NBpQx3VRKHD53ZdOc3z+eVduArSh0yLzGkyUGm3oMsjJYZ8roGceknTb34m1p/LY9YFV0CmndXcb8FoPcG878DqFBznwQDtwehTYkgX254DRopKkz77rQPpFEUtG8fjbIypZuiWjQDgpPXUFqND2pHMGRqdsVXISnSZCgqNI9XSErm56TbbnI1uAP3leqchErD8/ooBMklRmJLlAxEL1k3MAabCo9dNAehwwisBQSEAPQDob22guYJUdqWvV3VqQjlRh1ZsoszpMzOZdnS9Ig3ueUZLSs74ghLGoiIYRD7EqoEUAcT1BOsaVJCWbVKq6KUKnD2vYgVnmMoeUVrinMzgFjoc3m/jY3QyWyWEZBhIxHX5orxLJwQFaKAQX0P5Cu5Me+GQ/8LnnXXTmuExbNJMmXPImEZ1wZwKmxUBFAqjMSu5wAZ3DgbprXl6Sij179K7dj6z80kH/vX/TqVuUQfehDuD0CLC9FTiaU89HLLhzo8DWFgXcgRLEH25D1/ZbsE/TaH+8tmMuC25Ov/CJL4pYgkCaQ4R2NQKSBKkaKxnb7AyTgQJJSiBM2MBwHjh2XqnHmUbAvNj5J6Xujnb1/kunleRd1QSczqndlOxU2tFoAzZNVH9t25Ulae1DHRYi3gc0U8riI0Bv8Nn0+Oh8x2oSpMfzsjJIGHdFT7VsLbJsNyrAWQLVUaA0PV5JmStzVHVJckqVeGbHkdCXA4lKBfXCgRE291xokN599wd388k4KYeddjAw7KKFXJ9ZC0bGlLVyaest5V1YtBs7HDxjwqVVfr4k09l+eaeJ99/K5GaekPaqqfwak64JjnLBh+tyyUz6/AsuXj3NZbyddnU9ZOlTyAXArTtstDWZcsPv6nZx9I0ycqMc2QaGfM7Chzcx/OoMcdKJCbHYtrHFc9DuVDk70+/jT47p+N4wk0LhvjbgMIGUSDcUy80rFfhArypA8OX7gGVxSrLAcdvGwWvpPTPfhTcrYGtBSieRzdHRqEImJAWJOE0Gv3T4BFXgCHQHO4FhskkD2kk6SN6ddNAHAPzQJuVEIhIDHVJVHlYqEsVcwzzTt4dR/fTd8wNpsMC1fwIWXyhjWd7D2d+rQxjCma89Go7RJEiPjiOVqZ+KOZwrI6ZXoDWaKHMBEa8DlcyvLlJ1kWTCRgBSUncnbdJAWmK2+GsofZ/Fs1orHolEgUS5gljJmdogCJwLLUkf2bNH/5V7fnr3Ol2szY9w8fRzDHtPAqk2KunH4SUt+CkT3A3yQoNYo553YRBYJXbVAiBVtSXJ8FsP6VjTpDK/lb1Km7iPIhG1GcOzBzi+uk/ZnXbSnMywIXT7DofTbsMcdihci00bLRlNOHmsDN0ESiUTzoCFj+3y8dHdHBED3LK0lzMZ6yglrXsVb6uvGes5ry1Gx1HI+3i9V8d/OQp0OwztaWBNRhEyOgNJemBAlSH9/+4H2pUXgBpO5ZmJH0QiOHM1da8WDKQf+KKIrY7i8bMDiNByJNB0NKk4aGsW6BqY8sxSycaeYeDE+aDPB7FCAhdKWAYjXOkhZewjm4GXTiq1h1D+4U3A3x9QjqdVjUCJSPbDIK5h9WN349kdV3AchcCcvuBJLXwxj2UdSfQ9rhL/5TjPSZ24+CQJsDAEU85D1zVoPoP5jlexm/yoGzVRiVGaVM3BkxAMqJwF3HuVp/ayNmmnEFEPiOTyMBwHEdNApMigGxR6rkBQswwCJvU86tYRLbtVYzmLFIn/sVDqLoF0fOVP7zaEv/Y/tjCxw+I4fBr48+dMnM27SGYd8JgJN2PI0vNU24g27zDMoo86MKS9yuA0WzBHPBRyDj6+y8JHtigNK8wstQyGZ/Zy7DngIkkgMBh8KsRbe5DTsiMBs88BK7jSwaj2AIZCv4V71wGf+hBHOkmaHsM33+B8/9vey8/8VuKo64qdrovbZ5tvn5hLeR/Pdel4+iQw6jM80KFCg0S4CSXpsw9A2uOTOzaFi0x8JxrVTs93LV3N4pvxNwikK0ndJZBS5QJSd5uUi5omhMBKxrznAgfPqfeoOrnibAWOAAuIB/YovSe1I0o38oGP3AEcvEDuc2WP3rMKeO4wlXAEzlDoxVIS++wwqk/snDtIAwBOqozhwwWhkOnPOtfxouuplSOEdmYEddEMjIEhcjaWtHGDRdJW1G1wUfaSF4O09gfJP7JINX6aEajHhEiMDmAxfYfUWBaFRtF2ks7TO9n8aby4orkg3BV6ohLhqN4JjNSCdI8Q+p2A2a5p8253TyB1Nvz0bs/11xZ9iHU2w683AQ0uxzdeYfj8NwCW9hCLu3CSFlgDMY8gQyWkneZJOPo+zJwHJrmADF6Z4+FNJn55J5NrJzzIafjMKxzPHXBh2QzlVgt2Zxle0oRBQcyAtzcJ0sDeGhuw0JFk+I2PAOuXcjCD4ZUzHH/3vItimfNFi/SXv/yb8WPFcW8309m6WufV9EVAeCd1u2fYxxdP6vhaD5MbziPrVME0CsX8E4E0LJtP65t0dnjfq6uzjv+bgZTUXXIcnepDhFSQEKQEKIqDkvQkxxB5YCn2NWmgBSqwrGdD7noTaMsAXYFTKHygbR1Khf7CS8ATO5Tae6QHiNtK9aWJpO/oAtWPbcKzOzZcPgSj8EOtLZWUnAkItZ/PY2AvAfw5IerLOchIZSwOMQREEiV4dgzloNDhJZenSuvDIxArMijMBtL/1S3S9RZkfQEJUg1anQBFYQWVmlBXAAAgAElEQVT9Haq1n7cmbsn/EMKfrcTPjuiIHDOQ2lZFrhakx46JiL8IqdhVUAUlSNf+9G6P+2s1xgSptVRm8wMNDB9NAcMDHF/4J4bvnYCUqizG4WUs+EQTDJ7coZ1Y18EC55IE6WYTv3z37CAlB5HTZsE+U0J5ZQLW+TJcksR9DtwMk3ZvecCE6Vj41Ad87N7EFRc4x/DMvzjoyXHYFqMYF6+ztJef+d3E0YkJd7fn+OtlWRc6mWJHk4v10lXglDiODvh4+oSO1wtMxnZJI/9fDwGrCKQ+l8wnOrim/WtDg0V11OZ1zFUyXPGiUt018fipwcC7mwqI8kw5hk70KCBJ6Vl7BCAlx08ioyQiEe73n1cxLrIh6MjEgU/uVLFTCrl84XuqiPKmNhp0ZfPKfpYGnN+5D/84IVBINsK3Ab1xll6h00E6U0J2aAfOQeWVtuN09Zlsy9MTSOtaYJMmgKEyIgkOz45PgXQM0FKAGAZA5Bk2As3PgJPvbTYH0j+fRyoEaSQKcdCv2iOGVgdNY20uH1+pR8pnozCe1krrnizHjsUBnmOwenXXvpOZo2YUg1uCjtcSpEuRigj4a+rmlx3zpBDs4HHvHq/q30ogpXEgaVPmHEnG8DstwErGcfgcw+e+pqMzUIGpsYvTYCGW0NXgBOR4PuCAj7lXBVJSl+2eErwxoDRs4UNbgY89wKX2NeYwfHWvh33HXOkFDqmJnMNvSIrnv/TbydO9o2JpxPd36fDqSPhZ5PEjxNaEhS4Fg7JXv9cNPH1Gx6kCw3c/xNFh+TLrhiKMLozeiK6/kL6KPOcFAylJ0nobj524AIueiRKyO1qUY2gkrxhEch58oCWtCPJhYeuQlWQHYRvynpEBTsR5n5wMQY3V+28FtiwD/n6fqm8U4j0M1ZCmdHsrTv3uA3gx7AVDpT3e+wiiPX0Qm5ulY+YSR4zClsaJCdTX18eam5svOm+61J02SZdIzvBzUplJEx+dQNQoghGdgCRkQYdpFIq+bcTLyTT4oh+2iv+tN6pLs1GWXJ8w3v5gOwpDQXtAyj+YbYf85/NIpuuRMSsQ34/D/n8j+Y0f9ewzi2DyId+Lvp8bff9sllLfsbzGL7rJkw6gvea46eWamU9wuMtS6A/V2xCkRK+9Gk7vx46X23qr+vssrUbRDkiuBZdhZxp4grJSOMf3DjJ8/utA0fSQTLlwYyacjDU5oRSmmRdIz5VQ7ojB7iyBl4F8r4mt7SZ+/SOupIw6YPjWQY5v7HOgU7ZM6AGWiR4cOoyuDe2x7z71i0rV7x4T6Yjr3W4zsUIILrvrGQRW6Z6e4hxPnxdSafN5YM9JHw+vBxoiEC4XY64WeXO4D2c3bNCqV5R2M5ywYCAlSbrKxmMnA5BKWzQgMSjXu9opqXXA5g7l5BmtKfRP80mk+i0dALOBA+RUKgdk5oAKSOfI8Q0cTXRd+pM4nDpDdctyHHpoCQ6tWDGpwk7aV/uFMJcC0QHAqSW7h9I0VCkvCGFTq8suoLBL02oYxuoRaiSr/PtymS7UUyaXgzloIZLSoKEOqBSgF5yyqUdtryUuqaByKf/Ja9X2bFK0CFP3GTOGV+jF3jvb4xOngOq9M8+s9mwP6rIWMq4F7T9FJ9a/p2L0/1zFzo3Z0PcBi3ZxDHzbdDP/aDgdv+8kDg1yxD0BvlHDmB2Bl7YxGMZpa0GqJ1Bt1+bJOxVC+8RbaLrgVO/imtZq8IudbVROxdYZfr5Rx+6Ej7FRjr95nuG5fUAs68CKcWmvkhfYzM0dpOU2C/EzJUlFKvbpaICBT/00sG09h8mY5H7/7V4HuRxHwmIynCMPSujwRLkhoR+qbx85/mePLrloMyQNqG8Ut+hudbOpay2cc9mBXKrA06VqwPUikHqeC592Q5M5jq+9FTWMI9dSykeusatB9kzfeeRPhd2WweMSpKSmhkCqOVmyREzgzpVATw7o6lXsIXImkdRFVtH+nDyw79yU9JWXCDYwGihSjeW/qmi5v64FnR+8Fa81Wqh6BrZ43F+j67rQBE4tyWJ/TYxKe6FTWK0eIitWEM18ymlTCzZS33YWi1nHiNfzEfR8oGX+Sb2hFGU5aOUITNQDLA+twmQoz5gQ4ARSHtD+/vhAdVk2LloM2UU3oFrpKEeAgSVRDK9pxsSKKYqgpDJ+tQ/J5QbSX4lOZI/pWPTfinVvuRq0CQbjkOnV3yuM3Hm3av5xrLp+dyk6ukI3htdrmCgAvMVAaSiO8V2Bo6gWpAEjavRqwgWkuTy/Fst6hb/N93gm5FkrdZZLJ9FSi+E32nS0wcX5HPC5r5nY3+MjlVU1dDi5notzsUlVxXsnB3jDMTxxv49Hd3OJoVyZ4Usvejh53kVS5kdOZYV7Pry4pZ1esTT+xlOPXb6IOoW1uvqqK+qjuANcZDiHRn4TCdZwUQZ2J61vxuA7wuguc31/+2IMXku6YgidBQXpLfV4/FQvyEsu6xRJ13kQFw1/kIj2RHQgG/LwmaBTVhLYsUkRpb084OvAgU5lk8ogdo0dG6YHBSlvfR+8tfLG0si5voal61eWCtiqaVw6vsPNTgMrMNN9c3HcjDhOtZBIRLroZ145hWjRAR+/DZXZslO+KYTVX0VHJSK17q5fn0fuJcXbwlYVRRMGAq+1V4BpJKD7BfB0FZWgQ5v2Oz+oLmutF816UCeEcEobXYzimoYslDmxiuHo3YtCfzjwT53Fumw0nv4/EqUVazRW+JgTpRR5PJkoLe/g2vhjni3ZLkyo75DE5Q5EVkeBgJhMID+Tuks9RMdPYWzLNSQxPylE9NQxd8OYyzbqnJM/JQAKlzFNqjn0UJbho42AzTleOcHwha/r6PUcJLOu3Lild3cWx9E/HnTBOEO+38LudcCvfojLFMgyZ/j6cY5vH3RhgcOgLAy5m0tGGjdN9DXX66//+Wfsd6hqYmeniC5bJpfeZYuzHX270JiIGpuSlmhhQovLVDW5QLlkulHZGE/TBqs8cuiWRXj7cpTP+QrGhQdpDyxmqPIYFJgmkK1uUR7egWFgx7qgZZ0HvNENJNtVLulm6kcXNF8iSSnVXWp7Z6vrhEAluzMZRf7ONXjz0+/Fyb5RNLsetroub56ei0iDQWq3zVwVw+DUsFIfgI4jiUSke2AA2sQE9FwU7o4ls7fC+4MxkeYGllTjODbXAlSkNls56JoGjTHSipXWMmwiYmjQCST1CZQXKW2G/f5Bd+miGG8mXZ7kqG4Y0gse0SEo6Ml18NVxHL0zLjUAeXz3QqnOMI30U1FnVYvNyr9ajJ//fKzS0s28+qdGIidjkQgRF2h8JUj1CHjKRHmxDacI2a4jvywomFYrSYtF6W0bW6+W91UfJEV+94hIH6/69xR9r9UG01hI3CYJWAGSP8xyeaKNYSs1aXI4vvYSw1eeB9ykh5/diRlB+ld7Ob7yLYY1WRO//YiPNa1BSKUP+OvXPTglX1YoDJM/yVNsaMzf1K6d2bQt/vKDKzWHNJ2hEpoYR9rnqLIo9IYIurRpISgykxaPo81jjuHXWV3oRzIZ8e4wud+uaco57YNNlFwcX9JkHrseLRWvD0iJBWKptDTabDavUrtozwjQmlFVFOxm4FgRyJ8DUj6wbpXi9YZayeEuIB0PSqoEaW2aBu+uFTjyvltwKLEEhubiLp/zFZp2sZVADKR4jApqK4svNENCk991uah6vC8et4+ULAwOngInkXP3alkr96qM+9qVTHZrH+UL5MC07MUmhTsh23DqEwIiACmjbvN/8Fpp6ZJMpJFU3TA+TI4zOgismg6+XC8f395gF8cBrR4QL44gEdGQ+rxebH3D8peDadW00PK/X0qcSgj4FLCWD8PhRQy4yQiqEcK7rcBXC1LKujlSkEMOAmmyjPyyZZOla68KqAGZw/jBKLYdG3Vv++YQ10ndlQCSE63KdNA62VDP8MkOIMu43NCf/hpDY4bj1z6oNu/wIPPoa99hsJMcD2wlk4jJhIy/fJOjm+xO2pSks9GXTiQKkWxbZeL9dxoiamJ8RbP5SqGAnB/FUp1hZFEM/YHTMNFfwFKjgpFsVuujOcwV0SiAxREX52u9skR4aR+oLInq5nrPc4siFj3cmgSZB3PNWJrXeC4sSOvw+Ile5cglkFK35g1LFdjCKlGMuI4tgJ8Hvr8XWJZVqnE6UAeJkE81aKi+EcWl5XwK+GuX4Ox9GyYOrKuvK5d0bPJ9f70uNCt08YYA5D5DY5rislwGy3mYpFozLDIhwuW0KYiSo/VHIv6+TMZ+p6sLlpOAuXrRFD1vXqMZnEwTPEDpkDloFPrLZODncgqsXhRRVgdGaWtGAhVKm2WY0P/kQLRtkW02ktSUceQagNJrV4fYksDxpXbg7Z2YwFG/Lu5UlSL9fbOSjBoG314WBZc2+AjgCIiUCdfyUDItcFaB5kbhx21UR4tFPRuPjy0L8lpfeEEYqzcjldPAnDJYNgv6LKwvPa9hCMCpl8to0YG7jhfcZmKKUWmI/Xng+TEuqZwWgVTqocrPQBrTw20MH2ohIKsSJzOFKAmoZGYOc4ZnjnO80cMhc8sJnHTHtDeXfazM6vjAFibXHzksJee70RRcYyNVvfL9dDR64SJfxJNPss985rPNmoUUpUVVWWlkSSzWNysN88knGT77lNC0OacTzmscw5MXFKRL6vHYkW5EKRZKICVdfesawKXBNoD4CqXqkvSkwSRqILnImaVoW5RXSiUdabKktuIBTWkM33cbXv0P2/DOoIO2/Di2C4/LAP6kM7ymCxcZxGG4J2lzcFoNMxzlknJiRAwmmGF+qzGl0V2R91aGTWYK2cx1hOUuDMRBCQC6JNPI7YakqldAlGlg1IHaJJBOIMIY9M8dd5ek6thiBVC1NOXrALAeILam8NaSaADSInDGhZ13kQ5FvyFvH0Iz4dcZ8CguKiIQloCTr4BFBLhuwdN8JWAjdSiEICVm1DBQNzqAaL8Og1Uwur1VciTkMRuHeLq3OzidCP1bOMcaTYNxsuDK7CaDA9GgxtXf9nL0kBlDnnkanWBDLjkcSYPh0+sZ1tiUJzoFVOl4JH+HzfCdPgp1qNZq0oVD0pYKB9DvUBWHRoZ71qiGXrKggGIQYhX1oNBl9YRqJILjhoFD2jQv/hkhrBUqiyksfD/Xqb8u5y0YSJ/4sojWu3j8+HlEKVGb1FwiJVCOaKIdsLJAgTJdyLURMI7CLGXKKqK4KUlPGkxSbxIxTLx3Aw7sasapxnY05AvY7nHeovGpUqAhSOn3yNSh3XX/SSYJz2uWcVn0yjYpM1+pvbQRyCTivC7PoaAtObAW1Zv9ySheicUwuWuSC/7UEGLWIrjzpcqRh/POR1AXz8EjjzXFRkWO8jyh+Ytgl4tg5BAqxeEsAyKlEoynT7u32AZvNEjdDWJWOrVNoOGiinoR8C1JnFruT8VNBxkiI17VNkWECPogQCpRIiP1qGpVzYxEeKSCysAEIvV1qBLfPe6hMp4EOZzLrYroEWbRSOJFj4+4XcDgdDs9JHtMK/MSMraIpxwtlXDrDyt33qZpUzWVQpBS9ZLeIvBGrw7Xp8r2HOepDpHFYBLBNtxPPXIscWxoMPDxNUTu4DK+ThrXgTzDXx3jGC1xWaFefieIpRNgW+Gjo9WSzZmKDkfGZrI+FsXe6QhBOrX5YEKP4pAJnFgIU+d6oHRhQcrx+PFORGUIhgN3bgaytwLOMJA/EwxooL/QjkilPXuHAS+o2hDEQZ0Vrd7px3/SeCNpjZl+MbHJ14y1HHwy3BqS7gloBEADHvXOQpmb2H8SKBQYimWgOQssaSSnE0cqriR0wWFIWIqqxakCNwNSScXTNhk/1VBvHNBqYoTkpT01BGv1IrmY5+RIIZvFL6JhQwEFchpNGKP68nTaI5W3CCS0ODSSeHYcXC9Bj8dg/Omb7i0xi2Xl5mHoEpghQAms5HHdGMPpVXVTIM1VYOY9QuR0M1rSp6VFKiIREecojTowbQvkQXPtKspEIWyrl890UXzw1XGRcQXqzQn0X86ZVrsYKUzhOFiuCWzxBRrCzTc851zJxekicLBfR0+BoUHnsPIOSv2kNlF81MQA5ZyaTJINQtOImIIu59jWYshCY4dzXLZQpHinZM3TQX4MauhVcNHoOIFAZkhlY7CShgQqaWTLMsCWJcC6VvL5XnLQJjWoaZX90WiUWiG+qzq0LzhIj55G1IoB2V0qKyB/FHDGVDw0PMhMHBhRHl+qp0q9Iz0OvrIFbz+4CftX1p3Ns9SKW92qv9HnWpzc2/RdVReJarlyWZYlYfmqU7SifSoqmgOc7AE6+01Z3YEIFa1NwCpqIqtzUAMEqUIZBGtTThiBlFR02lw0IcqRmH4kaeJI6OkjydEDRMlbm81Ke/Wyk0ggzfdg2XYLMiRCai5d3svBL8VRRz9DZL/6CCpuErZegfnXp90mTxONLKILkqQSpBSGIbWU0vF0iB0xnFlsTqmgI1XHLEdD5T6Un1OGpFZVklTnKEqQcrixNKp8FOVIGvo4UKgldlBe7dg4FkcsCDGEgdkkaTiPgaq7uFrFNt/Hkulxd5oP0pKe6QSO5VXZzkTJhdNbhFv2oSOgA7o+bOrvEjfRT/1Dgk1e1f5UZHaaLVJX5R4v1WNyWTN5veyYI4uDyTaILgdV0JeefIuhoTEh/82XuQxKt2Ys/PwWlQM6HaxCwLd0dOoV7EO9rEd12Qyk6yE1Z7rmwoK0gscv1CHauA0YOwy0jil1V44sAYl6UFJBayrJSfmlVNKTih43YWjTKhz4rQfR2ZN3llZK1qaKxymbUKUYBRPjcYZsUklF6QqeZQgpa3+0SBXKTXT2MozlSd3h2LHJl7sqSXFGcZ8gmGrbuiwfSkdAMRQaE0OWqb9ZZ+FsOFmkxq5+L6LZRohmlfs5ozePQDrej1X1AoNrGcokTXV9hI1pGc20ENfKkOyIugicqIkY02A+X0G654LfpDFd1yMBn4FCMHRTlGsGiG1xnLvFRKUIx4hbljcyAWNCg2lINVedW3arTDcjygYOQMo4Cv0OzMYIqhUONx6XXexFbbI52WEDo2gsV2Ek6sFrQTobp5mkpxDYJQTIoJh08oSvqZTIf35dJhVgHfEQB0oojxJJT4GTtC2qwptN6WhJM+no6xvm6LQM5GKmsldDlTb8N9CKTZejMe8gWfaxZqWJjiUqX/XoOQfn+11ZL0kuEc5hJ0ykGm2MuQzf6zLRFOf47XuVGjz9oPt6ZRjlY3k/1xbTDx965rPnF7qO7nzBvXAgfVJEm9/vPz5k6dHubwC6C9y2UiXEhkXIiF1CybcEFJm6ZqB0zyYceHQT3rIbkZjIY7vgfKkIyejTQJpNEtmZOnsrdM7oFJJsZo58kfiWwAv7TfQMMCTjHNs2KslLB5XpOD3KcC6v48Prpoj/FzEzGTjTRE+0Tv9BHBiorYCQA6LFLnjt7ZemdhFIJ85jNeW23mWhL5wUIzuqj43ZqYgV9UnHbPLhFBKIGw4iLzlIO9yLOROITJSMKBHyzQgEqbq0UKs+sCNafTsdi1SUxSlrD+vlyGQbTvmer7lMr5qkMshDVKvCMiJ5CdJ6VP1ymWdsO0/rt1G1Z/Qopnt6DIsjGnTyFCUsBdKZHEc1dqnhlPAA17AsfL5QvZAazw9bGj72PHC+TK0hXGSoIFVQl0huvgRSV2VLNTaoshW0b9L05IY5CpzhXNxEXqfao5P7vPyppqKD7KijTFiToaPNxNLFDC7Tcd4BOg+WLmLY0qZNF6bO1Ee6GUoJU9qo/+NR5b+oPei+vtoN/BWlQS6DvyaNrhV1eH1XM4YXumXkXMG6oCBNrcBjR47ANmyVcrahTS1+sjuJZE9qJrGQNA3uxuXeiZ/9ifyh5fUZPubhDpfztRC1mfBTZRhDAv2JM8C6diYJDibjSMZI4ak5GDBGLQkoPktkClfH6yeAgRqQ0tqlco8vduug9LeNLVPmDV1pJvq00ODqOj/dkJD26mQH8TNnhOWnEJlur4YgJbtP8zDxYDuGZAgmC7hlpIerFTMhon7WQHnUd+oM24q8NuxlUWdI+7rqgRXLfqTiWpZgUuvVSN3dlkRn2oQjTdCIdGwyx3Vry7XJwTBMU0pWz3U1B0KkqpGx0RjMhKhwa8IvW9m4ZE03A9UDo4gXGTKU1haO5Ewgpc/CJHZ6feAAjLVr8aCmoW2mxUYA+u+HgS+dANYYDlp4WWmvQZsGOc5BDyDSlih5n5u0KwJunksvLcW6RxjDOW7KCIBV8tHmeDK8QiEbkpRkKjVnyWzhYNRmzQXOE0inG8bgcFwL54dNFMo+HrjHwid31zZzV09B9/WVTuD39qrX6xqAnW28uizN3lqTxsH3ZLWJuYJroc5bOJB+WURTPh471gWbBl3mhTYocJIHlcDpVCFas+j9qe147bGdGO4eRkehgjuF4PW14Ajd5Q2WD9PkGC0zOL6OwyfVddL1QEcrk3V946bKsKf3KTteqtec2gqQq17H5/9Suew3beTYuNLHvxzTYdnUp0RJdfIYhs2DZgNpONi6LgoJSz8QieBk6AmUxIU+2CMG2IkXUX70Uc2vBSnhKQGM3BbBOGuElh9BOhaDNuRUDDsiqjazY74G89C416BHL4636aYhKhXPKEu5aGCzhUGdjOoqQFKWcqXLLvTJrS0A7+TiqNKadWEYfKLqQKv3LCcRgdOYwPhxwOwdQtIyYdUCVIKcqkWk0H/vZeKkBNKOZdWHDMtYoutssrLG5FjRCx34TjfwR/s46uGgVWakT4GBwiYN5A8IJt9IkmebK5ASZ95isvrC1jWWbFlx9ryHAycdlKniIvcVSE2guUWBTW8xpcp8/mABbDIPVP1g0bHQmTORjANPvM/AznUzZLTIAu1cfPksw+/vg0YChjQCuvqOVmB7G8ZvMd3DG1zzravNaLka4C4oSJM+HjsRgJSSvKXjoKwkW2MGIz9xG9741IN4++0+tLga7qo6vJFKioTii1RR+g45ctKWH2SzB2R9MBw8qaN3mEnHHgGsMcWxtIVJ+gyBmZwHZdKjGRGvVZyHdujnnwdeeBVYuQP48E7V5kIWLgvCPRQ0l/TBSzfWS8aUnFgDJXHu//4n/fm/+OSUt5dCNkcGEN3YhNILAjqpuyRJpd+1CkSjGNsSwdiQiQbKfaqLwOUCfs6sNjBPi75V1erTllGl/qwUUyCZqsQimQceOZ7ELbpRsg34ritJ3sJzwcrUvW/ycKUU9QDNgatrnqdFDMPLMnOIQpKmkH4Vj8jLjo8EpbhdUsWhAvAoRKQefTUgDddJrQ1uDA9XHwQXbXQHVDCMLM1aj1rojifn0ZcOA984ydFulpDhygvLfF1usKH6zpIGzBqQptIMWzfYcj1IM8UFzo1x7NtbmMxmIVWWQm3ZRhN+jCHX6YA7HDJlRUpPEz1jlty0H91l4INbdclSuuhQ3ROE63POXVf7ux5L+08BSOXzBMW4qV7azjaIu1qRSxl48+eWS47udfcELxhIP/NNYfFePH6mCzY5iMjjSrZn1ER5yzL32K/c+86h+vplVt+Et8UXjILcoRYrJ8z3GZIxjqYkYWxmpxA5mcgJdLRLx/A4k7l7tAlsXUNgDb224U6tw9R9KU3JKygrENLiDLti1cwSzRmpydKVH7TYm45O5cDyxdGzBfHaOW/gkJsdFCYuUEH0Zx/V/KCygbmxSStOl6ThtTQfhY0pCMODG6UgITUZMpHWPESp0HrEqHDHg6YLg0oFCt0wBHVV1g0IzzOQ1V3HhjnpLnNNaBWXCjK4ch4rGgWzVPN5S9i+JDfAFQRSqqT5jo9oQYPeoMtEcikxZ6qVEhPwd6QwELAK9b4+mM3NUsmuddWxwUFnt65jdWjn0xjL6n4kxYKMp/DZaQ7OjAF/9Bq1rnSxTi8i5vtgui4TsmnNGHFDlk1xxqgNBfWMYchmTbl5ZrMGesgxVgLOvZSfSjkLfYjBTcgOB7JTG8NA3kL/qI6taxg++YAJ8mlM9zUyEDhdQVRR7klsa1/tMfGfD6gMGwoJbaCid2OQJUqJ+N+cAH5yOcTqNLqXRPHGg8um/BVXIymv9J2FBekFPH7mHZnUAF+Dv7YVbz12Nw5vX4/i8X73Nt9hG5mmBU0hptQeGg0awFSCy0FxZ2EJhXQ+EpbnRxj2vmlKD3E2xbFl3ZRTiBYEhfRf7dOxa5lq/ES/IbvABpNYOzDSd+ADw0UF0ul2qWFAdPdX+GtHx7TRojeRtq3vv8Abu50JrIjbyG7M4vx7boc3ZqL8UylttBakgSCVGmnJhZb3YLfbGL5tCUoElV6OBuYjekF48YxlOD48jWBW9FxGcStfg/ybBGydEJ5q6xUcpO8rYSuI3RWtAbDMr/Qga3xxE0WnAtMywF0B/zXfNR60+UikYomKTGm++Kj34bZmMNysQCmr8Qf/yhS58Oxj3YXVi2LWXSZ4nVz8wfhSNQPGggDLDLy+vb3A0/s4nIKDNawk58W2dCktuePKNCpqlZhMMzQ3BpUAGyhrQ4db8HFqb14VA5h+BJSksZKJzhETHY0MH3/AxLo21dLiosOn6mwkOH3uUdiA6mvTFsfgP9Nl8v+yn5nkVGokjyEFtw1gNPzNoJTS3S3AHS1wW6Peqc0Z4wdbriKl8UoApc8XBKREpXvwz2F2RPBzPziNutWt6N95a2XfJ+6L9p4dxFLH87d6jrZoko1Qc2e08xGpoSnJZLNYcgEYzL+0zErQUa1ItkoQytl70JS2aC1IyWH0ejdQ0E3s7uCBjVrjEaqhENJtSEdS0MOD7J9agBoGE/mCI14+mkfPQNmLRs0T9RHz0C8/nJ0ISfTfPQn7776Plbe3Qtt5O8bNJrxD+KhVd0NqgedCGxNI0o/GOIoroxiL1qHO8WEPMtgNnAiUJhzNY5YgEh3doCwYBOLjGi6EYUJMFgYigLqyvtFF882R0rAAACAASURBVEgS7VQe8UIVJjOoLZ83keCGJwyIw8KzvwO3+b9G7DcoXjtdklJoZhkR8R0Ul6UuKt0yCc6zZ6H/oA8d8agbWdnkmnHLuiXGvEYhWPCo6tapQZIu1aqa+EwwFbJB0wngbw9yNPISljJHVaVnpI4GvgKLobHFlBU6kCYHhI6RLgc9R0sXSVLaHWgvKPgmOnOWXDtP3Gdg121hrd+LocAEBQBcGm2NWP7ECGOMCZejUKry3i93G+nPH9UX03VIe6M10UiOhbJq1pQrAW1JFWslgbGlBbirES8/vlo7PBfQzfecawZpUFWPJpB9+xCWnO2pRj/9U5FzxzqLGU+LbteERtEo+TuzgZQ6qXUPAE1UF6lVRbKTli+9uJLK5+iqX4ys0OCj7Ok43Q3860sMHZQ5keTYequP7hzw+gUdO9czdGT4JCllUq+WNxG4/5VkQ77AkE2rSaaDzjUYE47vYv/JvDh6rsQtk11IJ/Uf/NKDzTnq4nBGIOIPSa+urJP75JOCHWrE3XeuhHvHBuQrGoaYg0WGBnaRLycCjBSRIinn+9CqgghBMJbE4UdssLgg8xNaoLHOdy4nz5/wYHQVJXcA3bYf3RurRn9j3H6bC/DXbS/2ouU2/deq9kYV0YvnvwIsTqKaqIAxDXmkUEEXsGyZkp5nz1I7hWJ6uBzf4XG0kKpombjQvqjaFbF4Om2zpqimZTxBT8CphJFUY0kFnslvTmM9UAK+eADYe9rFSr2MLHNkVjxJUpLIRHtO2gYSTSaGe13kc54k5/vyf2o+PV9HT95C3mF4eCvDR+7WEZMNiS45hBDcl4XBOHRJMTUY8Z0rRZcPTFRZn2ZUuv74VN3tz53C2s3UeZ4DncOqQiXV1KLLEjilczSoGELhnPcvw/d/YaV28Kon7TJfXAiQGj09MKOtMMLyk2f7nQ35orGTqeU2eVwOpERwIKeJ4zC0NnK0ZINSF0GfmCRR+Sj9iJgkzJSu9zcPA//wDwwr13Ek24CGFPD+O6byUsMfrjV+iedLdgVJb2n3WBenspHkOXuhJF4+PEoq1UimwXq99weLO596SuOUW5gYQnT1Itls6aIMkf/2iug4ehqrf/796K54YF15xFbUoRgS9kJSQm4caVJhCwaseqAyIlDnMpimDrEkgsLiGFwixl8Ns1s60AAMOTD7K7K8Lc7ZfnRf3I3+ynD07bd0L6pFwb8bc5v+uGS/To4tCrqS51duUAL+0hTKpQEkMjGMR+rgUJLAIIBFHGIAA/jcV+vvWtaqr1/dYkJw8OM9bvVsr7v///rF2Nujo9U2jYmWdJQ1MsopN6GFRiC1eqCHnKn6Hi14alv59D6gd8DBpngZqRixwphs2DXJKiNHkIwU+PAlLZBhoBRDzxjDpnbgl+430Z6dSbXlVHjYJ9WWe5zAKQ1OwZjnOGI4X+W9vo8LpZFoLyW6f3yvuO+541i7mcJzlHbJZH8XdI2qetJLA8cjraNxD2hPAfe/W0EqS0uMIbEsJWvDTvJa/+GVsftbG2OroqauhUWvryRJCaS0MinVjJxB5EpvbwHaKaFX9+XkTDKFYMrJk2UsALz2JrCGCj/Fg07MNZUZJoEabKwETroOdRGvDb5TNkzvcEm8dmgMgwW/HLfNo/WZytFf3NVeoZq07wWipArOyDQSQvvSESx7+U2sDUH65hCa0jZK7SbynFTUgBGU85D2A82CQJQTqNMYiECjQ1DJXIhEFK7svqDDS+jwI9Q2LDhIAl92t6aFw2GcdxAjOmFnxI++EXMjOwoY+FbEb3pIsy58N1Zp+kA1cfzbznjzHxr15/IVaLF6+IujKGkFaNUy6qGhQIwoCgrHOXihKluK3va1l90VLx7jRksDo/kSfeNctC5mr/3hJ8zT2hC0d7RycmIArRFLNK9ImxkmuKxiIIUe2XxhQa8ZSmXSOf9yGnhmH0eMu9hE5T/D6hySCchlQjcZBcOOiXM5Cy0NwC/tNrGlYwbJGdidnPu+63DKN6dokWRv+UIbzVf5gFd1ewzu9fFUmsqnUgzU+Hq3f9+fvqGt6BxlWBWkUpIq3mKr/GbaHwbLSpLKtp4E0pX4/i8se5dI0qD9Aa2vKiU2O13glBxcS5H7sz092yuO2Lx+ZZKvWJLUfIer2PIMTgTp9aPuVEHDJZKkpI0QKMmTe/92l7p3Tx4GI6q9KfttUB8OuZ/OcN3aWlE00TLDhqvSoLVJivTVqu/zlw+NoeudkojbxsmkZb0xaXf2wTaawai05qxczh82Cv7YV3B7Mob6+9+DHHkJ3xxDE6OyJxq8NQkMx3yQe4L1l5EmCRY+0ARDHWXM+eTtplQyEjZTgCTSryAvbMyEF2Pwkzr8qAU/5kKQjXkRYEn8kkHswHgnKE5wwVQgvdsz+v/Vcpp2V/Se78W8xo0a69zH/NYvFOoOFQR4awpFPgFh1IGVh9FAnIp8FZVIFJy5aImY2Fh1kXj+AMfrp5XPQHLhfY4da42hj9yt79PqMVaaAPMFRD6PTNovL05E0FgXNZoE50YtWC3y5sl+iJfaq2QHfvUAx9/u87Eh62FVxlVj4nGMlBgO91hyQ/+lXQzv36Jq917kFyI70gSvVFyfnEKklYZ2pyf8cqmq9eYdvz8mqp1FI8UMVFvjVqRsW246ZrKlhUKxkZum9vUeC3/0Oqm2DDvbgdZE0FCMASeoe1qQRveuAymNFbWXrxtHPFcP3gp45gj0TEZKUzmWJHkGv9G/Jp+vbrGjRmLjypRYnIkyMa2CnFSxmCIhPPc9hgbGsWEVUxXvC5CZLPdtc6VaSgeZNsdz1K9Sx6ZmoIHeDwA6fR+VUjcIuZQdJqmE5IAIQU1fo0yUo+fGxcEzZaHrWq9tWQc+9aEGCquAuKz1VOkvi2otCX26FCN79O31WMpLWPkz70EvuXEJhARS04AcEIpFLraRb+UoDVaR0Qi8gct02Ed9bxmJZBQ8TlkqQTLBJYSZIInIDcZQF+DrE5iwAylL0lmFbSAIpBccyVlHr+lbB+tcc3vFGHg+7jTurlg93yNJisixvOuaH2TxoVtslPi4AjwlonSW0ETNznwOa3gQHaUCliQXQaPN8lv7OY6ccuXCpRg0xTW3rTZx20rmRgx00fod92DWRVG0+MCE7trNUS3SVmeh2dS0lEbh0QBRFN+ULtQZeF40dz15ji+9CBzpcpG1ydxh0gO/awPDE/foaIhdGlJRKcHcKzkuNI8bOlnX9CZj1dGiP1H0RWeK2d2ahtFKBC1uwWFLm/yirkc2jI9Xllcqjkme6WAskLds/M05E9/uZNJ5tI4ka0B1pR651LhaqrvvJkk6uUiF0A6OoT6fQpqNY6yFg5c9+OuzEqxywr/y/7P3JtBxXOeZ6HdvVXV19YZuAI2NIEhwF0mJ4mJZixWZtsaWYsuJnUiWszpxEr/JGWeSPD/HyUli60yeM5NtXpxJ/JxJMn7J83EiZRzHHsu2TGuxrMUUKYqrSBAkSOxAAw2g9+qquvfpv1XVaIDgKlJe8uocGxTQSy33u//2/d//95Px2YR7S7WMW9rSmr5rUwaJhMlcVzQsSRgvEgBffBn4yhMcG2nX6gPm54G9exzVWa+ofIMadm4AtnX6DeXNu3AzSAmgtBAoE6wYRWG1PNi1TZ3L8+Ml+cLRAivaXqktbuzf3NI1sHcvc6l80j0DyyzBWYmX2wzSjzwuU9NVbOU2ig/dgbLUkKDY020CKb0+bHk0ddRTAhpZROGBUQF9TCA9UUCK3iM5pLKSOryYAY/iVKe+sntLYm3rLJQy3Kc/qEPXKa6URQF9sgJLl5Djlme+nPD0u2w5vS/mdr6vaJ7bn6zxjyNxvu6h1unADkXS1MIEtFfH0VeoIj153tvQEdOi6vwd4IkpgeOTUJL5ROGjojM5Jvfv8Rlgnqeazst1F8OOjcqaVgy8uZfNDg3Npcsw1raYelfC4l3wBA0+b2RoKb9gLB+lF1wSbeKHRwUefdZTWf2fuVPDxp4V4k6FTuHatiOE6+laMJGY1PuqHpsrluoTNRaZsqIRreag5tn1aFsmMr+qFWsqtdq2/EyDEt24nUEzjUpgDQkTnzlu4vCUUEBdn/H5xjRImOqm358gDS6FkimnaugpVJFczTH2FgDFImqrQ2EvCfaZf5nMVl1nV7XmrV/TE8MtG9pABPKgrNbYSMPJas88B+z7Dkd/H/CT73Lw7ICGVAq4i7SSgn1XPdOmoDIEKd24UM2eWE/hERa5SxVHvHB0DqPTdSdlWa/GI6xRUpmaQkx0Qn7nMdhE71tuNcP//sQxGXnmeWdrKmnoXe04/dl7UfjSOay5FEjD9+ZcxLtIDEyHTdXHMYb02DxS1Pmi9p1AfTLYyYUZhSBFBZ2ryWsybNujk1tjoZzmqoapDopXNQ2yIqBN275I9WTUixy2asY9VXP8dKwef3cxNrohgomsgRq1By6/Ro2j9fkJ3O54aHv8Ww6jkYL93RpOjzoYNznmUgZiJIUW3nAieL1Wk37HFuDmXp/AQoIoDBi52cKwK+3K9tUmkZwwOGKvLVW9za1xFkuYrJUzpp6QksLUuVQ5BkPVRS+Iu9Wgab9DbelBcSexAeuO69ZJrk1ZT6Xe5wheLNbFZK3qjusifn7jBhQffQx8592l1g1dCeIcbwP1votwGLEN23ZV4KpmtzQWKIVqfhH1hYKJvzthYKoksKOLq8l+lEzauxbf+aXv1+xueMcepU6KBWxzgPyDdUynozAnB1AIZSGprvg3X8uvml2o/AgTXuutm9tEX3eMCyo5LPNVVdP4a+39X/xn4IzN8eH3+f2jDbkiAVRoLEXYBhesGYplq05Aimh6lCFb6OCpgjh6psQsk49196Se+em702q8Ibm2yMPc0OSyrwRQcm1PbUFfWWLN2jROfPp+NkP6NnRtXzmPtS5HfLklXY70WRcJcvvXWiiQDNM4R3q6gCRlfBv3IYxLg/vS/BkRDq8roppisNZCpcXwQVqvQxPMY1FDcyt1aFN1ROkeLkTAqxGvdEdFm4+YcGIChT09GJ/PLwIh3QpZWYCejmBz3cUt/zLiN4c8+5yDXF74/FWqGWYNoJPDJv2p4KRUSEG89jKwhQMP7PATKtS7+e5e5FGrH83XIfUYPC4iruVgdIGhQ3Nqfcko7zI5a2dKC5H2XKX6JxTFkHFq5rx4koziTg5Rh+e4tmDUwU9xJ90LIaVd89hEqc4nodeGNnUnZ5tzJt89Od+fjBn3bV4dI+w3DtoAKhUbhYKtkpI+id8HK7nmjuPAIFc4ZuLLkyY+d8zPn2yi5NVmjN+7Rk1OoEkh1/V43SWY5WfzWSljH2asQm7jTtLMoeI4UGzEq8dkZPLk+LZixdvRkjDiOzal0NEWW+ICh5+paGY6UKG+rqa5OeGNDXZtPwNIzeC6UKtLrZ/g9bSjnh2vyJeOFahYPZtKioNZu3eILCUp5OUAc2EQzsaNS0sqy6/rvZ+RHZEM1mg65je2YeiRvYv6NwTSJ85jbbkJpIfm0Kn7LZFLjpk6iJ3DOnWU24D6eQPp3DySDYJCEGOrnMryhFiwMAmkhNK1FqpxAy7tVRUa1emB6QbcuoA2acNkEUiDZrtoGE+5sKO6yh5X20xM6FQG0sD7XHjJJNqlxC4a0F7xwL4yDByaBQ4f8xlgwe1EKQUUUhzEZyd65ZxDamuAR2US+p8NWLPA23qBzb3A/b0k9ATXkzi2IHF8dcviEK2TOZl0yqXeODN6U3HWaXDWQirxQbwq9Qj3DENjmsYpK7t8nUrPc1zSjnLrwqBuNjpHxrlTdflMoepMUknlpv7oeHPVIZeTyZYWbHMcbDs2XIpNzdvY3hfDmi4Ljudgfr6KQqGKVMJStV2qp4b9zA4NPPbpwMqFI4YUzeD6/JCBMwWO/7AF2NWuGvJPRqNKN+m6dctcd5AuX9zUztW5AQkXcDNNAsR/+6+5ZNF1dlYq4qbO1oh+66YUWhIms5viVbU4mra6ZsJBkyei7lug3dX4ejPC5fScLV48MstniqKaSLKDqzauOvHQdlanxNbWHKxWF6J72XyY5ef/0W9Mxs8vdG4UFThJiTOfC+aFNL+OQPrVYfTXGWKhJT2cRweP+DBrBmozSDMMznmO9EwByRCQ6rVBLoXizuWH7kF2xGG7HlhvBNVYFK6iUnrQyKRaET/erTBw+oWmwVvHMB7R4dU8GEkXc3MGCjmaccuRvy+LKauE+zygi1xlEq3+hWeAMyUSrfZLXKGFd0zgtjRwT8CDft4BnqOseZCko0fl0iY5C2wQwF++ixollBtOOYqnk0l2bPl9Gx1FpuBV1kR19KQjRifngsJcVSahW0dg1TRDZ1SiUgJiwqWkrbQFVWGXlFTyFTElNDackOZII9wKvlBKGatXcT+NIqKyoFKktAVGp2iSiIPtvbTz2HAb/jRHayuRikkW1IVm6HDIKgS0UjdwJTo7U2pD640ZfiKTDoGZQglf7uoitZzXf9xwkIanSI3FThmpaBzFnmCSF/3tb76+0LpQKtxeq3j9/b0JeevmDKMMYHivLgvSZdldCh3qjieeOTInxyYqMt0SPdndqr300N6OEoHp6eOI37QN8jOfRJUIChe7hQTkL/1PrLMraNm+Onfykb0dF8yFCd9Ln7tvCv3Fug9SyvAemUabZ8BcYkl1YKKIlGRg3SbKLRrqI3W0TpeRoMWgQBlsSqIZoI0dHNAZRDaCOmV5e+OoxoPGE48E3TUaQQLP8cD8YV6qFOFt8jBmcbijLmL5OuJWFCymQbYmMPQWNz9tmi3v5lyjYW7Ktf3UCeCfSTKREklhmjm4kK3DDu7ZQR0vAvuOejizRlNN26r5IUjm0ei/H3+to/y314fOAJEJvOdiMYPG0l+gZkH3b2gaHW7dWRvnsituyS4ZTNkmsNLwbqqv0uoPWB6aX1KBdCWvFGwxVrbdKTMVP7uxbeWxEXJOpsuG917OtQSBlBKRig6q7pLAwGgBmZiHrd0G7KqNVMpCW1tMZbFJvqVcrqimkXLZr91algkzFsOzR+fQEjOwU00M9h8edTW4Lh5tafIcXg9U3zCQ+icvWT6PpG0g0p1UGjLqsdLslc6vTq1dKNTfHNG01q3rE3LdqgTlLVkzpW9FS9oEUnpox84uiMODNDEAE0Tl+9/e3Usuj6S4k6h8pXbU9lxCUIzO8Ze/jI7pCnriMYx/4cdIQvfSB73nayNYV1OGzJcFG7WRyLtKDrZxkKzpeAktBMZuHeUk4IxwpG2BKHlW1Tq0uqZKKRedickZRCu1uZFCgQXixzNiCpELTeAnkAZseCqIsYUK9LiLYk3AJJmglAmnI4oy1VPjBob2spkpTUs8wARr0ykWDHzHZ2aBTxwFZt3ApaV2NBfoOOkoBQQ6yKDObeWwiSZHyRcAHa+1C/7WRuCejIKU2jEoGWNFrOdiLVgRpOENok4iI1nrZQy9qSjvjnDZxoI7Ecp5hq9ljNu2K6cX6t5ExJPD+/fHpi+V7Jubk2nh1N6rG1qCyj7kIdPGMl7wS32UOS5XbIxMlbCtz8TWNYklXlwYr6r7wzUcGy5hYNzBzX0JbOwKxc0EHGJDeXD1iPFoKnV94tMrBqmS5S9ig1PF2oSFl1MppuaMXMtB8WpXES2xJMR3gUI4i+XRYzIyeya3bWbB3pVJ8Oht29pka8rkjvBLNhcDKZVUhqcr4rnDs6xmy2ImEd+/ve3o4N69e10iX8wAsXmgHk4Qu9g5/+LfyqSdxFqpofDjHkYv9dCbP2O5u0sgrXNoJ+bQEdZK1fnrwEgJLXQhBNK4B5fcXY/5FpeIDOTGVgS4K8HrQSzWnNygsgqBlHa3rjhqloSgUg5ZTgIqgZTcXQJsqQZ9YhaxbhMlQ/eJEqYBd1UCyitI6Ri6Q05NGkbmPs6lcgMpwAsXMZHgP30G+IdhIK5D9dhkpnwOAtEpyWsZT/kxKSVQ3r8G+Pf9qsldJVwc1wnnpFBY+WR7u/nqlayXyUkZn7HrayKQq1rjvMuAaAmTSJxzr1p383NVNsE5Rjb1KYHry6o4SimT87POewHR0pg7avhgJZlXqtUTl5s4FuOzJcwVqrhtSwL9nUuatnB6tIr9AyV0tyXQlqE+VdLdAjotR43JoDXKIrziecZjbRex6ldyD5pfc0UgpR2ufwPeWS5hDXVOcI66FnUOt8QiL17tFy5b3OaRKbSYGqqb29VEa+UKUbw6X/duq5Srm/q6Y2z3TRkWjRpMOD5YQ+8vYnBZqNjyO6/MYXah7sZi+tFNUfbKAw/0VGhTOZ5DrDULGrBC0pUXdW0/e0Aaz45hje6A7Yph+Nd+1J8VQo7rJ/HJ+iPskYu+N/QQnpxA34JLvdz+QUA9X0fLgqNKiepQIF1AC7nD3UA5zuCeZWglPWhocCRpp9ARuJjSAxNMaaYxoixTLZVJyIwOlzIUnQZsw4DrupCertpwyfMQ3PMYsTOqtqdPLyDabWglg1Kovmi505tAibLJcQ1nf2Lm+OhAcn1viylvi0R4O5HO6RSoNkjseLoJh1+D9CePAgNVYM1rsWbW9JNGBWq+N4FNr0mf/P5WYGus2Xr6083I9Ss52nHm6QeWx4mXWju08Y2NobXmOWs1Q7TrEHFN00TVFSXb45Pt0ci5jo4LR1Ne7DOV6PlcfSsTbJfBkRKuYD5N0fce6ChQ62BjHKfAaK4Ez7Vx11YaEiDwzOECrISJ3mwC1ElIbm9PilwUD57ilBOdmc3XETnY3YZT10tt8IpA+t1XZVvSxMMdGXDTFDh0ooQXXi7k+9O9/3il1uZSD+TYtEzEJOKTdRQiU3B371Zro/4PT0xlp+fEW6r1eveOTSm5eXUL9QgrF9j2PHn4VEGcOFeUUZ2dX5uJ7P+pB3pm6GG8MAozUkekOIwyERQu8eDYx55GZxFoN8byw3/xM21NE1OVe67PA4mxHNxmksbyz1Oxbr66aqFkpQhUocsrTPDjM8hKv+6tKHvjy0B6BsjUpEqSRqgIYzB4GV8bSSuSmLYAK7pgNMiUjnC3oHuwTockT6uF2tGoV1SH4zLUZwXcsoQoVz19rqhFew2UTB0ebQ4xBrebLKkORKI4+2CLalzHK+fmEy1a9JaWODZzzqLEnQ4ZQaFr+Plh4KuTypX3N0oN+KV+4ENUcQwaSu2K49c9OWRdsnzZjhw4uApnLja57nKbPCk0Ul2TuUaLIaQQopZfuzZNodJVz12h5zQ8vJA2rJabTc3ZxKWwwnGcJvm7AVgJqCTW7k/1ExgYpkqdhk395Db4RAqlWml4Kl6ltwnJqyXBXnVL+rH16xd1sC53fVfy9yUgPT0rU6gitWGVUnJv5DxeHZVtXhUPk5rCgRM5DI+WYMWi+b5Y9xKQ0k2YA1J//lrJ5Uqnj4UnSeA6uoAWtwo9EoM3ZiC+4KCc/bOnC6/u2rS+WBJ7uIbMlrVxSQvo1eECcxwxnTSt/b/+cNcwPvlJPP3BT0Zo9uiojvpb1/qK0RfbzT5xSKYXZtAdY8h/6u2YvpgSHF3TcSBeGEWLbWJh7wq7N73mu1WscuqIzC4g2gAqzWPxYLy6gHbF1w1iUjqvNRGUDAEtz9Bel7AiEtpkHTSeosGQonVPfi25kkrgPUBoyEsm0URV6Avq7tStQaXMm+KQHTpE0YX73byH9igWTE1ziEts6nC7EijxKGTUxdCDnRgOn8Hx48c1PbF+VUuM7za57KQEHv1ttOq3mq1NA6OvtWv94Unf2H9iC9CnuojC2JMWLKeOk3qlzk57Uf3QmjQtie+vg0Kg8fFqTyQSucXQxGophEH3tnnuKLn+5AIT5zscnEXPgEaXZGNKtVtdFNO5U7TFsNTNV1a3+8OfrvfVNkA6PS0TQ9POw4WCGxXSO/GOOxNPhbsVgVRW8bAeAd9/OIfcbBWaHs13mR0NkEopW+fmcIfjYbVlYiyZxAuMXX3ceuCANCotSEd1aIdiiE/FEP39BE78j6fPmfNTbGvRZls5Z17SwNFuXhh48MFtzkFAdwdh9cXhdndfMGRINO+6f/a8tMaKWCOB8uY2TH74CmdwUrY3fhzZCSDh1TD+4T2Lg4UJpC9U0WPbNSOKKCaqsOBCiwS+LxELhhbQapiQE0XVBRPr1WDWbRgjLliJlPD88YYqmUHE7XBsBtV96W/0kxBDoJ0iSyYCbSClLetnKdXsmCBDS2uoiyiRjkA2wmkuZ10zUbJ0lHtbUCR31zJx9sfTOL+8+f/IFKyMqNw0UjR2TRY1c0eng2yChN/89DN1INH3+wIa/jQAtch1LmzJpxfK7sujZ8zzl/JirvdCvpbPUzNkC+jz7Pqtpi47qYVtMV71Xf0wXqV/d6YEDM/xiUgcwnb1KRvuK71Zk1TvLxsXX8s5qo0gfOPhQdkxNl56f7lqo1pjkz/7ntb/Ge4KypLW8XBEA99/NIfZWRu6HslnDR+kFLO2ZvFQMoaMEhPjwPnxcuHE4XNfeOih7dc0SvDAuIzVPTU7svKWPswH58kfO35cW1fbJneffUzgwQdZLofogga+oVWNX6D7t9yFp8E78hNPSR0WuqpFJLviOPebd158HumlbuajI9I6exrrqh6qPRmMEMiVJS2XOyJx1WcNXgUbnEeSc7+flpI98y4SgyWsmyygjdT55meByQJgdAFmwi990KxOojKSm6W4x47PrCJLGmzcDWU9xYJRYl7+2YZJtdDaKtUAClzpeZBye0JlgxG1YK9OYUKLoBTRMfTeDFOUvfAgVtXQOmSqLm7augr1X7nV67Z0tzckxpPyoqYYvjQ81/GHcVGigvFase4N1CLRQxcrg1zrIr3R76NEVUVWt6UM/SaDI+kE8aqpRh/7PTYOjSUhGCraJi8Wqu6JaK91rLmceKPOs7GgaaF96anKrvl8ubMlaR143zuT1OurDmVJ63hY18APHJ/FfN4G0/V8MFVVlQAAIABJREFU2/s7/pFijaeGZLTNwQc0joRh2PjaszkUSl7FNdd8/pEViv9XejF0ToPEWsqjZSaPhfs3+AJaBMTjOZiiCiPZh+paX4NHXcvo6KjeW6sJbKByujq8P3wWbfDQxnRM/fbd18X9Yp/6tmwfG8O6MjD1oxpG3vwgUrR0y6Vgk0gA56aQLANxWUNvTWJNxYPxpSEgpwRzfTpdJuN381DGlBIxtHMTsKjhQA27apJ7oQuiv9MYwQZI1RUGahNUa3X89xLAqbZO8ir2rICZ4qDxH5tI/SKlckKVNWk8/yMJJU8aDmzqnyp7t//v/0sb7M7gxJ+8k5WHhoaiMLJbooZ2S1RjKjPaaAOkBlsO4XhsouyJgwe+85XRhx566KKc5yt97t+L16mwZrSQadEjt0R1bZPOhBlea/hTMF4t1L1B3Y0e6e29cfNIl19/M0j59AL6uYOW9nY1YaohfxOClCzpgZOzyJMlNfR8WvqWlEaaVwQ+AInEwPl5nDpTgBbhlfY1vZ//hb0XKrxf7UOgGOLpc8hWqjA7Tcy3tYLFHbjZrIo7aYHRddBPcjDJqKg5W3+9by42Ust0SKCivxsTVxsnX+48yToP5uqbojLS/p/fjbIZw3kSmKBcIBXhK/lq8ryjvWWwEslSPPOlkwHAaG5J0LDOqd2LrCfJj1KZI3B5aSwjub7KjQza9EJFkPmLgdRXvVzMLqkZoICYp4CWI5715Uw2k+BzFrg1gno8glcsCwcoByGlbH+NX0JyNzQHpxFb0QI+lyt3WkzfE2HoC2uXgvGa7bFTBaYf2vI9EI2+3PO5lr/TnNYN29Cvo35rTGdZklnxiCAi+ISnOS+feuXFMSrtXctnX+t7FEiJ06ibuNerY5VLc24MFC3L/nY0GlUzO0dHZVu5jocpI3/4xCxmCyrgyiffk1GWNAQpl0icGZ3HyaECdE2vtKzuuS4gDS+O+ljPHEMmV0C0K4lCPIlqrwu5YUMA1DlEF4rgj08gcnQSbTEL1d3rMH7/Bn/t3oignj73TF62dKS8t0PTvlOEX4PUFuzuQt17K+Msdn7ewe8dSKAMjrRB/FfApGYAUmlve23Md0AnCwFGYCSzTC4ruVcUQhBdj/iy/qSxRSX45tqxGp7bvBLIItOHzvpSeLQZ6HFgtAzc3Sbwu9vpxVzqOs7HYvgWa2KCrbSgKKxJttU3aPC2Mz1Sq9brh9b3WGM36r5e66K+Hu+jNc2j9fU6492uFOP1UuTM5fjd1+N7V/oMBdKjp+V6KyJ+NNtKyXaBI6dLeOHQ3OBHP7T2ayFIqy4eZhr40ZPzyBdsRPRI3mwGKfCBEKSnh0rQdV5J9FxfkNK50K5O6ukH5xBLJhFdkLB4BVpNB4/USqbgEa/keMUfe5O1sLldWdRw16ME0g1zxahcE9xgVpurdc944j4wZhYKFXz8mRhGSxZ4AjDa4IsY0WgUAmmnD9KVTiwUC6fBu8r9Ddq1Jqu+e7uowOvrw6rEUtNTppEOpiNgjwM6SY6c8ZDYpMHJ+t0bP7emip9bryvuoG5gPGHh64xdmm8aqiSSIsfl+m1v1KJ9Iz93pWFVb+T3K+NC/zc4IjfUbNwX4WDfeHFcteqYljH40Z9fvQhS4ZdgTpyZx9wcjS7Q88a7Fy2pDXxASiSGRwsYGC6Aa0Yl1tV5XS3pxW6OlI9qo6N3RHp7e0ON2OVpcFq/8kaCNDy3YlF21GqV90jGrFKhhM8d5vjicJuv/esAXg+gxf3OHhpYFO8CjIDUEpQaVwRss4kMY0I13ZqOIE5UIA2U+X32kG95S08JGIJqerRJaODbKZD0Syd/uKWEHVlLSW9qEZxLxhRQb1im8o1e4D8M36dAemyktkGzzfs0A+xrT48GXSX64Ed+pnsJSKlRm0A6X/BByu9fClKypEMTBZw5XwDXjYqZfWNAGlrYaylwX8+HSCn9hYX6j9dcr9OuVjA0XsBv7F+jqGdKu4jGFdD0czUOwweXlQbMQDU/QRrEgSsbWtZG9is40UYWNyC/q1H2waFKpk0mmfRTSrZA4UmyxL6AF2WTzNupWdJ3MbanbHxqSxV6LAUuuUwk8FIkwr57Pe/L//9Zr+8ONEAKx7wvYoB945lxtXo0XR/81YeXgVQDP3mmoEDKDSP//nek/pGsE/nvjuYnjkbGCaQlaIZRWdea/fze65A4en2X+Ma9u2jLbeVi9W2ElPHxHJ4cT+Bzp7ON2adkIm0qudB8F8VU8EXUUpSqaQJb2MO55MybptWHnTINgAaurjKq4ecEvXy1UYHqMRq3ATgULVM8fJsP0tAMf3bHHNKmiUQiQYoZ1WQS/3IjmpffuCfxw/VNi5bUMe8zDLB9z437LhM3Bn/14Q5lSamDYL6Kh6WEcfpcAXOkGanzGTGfejTM7hJIyZKenyzg3DCRHYzKmnTrvxmQSinNmbn6+zzXa6+UKsjn5/G5wSyey6UW1fgp6UMCQUqp369/htY01rKoSELWMCTVh3Fp2D/bwHKzqQ3+GM73bCxRR2DheZrXSnNVgELOgdFvQG+SvyRCwm9vKmFHwkYilYLODRmN4VDMYM/9cC31H9yracSkngPl7u57bkr5TIZhDH7oQR+kFM7lyugSNdx59GSps+yw0/398QO3rPFrjqElJZASKXlopIyIZlR6kv92QFouy55y1aYuCz46mlP38E8Pt+FkKbUoZUolFSIZZAFybUm2NJwWRlne6EWGRalH0ATKpvZSpMhFbppRol5LA4sqAgsHAVEFLJJHKHtwSP7vdpr1uShzQSD9YE8J7+qyYZoxmJZF5OjplgT+tbkM94O7xH/wz3wRpB7uMzSwp14M2id1Pvih94YgDaAqpT68gGRfC+ab479mkFKbz9BoFREeqXTFW/7NWNJSyb65VPHeSmgaGppS2dhPH83iaKEJpAHYHFJAJ/V8Ih0EsalH81TjQEs2nAoWLC4CZ2A+Gy1rTa5xs9UNaUf2pEDplG9BQ6VEe96BsdGA3h8onQXBrQJpWwnvWkOqAxypVIqGPFeZxBevV9Oy2uYl5e0apInGv5dDiF5Hv2teXyu9t/l13w8Z2Bu5FTRACg/3cQPsmf1kSYmfqQ/+/HtaA0u6eAor3RACqYjgp6RAfCpXwvlxNc672h1r/X//LcSkdE+KtdpdlaLcSc2cw+cJpBz/fX8CL4ps83wl3yhSAinowySgkkV1w6EVxBRK+AklqmuGspIN5bolNZaAbUR9qBXAyQlURgGXSjSkHkCtY8RsKnjgfYC5NYhFm1QfCMi/lS1gxxq/myOVSoNJOKaJb1gWG7rc4gvBcrnX3aC/hyQW9fN7nTi8Qdfol2Aouxv1TAXS5w9SH4byrgZ//j2+JSU+58c/jj7DwFbPQ5QxjBoGjoc1NWIEDU3gLimwbXKmqg+PVYRu6KfbjUNPvtHsjBt1oy71ubRQazX3noWic3MDpCbH57+ax5Ox3QpszQeBVBHhY4ATkOfJAyVtW1WaoSQRvUZTUrrq/UtkacmS0mvIXSZwFnxgKp7ua2UVShKpdr4CWVMPxnrNt6AE8GW6ScasjUfWj6NvTaYBUtKqjUbwbdNcqkm00j1YBtJm3nTIBLvSRyIfA7j5HGLr07C3bVuUKr3CD/ghB+lgbUPU9EH64gGKp9TzVCCVUra4Nm6XvraU73GpaVSYFwLfNU0MBpQyNpbHqrHxyo7JsfKp97wzS1OQr3vbzhU+sDf0ZbRQq1X3jkLJ2U3b2+hoHoNnhvBfPvVZ4K6/gLFVyQeFm5/62Sil6DQCwKf/EZ87bD2rksBXqKpNbwiSTOrNoTUNftJDoc4UNbnBE7DLvmXlGcDcDHAl6beyJIv5zYMsM/bf5X/+o0dgWXGV4ZUSbiyKb0WjbOBqbmQTYK+oT7nx2dRm+OO/nqq68f6aYBmuyXK/YRy75RbV0eSvIXrNW9/KzxpvtZJp2A+uAOIf1vXmW1ICqWWqmPSFl0k2VIMj3PMPv7M9J11sF8wXWqajOWlBt49pGPO86kuWZY2RyzExAYvaxd4I4sDVLKAb+VpanJOzlT1MiNupppKbmMVv/MYnMDeXAxL3A2/7JWjU6LkourB4M0PwkiRm2KboAAlydYOSisrahokjShI1ZX/DMgzN0qmWyM0V4EQ17AH0dGA9m3eFppOInbFhf/UPUMgdwgMP3Idf//UPU+kMJJdpaOKbLS3RwWu5bwFYaW0tcUdX+qynjyNWLtZXe0x0RSIkH6TLYtWLSiFty9TrUrrnE7uj41/8fLVrXlg7a8Lp1XSe63KK+/7rB9PNsplkSX8ojYIC6blJ2e86eBeVYPYfnVfiUakEl/felqH10eiAL5X85uO45dPUmlQCPKa5pweGZKFYwba5QnXsvrtTxAV9Q4nI17Kgrsd7aFGeHZndw6R2eyJuYnh4FB/4qf+ITNofYuh0/i747bdAyxgNg6YMmzKBixaWGEJ0T1WuiBhBxFAiWc7AojZEfAm0oWUliUkCdALQ0gCnSeUrSIE2rjOwqFGiCu77KmaHPqtY9zHLwj/90//NLCsh6/WKYxrON9PptOJuX8sRyM80W9QlrvDx49AmauiqiNpaDYgYpi7qDvR8UaQqtmO1JfV8S0Krlmy4XxvU9YKLTZrud+o5LkSE4Rv/8DOgmDn83DeEUXYt9+L1vkddIPFOhyexCRx3P/fSbKQna2DHFguWudj4SgwZUpig8XOq8Zc6LGKhxISfqHjxSBWlikO0QdcwjX966L6W/Os9wR+E94cgXciXb+/tzSqz93uf+DO8+OIhlUDykILo/D/A9/RDI2GrsOgZuCahCJn6z3DUX5jKDQDXzCRS94Ra2Ih2S8AmoDarlYU3rRmsoSWmntUhwNj/PGZP/7HSdKnYLj78Sw/h5z74ATiuQK1cdBIJ84l02jr7eu5/MIHvAtf3iSOl1mJF69c1ljR1SAadTRVE0rZFjJFaIhE8omLh1RnTPFXU2jyBSPP1OQIixvDE//ipJSC9odzs13MfXu97Q5CmajXs0Rhumq86PE0DQKjznmT3g/FujlfF8LlJtfFb8Ri6erLwBFfWgNL89PtjZ6rYf7iAeJy5P7a35clk0jz9w+qCNN94AunIyOyesZn527PpFFKpBErlAn7hFz6GwkJFTR4j+oLX9ltQo8m3k8xugCr6sVxjNwCv+rHsb8oFDgSaG1gPAdoM7OYYNPg3cYWtYwLixJOYG/w0NM2E7bjYvWc7/vRPfl+dSKVUgic9J5WwvpFOW5fN7l5qAQYgDc9KHs8heuZsfZ3kooO6ESKmLhfKnpUvuCnSudZ1Lmmmaq7C9MNzWrQKbvjT3ZceBNIW3f7mX284NoTdu+mPtI4JpD+Unhurl+WbYOBWIZbGnVWiw6gxy0CpVMDo8BRu3rGeutJRLZVw8sQwduzeosY7qNHkEGpAbLUq1CQzTkxQHec0DfsZY40G8te7q3w/vj8E6cRM4Xa6X9msD9TTA2fwsY9+CqVKVUllElvWS7wXyL4T2BiH1hsL1ZnVZV1gRQOL6f8xuPJg0TaLZysrs8zyNg+z0hwBcwgwT8+hNPwFlKa/Dk2zFEC3bFmPP/+vvwvLSqNaLaFi29A17iTj1tczGWuJasPV3vsgNjWOHJkyhqvpHleTqziYEYloJJJmLhRFwvOEyXRNEs+4UId2bC4SnfW4QZpQKzkHdA4+SPHNv37/8XOD2MY2+CEZubs/lI0BrFaTH2m++XRjaORgoUT7mIdsNqb+nBsntYUKsm0ZTOXm0NPThlQ6Rd2wGJ4ogDsc2ayJBAmyLh5M1zGo6+zxq33A1+v1RHoH0GrbdhIwmWlSv+fEPGM9ocrD6/6qJSBV8aTw70/KwuTUFD76G3+A86OTiJHLQRkesxde4iehte0BenVfzYsKpnQEKfTQWjYydaFFCVYuzV4J3Wb1q+YVHSjha4UAnBM27PFvoDD+z/CcAjTDRKVUxV1334ZHPvFrMK00KnZJKbdrXIPGWD0eNwmkpH90zQfdl2+8UMjYRuwmkDKM5krBdT6dd5KOYJbGQHLAuqcZODHH2UhZo6FLJBp/yYNAmojY+/72wZFz57CBrQ3uHGPsmqR6rvYCP/GJT/Bt2z7JrodS5pV8NxsckR9Jp4AEtUsFmSCl1l0CqlUHJZsk9zVkWy3Yto35+RKy2Yza9scnSpifqyJhGogndGTaTHCyvsFBw4BrdZztzbKvXsnJXM/XSCkTrosdrutsEAJx6uBRn09i0pzbTJdDuq4fZUwJ9L2uI4xJZ8iSqoysUOLQndlWpDMJVCslfOYv/wFf+vI+WCa1hVF2iMBKStJ7wRO3AW0poJUDXa9RlVoNNf8zHAUZYjCcuUJWtLGQQ3dZFUYBbV7AyHnQJwGtMA87vw+V6X1w7Jxyb4kaSOf3S7/4k/i5Dz4EITRUqhX1bMnd9dXzWT0ZM7/W2mo1lASv5QaRHKe5prJT55EMdA/zRS9WrvMEpIhxphkGA58qg50oGbADj+xKvodA2hbBvr968Nz50dG1jLQkev3VW7+RhAZ6zh97HJ3n571djualOlI40lWKDD7y0I3dHNjZMfkRGkNLRXNS4g6ztuqZkxpAmeT3HVRcG12dBEYDuZyN0dECTEUjM9CWjaskUxgjKR0eKrALIKLj7NruNw6kgeXc4jneblewhFBp0CZTo+Izfzci4eZIxDyq62r8weuyrAND07fOzpXuVjuBUtIT8ISj6o493W2ImzoOHjqGz3zm8zh+9CQM0wqI98RCoI7u7eDmbvDYNsBM07ARX5mMNk8i+lJek5wUot2GKWBi8tEw0iqHTj1utg1RHYdTPQl77nk4pRPqDQqcjgvH8XDHHTvxm7/5IfSu6QNp5JarZXjUaBo0qSqYaqyesCKPt7XFlCbvtR7Hjh2LnLU37TKFSBYcmHNl2cGYsLgk4U//eGqUwzGMlRNfF/liAmlHFN/6i59YonRId4VKf1etx3u56yNwPvI02gam3d1VIfuZDoMk5mhl6VGZ68hEDkr94Lm/3rNHLbbAzU9Wq1U1ZoRGj8disfy1cqHZt18ufqSrzVBZWYqjLANoW5w9o85fzaO0SeGbLGlBPdQUTZHqTCCdojkY/i2nu0TgpGderVaRSFg04Obs1vXRG25JKeVfq9X6DMN4kxCsU7geWzojN5zOG3RF0wkHCRXG2Fw0GnmJ+t+vtb575NT5ddWy9y7fkoZzLQUc4anZIV3ZNFrbUuTfqazv3//Dl3D48DHqNoKp+H9UJK36oaSRgmb0gVs9SsqB805oNLxB0Y50+HODPQgxD3iT8Ow8hD0OUR2F5/n63hRz0meRhSQX9s67duJDH3wImzdv8hOCZD3VTMmwFuRnqfw8FbOFW/9yf3/H5OUW8MX+Tgt1FIgefdnZwbnsLJZFdsFmUY0U8sPElwc8NWHAu5x/u+xLCKQ9MTz58Tunhjs7O8O/0vKjSQXXFaQ0zX2h5t5SdORNjCOq9B8DWZvwp6dDRAw5vrojcuBP12O2imqbBYtcE5qL6pGY29q1a4nRQo9k5moTXOzoQOUjxwfn8NR3hnHf3i3YsTWlkkHk/rbS4N6mG0TF8lxuFlbMQLZzEckE0XwJKCnOqMChkwU8//wA3v62TejORs7u3BS/oSCVUqZd171dSr4uzJUKQYu4aeZ7aIJIli9kADQ1SJPqna7rE5GIRnrBE1e7OF8dLbRVcnM/4UrPVCBVgtGBarXnETlEjc/rzGbQ1dmqylmjoxP4+lefxr4nn8fQ0KivEmiZMEgtTD3PgLkQ6Nsul1ihDLGnhcDy1VvIYhIwDUPHxi39uP++e7D3bXchm+2E6wgFziqBM5BeXQLSwOHVDD6/qjtFPaUXnSR3uftDZb1iES3PDtbfqjHWVa4JXqBPI83eRkKbY9+4BueC/O2lP51AujqBp/7kxzA8E9RJvSmIzk5UridIaaP5+Hfdu87n3JtqrmZyDSz0ZkKAUm6AIrysAa9nDsWHbzWe29SCFefTSClp5AiJvREJY+5Kz5Xc3f9gGIJRM/cTz5xHIh7DvXf3opuUlR2OTAqIK5Vy/2gQvoNcBXVxzNHmzQUmpirY9+yoSjq9/e4+3LyljTioN8zdpZmTAG52HG8HIEyKrxrbavNY8Car6Qunhhojvv2njLUaNQ1OaUI3EtVe1XWdXOCFyy3G8O9Ubjh2cur+SrXS32xJ6WMnuY4hYWKnNw+X3AyhqQxwW1sa6ZSlBiSNDo/j4MEj7MCBo5KSTMPnJ1Q5xGfjBmBffjIqmeS3naXiCaxZ04P16/uwa882tnv3rTLb1qbGIFCm3rGrCrzqKmlcvf80A+0V+rehphBzzqVhRl7tak9860qvvfl1SgNpApaMYYsmvVuPj4o4hT80hLcQlPNoDdFtmK9yHJzXrsmS9qfw9Mfuyo+gtVV9fau/RMtXuvCv5NroWn73u7W7qoaxquZBny4LmrNLcx+Z2mwofRCB6K7Cdsdhu5CVd9wS2ffvLjFmQjVjFIuthmEkotEoWdXLzjBlZ0flDkjsYUCcG0Luf3kSzx3Mo78/jfvv6VG1UFISWClezVHcSdKTjoMnX5zC6YEp3L4nizt3d6uHTirxsShe7G5jFBxdt4MmdAPY6Hnem1yXtQRyno3P9zeSwJJSaYhTFKT5sBUed8nlUirSzT1ffvo0LC8yLqvRWPQV0mlj7NJTwMMvHh+v9o1NTT3gei4xtQLqkMAXkFUPdLc9h16nrNhCNp2f58I0TaRb4sikE364YenMMAxZKhGoKpjPk6bUPGZnF5oG3BKxxEBbOgB6OgMzpqZTM/XZjicd1/ZBSfSchtX0r/HC5KkPdHKLwVjdiuj/2tGRuCJXdxnBXhubsdfxiHmb54gM3YOBCV9byaYZn8HE9kKJo0JMKg4cKmhqjV2NMSVL2p/Btz/2ozgfvtMFvHYsDv26HotNgfQ5964KE70srsmIRYlQLZKrO6m4CdbpoC5mPbts87qha4JxOHds0J58bz8LxdwvehpBDZmsKq3l3KXWmCIzkPJC2cYu28MWXYNWqtj42lOj2LMzi/6elLrJ5LmlSFEgGHNHBHACAyWa9r0wjlyugPvftkaNMq/X4UVMnE5F8FImc/kTXrYTXyYBj27Pw22Mocdx1ID0ixwqFpQLtuc+dt5zj8w4jHFN9ieB9/UZvC+OiBtMaQtzScoTDixqwAKSAMtxLg+apnkx9k1ztwc7+uroO8sVZz1ld/3g1LekJ4SJu5150JAC2i2oW8b3x/1lpqomXFNuaiJmqmlfBGAaJKSpTC9XxAZybr1wK6F59OprXNU1Q0kyR3EJA34EpZGXrP+VQBo2gKuUM5Ix81h7e+LpK7VI4+MypuvgdQ1pTcctnoc1dVeEyokYmqLNCLBdgfE5mq4dXqv/vQdnrx6kFFP/7K0o7OrFccExlKCEdQtE8yT56wpSQSCFlIamZUzEUgaLzuaASsGrC42XGCP+h8cMQ6vf0XdlIG3ywKJVoF2Uy87jjz8+s5K4eJM4NtjQtOxgHu7wPPSaBth4roTxaRtbNqTUYgnWnNr0CKCu6+D4YAGrO0x0ZhMqG2zomGAOnl+9Wg19uqogPtiVabWE7wsJ2vTfSdfFHumJzU2pnyXudyhfQIvdcTzvf42j9jcnKhHbYxrnTA1Q55ARcvYeWq/XPrBOM6JMRELPuKFYHtxB1TLm/1tI5o0wJl5MJBLUgRAeDd4o/YKSBDSyYHxq5AG7Vs+quFRxYHyVa4dKM8F/qrERwRdruubPo1AgXCyIhqBUv2pybckCUalLxXaqHENXFIC9MYHY9wkuqKEGr1uyuwWZ3Wg0MtrdkXz8Sj0HlRwqIOPVsUPXsKnuikhzDoPOaXTWwfg8cGZWQ4zcaUozNuQOgZdyhsqSKtfjcttzcNcVSHcKbO/mUlJyRuAVqWFibVoNpr6qNXcpMNP1/c6z7p1VIfpYVIsyg8WK0iOqNAqzJF4u0JnkIsJR8cCrnHv1t3RFrsiSLv9eKhkG8SpZ4SXXcQGvUk2cmsEG28GPCA9RwxAYOl8ghxvr15Jejz+efGi0oBbOht44HGFQo3DJiuGFU20Y3HuN9KyAlL38UZlwsM2Dd7MAi4VCW6FL29T0FTB2NLE/J+2/PFbh50pMT5l8tI/VD//Gm9KzmM7h06MsOViP3lSrY3PagvjQTaZ7Xw8imiNoIoOyaE0018YkM7WGpFeHxl/1PPtoS0sLReLL+yfVcKihubl07tzCu5xavVUZ1ACkfgugj3xHTTvyVya5mQqETSClhazcT58prf6u6qsESPVasqlBLbXxMwR6EJtf4EUu/qL5JnNDl1HDyHV2Jr7B2JV5PlTqqtexOV/zdpZtraWhgBZ8MFWMxsvAMwNArsCRMgRaaVRyk9dA1/b8FF8EqX+xlzzojlF8++Hbgf6gA5Bx7ukcw20RHIjHMXW9gErX+Mlv2W8rAOscxrVJKq0ZQJrKYjZAkwToWaSjQIsBT9f53Juy2jceWs2uibMeGCkKsmkfoOtQS3ElkLbZtnenbYvVuXmhUTBFO7VwbQyMloJyt4e+7gRiMaq/UQHGQXsLr0WjeMUwjFeulZ4VgFStsOMA22DbfbpuvkkIlRFT7uHSnTp4nir/4WGixmt/ecIRz47XrVhUm1/Vou//P2+xZ+ClVtVstEKnWBS1uKhN/KfjtnaqzHfYUq7amonY/3GbJjfFhEkK/j52CF1Ejr/wkEwWGeMHEokItXKFc2hoB1fDoeg6pqfL2cHhyb1O3e3gkJLcXx+wAUiVu+t/tm8ZtUWQqv7QJpAGiZ4rAal6TUgGDvJCi3TDRQQ0Y8E0jeFYLP3MlYQmwUJaVfdwm3RFz3gBjCxbCK7wc794GvjCUY7bs/6sG4sLZAKOdzMf+TtUJw3AeSXWlBQs3rFe4J6tqhumsanSptCdlLVYVDuDaKkmAAAgAElEQVQyNTV1rKur67IJmUtb0XyLZ6fu+cuXxOqDM+AF8lgInDQeJBiq1dCWol8TD8WC/J31fLwjodFEwmsa+UgEkAceqK2ORqPkiSq9jgtAulB2f9RkYn2p4iI/72C2YMOyLKRSMTURWT1wP+xBuVyCY9uqVppJGbAsAw7jTyZNGul59UdoScvlcns0Gn8zU1wScIqJqbTTkKts+uiAaOP83am6+9UR17Drnhs3I0d+e3t9YF0ifpMN/SbDH9Lr49wG+SZCMG8iZjiv/OYrrlW02R4wGb+7W7d/ebOmteqIuJ5gAZ7Cdy7b5oWE1HK6KfZHo9Gw6K9AeqZQ27Quab5pslR6Yvjs7M1zZXfr2YjFtlby/nS0CyxpCFK/YUGVRyj4D60O/SOYHdOwpLRdBs9D2drgApeANFz8jfu1NCblXPcMgw90dMQ1XdeHGWOvXnrhStI63GPbYoPjeDSsEbkqsYX8d5G6xPM54O+OckyXfXNAM2cSweCpVtOXaFHhUrCXfGuIKwFvPygP3N7gvJvPRY3ayAGFcYBS+g/cI7D3NjqDsG1IoMf0YJma5FwuGIb2MqCmbV8T6X5kurYxohv/bqTqaZ89BozSUOGE3xZIF9aToNIRue/+zB5qM3ygFdgTA5svyae3rDaPXC0CFhYWWlOpVCKXQ755ivkFID03JndKJt6ctjyDam6FkqN0dinwb21NqenPZD2JHkhJIwJoKq4pPuhsEXXO+dfX9bBr4nySq111nN2mZlBrQyP5QGoDjQxlUI0IFqX37XFp/+2Arc/XwXUuz7yzXxx8qCfSWnLMNxtAhojbYfjnx4eLMzzzDryEjlOzDo7/0aniRltoN0UB7f3rDPv+1YgwNVw2NBONItSSrLDwpNC4PDmRm/jOZ89u0McnsY0GW/23n8a5BGOTZHmOHRtZV6k5t1XLtfaGu6tOSu0+vrvrcwmCmJSSRFpjetnVuLs+SBetaQhe/ypCkHJpxsycFdFfyGSi4/V6fdPfvBTp/PYoJrdwnFlOc6NSl+M42zyP75SSmcRcCj83V9XggmOkKvA3JzkOU597sNHQZkQgpfk3ZEnbaN8JZqiqMowAvjXI/Y0rLJ6Gm1QTUIlMkx8HPAJKoAlFFOjVWeCnHwA29vk5uB7T8ZUtyLIZmtR1PqFpIKHv8avtxhqclhtqNbwjogktnQCezXn45yGo+ZrUonlLt59ipP9tj3m4Kw7M5YGpeTDDkE/etdU8dqUgpfpprVZri0ajxHojAsSSuHpFmYtCodC2UEu+2XPEupaExzzHRbnqoVT1qWWmoSER1xWpgQheCyVNaAY/IyL47uuZ7CylXCME3r08MqHM5SKxuPEv7w8O1Z1Tc64Z0bTJ3ja2/6NrSnOItP9I0UZ/yvC9BMIlkXkE5ejpF8Fnqd/TLuiSyrssrcpoX//cQMk7Yht7RN3rb4ty5/d2aywqRDAKeJHQvrR0o+JEeTSvDf4/B/WZli6c+qO3sGbFAPWsqLh/5NT4+vmZwu6647U6rqsstYLTcndXxZx+kOqHoX5dkyznYhJpZUtKgSvlf0OXt5nMQzVQpuszMZO/dOJEy9Ihv6+Nqv/FL6O7amNdVxuG/uxtIJV0+vqNjuPd5rosRfNIm602nftEVcNfneHYN+pb0sZ8muCe30MgJUtqBCANko75KlfDko+NBks53JJDi0rPzgEKeaBU8D9bVRcATOaCq1PMKWDnRuDnHgC2ZhdpEcRPppDB4NQyL8/VTe27Kcaak35LMBS48UTjS9VqNTZnR7P5Asib02gDoL4RyxL42pSHx3PA29drWGMCO3UP1TIwOUeJVGVMWNRgT+65yTzO2KJgwkqAJdrktm3bOkjt5qWnn565mB7YRbVoyPUcm8EG18GeqC7a45YnXVrpYWsa55irGqgL5KImXuxKg9yl5pDxSjeScBHTuVDL3FuWv1HFvcF0sfBvFQ/1f/9svboqox3+lXXG2c0OvHob1o8V8dYM7bbkMgZhX2hBKSj0KYx+bBv+nmZ5pix+sq8H3zmeg/bYkN1zal7s/P2demK1Kfw2oAYzeeklhhbeAT/z539mfv2RRy59D2gyXO3gyOpCubLNderdjidNquMuTRz5fi7FqUtB2pQ4unJ3l+lcqxlWZMRg8lSxmBvbuHFjqE14wTP6lQPS6Mhj7X3r3c5bsqJdi+irhOPxxVrr4lvo3P74tIbHznMiLTZukzJmwSTwvW0APQ8/ceTPV81VfHNHVvXgmeDOhvFI8JNKfHMlQHN9Mg3JyVDcR3F9Txo4ccanqqqJ4+r5AX/xqw5IDKP5UFPQDeKm87LjiKOxvHGMrV46QHpcylimVmsPLBnFknJoBhtrVfF2qtvRE6fzJq8sHRegYNcyPZiuhqk5f6P3VDlM0L9ZPCpeXJ+tncpkMqWVaKZBWEdpL5IlIkJDwM9cGTKXFYwiCzCWw3bbwa6WGOI0ibpUAco1FLmGl86exKnrMXaddjLHwa2adiFI/RrgUqDSopZSjhGNb2ICihmUSGDXdA07qesrLHWEnIWAydBIPIW/J6uTszV0JuRYb7f2tYkJsEQCViRi7xIONjskurYkXaWWVwO0vlIFWUM+EE+ZT1xNZvHw4cm4EE5PsVhaJznvcl0vpkESOdefH0OBzpLsrm9JfZfuIjGpoVrNHF2PlAFv3LKMYTebGrvSidREsSyX3duklOsp5Ahn2DT2qGXr6PnXGEO/d5gr8Kj5qU1DpOil1NRze5sfn6oxGwSawLUdmAWmRlXZzt+UgrdT1lRpBtP4xyBJQ9+/vtPPrO47BGW91G3w/Lk6994s8GsPeA13d/lyD6+DMU7x6oFIBCSyRuu/owLQTjzdDKhHnx9pXZ/tuL+mRVpfngf2pP1uwnCiAH2+Io8FXU9Uu6aklu3CbmsRz9zSb+YmJlDr7ka1WW/YH/SBzAwwm2UXelwrwfSyIA3fNCllvDSGN+sc3QIYjgIHe3peX+dI8wkRSBdmsDMSxV26GZQbgheElrSxWQfGLHDl6oyJ46WSfixfcLcn4/rOWddX3qOFoQodIeE9/G/F7VIJJJQFRzYBFOa8sc4t2hPxirMZ8G5lgikLeqmYVD0wnSuu80JeDKxe+4ffZOyRa/ImKB4fGyumZ2crKS0qs7WKl3XduhUxNEvXjajruppwg1iQ3EqDEnWmJz1RA1jVssyqrmMGiEx3dkZp06Ja20rJ6RW3ayll1AG21SrOTiZU741agKcngLWdGmKGpwgTFyx+osu4wKfPaNg3ydUbVZY2IFSEnA56FvcSyAxgogKQvHPFATKksB/EpFUDqHp+MoLcyxgNuQKQtYD1PcCRAWCA3OogriXVkGxc4JfvBe7cRLXolS0RffyhMy529OvhBic0TU4KzRuIRyLUVHGBJaNhwiej871119jytjXWWlPjBmWTG2sw/Dqy5Iqn7UlHePmUKU51dMZGeDVXyWazxCVW6yGgsFKVguJO6oi54nVyxSANT44s67VmzJpv4Z2Hix27Y4mFv9jop5nJBZifr/VJR3sX4xq3KJNGSZVgGplaMsHDbGR5lyQZZPHQLMqpKutKkCg0uBq8S0kMHSKkqituPe3mBZsjZQm1oOYrHs6bmH93l3Q9T7YTqqkzwyczLE8cLTq+GtdRKACeA8kieLG72zh4NZZ05SW1+NumkpQ2OjrKRkaA1QBGVvs/g1GPtDQpq9x46EF8RQPHi5d7VrQ52DY2uK63W0rR0B6l9ThAZXV/JDIyCaCzjUIIn+W0vHGFntPRAvB/DRg4OQ81/mLRbfH/rVxPalVxfD8vPEI1RPpJg5Pjur9JE7C39wHjs8BLp33LqSZIUr7tNbmen9wp8OAeT1nwlfBJn0HU1aNnbBQqAvfcbCG11B12dJ0NRqM6PbdGyWRESmu8iFhrEqUNQP2LT+dX9fYk9qQTkVUuZcnCMCq4ANdxCh5nA1akPJWMmMKybN7Z0jITEOn1KtARKFuRa3vV6hFXDdLLLawr+fuG09JcJ/EjExIjRzezkwFI2fHjx42+nm1vksK5VQhN9Y+bcT9pspK7u7Qk47eEkeszlaf7KJAgORdKPqiis7+GHZcrF4qyjeWSp7a1TBbopbn1K/h0yi1Wh/8P+n8S3rFtjlIZ0KkQo/Gz+aj27OZ2RfC+4h3ySu7Vtbwm6LZoXVhAqWXZSJCmzZaVSmjn3LtdCLFmeTnuXBV4bhS4LeFnMemgTTObEqqV0Y/BVhBA04CvT2r4b6f9QcVq7Exwa5Xa4eJe69/M4HfKtSUh8OAmb876mdynTvh9zaovSPiu7W19Ar92t6c8oBWtu+a/5/AZF+OzTsO9PpPj+LHbTfTS9tW8SXBOHu+h6ZhxIijlohuLbiq9lCxrMV7a3JWK7IxF9Ra6F3VPuJVy9bxdLY0m09FqIt0yvbkdpccee4w/+OCD6SoQswDv3Llz+f7+/tq1PEt6z/cEpPTFtw7J9G2zKP/1nsWdhca9d3cjarNaOiGiuyTEKgpFyf01acw1JXxChe5liaTmjZt2+UIVyCmaM0csUNUjpgqxf6i5xBYCiTRHX5vwJTPJagYZj4ZIWLAw1CIVAobOYbtcqVaokNiTc4jgZdOMjHmtENnr3IVxrQ/1cu/L5/MtVjKz0605JGvSKHU1vy9vA397Brg/owUTxoMaOcWeBtCZFsoF9mvYS7+RImmiY/39OQ1fGeGN9ktV/w13upBwFdRXifBAz7Y74SeGXhyizdYfE0nvoyRRX1rgl2/zsLNrZXCGZ3F6QmBgxA5UJvzp9bkSQCD9nfeZF41bhaAZR2J/MmletK/40edHrFpZWxvTeMpxSpoV1dHfkxzOjx6ZvFHTGr5nIF1pIVF3y7l5xHkBqkestxWrNNvZJQTSgCapmEwKEs1u7/KsL23NZFGpC4ZeR+7OeElTO3q14KCiAdE4x9YsZeuEKqT7VEABrdGNEbq4VMsTynJS2bpMrq1LBXlecxmNYNAHnLjvacXTcH8QQCql7KvVvLe5rkheCswEkIGCwIs2sN40sMviahNrlGFpALIFdGaEKvmsCFYNGChp+OPTwNACRyLgXKrPCKwrWUKKPbvjwJYOYGgWODa52Fcdsop+ervAu9Z7jTzD8nNvuLZDNqo2JRl9koOKR8+TGIHPUrp3lwVrxW0p9BY0T9P4adNUAnortipSOPH0K/Mtnl43owav7OqLt1iWRfHnNdEBL7epfn+ClAUWfgHUUaO3trobDI1t9+osqjpvVLzaNDBXmdELoxLfHRYoeBwDVUHtsdhgcnQqgkPAnlcWlBaaTwEk507xSEIWP/fdWrLCnHGXSzFoM/O456FS1sGTSciUhHR+AEAqpWwtl733SHlpgFJJ4fR40OWkaTjpAMdKHu5MaeiPcSjacXhQWcISoII/+Z4rucD0GPblNHxumIPKXUoFJvShPSjLSI/w0LhfTlH7cJA7uLdX4Ge3eMjoF4k7KWx2gRPnXczScGvfMVcx7clx/38390J5TOQC79xkope0pC5zMMZLmuZ8y7Iur/MUSPasAnD+RoQ731cgpRpicgGN0L5YBNMYWCwBwd1qLMWMmznj/a4LnehZaqxf0Dvq3/NlatBNXNmQLyouosxA7/Zb1gKfTOOwKxyVsioRCCn4pB3RXinUMUfn5EnQUpcttNe2ADEHbnv79e1nvNxCutq/Fwq1TYzxd1wuzNl/qgDDTMDUabFryj0kHsWT8x5ISunetIYMMc+CEwj9DnKBTYM4j8tqn8GTKQjg70c1PJHjoJcRVChTS/FmoRL43RR3CmBLSuDDWz2sv0jcGRrjoQmB4dxiawRt3uQ9vTgAdKaAHf1+PsMv4wE9bQZ2b7yEKQ2vSZBINzsZj+s0iWHFvHGQ2CNCPFUCiBB/0frz1T6r5td/f4H0mIy0tAR1cSXhFAQ3KaBUBKM4Z7bgbNzZzre06CxBhWOaIEYxa7iDN5JJ1FR9QX0zvPQggm269Q2AkuK8w1GYJ+tKERuvvrrAzkUi+pG+7LJJX76cEJK9kLk8vA2tKpt63VqlXs+DXem94zNyS9x07uWXyUWcOFfAwYEydm/tJnpdA3EUMpSEwBM5T5Hm72nz2+XCrl669+RKUnLJ0DzKel/Q1UL3dNQG/mpYw7E5rggC6j57QEUAbYbAz/YDb82uXPJRW7HmM3zOTLjKOob5CNvx8OxJfy3cucWvxyqABp9PAgXdWY49603f4l7SoApWc3CmtDDxrbVr114gcCalpBVKACUZlCtW8LiWZ/p9A1Ly848fh6GlkUwkfToVAZN+0n9/+zzSoyW0S9pwHWB31su8qQerNMlMcpH8kk0zYc9ngCw5QrZc88/GC+i1QUnFL8x7Zwty8tuzkWlpKOE/mUkgf3c7Zul86NzC86SPiLlw29rUPvJ9e5wal1vgiXszCY9RJvWiRVQNGB6v4plDOXRm09jUl1E6RAEHAboGDFUEvpPzsDujYUcrb5DswziQylukkbVi+jW4Qy8WNHxhlGPKhopX92YF3tfpqbLZ8nMLmUMlW8OZcQcFMrdNz/HAkIfhvMBtazmyLVC5hjDcCf/d32Vgcy9xpflFk0dqEyDbUAUbnBKv3rXdJO4vfROJnHlUT64BHVGfxkv1ziuuRV/rwviegJQA+Y4RdD/R1BiuQAoY6SIaCY1iATg1h9ipBXQyDaYpF7mQdQnpuWB3d3vdt3awjjq5wOQ+0RMOCm8KpCplSwFmuG0uPtyQE6xpuuKHOrbv2s7Xef6JcW2sCjiRMD7WVbcDc124G1KYvrNNJTB9/ojPAXbXZVD4frakBFLh4V6Sj7F0KqVcnKGjLkoDDp2cx6GBAnZs6UE2YzVCf1WzNID9sw5OzAu8q9dA1grI8vTeYBIcWdVUzFOgWW64FOVRaxqbuhIfIayNAxjOCczOB5YxWPHDOd96Uty5sWexQ0vlpZSiCMXLHDf3G4G2dNCPewkrOpwDJvKCmaZ25C3b9ZdnANkOyGq1mrYsiwwIubbX1F1zLUD9noCUYqLfOiNT/2WZYBMF4AMTSlNLnh1F5HAF7dUKUjTUR10czfIknqQLpumQ3AWrCoisAevWHrFxU9qLCEdT7q9hBO5ug2seOkUBAVQtQq6AWSqojC1mHE0cyslzQ0UtH42A0/cKF4zT5rCo+a34mZqOyk1Z5NbHoepfFRvurWuvrzLAtTzQi72HNsHzE9hS9cTbAc4UCwtCcV7Tlt9ytdJBrmXFFnjqQA4kdr5jSydMQmdwX8l7oXLWV897iohwTw8pMASN3EECSGlkZQRNw1HzUy/b2d10IvT9syVgNEfKFovqj/PUUH7S32Tu2uLHs3QetCnTyyjbTKe5qUdDd5uuxMppeNbyclHzNZMG05kpIlsISNrIItpLm7r1Y5ZVjpddN97R0kJC6sTHvWQt/I8Py3hJg/PI9usjmv29AukF64EW0eAgIjUN6ecnkclV0Ro3cFF6hkaW1ANjOtILFfTYAtE72wTu6PUQj2kqS6jiVcXjbfg+QdOibzVVSSUIZkne4yvDHIzByZiYMgzkiLTrhZY0PGPaP4O8A20YGRMLO7uR68zAvt7yHdcTpLQxHjsvb9I43iZAmln+YvYvXyhObIqUEy4B1tz/1963BsdxnVee7p6enjcGMxjiQRAgCT4gkBRJkaEoUS49rNhOHMWJS5airdXG5cTrH+vNplbrJOtsrVa13l1vOetUufIoJWU7ceJSWfE6SmxZsiKLcmiraIqMTBGkKFIQCBLEg3gNBvPq6e7b63NvDziEAJKQKBP0qqskgMCgZ7r7fvd7ne+cGRcvHBmThGm9khYhMO2Au3vop22O/WcdbM3q2N3OHOFSeEgiKpCNKSDE5Q5GQByJJGxwlFxCsr+tDhrfgZMORvPAHb3kiDZkXsqWW704xNey17q2jeN+ulwDxAfXORIXvjer2WcmgFkC+oNGLjeEpqg4srbDIfX/nFuIF9rbpbMgS/6iF/DFl/zosUnnprzAdiOqV1a1GIdzBZx57O535nVXlJG+eAbWwUFs0TxEdWvpMR+OW4cFYjMOOh0XiYwBjR2YroRAq+kgYTno6TRh6oqXSU6YEBfK6VyGQAGVAB/IVFFgrKCDre+DE7rsp7IK6QPllgjOCxMF6TjcxYEfwoZWM+C8bzUG7tr01lnAa2xo7+h03z04lYpEjA915pKtkqGvAbnH+xTSBXIJTwEIlrRWYGC4hIPHZtDbk0VHLqU8XHDQ9DlTemTEwYd6THSniG2+1HlmEgRCXEQtBZCy+XlXVoYmCh7I08u/pTQGQ+PjwwI/POlhb4+BtW2qXVOnp5EtGweyFdTNHniIpG7sACgSt8UOfqwRzoAGgMCLgBhWg3U/ES4f3NDRdCqTqXd15de3FJEefdIPD4dqm6Z8bSd0NOmW4uf1whDpuD52S5vx8u+0Y/hKHnipW75ijJQf8E/3+22zHjZGw2rj9GxoLndAhptcOC6geTArQEfRkYyrmmytBKEXH9DutMBMwZP0l7mUg65WS86/8oSVIhMjtb3PVHSJCeXPsykDAxUdJ84Fep/Bmsp7QERHIRXFsBZCVULTNKmf6du2fG+fOzRzVTOEC4+8b3ny9e/I4t7mHz/6ZH9iTTxzy5Z1TZvSTZEoS7PzNhZ4vqvKV9nXPJ3HyaEibtnSgXjcumRChN7w+UEHU2XgY1tMRDmI0GCrkjAgoYAQ6lA8T/mKJ0fUpIhy8JuRaYFvH3bQlTWwd6PiISbIQbEuKjmTkO6hLRvMnOoGUjGd42lL3iW2aUang7pWsIbm74MPz9XE2e5W58cb2hJMZ+hBGUMtKmPx1Kjfd/ANb2//lIiG4kLnHKuw1MROd9LwYtP+3K6E8d17b1p6nvVyj3NFGen3xvxVrxzHBqLjhXfRc9EYdA9aTUdL0UFrVINZZ1zgYyA+l+X7sz/NXX57J5A1BPJS7oJIGFvqg5q6CqEcj9A+pRNAxExb2sCQDXzxkI6dKWXvlGCZHwrnpIwGr0nHZCyCcaHBoywfQ92wAZ+v43+tKZz/7Vu1M1qDMvrbtKN3/c8e9X3d/Gr/6p7O3M7NPenV0YgVaiyE16uiMgS+Qr5aLAtZBSavSN8GSmJcNEZFRibw7eMOdnbo2NsdTHTXB935FIjPJvMkZzFtek0FiOBz4L+fPmxjugR8YLspJ2PI0Fc3TBXeemhmJTmlhuJTUQPxJSBFzG/Zjx3mIDnx3I3EcwFo3vcxZ4bK/euz+pn29iRV2mi7DHGXVGz71px/k+7h5mLZM/55BLExT0RWJw2/y/crxbNepWQbzp5O48V/tVsj6H7Zx4ox0jqd53fOYMPQCJqLBRiCGpUEDehIT9fQHvYR4YREHW9A4yg4QJwTEzowWgCeGAQe3g3863WAUxYo23WS7ItwQoZBVIpj1eHxE8A3+oEHu4BOjirQywo16ka4cH3xcnKmosHJWRgLmZiikdK7cwPpzqG0O44TGza8u6pey366V/iDRx/tD1vrjbWb12Z3bu5OtximKYe764e6zwLpuCcNZMkImH3LKRsHT+Sl3CNbNgyn656Txnp42MHLgy4+sCWEre1m4P0CaiNWeD2hioIEaHrAC/0Crw460jg7s8pgJWdxwK8law6mh3TClXkkDTObCvqfi3xQnntoCoqgm0cD2JsbguazHui92ZTA6Z5sbS6VSvHHNMwr6sv85Yh/ExX80hH4mTBQsr3QkZMiVC5TGcHzfN2o7usy9n/0RvekdSMdHh42x2uduWMFtF6YQqJQRVfZQ7KFeWc9XGJYFOyEHMTlA2PY25MDnh0E/m4A6M4C/2WXFNWWC4I7MMWNQ5JSA/jRNPCFQ8D4FPDQRuAjvcDBgXk+LIl6YQrLDYCLQIEdgBnOO+ooN0VxLpfB3OZWTNzVg/OBQ3VXcgtmKSP7318+mYRlbNm9teWmzlw6Lhn+Gw4aq8V8NXX5lg3RSScGCzg6wJZNDql4MKAlMSGqmvyNI47UpHlor4V07KIhy9EHjwAFB18/4GDXWgP7toRg2wrOJ71rwHXFZxEzbZg6icdMtGZJIr50aDtekNxD0ic2cj7JNpEP4fvuuKl7x9ev0qYjq+JOSnWFiMW9qh7oH5/xbyq73vZ0GH4yBCNjGol/+okTDpGKGfBdD9UPbzSf+8Ue7W1JSa4YT8o1wRbMxATCkQgiZx3sGpzBxjMT0PITAWeXqcIU1jw4ryh1OqXhCvSPeFLi8+GdpiRj/sIrwCtTQF8HsK+dJFWKQGqoABwYVtw6e1uBz+6RjA54YVDgpWMO9naTLUsxDfCgp+Yhp/JZd+LMY0KSX/mrEzjfHS7/uBCJFbbkQAN92+NI19pLLvd8kgj6q6+0dKVT23b0tq/PNccibDU1elV+Hw8JNF+hvypB7a/nMTYj0NuTkfq19Q2Wueh4UeBbhxykY8D2Ll1CA4enBI4OOmhNGfjgzpCsyHIsjbmtZEAIjJSEt8xjLYutlSiaCfxf4mLZpiFrvuyXNyBd+Fl8dgeEN+N7pVPNCW10fVvGFqLgTU9Pl5c7VvbfT/k3FTxvR0oTsUgI0dVRQzt0mp8quOqfoql+b5dRa7bEa5GI1Bh6CwfW5Z7XijLSQd+PuJPoG6l5O+OmEcuQq8gDBqfVJMPElMoXjWAShpvncN7BD866GC6H8MltBt6/XZeGtYHyF0PAEwMCpwpKLJD3jH/TmwI+1Qfs6QROVpTBnz4r8OgBD7mowJ42Hb05BioXK6B5av4mgF1dQE8zw2GBgqPjgufZGyJGf64HR1vV7rtiYYFXY7iPP37YHAkl12zuTGzpXZddnYhbZmP1th4Cs796pXx1puji6GnigC2sayfqI5DK4CA+VeUmHAxOMBJSgIN1rMoy77Sp76o4qJTOq5JwFMKW44L0nLn00qEtRcTG8jRy7uKqB9wYxlOjqObYg0uHAewAACAASURBVAnDO9vSZpazkZibSEgEEalOlvSev/cPE8kRvWl9LmtOpm7D6GOaJjhe+UPd3fta2d+qWcKIhXR0xoBTI8pAiQXnCf+gT5fD7KGQPhuJSLrRU1erTL6ijPT8lL/mZA2/0iQQ4u5ax1zycidsBZwePMtckzynAs+csnFCsqMDH+wx0ZXWsadD6aseLxJqJtCtezhXNDBBI7N0dCQUHccg+6QC6IsCY0Xg5WFgqiLw3ICDsaJAZwL4tY0EBbM9A3R1Aj1Z4kGFzFcv1iSBczb8mxL6i9s3cHzt5+N49KuDEbjFTds35Po29WSyhsYrD475/qdANk6isMv3V4fGKjhxtojO1ma0ZSUzSyCboWZTeVQcVmy9QMzqYuW2YrsoFooyVKZxdrdGKcC16E1mWsMoqsh5RHmozyU/N/9nwKnZzki5UjyzoTM53ZSOurZXqHWmUsRcL8mY8O+/61slz+nN1/SdwhRJzxJeNB46c/86Y+CjLd62586LtmfHobEIRhWcjpiBkRk5/Chnq3iJn+kzoBRj1SyyYejjgHEwys7BFTb2FWOkDLdO5LFjcAp30IhITBhMjGGW2M6gCjhVAU6PASMjAn91xMbuzhD2dF6sGvJh5OLA9jaApHRnKwKhYOyMPTMaHL3zOo7gCzUeNV5UO3jdS5wY93Dgpz25e7t0rOs0ZchMYmcexJm2SinIOikzcNYW2GjpJ97XhxeudMNvKBP2fe0//+mhzKp0tnd7X66nPZdIcWBv/hoC6F/UEkjHLt9f5d07MVCQmNuuzhRScoRJkUqrNIJhLVtnAQOD42ImTy1VG6mEiZ7OBJoToUWhwHxuXBfTVGjjfHDDBk9D9X0I1/Mnq5W5N7NJYyLVFBFlK+JHgNkrDUV87iV/9b8M1e5wTS0XigX6pLQ6C8jGDPx6DhAFD8+NAGZUwAsqzOy1y85OEPV+tk+XwwO2zY6DItUDdKZIp+Nx0rcgL8tXixwrykjfmMCO/jzukL3LQO68vhXSONqD0TT+bKIE9L8hoEuVrot5CZvkMm8F0NcKbAxYe+pFPbZuuKH1j1NESOW0pFNhcaLOWMciU8WABGPT89bzKXpzQoPrnDo8FVs/BUfg5ox4/da//dzz2mNvj4hsJRvvk08+aRwe29ze3Rnfektve2e2KRatE4w1OFfELYHm6OUZ+4ge6h8oQA/R8FISqsd7zxYMleZYBJyYquDCVAFWRMemzhRayQW6xCEZOAqGNO7Gg7ZBnmG36hRnq6WhdMwZzqVDdsq0XF2vFjOZTOlVIBIDjA2KUWPRcOD/nPF3Fkte3+sjIl7UEdYj0FiA7EoBuSJQmQBu7gJ+MAJI7efgo4YSjBIMFbYL4JF1uowAyRVF0Ihts1Yt2wca6UZN03z1/PkzxxbLh1eSkerlWew4XxX7Do3pcvG3MTKq33yigwJ9y1ydspNjT3mBwXOAxWpvAKInXQr/nhSLUlAnoQyR56IB58low4plQBdJrUwVEQkQwNDZxkrxxZEaYiD4d4S0yfwmkBUYC9CG+zoE1mjO66vWWM+/XVTJSjXSw75v7g5CwS9997Q1NVzqXtPe1LfzpvbWZNQKz+erDSFwHQ98uWvKl1ypLRSLqvxSesOCjZGxoiz0bOxMYF1nfElMMYtK3Khl3tkAkqgvF833q4Vi9ZzvzZ1radIqiDQhZrnF/HBiZncjZY/vh88W0ZSqonpHC4pYEHp+9pS/w/BrvVnTCE87WnKi5ukdMFC54KHsKh6tXTkDPxz2JKnAONkPma9nSUlqyHSA6+4TXbqsp5wZAdqzAKlxy8Q9Bodaj/oZyzKeXRh6rwgjrQvRzk46txiacTtD0iPTOo7OqKpquh5ZBgRT04R/BeFvPd0YGBcojJEeUuUrNEAeLELUX1N/mJLdITB0PmwWk/KugJnW0ddJslnlbbk7T5Fx0FBzknWPysFncgBtTgvclvNg8Q5rxvHW1SHqei7Y01eq+V3+c/2n7/nxqTln66ytb0om/DfXtoaOPbZXjeKxZVNwnM27t7Rt3NidaTZIIN2wmbKXGTJUvkoS6aUOhqXDEzaGxkoyDOTsamvaQmdbFDHOCi7yp3wfek4W8uTzbBhu4r9dzfMc270wUywNZhL+bHs26SZCEbvagvws4GWAULtCDs2fncPb3xlFZnoOVnQTJh4IgAtcl//1OHbPOs7OWMQIZ0xPS+tsM3lK4Y4k2SawM2XgW8c9SZrNBJTAis5u5UV5MBD4rU4ddkkRfZOdjLtSmZyyDcf5aX/cnQs/tXUBMP+6G2lgoCHHQR88b1elqsXlQzYBDtwfGNZxtqKkCiQPa+DFWMElwCAlgdMqD+HGNDwm4P60BRMPkC/1wkR9EdVpV+qcPAVXwI3qsjBEw5fTIR4w46hzcoOo73d0uAx52xMC93QAuZCjWNRNIJsLvfHGGye/v3Xr1hqv6UbNTb/40rno8YnO3tmKs82FxKHKzUkzUWpK4Fi3n3/tsbtXFR999FHd6bw/lzKtzXt2tq5tzyRSQlzMV6XNejTSK4/EXRSZWnrQm+crVAxMFQMs8EUwo1zmPuA7tpufmZs9Ewm5ky1NMSeaCdd8VGY3ZDLzkyukMH2d478TE/6WXI5h7nwe+O0RP9Y/jQ7fwMwne1FLu+62J9/0t/44D0s3BUxLR840MD7lyBCWdkqc86d6TTx1Etg/oGgNc2kdW3sNuT6ZGu1LATcnVH9eYpEd9n5VGEYUHAuiJ4dcUp2e70lHv7NijLS+kH3ft2wb7xeO00O0ANWtbSKFKoFGCrlqCsD+IV1Sc+YISAiKDXw4jX3M+qbE142PA9GyShHYT50/grlGjjXldSDXocix5a5tQHLwSFXzRpB54FF5mvevE9iS8mR7gONPiZSOVLMJx3GE5+lDsZjxTwGM7IZqxVBeQruAjROztR1C87PEn8qyZMAuz6/CoL5KKJ9rMl79yBac/GVNsx8/7JvnXjrStWZ1c++OrR3tqVgkeglqKbjxkgcpelXYgEu8C+85OYzGCxSGXuA2g1cKz6vM5OfOlf3yaFcuVTFCvhetGXMbNiTImvDWuU/f144CsdkiYsUECryO+ps+2d8fXpvZvLc3pa0P+SL5j8NKKc7k9E7IkPKNBeky1bXQCH9/q4GUqeP0lMAT/R5GysAHbjPQHQL6YrpErvGQxikRcIooTXJJDQvZT2Y348hZvzpd0777x78ZIzhm/rhunrQe4trARlHBBwCheY4NwwzBskyJLmF4IMMgWUQycGBUGStDDGlEDYElQ+C4qchm6PkI/ZspANMzqopbFxKSmFCCE9IE1gf9s0DhS5Jp1yUGacwGkHcgSbb3dgjc0+lJtnXbEbBiOlJpTloolTlKQMIM+Ymo+Z2AkOqGMtI/POSvGZn27s2XRUyj0AXvr4I4y69yowsByagh2itetU8zD358z0WJyy987Wi8WNR7NnSnN+7o68iFQrpZN9a6V6WqSjbuyZDvag6mG2MFcikHQlVB3jv/4DW4s4XSaL5YPNfahFI0Hve0sFlucqNT69ZdGVjCfHtoEi2lWXgP95D9Hxnb9vZ6nugWripxPD0MHBjnelJuMW4ZsqEq5RqJfDKA39+s2oA8eK0DeQG2hRNBLE6jZGg7zx1NBfQJgaFxtYB5nS8c8+BqGPvdj+AHPa0JkgfMA2Ouu5EC2FKp4G5uTB5sCMYIxOJGrXkDsIORJeaO4y7w1CngxIS6MaQBqQNKpEKap/LYuvOU90kqbKvX0UHUZfckLIw7tac8LivD9KL8Exoy886etMB9PR66LCERMBL3mzalkcqNxGbIK1QOBTnj+kxTkzV4o+WmNFI75O1z4WlTc0asKLSIb3gEn0rjTFjwV+u6HZ1EaWYG3sZWo//Td1yqQ8uN93997WRmbq6y6dYda9Zt6MqkL8lXg0VMiGEm4Uk+5MV8qywiFZl3BhOgb3Ggwi9X7amxify5mKnNtLfEGdfUYrmmqSu1VBZuDvzMLwyjI21h25EBZ40NRD7WqyZYmCMzjD0w4snKbUFNOsJqArJxJfpM2/yPa3W5uS885kNbOyCf0SGHBQZHhBIUY+1l0MHgGLCnB+hs9s/cvlU7KBIJL6WWIMEV4nobqVaroU/TcLcErEtNDUfuOMwLQ5YuvSqnG0ipWSHdPFFDFtA/AXzzpI7hggInNNDxSpACSbBodG/l5b3IC0APSSNtvME0UobQrAbfv0lgZ86T782DoW1CbpncGR24pPkkqEXqwQB2EX44royUadKNlJfSSKuud4cwPT8UMXw9BGO0LJKegfBqA068pJeK017N45yegNaTNY59usGT1hcoUWOlCYS++fcnMtlmY8PWjR1rOlYlk24jxDCgSYmZZEsIuJTpUVzVCivTc/JYBLNQq1WLo5OFYa/mXMjmIrVUzHRj0dTMpnZJCLaseJow1IHx2qYXzhrbfzjkZqYYTlPBLQXct87AhzuBF08zenPA37H32ZYGolnlAljtZ1Ho4+1vNdLG0Ja8zewOkJZlpiRkHksGCBro2hyhqwZqrics0z+6vS95sj0p9wJeC7/WrouRBqGufO+6kSrNFyHbJpyEIJpBNrY94jRNxGhxIHs8XxMIF5nE3Br4m6PqaaaDNgu/Z6jCXIbGzvC48XnT5ghoaDRO/l4Wo1zgw73KexoMY2mwKR3xFDcLlVOUy64sKtWRL5TpE44uixfRpPlMUxNuTCMt1+4QJnwvqpnRMCJtCYSdOUMfG/FcEUJR1/0adyUC8Dc1G8c+veOiJ2XoiDk0mUlUbg7gkU8+6YdfnXt13bqW5s07tuTaYlZEFsLr7lN+21AVls8tsPa3WJtwaucmZkeK05XR1pxZiUZN4YdRSDnZiYWFliuF0nL9VbD69Yq394svibZzJWhR5klcP4zMTEgS9b44cKdl4C8OOdJhMIrKUZKkgyrfinq0Jwp8vEORBfBYmHfy8oYnFFqOwA32iTkbm4gCd/Yq91tz3Ol41D2ZWeWObe/MUn2Hly8zsxXhSW3bXm+a1gfr+yYxmhIzK8hCL4PU+dQzGg3JEIReslKhhwNMy5ATMU8cA54/rcuRKnnDgn6JDDmCJ15vodTDlPq/abA8xy90CzzU56EjKnUmJYwwkSIDGvNOB5WKO19dpod2bWrCXOwDaD5qcdN8Kr4K5MK5sTzpD/w1FVG709OFpUcNyzUMvep6WlwoapG2JPxEGLbr+2XO1G6Kh6WRcjY1+wayuTTMpjymfjkQ4Go0lP/5169lheP1bL+pvau7M501oIflPnwZawrqeCQ89ubK5ckzo9PnkxF9LpkKeQk9Wkm1N01Qd2U50UpdyKpaxQ5XOL2jJYT+jOrdDK8pW0iSdBpiVEd7BbDHgE/fpXLQvz3q4ZUxgR7iunsNGebujFPl+2LVlqmP6hqolcXQVhILBPOxL52kNg1wJ9FHKR1V26tocN9sjnpnulYZRctK1NJpCTPniJxTv7br4kn5bBq8qeG62ON4uIUejzAw8g4pXIIFR47oq8fJgWCOQ5EFwGDBhiEw9x2GwKZkFsSfvKTjxBiQC4AHl9tVeVa2VDriAv/uNg87cyxUqYmJ5rQxn3dWKrz5Dky6z3oZvawkD/lvOYlDYncdL61aZUr87nJDryvt/u/W7+sK139/stK3f1DfEUqYxgXH01jAtCIKAnk2oBdhwScX5XQXqhsS/qHXxsKDVjO6u1OY/A/rpL7nksWy/fv3h350trk1Zlobbt7c0dmWS6Q1X+dw/6KHpsMvlEuFM+fyw5ruzrQ0R9x4OOSErfDkm0efnXnggQeWG9pajoOtnudtd10R55oZJf/vSQEjpSMaM+RmTvSnmPBQKRPiBzyy10QnKWDAmViBQxMe7u0zsM5U3vMtLZUgtOVgOfHIRFQdHyLti4O9mwz0dobg1OC5NWdE16qnO9oiMx1pz04mk/XwVlKHNt6U62Kk9cpu4D2t0bz3wc//yOh8cBv5dG1FiyE/JXe2kPScgrFvQH1CY1X6nCpfVS0bT/WhfqpC/Pwg8Oc/0BXmtwFKKKUMg7CERSDmn5/4BYGP9nowXCFDmFTKRDRO5naBctGRlVyJDA6aXI6ty9C2Hj8zhDk0YeD75+E/ss8f8UuT32ttbWVlTixnl3+3jPBy56X6WrVabfE87ab+C6GuP3tFWGXO57L3zPBPehWiaFTLYH4CxtLx8Gp9bnbOP390OvTjOsjhaq6BgkdnXp/rTDdH16/rbsrmkomkJekH1bywW3PcYrlWHJmamyzPVaZW5eJV3fBF0gzN5OLZyY2LeOorXKNu2/Y6IUK7PE+sEpyV5UC/aWC4AnzpqAeDmNuYDuIuJsYVioi5MuGhn9lpopNY0OCoFykXC21VNRrIU3vI8OT33z9qI5dStC8sF3uuN+2K8kBLTB/ryDBsj7ukiW1uVkXjxdbMdTHSRk9aq2FzzcO9f/i8anX05hhyOtITsg+pSxnoOoeqMlyuFtUL9hBNmIgF8KJigR7PkMPAjgF85ZCJb76iKCHrRsWFQHjWh7YK/NZuD2niKCW5tmqp0FnKvJMJLVuFAXZfGmfQCpA+nmiZMvD10yZGigoj/Mhe4Vf92nebIpEzKzncpTAWtXkrlYp2vhKdszznfsNE/EvHgFfHKTepjJSBQntzQCXD+y0ZFIDeGPBwK+CW9bGuNuOpt6O5+bffnUoNj46ug6E3RS3DNKMhTRO+qJRsR4+i1plL1+JWyNNMrdweEqPbt7fJ7uRyjoLvZ42yd6vruut0XQWhfJ6cReWmM5gX+NPDDgoEFLArEFNshKTj4fpjS+8zm02J3248ZEuF/U4JlFcGzNCWSCiVaXl44ZjA8JSD+3ZbkjaVg9/lcnlQCztnN62OFZvVeBx9ETf0y444rgQj7fM83D1WBr7Zz9aKKmvf2SPwoR4HKUvt4JIxjjuRNM56w4zGqkJgla+a8Byh8lVJr2HIhUalrnGK0ztAk+VhLeXhpYy7QpGkmut5p4BdsSUahLmvrAyTroOuJcih+JCJRnp60MCRcdUi2NbKYXPB4Hy+BbMSjZRoGxSLGSRkfEH29fLRo2NxvanlwZChxQn+Hix7+MYAMMDRPips50j1achEiZjp9yWAjOPJSqXt+pN33hz+YSC1IOWGl3MQtbTltt9O20DG1/xIzND0RCTmhUzhmDG9UrPzhXt3recY2bKglr7vJyoVd5vva1uEENE6eIDGKSMvbsqcZy0K/OEPPEx4AtGULgELHM5hhMU6BQv5n+8zJYBGuoc6WkhOYyi91pJtSI8pydA47D7o4JVBgT09IfStkYVRr+I4I3atONiVC+dzyXQt0iKXov3mkSPl3bt3X1FU+Lob6cxMrU9ztbutqCFDSo6OffOEChtIMPX+DZwVDUYJJI8J+6gEO3gqBA4KS/w3c8Yo81U+CJvhKm+lJ/NbNvyKhBMFAHlC+VIpHbGEAk5UKrYclaIrZWQre6t2HW5zcS7xuWEDB4aUODG1NB/arrw/iwaeI/xYQn/GslZWC4bpRT6fb0qn002BQc3LYdBIQ80tD8I3WCOSNCkcSDhR9vC1M6THNLA1B/TqHnKC9JcGChW1Y3mOP7qmOfydtWspWSX3VualSxJ2Xc6AiZ998UXueS/irrvuonL5ssEgjBBqNWxyhHeL74o0N1p5TSTFDgAI5OtlcZHXyA18rCLwzVMenhtXjBt97cpItycM3Jkmwk15SqY9jLBoqTTORqAFQ2N6zW8fsrG5w8RtvSbx4H6xXJuZqxTezGVwoS2TtK2ILywvVksmpWbQVYs7XRcjbchJteIM+uyaczeL72RckCABAE+fBJ47pfC5HQmBf7PLw8ZmFQIHYD958zjeJOTwab2K60mGdRofTZPFJXpGapaydSND1Rg9p9wL5cQ/c0+2FoK6kMw5SaRlBA0BXffwyhQb2zqm6WFM4L5e4N4e8vJ4YFLBg5QcsZg0Uoa7KyInDWT5WoOwinLwlyx+Ss8Xz3kPCs1Q8h5BkMKxs1jUw4QAOkOcUDFAOhJ5n8nCSG5iz7+wc739fDKZJB0IV3NucnIyn8vllkUPshzvu9RrKeto29jnOA45CbWZio2/+tpzeO7gadx3z1Z88uF7kYhZmCKLpEdRKQVMqXtIarH+w7CHvk4De+OMGpRxcs6V66Y+A8rxsqmSgUKRmjKKNf8fD9myyv+reyyJpqp5XnVurjYktOq5zoxRSaYsN21F3UoFpZa3oQZ/3Y10drbaLezwL2m+EtzmYUplb7ZFdDzxCnBoKJgPbRP4xC4PrQmyzakIqD46xipwXaBJelmCD2Km7LG+tSuuPF+Z82z0tPWRBllVCsiTWKcKQYIlnjgJDEyr3fieHuC+PoGUVLl2UbDVw7IMwYqu3dQU+RZDyZUS7s7Nza1KJBLMeRYNRx8/fNjsjW39xbZmaz0lNepxpepnClk1t1koC2QpVOohAR6+p/snN691fmI5yVomg1KhUKBMfSiZTF64FoZ3teegF3Zdd1+16u3g8xudyOOh3/wChjs70PGpD2P8z/8Raz0Xn/nEB/BL92zVdN30A+Vo2ZitA99l2yeoCarQVqHJggFtFGwD0zIGYRFISCb9/iEHv3yLhe6cCdsVbqlsj83NzZxZlYsXMnHfDVtpzw8Vyp2pFKF+b0s/5roYqfI6Pt+b/+nFaWyqOc5eHYbUJq0bKw2VBktD+cohHSfn81Xgge1Cgp0fPwvc36kjRcJkR3lVOUwr0UvKWOWmWDdEnn/+53XdPW6Zip+Tf0DPWXANfP2YjsMjyrts6wA+vkvIggIfHs97YFDH0ycMfPYeB6mon4+EIz+KRDAULK4V4UkHBwcja9eupSed1TSNnHlvOb761cFI69ZVN3VkrB1WxEgEgYnyMsHDUEPeqgLuOn4xotVeyyX8s8lkrJxOw5mpVrPNkQgrlFPLzSGv1hgv97rj52s70xb2pcgeD4HnD5zA5/7oWzgzU0HXH30K9ugUxh/7Om6/bSMe+8xHsXNrp4R5EmTAPJTfyznYhBKMlmoHXEkBEH6iSOkSJVlxetzBM4dd7OnRsWeTBWrVVqu1/PhUfiCe0Kc7msxaOGyJuBGprlqF/HJC28Wu8boYaWO4Wxe0zefzyZCWuMWu6L2GNi9ZqbxUFLJndWQY+MphHcWKaq38+nYhJQVsT8fhksAnO1VljcUjCS2cv+KFI1AqtJWHJ8c75p0t7fTpAeDp47pscpOS5+O7BXZ20LgZFgu8PhGSHr49ZeA3dnhONqH1z82FfpLLyTK63INWiicNNkRuU80MLoK8sf45L1kTX90/k16TjOxsXRXuDWl6qJFFXi5ZT7ie8M+EzfKbsbBTykQzhUikHK9qmpGJRqk0JpP+4PnmqtUqGzmoVqv5dDrNTWLZeebVGPDnB/wmq1T7lQ81aRmuF0oucn0UyjYe/5vn8fiX96NiO7BSMZlXWhB4+MHb8cinP4xsKqYVbd3nvLBsu80D4VVvlGF+yVbGyULjNw7Y0pg/uNuSEhY127FHJ2fOGJ4/0tIarSZMX7iucPvWN7O7vCywxVLXel2MtOFB1iNWfuVn8UulUq5aitwGIVYbmqG6upwhpVIaK29QVeBnTqrkvTUOfGof+5gCB6aAPcRCBiNWErFUN9ZGhW8VsCgyUFo/vzMUHvgvD6mROHrfj2wT+LXNKu9lI2K6ouOJoyamyh5+c5fhrcs6w55XeymZTAbt/osGKi/oXVqUV7NwF3uN7/ushK3iRzty5MiFxSuLvvZ//3myrSOX3J2IW6s1IQzf172KXZuuFgtvhGP+XDwSK3Svi3tmtZqIRCITmiaxD3XjTFWr1WwkEmH+K4ND36dyoBxQ4s+IwL6mB1XMph3vF3fHxZrtCeaJBqIhTxLSsaI7PD6FRz//LTy7vx961ILOilHORjZh4TMP3IeH7t8n23n0oDIT1XXkK2qwnOuEzZvnjzp4fVjggX1kkpDDFd5UvjA2Pl4Y6t7QPBf3fRFK+F5K6HPt7cll44gvd0NWgpHWP0PjV602h55SxdvteiJj6obcgYnpJQyQRR+Sh/3VYeDQWWVuO7uAj20XyMQURec8LLARKCrBEKogIP0sESaGjuGygb88ouPEiHKo+9YJPLyLimkePOHCFjq+fVKXnvy+PmBftz9pGOLHkUjkXN1rNtxk6UVXopHWP6Pv+9FqtZpzXbeSSCQWDU/37/dD0+HR1XZFdCSihut7rp1Khgq9bYlSOp2I1mqFYiqV4mKU1+r7fozAiKXOGfRmaaza8ePHJzkcfy0tdWDM33Zw0rnzzSq021NAd1QZK2lHGcLSwx44eBqf+8JTODE1ivb/EULpWRcf1nfhv/3BgzD1kMw9CQeVoa3QJRD++FkH3z9m4/ZNFnb2yEqTP1eq5ofGJoaaI/GplpzphsK+CEVCZaMlNrVxGVXbq73+626kfMgN+Wnj5+H3ofIstjiOd4vvaZHAqUpLoqGyOnd6CvjSAR0jBDDrwAd6hWyL1Ge2FUrmIk6UtWMaaL2M/uXDBn44qMRve7ICv/M+wgRZvVQ5/sGzITx1HFLH5Fe21EoZK/IywjgdMNbLhxbc7IVfV5wnXbAoeOOpRpQtT09PZ7PZRVXK9+8fjIx6flPP6hZ3U5uXME2zGo/H6RFlkLPf90O3Vipt0aic6ObPL9v3o1I2q8DFYrG61AZxtYu3YdPRnj+c37E6F73d00z9xQlPDu9/qIP8yEoSqpm8QwmVCn3r2VfwwwOn8PBD+7B7+zrVzquHtq4yTk6rPHnARmdOx73b2VLRUXOcytnRybPCM8ZyaaNmhn0/ZIVss+RMbtlyKcvDcq9hRXrSxhu8wFClE2r40FqhUEi51dgvaNB7WAWm1fHGE1nEEJgR6/OnDPz1QSULz5v8b28TuGutsk7ZpglOSENm5Pv8aQN/c1iXBYN4qCj7qwAABuRJREFUTOCTtwPv62TJnbN/AmcKKu+MWgZ+42bPXZvWXg9FQoeJDlnEKOdzrZUW4l5psbAyCqClCkQiSsH6kv6dBEAA2Wq1GolEImP1PiiBCI888kizmUwmg79bNM9d6v1nfD+dBtK0jXeau3GTf+wvjqzp7MjecuvW1W3xsGEOlzw8e06gr0nHnlZlqPSmUtpRjjBygEPVKkjLwtlVFekKPPuKg6EJgY/utdCW0uH6whubKY+PTMyc7UiZZU7gROSInDZztD0588AyR+Su9EwW/v66edLGD9JQSKr/eLEQGOXJcq6mWXt9oa3WKEJY1/PlkDclCAXwjaMGnu5XYIOuLPBrWwX62pSXpd7l0XH2YBWvDB/W/dsFPnqzB6VUJGTe+XfHTYwXPPzGTogtbWLIdd2X6T3qefMN6jkvuzbqUMHgGnmtEkEZFJvoIedheQxt6Q0BWbmcXe6ia9ygi0CLXi6bsViMG8CykEUL35eyjvaksfnWbS2bNndnmsMGjGPTHg6eE9jboWNL1pQRE3mXOHDO7yX9q9Al+8fJYQfPHHHxS7tC6OsmJY7w50q1mYHhibMpU8snszEvJHwRCUcLYTc2udwRubd7n1aEkTY+tIUh2UKvyg2xVMJmp+zcEgJSj08Y/sdyJAwjWojFJYHhGR1/csDA0WGlMxIMq6hTB5CvPesEPrXPkxMwbFizZPDCgI79A8DdPQbu6anNxiL6y+FweCBYsI2Vyfm8c35XWWFFore7IEZGRmLt7e1N5XJZi8Vi9I6syl5iPL7vt+Xz+Wpzc/OiLZ3lvLfv+00VsrIAo9dicogcwT+ZWb+qJZHcsufmzu62TCTGPFNqpRaAD/eZUj+GP6PvZCQ2UxT4hx/ZiMd0/Oou9tY5RubYQyP54VKxPNaajdRM0/fDHJELOxObN7dck6rt1d6nFWWkl/Gu9Z5qPRSmkVhz0+6OC7a+Le8g/EwR+N3WoKnHfJU4ynEDXzkIDE2ocjp3y5s7BB7aDfRmHIkW4YN6ZTyEJ48CfTngY9u8akvS+BeY5olgrk9WnRu9Z33R3sisgFe7QBZ7HUNkVuGNeJzTbPMh8HLOyeIVK81zc3NFVsffqRdd+N4sfH3/jVfXrG9tvvnW7W1tUcsMTxQFvn3URlTXcc8WE8LzcKDfxUQRuH+vhVxKRw1CDJ2fGb0wXhlON6Eai5l+KCwcS49f+N6WVJ76L8u5zmvx2hvFSOvGufCrjyIyZeHtGZ4Va5+bhX5LxkCf6cjCkG41gPKDCQiiaOo8RtSH+fq/ECni4cFb4G5Ma4NWPPRjkjQsCG35vpd4zxst97wWi2XhOcj0SP3kIE+/qrYD20AloCWuSBiI9b0iwPydfHYSpNWqxsZd21v7utoZAuv6qXEHL59yVVdgQwib2k3JqlEsVUuvnblwNgxjKpkyhe75omlVKp/YEL2w9W1ikt/JZ5+P0q7FSd7Nc1xtvpofra4Wlnlr1RGtzDcUjk2XnLhy65OYX1Xn5VzfE8cMnBgH7r8Z/q1r/fNu2DgYAwhna/Sc7xnnVTxc3/eJ+83Mzs4WmpqamKe+BbRA71ssFrOhRCI6Mzo62dHRcc37pUt+VN/XHv3y8eZVqWjfzb25jauyybhhqOIkW+AMbU8PT52fypcv5JKWE4maIhHziykf429nRO4qbtmyXrJiPekSYdaiBaX5vHUYZjnp3OTUsNPX2TxfGJnoSgkYOp4fMHDnOq/clDBfDofPnALWsufy/0XeuawVcpUvDqrARDWxqESAw3y1t27EQYSyqBFf5du8o5cxBD4y8trqtuZkX3tboiVsmpieLZUmZ4oXmiKRUjRmSm2nSCY2+v7eax+Cv90Pf6MaaeP1zuerL74I7a67pKFFi3l3l+f6vb6GsDRWCSxSvRtKr8fj2rFQNPRqMB2yMO+8xBO8F9pe/fJiOFsGVsVURFJEpZJENErgAivEP/N8brFPTk0bd0asNq1QpilqoikR8WD5XkQPzczGRscfuMZAi6u/e4u/8oYy0sZLWBAGNxaW5vPWIgec3chNnhCrNAFDaIZtmcZ5V8NAMkmpuUtC27eAEeSJfk6qtu90oSz37/v7+8Pt7e2RTCZDzp5rii5a7mdZ6vUvvXQuOuebSS/q+8WqW3zg9jXL6vVeq89xpfPcsEYqk0U1SbPQq84baYMR1klq6sWfJfPOOrDiPeO80tJ57/c/qztwQxtp/SYFqJm6J1yYty404vfyzp/V6nrvfa7JHfi5MNIGY72SZ5UOOHj9e3nnNVlC753k3b4DP1dGukQIXL+H9Wt9S3vgvdD23V5m753/ndyBnzsjXXgzFuat7+Wc72S5vPe31+MO/D88wFElofZciQAAAABJRU5ErkJggg==",wr=De.p+"static/shiyong.3f0aff1d.png",fr="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAAAXNSR0IArs4c6QAABQVJREFUWEfNmXes32MUxj8PagS1QghJiU1pxExsFbUqitoSKzVilEjoHzVj/KEEDYnGbq3aexNiRRGjlMTee8+K432u87u+99ffvPdK7kl+f/3e8bznPec5z3m/oh8WEfMBGwPbAhsCawIrAIvncj8BnwFvAS8CjwMvSPq72+3UzYSIWBE4BjgQ+BZ4FHgOmAN8AhiYzUA9di1gM2A0sDQwHZgqyWM7so4ARsQywFnA3sDVwJWS3uhohxwUEesAhwIHAzcDkyV9026NtgAjYl/gwuKNGw1Skj3Xb4sIe3Jy8brXnSjpplaLNQUYEQsAlwDbeTFJL/cbVYOJEbFBHvox4FhJfzVavyHAiFgEmAk4qPeX9PNggqutFRGLAdcDTrrxkn6r32cegOm5O4DvgEOanWywAOd+VwFLAbvX79cI4GWZgXv83+AqnnQ43WYmkHRU9fB9AGZCnGFuq11rRPSMkRSD4bWIGAacU650tiQzQo/ldZszT60mTi/ApJLXgZ2rCRERnuSY3FHShwMBmQR/Q9LVLEkm+17LxLkPGFmjoCrAS4E/JJ1QN+kpYAvgI2B7SW/3F2Qh+mnA4YVevjc7NGKGiDClLSTp6J6bS/ea9V8pGbVGPc9FxPBy5XcDWwFfAGMkeWxXFhFTgBOBX3KNpxstkDxpJ4xyxakBPBcYVuLupCaTfMW3Ajvl6XeR9EynCCPCxHymbwjYTdJDreaWeDwfmCtpkjIuPshTNS1fGdwzzFfphXGSHm4HMiKOKxRyEWAi3keSs7WlZVl8EBhhgJsCl0sa1cHE+T02a6q9sV+Zd3uzeRHhuntF/n9YNWs72MthNMEATwGWk+T4aGtJO44nJ5O94o2vrZ8YEXtmKTPHHS/p4raL983oC4AvDfAWqwtJVhgdW0ScVgafnuXQAKbWJkfEGOBOZ2PympVQVxYRVk7jDfA14ABJr3a1wr/kOhHwSW2WT2dHxOaA42fRogunNEu8dntFxPrADAP8ysKyE23WaNGIsMZzXDo+XVPHAUuWcjlN0oR2QFrErzXoHAP8vXhhuKQ/B7DYXj5tKWEL5hrWeFZBXUv8Sph4rR8HC+DKhaaeBZavADxI0twBHLoX4ECv2KBcDlcrRP589iFLAPekxvMNdW2pDXqueCBJYvn+RKky6wGzUn2vXhqlB4Bl8z9Xjloz1THQTJLpBmjlPLMfNGM1/Ahgop9dWsuta4kWEWsDLmcrud1MJdRVL1Olma6I2i6IiIVLX3xveuzd0n5uWTL206p7IsJx6QOsCljG7SDJvXJHVkRKL1F3XOoSXE39js1e2ODea0JBbubtyZHAOynX3u8EYUT0ljo3LG3FQoLz2OtMIaWB/zqvtWV/nPLpfmCTogU/Tk++2QpkH7GQG7eUWxVucr9ypPkpBafVdlsrWtAvDXeVpNkGMGtYnb/UgqT/k1sJsKlgrYA7DzgZ+NW6UNKTbZFVBmTcOiF3LULjh/JmM1aS6amPNRSsCbKh5M//JmWj42pjHei+oWtLTXmNZVoedLQkv+30WkPJnyBc+xo1Te5H7K1aE9+V6mngIcexnXGEf5Jcx3ssmybH67rzNE05wO8l9W3niEwMF38nyKBYRKxSzf62bWflFEO3cU8vmueG7tNHghy6j0eVqx66z291aT80HzDrQA7dJ+A6oEPzEb0J2dY+Q2yUnyGsrKufIT7PzxAWsv3+DPEPkKKBQOOiq+AAAAAASUVORK5CYII=",Ei=De(3407),Di=De(30001),uo=De(52262),vt=De(67294),ei=Object.defineProperty,co=Object.defineProperties,bo=Object.getOwnPropertyDescriptors,Ui=Object.getOwnPropertySymbols,yo=Object.prototype.hasOwnProperty,ha=Object.prototype.propertyIsEnumerable,Ka=(on,ln,gn)=>ln in on?ei(on,ln,{enumerable:!0,configurable:!0,writable:!0,value:gn}):on[ln]=gn,Ra=(on,ln)=>{for(var gn in ln||(ln={}))yo.call(ln,gn)&&Ka(on,gn,ln[gn]);if(Ui)for(var gn of Ui(ln))ha.call(ln,gn)&&Ka(on,gn,ln[gn]);return on},ca=(on,ln)=>co(on,bo(ln)),ma=(on,ln)=>{var gn={};for(var Vn in on)yo.call(on,Vn)&&ln.indexOf(Vn)<0&&(gn[Vn]=on[Vn]);if(on!=null&&Ui)for(var Vn of Ui(on))ln.indexOf(Vn)<0&&ha.call(on,Vn)&&(gn[Vn]=on[Vn]);return gn},Ho=(on,ln,gn)=>new Promise((Vn,_i)=>{var jt=Yt=>{try{Ct(gn.next(Yt))}catch(ci){_i(ci)}},zt=Yt=>{try{Ct(gn.throw(Yt))}catch(ci){_i(ci)}},Ct=Yt=>Yt.done?Vn(Yt.value):Promise.resolve(Yt.value).then(jt,zt);Ct((gn=gn.apply(on,ln)).next())});const{TextArea:_r}=Ut.default,{TreeNode:Fn}=$t.default,we=kt.default.Option,Qn=on=>{var ln=on,{user:gn,newCourse:Vn,globalSetting:_i,loading:jt,dispatch:zt}=ln,Ct=ma(ln,["user","newCourse","globalSetting","loading","dispatch"]),Yt,ci,vi,ai,Kt,wn,pi,ji,Rn,Dt,wi,gr,eo,kn,Xi,Lo,La,$o,qi,Zi,cr,Co,Zo,ri,Lr,ml,Fs,gs,Vt,Kr,Ko,Er,Wa,Wo,ea,fo,Oo,xa,An,Ya,Pn,jo,Ws,qa,bl,Xa,_o,Va,il,Na,Li,Qe,bs,Ul,Zl,rl,tu,Il,Hu,nu,Ua,ps,Or,Pr,so,fn,jr,Ao,$a,Ia,ms,Vs,el,vl,Gu,Fu,Xt,Ll,zl,fu,As,gu,xh,Xu,es;const[Ds]=(0,dt.useSearchParams)(),Mo=(0,dt.useParams)(),[Ro]=Ie.default.useForm(),[Ma,Ls]=(0,Ne.useState)({}),[vr,$h]=(0,Ne.useState)(),Nl=(0,Ne.useRef)(),[Tl,wh]=(0,Ne.useState)(!0),[Ju,Bi]=(0,Ne.useState)(!1),[Ms,Cs]=(0,Ne.useState)(),[_l,lh]=(0,Ne.useState)(),[Ph,ko]=(0,Ne.useState)(!0),[Ch,iu]=(0,Ne.useState)(!1),[yl,Hl]=(0,Ne.useState)(!1),[Eh,ec]=(0,Ne.useState)(-1),[Dl,ru]=(0,Ne.useState)(!0),[uh,Ec]=(0,Ne.useState)([]),[zh,Rc]=(0,Ne.useState)([]),[dc,Gl]=(0,Ne.useState)(!1),[Qu,pu]=(0,Ne.useState)(!1),[bh,tc]=(0,Ne.useState)(!1),[Hh]=Ie.default.useForm(),vs=(0,Ne.useRef)(),[tn,nc]=(0,Ne.useState)({}),[Gh,qu]=(0,Ne.useState)(!1),[Ml,ol]=(0,Ne.useState)(!1),[Rs,Us]=(0,Ne.useState)(!1);(0,Ne.useEffect)(()=>()=>{window.clearInterval(vs.current)},[]);const hh=()=>Ho(void 0,null,function*(){var fi,po;const Vo=yield(0,Ge.ZP)("/api/subject_generations/get.json",{method:"get"});(Vo==null?void 0:Vo.status)==0&&(nc(Vo==null?void 0:Vo.data),(((fi=Vo==null?void 0:Vo.data)==null?void 0:fi.state)==1||((po=Vo==null?void 0:Vo.data)==null?void 0:po.state)==-1)&&window.clearInterval(vs.current))}),al=()=>Ho(void 0,null,function*(){const fi=yield(0,Ge.ZP)("/api/subject_generations/get_file.json",{method:"get"});(fi==null?void 0:fi.status)==0&&Hh.setFieldValue("file_ids",(0,Zt.z)(fi==null?void 0:fi.data))}),Ss=[{title:"\u5C55\u793A\u8BFE\u7A0B\u6982\u8981\uFF08\u9009\u4E2D\uFF0C\u5219\u9ED8\u8BA4\u5C55\u793A\u6240\u6709\u6982\u89C8\u6A21\u5757\uFF09",key:"all",children:[{title:"\u5C55\u793A\u8BFE\u7A0B\u7AE0\u8282",key:"chapter"},{title:"\u5C55\u793A\u6392\u884C\u699C",key:"charts"},{title:"\u5C55\u793A\u8BC1\u4E66\u7533\u8BF7",key:"cert_apply"},{title:"\u5C55\u793A\u77E5\u8BC6\u56FE\u8C31",key:"knowledge_graph"}]}],[os,Lh]=(0,Ne.useState)([]),[Au,kr]=(0,Ne.useState)(!1),Kh=os.length>0&&os.length<4,[yt,Bn]=(0,Ne.useState)(1),[Kl,ch]=(0,Ne.useState)([]),[$u,Nu]=(0,Ne.useState)([]);(0,Ne.useEffect)(()=>{var fi;Tu(),Wh(),Nl.current=Mo.pathId,$h(!!Nl.current),(0,xe.Dk)((fi=_i==null?void 0:_i.setting)==null?void 0:fi.name),Ro.setFieldsValue({learning_notes_title:"\u8BFE\u7A0B\u987B\u77E5"}),Nl.current&&Ns()},[]);const Tu=()=>Ho(void 0,null,function*(){const fi=yield(0,Ge.ZP)("/api/disciplines.json",{method:"get",params:{source:"subject"}});ch(fi.disciplines)}),Wh=()=>Ho(void 0,null,function*(){ru(!0);const fi=yield zt({type:"newCourse/getSchoolOption",payload:{display_aliases:!0}});ru(!1),Ec(fi==null?void 0:fi.schools),Rc(fi==null?void 0:fi.schools)}),Du=()=>{if(Ds.get("username")){dt.history.push(`/users/${Ds.get("username")}/paths`);return}dt.history.push(vr?`/paths/${Nl.current}`:"/paths")},Ns=()=>Ho(void 0,null,function*(){var fi,po,Vo,qo,Ja,Zs,mu,ka,sl,ga,ts,ss,ws,Ta,vu,Ni,ou,sa;const mo=yield zt({type:"newCourse/getEditCourseData",payload:{id:Nl.current}});if(mo){let Mh={name:mo.name,name_en:mo.name_en,intro:mo.description,content:(fi=mo==null?void 0:mo.toast)==null?void 0:fi.content,notice:mo.learning_notes,school_id:mo==null?void 0:mo.school,learning_notes_title:mo.learning_notes_title||"\u8BFE\u7A0B\u987B\u77E5"};mo.disciplines&&mo.disciplines.length>0&&Nu(mo.disciplines),Ro.setFieldsValue(Mh),Hl((po=mo==null?void 0:mo.toast)==null?void 0:po.is_open),ec((Vo=mo==null?void 0:mo.toast)==null?void 0:Vo.open_num),wh(mo==null?void 0:mo.cust_seq),Bi(mo==null?void 0:mo.show_spoc),iu(mo==null?void 0:mo.show_history),pu(mo==null?void 0:mo.show_course_section),Gl(mo==null?void 0:mo.allow_download),ko(mo==null?void 0:mo.show_tag),kr(mo==null?void 0:mo.allow_set_subject_summary),mo!=null&&mo.show_chapter&&os.push("chapter"),mo!=null&&mo.show_charts&&os.push("charts"),mo!=null&&mo.show_cert_apply&&os.push("cert_apply"),mo!=null&&mo.show_knowledge_graph&&os.push("knowledge_graph"),mo!=null&&mo.show_chapter&&(mo!=null&&mo.show_charts)&&(mo!=null&&mo.show_cert_apply)&&(mo!=null&&mo.show_knowledge_graph)&&os.push("all"),Lh([...os]),((qo=mo==null?void 0:mo.attachments)==null?void 0:qo.length)>0&&Cs([{uid:(Zs=(Ja=mo==null?void 0:mo.attachments)==null?void 0:Ja[0])==null?void 0:Zs.id,name:(ka=(mu=mo==null?void 0:mo.attachments)==null?void 0:mu[0])==null?void 0:ka.title,response:{id:(ga=(sl=mo==null?void 0:mo.attachments)==null?void 0:sl[0])==null?void 0:ga.id}}]),((ts=mo==null?void 0:mo.attachments_b)==null?void 0:ts.length)>0&&lh([{uid:(ws=(ss=mo==null?void 0:mo.attachments_b)==null?void 0:ss[0])==null?void 0:ws.id,name:(vu=(Ta=mo==null?void 0:mo.attachments_b)==null?void 0:Ta[0])==null?void 0:vu.title,response:{id:(ou=(Ni=mo==null?void 0:mo.attachments_b)==null?void 0:Ni[0])==null?void 0:ou.id}}]),Ls({name:mo.name,intro:mo.description,notice:mo.learning_notes,content:(sa=mo==null?void 0:mo.toast)==null?void 0:sa.content})}}),to=fi=>Ho(void 0,null,function*(){var po,Vo,qo,Ja;const{name:Zs,intro:mu,notice:ka,name_en:sl,learning_notes_title:ga,sub_discipline_ids:ts,school_id:ss}=fi||{},ws=vr?"newCourse/editCourse":"newCourse/submitCourse";let Ta=!1,vu=null;if(uh.map(sa=>{ss===sa.name&&(Ta=!0,vu=sa.id)}),!Ta)return $e.ZP.error(`\u672A\u627E\u5230\u5305\u542B'${ss}'\u7684\u53D1\u5E03\u5355\u4F4D`);let Ni={id:Nl.current,name:Zs,name_en:sl,description:mu,learning_notes:ka,cust_seq:Tl,show_spoc:Ju,school_id:vu,show_tag:Ph,show_history:Ch,show_course_section:Qu,allow_download:dc,learning_notes_title:ga,attachment_ids:[(Vo=(po=Ms==null?void 0:Ms[0])==null?void 0:po.response)==null?void 0:Vo.id],attachment_ids_b:[(Ja=(qo=_l==null?void 0:_l[0])==null?void 0:qo.response)==null?void 0:Ja.id],sub_discipline_ids:ts,subject_toast_attributes:{is_open:yl,open_num:Eh,content:fi.content}};Au&&(Ni.show_chapter=os==null?void 0:os.includes("chapter"),Ni.show_charts=os==null?void 0:os.includes("charts"),Ni.show_cert_apply=os==null?void 0:os.includes("cert_apply"),Ni.show_knowledge_graph=os==null?void 0:os.includes("knowledge_graph"));const ou=yield zt({type:ws,payload:Ra({},Ni)});ou!=null&&ou.subject_id&&dt.history.push(`/paths/${ou.subject_id}`)}),Bl=()=>{zt({type:"newCourse/setActionTabs",payload:{key:"NewCourse-AppplySchool"}})},Pl=fi=>{Wh(),Ls(ca(Ra({},Ro.getFieldsValue()),{school_id:fi}))},xs=(fi,po)=>{Lh(fi)};return vt.createElement("div",{className:me.wrap},vt.createElement("div",{className:me.bg},vt.createElement("div",{className:me.crumbs},vt.createElement("span",null,"\u5B9E\u8DF5\u8BFE\u7A0B"),vt.createElement("i",{className:"iconfont icon-zhankai1"}),vt.createElement("b",null,vr?"\u7F16\u8F91":"\u521B\u5EFA","\u5B9E\u8DF5\u8BFE\u7A0B")),vt.createElement("div",{className:me.titleWrap},vt.createElement("span",null,vr?"\u7F16\u8F91":"\u521B\u5EFA","\u5B9E\u8DF5\u8BFE\u7A0B"),vt.createElement("b",{onClick:Du},"\u8FD4\u56DE")),!vr&&vt.createElement(Di.tp,{style:{marginTop:"20px"},dataSource:[{name:"\u624B\u52A8\u521B\u5EFA",id:1},{name:"\u667A\u80FD\u521B\u5EFA",id:2}],value:yt,onChange:fi=>Ho(void 0,null,function*(){var po,Vo,qo;if(Bn(fi),fi==1)window.clearInterval(vs.current),Hh.resetFields();else{al();const Ja=yield(0,Ge.ZP)("/api/subject_generations/get.json",{method:"get"});(Ja==null?void 0:Ja.status)==0&&(nc(Ja==null?void 0:Ja.data),(((po=Ja==null?void 0:Ja.data)==null?void 0:po.state)==1||((Vo=Ja==null?void 0:Ja.data)==null?void 0:Vo.state)==-1)&&window.clearInterval(vs.current),((qo=Ja==null?void 0:Ja.data)==null?void 0:qo.state)==0&&(vs.current=setInterval(()=>{hh()},1e3)))}})}),yt==1&&vt.createElement(Ie.default,{form:Ro,className:me.formWrap,scrollToFirstError:!0,layout:"vertical",colon:!1,onValuesChange:()=>{const fi=Ro.getFieldsValue();"school_id"in fi&&Rc(uh.filter(po=>{var Vo,qo,Ja;return((Ja=(Vo=po==null?void 0:po.name)==null?void 0:Vo.toUpperCase())==null?void 0:Ja.indexOf((qo=fi==null?void 0:fi.school_id)==null?void 0:qo.toUpperCase()))!==-1})),Ls(Ra({},fi))},onFinish:to},vt.createElement("div",{className:me.fieldWrap},vt.createElement(Ie.default.Item,{extra:vt.createElement("div",{className:"tr c-grey-333 font12 mt3"},`${((Yt=Ma.name)==null?void 0:Yt.length)||0}/60`),name:"name",label:"\u5B9E\u8DF5\u8BFE\u7A0B\u540D\u79F0",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5B9E\u8DF5\u8BFE\u7A0B\u540D\u79F0"}]},vt.createElement(_r,{maxLength:60,placeholder:"\u4F8B\u5982\uFF1A\u5927\u5B66\u8BA1\u7B97\u673A\u57FA\u7840 \u2014\u2014 \u8BA1\u7B97\u601D\u7EF4"})),vt.createElement(Ie.default.Item,{style:{marginTop:"-24px"},name:"name_en",label:"\u82F1\u6587\u8BFE\u7A0B\u540D\u79F0",extra:vt.createElement("div",{className:"tr c-grey-333 font12 mt3"},`${((ci=Ma.name_en)==null?void 0:ci.length)||0}/200`),rules:[{message:"\u8BF7\u8F93\u5165\u82F1\u6587\u8BFE\u7A0B\u540D\u79F0"}]},vt.createElement(_r,{maxLength:200,placeholder:"College Computer Fundamentals - Computational Thinking"})),vt.createElement(Ie.default.Item,{name:"sub_discipline_ids",label:vt.createElement("div",{style:{display:"flex",justifyContent:"space-between",width:1200}},vt.createElement("div",null,"\u65B9\u5411&\u8BFE\u7A0B"),vt.createElement("div",{style:{color:"#9096A3",position:"relative",left:12}},"\u6CA1\u6709\u5408\u9002\u7684\u65B9\u5411&\u8BFE\u7A0B\uFF1F",vt.createElement("span",{style:{color:"#3061D0",cursor:"pointer"},onClick:()=>tc(!0)},"\u8054\u7CFB\u6559\u7814\u52A9\u7406"))),style:{marginTop:"-24px"}},vt.createElement(Wt,{defaultValue:$u,dataSource:Kl,onChange:fi=>Ro.setFieldsValue({sub_discipline_ids:fi})})),vt.createElement(Ie.default.Item,{label:"\u53D1\u5E03\u5355\u4F4D",name:"school_id",wrapperCol:{span:24},extra:!Dl&&Ma.school_id&&!(uh!=null&&uh.find(fi=>fi.name===Ma.school_id))&&vt.createElement("div",{className:me.schoolHintWrap},vt.createElement("span",{className:me.colorCDCDCD},"\u672A\u627E\u5230\u5305\u542B\u201C",Ma.school_id,"\u201D\u7684\u53D1\u5E03\u5355\u4F4D\uFF0C\u5982\u6709\u9700\u8981\uFF0C\u8BF7",vt.createElement("span",{style:{color:"blue",cursor:"pointer"},onClick:()=>{var fi,po;Mt.default.info({title:"\u8054\u7CFB\u5E73\u53F0\u8FD0\u8425",width:400,icon:null,centered:!0,content:vt.createElement("div",{style:{textAlign:"center"}},vt.createElement("div",{style:{textAlign:"left"}},"\u8BF7\u626B\u7801\u6216\u641C\u7D22\u52A0\u5165\u5934\u6B4C\u5B98\u65B9\u4EA4\u6D41QQ\u7FA4\uFF1A",(fi=_i==null?void 0:_i.setting)==null?void 0:fi.homepage_tea_qq_number,"\uFF0C\u8054\u7CFB\u7FA4\u5185\u7684\u8FD0\u8425\u8FDB\u884C\u54A8\u8BE2\u548C\u7533\u8BF7\u65B0\u589E\u5B66\u6821\u540D\u79F0\u3002"),vt.createElement("img",{src:`${Ee.Z.IMG_SERVER}/${(po=_i==null?void 0:_i.setting)==null?void 0:po.homepage_tea_qq_qrcode_url}`,style:{width:"170px",height:"170px",marginTop:"20px"}})),okText:"\u6211\u77E5\u9053\u4E86"})}},"\u8054\u7CFB\u5E73\u53F0\u8FD0\u8425"),"\u7533\u8BF7\u65B0\u589E")),rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u53D1\u5E03\u5355\u4F4D"}]},vt.createElement(Pt.Z,{placeholder:"\u8BF7\u8F93\u5165\u53D1\u5E03\u5355\u4F4D",showSearch:!0,size:"large"},zh.map((fi,po)=>vt.createElement(we,{key:po,value:fi.name},fi.name))))),vt.createElement("div",{className:me.mdWrap},vt.createElement(Ie.default.Item,{name:"intro",label:"\u7B80\u4ECB",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5B9E\u8DF5\u8BFE\u7A0B\u7684\u7B80\u4ECB"},{whitespace:!0,message:"\u8BF7\u8F93\u5165\u5B9E\u8DF5\u8BFE\u7A0B\u7684\u7B80\u4ECB"},{max:65e3,message:"\u5B9E\u8DF5\u8BFE\u7A0B\u7684\u7B80\u4ECB\u6700\u5927\u9650\u523665000\u4E2A\u5B57\u7B26"}]},vt.createElement(pe.Z,{watch:!0,defaultValue:Ma.intro}))),vt.createElement("div",{className:me.mdWrap},vt.createElement(wt.Z,{align:"top",className:"mb10 mt10"},vt.createElement(Qt.Z,null,vt.createElement("span",{className:"c-red mr10"},"*")),vt.createElement(Qt.Z,{flex:"1"},vt.createElement(Ie.default.Item,{name:"learning_notes_title",label:"",style:{marginBottom:0},rules:[{required:!0,message:"\u8BF7\u8F93\u8BFE\u7A0B\u987B\u77E5\u6807\u9898"},{max:15,message:"\u8BF7\u8F93\u8BFE\u7A0B\u987B\u77E5\u6807\u9898\u6700\u5927\u9650\u523615\u4E2A\u5B57\u7B26"}]},vt.createElement(Ut.default,{style:{height:38},placeholder:"\u8BF7\u8F93\u5165"})))),vt.createElement(Ie.default.Item,{name:"notice",label:"",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5B9E\u8DF5\u8BFE\u7A0B\u7684\u8BFE\u7A0B\u987B\u77E5"},{whitespace:!0,message:"\u8BF7\u8F93\u5165\u5B9E\u8DF5\u8BFE\u7A0B\u7684\u8BFE\u7A0B\u987B\u77E5"},{max:65e3,message:"\u5B9E\u8DF5\u8BFE\u7A0B\u7684\u8BFE\u7A0B\u987B\u77E5\u6700\u5927\u9650\u523665000\u4E2A\u5B57\u7B26"}]},vt.createElement(pe.Z,{insertTemp:"1",watch:!0,defaultValue:Ma.notice}))),vt.createElement("div",{className:me.mdWrap},vt.createElement("div",{style:{display:"flex",alignItems:"center"}},vt.createElement(It.Z,{checked:yl,style:{marginRight:11,minWidth:32},onChange:fi=>{Hl(fi)}}),vt.createElement("span",{className:me.spanText},"\u8BFE\u7A0B\u516C\u544A",vt.createElement("span",null,"\uFF08\u652F\u6301\u8001\u5E08\u81EA\u5B9A\u4E49\u516C\u544A\u5185\u5BB9\uFF0C\u4EE5\u5F39\u6846\u5F62\u5F0F\u63D0\u9192\u8BFE\u7A0B\u7684\u5B66\u4E60\u7528\u6237\uFF09"))),yl&&vt.createElement(Ie.default.Item,{style:{marginTop:10},name:"content",label:"",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5B9E\u8DF5\u8BFE\u7A0B\u7684\u8BFE\u7A0B\u63D0\u793A"},{max:1e4,message:"\u5B9E\u8DF5\u8BFE\u7A0B\u7684\u8BFE\u7A0B\u63D0\u793A\u6700\u5927\u9650\u523610000\u4E2A\u5B57\u7B26"}]},vt.createElement(pe.Z,{insertTemp:"1",watch:!0,defaultValue:Ma.content})),yl&&vt.createElement("div",{style:{marginTop:20,borderBottom:"1px solid #DBDCE0",paddingBottom:7}},vt.createElement("label",{style:{color:"#000",marginRight:10}},"\u63D0\u793A\u6B21\u6570"),vt.createElement(sn.ZP.Group,{value:Eh,onChange:fi=>{ec(fi.target.value)}},vt.createElement(sn.ZP,{className:"c-black",value:-1},"\u6BCF\u6B21"),vt.createElement(sn.ZP,{className:"ml20 c-black",value:1},"\u4E00\u6B21")))),vt.createElement("div",{className:me.mdWrap,style:{marginTop:25}},vt.createElement(Re.default,{style:{marginLeft:Au?"28px":"0"},checked:Tl,onChange:fi=>{wh(fi==null?void 0:fi.target.checked)}},vt.createElement("span",{className:me.spanText},"\u5C55\u793A\u9ED8\u8BA4\u7AE0\u8282\u5E8F\u53F7",vt.createElement("span",null,"\uFF08\u9009\u4E2D\uFF0C\u5219\u4E3A\u7AE0\u8282\u4E0B\u6240\u6709\u9879\u76EE\u6DFB\u52A0\u6392\u5E8F\u7F16\u53F7\uFF09"))),vt.createElement("br",null),vt.createElement(Re.default,{style:{marginTop:"10px",marginLeft:Au?"28px":"0"},checked:Ju,onChange:fi=>Bi(fi==null?void 0:fi.target.checked)},vt.createElement("span",{className:me.spanText},"\u81EA\u9009\u5E76\u5C55\u793ASPOC\u8BFE\u5802",vt.createElement("span",null,"\uFF08\u9009\u4E2D\uFF0C\u5219\u5728\u6559\u5B66\u56E2\u961F\u4E0B\u65B9\u6DFB\u52A0SPOC\u8BFE\u5802\u6A21\u5757\uFF0C\u56E2\u961F\u6210\u5458\u53EF\u7BA1\u7406\u6A21\u5757\u4E2D\u8BFE\u5802\u7684\u5C55\u793A\uFF09"))),vt.createElement("br",null),vt.createElement(Re.default,{style:{marginTop:"10px",marginLeft:Au?"28px":"0"},checked:Ph,onChange:fi=>ko(fi==null?void 0:fi.target.checked)},vt.createElement("span",{className:me.spanText},"\u5C55\u793A\u6280\u672F\u6807\u7B7E\u6A21\u5757",vt.createElement("span",null,"\uFF08\u9009\u4E2D\uFF0C\u5219\u5728\u6559\u5B66\u56E2\u961F\u4E0B\u65B9\u6DFB\u52A0\u6280\u672F\u6807\u7B7E\u6A21\u5757\uFF09"))),vt.createElement("br",null),vt.createElement(Re.default,{style:{marginTop:"10px",marginLeft:Au?"28px":"0"},checked:Ch,onChange:fi=>iu(fi==null?void 0:fi.target.checked)},vt.createElement("span",{className:me.spanText},"\u5C55\u793A\u5386\u53F2\u8BFE\u5802\u6A21\u5757",vt.createElement("span",null,"\uFF08\u9009\u4E2D\uFF0C\u5219\u5728\u6559\u5B66\u56E2\u961F\u4E0B\u65B9\u6DFB\u52A0\u5386\u53F2\u8BFE\u5802\u6A21\u5757\uFF0C\u56E2\u961F\u6210\u5458\u53EF\u7BA1\u7406\u6A21\u5757\u4E2D\u8BFE\u5802\u7684\u5C55\u793A\uFF09"))),vt.createElement("br",null),vt.createElement(Re.default,{style:{marginTop:"10px",marginLeft:Au?"28px":"0"},checked:dc,onChange:fi=>Gl(fi==null?void 0:fi.target.checked)},vt.createElement("span",{className:me.spanText},"\u5141\u8BB8\u4E0B\u8F7D\u6559\u5B66\u8BFE\u4EF6",vt.createElement("span",null,"\uFF08\u9009\u4E2D\uFF0C\u5219\u5141\u8BB8\u5B66\u4E60\u7528\u6237\u4E0B\u8F7D\u8BFE\u7A0B\u7AE0\u8282\u4E2D\u4E0A\u4F20\u7684\u6559\u5B66\u8BFE\u4EF6\uFF09"))),vt.createElement("br",null),vt.createElement(Re.default,{style:{marginTop:"10px",marginLeft:Au?"28px":"0"},checked:Qu,onChange:fi=>pu(fi==null?void 0:fi.target.checked)},vt.createElement("span",{className:me.spanText},"\u9ED8\u8BA4\u5C55\u5F00\u8BFE\u7A0B\u5C0F\u8282\u5185\u5BB9",vt.createElement("span",null,"\uFF08\u9009\u4E2D\uFF0C\u5219\u7528\u6237\u5728\u8FDB\u5165\u662F\u5C06\u8BFE\u7A0B\u8BE6\u60C5\u9875\u9762\u65F6\uFF0C\u9ED8\u8BA4\u5C55\u5F00\u6240\u6709\u5C0F\u8282\u5185\u5BB9\uFF09"))),vt.createElement("br",null),Au&&vt.createElement(ne.default,{style:{marginTop:"10px"},showIcon:!1,className:me.tree,defaultExpandAll:!0,treeData:Ss,onCheck:(fi,po)=>{xs(fi,po)},titleRender:fi=>vt.createElement(Re.default,{checked:os==null?void 0:os.includes(fi.key),indeterminate:fi.key==="all"?Kh:!1,onChange:po=>{const Vo=os==null?void 0:os.indexOf(fi.key);if(Vo>-1)if(fi.key==="all")os.splice(0);else{os.splice(Vo,1);const qo=os==null?void 0:os.indexOf("all");qo>-1&&os.splice(qo,1)}else fi.key==="all"?os.splice(0,os.length,"all","chapter","charts","cert_apply","knowledge_graph"):(os.push(fi.key),os.length>=4&&!(os!=null&&os.includes("all"))&&os.push("all"));console.log("checkedValueList--",os),Lh([...os])}},fi.title)}),vt.createElement("div",{className:"mt10"},vt.createElement("div",{className:"c-black mb10"},"\u81EA\u5B9A\u4E49\u9876\u90E8\u80CC\u666F\u56FE"),vt.createElement(te.default,{action:Ee.Z.API_SERVER+"/api/attachments.json",withCredentials:!0,fileList:Ms,onChange:fi=>{var po,Vo;const qo=(fi==null?void 0:fi.file.size)/1024/1024<2;if(!((po=fi.fileList)!=null&&po.length))return!1;Cs(qo?(Vo=fi==null?void 0:fi.fileList)==null?void 0:Vo.slice(-1):[...Ms])},beforeUpload:fi=>{const po=fi.type==="image/jpeg"||fi.type==="image/png";if(!po)return $e.ZP.error("\u53EA\u80FD\u4E0A\u4F20jpg \u6216\u8005png\u56FE\u7247"),!1;const Vo=fi.size/1024/1024<2;return Vo?po&&Vo:($e.ZP.error("\u6587\u4EF6\u5927\u5C0F\u4E0D\u80FD\u5927\u4E8E2m"),!1)},onRemove:fi=>{Cs([])}},vt.createElement("div",{className:me.aBtn},"\u4E0A\u4F20\u56FE\u7247"),vt.createElement("span",{style:{color:"#5F6367",pointerEvents:"none"}},"\uFF08\u672C\u9879\u975E\u5FC5\u9700\u3002\u5982\u4E0D\u4E0A\u4F20\uFF0C\u5219\u4F7F\u7528\u7CFB\u7EDF\u9ED8\u8BA4\u56FE\u7247\uFF1B\u5982\u4E0A\u4F20\uFF0C\u8BF7\u9009\u62E9jpg\u3001png\u683C\u5F0F\uFF0C\u5927\u5C0F\u4E0D\u8D85\u8FC72M\uFF0C\u5EFA\u8BAE\u5C3A\u5BF81920*240\u50CF\u7D20\uFF09"))),vt.createElement("div",{className:"mt10"},vt.createElement("div",{className:"c-black mb10"},"\u81EA\u5B9A\u4E49\u9876\u90E8\u5185\u5BB9\u56FE"),vt.createElement(te.default,{action:Ee.Z.API_SERVER+"/api/attachments.json",withCredentials:!0,fileList:_l,onChange:fi=>{var po,Vo;const qo=(fi==null?void 0:fi.file.size)/1024/1024<2;if(!((po=fi.fileList)!=null&&po.length))return!1;lh(qo?(Vo=fi==null?void 0:fi.fileList)==null?void 0:Vo.slice(-1):[..._l])},beforeUpload:fi=>{const po=fi.type==="image/jpeg"||fi.type==="image/png";if(!po)return $e.ZP.error("\u53EA\u80FD\u4E0A\u4F20jpg \u6216\u8005png\u56FE\u7247"),!1;const Vo=fi.size/1024/1024<2;return Vo?po&&Vo:($e.ZP.error("\u6587\u4EF6\u5927\u5C0F\u4E0D\u80FD\u5927\u4E8E2m"),!1)},onRemove:fi=>{lh([])}},vt.createElement("div",{className:me.aBtn},"\u4E0A\u4F20\u56FE\u7247"),vt.createElement("span",{style:{color:"#5F6367",pointerEvents:"none"}},"\uFF08\u672C\u9879\u975E\u5FC5\u9700\u3002\u5982\u4E0D\u4E0A\u4F20\uFF0C\u5219\u4F7F\u7528\u7CFB\u7EDF\u9ED8\u8BA4\u56FE\u7247\uFF1B\u5982\u4E0A\u4F20\uFF0C\u8BF7\u9009\u62E9jpg\u3001png\u683C\u5F0F\uFF0C\u5927\u5C0F\u4E0D\u8D85\u8FC72M\uFF0C\u5EFA\u8BAE\u5C3A\u5BF81200*240\u50CF\u7D20\uFF09")))),vt.createElement("div",{className:me.backgroundFa},vt.createElement("div",{className:me.bBtn,onClick:Du},"\u53D6\u6D88"),vt.createElement(he.ZP,{className:me.cBtn,onClick:()=>Ro.submit(),loading:jt["newCourse/editCourse"]||jt["newCourse/submitCourse"]},"\u63D0\u4EA4 "))),yt==2&&vt.createElement("div",{className:me.add_ai},vt.createElement("div",{style:{margin:"20px 0"}},"\u6839\u636E\u60A8\u4E0A\u4F20\u7684\u8D44\u6599\u81EA\u52A8\u751F\u6210\u8BFE\u7A0B\u7B80\u4ECB\u3001\u8BFE\u7A0B\u76EE\u6807\u3001\u8BFE\u7A0B\u5927\u7EB2\u3001\u7AE0\u8282\u63CF\u8FF0\u3001\u8BFE\u7A0B\u8D44\u6E90\u3001\u77E5\u8BC6\u70B9\u3001\u77E5\u8BC6\u56FE\u8C31\u7B49\u5185\u5BB9"),vt.createElement(Ie.default,{form:Hh,scrollToFirstError:!0,colon:!1},vt.createElement(Ie.default.Item,{name:"file_ids"},vt.createElement(Zt.Z,{accept:".pdf, .docx, .doc, .xlsx, .xls, .txt, .md",maxSize:150,number:99,uploadText:"\u5EFA\u8BAE\u4E0A\u4F20\u8BFE\u7A0B\u4E66\u7C4D\u3001\u8BFE\u7A0B\u6559\u5B66\u5927\u7EB2\u7B49\u7C7B\u4F3C\u6587\u4EF6",setFileProgress:Us,showFileProgress:!0}))),((vi=[-1,0,1])==null?void 0:vi.includes(tn==null?void 0:tn.state))&&vt.createElement("div",{className:me.paths_content},vt.createElement("div",{className:me.content_header},vt.createElement("i",{className:"iconfont icon-ziyuanshibie font22 mb10",style:{color:(ai=[1,2,3,4,5,6,7,8])!=null&&ai.includes(tn==null?void 0:tn.phase)?"#2a56ca":"#bdbdbd"}}),vt.createElement("i",{className:"iconfont icon-kechengjibenxinxi font22 mb10",style:{color:(Kt=[2,3,4,5,6,7,8])!=null&&Kt.includes(tn==null?void 0:tn.phase)?"#2a56ca":"#bdbdbd"}}),vt.createElement("i",{className:"iconfont icon-kechengneirongziyuan font22 mb10",style:{color:(wn=[5,6,7,8])!=null&&wn.includes(tn==null?void 0:tn.phase)?"#2a56ca":"#bdbdbd"}})),vt.createElement("div",{style:{display:"flex",position:"relative"}},vt.createElement("div",{className:me.header_box,style:{left:0}},vt.createElement("img",{src:(pi=[1,2,3,4,5,6,7,8])!=null&&pi.includes(tn==null?void 0:tn.phase)?_n:ti}),vt.createElement("div",{className:me.header_text,style:{color:(ji=[1,2,3,4,5,6,7,8])!=null&&ji.includes(tn==null?void 0:tn.phase)?"#fff":"#9096A3"}},(Rn=[1,2,3,4,5,6,7,8])!=null&&Rn.includes(tn==null?void 0:tn.phase)?"\u8D44\u6E90\u8BC6\u522B \u5DF2\u5B8C\u6210":"\u8D44\u6E90\u8BC6\u522B"),vt.createElement("div",{style:{textAlign:"center",width:"386px"}},vt.createElement("img",{src:oi,style:{width:"233px",height:"179px"}}))),vt.createElement("div",{className:me.header_box,style:{left:"380px"}},vt.createElement("img",{src:(Dt=[2,3,4,5,6,7,8])!=null&&Dt.includes(tn==null?void 0:tn.phase)?Ri:ti}),vt.createElement("div",{className:me.header_text,style:{color:(wi=[2,3,4,5,6,7,8])!=null&&wi.includes(tn==null?void 0:tn.phase)?"#fff":"#9096A3"}},(gr=[2,3,4,5,6,7,8])!=null&&gr.includes(tn==null?void 0:tn.phase)?`\u8BFE\u7A0B\u57FA\u672C\u4FE1\u606F\u751F\u6210 ${(eo=[2,3,4])!=null&&eo.includes(tn==null?void 0:tn.phase)?"\u8FDB\u884C\u4E2D":"\u5DF2\u5B8C\u6210"}`:"\u8BFE\u7A0B\u57FA\u672C\u4FE1\u606F\u751F\u6210 \u7B49\u5F85\u4E2D"),vt.createElement("div",{className:me.lianjie}),vt.createElement("div",{style:{textAlign:"center"}},vt.createElement("div",{className:me.buzou_box},vt.createElement("div",{style:{display:"flex",alignItems:"center"}},((kn=[0,1])==null?void 0:kn.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}}),((Xi=[2])==null?void 0:Xi.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)!=-1&&vt.createElement(le.Z,{indicator:vt.createElement(Ei.Z,{spin:!0}),size:"small"},vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}})),((Lo=[2])==null?void 0:Lo.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)==-1&&vt.createElement("i",{className:"iconfont icon-cuowu font16",style:{color:"#E30000"}}),((La=[3,4,5,6,7,8])==null?void 0:La.includes(tn==null?void 0:tn.phase))&&vt.createElement("i",{className:"iconfont icon-wancheng3 font16",style:{color:"#83B6FF"}}),vt.createElement("div",{style:{margin:"0 10px",color:($o=[0,1])!=null&&$o.includes(tn==null?void 0:tn.phase)?"#9096A3":(qi=[2])!=null&&qi.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},"\u8BFE\u7A0B\u7B80\u4ECB\u751F\u6210"),vt.createElement("div",{style:{color:(Zi=[0,1])!=null&&Zi.includes(tn==null?void 0:tn.phase)?"#9096A3":(cr=[2])!=null&&cr.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},(Co=[0,1])!=null&&Co.includes(tn==null?void 0:tn.phase)?"\u7B49\u5F85\u4E2D":(Zo=[2])!=null&&Zo.includes(tn==null?void 0:tn.phase)?(tn==null?void 0:tn.state)==-1?"\u751F\u6210\u5931\u8D25":"\u8FDB\u884C\u4E2D":"\u5DF2\u5B8C\u6210")),vt.createElement("div",{style:{width:"2px",height:"30px",background:(ri=[0,1,2])!=null&&ri.includes(tn==null?void 0:tn.phase)?"rgba(48,97,208,0.1)":"#83B6FF",marginLeft:"7px"}}),vt.createElement("div",{style:{display:"flex",alignItems:"center"}},((Lr=[0,1,2])==null?void 0:Lr.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}}),((ml=[3])==null?void 0:ml.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)!=-1&&vt.createElement(le.Z,{indicator:vt.createElement(Ei.Z,{spin:!0}),size:"small"},vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}})),((Fs=[3])==null?void 0:Fs.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)==-1&&vt.createElement("i",{className:"iconfont icon-cuowu font16",style:{color:"#E30000"}}),((gs=[4,5,6,7,8])==null?void 0:gs.includes(tn==null?void 0:tn.phase))&&vt.createElement("i",{className:"iconfont icon-wancheng3 font16",style:{color:"#83B6FF"}}),vt.createElement("div",{style:{margin:"0 10px",color:(Vt=[0,1,2])!=null&&Vt.includes(tn==null?void 0:tn.phase)?"#9096A3":(Kr=[3])!=null&&Kr.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},"\u8BFE\u7A0B\u76EE\u6807\u751F\u6210"),vt.createElement("div",{style:{color:(Ko=[0,1,2])!=null&&Ko.includes(tn==null?void 0:tn.phase)?"#9096A3":(Er=[3])!=null&&Er.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},(Wa=[0,1,2])!=null&&Wa.includes(tn==null?void 0:tn.phase)?"\u7B49\u5F85\u4E2D":(Wo=[3])!=null&&Wo.includes(tn==null?void 0:tn.phase)?(tn==null?void 0:tn.state)==-1?"\u751F\u6210\u5931\u8D25":"\u8FDB\u884C\u4E2D":"\u5DF2\u5B8C\u6210")),vt.createElement("div",{style:{width:"2px",height:"30px",background:(ea=[0,1,2,3])!=null&&ea.includes(tn==null?void 0:tn.phase)?"rgba(48,97,208,0.1)":"#83B6FF",marginLeft:"7px"}}),vt.createElement("div",{style:{display:"flex",alignItems:"center"}},((fo=[0,1,2,3])==null?void 0:fo.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}}),((Oo=[4])==null?void 0:Oo.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)!=-1&&vt.createElement(le.Z,{indicator:vt.createElement(Ei.Z,{spin:!0}),size:"small"},vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}})),((xa=[4])==null?void 0:xa.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)==-1&&vt.createElement("i",{className:"iconfont icon-cuowu font16",style:{color:"#E30000"}}),((An=[5,6,7,8])==null?void 0:An.includes(tn==null?void 0:tn.phase))&&vt.createElement("i",{className:"iconfont icon-wancheng3 font16",style:{color:"#83B6FF"}}),vt.createElement("div",{style:{margin:"0 10px",color:(Ya=[0,1,2,3])!=null&&Ya.includes(tn==null?void 0:tn.phase)?"#9096A3":(Pn=[4])!=null&&Pn.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},"\u7AE0\u8282\u53CA\u63CF\u8FF0\u751F\u6210"),vt.createElement("div",{style:{color:(jo=[0,1,2,3])!=null&&jo.includes(tn==null?void 0:tn.phase)?"#9096A3":(Ws=[4])!=null&&Ws.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},(qa=[0,1,2,3])!=null&&qa.includes(tn==null?void 0:tn.phase)?"\u7B49\u5F85\u4E2D":(bl=[4])!=null&&bl.includes(tn==null?void 0:tn.phase)?(tn==null?void 0:tn.state)==-1?"\u751F\u6210\u5931\u8D25":"\u8FDB\u884C\u4E2D":"\u5DF2\u5B8C\u6210"),((Xa=[5,6,7,8])==null?void 0:Xa.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{marginLeft:"10px",color:"#232B40"}},"\u5171\u751F\u6210",vt.createElement("span",{style:{color:"#3061D0"}},tn==null?void 0:tn.stage_size),"\u4E2A\u7AE0\u8282"))))),vt.createElement("div",{className:me.header_box,style:{left:"760px"}},vt.createElement("img",{src:(_o=[5,6,7,8])!=null&&_o.includes(tn==null?void 0:tn.phase)?Ri:ti}),vt.createElement("div",{className:me.header_text,style:{color:(Va=[5,6,7,8])!=null&&Va.includes(tn==null?void 0:tn.phase)?"#fff":"#9096A3"}},(il=[5,6,7,8])!=null&&il.includes(tn==null?void 0:tn.phase)?`\u8BFE\u7A0B\u5185\u5BB9\u8D44\u6E90\u751F\u6210 ${(Na=[5,6,7])!=null&&Na.includes(tn==null?void 0:tn.phase)?"\u8FDB\u884C\u4E2D":"\u5DF2\u5B8C\u6210"}`:"\u8BFE\u7A0B\u5185\u5BB9\u8D44\u6E90\u751F\u6210 \u7B49\u5F85\u4E2D"),vt.createElement("div",{className:me.lianjie}),vt.createElement("div",{style:{textAlign:"center"}},vt.createElement("div",{className:me.buzou_box},vt.createElement("div",{style:{display:"flex",alignItems:"center"}},((Li=[0,1,2,3,4])==null?void 0:Li.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}}),((Qe=[5])==null?void 0:Qe.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)!=-1&&vt.createElement(le.Z,{indicator:vt.createElement(Ei.Z,{spin:!0}),size:"small"},vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}})),((bs=[5])==null?void 0:bs.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)==-1&&vt.createElement("i",{className:"iconfont icon-cuowu font16",style:{color:"#E30000"}}),((Ul=[6,7,8])==null?void 0:Ul.includes(tn==null?void 0:tn.phase))&&vt.createElement("i",{className:"iconfont icon-wancheng3 font16",style:{color:"#83B6FF"}}),vt.createElement("div",{style:{margin:"0 10px",color:(Zl=[0,1,2,3,4])!=null&&Zl.includes(tn==null?void 0:tn.phase)?"#9096A3":(rl=[5])!=null&&rl.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},"\u77E5\u8BC6\u70B9\u751F\u6210"),vt.createElement("div",{style:{color:(tu=[0,1,2,3,4])!=null&&tu.includes(tn==null?void 0:tn.phase)?"#9096A3":(Il=[5])!=null&&Il.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},(Hu=[0,1,2,3,4])!=null&&Hu.includes(tn==null?void 0:tn.phase)?"\u7B49\u5F85\u4E2D":(nu=[5])!=null&&nu.includes(tn==null?void 0:tn.phase)?(tn==null?void 0:tn.state)==-1?"\u751F\u6210\u5931\u8D25":"\u8FDB\u884C\u4E2D":"\u5DF2\u5B8C\u6210"),((Ua=[6,7,8])==null?void 0:Ua.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{marginLeft:"10px",color:"#232B40"}},"\u5171\u751F\u6210",vt.createElement("span",{style:{color:"#3061D0"}},tn==null?void 0:tn.resource_size),"\u4E2A\u77E5\u8BC6\u70B9")),vt.createElement("div",{style:{width:"2px",height:"30px",background:(ps=[0,1,2,3,4,5])!=null&&ps.includes(tn==null?void 0:tn.phase)?"rgba(48,97,208,0.1)":"#83B6FF",marginLeft:"7px"}}),vt.createElement("div",{style:{display:"flex",alignItems:"center"}},((Or=[0,1,2,3,4,5])==null?void 0:Or.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}}),((Pr=[6])==null?void 0:Pr.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)!=-1&&vt.createElement(le.Z,{indicator:vt.createElement(Ei.Z,{spin:!0}),size:"small"},vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}})),((so=[6])==null?void 0:so.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)==-1&&vt.createElement("i",{className:"iconfont icon-cuowu font16",style:{color:"#E30000"}}),((fn=[7,8])==null?void 0:fn.includes(tn==null?void 0:tn.phase))&&vt.createElement("i",{className:"iconfont icon-wancheng3 font16",style:{color:"#83B6FF"}}),vt.createElement("div",{style:{margin:"0 10px",color:(jr=[0,1,2,3,4,5])!=null&&jr.includes(tn==null?void 0:tn.phase)?"#9096A3":(Ao=[6])!=null&&Ao.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},"\u77E5\u8BC6\u70B9\u8D44\u6E90\u751F\u6210"),vt.createElement("div",{style:{color:($a=[0,1,2,3,4,5])!=null&&$a.includes(tn==null?void 0:tn.phase)?"#9096A3":(Ia=[6])!=null&&Ia.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},(ms=[0,1,2,3,4,5])!=null&&ms.includes(tn==null?void 0:tn.phase)?"\u7B49\u5F85\u4E2D":(Vs=[6])!=null&&Vs.includes(tn==null?void 0:tn.phase)?(tn==null?void 0:tn.state)==-1?"\u751F\u6210\u5931\u8D25":"\u8FDB\u884C\u4E2D":"\u5DF2\u5B8C\u6210"),((el=[7,8])==null?void 0:el.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{marginLeft:"10px",color:"#232B40"}},"\u5171\u751F\u6210",vt.createElement("span",{style:{color:"#3061D0"}},tn==null?void 0:tn.resource_size),"\u4E2A\u8D44\u6E90")),vt.createElement("div",{style:{width:"2px",height:"30px",background:(vl=[0,1,2,3,4,5,6])!=null&&vl.includes(tn==null?void 0:tn.phase)?"rgba(48,97,208,0.1)":"#83B6FF",marginLeft:"7px"}}),vt.createElement("div",{style:{display:"flex",alignItems:"center"}},((Gu=[0,1,2,3,4,5,6])==null?void 0:Gu.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}}),((Fu=[7])==null?void 0:Fu.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)!=-1&&vt.createElement(le.Z,{indicator:vt.createElement(Ei.Z,{spin:!0}),size:"small"},vt.createElement("div",{style:{width:"16px",height:"16px",borderRadius:"8px",border:"2px solid rgba(48,97,208,0.1)"}})),((Xt=[7])==null?void 0:Xt.includes(tn==null?void 0:tn.phase))&&(tn==null?void 0:tn.state)==-1&&vt.createElement("i",{className:"iconfont icon-cuowu font16",style:{color:"#E30000"}}),((Ll=[8])==null?void 0:Ll.includes(tn==null?void 0:tn.phase))&&vt.createElement("i",{className:"iconfont icon-wancheng3 font16",style:{color:"#83B6FF"}}),vt.createElement("div",{style:{margin:"0 10px",color:(zl=[0,1,2,3,4,5,6])!=null&&zl.includes(tn==null?void 0:tn.phase)?"#9096A3":(fu=[7])!=null&&fu.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},"\u77E5\u8BC6\u56FE\u8C31\u751F\u6210"),vt.createElement("div",{style:{color:(As=[0,1,2,3,4,5,6])!=null&&As.includes(tn==null?void 0:tn.phase)?"#9096A3":(gu=[7])!=null&&gu.includes(tn==null?void 0:tn.phase)&&(tn==null?void 0:tn.state)==-1?"red":"#83B6FF"}},(xh=[0,1,2,3,4,5,6])!=null&&xh.includes(tn==null?void 0:tn.phase)?"\u7B49\u5F85\u4E2D":(Xu=[7])!=null&&Xu.includes(tn==null?void 0:tn.phase)?(tn==null?void 0:tn.state)==-1?"\u751F\u6210\u5931\u8D25":"\u8FDB\u884C\u4E2D":"\u5DF2\u5B8C\u6210"),((es=[8])==null?void 0:es.includes(tn==null?void 0:tn.phase))&&vt.createElement("div",{style:{marginLeft:"10px",color:"#232B40"}},"\u5171\u751F\u6210",vt.createElement("span",{style:{color:"#3061D0"}},tn==null?void 0:tn.knowledge_size),"\u4E2A\u77E5\u8BC6\u56FE\u8C31"))))))),vt.createElement(le.Z,{spinning:Ml},vt.createElement("div",{className:(tn==null?void 0:tn.state)==0||Rs?me.start_style:me.no_start_style,onClick:()=>Ho(void 0,null,function*(){var fi;if(Rs)return $e.ZP.error("\u6709\u6587\u4EF6\u672A\u4E0A\u4F20\u5B8C\u6210\uFF0C\u8BF7\u7B49\u6587\u4EF6\u4E0A\u4F20\u5B8C\u6210\u540E\u518D\u751F\u6210"),!1;if(!(0,uo.$O)())return qu(!0),!1;if((tn==null?void 0:tn.state)==-2||(tn==null?void 0:tn.state)==-1){ol(!0);let po=[];if((fi=Hh.getFieldValue("file_ids"))==null||fi.map(Vo=>{var qo,Ja;po.push(((qo=Vo==null?void 0:Vo.response)==null?void 0:qo.container_id)||((Ja=Vo==null?void 0:Vo.response)==null?void 0:Ja.id))}),(po==null?void 0:po.length)>0){const Vo=yield(0,Ge.ZP)("/api/subject_generations.json",{method:"post",body:{attachment_ids:po}});(Vo==null?void 0:Vo.status)==0&&($e.ZP.success("\u5F00\u59CB\u751F\u6210"),hh(),vs.current=setInterval(()=>{hh()},1e3))}else $e.ZP.error("\u8BF7\u4E0A\u4F20\u8BFE\u7A0B\u8D44\u6599\uFF0C\u5EFA\u8BAE\u4E0A\u4F20\u4E66\u7C4D\u3001\u8BFE\u7A0B\u6559\u5B66\u5927\u7EB2\u7B49");ol(!1)}else if((tn==null?void 0:tn.state)==1){ol(!0);const po=yield(0,Ge.ZP)("/api/subject_generations/finish.json",{method:"post",body:{id:tn==null?void 0:tn.id}});(po==null?void 0:po.status)==0&&dt.history.push(`/paths/${tn==null?void 0:tn.subject_id}`),ol(!1)}})},(tn==null?void 0:tn.state)==1?"\u5B8C\u6210\u8BFE\u7A0B\u521B\u5EFA":(tn==null?void 0:tn.state)==0?"\u8BFE\u7A0B\u751F\u6210\u4E2D\uFF0C\u8BF7\u7A0D\u540E...":(tn==null?void 0:tn.state)==-1?"\u91CD\u65B0\u751F\u6210\u8BFE\u7A0B":"\u5F00\u59CB\u751F\u6210\u8BFE\u7A0B"))),Gh&&vt.createElement("div",{style:{width:"100vw",height:"100vh",position:"fixed",top:0,left:0,background:"rgba(0,0,0,.5)",zIndex:200,display:"flex",alignItems:"center",justifyContent:"center"}},vt.createElement("div",{style:{width:"500px",height:"515px",textAlign:"center"}},vt.createElement("img",{src:fr,style:{marginLeft:"auto",display:"block",cursor:"pointer",width:"30px",height:"30px"},onClick:()=>{qu(!1)}}),vt.createElement("img",{src:wr,style:{display:"block",marginTop:"-20px",width:"460px",height:"500px"}}))),vt.createElement(rn,{schoolName:Ma.school_id,onSuccess:Pl}),vt.createElement(Hn.Z,{open:bh,onCancel:()=>{tc(!1)}})))};var bn=(0,dt.connect)(({user:on,newCourse:ln,loading:gn,globalSetting:Vn})=>({user:on,newCourse:ln,globalSetting:Vn,loading:gn.effects}))(Qn)},70757:function(jn,li,De){"use strict";De.d(li,{P:function(){return Ne}});const Ne=[{value:"\u5317\u4EAC",label:"\u5317\u4EAC",children:[{value:"\u4E1C\u57CE",label:"\u4E1C\u57CE"},{value:"\u897F\u57CE",label:"\u897F\u57CE"},{value:"\u671D\u9633",label:"\u671D\u9633"},{value:"\u4E30\u53F0",label:"\u4E30\u53F0"},{value:"\u77F3\u666F\u5C71",label:"\u77F3\u666F\u5C71"},{value:"\u6D77\u6DC0",label:"\u6D77\u6DC0"},{value:"\u95E8\u5934\u6C9F",label:"\u95E8\u5934\u6C9F"},{value:"\u623F\u5C71",label:"\u623F\u5C71"},{value:"\u901A\u5DDE",label:"\u901A\u5DDE"},{value:"\u987A\u4E49",label:"\u987A\u4E49"},{value:"\u660C\u5E73",label:"\u660C\u5E73"},{value:"\u5927\u5174",label:"\u5927\u5174"},{value:"\u5E73\u8C37",label:"\u5E73\u8C37"},{value:"\u6000\u67D4",label:"\u6000\u67D4"},{value:"\u5BC6\u4E91",label:"\u5BC6\u4E91"},{value:"\u5EF6\u5E86",label:"\u5EF6\u5E86"}]},{value:"\u4E0A\u6D77",label:"\u4E0A\u6D77",children:[{value:"\u5D07\u660E",label:"\u5D07\u660E"},{value:"\u9EC4\u6D66",label:"\u9EC4\u6D66"},{value:"\u5362\u6E7E",label:"\u5362\u6E7E"},{value:"\u5F90\u6C47",label:"\u5F90\u6C47"},{value:"\u957F\u5B81",label:"\u957F\u5B81"},{value:"\u9759\u5B89",label:"\u9759\u5B89"},{value:"\u666E\u9640",label:"\u666E\u9640"},{value:"\u95F8\u5317",label:"\u95F8\u5317"},{value:"\u8679\u53E3",label:"\u8679\u53E3"},{value:"\u6768\u6D66",label:"\u6768\u6D66"},{value:"\u95F5\u884C",label:"\u95F5\u884C"},{value:"\u5B9D\u5C71",label:"\u5B9D\u5C71"},{value:"\u5609\u5B9A",label:"\u5609\u5B9A"},{value:"\u6D66\u4E1C",label:"\u6D66\u4E1C"},{value:"\u91D1\u5C71",label:"\u91D1\u5C71"},{value:"\u677E\u6C5F",label:"\u677E\u6C5F"},{value:"\u9752\u6D66",label:"\u9752\u6D66"},{value:"\u5357\u6C47",label:"\u5357\u6C47"},{value:"\u5949\u8D24",label:"\u5949\u8D24"}]},{value:"\u5E7F\u4E1C",label:"\u5E7F\u4E1C",children:[{value:"\u5E7F\u5DDE",label:"\u5E7F\u5DDE"},{value:"\u6DF1\u5733",label:"\u6DF1\u5733"},{value:"\u73E0\u6D77",label:"\u73E0\u6D77"},{value:"\u4E1C\u839E",label:"\u4E1C\u839E"},{value:"\u4E2D\u5C71",label:"\u4E2D\u5C71"},{value:"\u4F5B\u5C71",label:"\u4F5B\u5C71"},{value:"\u60E0\u5DDE",label:"\u60E0\u5DDE"},{value:"\u6CB3\u6E90",label:"\u6CB3\u6E90"},{value:"\u6F6E\u5DDE",label:"\u6F6E\u5DDE"},{value:"\u6C5F\u95E8",label:"\u6C5F\u95E8"},{value:"\u63ED\u9633",label:"\u63ED\u9633"},{value:"\u8302\u540D",label:"\u8302\u540D"},{value:"\u6885\u5DDE",label:"\u6885\u5DDE"},{value:"\u6E05\u8FDC",label:"\u6E05\u8FDC"},{value:"\u6C55\u5934",label:"\u6C55\u5934"},{value:"\u6C55\u5C3E",label:"\u6C55\u5C3E"},{value:"\u97F6\u5173",label:"\u97F6\u5173"},{value:"\u987A\u5FB7",label:"\u987A\u5FB7"},{value:"\u9633\u6C5F",label:"\u9633\u6C5F"},{value:"\u4E91\u6D6E",label:"\u4E91\u6D6E"},{value:"\u6E5B\u6C5F",label:"\u6E5B\u6C5F"},{value:"\u8087\u5E86",label:"\u8087\u5E86"}]},{value:"\u6C5F\u82CF",label:"\u6C5F\u82CF",children:[{value:"\u5357\u4EAC",label:"\u5357\u4EAC"},{value:"\u5E38\u719F",label:"\u5E38\u719F"},{value:"\u5E38\u5DDE",label:"\u5E38\u5DDE"},{value:"\u6D77\u95E8",label:"\u6D77\u95E8"},{value:"\u6DEE\u5B89",label:"\u6DEE\u5B89"},{value:"\u6C5F\u90FD",label:"\u6C5F\u90FD"},{value:"\u6C5F\u9634",label:"\u6C5F\u9634"},{value:"\u6606\u5C71",label:"\u6606\u5C71"},{value:"\u8FDE\u4E91\u6E2F",label:"\u8FDE\u4E91\u6E2F"},{value:"\u5357\u901A",label:"\u5357\u901A"},{value:"\u542F\u4E1C",label:"\u542F\u4E1C"},{value:"\u6CAD\u9633",label:"\u6CAD\u9633"},{value:"\u5BBF\u8FC1",label:"\u5BBF\u8FC1"},{value:"\u82CF\u5DDE",label:"\u82CF\u5DDE"},{value:"\u592A\u4ED3",label:"\u592A\u4ED3"},{value:"\u6CF0\u5DDE",label:"\u6CF0\u5DDE"},{value:"\u540C\u91CC",label:"\u540C\u91CC"},{value:"\u65E0\u9521",label:"\u65E0\u9521"},{value:"\u5F90\u5DDE",label:"\u5F90\u5DDE"},{value:"\u76D0\u57CE",label:"\u76D0\u57CE"},{value:"\u626C\u5DDE",label:"\u626C\u5DDE"},{value:"\u5B9C\u5174",label:"\u5B9C\u5174"},{value:"\u4EEA\u5F81",label:"\u4EEA\u5F81"},{value:"\u5F20\u5BB6\u6E2F",label:"\u5F20\u5BB6\u6E2F"},{value:"\u9547\u6C5F",label:"\u9547\u6C5F"}]},{value:"\u91CD\u5E86",label:"\u91CD\u5E86",children:[{value:"\u4E07\u5DDE",label:"\u4E07\u5DDE"},{value:"\u6DAA\u9675",label:"\u6DAA\u9675"},{value:"\u6E1D\u4E2D",label:"\u6E1D\u4E2D"},{value:"\u5927\u6E21\u53E3",label:"\u5927\u6E21\u53E3"},{value:"\u6C5F\u5317",label:"\u6C5F\u5317"},{value:"\u6C99\u576A\u575D",label:"\u6C99\u576A\u575D"},{value:"\u4E5D\u9F99\u5761",label:"\u4E5D\u9F99\u5761"},{value:"\u5357\u5CB8",label:"\u5357\u5CB8"},{value:"\u5317\u789A",label:"\u5317\u789A"},{value:"\u4E07\u76DB",label:"\u4E07\u76DB"},{value:"\u53CC\u6322",label:"\u53CC\u6322"},{value:"\u6E1D\u5317",label:"\u6E1D\u5317"},{value:"\u5DF4\u5357",label:"\u5DF4\u5357"},{value:"\u9ED4\u6C5F",label:"\u9ED4\u6C5F"},{value:"\u957F\u5BFF",label:"\u957F\u5BFF"},{value:"\u7DA6\u6C5F",label:"\u7DA6\u6C5F"},{value:"\u6F7C\u5357",label:"\u6F7C\u5357"},{value:"\u94DC\u6881",label:"\u94DC\u6881"},{value:"\u5927\u8DB3",label:"\u5927\u8DB3"},{value:"\u8363\u660C",label:"\u8363\u660C"},{value:"\u58C1\u5C71",label:"\u58C1\u5C71"},{value:"\u6881\u5E73",label:"\u6881\u5E73"},{value:"\u57CE\u53E3",label:"\u57CE\u53E3"},{value:"\u4E30\u90FD",label:"\u4E30\u90FD"},{value:"\u57AB\u6C5F",label:"\u57AB\u6C5F"},{value:"\u6B66\u9686",label:"\u6B66\u9686"},{value:"\u5FE0\u53BF",label:"\u5FE0\u53BF"},{value:"\u5F00\u53BF",label:"\u5F00\u53BF"},{value:"\u4E91\u9633",label:"\u4E91\u9633"},{value:"\u5949\u8282",label:"\u5949\u8282"},{value:"\u5DEB\u5C71",label:"\u5DEB\u5C71"},{value:"\u5DEB\u6EAA",label:"\u5DEB\u6EAA"},{value:"\u77F3\u67F1",label:"\u77F3\u67F1"},{value:"\u79C0\u5C71",label:"\u79C0\u5C71"},{value:"\u9149\u9633",label:"\u9149\u9633"},{value:"\u5F6D\u6C34",label:"\u5F6D\u6C34"},{value:"\u6C5F\u6D25",label:"\u6C5F\u6D25"},{value:"\u5408\u5DDD",label:"\u5408\u5DDD"},{value:"\u6C38\u5DDD",label:"\u6C38\u5DDD"},{value:"\u5357\u5DDD",label:"\u5357\u5DDD"}]},{value:"\u5B89\u5FBD",label:"\u5B89\u5FBD",children:[{value:"\u5408\u80A5",label:"\u5408\u80A5"},{value:"\u5B89\u5E86",label:"\u5B89\u5E86"},{value:"\u868C\u57E0",label:"\u868C\u57E0"},{value:"\u4EB3\u5DDE",label:"\u4EB3\u5DDE"},{value:"\u5DE2\u6E56",label:"\u5DE2\u6E56"},{value:"\u6EC1\u5DDE",label:"\u6EC1\u5DDE"},{value:"\u961C\u9633",label:"\u961C\u9633"},{value:"\u8D35\u6C60",label:"\u8D35\u6C60"},{value:"\u6DEE\u5317",label:"\u6DEE\u5317"},{value:"\u6DEE\u5316",label:"\u6DEE\u5316"},{value:"\u6DEE\u5357",label:"\u6DEE\u5357"},{value:"\u9EC4\u5C71",label:"\u9EC4\u5C71"},{value:"\u4E5D\u534E\u5C71",label:"\u4E5D\u534E\u5C71"},{value:"\u516D\u5B89",label:"\u516D\u5B89"},{value:"\u9A6C\u978D\u5C71",label:"\u9A6C\u978D\u5C71"},{value:"\u5BBF\u5DDE",label:"\u5BBF\u5DDE"},{value:"\u94DC\u9675",label:"\u94DC\u9675"},{value:"\u5C6F\u6EAA",label:"\u5C6F\u6EAA"},{value:"\u829C\u6E56",label:"\u829C\u6E56"},{value:"\u5BA3\u57CE",label:"\u5BA3\u57CE"}]},{value:"\u798F\u5EFA",label:"\u798F\u5EFA",children:[{value:"\u798F\u5DDE",label:"\u798F\u5DDE"},{value:"\u53A6\u95E8",label:"\u53A6\u95E8"},{value:"\u6CC9\u5DDE",label:"\u6CC9\u5DDE"},{value:"\u6F33\u5DDE",label:"\u6F33\u5DDE"},{value:"\u9F99\u5CA9",label:"\u9F99\u5CA9"},{value:"\u5357\u5E73",label:"\u5357\u5E73"},{value:"\u5B81\u5FB7",label:"\u5B81\u5FB7"},{value:"\u8386\u7530",label:"\u8386\u7530"},{value:"\u4E09\u660E",label:"\u4E09\u660E"}]},{value:"\u7518\u8083",label:"\u7518\u8083",children:[{value:"\u5170\u5DDE",label:"\u5170\u5DDE"},{value:"\u5609\u5CEA\u5173",label:"\u5609\u5CEA\u5173"},{value:"\u767D\u94F6",label:"\u767D\u94F6"},{value:"\u5B9A\u897F",label:"\u5B9A\u897F"},{value:"\u6566\u714C",label:"\u6566\u714C"},{value:"\u7518\u5357",label:"\u7518\u5357"},{value:"\u91D1\u660C",label:"\u91D1\u660C"},{value:"\u9152\u6CC9",label:"\u9152\u6CC9"},{value:"\u4E34\u590F",label:"\u4E34\u590F"},{value:"\u5E73\u51C9",label:"\u5E73\u51C9"},{value:"\u5929\u6C34",label:"\u5929\u6C34"},{value:"\u9647\u5357",label:"\u9647\u5357"},{value:"\u6B66\u5A01",label:"\u6B66\u5A01"},{value:"\u897F\u5CF0",label:"\u897F\u5CF0"},{value:"\u5F20\u6396",label:"\u5F20\u6396"}]},{value:"\u5E7F\u897F",label:"\u5E7F\u897F",children:[{value:"\u5357\u5B81",label:"\u5357\u5B81"},{value:"\u6765\u5BBE",label:"\u6765\u5BBE"},{value:"\u767E\u8272",label:"\u767E\u8272"},{value:"\u5317\u6D77",label:"\u5317\u6D77"},{value:"\u6842\u6797",label:"\u6842\u6797"},{value:"\u9632\u57CE\u6E2F",label:"\u9632\u57CE\u6E2F"},{value:"\u8D35\u6E2F",label:"\u8D35\u6E2F"},{value:"\u6CB3\u6C60",label:"\u6CB3\u6C60"},{value:"\u8D3A\u5DDE",label:"\u8D3A\u5DDE"},{value:"\u67F3\u5DDE",label:"\u67F3\u5DDE"},{value:"\u94A6\u5DDE",label:"\u94A6\u5DDE"},{value:"\u68A7\u5DDE",label:"\u68A7\u5DDE"},{value:"\u7389\u6797",label:"\u7389\u6797"}]},{value:"\u8D35\u5DDE",label:"\u8D35\u5DDE",children:[{value:"\u8D35\u9633",label:"\u8D35\u9633"},{value:"\u5B89\u987A",label:"\u5B89\u987A"},{value:"\u6BD5\u8282",label:"\u6BD5\u8282"},{value:"\u90FD\u5300",label:"\u90FD\u5300"},{value:"\u51EF\u91CC",label:"\u51EF\u91CC"},{value:"\u516D\u76D8\u6C34",label:"\u516D\u76D8\u6C34"},{value:"\u94DC\u4EC1",label:"\u94DC\u4EC1"},{value:"\u5174\u4E49",label:"\u5174\u4E49"},{value:"\u7389\u5C4F",label:"\u7389\u5C4F"},{value:"\u9075\u4E49",label:"\u9075\u4E49"}]},{value:"\u6D77\u5357",label:"\u6D77\u5357",children:[{value:"\u6D77\u53E3",label:"\u6D77\u53E3"},{value:"\u510B\u53BF",label:"\u510B\u53BF"},{value:"\u9675\u6C34",label:"\u9675\u6C34"},{value:"\u743C\u6D77",label:"\u743C\u6D77"},{value:"\u4E09\u4E9A",label:"\u4E09\u4E9A"},{value:"\u901A\u4EC0",label:"\u901A\u4EC0"},{value:"\u4E07\u5B81",label:"\u4E07\u5B81"}]},{value:"\u6CB3\u5317",label:"\u6CB3\u5317",children:[{value:"\u77F3\u5BB6\u5E84",label:"\u77F3\u5BB6\u5E84"},{value:"\u4FDD\u5B9A",label:"\u4FDD\u5B9A"},{value:"\u5317\u6234\u6CB3",label:"\u5317\u6234\u6CB3"},{value:"\u6CA7\u5DDE",label:"\u6CA7\u5DDE"},{value:"\u627F\u5FB7",label:"\u627F\u5FB7"},{value:"\u4E30\u6DA6",label:"\u4E30\u6DA6"},{value:"\u90AF\u90F8",label:"\u90AF\u90F8"},{value:"\u8861\u6C34",label:"\u8861\u6C34"},{value:"\u5ECA\u574A",label:"\u5ECA\u574A"},{value:"\u5357\u6234\u6CB3",label:"\u5357\u6234\u6CB3"},{value:"\u79E6\u7687\u5C9B",label:"\u79E6\u7687\u5C9B"},{value:"\u5510\u5C71",label:"\u5510\u5C71"},{value:"\u65B0\u57CE",label:"\u65B0\u57CE"},{value:"\u90A2\u53F0",label:"\u90A2\u53F0"},{value:"\u5F20\u5BB6\u53E3",label:"\u5F20\u5BB6\u53E3"}]},{value:"\u9ED1\u9F99\u6C5F",label:"\u9ED1\u9F99\u6C5F",children:[{value:"\u54C8\u5C14\u6EE8",label:"\u54C8\u5C14\u6EE8"},{value:"\u5317\u5B89",label:"\u5317\u5B89"},{value:"\u5927\u5E86",label:"\u5927\u5E86"},{value:"\u5927\u5174\u5B89\u5CAD",label:"\u5927\u5174\u5B89\u5CAD"},{value:"\u9E64\u5C97",label:"\u9E64\u5C97"},{value:"\u9ED1\u6CB3",label:"\u9ED1\u6CB3"},{value:"\u4F73\u6728\u65AF",label:"\u4F73\u6728\u65AF"},{value:"\u9E21\u897F",label:"\u9E21\u897F"},{value:"\u7261\u4E39\u6C5F",label:"\u7261\u4E39\u6C5F"},{value:"\u9F50\u9F50\u54C8\u5C14",label:"\u9F50\u9F50\u54C8\u5C14"},{value:"\u4E03\u53F0\u6CB3",label:"\u4E03\u53F0\u6CB3"},{value:"\u53CC\u9E2D\u5C71",label:"\u53CC\u9E2D\u5C71"},{value:"\u7EE5\u5316",label:"\u7EE5\u5316"},{value:"\u4F0A\u6625",label:"\u4F0A\u6625"}]},{value:"\u6CB3\u5357",label:"\u6CB3\u5357",children:[{value:"\u90D1\u5DDE",label:"\u90D1\u5DDE"},{value:"\u5B89\u9633",label:"\u5B89\u9633"},{value:"\u9E64\u58C1",label:"\u9E64\u58C1"},{value:"\u6F62\u5DDD",label:"\u6F62\u5DDD"},{value:"\u7126\u4F5C",label:"\u7126\u4F5C"},{value:"\u6D4E\u6E90",label:"\u6D4E\u6E90"},{value:"\u5F00\u5C01",label:"\u5F00\u5C01"},{value:"\u6F2F\u6CB3",label:"\u6F2F\u6CB3"},{value:"\u6D1B\u9633",label:"\u6D1B\u9633"},{value:"\u5357\u9633",label:"\u5357\u9633"},{value:"\u5E73\u9876\u5C71",label:"\u5E73\u9876\u5C71"},{value:"\u6FEE\u9633",label:"\u6FEE\u9633"},{value:"\u4E09\u95E8\u5CE1",label:"\u4E09\u95E8\u5CE1"},{value:"\u5546\u4E18",label:"\u5546\u4E18"},{value:"\u65B0\u4E61",label:"\u65B0\u4E61"},{value:"\u4FE1\u9633",label:"\u4FE1\u9633"},{value:"\u8BB8\u660C",label:"\u8BB8\u660C"},{value:"\u5468\u53E3",label:"\u5468\u53E3"},{value:"\u9A7B\u9A6C\u5E97",label:"\u9A7B\u9A6C\u5E97"}]},{value:"\u9999\u6E2F",label:"\u9999\u6E2F",children:[{value:"\u9999\u6E2F",label:"\u9999\u6E2F"},{value:"\u4E5D\u9F99",label:"\u4E5D\u9F99"},{value:"\u65B0\u754C",label:"\u65B0\u754C"}]},{value:"\u6E56\u5317",label:"\u6E56\u5317",children:[{value:"\u6B66\u6C49",label:"\u6B66\u6C49"},{value:"\u5929\u95E8",label:"\u5929\u95E8"},{value:"\u6069\u65BD",label:"\u6069\u65BD"},{value:"\u9102\u5DDE",label:"\u9102\u5DDE"},{value:"\u9EC4\u5188",label:"\u9EC4\u5188"},{value:"\u9EC4\u77F3",label:"\u9EC4\u77F3"},{value:"\u8346\u95E8",label:"\u8346\u95E8"},{value:"\u8346\u5DDE",label:"\u8346\u5DDE"},{value:"\u6F5C\u6C5F",label:"\u6F5C\u6C5F"},{value:"\u5341\u5830",label:"\u5341\u5830"},{value:"\u968F\u5DDE",label:"\u968F\u5DDE"},{value:"\u6B66\u7A74",label:"\u6B66\u7A74"},{value:"\u4ED9\u6843",label:"\u4ED9\u6843"},{value:"\u54B8\u5B81",label:"\u54B8\u5B81"},{value:"\u8944\u9633",label:"\u8944\u9633"},{value:"\u8944\u6A0A",label:"\u8944\u6A0A"},{value:"\u5B5D\u611F",label:"\u5B5D\u611F"},{value:"\u5B9C\u660C",label:"\u5B9C\u660C"}]},{value:"\u6E56\u5357",label:"\u6E56\u5357",children:[{value:"\u957F\u6C99",label:"\u957F\u6C99"},{value:"\u5E38\u5FB7",label:"\u5E38\u5FB7"},{value:"\u90F4\u5DDE",label:"\u90F4\u5DDE"},{value:"\u8861\u9633",label:"\u8861\u9633"},{value:"\u6000\u5316",label:"\u6000\u5316"},{value:"\u5409\u9996",label:"\u5409\u9996"},{value:"\u5A04\u5E95",label:"\u5A04\u5E95"},{value:"\u90B5\u9633",label:"\u90B5\u9633"},{value:"\u6E58\u6F6D",label:"\u6E58\u6F6D"},{value:"\u76CA\u9633",label:"\u76CA\u9633"},{value:"\u5CB3\u9633",label:"\u5CB3\u9633"},{value:"\u6C38\u5DDE",label:"\u6C38\u5DDE"},{value:"\u5F20\u5BB6\u754C",label:"\u5F20\u5BB6\u754C"},{value:"\u682A\u6D32",label:"\u682A\u6D32"}]},{value:"\u6C5F\u897F",label:"\u6C5F\u897F",children:[{value:"\u5357\u660C",label:"\u5357\u660C"},{value:"\u629A\u5DDE",label:"\u629A\u5DDE"},{value:"\u8D63\u5DDE",label:"\u8D63\u5DDE"},{value:"\u5409\u5B89",label:"\u5409\u5B89"},{value:"\u666F\u5FB7\u9547",label:"\u666F\u5FB7\u9547"},{value:"\u4E95\u5188\u5C71",label:"\u4E95\u5188\u5C71"},{value:"\u4E5D\u6C5F",label:"\u4E5D\u6C5F"},{value:"\u5E90\u5C71",label:"\u5E90\u5C71"},{value:"\u840D\u4E61",label:"\u840D\u4E61"},{value:"\u4E0A\u9976",label:"\u4E0A\u9976"},{value:"\u65B0\u4F59",label:"\u65B0\u4F59"},{value:"\u5B9C\u6625",label:"\u5B9C\u6625"},{value:"\u9E70\u6F6D",label:"\u9E70\u6F6D"}]},{value:"\u5409\u6797",label:"\u5409\u6797",children:[{value:"\u957F\u6625",label:"\u957F\u6625"},{value:"\u5409\u6797",label:"\u5409\u6797"},{value:"\u767D\u57CE",label:"\u767D\u57CE"},{value:"\u767D\u5C71",label:"\u767D\u5C71"},{value:"\u73F2\u6625",label:"\u73F2\u6625"},{value:"\u8FBD\u6E90",label:"\u8FBD\u6E90"},{value:"\u6885\u6CB3",label:"\u6885\u6CB3"},{value:"\u56DB\u5E73",label:"\u56DB\u5E73"},{value:"\u677E\u539F",label:"\u677E\u539F"},{value:"\u901A\u5316",label:"\u901A\u5316"},{value:"\u5EF6\u5409",label:"\u5EF6\u5409"}]},{value:"\u8FBD\u5B81",label:"\u8FBD\u5B81",children:[{value:"\u6C88\u9633",label:"\u6C88\u9633"},{value:"\u978D\u5C71",label:"\u978D\u5C71"},{value:"\u672C\u6EAA",label:"\u672C\u6EAA"},{value:"\u671D\u9633",label:"\u671D\u9633"},{value:"\u5927\u8FDE",label:"\u5927\u8FDE"},{value:"\u4E39\u4E1C",label:"\u4E39\u4E1C"},{value:"\u629A\u987A",label:"\u629A\u987A"},{value:"\u961C\u65B0",label:"\u961C\u65B0"},{value:"\u846B\u82A6\u5C9B",label:"\u846B\u82A6\u5C9B"},{value:"\u9526\u5DDE",label:"\u9526\u5DDE"},{value:"\u8FBD\u9633",label:"\u8FBD\u9633"},{value:"\u76D8\u9526",label:"\u76D8\u9526"},{value:"\u94C1\u5CAD",label:"\u94C1\u5CAD"},{value:"\u8425\u53E3",label:"\u8425\u53E3"}]},{value:"\u6FB3\u95E8",label:"\u6FB3\u95E8",children:[{value:"\u6FB3\u95E8",label:"\u6FB3\u95E8"}]},{value:"\u5185\u8499\u53E4",label:"\u5185\u8499\u53E4",children:[{value:"\u547C\u548C\u6D69\u7279",label:"\u547C\u548C\u6D69\u7279"},{value:"\u963F\u62C9\u5584\u76DF",label:"\u963F\u62C9\u5584\u76DF"},{value:"\u5305\u5934",label:"\u5305\u5934"},{value:"\u8D64\u5CF0",label:"\u8D64\u5CF0"},{value:"\u4E1C\u80DC",label:"\u4E1C\u80DC"},{value:"\u6D77\u62C9\u5C14",label:"\u6D77\u62C9\u5C14"},{value:"\u96C6\u5B81",label:"\u96C6\u5B81"},{value:"\u4E34\u6CB3",label:"\u4E34\u6CB3"},{value:"\u901A\u8FBD",label:"\u901A\u8FBD"},{value:"\u4E4C\u6D77",label:"\u4E4C\u6D77"},{value:"\u4E4C\u5170\u6D69\u7279",label:"\u4E4C\u5170\u6D69\u7279"},{value:"\u9521\u6797\u6D69\u7279",label:"\u9521\u6797\u6D69\u7279"}]},{value:"\u5B81\u590F",label:"\u5B81\u590F",children:[{value:"\u94F6\u5DDD",label:"\u94F6\u5DDD"},{value:"\u56FA\u6E90",label:"\u56FA\u6E90"},{value:"\u77F3\u5634\u5C71",label:"\u77F3\u5634\u5C71"},{value:"\u5434\u5FE0",label:"\u5434\u5FE0"}]},{value:"\u9752\u6D77",label:"\u9752\u6D77",children:[{value:"\u897F\u5B81",label:"\u897F\u5B81"},{value:"\u5FB7\u4EE4\u54C8",label:"\u5FB7\u4EE4\u54C8"},{value:"\u683C\u5C14\u6728",label:"\u683C\u5C14\u6728"},{value:"\u5171\u548C",label:"\u5171\u548C"},{value:"\u6D77\u4E1C",label:"\u6D77\u4E1C"},{value:"\u6D77\u664F",label:"\u6D77\u664F"},{value:"\u739B\u6C81",label:"\u739B\u6C81"},{value:"\u540C\u4EC1",label:"\u540C\u4EC1"},{value:"\u7389\u6811",label:"\u7389\u6811"}]},{value:"\u5C71\u4E1C",label:"\u5C71\u4E1C",children:[{value:"\u6D4E\u5357",label:"\u6D4E\u5357"},{value:"\u6EE8\u5DDE",label:"\u6EE8\u5DDE"},{value:"\u5156\u5DDE",label:"\u5156\u5DDE"},{value:"\u5FB7\u5DDE",label:"\u5FB7\u5DDE"},{value:"\u4E1C\u8425",label:"\u4E1C\u8425"},{value:"\u83CF\u6CFD",label:"\u83CF\u6CFD"},{value:"\u6D4E\u5B81",label:"\u6D4E\u5B81"},{value:"\u83B1\u829C",label:"\u83B1\u829C"},{value:"\u804A\u57CE",label:"\u804A\u57CE"},{value:"\u4E34\u6C82",label:"\u4E34\u6C82"},{value:"\u84EC\u83B1",label:"\u84EC\u83B1"},{value:"\u9752\u5C9B",label:"\u9752\u5C9B"},{value:"\u66F2\u961C",label:"\u66F2\u961C"},{value:"\u65E5\u7167",label:"\u65E5\u7167"},{value:"\u6CF0\u5B89",label:"\u6CF0\u5B89"},{value:"\u6F4D\u574A",label:"\u6F4D\u574A"},{value:"\u5A01\u6D77",label:"\u5A01\u6D77"},{value:"\u70DF\u53F0",label:"\u70DF\u53F0"},{value:"\u67A3\u5E84",label:"\u67A3\u5E84"},{value:"\u6DC4\u535A",label:"\u6DC4\u535A"}]},{value:"\u5C71\u897F",label:"\u5C71\u897F",children:[{value:"\u592A\u539F",label:"\u592A\u539F"},{value:"\u5415\u6881",label:"\u5415\u6881"},{value:"\u957F\u6CBB",label:"\u957F\u6CBB"},{value:"\u5927\u540C",label:"\u5927\u540C"},{value:"\u5019\u9A6C",label:"\u5019\u9A6C"},{value:"\u664B\u57CE",label:"\u664B\u57CE"},{value:"\u79BB\u77F3",label:"\u79BB\u77F3"},{value:"\u4E34\u6C7E",label:"\u4E34\u6C7E"},{value:"\u5B81\u6B66",label:"\u5B81\u6B66"},{value:"\u6714\u5DDE",label:"\u6714\u5DDE"},{value:"\u5FFB\u5DDE",label:"\u5FFB\u5DDE"},{value:"\u9633\u6CC9",label:"\u9633\u6CC9"},{value:"\u6986\u6B21",label:"\u6986\u6B21"},{value:"\u664B\u4E2D",label:"\u664B\u4E2D"},{value:"\u8FD0\u57CE",label:"\u8FD0\u57CE"}]},{value:"\u9655\u897F",label:"\u9655\u897F",children:[{value:"\u897F\u5B89",label:"\u897F\u5B89"},{value:"\u5B89\u5EB7",label:"\u5B89\u5EB7"},{value:"\u5B9D\u9E21",label:"\u5B9D\u9E21"},{value:"\u6C49\u4E2D",label:"\u6C49\u4E2D"},{value:"\u6E2D\u5357",label:"\u6E2D\u5357"},{value:"\u5546\u5DDE",label:"\u5546\u5DDE"},{value:"\u7EE5\u5FB7",label:"\u7EE5\u5FB7"},{value:"\u94DC\u5DDD",label:"\u94DC\u5DDD"},{value:"\u54B8\u9633",label:"\u54B8\u9633"},{value:"\u5EF6\u5B89",label:"\u5EF6\u5B89"},{value:"\u6986\u6797",label:"\u6986\u6797"}]},{value:"\u56DB\u5DDD",label:"\u56DB\u5DDD",children:[{value:"\u6210\u90FD",label:"\u6210\u90FD"},{value:"\u5DF4\u4E2D",label:"\u5DF4\u4E2D"},{value:"\u8FBE\u5DDD",label:"\u8FBE\u5DDD"},{value:"\u5FB7\u9633",label:"\u5FB7\u9633"},{value:"\u90FD\u6C5F\u5830",label:"\u90FD\u6C5F\u5830"},{value:"\u5CE8\u7709\u5C71",label:"\u5CE8\u7709\u5C71"},{value:"\u6DAA\u9675",label:"\u6DAA\u9675"},{value:"\u5E7F\u5B89",label:"\u5E7F\u5B89"},{value:"\u5E7F\u5143",label:"\u5E7F\u5143"},{value:"\u4E5D\u5BE8\u6C9F",label:"\u4E5D\u5BE8\u6C9F"},{value:"\u5EB7\u5B9A",label:"\u5EB7\u5B9A"},{value:"\u4E50\u5C71",label:"\u4E50\u5C71"},{value:"\u6CF8\u5DDE",label:"\u6CF8\u5DDE"},{value:"\u9A6C\u5C14\u5EB7",label:"\u9A6C\u5C14\u5EB7"},{value:"\u7EF5\u9633",label:"\u7EF5\u9633"},{value:"\u7709\u5C71",label:"\u7709\u5C71"},{value:"\u5357\u5145",label:"\u5357\u5145"},{value:"\u5185\u6C5F",label:"\u5185\u6C5F"},{value:"\u6500\u679D\u82B1",label:"\u6500\u679D\u82B1"},{value:"\u9042\u5B81",label:"\u9042\u5B81"},{value:"\u6C76\u5DDD",label:"\u6C76\u5DDD"},{value:"\u897F\u660C",label:"\u897F\u660C"},{value:"\u96C5\u5B89",label:"\u96C5\u5B89"},{value:"\u5B9C\u5BBE",label:"\u5B9C\u5BBE"},{value:"\u81EA\u8D21",label:"\u81EA\u8D21"},{value:"\u8D44\u9633",label:"\u8D44\u9633"}]},{value:"\u53F0\u6E7E",label:"\u53F0\u6E7E",children:[{value:"\u53F0\u5317",label:"\u53F0\u5317"},{value:"\u57FA\u9686",label:"\u57FA\u9686"},{value:"\u53F0\u5357",label:"\u53F0\u5357"},{value:"\u53F0\u4E2D",label:"\u53F0\u4E2D"},{value:"\u9AD8\u96C4",label:"\u9AD8\u96C4"},{value:"\u5C4F\u4E1C",label:"\u5C4F\u4E1C"},{value:"\u5357\u6295",label:"\u5357\u6295"},{value:"\u4E91\u6797",label:"\u4E91\u6797"},{value:"\u65B0\u7AF9",label:"\u65B0\u7AF9"},{value:"\u5F70\u5316",label:"\u5F70\u5316"},{value:"\u82D7\u6817",label:"\u82D7\u6817"},{value:"\u5609\u4E49",label:"\u5609\u4E49"},{value:"\u6843\u56ED",label:"\u6843\u56ED"},{value:"\u5B9C\u5170",label:"\u5B9C\u5170"},{value:"\u53F0\u4E1C",label:"\u53F0\u4E1C"},{value:"\u91D1\u95E8",label:"\u91D1\u95E8"},{value:"\u9A6C\u7956",label:"\u9A6C\u7956"},{value:"\u6F8E\u6E56",label:"\u6F8E\u6E56"}]},{value:"\u5929\u6D25",label:"\u5929\u6D25",children:[{value:"\u5929\u6D25",label:"\u5929\u6D25"},{value:"\u548C\u5E73",label:"\u548C\u5E73"},{value:"\u4E1C\u4E3D",label:"\u4E1C\u4E3D"},{value:"\u6CB3\u4E1C",label:"\u6CB3\u4E1C"},{value:"\u897F\u9752",label:"\u897F\u9752"},{value:"\u6CB3\u897F",label:"\u6CB3\u897F"},{value:"\u6D25\u5357",label:"\u6D25\u5357"},{value:"\u5357\u5F00",label:"\u5357\u5F00"},{value:"\u5317\u8FB0",label:"\u5317\u8FB0"},{value:"\u6CB3\u5317",label:"\u6CB3\u5317"},{value:"\u6B66\u6E05",label:"\u6B66\u6E05"},{value:"\u7EA2\u6322",label:"\u7EA2\u6322"},{value:"\u5858\u6CBD",label:"\u5858\u6CBD"},{value:"\u6C49\u6CBD",label:"\u6C49\u6CBD"},{value:"\u5927\u6E2F",label:"\u5927\u6E2F"},{value:"\u5B81\u6CB3",label:"\u5B81\u6CB3"},{value:"\u9759\u6D77",label:"\u9759\u6D77"},{value:"\u5B9D\u577B",label:"\u5B9D\u577B"},{value:"\u84DF\u53BF",label:"\u84DF\u53BF"}]},{value:"\u65B0\u7586",label:"\u65B0\u7586",children:[{value:"\u4E4C\u9C81\u6728\u9F50",label:"\u4E4C\u9C81\u6728\u9F50"},{value:"\u963F\u514B\u82CF",label:"\u963F\u514B\u82CF"},{value:"\u963F\u52D2\u6CF0",label:"\u963F\u52D2\u6CF0"},{value:"\u963F\u56FE\u4EC0",label:"\u963F\u56FE\u4EC0"},{value:"\u535A\u4E50",label:"\u535A\u4E50"},{value:"\u660C\u5409",label:"\u660C\u5409"},{value:"\u4E1C\u5C71",label:"\u4E1C\u5C71"},{value:"\u54C8\u5BC6",label:"\u54C8\u5BC6"},{value:"\u548C\u7530",label:"\u548C\u7530"},{value:"\u5580\u4EC0",label:"\u5580\u4EC0"},{value:"\u514B\u62C9\u739B\u4F9D",label:"\u514B\u62C9\u739B\u4F9D"},{value:"\u5E93\u8F66",label:"\u5E93\u8F66"},{value:"\u5E93\u5C14\u52D2",label:"\u5E93\u5C14\u52D2"},{value:"\u594E\u5C6F",label:"\u594E\u5C6F"},{value:"\u77F3\u6CB3\u5B50",label:"\u77F3\u6CB3\u5B50"},{value:"\u5854\u57CE",label:"\u5854\u57CE"},{value:"\u5410\u9C81\u756A",label:"\u5410\u9C81\u756A"},{value:"\u4F0A\u5B81",label:"\u4F0A\u5B81"}]},{value:"\u897F\u85CF",label:"\u897F\u85CF",children:[{value:"\u62C9\u8428",label:"\u62C9\u8428"},{value:"\u963F\u91CC",label:"\u963F\u91CC"},{value:"\u660C\u90FD",label:"\u660C\u90FD"},{value:"\u6797\u829D",label:"\u6797\u829D"},{value:"\u90A3\u66F2",label:"\u90A3\u66F2"},{value:"\u65E5\u5580\u5219",label:"\u65E5\u5580\u5219"},{value:"\u5C71\u5357",label:"\u5C71\u5357"}]},{value:"\u4E91\u5357",label:"\u4E91\u5357",children:[{value:"\u6606\u660E",label:"\u6606\u660E"},{value:"\u5927\u7406",label:"\u5927\u7406"},{value:"\u4FDD\u5C71",label:"\u4FDD\u5C71"},{value:"\u695A\u96C4",label:"\u695A\u96C4"},{value:"\u5927\u7406",label:"\u5927\u7406"},{value:"\u4E1C\u5DDD",label:"\u4E1C\u5DDD"},{value:"\u4E2A\u65E7",label:"\u4E2A\u65E7"},{value:"\u666F\u6D2A",label:"\u666F\u6D2A"},{value:"\u5F00\u8FDC",label:"\u5F00\u8FDC"},{value:"\u4E34\u6CA7",label:"\u4E34\u6CA7"},{value:"\u4E3D\u6C5F",label:"\u4E3D\u6C5F"},{value:"\u516D\u5E93",label:"\u516D\u5E93"},{value:"\u6F5E\u897F",label:"\u6F5E\u897F"},{value:"\u66F2\u9756",label:"\u66F2\u9756"},{value:"\u601D\u8305",label:"\u601D\u8305"},{value:"\u6587\u5C71",label:"\u6587\u5C71"},{value:"\u897F\u53CC\u7248\u7EB3",label:"\u897F\u53CC\u7248\u7EB3"},{value:"\u7389\u6EAA",label:"\u7389\u6EAA"},{value:"\u4E2D\u7538",label:"\u4E2D\u7538"},{value:"\u662D\u901A",label:"\u662D\u901A"}]},{value:"\u6D59\u6C5F",label:"\u6D59\u6C5F",children:[{value:"\u676D\u5DDE",label:"\u676D\u5DDE"},{value:"\u6E29\u5DDE",label:"\u6E29\u5DDE"},{value:"\u5B89\u5409",label:"\u5B89\u5409"},{value:"\u6148\u6EAA",label:"\u6148\u6EAA"},{value:"\u5B9A\u6D77",label:"\u5B9A\u6D77"},{value:"\u5949\u5316",label:"\u5949\u5316"},{value:"\u6D77\u76D0",label:"\u6D77\u76D0"},{value:"\u9EC4\u5CA9",label:"\u9EC4\u5CA9"},{value:"\u6E56\u5DDE",label:"\u6E56\u5DDE"},{value:"\u5609\u5174",label:"\u5609\u5174"},{value:"\u91D1\u534E",label:"\u91D1\u534E"},{value:"\u4E34\u5B89",label:"\u4E34\u5B89"},{value:"\u4E34\u6D77",label:"\u4E34\u6D77"},{value:"\u4E3D\u6C34",label:"\u4E3D\u6C34"},{value:"\u5B81\u6CE2",label:"\u5B81\u6CE2"},{value:"\u74EF\u6D77",label:"\u74EF\u6D77"},{value:"\u5E73\u6E56",label:"\u5E73\u6E56"},{value:"\u5343\u5C9B\u6E56",label:"\u5343\u5C9B\u6E56"},{value:"\u8862\u5DDE",label:"\u8862\u5DDE"},{value:"\u6C5F\u5C71",label:"\u6C5F\u5C71"},{value:"\u745E\u5B89",label:"\u745E\u5B89"},{value:"\u7ECD\u5174",label:"\u7ECD\u5174"},{value:"\u5D4A\u5DDE",label:"\u5D4A\u5DDE"},{value:"\u53F0\u5DDE",label:"\u53F0\u5DDE"},{value:"\u6E29\u5CAD",label:"\u6E29\u5CAD"},{value:"\u4F59\u59DA",label:"\u4F59\u59DA"},{value:"\u821F\u5C71",label:"\u821F\u5C71"}]},{value:"\u6D77\u5916",label:"\u6D77\u5916",children:[{value:"\u7F8E\u56FD",label:"\u7F8E\u56FD"},{value:"\u65E5\u672C",label:"\u65E5\u672C"},{value:"\u82F1\u56FD",label:"\u82F1\u56FD"},{value:"\u6CD5\u56FD",label:"\u6CD5\u56FD"},{value:"\u5FB7\u56FD",label:"\u5FB7\u56FD"},{value:"\u5176\u4ED6",label:"\u5176\u4ED6"}]}]},51161:function(jn,li,De){"use strict";De.d(li,{AL:function(){return xe},Iy:function(){return Qt},Qv:function(){return Re},ez:function(){return me},jb:function(){return It}});var Ne=De(47084),dt=De.n(Ne),Ut=De(90621),$t=De.n(Ut);let kt=1;function Ie(st,it){const Nt=st.match(/^(\s+)(?:```)/);if(Nt===null)return it;const St=Nt[1];return it.split(`
`).map(Ft=>{const cn=Ft.match(/^\s+/);if(cn===null)return Ft;const[Tt]=cn;return Tt.length>=St.length?Ft.slice(St.length):Ft}).join(`
`)}let $e=[],Mt=["<ul>"];const Pt=new(dt()).Renderer,wt=/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/;function Qt(){$e.length=0,Mt=["<ul>"]}const It={overflow:"hidden",WebkitBoxOrient:"vertical",display:"-webkit-box",WebkitLineClamp:2};function sn(st,it,Nt,St){if(it>=st.length||st[it].level<=Nt)return it;var Ft=st[it];St.push("<li><a href='#"+kt+Ft.anchor+"'>"+Ft.text+"</a>"),it++;var cn=[];return it=sn(st,it,Ft.level,cn),cn.length>0&&(St.push("<ul>"),cn.forEach(function(Tt){St.push(Tt)}),St.push("</ul>")),St.push("</li>"),it=sn(st,it,Nt,St),it}function Re(){return sn($e,0,0,Mt),Mt.push("</ul>"),Mt.join("")}const ne={heading(st){const it=wt.exec(st);if(kt+=1,it)return{type:"heading",raw:it[0],depth:it[1].length,text:it[2]}},fences(st){const it=this.rules.block.fences.exec(st);if(it){const Nt=it[0];let St=Ie(Nt,it[3]||"");const Ft=it[2]?it[2].trim():it[2];if(["latex","katex","math"].indexOf(Ft)>=0){const cn=le(),Tt=St;St=cn,pe[cn]={type:"block",expression:Tt}}return{type:"code",raw:Nt,lang:Ft,text:St}}}},te=/(?:\${2})([^\n`]+?)(?:\${2})/gi;let he=0;const le=()=>`__special_katext_id_${he++}__`;let pe={};function me(){return pe}function xe(){he=0,pe={}}function Ee(st){return st=st.replace(te,(it,Nt)=>{const St=le();return pe[St]={type:"inline",expression:Nt},St}),st}const Ge=Pt.listitem;Pt.listitem=function(st){return Ge(Ee(st))};const et=Pt.paragraph;Pt.paragraph=function(st){return et(Ee(st))};const ut=Pt.tablecell;Pt.tablecell=function(st,it){return ut(Ee(st),it)},Pt.code=function(st,it,Nt){const St=(it||"").match(/\S*/)[0];return St?["latex","katex","math"].indexOf(St)>=0?`<p class='editormd-tex'>${st}</p>`:`<pre class="prettyprint linenums"><code class="language-${it}">${Nt?st:(0,Ut.escape)(st,!0)}</code></pre>
`:'<pre class="prettyprint linenums"><code>'+(Nt?st:(0,Ut.escape)(st,!0))+"</code></pre>"},Pt.heading=function(st,it,Nt){let St=this.options.headerPrefix+Nt.toLowerCase().replace(/[^\w\\u4e00-\\u9fa5]]+/g,"-");return $e.push({anchor:St,level:it,text:st}),"<h"+it+' id="'+kt+St+'">'+st+"</h"+it+">"},dt().setOptions({silent:!0,gfm:!0,pedantic:!1}),dt().use({tokenizer:ne,renderer:Pt}),li.ZP=dt()},88386:function(jn,li,De){(function(Ne){Ne(De(4631))})(function(Ne){Ne.defineOption("placeholder","",function(Mt,Pt,wt){var Qt=wt&&wt!=Ne.Init;if(Pt&&!Qt)Mt.on("blur",kt),Mt.on("change",Ie),Mt.on("swapDoc",Ie),Ne.on(Mt.getInputField(),"compositionupdate",Mt.state.placeholderCompose=function(){$t(Mt)}),Ie(Mt);else if(!Pt&&Qt){Mt.off("blur",kt),Mt.off("change",Ie),Mt.off("swapDoc",Ie),Ne.off(Mt.getInputField(),"compositionupdate",Mt.state.placeholderCompose),dt(Mt);var It=Mt.getWrapperElement();It.className=It.className.replace(" CodeMirror-empty","")}Pt&&!Mt.hasFocus()&&kt(Mt)});function dt(Mt){Mt.state.placeholder&&(Mt.state.placeholder.parentNode.removeChild(Mt.state.placeholder),Mt.state.placeholder=null)}function Ut(Mt){dt(Mt);var Pt=Mt.state.placeholder=document.createElement("pre");Pt.style.cssText="height: 0; overflow: visible",Pt.style.direction=Mt.getOption("direction"),Pt.className="CodeMirror-placeholder CodeMirror-line-like";var wt=Mt.getOption("placeholder");typeof wt=="string"&&(wt=document.createTextNode(wt)),Pt.appendChild(wt),Mt.display.lineSpace.insertBefore(Pt,Mt.display.lineSpace.firstChild)}function $t(Mt){setTimeout(function(){var Pt=!1,wt=Mt.getInputField();wt.nodeName=="TEXTAREA"?Pt=!wt.value:Mt.lineCount()==1&&(Pt=!/[^\u200b]/.test(wt.querySelector(".CodeMirror-line").textContent)),Pt?Ut(Mt):dt(Mt)},20)}function kt(Mt){$e(Mt)&&Ut(Mt)}function Ie(Mt){var Pt=Mt.getWrapperElement(),wt=$e(Mt);Pt.className=Pt.className.replace(" CodeMirror-empty","")+(wt?" CodeMirror-empty":""),wt?Ut(Mt):dt(Mt)}function $e(Mt){return Mt.lineCount()===1&&Mt.getLine(0)===""}})},82801:function(jn,li,De){(function(Ne){Ne(De(4631))})(function(Ne){var dt={pairs:`()[]{}''""`,closeBefore:`)]}'":;>`,triples:"",explode:"[]{}"},Ut=Ne.Pos;Ne.defineOption("autoCloseBrackets",!1,function(ne,te,he){he&&he!=Ne.Init&&(ne.removeKeyMap(kt),ne.state.closeBrackets=null),te&&(Ie($t(te,"pairs")),ne.state.closeBrackets=te,ne.addKeyMap(kt))});function $t(ne,te){return te=="pairs"&&typeof ne=="string"?ne:typeof ne=="object"&&ne[te]!=null?ne[te]:dt[te]}var kt={Backspace:Pt,Enter:wt};function Ie(ne){for(var te=0;te<ne.length;te++){var he=ne.charAt(te),le="'"+he+"'";kt[le]||(kt[le]=$e(he))}}Ie(dt.pairs+"`");function $e(ne){return function(te){return It(te,ne)}}function Mt(ne){var te=ne.state.closeBrackets;if(!te||te.override)return te;var he=ne.getModeAt(ne.getCursor());return he.closeBrackets||te}function Pt(ne){var te=Mt(ne);if(!te||ne.getOption("disableInput"))return Ne.Pass;for(var he=$t(te,"pairs"),le=ne.listSelections(),pe=0;pe<le.length;pe++){if(!le[pe].empty())return Ne.Pass;var me=sn(ne,le[pe].head);if(!me||he.indexOf(me)%2!=0)return Ne.Pass}for(var pe=le.length-1;pe>=0;pe--){var xe=le[pe].head;ne.replaceRange("",Ut(xe.line,xe.ch-1),Ut(xe.line,xe.ch+1),"+delete")}}function wt(ne){var te=Mt(ne),he=te&&$t(te,"explode");if(!he||ne.getOption("disableInput"))return Ne.Pass;for(var le=ne.listSelections(),pe=0;pe<le.length;pe++){if(!le[pe].empty())return Ne.Pass;var me=sn(ne,le[pe].head);if(!me||he.indexOf(me)%2!=0)return Ne.Pass}ne.operation(function(){var xe=ne.lineSeparator()||`
`;ne.replaceSelection(xe+xe,null),ne.execCommand("goCharLeft"),le=ne.listSelections();for(var Ee=0;Ee<le.length;Ee++){var Ge=le[Ee].head.line;ne.indentLine(Ge,null,!0),ne.indentLine(Ge+1,null,!0)}})}function Qt(ne){var te=Ne.cmpPos(ne.anchor,ne.head)>0;return{anchor:new Ut(ne.anchor.line,ne.anchor.ch+(te?-1:1)),head:new Ut(ne.head.line,ne.head.ch+(te?1:-1))}}function It(ne,te){var he=Mt(ne);if(!he||ne.getOption("disableInput"))return Ne.Pass;var le=$t(he,"pairs"),pe=le.indexOf(te);if(pe==-1)return Ne.Pass;for(var me=$t(he,"closeBefore"),xe=$t(he,"triples"),Ee=le.charAt(pe+1)==te,Ge=ne.listSelections(),et=pe%2==0,ut,st=0;st<Ge.length;st++){var it=Ge[st],Nt=it.head,St,Ft=ne.getRange(Nt,Ut(Nt.line,Nt.ch+1));if(et&&!it.empty())St="surround";else if((Ee||!et)&&Ft==te)Ee&&Re(ne,Nt)?St="both":xe.indexOf(te)>=0&&ne.getRange(Nt,Ut(Nt.line,Nt.ch+3))==te+te+te?St="skipThree":St="skip";else if(Ee&&Nt.ch>1&&xe.indexOf(te)>=0&&ne.getRange(Ut(Nt.line,Nt.ch-2),Nt)==te+te){if(Nt.ch>2&&/\bstring/.test(ne.getTokenTypeAt(Ut(Nt.line,Nt.ch-2))))return Ne.Pass;St="addFour"}else if(Ee){var cn=Nt.ch==0?" ":ne.getRange(Ut(Nt.line,Nt.ch-1),Nt);if(!Ne.isWordChar(Ft)&&cn!=te&&!Ne.isWordChar(cn))St="both";else return Ne.Pass}else if(et&&(Ft.length===0||/\s/.test(Ft)||me.indexOf(Ft)>-1))St="both";else return Ne.Pass;if(!ut)ut=St;else if(ut!=St)return Ne.Pass}var Tt=pe%2?le.charAt(pe-1):te,hi=pe%2?te:le.charAt(pe+1);ne.operation(function(){if(ut=="skip")ne.execCommand("goCharRight");else if(ut=="skipThree")for(var di=0;di<3;di++)ne.execCommand("goCharRight");else if(ut=="surround"){for(var zn=ne.getSelections(),di=0;di<zn.length;di++)zn[di]=Tt+zn[di]+hi;ne.replaceSelections(zn,"around"),zn=ne.listSelections().slice();for(var di=0;di<zn.length;di++)zn[di]=Qt(zn[di]);ne.setSelections(zn)}else ut=="both"?(ne.replaceSelection(Tt+hi,null),ne.triggerElectric(Tt+hi),ne.execCommand("goCharLeft")):ut=="addFour"&&(ne.replaceSelection(Tt+Tt+Tt+Tt,"before"),ne.execCommand("goCharRight"))})}function sn(ne,te){var he=ne.getRange(Ut(te.line,te.ch-1),Ut(te.line,te.ch+1));return he.length==2?he:null}function Re(ne,te){var he=ne.getTokenAt(Ut(te.line,te.ch+1));return/\bstring/.test(he.type)&&he.start==te.ch&&(te.ch==0||!/\bstring/.test(ne.getTokenTypeAt(te)))}})},57341:function(jn,li,De){(function(Ne){Ne(De(4631),De(4786))})(function(Ne){Ne.defineOption("autoCloseTags",!1,function(Pt,wt,Qt){if(Qt!=Ne.Init&&Qt&&Pt.removeKeyMap("autoCloseTags"),!!wt){var It={name:"autoCloseTags"};(typeof wt!="object"||wt.whenClosing!==!1)&&(It["'/'"]=function(sn){return Ie(sn)}),(typeof wt!="object"||wt.whenOpening!==!1)&&(It["'>'"]=function(sn){return $t(sn)}),Pt.addKeyMap(It)}});var dt=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],Ut=["applet","blockquote","body","button","div","dl","fieldset","form","frameset","h1","h2","h3","h4","h5","h6","head","html","iframe","layer","legend","object","ol","p","select","table","ul"];function $t(Pt){if(Pt.getOption("disableInput"))return Ne.Pass;for(var wt=Pt.listSelections(),Qt=[],It=Pt.getOption("autoCloseTags"),sn=0;sn<wt.length;sn++){if(!wt[sn].empty())return Ne.Pass;var Re=wt[sn].head,ne=Pt.getTokenAt(Re),te=Ne.innerMode(Pt.getMode(),ne.state),he=te.state,le=te.mode.xmlCurrentTag&&te.mode.xmlCurrentTag(he),pe=le&&le.name;if(!pe)return Ne.Pass;var me=te.mode.configuration=="html",xe=typeof It=="object"&&It.dontCloseTags||me&&dt,Ee=typeof It=="object"&&It.indentTags||me&&Ut;ne.end>Re.ch&&(pe=pe.slice(0,pe.length-ne.end+Re.ch));var Ge=pe.toLowerCase();if(!pe||ne.type=="string"&&(ne.end!=Re.ch||!/[\"\']/.test(ne.string.charAt(ne.string.length-1))||ne.string.length==1)||ne.type=="tag"&&le.close||ne.string.indexOf("/")==Re.ch-ne.start-1||xe&&$e(xe,Ge)>-1||Mt(Pt,te.mode.xmlCurrentContext&&te.mode.xmlCurrentContext(he)||[],pe,Re,!0))return Ne.Pass;var et=typeof It=="object"&&It.emptyTags;if(et&&$e(et,pe)>-1){Qt[sn]={text:"/>",newPos:Ne.Pos(Re.line,Re.ch+2)};continue}var ut=Ee&&$e(Ee,Ge)>-1;Qt[sn]={indent:ut,text:">"+(ut?`
`:"")+"</"+pe+">",newPos:ut?Ne.Pos(Re.line+1,0):Ne.Pos(Re.line,Re.ch+1)}}for(var st=typeof It=="object"&&It.dontIndentOnAutoClose,sn=wt.length-1;sn>=0;sn--){var it=Qt[sn];Pt.replaceRange(it.text,wt[sn].head,wt[sn].anchor,"+insert");var Nt=Pt.listSelections().slice(0);Nt[sn]={head:it.newPos,anchor:it.newPos},Pt.setSelections(Nt),!st&&it.indent&&(Pt.indentLine(it.newPos.line,null,!0),Pt.indentLine(it.newPos.line+1,null,!0))}}function kt(Pt,wt){for(var Qt=Pt.listSelections(),It=[],sn=wt?"/":"</",Re=Pt.getOption("autoCloseTags"),ne=typeof Re=="object"&&Re.dontIndentOnSlash,te=0;te<Qt.length;te++){if(!Qt[te].empty())return Ne.Pass;var he=Qt[te].head,le=Pt.getTokenAt(he),pe=Ne.innerMode(Pt.getMode(),le.state),me=pe.state;if(wt&&(le.type=="string"||le.string.charAt(0)!="<"||le.start!=he.ch-1))return Ne.Pass;var xe,Ee=pe.mode.name!="xml"&&Pt.getMode().name=="htmlmixed";if(Ee&&pe.mode.name=="javascript")xe=sn+"script";else if(Ee&&pe.mode.name=="css")xe=sn+"style";else{var Ge=pe.mode.xmlCurrentContext&&pe.mode.xmlCurrentContext(me);if(!Ge||Ge.length&&Mt(Pt,Ge,Ge[Ge.length-1],he))return Ne.Pass;xe=sn+Ge[Ge.length-1]}Pt.getLine(he.line).charAt(le.end)!=">"&&(xe+=">"),It[te]=xe}if(Pt.replaceSelections(It),Qt=Pt.listSelections(),!ne)for(var te=0;te<Qt.length;te++)(te==Qt.length-1||Qt[te].head.line<Qt[te+1].head.line)&&Pt.indentLine(Qt[te].head.line)}function Ie(Pt){return Pt.getOption("disableInput")?Ne.Pass:kt(Pt,!0)}Ne.commands.closeTag=function(Pt){return kt(Pt)};function $e(Pt,wt){if(Pt.indexOf)return Pt.indexOf(wt);for(var Qt=0,It=Pt.length;Qt<It;++Qt)if(Pt[Qt]==wt)return Qt;return-1}function Mt(Pt,wt,Qt,It,sn){if(!Ne.scanForClosingTag)return!1;var Re=Math.min(Pt.lastLine()+1,It.line+500),ne=Ne.scanForClosingTag(Pt,It,null,Re);if(!ne||ne.tag!=Qt)return!1;for(var te=sn?1:0,he=wt.length-1;he>=0&&wt[he]==Qt;he--)++te;It=ne.to;for(var he=1;he<te;he++){var le=Ne.scanForClosingTag(Pt,It,null,Re);if(!le||le.tag!=Qt)return!1;It=le.to}return!0}})},4786:function(jn,li,De){(function(Ne){Ne(De(4631))})(function(Ne){"use strict";var dt=Ne.Pos;function Ut(he,le){return he.line-le.line||he.ch-le.ch}var $t="A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",kt=$t+"-:.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",Ie=new RegExp("<(/?)(["+$t+"]["+kt+"]*)","g");function $e(he,le,pe,me){this.line=le,this.ch=pe,this.cm=he,this.text=he.getLine(le),this.min=me?Math.max(me.from,he.firstLine()):he.firstLine(),this.max=me?Math.min(me.to-1,he.lastLine()):he.lastLine()}function Mt(he,le){var pe=he.cm.getTokenTypeAt(dt(he.line,le));return pe&&/\btag\b/.test(pe)}function Pt(he){if(!(he.line>=he.max))return he.ch=0,he.text=he.cm.getLine(++he.line),!0}function wt(he){if(!(he.line<=he.min))return he.text=he.cm.getLine(--he.line),he.ch=he.text.length,!0}function Qt(he){for(;;){var le=he.text.indexOf(">",he.ch);if(le==-1){if(Pt(he))continue;return}if(!Mt(he,le+1)){he.ch=le+1;continue}var pe=he.text.lastIndexOf("/",le),me=pe>-1&&!/\S/.test(he.text.slice(pe+1,le));return he.ch=le+1,me?"selfClose":"regular"}}function It(he){for(;;){var le=he.ch?he.text.lastIndexOf("<",he.ch-1):-1;if(le==-1){if(wt(he))continue;return}if(!Mt(he,le+1)){he.ch=le;continue}Ie.lastIndex=le,he.ch=le;var pe=Ie.exec(he.text);if(pe&&pe.index==le)return pe}}function sn(he){for(;;){Ie.lastIndex=he.ch;var le=Ie.exec(he.text);if(!le){if(Pt(he))continue;return}if(!Mt(he,le.index+1)){he.ch=le.index+1;continue}return he.ch=le.index+le[0].length,le}}function Re(he){for(;;){var le=he.ch?he.text.lastIndexOf(">",he.ch-1):-1;if(le==-1){if(wt(he))continue;return}if(!Mt(he,le+1)){he.ch=le;continue}var pe=he.text.lastIndexOf("/",le),me=pe>-1&&!/\S/.test(he.text.slice(pe+1,le));return he.ch=le+1,me?"selfClose":"regular"}}function ne(he,le){for(var pe=[];;){var me=sn(he),xe,Ee=he.line,Ge=he.ch-(me?me[0].length:0);if(!me||!(xe=Qt(he)))return;if(xe!="selfClose")if(me[1]){for(var et=pe.length-1;et>=0;--et)if(pe[et]==me[2]){pe.length=et;break}if(et<0&&(!le||le==me[2]))return{tag:me[2],from:dt(Ee,Ge),to:dt(he.line,he.ch)}}else pe.push(me[2])}}function te(he,le){for(var pe=[];;){var me=Re(he);if(!me)return;if(me=="selfClose"){It(he);continue}var xe=he.line,Ee=he.ch,Ge=It(he);if(!Ge)return;if(Ge[1])pe.push(Ge[2]);else{for(var et=pe.length-1;et>=0;--et)if(pe[et]==Ge[2]){pe.length=et;break}if(et<0&&(!le||le==Ge[2]))return{tag:Ge[2],from:dt(he.line,he.ch),to:dt(xe,Ee)}}}}Ne.registerHelper("fold","xml",function(he,le){for(var pe=new $e(he,le.line,0);;){var me=sn(pe);if(!me||pe.line!=le.line)return;var xe=Qt(pe);if(!xe)return;if(!me[1]&&xe!="selfClose"){var Ee=dt(pe.line,pe.ch),Ge=ne(pe,me[2]);return Ge&&Ut(Ge.from,Ee)>0?{from:Ee,to:Ge.from}:null}}}),Ne.findMatchingTag=function(he,le,pe){var me=new $e(he,le.line,le.ch,pe);if(!(me.text.indexOf(">")==-1&&me.text.indexOf("<")==-1)){var xe=Qt(me),Ee=xe&&dt(me.line,me.ch),Ge=xe&&It(me);if(!(!xe||!Ge||Ut(me,le)>0)){var et={from:dt(me.line,me.ch),to:Ee,tag:Ge[2]};return xe=="selfClose"?{open:et,close:null,at:"open"}:Ge[1]?{open:te(me,Ge[2]),close:et,at:"close"}:(me=new $e(he,Ee.line,Ee.ch,pe),{open:et,close:ne(me,Ge[2]),at:"open"})}}},Ne.findEnclosingTag=function(he,le,pe,me){for(var xe=new $e(he,le.line,le.ch,pe);;){var Ee=te(xe,me);if(!Ee)break;var Ge=new $e(he,le.line,le.ch,pe),et=ne(Ge,Ee.tag);if(et)return{open:Ee,close:et}}},Ne.scanForClosingTag=function(he,le,pe,me){var xe=new $e(he,le.line,le.ch,me?{from:0,to:me}:null);return ne(xe,pe)}})},4631:function(jn){(function(li,De){jn.exports=De()})(this,function(){"use strict";var li=navigator.userAgent,De=navigator.platform,Ne=/gecko\/\d/i.test(li),dt=/MSIE \d/.test(li),Ut=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(li),$t=/Edge\/(\d+)/.exec(li),kt=dt||Ut||$t,Ie=kt&&(dt?document.documentMode||6:+($t||Ut)[1]),$e=!$t&&/WebKit\//.test(li),Mt=$e&&/Qt\/\d+\.\d+/.test(li),Pt=!$t&&/Chrome\//.test(li),wt=/Opera\//.test(li),Qt=/Apple Computer/.test(navigator.vendor),It=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(li),sn=/PhantomJS/.test(li),Re=!$t&&/AppleWebKit/.test(li)&&/Mobile\/\w+/.test(li),ne=/Android/.test(li),te=Re||ne||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(li),he=Re||/Mac/.test(De),le=/\bCrOS\b/.test(li),pe=/win/i.test(De),me=wt&&li.match(/Version\/(\d*\.\d*)/);me&&(me=Number(me[1])),me&&me>=15&&(wt=!1,$e=!0);var xe=he&&(Mt||wt&&(me==null||me<12.11)),Ee=Ne||kt&&Ie>=9;function Ge(ie){return new RegExp("(^|\\s)"+ie+"(?:$|\\s)\\s*")}var et=function(ie,ae){var de=ie.className,ce=Ge(ae).exec(de);if(ce){var ge=de.slice(ce.index+ce[0].length);ie.className=de.slice(0,ce.index)+(ge?ce[1]+ge:"")}};function ut(ie){for(var ae=ie.childNodes.length;ae>0;--ae)ie.removeChild(ie.firstChild);return ie}function st(ie,ae){return ut(ie).appendChild(ae)}function it(ie,ae,de,ce){var ge=document.createElement(ie);if(de&&(ge.className=de),ce&&(ge.style.cssText=ce),typeof ae=="string")ge.appendChild(document.createTextNode(ae));else if(ae)for(var Me=0;Me<ae.length;++Me)ge.appendChild(ae[Me]);return ge}function Nt(ie,ae,de,ce){var ge=it(ie,ae,de,ce);return ge.setAttribute("role","presentation"),ge}var St;document.createRange?St=function(ie,ae,de,ce){var ge=document.createRange();return ge.setEnd(ce||ie,de),ge.setStart(ie,ae),ge}:St=function(ie,ae,de){var ce=document.body.createTextRange();try{ce.moveToElementText(ie.parentNode)}catch(ge){return ce}return ce.collapse(!0),ce.moveEnd("character",de),ce.moveStart("character",ae),ce};function Ft(ie,ae){if(ae.nodeType==3&&(ae=ae.parentNode),ie.contains)return ie.contains(ae);do if(ae.nodeType==11&&(ae=ae.host),ae==ie)return!0;while(ae=ae.parentNode)}function cn(){var ie;try{ie=document.activeElement}catch(ae){ie=document.body||null}for(;ie&&ie.shadowRoot&&ie.shadowRoot.activeElement;)ie=ie.shadowRoot.activeElement;return ie}function Tt(ie,ae){var de=ie.className;Ge(ae).test(de)||(ie.className+=(de?" ":"")+ae)}function hi(ie,ae){for(var de=ie.split(" "),ce=0;ce<de.length;ce++)de[ce]&&!Ge(de[ce]).test(ae)&&(ae+=" "+de[ce]);return ae}var di=function(ie){ie.select()};Re?di=function(ie){ie.selectionStart=0,ie.selectionEnd=ie.value.length}:kt&&(di=function(ie){try{ie.select()}catch(ae){}});function zn(ie){var ae=Array.prototype.slice.call(arguments,1);return function(){return ie.apply(null,ae)}}function Dn(ie,ae,de){ae||(ae={});for(var ce in ie)ie.hasOwnProperty(ce)&&(de!==!1||!ae.hasOwnProperty(ce))&&(ae[ce]=ie[ce]);return ae}function nt(ie,ae,de,ce,ge){ae==null&&(ae=ie.search(/[^\s\u00a0]/),ae==-1&&(ae=ie.length));for(var Me=ce||0,He=ge||0;;){var Je=ie.indexOf(" ",Me);if(Je<0||Je>=ae)return He+(ae-Me);He+=Je-Me,He+=de-He%de,Me=Je+1}}var ze=function(){this.id=null,this.f=null,this.time=0,this.handler=zn(this.onTimeout,this)};ze.prototype.onTimeout=function(ie){ie.id=0,ie.time<=+new Date?ie.f():setTimeout(ie.handler,ie.time-+new Date)},ze.prototype.set=function(ie,ae){this.f=ae;var de=+new Date+ie;(!this.id||de<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,ie),this.time=de)};function ke(ie,ae){for(var de=0;de<ie.length;++de)if(ie[de]==ae)return de;return-1}var Wt=50,On={toString:function(){return"CodeMirror.Pass"}},Lt={scroll:!1},xn={origin:"*mouse"},vn={origin:"+move"};function Xn(ie,ae,de){for(var ce=0,ge=0;;){var Me=ie.indexOf(" ",ce);Me==-1&&(Me=ie.length);var He=Me-ce;if(Me==ie.length||ge+He>=ae)return ce+Math.min(He,ae-ge);if(ge+=Me-ce,ge+=de-ge%de,ce=Me+1,ge>=ae)return ce}}var Ot=[""];function ft(ie){for(;Ot.length<=ie;)Ot.push(Gt(Ot)+" ");return Ot[ie]}function Gt(ie){return ie[ie.length-1]}function an(ie,ae){for(var de=[],ce=0;ce<ie.length;ce++)de[ce]=ae(ie[ce],ce);return de}function Jt(ie,ae,de){for(var ce=0,ge=de(ae);ce<ie.length&&de(ie[ce])<=ge;)ce++;ie.splice(ce,0,ae)}function Ve(){}function be(ie,ae){var de;return Object.create?de=Object.create(ie):(Ve.prototype=ie,de=new Ve),ae&&Dn(ae,de),de}var Pe=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function Be(ie){return/\w/.test(ie)||ie>"\x80"&&(ie.toUpperCase()!=ie.toLowerCase()||Pe.test(ie))}function Ze(ie,ae){return ae?ae.source.indexOf("\\w")>-1&&Be(ie)?!0:ae.test(ie):Be(ie)}function Fe(ie){for(var ae in ie)if(ie.hasOwnProperty(ae)&&ie[ae])return!1;return!0}var qe=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function dn(ie){return ie.charCodeAt(0)>=768&&qe.test(ie)}function ui(ie,ae,de){for(;(de<0?ae>0:ae<ie.length)&&dn(ie.charAt(ae));)ae+=de;return ae}function $n(ie,ae,de){for(var ce=ae>de?-1:1;;){if(ae==de)return ae;var ge=(ae+de)/2,Me=ce<0?Math.ceil(ge):Math.floor(ge);if(Me==ae)return ie(Me)?ae:de;ie(Me)?de=Me:ae=Me+ce}}function rn(ie,ae,de,ce){if(!ie)return ce(ae,de,"ltr",0);for(var ge=!1,Me=0;Me<ie.length;++Me){var He=ie[Me];(He.from<de&&He.to>ae||ae==de&&He.to==ae)&&(ce(Math.max(He.from,ae),Math.min(He.to,de),He.level==1?"rtl":"ltr",Me),ge=!0)}ge||ce(ae,de,"ltr")}var Hn=null;function Zt(ie,ae,de){var ce;Hn=null;for(var ge=0;ge<ie.length;++ge){var Me=ie[ge];if(Me.from<ae&&Me.to>ae)return ge;Me.to==ae&&(Me.from!=Me.to&&de=="before"?ce=ge:Hn=ge),Me.from==ae&&(Me.from!=Me.to&&de!="before"?ce=ge:Hn=ge)}return ce!=null?ce:Hn}var _n=function(){var ie="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",ae="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function de(lt){return lt<=247?ie.charAt(lt):1424<=lt&&lt<=1524?"R":1536<=lt&&lt<=1785?ae.charAt(lt-1536):1774<=lt&&lt<=2220?"r":8192<=lt&&lt<=8203?"w":lt==8204?"b":"L"}var ce=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,ge=/[stwN]/,Me=/[LRr]/,He=/[Lb1n]/,Je=/[1n]/;function _e(lt,_t,mt){this.level=lt,this.from=_t,this.to=mt}return function(lt,_t){var mt=_t=="ltr"?"L":"R";if(lt.length==0||_t=="ltr"&&!ce.test(lt))return!1;for(var Cn=lt.length,mn=[],xi=0;xi<Cn;++xi)mn.push(de(lt.charCodeAt(xi)));for(var Mi=0,Yi=mt;Mi<Cn;++Mi){var Cr=mn[Mi];Cr=="m"?mn[Mi]=Yi:Yi=Cr}for(var ao=0,Gr=mt;ao<Cn;++ao){var wo=mn[ao];wo=="1"&&Gr=="r"?mn[ao]="n":Me.test(wo)&&(Gr=wo,wo=="r"&&(mn[ao]="R"))}for(var ua=1,Hr=mn[0];ua<Cn-1;++ua){var _a=mn[ua];_a=="+"&&Hr=="1"&&mn[ua+1]=="1"?mn[ua]="1":_a==","&&Hr==mn[ua+1]&&(Hr=="1"||Hr=="n")&&(mn[ua]=Hr),Hr=_a}for(var fl=0;fl<Cn;++fl){var uu=mn[fl];if(uu==",")mn[fl]="N";else if(uu=="%"){var Cl=void 0;for(Cl=fl+1;Cl<Cn&&mn[Cl]=="%";++Cl);for(var gh=fl&&mn[fl-1]=="!"||Cl<Cn&&mn[Cl]=="1"?"1":"N",Wu=fl;Wu<Cl;++Wu)mn[Wu]=gh;fl=Cl-1}}for(var ql=0,Ah=mt;ql<Cn;++ql){var Bu=mn[ql];Ah=="L"&&Bu=="1"?mn[ql]="L":Me.test(Bu)&&(Ah=Bu)}for(var $l=0;$l<Cn;++$l)if(ge.test(mn[$l])){var ks=void 0;for(ks=$l+1;ks<Cn&&ge.test(mn[ks]);++ks);for(var kl=($l?mn[$l-1]:mt)=="L",yu=(ks<Cn?mn[ks]:mt)=="L",Ou=kl==yu?kl?"L":"R":mt,gc=$l;gc<ks;++gc)mn[gc]=Ou;$l=ks-1}for(var El=[],ic,Rl=0;Rl<Cn;)if(He.test(mn[Rl])){var zf=Rl;for(++Rl;Rl<Cn&&He.test(mn[Rl]);++Rl);El.push(new _e(0,zf,Rl))}else{var Uh=Rl,Nh=El.length,ph=_t=="rtl"?1:0;for(++Rl;Rl<Cn&&mn[Rl]!="L";++Rl);for(var Ys=Uh;Ys<Rl;)if(Je.test(mn[Ys])){Uh<Ys&&(El.splice(Nh,0,new _e(1,Uh,Ys)),Nh+=ph);var Su=Ys;for(++Ys;Ys<Rl&&Je.test(mn[Ys]);++Ys);El.splice(Nh,0,new _e(2,Su,Ys)),Nh+=ph,Uh=Ys}else++Ys;Uh<Rl&&El.splice(Nh,0,new _e(1,Uh,Rl))}return _t=="ltr"&&(El[0].level==1&&(ic=lt.match(/^\s+/))&&(El[0].from=ic[0].length,El.unshift(new _e(0,0,ic[0].length))),Gt(El).level==1&&(ic=lt.match(/\s+$/))&&(Gt(El).to-=ic[0].length,El.push(new _e(0,Cn-ic[0].length,Cn)))),_t=="rtl"?El.reverse():El}}();function ti(ie,ae){var de=ie.order;return de==null&&(de=ie.order=_n(ie.text,ae)),de}var Ri=[],oi=function(ie,ae,de){if(ie.addEventListener)ie.addEventListener(ae,de,!1);else if(ie.attachEvent)ie.attachEvent("on"+ae,de);else{var ce=ie._handlers||(ie._handlers={});ce[ae]=(ce[ae]||Ri).concat(de)}};function wr(ie,ae){return ie._handlers&&ie._handlers[ae]||Ri}function fr(ie,ae,de){if(ie.removeEventListener)ie.removeEventListener(ae,de,!1);else if(ie.detachEvent)ie.detachEvent("on"+ae,de);else{var ce=ie._handlers,ge=ce&&ce[ae];if(ge){var Me=ke(ge,de);Me>-1&&(ce[ae]=ge.slice(0,Me).concat(ge.slice(Me+1)))}}}function Ei(ie,ae){var de=wr(ie,ae);if(de.length)for(var ce=Array.prototype.slice.call(arguments,2),ge=0;ge<de.length;++ge)de[ge].apply(null,ce)}function Di(ie,ae,de){return typeof ae=="string"&&(ae={type:ae,preventDefault:function(){this.defaultPrevented=!0}}),Ei(ie,de||ae.type,ie,ae),Ui(ae)||ae.codemirrorIgnore}function uo(ie){var ae=ie._handlers&&ie._handlers.cursorActivity;if(ae)for(var de=ie.curOp.cursorActivityHandlers||(ie.curOp.cursorActivityHandlers=[]),ce=0;ce<ae.length;++ce)ke(de,ae[ce])==-1&&de.push(ae[ce])}function vt(ie,ae){return wr(ie,ae).length>0}function ei(ie){ie.prototype.on=function(ae,de){oi(this,ae,de)},ie.prototype.off=function(ae,de){fr(this,ae,de)}}function co(ie){ie.preventDefault?ie.preventDefault():ie.returnValue=!1}function bo(ie){ie.stopPropagation?ie.stopPropagation():ie.cancelBubble=!0}function Ui(ie){return ie.defaultPrevented!=null?ie.defaultPrevented:ie.returnValue==!1}function yo(ie){co(ie),bo(ie)}function ha(ie){return ie.target||ie.srcElement}function Ka(ie){var ae=ie.which;return ae==null&&(ie.button&1?ae=1:ie.button&2?ae=3:ie.button&4&&(ae=2)),he&&ie.ctrlKey&&ae==1&&(ae=3),ae}var Ra=function(){if(kt&&Ie<9)return!1;var ie=it("div");return"draggable"in ie||"dragDrop"in ie}(),ca;function ma(ie){if(ca==null){var ae=it("span","\u200B");st(ie,it("span",[ae,document.createTextNode("x")])),ie.firstChild.offsetHeight!=0&&(ca=ae.offsetWidth<=1&&ae.offsetHeight>2&&!(kt&&Ie<8))}var de=ca?it("span","\u200B"):it("span","\xA0",null,"display: inline-block; width: 1px; margin-right: -1px");return de.setAttribute("cm-text",""),de}var Ho;function _r(ie){if(Ho!=null)return Ho;var ae=st(ie,document.createTextNode("A\u062EA")),de=St(ae,0,1).getBoundingClientRect(),ce=St(ae,1,2).getBoundingClientRect();return ut(ie),!de||de.left==de.right?!1:Ho=ce.right-de.right<3}var Fn=`
b`.split(/\n/).length!=3?function(ie){for(var ae=0,de=[],ce=ie.length;ae<=ce;){var ge=ie.indexOf(`
`,ae);ge==-1&&(ge=ie.length);var Me=ie.slice(ae,ie.charAt(ge-1)=="\r"?ge-1:ge),He=Me.indexOf("\r");He!=-1?(de.push(Me.slice(0,He)),ae+=He+1):(de.push(Me),ae=ge+1)}return de}:function(ie){return ie.split(/\r\n?|\n/)},we=window.getSelection?function(ie){try{return ie.selectionStart!=ie.selectionEnd}catch(ae){return!1}}:function(ie){var ae;try{ae=ie.ownerDocument.selection.createRange()}catch(de){}return!ae||ae.parentElement()!=ie?!1:ae.compareEndPoints("StartToEnd",ae)!=0},Qn=function(){var ie=it("div");return"oncopy"in ie?!0:(ie.setAttribute("oncopy","return;"),typeof ie.oncopy=="function")}(),bn=null;function on(ie){if(bn!=null)return bn;var ae=st(ie,it("span","x")),de=ae.getBoundingClientRect(),ce=St(ae,0,1).getBoundingClientRect();return bn=Math.abs(de.left-ce.left)>1}var ln={},gn={};function Vn(ie,ae){arguments.length>2&&(ae.dependencies=Array.prototype.slice.call(arguments,2)),ln[ie]=ae}function _i(ie,ae){gn[ie]=ae}function jt(ie){if(typeof ie=="string"&&gn.hasOwnProperty(ie))ie=gn[ie];else if(ie&&typeof ie.name=="string"&&gn.hasOwnProperty(ie.name)){var ae=gn[ie.name];typeof ae=="string"&&(ae={name:ae}),ie=be(ae,ie),ie.name=ae.name}else{if(typeof ie=="string"&&/^[\w\-]+\/[\w\-]+\+xml$/.test(ie))return jt("application/xml");if(typeof ie=="string"&&/^[\w\-]+\/[\w\-]+\+json$/.test(ie))return jt("application/json")}return typeof ie=="string"?{name:ie}:ie||{name:"null"}}function zt(ie,ae){ae=jt(ae);var de=ln[ae.name];if(!de)return zt(ie,"text/plain");var ce=de(ie,ae);if(Ct.hasOwnProperty(ae.name)){var ge=Ct[ae.name];for(var Me in ge)ge.hasOwnProperty(Me)&&(ce.hasOwnProperty(Me)&&(ce["_"+Me]=ce[Me]),ce[Me]=ge[Me])}if(ce.name=ae.name,ae.helperType&&(ce.helperType=ae.helperType),ae.modeProps)for(var He in ae.modeProps)ce[He]=ae.modeProps[He];return ce}var Ct={};function Yt(ie,ae){var de=Ct.hasOwnProperty(ie)?Ct[ie]:Ct[ie]={};Dn(ae,de)}function ci(ie,ae){if(ae===!0)return ae;if(ie.copyState)return ie.copyState(ae);var de={};for(var ce in ae){var ge=ae[ce];ge instanceof Array&&(ge=ge.concat([])),de[ce]=ge}return de}function vi(ie,ae){for(var de;ie.innerMode&&(de=ie.innerMode(ae),!(!de||de.mode==ie));)ae=de.state,ie=de.mode;return de||{mode:ie,state:ae}}function ai(ie,ae,de){return ie.startState?ie.startState(ae,de):!0}var Kt=function(ie,ae,de){this.pos=this.start=0,this.string=ie,this.tabSize=ae||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=de};Kt.prototype.eol=function(){return this.pos>=this.string.length},Kt.prototype.sol=function(){return this.pos==this.lineStart},Kt.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Kt.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},Kt.prototype.eat=function(ie){var ae=this.string.charAt(this.pos),de;if(typeof ie=="string"?de=ae==ie:de=ae&&(ie.test?ie.test(ae):ie(ae)),de)return++this.pos,ae},Kt.prototype.eatWhile=function(ie){for(var ae=this.pos;this.eat(ie););return this.pos>ae},Kt.prototype.eatSpace=function(){for(var ie=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>ie},Kt.prototype.skipToEnd=function(){this.pos=this.string.length},Kt.prototype.skipTo=function(ie){var ae=this.string.indexOf(ie,this.pos);if(ae>-1)return this.pos=ae,!0},Kt.prototype.backUp=function(ie){this.pos-=ie},Kt.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=nt(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?nt(this.string,this.lineStart,this.tabSize):0)},Kt.prototype.indentation=function(){return nt(this.string,null,this.tabSize)-(this.lineStart?nt(this.string,this.lineStart,this.tabSize):0)},Kt.prototype.match=function(ie,ae,de){if(typeof ie=="string"){var ce=function(He){return de?He.toLowerCase():He},ge=this.string.substr(this.pos,ie.length);if(ce(ge)==ce(ie))return ae!==!1&&(this.pos+=ie.length),!0}else{var Me=this.string.slice(this.pos).match(ie);return Me&&Me.index>0?null:(Me&&ae!==!1&&(this.pos+=Me[0].length),Me)}},Kt.prototype.current=function(){return this.string.slice(this.start,this.pos)},Kt.prototype.hideFirstChars=function(ie,ae){this.lineStart+=ie;try{return ae()}finally{this.lineStart-=ie}},Kt.prototype.lookAhead=function(ie){var ae=this.lineOracle;return ae&&ae.lookAhead(ie)},Kt.prototype.baseToken=function(){var ie=this.lineOracle;return ie&&ie.baseToken(this.pos)};function wn(ie,ae){if(ae-=ie.first,ae<0||ae>=ie.size)throw new Error("There is no line "+(ae+ie.first)+" in the document.");for(var de=ie;!de.lines;)for(var ce=0;;++ce){var ge=de.children[ce],Me=ge.chunkSize();if(ae<Me){de=ge;break}ae-=Me}return de.lines[ae]}function pi(ie,ae,de){var ce=[],ge=ae.line;return ie.iter(ae.line,de.line+1,function(Me){var He=Me.text;ge==de.line&&(He=He.slice(0,de.ch)),ge==ae.line&&(He=He.slice(ae.ch)),ce.push(He),++ge}),ce}function ji(ie,ae,de){var ce=[];return ie.iter(ae,de,function(ge){ce.push(ge.text)}),ce}function Rn(ie,ae){var de=ae-ie.height;if(de)for(var ce=ie;ce;ce=ce.parent)ce.height+=de}function Dt(ie){if(ie.parent==null)return null;for(var ae=ie.parent,de=ke(ae.lines,ie),ce=ae.parent;ce;ae=ce,ce=ce.parent)for(var ge=0;ce.children[ge]!=ae;++ge)de+=ce.children[ge].chunkSize();return de+ae.first}function wi(ie,ae){var de=ie.first;e:do{for(var ce=0;ce<ie.children.length;++ce){var ge=ie.children[ce],Me=ge.height;if(ae<Me){ie=ge;continue e}ae-=Me,de+=ge.chunkSize()}return de}while(!ie.lines);for(var He=0;He<ie.lines.length;++He){var Je=ie.lines[He],_e=Je.height;if(ae<_e)break;ae-=_e}return de+He}function gr(ie,ae){return ae>=ie.first&&ae<ie.first+ie.size}function eo(ie,ae){return String(ie.lineNumberFormatter(ae+ie.firstLineNumber))}function kn(ie,ae,de){if(de===void 0&&(de=null),!(this instanceof kn))return new kn(ie,ae,de);this.line=ie,this.ch=ae,this.sticky=de}function Xi(ie,ae){return ie.line-ae.line||ie.ch-ae.ch}function Lo(ie,ae){return ie.sticky==ae.sticky&&Xi(ie,ae)==0}function La(ie){return kn(ie.line,ie.ch)}function $o(ie,ae){return Xi(ie,ae)<0?ae:ie}function qi(ie,ae){return Xi(ie,ae)<0?ie:ae}function Zi(ie,ae){return Math.max(ie.first,Math.min(ae,ie.first+ie.size-1))}function cr(ie,ae){if(ae.line<ie.first)return kn(ie.first,0);var de=ie.first+ie.size-1;return ae.line>de?kn(de,wn(ie,de).text.length):Co(ae,wn(ie,ae.line).text.length)}function Co(ie,ae){var de=ie.ch;return de==null||de>ae?kn(ie.line,ae):de<0?kn(ie.line,0):ie}function Zo(ie,ae){for(var de=[],ce=0;ce<ae.length;ce++)de[ce]=cr(ie,ae[ce]);return de}var ri=function(ie,ae){this.state=ie,this.lookAhead=ae},Lr=function(ie,ae,de,ce){this.state=ae,this.doc=ie,this.line=de,this.maxLookAhead=ce||0,this.baseTokens=null,this.baseTokenPos=1};Lr.prototype.lookAhead=function(ie){var ae=this.doc.getLine(this.line+ie);return ae!=null&&ie>this.maxLookAhead&&(this.maxLookAhead=ie),ae},Lr.prototype.baseToken=function(ie){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=ie;)this.baseTokenPos+=2;var ae=this.baseTokens[this.baseTokenPos+1];return{type:ae&&ae.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-ie}},Lr.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},Lr.fromSaved=function(ie,ae,de){return ae instanceof ri?new Lr(ie,ci(ie.mode,ae.state),de,ae.lookAhead):new Lr(ie,ci(ie.mode,ae),de)},Lr.prototype.save=function(ie){var ae=ie!==!1?ci(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new ri(ae,this.maxLookAhead):ae};function ml(ie,ae,de,ce){var ge=[ie.state.modeGen],Me={};ea(ie,ae.text,ie.doc.mode,de,function(lt,_t){return ge.push(lt,_t)},Me,ce);for(var He=de.state,Je=function(lt){de.baseTokens=ge;var _t=ie.state.overlays[lt],mt=1,Cn=0;de.state=!0,ea(ie,ae.text,_t.mode,de,function(mn,xi){for(var Mi=mt;Cn<mn;){var Yi=ge[mt];Yi>mn&&ge.splice(mt,1,mn,ge[mt+1],Yi),mt+=2,Cn=Math.min(mn,Yi)}if(xi)if(_t.opaque)ge.splice(Mi,mt-Mi,mn,"overlay "+xi),mt=Mi+2;else for(;Mi<mt;Mi+=2){var Cr=ge[Mi+1];ge[Mi+1]=(Cr?Cr+" ":"")+"overlay "+xi}},Me),de.state=He,de.baseTokens=null,de.baseTokenPos=1},_e=0;_e<ie.state.overlays.length;++_e)Je(_e);return{styles:ge,classes:Me.bgClass||Me.textClass?Me:null}}function Fs(ie,ae,de){if(!ae.styles||ae.styles[0]!=ie.state.modeGen){var ce=gs(ie,Dt(ae)),ge=ae.text.length>ie.options.maxHighlightLength&&ci(ie.doc.mode,ce.state),Me=ml(ie,ae,ce);ge&&(ce.state=ge),ae.stateAfter=ce.save(!ge),ae.styles=Me.styles,Me.classes?ae.styleClasses=Me.classes:ae.styleClasses&&(ae.styleClasses=null),de===ie.doc.highlightFrontier&&(ie.doc.modeFrontier=Math.max(ie.doc.modeFrontier,++ie.doc.highlightFrontier))}return ae.styles}function gs(ie,ae,de){var ce=ie.doc,ge=ie.display;if(!ce.mode.startState)return new Lr(ce,!0,ae);var Me=fo(ie,ae,de),He=Me>ce.first&&wn(ce,Me-1).stateAfter,Je=He?Lr.fromSaved(ce,He,Me):new Lr(ce,ai(ce.mode),Me);return ce.iter(Me,ae,function(_e){Vt(ie,_e.text,Je);var lt=Je.line;_e.stateAfter=lt==ae-1||lt%5==0||lt>=ge.viewFrom&&lt<ge.viewTo?Je.save():null,Je.nextLine()}),de&&(ce.modeFrontier=Je.line),Je}function Vt(ie,ae,de,ce){var ge=ie.doc.mode,Me=new Kt(ae,ie.options.tabSize,de);for(Me.start=Me.pos=ce||0,ae==""&&Kr(ge,de.state);!Me.eol();)Ko(ge,Me,de.state),Me.start=Me.pos}function Kr(ie,ae){if(ie.blankLine)return ie.blankLine(ae);if(ie.innerMode){var de=vi(ie,ae);if(de.mode.blankLine)return de.mode.blankLine(de.state)}}function Ko(ie,ae,de,ce){for(var ge=0;ge<10;ge++){ce&&(ce[0]=vi(ie,de).mode);var Me=ie.token(ae,de);if(ae.pos>ae.start)return Me}throw new Error("Mode "+ie.name+" failed to advance stream.")}var Er=function(ie,ae,de){this.start=ie.start,this.end=ie.pos,this.string=ie.current(),this.type=ae||null,this.state=de};function Wa(ie,ae,de,ce){var ge=ie.doc,Me=ge.mode,He;ae=cr(ge,ae);var Je=wn(ge,ae.line),_e=gs(ie,ae.line,de),lt=new Kt(Je.text,ie.options.tabSize,_e),_t;for(ce&&(_t=[]);(ce||lt.pos<ae.ch)&&!lt.eol();)lt.start=lt.pos,He=Ko(Me,lt,_e.state),ce&&_t.push(new Er(lt,He,ci(ge.mode,_e.state)));return ce?_t:new Er(lt,He,_e.state)}function Wo(ie,ae){if(ie)for(;;){var de=ie.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!de)break;ie=ie.slice(0,de.index)+ie.slice(de.index+de[0].length);var ce=de[1]?"bgClass":"textClass";ae[ce]==null?ae[ce]=de[2]:new RegExp("(?:^|\\s)"+de[2]+"(?:$|\\s)").test(ae[ce])||(ae[ce]+=" "+de[2])}return ie}function ea(ie,ae,de,ce,ge,Me,He){var Je=de.flattenSpans;Je==null&&(Je=ie.options.flattenSpans);var _e=0,lt=null,_t=new Kt(ae,ie.options.tabSize,ce),mt,Cn=ie.options.addModeClass&&[null];for(ae==""&&Wo(Kr(de,ce.state),Me);!_t.eol();){if(_t.pos>ie.options.maxHighlightLength?(Je=!1,He&&Vt(ie,ae,ce,_t.pos),_t.pos=ae.length,mt=null):mt=Wo(Ko(de,_t,ce.state,Cn),Me),Cn){var mn=Cn[0].name;mn&&(mt="m-"+(mt?mn+" "+mt:mn))}if(!Je||lt!=mt){for(;_e<_t.start;)_e=Math.min(_t.start,_e+5e3),ge(_e,lt);lt=mt}_t.start=_t.pos}for(;_e<_t.pos;){var xi=Math.min(_t.pos,_e+5e3);ge(xi,lt),_e=xi}}function fo(ie,ae,de){for(var ce,ge,Me=ie.doc,He=de?-1:ae-(ie.doc.mode.innerMode?1e3:100),Je=ae;Je>He;--Je){if(Je<=Me.first)return Me.first;var _e=wn(Me,Je-1),lt=_e.stateAfter;if(lt&&(!de||Je+(lt instanceof ri?lt.lookAhead:0)<=Me.modeFrontier))return Je;var _t=nt(_e.text,null,ie.options.tabSize);(ge==null||ce>_t)&&(ge=Je-1,ce=_t)}return ge}function Oo(ie,ae){if(ie.modeFrontier=Math.min(ie.modeFrontier,ae),!(ie.highlightFrontier<ae-10)){for(var de=ie.first,ce=ae-1;ce>de;ce--){var ge=wn(ie,ce).stateAfter;if(ge&&(!(ge instanceof ri)||ce+ge.lookAhead<ae)){de=ce+1;break}}ie.highlightFrontier=Math.min(ie.highlightFrontier,de)}}var xa=!1,An=!1;function Ya(){xa=!0}function Pn(){An=!0}function jo(ie,ae,de){this.marker=ie,this.from=ae,this.to=de}function Ws(ie,ae){if(ie)for(var de=0;de<ie.length;++de){var ce=ie[de];if(ce.marker==ae)return ce}}function qa(ie,ae){for(var de,ce=0;ce<ie.length;++ce)ie[ce]!=ae&&(de||(de=[])).push(ie[ce]);return de}function bl(ie,ae){ie.markedSpans=ie.markedSpans?ie.markedSpans.concat([ae]):[ae],ae.marker.attachLine(ie)}function Xa(ie,ae,de){var ce;if(ie)for(var ge=0;ge<ie.length;++ge){var Me=ie[ge],He=Me.marker,Je=Me.from==null||(He.inclusiveLeft?Me.from<=ae:Me.from<ae);if(Je||Me.from==ae&&He.type=="bookmark"&&(!de||!Me.marker.insertLeft)){var _e=Me.to==null||(He.inclusiveRight?Me.to>=ae:Me.to>ae);(ce||(ce=[])).push(new jo(He,Me.from,_e?null:Me.to))}}return ce}function _o(ie,ae,de){var ce;if(ie)for(var ge=0;ge<ie.length;++ge){var Me=ie[ge],He=Me.marker,Je=Me.to==null||(He.inclusiveRight?Me.to>=ae:Me.to>ae);if(Je||Me.from==ae&&He.type=="bookmark"&&(!de||Me.marker.insertLeft)){var _e=Me.from==null||(He.inclusiveLeft?Me.from<=ae:Me.from<ae);(ce||(ce=[])).push(new jo(He,_e?null:Me.from-ae,Me.to==null?null:Me.to-ae))}}return ce}function Va(ie,ae){if(ae.full)return null;var de=gr(ie,ae.from.line)&&wn(ie,ae.from.line).markedSpans,ce=gr(ie,ae.to.line)&&wn(ie,ae.to.line).markedSpans;if(!de&&!ce)return null;var ge=ae.from.ch,Me=ae.to.ch,He=Xi(ae.from,ae.to)==0,Je=Xa(de,ge,He),_e=_o(ce,Me,He),lt=ae.text.length==1,_t=Gt(ae.text).length+(lt?ge:0);if(Je)for(var mt=0;mt<Je.length;++mt){var Cn=Je[mt];if(Cn.to==null){var mn=Ws(_e,Cn.marker);mn?lt&&(Cn.to=mn.to==null?null:mn.to+_t):Cn.to=ge}}if(_e)for(var xi=0;xi<_e.length;++xi){var Mi=_e[xi];if(Mi.to!=null&&(Mi.to+=_t),Mi.from==null){var Yi=Ws(Je,Mi.marker);Yi||(Mi.from=_t,lt&&(Je||(Je=[])).push(Mi))}else Mi.from+=_t,lt&&(Je||(Je=[])).push(Mi)}Je&&(Je=il(Je)),_e&&_e!=Je&&(_e=il(_e));var Cr=[Je];if(!lt){var ao=ae.text.length-2,Gr;if(ao>0&&Je)for(var wo=0;wo<Je.length;++wo)Je[wo].to==null&&(Gr||(Gr=[])).push(new jo(Je[wo].marker,null,null));for(var ua=0;ua<ao;++ua)Cr.push(Gr);Cr.push(_e)}return Cr}function il(ie){for(var ae=0;ae<ie.length;++ae){var de=ie[ae];de.from!=null&&de.from==de.to&&de.marker.clearWhenEmpty!==!1&&ie.splice(ae--,1)}return ie.length?ie:null}function Na(ie,ae,de){var ce=null;if(ie.iter(ae.line,de.line+1,function(mn){if(mn.markedSpans)for(var xi=0;xi<mn.markedSpans.length;++xi){var Mi=mn.markedSpans[xi].marker;Mi.readOnly&&(!ce||ke(ce,Mi)==-1)&&(ce||(ce=[])).push(Mi)}}),!ce)return null;for(var ge=[{from:ae,to:de}],Me=0;Me<ce.length;++Me)for(var He=ce[Me],Je=He.find(0),_e=0;_e<ge.length;++_e){var lt=ge[_e];if(!(Xi(lt.to,Je.from)<0||Xi(lt.from,Je.to)>0)){var _t=[_e,1],mt=Xi(lt.from,Je.from),Cn=Xi(lt.to,Je.to);(mt<0||!He.inclusiveLeft&&!mt)&&_t.push({from:lt.from,to:Je.from}),(Cn>0||!He.inclusiveRight&&!Cn)&&_t.push({from:Je.to,to:lt.to}),ge.splice.apply(ge,_t),_e+=_t.length-3}}return ge}function Li(ie){var ae=ie.markedSpans;if(ae){for(var de=0;de<ae.length;++de)ae[de].marker.detachLine(ie);ie.markedSpans=null}}function Qe(ie,ae){if(ae){for(var de=0;de<ae.length;++de)ae[de].marker.attachLine(ie);ie.markedSpans=ae}}function bs(ie){return ie.inclusiveLeft?-1:0}function Ul(ie){return ie.inclusiveRight?1:0}function Zl(ie,ae){var de=ie.lines.length-ae.lines.length;if(de!=0)return de;var ce=ie.find(),ge=ae.find(),Me=Xi(ce.from,ge.from)||bs(ie)-bs(ae);if(Me)return-Me;var He=Xi(ce.to,ge.to)||Ul(ie)-Ul(ae);return He||ae.id-ie.id}function rl(ie,ae){var de=An&&ie.markedSpans,ce;if(de)for(var ge=void 0,Me=0;Me<de.length;++Me)ge=de[Me],ge.marker.collapsed&&(ae?ge.from:ge.to)==null&&(!ce||Zl(ce,ge.marker)<0)&&(ce=ge.marker);return ce}function tu(ie){return rl(ie,!0)}function Il(ie){return rl(ie,!1)}function Hu(ie,ae){var de=An&&ie.markedSpans,ce;if(de)for(var ge=0;ge<de.length;++ge){var Me=de[ge];Me.marker.collapsed&&(Me.from==null||Me.from<ae)&&(Me.to==null||Me.to>ae)&&(!ce||Zl(ce,Me.marker)<0)&&(ce=Me.marker)}return ce}function nu(ie,ae,de,ce,ge){var Me=wn(ie,ae),He=An&&Me.markedSpans;if(He)for(var Je=0;Je<He.length;++Je){var _e=He[Je];if(_e.marker.collapsed){var lt=_e.marker.find(0),_t=Xi(lt.from,de)||bs(_e.marker)-bs(ge),mt=Xi(lt.to,ce)||Ul(_e.marker)-Ul(ge);if(!(_t>=0&&mt<=0||_t<=0&&mt>=0)&&(_t<=0&&(_e.marker.inclusiveRight&&ge.inclusiveLeft?Xi(lt.to,de)>=0:Xi(lt.to,de)>0)||_t>=0&&(_e.marker.inclusiveRight&&ge.inclusiveLeft?Xi(lt.from,ce)<=0:Xi(lt.from,ce)<0)))return!0}}}function Ua(ie){for(var ae;ae=tu(ie);)ie=ae.find(-1,!0).line;return ie}function ps(ie){for(var ae;ae=Il(ie);)ie=ae.find(1,!0).line;return ie}function Or(ie){for(var ae,de;ae=Il(ie);)ie=ae.find(1,!0).line,(de||(de=[])).push(ie);return de}function Pr(ie,ae){var de=wn(ie,ae),ce=Ua(de);return de==ce?ae:Dt(ce)}function so(ie,ae){if(ae>ie.lastLine())return ae;var de=wn(ie,ae),ce;if(!fn(ie,de))return ae;for(;ce=Il(de);)de=ce.find(1,!0).line;return Dt(de)+1}function fn(ie,ae){var de=An&&ae.markedSpans;if(de){for(var ce=void 0,ge=0;ge<de.length;++ge)if(ce=de[ge],!!ce.marker.collapsed){if(ce.from==null)return!0;if(!ce.marker.widgetNode&&ce.from==0&&ce.marker.inclusiveLeft&&jr(ie,ae,ce))return!0}}}function jr(ie,ae,de){if(de.to==null){var ce=de.marker.find(1,!0);return jr(ie,ce.line,Ws(ce.line.markedSpans,de.marker))}if(de.marker.inclusiveRight&&de.to==ae.text.length)return!0;for(var ge=void 0,Me=0;Me<ae.markedSpans.length;++Me)if(ge=ae.markedSpans[Me],ge.marker.collapsed&&!ge.marker.widgetNode&&ge.from==de.to&&(ge.to==null||ge.to!=de.from)&&(ge.marker.inclusiveLeft||de.marker.inclusiveRight)&&jr(ie,ae,ge))return!0}function Ao(ie){ie=Ua(ie);for(var ae=0,de=ie.parent,ce=0;ce<de.lines.length;++ce){var ge=de.lines[ce];if(ge==ie)break;ae+=ge.height}for(var Me=de.parent;Me;de=Me,Me=de.parent)for(var He=0;He<Me.children.length;++He){var Je=Me.children[He];if(Je==de)break;ae+=Je.height}return ae}function $a(ie){if(ie.height==0)return 0;for(var ae=ie.text.length,de,ce=ie;de=tu(ce);){var ge=de.find(0,!0);ce=ge.from.line,ae+=ge.from.ch-ge.to.ch}for(ce=ie;de=Il(ce);){var Me=de.find(0,!0);ae-=ce.text.length-Me.from.ch,ce=Me.to.line,ae+=ce.text.length-Me.to.ch}return ae}function Ia(ie){var ae=ie.display,de=ie.doc;ae.maxLine=wn(de,de.first),ae.maxLineLength=$a(ae.maxLine),ae.maxLineChanged=!0,de.iter(function(ce){var ge=$a(ce);ge>ae.maxLineLength&&(ae.maxLineLength=ge,ae.maxLine=ce)})}var ms=function(ie,ae,de){this.text=ie,Qe(this,ae),this.height=de?de(this):1};ms.prototype.lineNo=function(){return Dt(this)},ei(ms);function Vs(ie,ae,de,ce){ie.text=ae,ie.stateAfter&&(ie.stateAfter=null),ie.styles&&(ie.styles=null),ie.order!=null&&(ie.order=null),Li(ie),Qe(ie,de);var ge=ce?ce(ie):1;ge!=ie.height&&Rn(ie,ge)}function el(ie){ie.parent=null,Li(ie)}var vl={},Gu={};function Fu(ie,ae){if(!ie||/^\s*$/.test(ie))return null;var de=ae.addModeClass?Gu:vl;return de[ie]||(de[ie]=ie.replace(/\S+/g,"cm-$&"))}function Xt(ie,ae){var de=Nt("span",null,null,$e?"padding-right: .1px":null),ce={pre:Nt("pre",[de],"CodeMirror-line"),content:de,col:0,pos:0,cm:ie,trailingSpace:!1,splitSpaces:ie.getOption("lineWrapping")};ae.measure={};for(var ge=0;ge<=(ae.rest?ae.rest.length:0);ge++){var Me=ge?ae.rest[ge-1]:ae.line,He=void 0;ce.pos=0,ce.addToken=zl,_r(ie.display.measure)&&(He=ti(Me,ie.doc.direction))&&(ce.addToken=As(ce.addToken,He)),ce.map=[];var Je=ae!=ie.display.externalMeasured&&Dt(Me);xh(Me,ce,Fs(ie,Me,Je)),Me.styleClasses&&(Me.styleClasses.bgClass&&(ce.bgClass=hi(Me.styleClasses.bgClass,ce.bgClass||"")),Me.styleClasses.textClass&&(ce.textClass=hi(Me.styleClasses.textClass,ce.textClass||""))),ce.map.length==0&&ce.map.push(0,0,ce.content.appendChild(ma(ie.display.measure))),ge==0?(ae.measure.map=ce.map,ae.measure.cache={}):((ae.measure.maps||(ae.measure.maps=[])).push(ce.map),(ae.measure.caches||(ae.measure.caches=[])).push({}))}if($e){var _e=ce.content.lastChild;(/\bcm-tab\b/.test(_e.className)||_e.querySelector&&_e.querySelector(".cm-tab"))&&(ce.content.className="cm-tab-wrap-hack")}return Ei(ie,"renderLine",ie,ae.line,ce.pre),ce.pre.className&&(ce.textClass=hi(ce.pre.className,ce.textClass||"")),ce}function Ll(ie){var ae=it("span","\u2022","cm-invalidchar");return ae.title="\\u"+ie.charCodeAt(0).toString(16),ae.setAttribute("aria-label",ae.title),ae}function zl(ie,ae,de,ce,ge,Me,He){if(ae){var Je=ie.splitSpaces?fu(ae,ie.trailingSpace):ae,_e=ie.cm.state.specialChars,lt=!1,_t;if(!_e.test(ae))ie.col+=ae.length,_t=document.createTextNode(Je),ie.map.push(ie.pos,ie.pos+ae.length,_t),kt&&Ie<9&&(lt=!0),ie.pos+=ae.length;else{_t=document.createDocumentFragment();for(var mt=0;;){_e.lastIndex=mt;var Cn=_e.exec(ae),mn=Cn?Cn.index-mt:ae.length-mt;if(mn){var xi=document.createTextNode(Je.slice(mt,mt+mn));kt&&Ie<9?_t.appendChild(it("span",[xi])):_t.appendChild(xi),ie.map.push(ie.pos,ie.pos+mn,xi),ie.col+=mn,ie.pos+=mn}if(!Cn)break;mt+=mn+1;var Mi=void 0;if(Cn[0]==" "){var Yi=ie.cm.options.tabSize,Cr=Yi-ie.col%Yi;Mi=_t.appendChild(it("span",ft(Cr),"cm-tab")),Mi.setAttribute("role","presentation"),Mi.setAttribute("cm-text"," "),ie.col+=Cr}else Cn[0]=="\r"||Cn[0]==`
`?(Mi=_t.appendChild(it("span",Cn[0]=="\r"?"\u240D":"\u2424","cm-invalidchar")),Mi.setAttribute("cm-text",Cn[0]),ie.col+=1):(Mi=ie.cm.options.specialCharPlaceholder(Cn[0]),Mi.setAttribute("cm-text",Cn[0]),kt&&Ie<9?_t.appendChild(it("span",[Mi])):_t.appendChild(Mi),ie.col+=1);ie.map.push(ie.pos,ie.pos+1,Mi),ie.pos++}}if(ie.trailingSpace=Je.charCodeAt(ae.length-1)==32,de||ce||ge||lt||Me||He){var ao=de||"";ce&&(ao+=ce),ge&&(ao+=ge);var Gr=it("span",[_t],ao,Me);if(He)for(var wo in He)He.hasOwnProperty(wo)&&wo!="style"&&wo!="class"&&Gr.setAttribute(wo,He[wo]);return ie.content.appendChild(Gr)}ie.content.appendChild(_t)}}function fu(ie,ae){if(ie.length>1&&!/ /.test(ie))return ie;for(var de=ae,ce="",ge=0;ge<ie.length;ge++){var Me=ie.charAt(ge);Me==" "&&de&&(ge==ie.length-1||ie.charCodeAt(ge+1)==32)&&(Me="\xA0"),ce+=Me,de=Me==" "}return ce}function As(ie,ae){return function(de,ce,ge,Me,He,Je,_e){ge=ge?ge+" cm-force-border":"cm-force-border";for(var lt=de.pos,_t=lt+ce.length;;){for(var mt=void 0,Cn=0;Cn<ae.length&&(mt=ae[Cn],!(mt.to>lt&&mt.from<=lt));Cn++);if(mt.to>=_t)return ie(de,ce,ge,Me,He,Je,_e);ie(de,ce.slice(0,mt.to-lt),ge,Me,null,Je,_e),Me=null,ce=ce.slice(mt.to-lt),lt=mt.to}}}function gu(ie,ae,de,ce){var ge=!ce&&de.widgetNode;ge&&ie.map.push(ie.pos,ie.pos+ae,ge),!ce&&ie.cm.display.input.needsContentAttribute&&(ge||(ge=ie.content.appendChild(document.createElement("span"))),ge.setAttribute("cm-marker",de.id)),ge&&(ie.cm.display.input.setUneditable(ge),ie.content.appendChild(ge)),ie.pos+=ae,ie.trailingSpace=!1}function xh(ie,ae,de){var ce=ie.markedSpans,ge=ie.text,Me=0;if(!ce){for(var He=1;He<de.length;He+=2)ae.addToken(ae,ge.slice(Me,Me=de[He]),Fu(de[He+1],ae.cm.options));return}for(var Je=ge.length,_e=0,lt=1,_t="",mt,Cn,mn=0,xi,Mi,Yi,Cr,ao;;){if(mn==_e){xi=Mi=Yi=Cn="",ao=null,Cr=null,mn=1/0;for(var Gr=[],wo=void 0,ua=0;ua<ce.length;++ua){var Hr=ce[ua],_a=Hr.marker;if(_a.type=="bookmark"&&Hr.from==_e&&_a.widgetNode)Gr.push(_a);else if(Hr.from<=_e&&(Hr.to==null||Hr.to>_e||_a.collapsed&&Hr.to==_e&&Hr.from==_e)){if(Hr.to!=null&&Hr.to!=_e&&mn>Hr.to&&(mn=Hr.to,Mi=""),_a.className&&(xi+=" "+_a.className),_a.css&&(Cn=(Cn?Cn+";":"")+_a.css),_a.startStyle&&Hr.from==_e&&(Yi+=" "+_a.startStyle),_a.endStyle&&Hr.to==mn&&(wo||(wo=[])).push(_a.endStyle,Hr.to),_a.title&&((ao||(ao={})).title=_a.title),_a.attributes)for(var fl in _a.attributes)(ao||(ao={}))[fl]=_a.attributes[fl];_a.collapsed&&(!Cr||Zl(Cr.marker,_a)<0)&&(Cr=Hr)}else Hr.from>_e&&mn>Hr.from&&(mn=Hr.from)}if(wo)for(var uu=0;uu<wo.length;uu+=2)wo[uu+1]==mn&&(Mi+=" "+wo[uu]);if(!Cr||Cr.from==_e)for(var Cl=0;Cl<Gr.length;++Cl)gu(ae,0,Gr[Cl]);if(Cr&&(Cr.from||0)==_e){if(gu(ae,(Cr.to==null?Je+1:Cr.to)-_e,Cr.marker,Cr.from==null),Cr.to==null)return;Cr.to==_e&&(Cr=!1)}}if(_e>=Je)break;for(var gh=Math.min(Je,mn);;){if(_t){var Wu=_e+_t.length;if(!Cr){var ql=Wu>gh?_t.slice(0,gh-_e):_t;ae.addToken(ae,ql,mt?mt+xi:xi,Yi,_e+ql.length==mn?Mi:"",Cn,ao)}if(Wu>=gh){_t=_t.slice(gh-_e),_e=gh;break}_e=Wu,Yi=""}_t=ge.slice(Me,Me=de[lt++]),mt=Fu(de[lt++],ae.cm.options)}}}function Xu(ie,ae,de){this.line=ae,this.rest=Or(ae),this.size=this.rest?Dt(Gt(this.rest))-de+1:1,this.node=this.text=null,this.hidden=fn(ie,ae)}function es(ie,ae,de){for(var ce=[],ge,Me=ae;Me<de;Me=ge){var He=new Xu(ie.doc,wn(ie.doc,Me),Me);ge=Me+He.size,ce.push(He)}return ce}var Ds=null;function Mo(ie){Ds?Ds.ops.push(ie):ie.ownsGroup=Ds={ops:[ie],delayedCallbacks:[]}}function Ro(ie){var ae=ie.delayedCallbacks,de=0;do{for(;de<ae.length;de++)ae[de].call(null);for(var ce=0;ce<ie.ops.length;ce++){var ge=ie.ops[ce];if(ge.cursorActivityHandlers)for(;ge.cursorActivityCalled<ge.cursorActivityHandlers.length;)ge.cursorActivityHandlers[ge.cursorActivityCalled++].call(null,ge.cm)}}while(de<ae.length)}function Ma(ie,ae){var de=ie.ownsGroup;if(de)try{Ro(de)}finally{Ds=null,ae(de)}}var Ls=null;function vr(ie,ae){var de=wr(ie,ae);if(de.length){var ce=Array.prototype.slice.call(arguments,2),ge;Ds?ge=Ds.delayedCallbacks:Ls?ge=Ls:(ge=Ls=[],setTimeout($h,0));for(var Me=function(Je){ge.push(function(){return de[Je].apply(null,ce)})},He=0;He<de.length;++He)Me(He)}}function $h(){var ie=Ls;Ls=null;for(var ae=0;ae<ie.length;++ae)ie[ae]()}function Nl(ie,ae,de,ce){for(var ge=0;ge<ae.changes.length;ge++){var Me=ae.changes[ge];Me=="text"?Bi(ie,ae):Me=="gutter"?Cs(ie,ae,de,ce):Me=="class"?Ms(ie,ae):Me=="widget"&&_l(ie,ae,ce)}ae.changes=null}function Tl(ie){return ie.node==ie.text&&(ie.node=it("div",null,null,"position: relative"),ie.text.parentNode&&ie.text.parentNode.replaceChild(ie.node,ie.text),ie.node.appendChild(ie.text),kt&&Ie<8&&(ie.node.style.zIndex=2)),ie.node}function wh(ie,ae){var de=ae.bgClass?ae.bgClass+" "+(ae.line.bgClass||""):ae.line.bgClass;if(de&&(de+=" CodeMirror-linebackground"),ae.background)de?ae.background.className=de:(ae.background.parentNode.removeChild(ae.background),ae.background=null);else if(de){var ce=Tl(ae);ae.background=ce.insertBefore(it("div",null,de),ce.firstChild),ie.display.input.setUneditable(ae.background)}}function Ju(ie,ae){var de=ie.display.externalMeasured;return de&&de.line==ae.line?(ie.display.externalMeasured=null,ae.measure=de.measure,de.built):Xt(ie,ae)}function Bi(ie,ae){var de=ae.text.className,ce=Ju(ie,ae);ae.text==ae.node&&(ae.node=ce.pre),ae.text.parentNode.replaceChild(ce.pre,ae.text),ae.text=ce.pre,ce.bgClass!=ae.bgClass||ce.textClass!=ae.textClass?(ae.bgClass=ce.bgClass,ae.textClass=ce.textClass,Ms(ie,ae)):de&&(ae.text.className=de)}function Ms(ie,ae){wh(ie,ae),ae.line.wrapClass?Tl(ae).className=ae.line.wrapClass:ae.node!=ae.text&&(ae.node.className="");var de=ae.textClass?ae.textClass+" "+(ae.line.textClass||""):ae.line.textClass;ae.text.className=de||""}function Cs(ie,ae,de,ce){if(ae.gutter&&(ae.node.removeChild(ae.gutter),ae.gutter=null),ae.gutterBackground&&(ae.node.removeChild(ae.gutterBackground),ae.gutterBackground=null),ae.line.gutterClass){var ge=Tl(ae);ae.gutterBackground=it("div",null,"CodeMirror-gutter-background "+ae.line.gutterClass,"left: "+(ie.options.fixedGutter?ce.fixedPos:-ce.gutterTotalWidth)+"px; width: "+ce.gutterTotalWidth+"px"),ie.display.input.setUneditable(ae.gutterBackground),ge.insertBefore(ae.gutterBackground,ae.text)}var Me=ae.line.gutterMarkers;if(ie.options.lineNumbers||Me){var He=Tl(ae),Je=ae.gutter=it("div",null,"CodeMirror-gutter-wrapper","left: "+(ie.options.fixedGutter?ce.fixedPos:-ce.gutterTotalWidth)+"px");if(ie.display.input.setUneditable(Je),He.insertBefore(Je,ae.text),ae.line.gutterClass&&(Je.className+=" "+ae.line.gutterClass),ie.options.lineNumbers&&(!Me||!Me["CodeMirror-linenumbers"])&&(ae.lineNumber=Je.appendChild(it("div",eo(ie.options,de),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+ce.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+ie.display.lineNumInnerWidth+"px"))),Me)for(var _e=0;_e<ie.display.gutterSpecs.length;++_e){var lt=ie.display.gutterSpecs[_e].className,_t=Me.hasOwnProperty(lt)&&Me[lt];_t&&Je.appendChild(it("div",[_t],"CodeMirror-gutter-elt","left: "+ce.gutterLeft[lt]+"px; width: "+ce.gutterWidth[lt]+"px"))}}}function _l(ie,ae,de){ae.alignable&&(ae.alignable=null);for(var ce=Ge("CodeMirror-linewidget"),ge=ae.node.firstChild,Me=void 0;ge;ge=Me)Me=ge.nextSibling,ce.test(ge.className)&&ae.node.removeChild(ge);Ph(ie,ae,de)}function lh(ie,ae,de,ce){var ge=Ju(ie,ae);return ae.text=ae.node=ge.pre,ge.bgClass&&(ae.bgClass=ge.bgClass),ge.textClass&&(ae.textClass=ge.textClass),Ms(ie,ae),Cs(ie,ae,de,ce),Ph(ie,ae,ce),ae.node}function Ph(ie,ae,de){if(ko(ie,ae.line,ae,de,!0),ae.rest)for(var ce=0;ce<ae.rest.length;ce++)ko(ie,ae.rest[ce],ae,de,!1)}function ko(ie,ae,de,ce,ge){if(ae.widgets)for(var Me=Tl(de),He=0,Je=ae.widgets;He<Je.length;++He){var _e=Je[He],lt=it("div",[_e.node],"CodeMirror-linewidget"+(_e.className?" "+_e.className:""));_e.handleMouseEvents||lt.setAttribute("cm-ignore-events","true"),Ch(_e,lt,de,ce),ie.display.input.setUneditable(lt),ge&&_e.above?Me.insertBefore(lt,de.gutter||de.text):Me.appendChild(lt),vr(_e,"redraw")}}function Ch(ie,ae,de,ce){if(ie.noHScroll){(de.alignable||(de.alignable=[])).push(ae);var ge=ce.wrapperWidth;ae.style.left=ce.fixedPos+"px",ie.coverGutter||(ge-=ce.gutterTotalWidth,ae.style.paddingLeft=ce.gutterTotalWidth+"px"),ae.style.width=ge+"px"}ie.coverGutter&&(ae.style.zIndex=5,ae.style.position="relative",ie.noHScroll||(ae.style.marginLeft=-ce.gutterTotalWidth+"px"))}function iu(ie){if(ie.height!=null)return ie.height;var ae=ie.doc.cm;if(!ae)return 0;if(!Ft(document.body,ie.node)){var de="position: relative;";ie.coverGutter&&(de+="margin-left: -"+ae.display.gutters.offsetWidth+"px;"),ie.noHScroll&&(de+="width: "+ae.display.wrapper.clientWidth+"px;"),st(ae.display.measure,it("div",[ie.node],null,de))}return ie.height=ie.node.parentNode.offsetHeight}function yl(ie,ae){for(var de=ha(ae);de!=ie.wrapper;de=de.parentNode)if(!de||de.nodeType==1&&de.getAttribute("cm-ignore-events")=="true"||de.parentNode==ie.sizer&&de!=ie.mover)return!0}function Hl(ie){return ie.lineSpace.offsetTop}function Eh(ie){return ie.mover.offsetHeight-ie.lineSpace.offsetHeight}function ec(ie){if(ie.cachedPaddingH)return ie.cachedPaddingH;var ae=st(ie.measure,it("pre","x","CodeMirror-line-like")),de=window.getComputedStyle?window.getComputedStyle(ae):ae.currentStyle,ce={left:parseInt(de.paddingLeft),right:parseInt(de.paddingRight)};return!isNaN(ce.left)&&!isNaN(ce.right)&&(ie.cachedPaddingH=ce),ce}function Dl(ie){return Wt-ie.display.nativeBarWidth}function ru(ie){return ie.display.scroller.clientWidth-Dl(ie)-ie.display.barWidth}function uh(ie){return ie.display.scroller.clientHeight-Dl(ie)-ie.display.barHeight}function Ec(ie,ae,de){var ce=ie.options.lineWrapping,ge=ce&&ru(ie);if(!ae.measure.heights||ce&&ae.measure.width!=ge){var Me=ae.measure.heights=[];if(ce){ae.measure.width=ge;for(var He=ae.text.firstChild.getClientRects(),Je=0;Je<He.length-1;Je++){var _e=He[Je],lt=He[Je+1];Math.abs(_e.bottom-lt.bottom)>2&&Me.push((_e.bottom+lt.top)/2-de.top)}}Me.push(de.bottom-de.top)}}function zh(ie,ae,de){if(ie.line==ae)return{map:ie.measure.map,cache:ie.measure.cache};for(var ce=0;ce<ie.rest.length;ce++)if(ie.rest[ce]==ae)return{map:ie.measure.maps[ce],cache:ie.measure.caches[ce]};for(var ge=0;ge<ie.rest.length;ge++)if(Dt(ie.rest[ge])>de)return{map:ie.measure.maps[ge],cache:ie.measure.caches[ge],before:!0}}function Rc(ie,ae){ae=Ua(ae);var de=Dt(ae),ce=ie.display.externalMeasured=new Xu(ie.doc,ae,de);ce.lineN=de;var ge=ce.built=Xt(ie,ce);return ce.text=ge.pre,st(ie.display.lineMeasure,ge.pre),ce}function dc(ie,ae,de,ce){return pu(ie,Qu(ie,ae),de,ce)}function Gl(ie,ae){if(ae>=ie.display.viewFrom&&ae<ie.display.viewTo)return ie.display.view[Pl(ie,ae)];var de=ie.display.externalMeasured;if(de&&ae>=de.lineN&&ae<de.lineN+de.size)return de}function Qu(ie,ae){var de=Dt(ae),ce=Gl(ie,de);ce&&!ce.text?ce=null:ce&&ce.changes&&(Nl(ie,ce,de,Wh(ie)),ie.curOp.forceUpdate=!0),ce||(ce=Rc(ie,ae));var ge=zh(ce,ae,de);return{line:ae,view:ce,rect:null,map:ge.map,cache:ge.cache,before:ge.before,hasHeights:!1}}function pu(ie,ae,de,ce,ge){ae.before&&(de=-1);var Me=de+(ce||""),He;return ae.cache.hasOwnProperty(Me)?He=ae.cache[Me]:(ae.rect||(ae.rect=ae.view.text.getBoundingClientRect()),ae.hasHeights||(Ec(ie,ae.view,ae.rect),ae.hasHeights=!0),He=vs(ie,ae,de,ce),He.bogus||(ae.cache[Me]=He)),{left:He.left,right:He.right,top:ge?He.rtop:He.top,bottom:ge?He.rbottom:He.bottom}}var bh={left:0,right:0,top:0,bottom:0};function tc(ie,ae,de){for(var ce,ge,Me,He,Je,_e,lt=0;lt<ie.length;lt+=3)if(Je=ie[lt],_e=ie[lt+1],ae<Je?(ge=0,Me=1,He="left"):ae<_e?(ge=ae-Je,Me=ge+1):(lt==ie.length-3||ae==_e&&ie[lt+3]>ae)&&(Me=_e-Je,ge=Me-1,ae>=_e&&(He="right")),ge!=null){if(ce=ie[lt+2],Je==_e&&de==(ce.insertLeft?"left":"right")&&(He=de),de=="left"&&ge==0)for(;lt&&ie[lt-2]==ie[lt-3]&&ie[lt-1].insertLeft;)ce=ie[(lt-=3)+2],He="left";if(de=="right"&&ge==_e-Je)for(;lt<ie.length-3&&ie[lt+3]==ie[lt+4]&&!ie[lt+5].insertLeft;)ce=ie[(lt+=3)+2],He="right";break}return{node:ce,start:ge,end:Me,collapse:He,coverStart:Je,coverEnd:_e}}function Hh(ie,ae){var de=bh;if(ae=="left")for(var ce=0;ce<ie.length&&(de=ie[ce]).left==de.right;ce++);else for(var ge=ie.length-1;ge>=0&&(de=ie[ge]).left==de.right;ge--);return de}function vs(ie,ae,de,ce){var ge=tc(ae.map,de,ce),Me=ge.node,He=ge.start,Je=ge.end,_e=ge.collapse,lt;if(Me.nodeType==3){for(var _t=0;_t<4;_t++){for(;He&&dn(ae.line.text.charAt(ge.coverStart+He));)--He;for(;ge.coverStart+Je<ge.coverEnd&&dn(ae.line.text.charAt(ge.coverStart+Je));)++Je;if(kt&&Ie<9&&He==0&&Je==ge.coverEnd-ge.coverStart?lt=Me.parentNode.getBoundingClientRect():lt=Hh(St(Me,He,Je).getClientRects(),ce),lt.left||lt.right||He==0)break;Je=He,He=He-1,_e="right"}kt&&Ie<11&&(lt=tn(ie.display.measure,lt))}else{He>0&&(_e=ce="right");var mt;ie.options.lineWrapping&&(mt=Me.getClientRects()).length>1?lt=mt[ce=="right"?mt.length-1:0]:lt=Me.getBoundingClientRect()}if(kt&&Ie<9&&!He&&(!lt||!lt.left&&!lt.right)){var Cn=Me.parentNode.getClientRects()[0];Cn?lt={left:Cn.left,right:Cn.left+Tu(ie.display),top:Cn.top,bottom:Cn.bottom}:lt=bh}for(var mn=lt.top-ae.rect.top,xi=lt.bottom-ae.rect.top,Mi=(mn+xi)/2,Yi=ae.view.measure.heights,Cr=0;Cr<Yi.length-1&&!(Mi<Yi[Cr]);Cr++);var ao=Cr?Yi[Cr-1]:0,Gr=Yi[Cr],wo={left:(_e=="right"?lt.right:lt.left)-ae.rect.left,right:(_e=="left"?lt.left:lt.right)-ae.rect.left,top:ao,bottom:Gr};return!lt.left&&!lt.right&&(wo.bogus=!0),ie.options.singleCursorHeightPerLine||(wo.rtop=mn,wo.rbottom=xi),wo}function tn(ie,ae){if(!window.screen||screen.logicalXDPI==null||screen.logicalXDPI==screen.deviceXDPI||!on(ie))return ae;var de=screen.logicalXDPI/screen.deviceXDPI,ce=screen.logicalYDPI/screen.deviceYDPI;return{left:ae.left*de,right:ae.right*de,top:ae.top*ce,bottom:ae.bottom*ce}}function nc(ie){if(ie.measure&&(ie.measure.cache={},ie.measure.heights=null,ie.rest))for(var ae=0;ae<ie.rest.length;ae++)ie.measure.caches[ae]={}}function Gh(ie){ie.display.externalMeasure=null,ut(ie.display.lineMeasure);for(var ae=0;ae<ie.display.view.length;ae++)nc(ie.display.view[ae])}function qu(ie){Gh(ie),ie.display.cachedCharWidth=ie.display.cachedTextHeight=ie.display.cachedPaddingH=null,ie.options.lineWrapping||(ie.display.maxLineChanged=!0),ie.display.lineNumChars=null}function Ml(){return Pt&&ne?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function ol(){return Pt&&ne?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function Rs(ie){var ae=0;if(ie.widgets)for(var de=0;de<ie.widgets.length;++de)ie.widgets[de].above&&(ae+=iu(ie.widgets[de]));return ae}function Us(ie,ae,de,ce,ge){if(!ge){var Me=Rs(ae);de.top+=Me,de.bottom+=Me}if(ce=="line")return de;ce||(ce="local");var He=Ao(ae);if(ce=="local"?He+=Hl(ie.display):He-=ie.display.viewOffset,ce=="page"||ce=="window"){var Je=ie.display.lineSpace.getBoundingClientRect();He+=Je.top+(ce=="window"?0:ol());var _e=Je.left+(ce=="window"?0:Ml());de.left+=_e,de.right+=_e}return de.top+=He,de.bottom+=He,de}function hh(ie,ae,de){if(de=="div")return ae;var ce=ae.left,ge=ae.top;if(de=="page")ce-=Ml(),ge-=ol();else if(de=="local"||!de){var Me=ie.display.sizer.getBoundingClientRect();ce+=Me.left,ge+=Me.top}var He=ie.display.lineSpace.getBoundingClientRect();return{left:ce-He.left,top:ge-He.top}}function al(ie,ae,de,ce,ge){return ce||(ce=wn(ie.doc,ae.line)),Us(ie,ce,dc(ie,ce,ae.ch,ge),de)}function Ss(ie,ae,de,ce,ge,Me){ce=ce||wn(ie.doc,ae.line),ge||(ge=Qu(ie,ce));function He(xi,Mi){var Yi=pu(ie,ge,xi,Mi?"right":"left",Me);return Mi?Yi.left=Yi.right:Yi.right=Yi.left,Us(ie,ce,Yi,de)}var Je=ti(ce,ie.doc.direction),_e=ae.ch,lt=ae.sticky;if(_e>=ce.text.length?(_e=ce.text.length,lt="before"):_e<=0&&(_e=0,lt="after"),!Je)return He(lt=="before"?_e-1:_e,lt=="before");function _t(xi,Mi,Yi){var Cr=Je[Mi],ao=Cr.level==1;return He(Yi?xi-1:xi,ao!=Yi)}var mt=Zt(Je,_e,lt),Cn=Hn,mn=_t(_e,mt,lt=="before");return Cn!=null&&(mn.other=_t(_e,Cn,lt!="before")),mn}function os(ie,ae){var de=0;ae=cr(ie.doc,ae),ie.options.lineWrapping||(de=Tu(ie.display)*ae.ch);var ce=wn(ie.doc,ae.line),ge=Ao(ce)+Hl(ie.display);return{left:de,right:de,top:ge,bottom:ge+ce.height}}function Lh(ie,ae,de,ce,ge){var Me=kn(ie,ae,de);return Me.xRel=ge,ce&&(Me.outside=ce),Me}function Au(ie,ae,de){var ce=ie.doc;if(de+=ie.display.viewOffset,de<0)return Lh(ce.first,0,null,-1,-1);var ge=wi(ce,de),Me=ce.first+ce.size-1;if(ge>Me)return Lh(ce.first+ce.size-1,wn(ce,Me).text.length,null,1,1);ae<0&&(ae=0);for(var He=wn(ce,ge);;){var Je=Bn(ie,He,ge,ae,de),_e=Hu(He,Je.ch+(Je.xRel>0||Je.outside>0?1:0));if(!_e)return Je;var lt=_e.find(1);if(lt.line==ge)return lt;He=wn(ce,ge=lt.line)}}function kr(ie,ae,de,ce){ce-=Rs(ae);var ge=ae.text.length,Me=$n(function(He){return pu(ie,de,He-1).bottom<=ce},ge,0);return ge=$n(function(He){return pu(ie,de,He).top>ce},Me,ge),{begin:Me,end:ge}}function Kh(ie,ae,de,ce){de||(de=Qu(ie,ae));var ge=Us(ie,ae,pu(ie,de,ce),"line").top;return kr(ie,ae,de,ge)}function yt(ie,ae,de,ce){return ie.bottom<=de?!1:ie.top>de?!0:(ce?ie.left:ie.right)>ae}function Bn(ie,ae,de,ce,ge){ge-=Ao(ae);var Me=Qu(ie,ae),He=Rs(ae),Je=0,_e=ae.text.length,lt=!0,_t=ti(ae,ie.doc.direction);if(_t){var mt=(ie.options.lineWrapping?ch:Kl)(ie,ae,de,Me,_t,ce,ge);lt=mt.level!=1,Je=lt?mt.from:mt.to-1,_e=lt?mt.to:mt.from-1}var Cn=null,mn=null,xi=$n(function(ua){var Hr=pu(ie,Me,ua);return Hr.top+=He,Hr.bottom+=He,yt(Hr,ce,ge,!1)?(Hr.top<=ge&&Hr.left<=ce&&(Cn=ua,mn=Hr),!0):!1},Je,_e),Mi,Yi,Cr=!1;if(mn){var ao=ce-mn.left<mn.right-ce,Gr=ao==lt;xi=Cn+(Gr?0:1),Yi=Gr?"after":"before",Mi=ao?mn.left:mn.right}else{!lt&&(xi==_e||xi==Je)&&xi++,Yi=xi==0?"after":xi==ae.text.length?"before":pu(ie,Me,xi-(lt?1:0)).bottom+He<=ge==lt?"after":"before";var wo=Ss(ie,kn(de,xi,Yi),"line",ae,Me);Mi=wo.left,Cr=ge<wo.top?-1:ge>=wo.bottom?1:0}return xi=ui(ae.text,xi,1),Lh(de,xi,Yi,Cr,ce-Mi)}function Kl(ie,ae,de,ce,ge,Me,He){var Je=$n(function(mt){var Cn=ge[mt],mn=Cn.level!=1;return yt(Ss(ie,kn(de,mn?Cn.to:Cn.from,mn?"before":"after"),"line",ae,ce),Me,He,!0)},0,ge.length-1),_e=ge[Je];if(Je>0){var lt=_e.level!=1,_t=Ss(ie,kn(de,lt?_e.from:_e.to,lt?"after":"before"),"line",ae,ce);yt(_t,Me,He,!0)&&_t.top>He&&(_e=ge[Je-1])}return _e}function ch(ie,ae,de,ce,ge,Me,He){var Je=kr(ie,ae,ce,He),_e=Je.begin,lt=Je.end;/\s/.test(ae.text.charAt(lt-1))&&lt--;for(var _t=null,mt=null,Cn=0;Cn<ge.length;Cn++){var mn=ge[Cn];if(!(mn.from>=lt||mn.to<=_e)){var xi=mn.level!=1,Mi=pu(ie,ce,xi?Math.min(lt,mn.to)-1:Math.max(_e,mn.from)).right,Yi=Mi<Me?Me-Mi+1e9:Mi-Me;(!_t||mt>Yi)&&(_t=mn,mt=Yi)}}return _t||(_t=ge[ge.length-1]),_t.from<_e&&(_t={from:_e,to:_t.to,level:_t.level}),_t.to>lt&&(_t={from:_t.from,to:lt,level:_t.level}),_t}var $u;function Nu(ie){if(ie.cachedTextHeight!=null)return ie.cachedTextHeight;if($u==null){$u=it("pre",null,"CodeMirror-line-like");for(var ae=0;ae<49;++ae)$u.appendChild(document.createTextNode("x")),$u.appendChild(it("br"));$u.appendChild(document.createTextNode("x"))}st(ie.measure,$u);var de=$u.offsetHeight/50;return de>3&&(ie.cachedTextHeight=de),ut(ie.measure),de||1}function Tu(ie){if(ie.cachedCharWidth!=null)return ie.cachedCharWidth;var ae=it("span","xxxxxxxxxx"),de=it("pre",[ae],"CodeMirror-line-like");st(ie.measure,de);var ce=ae.getBoundingClientRect(),ge=(ce.right-ce.left)/10;return ge>2&&(ie.cachedCharWidth=ge),ge||10}function Wh(ie){for(var ae=ie.display,de={},ce={},ge=ae.gutters.clientLeft,Me=ae.gutters.firstChild,He=0;Me;Me=Me.nextSibling,++He){var Je=ie.display.gutterSpecs[He].className;de[Je]=Me.offsetLeft+Me.clientLeft+ge,ce[Je]=Me.clientWidth}return{fixedPos:Du(ae),gutterTotalWidth:ae.gutters.offsetWidth,gutterLeft:de,gutterWidth:ce,wrapperWidth:ae.wrapper.clientWidth}}function Du(ie){return ie.scroller.getBoundingClientRect().left-ie.sizer.getBoundingClientRect().left}function Ns(ie){var ae=Nu(ie.display),de=ie.options.lineWrapping,ce=de&&Math.max(5,ie.display.scroller.clientWidth/Tu(ie.display)-3);return function(ge){if(fn(ie.doc,ge))return 0;var Me=0;if(ge.widgets)for(var He=0;He<ge.widgets.length;He++)ge.widgets[He].height&&(Me+=ge.widgets[He].height);return de?Me+(Math.ceil(ge.text.length/ce)||1)*ae:Me+ae}}function to(ie){var ae=ie.doc,de=Ns(ie);ae.iter(function(ce){var ge=de(ce);ge!=ce.height&&Rn(ce,ge)})}function Bl(ie,ae,de,ce){var ge=ie.display;if(!de&&ha(ae).getAttribute("cm-not-content")=="true")return null;var Me,He,Je=ge.lineSpace.getBoundingClientRect();try{Me=ae.clientX-Je.left,He=ae.clientY-Je.top}catch(mt){return null}var _e=Au(ie,Me,He),lt;if(ce&&_e.xRel>0&&(lt=wn(ie.doc,_e.line).text).length==_e.ch){var _t=nt(lt,lt.length,ie.options.tabSize)-lt.length;_e=kn(_e.line,Math.max(0,Math.round((Me-ec(ie.display).left)/Tu(ie.display))-_t))}return _e}function Pl(ie,ae){if(ae>=ie.display.viewTo||(ae-=ie.display.viewFrom,ae<0))return null;for(var de=ie.display.view,ce=0;ce<de.length;ce++)if(ae-=de[ce].size,ae<0)return ce}function xs(ie,ae,de,ce){ae==null&&(ae=ie.doc.first),de==null&&(de=ie.doc.first+ie.doc.size),ce||(ce=0);var ge=ie.display;if(ce&&de<ge.viewTo&&(ge.updateLineNumbers==null||ge.updateLineNumbers>ae)&&(ge.updateLineNumbers=ae),ie.curOp.viewChanged=!0,ae>=ge.viewTo)An&&Pr(ie.doc,ae)<ge.viewTo&&po(ie);else if(de<=ge.viewFrom)An&&so(ie.doc,de+ce)>ge.viewFrom?po(ie):(ge.viewFrom+=ce,ge.viewTo+=ce);else if(ae<=ge.viewFrom&&de>=ge.viewTo)po(ie);else if(ae<=ge.viewFrom){var Me=Vo(ie,de,de+ce,1);Me?(ge.view=ge.view.slice(Me.index),ge.viewFrom=Me.lineN,ge.viewTo+=ce):po(ie)}else if(de>=ge.viewTo){var He=Vo(ie,ae,ae,-1);He?(ge.view=ge.view.slice(0,He.index),ge.viewTo=He.lineN):po(ie)}else{var Je=Vo(ie,ae,ae,-1),_e=Vo(ie,de,de+ce,1);Je&&_e?(ge.view=ge.view.slice(0,Je.index).concat(es(ie,Je.lineN,_e.lineN)).concat(ge.view.slice(_e.index)),ge.viewTo+=ce):po(ie)}var lt=ge.externalMeasured;lt&&(de<lt.lineN?lt.lineN+=ce:ae<lt.lineN+lt.size&&(ge.externalMeasured=null))}function fi(ie,ae,de){ie.curOp.viewChanged=!0;var ce=ie.display,ge=ie.display.externalMeasured;if(ge&&ae>=ge.lineN&&ae<ge.lineN+ge.size&&(ce.externalMeasured=null),!(ae<ce.viewFrom||ae>=ce.viewTo)){var Me=ce.view[Pl(ie,ae)];if(Me.node!=null){var He=Me.changes||(Me.changes=[]);ke(He,de)==-1&&He.push(de)}}}function po(ie){ie.display.viewFrom=ie.display.viewTo=ie.doc.first,ie.display.view=[],ie.display.viewOffset=0}function Vo(ie,ae,de,ce){var ge=Pl(ie,ae),Me,He=ie.display.view;if(!An||de==ie.doc.first+ie.doc.size)return{index:ge,lineN:de};for(var Je=ie.display.viewFrom,_e=0;_e<ge;_e++)Je+=He[_e].size;if(Je!=ae){if(ce>0){if(ge==He.length-1)return null;Me=Je+He[ge].size-ae,ge++}else Me=Je-ae;ae+=Me,de+=Me}for(;Pr(ie.doc,de)!=de;){if(ge==(ce<0?0:He.length-1))return null;de+=ce*He[ge-(ce<0?1:0)].size,ge+=ce}return{index:ge,lineN:de}}function qo(ie,ae,de){var ce=ie.display,ge=ce.view;ge.length==0||ae>=ce.viewTo||de<=ce.viewFrom?(ce.view=es(ie,ae,de),ce.viewFrom=ae):(ce.viewFrom>ae?ce.view=es(ie,ae,ce.viewFrom).concat(ce.view):ce.viewFrom<ae&&(ce.view=ce.view.slice(Pl(ie,ae))),ce.viewFrom=ae,ce.viewTo<de?ce.view=ce.view.concat(es(ie,ce.viewTo,de)):ce.viewTo>de&&(ce.view=ce.view.slice(0,Pl(ie,de)))),ce.viewTo=de}function Ja(ie){for(var ae=ie.display.view,de=0,ce=0;ce<ae.length;ce++){var ge=ae[ce];!ge.hidden&&(!ge.node||ge.changes)&&++de}return de}function Zs(ie){ie.display.input.showSelection(ie.display.input.prepareSelection())}function mu(ie,ae){ae===void 0&&(ae=!0);for(var de=ie.doc,ce={},ge=ce.cursors=document.createDocumentFragment(),Me=ce.selection=document.createDocumentFragment(),He=0;He<de.sel.ranges.length;He++)if(!(!ae&&He==de.sel.primIndex)){var Je=de.sel.ranges[He];if(!(Je.from().line>=ie.display.viewTo||Je.to().line<ie.display.viewFrom)){var _e=Je.empty();(_e||ie.options.showCursorWhenSelecting)&&ka(ie,Je.head,ge),_e||ga(ie,Je,Me)}}return ce}function ka(ie,ae,de){var ce=Ss(ie,ae,"div",null,null,!ie.options.singleCursorHeightPerLine),ge=de.appendChild(it("div","\xA0","CodeMirror-cursor"));if(ge.style.left=ce.left+"px",ge.style.top=ce.top+"px",ge.style.height=Math.max(0,ce.bottom-ce.top)*ie.options.cursorHeight+"px",ce.other){var Me=de.appendChild(it("div","\xA0","CodeMirror-cursor CodeMirror-secondarycursor"));Me.style.display="",Me.style.left=ce.other.left+"px",Me.style.top=ce.other.top+"px",Me.style.height=(ce.other.bottom-ce.other.top)*.85+"px"}}function sl(ie,ae){return ie.top-ae.top||ie.left-ae.left}function ga(ie,ae,de){var ce=ie.display,ge=ie.doc,Me=document.createDocumentFragment(),He=ec(ie.display),Je=He.left,_e=Math.max(ce.sizerWidth,ru(ie)-ce.sizer.offsetLeft)-He.right,lt=ge.direction=="ltr";function _t(Gr,wo,ua,Hr){wo<0&&(wo=0),wo=Math.round(wo),Hr=Math.round(Hr),Me.appendChild(it("div",null,"CodeMirror-selected","position: absolute; left: "+Gr+`px;
top: `+wo+"px; width: "+(ua==null?_e-Gr:ua)+`px;
height: `+(Hr-wo)+"px"))}function mt(Gr,wo,ua){var Hr=wn(ge,Gr),_a=Hr.text.length,fl,uu;function Cl(ql,Ah){return al(ie,kn(Gr,ql),"div",Hr,Ah)}function gh(ql,Ah,Bu){var $l=Kh(ie,Hr,null,ql),ks=Ah=="ltr"==(Bu=="after")?"left":"right",kl=Bu=="after"?$l.begin:$l.end-(/\s/.test(Hr.text.charAt($l.end-1))?2:1);return Cl(kl,ks)[ks]}var Wu=ti(Hr,ge.direction);return rn(Wu,wo||0,ua==null?_a:ua,function(ql,Ah,Bu,$l){var ks=Bu=="ltr",kl=Cl(ql,ks?"left":"right"),yu=Cl(Ah-1,ks?"right":"left"),Ou=wo==null&&ql==0,gc=ua==null&&Ah==_a,El=$l==0,ic=!Wu||$l==Wu.length-1;if(yu.top-kl.top<=3){var Rl=(lt?Ou:gc)&&El,zf=(lt?gc:Ou)&&ic,Uh=Rl?Je:(ks?kl:yu).left,Nh=zf?_e:(ks?yu:kl).right;_t(Uh,kl.top,Nh-Uh,kl.bottom)}else{var ph,Ys,Su,Hc;ks?(ph=lt&&Ou&&El?Je:kl.left,Ys=lt?_e:gh(ql,Bu,"before"),Su=lt?Je:gh(Ah,Bu,"after"),Hc=lt&&gc&&ic?_e:yu.right):(ph=lt?gh(ql,Bu,"before"):Je,Ys=!lt&&Ou&&El?_e:kl.right,Su=!lt&&gc&&ic?Je:yu.left,Hc=lt?gh(Ah,Bu,"after"):_e),_t(ph,kl.top,Ys-ph,kl.bottom),kl.bottom<yu.top&&_t(Je,kl.bottom,null,yu.top),_t(Su,yu.top,Hc-Su,yu.bottom)}(!fl||sl(kl,fl)<0)&&(fl=kl),sl(yu,fl)<0&&(fl=yu),(!uu||sl(kl,uu)<0)&&(uu=kl),sl(yu,uu)<0&&(uu=yu)}),{start:fl,end:uu}}var Cn=ae.from(),mn=ae.to();if(Cn.line==mn.line)mt(Cn.line,Cn.ch,mn.ch);else{var xi=wn(ge,Cn.line),Mi=wn(ge,mn.line),Yi=Ua(xi)==Ua(Mi),Cr=mt(Cn.line,Cn.ch,Yi?xi.text.length+1:null).end,ao=mt(mn.line,Yi?0:null,mn.ch).start;Yi&&(Cr.top<ao.top-2?(_t(Cr.right,Cr.top,null,Cr.bottom),_t(Je,ao.top,ao.left,ao.bottom)):_t(Cr.right,Cr.top,ao.left-Cr.right,Cr.bottom)),Cr.bottom<ao.top&&_t(Je,Cr.bottom,null,ao.top)}de.appendChild(Me)}function ts(ie){if(ie.state.focused){var ae=ie.display;clearInterval(ae.blinker);var de=!0;ae.cursorDiv.style.visibility="",ie.options.cursorBlinkRate>0?ae.blinker=setInterval(function(){ie.hasFocus()||vu(ie),ae.cursorDiv.style.visibility=(de=!de)?"":"hidden"},ie.options.cursorBlinkRate):ie.options.cursorBlinkRate<0&&(ae.cursorDiv.style.visibility="hidden")}}function ss(ie){ie.state.focused||(ie.display.input.focus(),Ta(ie))}function ws(ie){ie.state.delayingBlurEvent=!0,setTimeout(function(){ie.state.delayingBlurEvent&&(ie.state.delayingBlurEvent=!1,vu(ie))},100)}function Ta(ie,ae){ie.state.delayingBlurEvent&&(ie.state.delayingBlurEvent=!1),ie.options.readOnly!="nocursor"&&(ie.state.focused||(Ei(ie,"focus",ie,ae),ie.state.focused=!0,Tt(ie.display.wrapper,"CodeMirror-focused"),!ie.curOp&&ie.display.selForContextMenu!=ie.doc.sel&&(ie.display.input.reset(),$e&&setTimeout(function(){return ie.display.input.reset(!0)},20)),ie.display.input.receivedFocus()),ts(ie))}function vu(ie,ae){ie.state.delayingBlurEvent||(ie.state.focused&&(Ei(ie,"blur",ie,ae),ie.state.focused=!1,et(ie.display.wrapper,"CodeMirror-focused")),clearInterval(ie.display.blinker),setTimeout(function(){ie.state.focused||(ie.display.shift=!1)},150))}function Ni(ie){for(var ae=ie.display,de=ae.lineDiv.offsetTop,ce=0;ce<ae.view.length;ce++){var ge=ae.view[ce],Me=ie.options.lineWrapping,He=void 0,Je=0;if(!ge.hidden){if(kt&&Ie<8){var _e=ge.node.offsetTop+ge.node.offsetHeight;He=_e-de,de=_e}else{var lt=ge.node.getBoundingClientRect();He=lt.bottom-lt.top,!Me&&ge.text.firstChild&&(Je=ge.text.firstChild.getBoundingClientRect().right-lt.left-1)}var _t=ge.line.height-He;if((_t>.005||_t<-.005)&&(Rn(ge.line,He),ou(ge.line),ge.rest))for(var mt=0;mt<ge.rest.length;mt++)ou(ge.rest[mt]);if(Je>ie.display.sizerWidth){var Cn=Math.ceil(Je/Tu(ie.display));Cn>ie.display.maxLineLength&&(ie.display.maxLineLength=Cn,ie.display.maxLine=ge.line,ie.display.maxLineChanged=!0)}}}}function ou(ie){if(ie.widgets)for(var ae=0;ae<ie.widgets.length;++ae){var de=ie.widgets[ae],ce=de.node.parentNode;ce&&(de.height=ce.offsetHeight)}}function sa(ie,ae,de){var ce=de&&de.top!=null?Math.max(0,de.top):ie.scroller.scrollTop;ce=Math.floor(ce-Hl(ie));var ge=de&&de.bottom!=null?de.bottom:ce+ie.wrapper.clientHeight,Me=wi(ae,ce),He=wi(ae,ge);if(de&&de.ensure){var Je=de.ensure.from.line,_e=de.ensure.to.line;Je<Me?(Me=Je,He=wi(ae,Ao(wn(ae,Je))+ie.wrapper.clientHeight)):Math.min(_e,ae.lastLine())>=He&&(Me=wi(ae,Ao(wn(ae,_e))-ie.wrapper.clientHeight),He=_e)}return{from:Me,to:Math.max(He,Me+1)}}function mo(ie,ae){if(!Di(ie,"scrollCursorIntoView")){var de=ie.display,ce=de.sizer.getBoundingClientRect(),ge=null;if(ae.top+ce.top<0?ge=!0:ae.bottom+ce.top>(window.innerHeight||document.documentElement.clientHeight)&&(ge=!1),ge!=null&&!sn){var Me=it("div","\u200B",null,`position: absolute;
top: `+(ae.top-de.viewOffset-Hl(ie.display))+`px;
height: `+(ae.bottom-ae.top+Dl(ie)+de.barHeight)+`px;
left: `+ae.left+"px; width: "+Math.max(2,ae.right-ae.left)+"px;");ie.display.lineSpace.appendChild(Me),Me.scrollIntoView(ge),ie.display.lineSpace.removeChild(Me)}}}function Mh(ie,ae,de,ce){ce==null&&(ce=0);var ge;!ie.options.lineWrapping&&ae==de&&(ae=ae.ch?kn(ae.line,ae.sticky=="before"?ae.ch-1:ae.ch,"after"):ae,de=ae.sticky=="before"?kn(ae.line,ae.ch+1,"before"):ae);for(var Me=0;Me<5;Me++){var He=!1,Je=Ss(ie,ae),_e=!de||de==ae?Je:Ss(ie,de);ge={left:Math.min(Je.left,_e.left),top:Math.min(Je.top,_e.top)-ce,right:Math.max(Je.left,_e.left),bottom:Math.max(Je.bottom,_e.bottom)+ce};var lt=Ic(ie,ge),_t=ie.doc.scrollTop,mt=ie.doc.scrollLeft;if(lt.scrollTop!=null&&(ht(ie,lt.scrollTop),Math.abs(ie.doc.scrollTop-_t)>1&&(He=!0)),lt.scrollLeft!=null&&(xt(ie,lt.scrollLeft),Math.abs(ie.doc.scrollLeft-mt)>1&&(He=!0)),!He)break}return ge}function bc(ie,ae){var de=Ic(ie,ae);de.scrollTop!=null&&ht(ie,de.scrollTop),de.scrollLeft!=null&&xt(ie,de.scrollLeft)}function Ic(ie,ae){var de=ie.display,ce=Nu(ie.display);ae.top<0&&(ae.top=0);var ge=ie.curOp&&ie.curOp.scrollTop!=null?ie.curOp.scrollTop:de.scroller.scrollTop,Me=uh(ie),He={};ae.bottom-ae.top>Me&&(ae.bottom=ae.top+Me);var Je=ie.doc.height+Eh(de),_e=ae.top<ce,lt=ae.bottom>Je-ce;if(ae.top<ge)He.scrollTop=_e?0:ae.top;else if(ae.bottom>ge+Me){var _t=Math.min(ae.top,(lt?Je:ae.bottom)-Me);_t!=ge&&(He.scrollTop=_t)}var mt=ie.options.fixedGutter?0:de.gutters.offsetWidth,Cn=ie.curOp&&ie.curOp.scrollLeft!=null?ie.curOp.scrollLeft:de.scroller.scrollLeft-mt,mn=ru(ie)-de.gutters.offsetWidth,xi=ae.right-ae.left>mn;return xi&&(ae.right=ae.left+mn),ae.left<10?He.scrollLeft=0:ae.left<Cn?He.scrollLeft=Math.max(0,ae.left+mt-(xi?0:10)):ae.right>mn+Cn-3&&(He.scrollLeft=ae.right+(xi?0:10)-mn),He}function fc(ie,ae){ae!=null&&(Wl(ie),ie.curOp.scrollTop=(ie.curOp.scrollTop==null?ie.doc.scrollTop:ie.curOp.scrollTop)+ae)}function kh(ie){Wl(ie);var ae=ie.getCursor();ie.curOp.scrollToPos={from:ae,to:ae,margin:ie.options.cursorScrollMargin}}function Fh(ie,ae,de){(ae!=null||de!=null)&&Wl(ie),ae!=null&&(ie.curOp.scrollLeft=ae),de!=null&&(ie.curOp.scrollTop=de)}function Br(ie,ae){Wl(ie),ie.curOp.scrollToPos=ae}function Wl(ie){var ae=ie.curOp.scrollToPos;if(ae){ie.curOp.scrollToPos=null;var de=os(ie,ae.from),ce=os(ie,ae.to);Ue(ie,de,ce,ae.margin)}}function Ue(ie,ae,de,ce){var ge=Ic(ie,{left:Math.min(ae.left,de.left),top:Math.min(ae.top,de.top)-ce,right:Math.max(ae.right,de.right),bottom:Math.max(ae.bottom,de.bottom)+ce});Fh(ie,ge.scrollLeft,ge.scrollTop)}function ht(ie,ae){Math.abs(ie.doc.scrollTop-ae)<2||(Ne||ot(ie,{top:ae}),pt(ie,ae,!0),Ne&&ot(ie),da(ie,100))}function pt(ie,ae,de){ae=Math.max(0,Math.min(ie.display.scroller.scrollHeight-ie.display.scroller.clientHeight,ae)),!(ie.display.scroller.scrollTop==ae&&!de)&&(ie.doc.scrollTop=ae,ie.display.scrollbars.setScrollTop(ae),ie.display.scroller.scrollTop!=ae&&(ie.display.scroller.scrollTop=ae))}function xt(ie,ae,de,ce){ae=Math.max(0,Math.min(ae,ie.display.scroller.scrollWidth-ie.display.scroller.clientWidth)),!((de?ae==ie.doc.scrollLeft:Math.abs(ie.doc.scrollLeft-ae)<2)&&!ce)&&(ie.doc.scrollLeft=ae,je(ie),ie.display.scroller.scrollLeft!=ae&&(ie.display.scroller.scrollLeft=ae),ie.display.scrollbars.setScrollLeft(ae))}function Ht(ie){var ae=ie.display,de=ae.gutters.offsetWidth,ce=Math.round(ie.doc.height+Eh(ie.display));return{clientHeight:ae.scroller.clientHeight,viewHeight:ae.wrapper.clientHeight,scrollWidth:ae.scroller.scrollWidth,clientWidth:ae.scroller.clientWidth,viewWidth:ae.wrapper.clientWidth,barLeft:ie.options.fixedGutter?de:0,docHeight:ce,scrollHeight:ce+Dl(ie)+ae.barHeight,nativeBarWidth:ae.nativeBarWidth,gutterWidth:de}}var en=function(ie,ae,de){this.cm=de;var ce=this.vert=it("div",[it("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),ge=this.horiz=it("div",[it("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");ce.tabIndex=ge.tabIndex=-1,ie(ce),ie(ge),oi(ce,"scroll",function(){ce.clientHeight&&ae(ce.scrollTop,"vertical")}),oi(ge,"scroll",function(){ge.clientWidth&&ae(ge.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,kt&&Ie<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};en.prototype.update=function(ie){var ae=ie.scrollWidth>ie.clientWidth+1,de=ie.scrollHeight>ie.clientHeight+1,ce=ie.nativeBarWidth;if(de){this.vert.style.display="block",this.vert.style.bottom=ae?ce+"px":"0";var ge=ie.viewHeight-(ae?ce:0);this.vert.firstChild.style.height=Math.max(0,ie.scrollHeight-ie.clientHeight+ge)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(ae){this.horiz.style.display="block",this.horiz.style.right=de?ce+"px":"0",this.horiz.style.left=ie.barLeft+"px";var Me=ie.viewWidth-ie.barLeft-(de?ce:0);this.horiz.firstChild.style.width=Math.max(0,ie.scrollWidth-ie.clientWidth+Me)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&ie.clientHeight>0&&(ce==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:de?ce:0,bottom:ae?ce:0}},en.prototype.setScrollLeft=function(ie){this.horiz.scrollLeft!=ie&&(this.horiz.scrollLeft=ie),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},en.prototype.setScrollTop=function(ie){this.vert.scrollTop!=ie&&(this.vert.scrollTop=ie),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},en.prototype.zeroWidthHack=function(){var ie=he&&!It?"12px":"18px";this.horiz.style.height=this.vert.style.width=ie,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new ze,this.disableVert=new ze},en.prototype.enableZeroWidthBar=function(ie,ae,de){ie.style.pointerEvents="auto";function ce(){var ge=ie.getBoundingClientRect(),Me=de=="vert"?document.elementFromPoint(ge.right-1,(ge.top+ge.bottom)/2):document.elementFromPoint((ge.right+ge.left)/2,ge.bottom-1);Me!=ie?ie.style.pointerEvents="none":ae.set(1e3,ce)}ae.set(1e3,ce)},en.prototype.clear=function(){var ie=this.horiz.parentNode;ie.removeChild(this.horiz),ie.removeChild(this.vert)};var un=function(){};un.prototype.update=function(){return{bottom:0,right:0}},un.prototype.setScrollLeft=function(){},un.prototype.setScrollTop=function(){},un.prototype.clear=function(){};function En(ie,ae){ae||(ae=Ht(ie));var de=ie.display.barWidth,ce=ie.display.barHeight;Yn(ie,ae);for(var ge=0;ge<4&&de!=ie.display.barWidth||ce!=ie.display.barHeight;ge++)de!=ie.display.barWidth&&ie.options.lineWrapping&&Ni(ie),Yn(ie,Ht(ie)),de=ie.display.barWidth,ce=ie.display.barHeight}function Yn(ie,ae){var de=ie.display,ce=de.scrollbars.update(ae);de.sizer.style.paddingRight=(de.barWidth=ce.right)+"px",de.sizer.style.paddingBottom=(de.barHeight=ce.bottom)+"px",de.heightForcer.style.borderBottom=ce.bottom+"px solid transparent",ce.right&&ce.bottom?(de.scrollbarFiller.style.display="block",de.scrollbarFiller.style.height=ce.bottom+"px",de.scrollbarFiller.style.width=ce.right+"px"):de.scrollbarFiller.style.display="",ce.bottom&&ie.options.coverGutterNextToScrollbar&&ie.options.fixedGutter?(de.gutterFiller.style.display="block",de.gutterFiller.style.height=ce.bottom+"px",de.gutterFiller.style.width=ae.gutterWidth+"px"):de.gutterFiller.style.display=""}var Gn={native:en,null:un};function Si(ie){ie.display.scrollbars&&(ie.display.scrollbars.clear(),ie.display.scrollbars.addClass&&et(ie.display.wrapper,ie.display.scrollbars.addClass)),ie.display.scrollbars=new Gn[ie.options.scrollbarStyle](function(ae){ie.display.wrapper.insertBefore(ae,ie.display.scrollbarFiller),oi(ae,"mousedown",function(){ie.state.focused&&setTimeout(function(){return ie.display.input.focus()},0)}),ae.setAttribute("cm-not-content","true")},function(ae,de){de=="horizontal"?xt(ie,ae):ht(ie,ae)},ie),ie.display.scrollbars.addClass&&Tt(ie.display.wrapper,ie.display.scrollbars.addClass)}var Un=0;function gi(ie){ie.curOp={cm:ie,viewChanged:!1,startHeight:ie.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Un},Mo(ie.curOp)}function ii(ie){var ae=ie.curOp;ae&&Ma(ae,function(de){for(var ce=0;ce<de.ops.length;ce++)de.ops[ce].cm.curOp=null;Oi(de)})}function Oi(ie){for(var ae=ie.ops,de=0;de<ae.length;de++)lr(ae[de]);for(var ce=0;ce<ae.length;ce++)br(ae[ce]);for(var ge=0;ge<ae.length;ge++)Zr(ae[ge]);for(var Me=0;Me<ae.length;Me++)Gi(ae[Me]);for(var He=0;He<ae.length;He++)mr(ae[He])}function lr(ie){var ae=ie.cm,de=ae.display;ys(ae),ie.updateMaxLine&&Ia(ae),ie.mustUpdate=ie.viewChanged||ie.forceUpdate||ie.scrollTop!=null||ie.scrollToPos&&(ie.scrollToPos.from.line<de.viewFrom||ie.scrollToPos.to.line>=de.viewTo)||de.maxLineChanged&&ae.options.lineWrapping,ie.update=ie.mustUpdate&&new la(ae,ie.mustUpdate&&{top:ie.scrollTop,ensure:ie.scrollToPos},ie.forceUpdate)}function br(ie){ie.updatedDisplay=ie.mustUpdate&&Oe(ie.cm,ie.update)}function Zr(ie){var ae=ie.cm,de=ae.display;ie.updatedDisplay&&Ni(ae),ie.barMeasure=Ht(ae),de.maxLineChanged&&!ae.options.lineWrapping&&(ie.adjustWidthTo=dc(ae,de.maxLine,de.maxLine.text.length).left+3,ae.display.sizerWidth=ie.adjustWidthTo,ie.barMeasure.scrollWidth=Math.max(de.scroller.clientWidth,de.sizer.offsetLeft+ie.adjustWidthTo+Dl(ae)+ae.display.barWidth),ie.maxScrollLeft=Math.max(0,de.sizer.offsetLeft+ie.adjustWidthTo-ru(ae))),(ie.updatedDisplay||ie.selectionChanged)&&(ie.preparedSelection=de.input.prepareSelection())}function Gi(ie){var ae=ie.cm;ie.adjustWidthTo!=null&&(ae.display.sizer.style.minWidth=ie.adjustWidthTo+"px",ie.maxScrollLeft<ae.doc.scrollLeft&&xt(ae,Math.min(ae.display.scroller.scrollLeft,ie.maxScrollLeft),!0),ae.display.maxLineChanged=!1);var de=ie.focus&&ie.focus==cn();ie.preparedSelection&&ae.display.input.showSelection(ie.preparedSelection,de),(ie.updatedDisplay||ie.startHeight!=ae.doc.height)&&En(ae,ie.barMeasure),ie.updatedDisplay&&Le(ae,ie.barMeasure),ie.selectionChanged&&ts(ae),ae.state.focused&&ie.updateInput&&ae.display.input.reset(ie.typing),de&&ss(ie.cm)}function mr(ie){var ae=ie.cm,de=ae.display,ce=ae.doc;if(ie.updatedDisplay&&Xe(ae,ie.update),de.wheelStartX!=null&&(ie.scrollTop!=null||ie.scrollLeft!=null||ie.scrollToPos)&&(de.wheelStartX=de.wheelStartY=null),ie.scrollTop!=null&&pt(ae,ie.scrollTop,ie.forceScroll),ie.scrollLeft!=null&&xt(ae,ie.scrollLeft,!0,!0),ie.scrollToPos){var ge=Mh(ae,cr(ce,ie.scrollToPos.from),cr(ce,ie.scrollToPos.to),ie.scrollToPos.margin);mo(ae,ge)}var Me=ie.maybeHiddenMarkers,He=ie.maybeUnhiddenMarkers;if(Me)for(var Je=0;Je<Me.length;++Je)Me[Je].lines.length||Ei(Me[Je],"hide");if(He)for(var _e=0;_e<He.length;++_e)He[_e].lines.length&&Ei(He[_e],"unhide");de.wrapper.offsetHeight&&(ce.scrollTop=ae.display.scroller.scrollTop),ie.changeObjs&&Ei(ae,"changes",ae,ie.changeObjs),ie.update&&ie.update.finish()}function er(ie,ae){if(ie.curOp)return ae();gi(ie);try{return ae()}finally{ii(ie)}}function Yr(ie,ae){return function(){if(ie.curOp)return ae.apply(ie,arguments);gi(ie);try{return ae.apply(ie,arguments)}finally{ii(ie)}}}function No(ie){return function(){if(this.curOp)return ie.apply(this,arguments);gi(this);try{return ie.apply(this,arguments)}finally{ii(this)}}}function Wr(ie){return function(){var ae=this.cm;if(!ae||ae.curOp)return ie.apply(this,arguments);gi(ae);try{return ie.apply(this,arguments)}finally{ii(ae)}}}function da(ie,ae){ie.doc.highlightFrontier<ie.display.viewTo&&ie.state.highlight.set(ae,zn(To,ie))}function To(ie){var ae=ie.doc;if(!(ae.highlightFrontier>=ie.display.viewTo)){var de=+new Date+ie.options.workTime,ce=gs(ie,ae.highlightFrontier),ge=[];ae.iter(ce.line,Math.min(ae.first+ae.size,ie.display.viewTo+500),function(Me){if(ce.line>=ie.display.viewFrom){var He=Me.styles,Je=Me.text.length>ie.options.maxHighlightLength?ci(ae.mode,ce.state):null,_e=ml(ie,Me,ce,!0);Je&&(ce.state=Je),Me.styles=_e.styles;var lt=Me.styleClasses,_t=_e.classes;_t?Me.styleClasses=_t:lt&&(Me.styleClasses=null);for(var mt=!He||He.length!=Me.styles.length||lt!=_t&&(!lt||!_t||lt.bgClass!=_t.bgClass||lt.textClass!=_t.textClass),Cn=0;!mt&&Cn<He.length;++Cn)mt=He[Cn]!=Me.styles[Cn];mt&&ge.push(ce.line),Me.stateAfter=ce.save(),ce.nextLine()}else Me.text.length<=ie.options.maxHighlightLength&&Vt(ie,Me.text,ce),Me.stateAfter=ce.line%5==0?ce.save():null,ce.nextLine();if(+new Date>de)return da(ie,ie.options.workDelay),!0}),ae.highlightFrontier=ce.line,ae.modeFrontier=Math.max(ae.modeFrontier,ce.line),ge.length&&er(ie,function(){for(var Me=0;Me<ge.length;Me++)fi(ie,ge[Me],"text")})}}var la=function(ie,ae,de){var ce=ie.display;this.viewport=ae,this.visible=sa(ce,ie.doc,ae),this.editorIsHidden=!ce.wrapper.offsetWidth,this.wrapperHeight=ce.wrapper.clientHeight,this.wrapperWidth=ce.wrapper.clientWidth,this.oldDisplayWidth=ru(ie),this.force=de,this.dims=Wh(ie),this.events=[]};la.prototype.signal=function(ie,ae){vt(ie,ae)&&this.events.push(arguments)},la.prototype.finish=function(){for(var ie=0;ie<this.events.length;ie++)Ei.apply(null,this.events[ie])};function ys(ie){var ae=ie.display;!ae.scrollbarsClipped&&ae.scroller.offsetWidth&&(ae.nativeBarWidth=ae.scroller.offsetWidth-ae.scroller.clientWidth,ae.heightForcer.style.height=Dl(ie)+"px",ae.sizer.style.marginBottom=-ae.nativeBarWidth+"px",ae.sizer.style.borderRightWidth=Dl(ie)+"px",ae.scrollbarsClipped=!0)}function Da(ie){if(ie.hasFocus())return null;var ae=cn();if(!ae||!Ft(ie.display.lineDiv,ae))return null;var de={activeElt:ae};if(window.getSelection){var ce=window.getSelection();ce.anchorNode&&ce.extend&&Ft(ie.display.lineDiv,ce.anchorNode)&&(de.anchorNode=ce.anchorNode,de.anchorOffset=ce.anchorOffset,de.focusNode=ce.focusNode,de.focusOffset=ce.focusOffset)}return de}function Te(ie){if(!(!ie||!ie.activeElt||ie.activeElt==cn())&&(ie.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(ie.activeElt.nodeName)&&ie.anchorNode&&Ft(document.body,ie.anchorNode)&&Ft(document.body,ie.focusNode))){var ae=window.getSelection(),de=document.createRange();de.setEnd(ie.anchorNode,ie.anchorOffset),de.collapse(!1),ae.removeAllRanges(),ae.addRange(de),ae.extend(ie.focusNode,ie.focusOffset)}}function Oe(ie,ae){var de=ie.display,ce=ie.doc;if(ae.editorIsHidden)return po(ie),!1;if(!ae.force&&ae.visible.from>=de.viewFrom&&ae.visible.to<=de.viewTo&&(de.updateLineNumbers==null||de.updateLineNumbers>=de.viewTo)&&de.renderedView==de.view&&Ja(ie)==0)return!1;Ke(ie)&&(po(ie),ae.dims=Wh(ie));var ge=ce.first+ce.size,Me=Math.max(ae.visible.from-ie.options.viewportMargin,ce.first),He=Math.min(ge,ae.visible.to+ie.options.viewportMargin);de.viewFrom<Me&&Me-de.viewFrom<20&&(Me=Math.max(ce.first,de.viewFrom)),de.viewTo>He&&de.viewTo-He<20&&(He=Math.min(ge,de.viewTo)),An&&(Me=Pr(ie.doc,Me),He=so(ie.doc,He));var Je=Me!=de.viewFrom||He!=de.viewTo||de.lastWrapHeight!=ae.wrapperHeight||de.lastWrapWidth!=ae.wrapperWidth;qo(ie,Me,He),de.viewOffset=Ao(wn(ie.doc,de.viewFrom)),ie.display.mover.style.top=de.viewOffset+"px";var _e=Ja(ie);if(!Je&&_e==0&&!ae.force&&de.renderedView==de.view&&(de.updateLineNumbers==null||de.updateLineNumbers>=de.viewTo))return!1;var lt=Da(ie);return _e>4&&(de.lineDiv.style.display="none"),Rt(ie,de.updateLineNumbers,ae.dims),_e>4&&(de.lineDiv.style.display=""),de.renderedView=de.view,Te(lt),ut(de.cursorDiv),ut(de.selectionDiv),de.gutters.style.height=de.sizer.style.minHeight=0,Je&&(de.lastWrapHeight=ae.wrapperHeight,de.lastWrapWidth=ae.wrapperWidth,da(ie,400)),de.updateLineNumbers=null,!0}function Xe(ie,ae){for(var de=ae.viewport,ce=!0;;ce=!1){if(!ce||!ie.options.lineWrapping||ae.oldDisplayWidth==ru(ie)){if(de&&de.top!=null&&(de={top:Math.min(ie.doc.height+Eh(ie.display)-uh(ie),de.top)}),ae.visible=sa(ie.display,ie.doc,de),ae.visible.from>=ie.display.viewFrom&&ae.visible.to<=ie.display.viewTo)break}else ce&&(ae.visible=sa(ie.display,ie.doc,de));if(!Oe(ie,ae))break;Ni(ie);var ge=Ht(ie);Zs(ie),En(ie,ge),Le(ie,ge),ae.force=!1}ae.signal(ie,"update",ie),(ie.display.viewFrom!=ie.display.reportedViewFrom||ie.display.viewTo!=ie.display.reportedViewTo)&&(ae.signal(ie,"viewportChange",ie,ie.display.viewFrom,ie.display.viewTo),ie.display.reportedViewFrom=ie.display.viewFrom,ie.display.reportedViewTo=ie.display.viewTo)}function ot(ie,ae){var de=new la(ie,ae);if(Oe(ie,de)){Ni(ie),Xe(ie,de);var ce=Ht(ie);Zs(ie),En(ie,ce),Le(ie,ce),de.finish()}}function Rt(ie,ae,de){var ce=ie.display,ge=ie.options.lineNumbers,Me=ce.lineDiv,He=Me.firstChild;function Je(xi){var Mi=xi.nextSibling;return $e&&he&&ie.display.currentWheelTarget==xi?xi.style.display="none":xi.parentNode.removeChild(xi),Mi}for(var _e=ce.view,lt=ce.viewFrom,_t=0;_t<_e.length;_t++){var mt=_e[_t];if(!mt.hidden)if(!mt.node||mt.node.parentNode!=Me){var Cn=lh(ie,mt,lt,de);Me.insertBefore(Cn,He)}else{for(;He!=mt.node;)He=Je(He);var mn=ge&&ae!=null&&ae<=lt&&mt.lineNumber;mt.changes&&(ke(mt.changes,"gutter")>-1&&(mn=!1),Nl(ie,mt,lt,de)),mn&&(ut(mt.lineNumber),mt.lineNumber.appendChild(document.createTextNode(eo(ie.options,lt)))),He=mt.node.nextSibling}lt+=mt.size}for(;He;)He=Je(He)}function Se(ie){var ae=ie.gutters.offsetWidth;ie.sizer.style.marginLeft=ae+"px"}function Le(ie,ae){ie.display.sizer.style.minHeight=ae.docHeight+"px",ie.display.heightForcer.style.top=ae.docHeight+"px",ie.display.gutters.style.height=ae.docHeight+ie.display.barHeight+Dl(ie)+"px"}function je(ie){var ae=ie.display,de=ae.view;if(!(!ae.alignWidgets&&(!ae.gutters.firstChild||!ie.options.fixedGutter))){for(var ce=Du(ae)-ae.scroller.scrollLeft+ie.doc.scrollLeft,ge=ae.gutters.offsetWidth,Me=ce+"px",He=0;He<de.length;He++)if(!de[He].hidden){ie.options.fixedGutter&&(de[He].gutter&&(de[He].gutter.style.left=Me),de[He].gutterBackground&&(de[He].gutterBackground.style.left=Me));var Je=de[He].alignable;if(Je)for(var _e=0;_e<Je.length;_e++)Je[_e].style.left=Me}ie.options.fixedGutter&&(ae.gutters.style.left=ce+ge+"px")}}function Ke(ie){if(!ie.options.lineNumbers)return!1;var ae=ie.doc,de=eo(ie.options,ae.first+ae.size-1),ce=ie.display;if(de.length!=ce.lineNumChars){var ge=ce.measure.appendChild(it("div",[it("div",de)],"CodeMirror-linenumber CodeMirror-gutter-elt")),Me=ge.firstChild.offsetWidth,He=ge.offsetWidth-Me;return ce.lineGutter.style.width="",ce.lineNumInnerWidth=Math.max(Me,ce.lineGutter.offsetWidth-He)+1,ce.lineNumWidth=ce.lineNumInnerWidth+He,ce.lineNumChars=ce.lineNumInnerWidth?de.length:-1,ce.lineGutter.style.width=ce.lineNumWidth+"px",Se(ie.display),!0}return!1}function ct(ie,ae){for(var de=[],ce=!1,ge=0;ge<ie.length;ge++){var Me=ie[ge],He=null;if(typeof Me!="string"&&(He=Me.style,Me=Me.className),Me=="CodeMirror-linenumbers")if(ae)ce=!0;else continue;de.push({className:Me,style:He})}return ae&&!ce&&de.push({className:"CodeMirror-linenumbers",style:null}),de}function Et(ie){var ae=ie.gutters,de=ie.gutterSpecs;ut(ae),ie.lineGutter=null;for(var ce=0;ce<de.length;++ce){var ge=de[ce],Me=ge.className,He=ge.style,Je=ae.appendChild(it("div",null,"CodeMirror-gutter "+Me));He&&(Je.style.cssText=He),Me=="CodeMirror-linenumbers"&&(ie.lineGutter=Je,Je.style.width=(ie.lineNumWidth||1)+"px")}ae.style.display=de.length?"":"none",Se(ie)}function Bt(ie){Et(ie.display),xs(ie),je(ie)}function hn(ie,ae,de,ce){var ge=this;this.input=de,ge.scrollbarFiller=it("div",null,"CodeMirror-scrollbar-filler"),ge.scrollbarFiller.setAttribute("cm-not-content","true"),ge.gutterFiller=it("div",null,"CodeMirror-gutter-filler"),ge.gutterFiller.setAttribute("cm-not-content","true"),ge.lineDiv=Nt("div",null,"CodeMirror-code"),ge.selectionDiv=it("div",null,null,"position: relative; z-index: 1"),ge.cursorDiv=it("div",null,"CodeMirror-cursors"),ge.measure=it("div",null,"CodeMirror-measure"),ge.lineMeasure=it("div",null,"CodeMirror-measure"),ge.lineSpace=Nt("div",[ge.measure,ge.lineMeasure,ge.selectionDiv,ge.cursorDiv,ge.lineDiv],null,"position: relative; outline: none");var Me=Nt("div",[ge.lineSpace],"CodeMirror-lines");ge.mover=it("div",[Me],null,"position: relative"),ge.sizer=it("div",[ge.mover],"CodeMirror-sizer"),ge.sizerWidth=null,ge.heightForcer=it("div",null,null,"position: absolute; height: "+Wt+"px; width: 1px;"),ge.gutters=it("div",null,"CodeMirror-gutters"),ge.lineGutter=null,ge.scroller=it("div",[ge.sizer,ge.heightForcer,ge.gutters],"CodeMirror-scroll"),ge.scroller.setAttribute("tabIndex","-1"),ge.wrapper=it("div",[ge.scrollbarFiller,ge.gutterFiller,ge.scroller],"CodeMirror"),kt&&Ie<8&&(ge.gutters.style.zIndex=-1,ge.scroller.style.paddingRight=0),!$e&&!(Ne&&te)&&(ge.scroller.draggable=!0),ie&&(ie.appendChild?ie.appendChild(ge.wrapper):ie(ge.wrapper)),ge.viewFrom=ge.viewTo=ae.first,ge.reportedViewFrom=ge.reportedViewTo=ae.first,ge.view=[],ge.renderedView=null,ge.externalMeasured=null,ge.viewOffset=0,ge.lastWrapHeight=ge.lastWrapWidth=0,ge.updateLineNumbers=null,ge.nativeBarWidth=ge.barHeight=ge.barWidth=0,ge.scrollbarsClipped=!1,ge.lineNumWidth=ge.lineNumInnerWidth=ge.lineNumChars=null,ge.alignWidgets=!1,ge.cachedCharWidth=ge.cachedTextHeight=ge.cachedPaddingH=null,ge.maxLine=null,ge.maxLineLength=0,ge.maxLineChanged=!1,ge.wheelDX=ge.wheelDY=ge.wheelStartX=ge.wheelStartY=null,ge.shift=!1,ge.selForContextMenu=null,ge.activeTouch=null,ge.gutterSpecs=ct(ce.gutters,ce.lineNumbers),Et(ge),de.init(ge)}var qt=0,nn=null;kt?nn=-.53:Ne?nn=15:Pt?nn=-.7:Qt&&(nn=-1/3);function Sn(ie){var ae=ie.wheelDeltaX,de=ie.wheelDeltaY;return ae==null&&ie.detail&&ie.axis==ie.HORIZONTAL_AXIS&&(ae=ie.detail),de==null&&ie.detail&&ie.axis==ie.VERTICAL_AXIS?de=ie.detail:de==null&&(de=ie.wheelDelta),{x:ae,y:de}}function yn(ie){var ae=Sn(ie);return ae.x*=nn,ae.y*=nn,ae}function Jn(ie,ae){var de=Sn(ae),ce=de.x,ge=de.y,Me=ie.display,He=Me.scroller,Je=He.scrollWidth>He.clientWidth,_e=He.scrollHeight>He.clientHeight;if(ce&&Je||ge&&_e){if(ge&&he&&$e){e:for(var lt=ae.target,_t=Me.view;lt!=He;lt=lt.parentNode)for(var mt=0;mt<_t.length;mt++)if(_t[mt].node==lt){ie.display.currentWheelTarget=lt;break e}}if(ce&&!Ne&&!wt&&nn!=null){ge&&_e&&ht(ie,Math.max(0,He.scrollTop+ge*nn)),xt(ie,Math.max(0,He.scrollLeft+ce*nn)),(!ge||ge&&_e)&&co(ae),Me.wheelStartX=null;return}if(ge&&nn!=null){var Cn=ge*nn,mn=ie.doc.scrollTop,xi=mn+Me.wrapper.clientHeight;Cn<0?mn=Math.max(0,mn+Cn-50):xi=Math.min(ie.doc.height,xi+Cn+50),ot(ie,{top:mn,bottom:xi})}qt<20&&(Me.wheelStartX==null?(Me.wheelStartX=He.scrollLeft,Me.wheelStartY=He.scrollTop,Me.wheelDX=ce,Me.wheelDY=ge,setTimeout(function(){if(Me.wheelStartX!=null){var Mi=He.scrollLeft-Me.wheelStartX,Yi=He.scrollTop-Me.wheelStartY,Cr=Yi&&Me.wheelDY&&Yi/Me.wheelDY||Mi&&Me.wheelDX&&Mi/Me.wheelDX;Me.wheelStartX=Me.wheelStartY=null,Cr&&(nn=(nn*qt+Cr)/(qt+1),++qt)}},200)):(Me.wheelDX+=ce,Me.wheelDY+=ge))}}var In=function(ie,ae){this.ranges=ie,this.primIndex=ae};In.prototype.primary=function(){return this.ranges[this.primIndex]},In.prototype.equals=function(ie){if(ie==this)return!0;if(ie.primIndex!=this.primIndex||ie.ranges.length!=this.ranges.length)return!1;for(var ae=0;ae<this.ranges.length;ae++){var de=this.ranges[ae],ce=ie.ranges[ae];if(!Lo(de.anchor,ce.anchor)||!Lo(de.head,ce.head))return!1}return!0},In.prototype.deepCopy=function(){for(var ie=[],ae=0;ae<this.ranges.length;ae++)ie[ae]=new Mn(La(this.ranges[ae].anchor),La(this.ranges[ae].head));return new In(ie,this.primIndex)},In.prototype.somethingSelected=function(){for(var ie=0;ie<this.ranges.length;ie++)if(!this.ranges[ie].empty())return!0;return!1},In.prototype.contains=function(ie,ae){ae||(ae=ie);for(var de=0;de<this.ranges.length;de++){var ce=this.ranges[de];if(Xi(ae,ce.from())>=0&&Xi(ie,ce.to())<=0)return de}return-1};var Mn=function(ie,ae){this.anchor=ie,this.head=ae};Mn.prototype.from=function(){return qi(this.anchor,this.head)},Mn.prototype.to=function(){return $o(this.anchor,this.head)},Mn.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function Kn(ie,ae,de){var ce=ie&&ie.options.selectionsMayTouch,ge=ae[de];ae.sort(function(Cn,mn){return Xi(Cn.from(),mn.from())}),de=ke(ae,ge);for(var Me=1;Me<ae.length;Me++){var He=ae[Me],Je=ae[Me-1],_e=Xi(Je.to(),He.from());if(ce&&!He.empty()?_e>0:_e>=0){var lt=qi(Je.from(),He.from()),_t=$o(Je.to(),He.to()),mt=Je.empty()?He.from()==He.head:Je.from()==Je.head;Me<=de&&--de,ae.splice(--Me,2,new Mn(mt?_t:lt,mt?lt:_t))}}return new In(ae,de)}function ni(ie,ae){return new In([new Mn(ie,ae||ie)],0)}function yi(ie){return ie.text?kn(ie.from.line+ie.text.length-1,Gt(ie.text).length+(ie.text.length==1?ie.from.ch:0)):ie.to}function $i(ie,ae){if(Xi(ie,ae.from)<0)return ie;if(Xi(ie,ae.to)<=0)return yi(ae);var de=ie.line+ae.text.length-(ae.to.line-ae.from.line)-1,ce=ie.ch;return ie.line==ae.to.line&&(ce+=yi(ae).ch-ae.to.ch),kn(de,ce)}function Ai(ie,ae){for(var de=[],ce=0;ce<ie.sel.ranges.length;ce++){var ge=ie.sel.ranges[ce];de.push(new Mn($i(ge.anchor,ae),$i(ge.head,ae)))}return Kn(ie.cm,de,ie.sel.primIndex)}function bi(ie,ae,de){return ie.line==ae.line?kn(de.line,ie.ch-ae.ch+de.ch):kn(de.line+(ie.line-ae.line),ie.ch)}function dr(ie,ae,de){for(var ce=[],ge=kn(ie.first,0),Me=ge,He=0;He<ae.length;He++){var Je=ae[He],_e=bi(Je.from,ge,Me),lt=bi(yi(Je),ge,Me);if(ge=Je.to,Me=lt,de=="around"){var _t=ie.sel.ranges[He],mt=Xi(_t.head,_t.anchor)<0;ce[He]=new Mn(mt?lt:_e,mt?_e:lt)}else ce[He]=new Mn(_e,_e)}return new In(ce,ie.sel.primIndex)}function Wn(ie){ie.doc.mode=zt(ie.options,ie.doc.modeOption),Ji(ie)}function Ji(ie){ie.doc.iter(function(ae){ae.stateAfter&&(ae.stateAfter=null),ae.styles&&(ae.styles=null)}),ie.doc.modeFrontier=ie.doc.highlightFrontier=ie.doc.first,da(ie,100),ie.state.modeGen++,ie.curOp&&xs(ie)}function Pi(ie,ae){return ae.from.ch==0&&ae.to.ch==0&&Gt(ae.text)==""&&(!ie.cm||ie.cm.options.wholeLineUpdateBefore)}function tr(ie,ae,de,ce){function ge(ao){return de?de[ao]:null}function Me(ao,Gr,wo){Vs(ao,Gr,wo,ce),vr(ao,"change",ao,ae)}function He(ao,Gr){for(var wo=[],ua=ao;ua<Gr;++ua)wo.push(new ms(lt[ua],ge(ua),ce));return wo}var Je=ae.from,_e=ae.to,lt=ae.text,_t=wn(ie,Je.line),mt=wn(ie,_e.line),Cn=Gt(lt),mn=ge(lt.length-1),xi=_e.line-Je.line;if(ae.full)ie.insert(0,He(0,lt.length)),ie.remove(lt.length,ie.size-lt.length);else if(Pi(ie,ae)){var Mi=He(0,lt.length-1);Me(mt,mt.text,mn),xi&&ie.remove(Je.line,xi),Mi.length&&ie.insert(Je.line,Mi)}else if(_t==mt)if(lt.length==1)Me(_t,_t.text.slice(0,Je.ch)+Cn+_t.text.slice(_e.ch),mn);else{var Yi=He(1,lt.length-1);Yi.push(new ms(Cn+_t.text.slice(_e.ch),mn,ce)),Me(_t,_t.text.slice(0,Je.ch)+lt[0],ge(0)),ie.insert(Je.line+1,Yi)}else if(lt.length==1)Me(_t,_t.text.slice(0,Je.ch)+lt[0]+mt.text.slice(_e.ch),ge(0)),ie.remove(Je.line+1,xi);else{Me(_t,_t.text.slice(0,Je.ch)+lt[0],ge(0)),Me(mt,Cn+mt.text.slice(_e.ch),mn);var Cr=He(1,lt.length-1);xi>1&&ie.remove(Je.line+1,xi-1),ie.insert(Je.line+1,Cr)}vr(ie,"change",ie,ae)}function ar(ie,ae,de){function ce(ge,Me,He){if(ge.linked)for(var Je=0;Je<ge.linked.length;++Je){var _e=ge.linked[Je];if(_e.doc!=Me){var lt=He&&_e.sharedHist;de&&!lt||(ae(_e.doc,lt),ce(_e.doc,ge,lt))}}}ce(ie,null,!0)}function ki(ie,ae){if(ae.cm)throw new Error("This document is already in use.");ie.doc=ae,ae.cm=ie,to(ie),Wn(ie),Fr(ie),ie.options.lineWrapping||Ia(ie),ie.options.mode=ae.modeOption,xs(ie)}function Fr(ie){(ie.doc.direction=="rtl"?Tt:et)(ie.display.lineDiv,"CodeMirror-rtl")}function hr(ie){er(ie,function(){Fr(ie),xs(ie)})}function Mr(ie){this.done=[],this.undone=[],this.undoDepth=1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=ie||1}function Ti(ie,ae){var de={from:La(ae.from),to:yi(ae),text:pi(ie,ae.from,ae.to)};return $r(ie,de,ae.from.line,ae.to.line+1),ar(ie,function(ce){return $r(ce,de,ae.from.line,ae.to.line+1)},!0),de}function pr(ie){for(;ie.length;){var ae=Gt(ie);if(ae.ranges)ie.pop();else break}}function qr(ie,ae){if(ae)return pr(ie.done),Gt(ie.done);if(ie.done.length&&!Gt(ie.done).ranges)return Gt(ie.done);if(ie.done.length>1&&!ie.done[ie.done.length-2].ranges)return ie.done.pop(),Gt(ie.done)}function Po(ie,ae,de,ce){var ge=ie.history;ge.undone.length=0;var Me=+new Date,He,Je;if((ge.lastOp==ce||ge.lastOrigin==ae.origin&&ae.origin&&(ae.origin.charAt(0)=="+"&&ge.lastModTime>Me-(ie.cm?ie.cm.options.historyEventDelay:500)||ae.origin.charAt(0)=="*"))&&(He=qr(ge,ge.lastOp==ce)))Je=Gt(He.changes),Xi(ae.from,ae.to)==0&&Xi(ae.from,Je.to)==0?Je.to=yi(ae):He.changes.push(Ti(ie,ae));else{var _e=Gt(ge.done);for((!_e||!_e.ranges)&&zr(ie.sel,ge.done),He={changes:[Ti(ie,ae)],generation:ge.generation},ge.done.push(He);ge.done.length>ge.undoDepth;)ge.done.shift(),ge.done[0].ranges||ge.done.shift()}ge.done.push(de),ge.generation=++ge.maxGeneration,ge.lastModTime=ge.lastSelTime=Me,ge.lastOp=ge.lastSelOp=ce,ge.lastOrigin=ge.lastSelOrigin=ae.origin,Je||Ei(ie,"historyAdded")}function no(ie,ae,de,ce){var ge=ae.charAt(0);return ge=="*"||ge=="+"&&de.ranges.length==ce.ranges.length&&de.somethingSelected()==ce.somethingSelected()&&new Date-ie.history.lastSelTime<=(ie.cm?ie.cm.options.historyEventDelay:500)}function Qi(ie,ae,de,ce){var ge=ie.history,Me=ce&&ce.origin;de==ge.lastSelOp||Me&&ge.lastSelOrigin==Me&&(ge.lastModTime==ge.lastSelTime&&ge.lastOrigin==Me||no(ie,Me,Gt(ge.done),ae))?ge.done[ge.done.length-1]=ae:zr(ae,ge.done),ge.lastSelTime=+new Date,ge.lastSelOrigin=Me,ge.lastSelOp=de,ce&&ce.clearRedo!==!1&&pr(ge.undone)}function zr(ie,ae){var de=Gt(ae);de&&de.ranges&&de.equals(ie)||ae.push(ie)}function $r(ie,ae,de,ce){var ge=ae["spans_"+ie.id],Me=0;ie.iter(Math.max(ie.first,de),Math.min(ie.first+ie.size,ce),function(He){He.markedSpans&&((ge||(ge=ae["spans_"+ie.id]={}))[Me]=He.markedSpans),++Me})}function lo(ie){if(!ie)return null;for(var ae,de=0;de<ie.length;++de)ie[de].marker.explicitlyCleared?ae||(ae=ie.slice(0,de)):ae&&ae.push(ie[de]);return ae?ae.length?ae:null:ie}function Uo(ie,ae){var de=ae["spans_"+ie.id];if(!de)return null;for(var ce=[],ge=0;ge<ae.text.length;++ge)ce.push(lo(de[ge]));return ce}function So(ie,ae){var de=Uo(ie,ae),ce=Va(ie,ae);if(!de)return ce;if(!ce)return de;for(var ge=0;ge<de.length;++ge){var Me=de[ge],He=ce[ge];if(Me&&He)e:for(var Je=0;Je<He.length;++Je){for(var _e=He[Je],lt=0;lt<Me.length;++lt)if(Me[lt].marker==_e.marker)continue e;Me.push(_e)}else He&&(de[ge]=He)}return de}function Ar(ie,ae,de){for(var ce=[],ge=0;ge<ie.length;++ge){var Me=ie[ge];if(Me.ranges){ce.push(de?In.prototype.deepCopy.call(Me):Me);continue}var He=Me.changes,Je=[];ce.push({changes:Je});for(var _e=0;_e<He.length;++_e){var lt=He[_e],_t=void 0;if(Je.push({from:lt.from,to:lt.to,text:lt.text}),ae)for(var mt in lt)(_t=mt.match(/^spans_(\d+)$/))&&ke(ae,Number(_t[1]))>-1&&(Gt(Je)[mt]=lt[mt],delete lt[mt])}}return ce}function ur(ie,ae,de,ce){if(ce){var ge=ie.anchor;if(de){var Me=Xi(ae,ge)<0;Me!=Xi(de,ge)<0?(ge=ae,ae=de):Me!=Xi(ae,de)<0&&(ae=de)}return new Mn(ge,ae)}else return new Mn(de||ae,ae)}function Vr(ie,ae,de,ce,ge){ge==null&&(ge=ie.cm&&(ie.cm.display.shift||ie.extend)),Fi(ie,new In([ur(ie.sel.primary(),ae,de,ge)],0),ce)}function Do(ie,ae,de){for(var ce=[],ge=ie.cm&&(ie.cm.display.shift||ie.extend),Me=0;Me<ie.sel.ranges.length;Me++)ce[Me]=ur(ie.sel.ranges[Me],ae[Me],null,ge);var He=Kn(ie.cm,ce,ie.sel.primIndex);Fi(ie,He,de)}function Nr(ie,ae,de,ce){var ge=ie.sel.ranges.slice(0);ge[ae]=de,Fi(ie,Kn(ie.cm,ge,ie.sel.primIndex),ce)}function Wi(ie,ae,de,ce){Fi(ie,ni(ae,de),ce)}function ir(ie,ae,de){var ce={ranges:ae.ranges,update:function(ge){this.ranges=[];for(var Me=0;Me<ge.length;Me++)this.ranges[Me]=new Mn(cr(ie,ge[Me].anchor),cr(ie,ge[Me].head))},origin:de&&de.origin};return Ei(ie,"beforeSelectionChange",ie,ce),ie.cm&&Ei(ie.cm,"beforeSelectionChange",ie.cm,ce),ce.ranges!=ae.ranges?Kn(ie.cm,ce.ranges,ce.ranges.length-1):ae}function rr(ie,ae,de){var ce=ie.history.done,ge=Gt(ce);ge&&ge.ranges?(ce[ce.length-1]=ae,zi(ie,ae,de)):Fi(ie,ae,de)}function Fi(ie,ae,de){zi(ie,ae,de),Qi(ie,ie.sel,ie.cm?ie.cm.curOp.id:NaN,de)}function zi(ie,ae,de){(vt(ie,"beforeSelectionChange")||ie.cm&&vt(ie.cm,"beforeSelectionChange"))&&(ae=ir(ie,ae,de));var ce=de&&de.bias||(Xi(ae.primary().head,ie.sel.primary().head)<0?-1:1);Sr(ie,Xr(ie,ae,ce,!0)),!(de&&de.scroll===!1)&&ie.cm&&kh(ie.cm)}function Sr(ie,ae){ae.equals(ie.sel)||(ie.sel=ae,ie.cm&&(ie.cm.curOp.updateInput=1,ie.cm.curOp.selectionChanged=!0,uo(ie.cm)),vr(ie,"cursorActivity",ie))}function io(ie){Sr(ie,Xr(ie,ie.sel,null,!1))}function Xr(ie,ae,de,ce){for(var ge,Me=0;Me<ae.ranges.length;Me++){var He=ae.ranges[Me],Je=ae.ranges.length==ie.sel.ranges.length&&ie.sel.ranges[Me],_e=wa(ie,He.anchor,Je&&Je.anchor,de,ce),lt=wa(ie,He.head,Je&&Je.head,de,ce);(ge||_e!=He.anchor||lt!=He.head)&&(ge||(ge=ae.ranges.slice(0,Me)),ge[Me]=new Mn(_e,lt))}return ge?Kn(ie.cm,ge,ae.primIndex):ae}function Ir(ie,ae,de,ce,ge){var Me=wn(ie,ae.line);if(Me.markedSpans)for(var He=0;He<Me.markedSpans.length;++He){var Je=Me.markedSpans[He],_e=Je.marker,lt="selectLeft"in _e?!_e.selectLeft:_e.inclusiveLeft,_t="selectRight"in _e?!_e.selectRight:_e.inclusiveRight;if((Je.from==null||(lt?Je.from<=ae.ch:Je.from<ae.ch))&&(Je.to==null||(_t?Je.to>=ae.ch:Je.to>ae.ch))){if(ge&&(Ei(_e,"beforeCursorEnter"),_e.explicitlyCleared))if(Me.markedSpans){--He;continue}else break;if(!_e.atomic)continue;if(de){var mt=_e.find(ce<0?1:-1),Cn=void 0;if((ce<0?_t:lt)&&(mt=ra(ie,mt,-ce,mt&&mt.line==ae.line?Me:null)),mt&&mt.line==ae.line&&(Cn=Xi(mt,de))&&(ce<0?Cn<0:Cn>0))return Ir(ie,mt,ae,ce,ge)}var mn=_e.find(ce<0?-1:1);return(ce<0?lt:_t)&&(mn=ra(ie,mn,ce,mn.line==ae.line?Me:null)),mn?Ir(ie,mn,ae,ce,ge):null}}return ae}function wa(ie,ae,de,ce,ge){var Me=ce||1,He=Ir(ie,ae,de,Me,ge)||!ge&&Ir(ie,ae,de,Me,!0)||Ir(ie,ae,de,-Me,ge)||!ge&&Ir(ie,ae,de,-Me,!0);return He||(ie.cantEdit=!0,kn(ie.first,0))}function ra(ie,ae,de,ce){return de<0&&ae.ch==0?ae.line>ie.first?cr(ie,kn(ae.line-1)):null:de>0&&ae.ch==(ce||wn(ie,ae.line)).text.length?ae.line<ie.first+ie.size-1?kn(ae.line+1,0):null:new kn(ae.line,ae.ch+de)}function Xo(ie){ie.setSelection(kn(ie.firstLine(),0),kn(ie.lastLine()),Lt)}function pa(ie,ae,de){var ce={canceled:!1,from:ae.from,to:ae.to,text:ae.text,origin:ae.origin,cancel:function(){return ce.canceled=!0}};return de&&(ce.update=function(ge,Me,He,Je){ge&&(ce.from=cr(ie,ge)),Me&&(ce.to=cr(ie,Me)),He&&(ce.text=He),Je!==void 0&&(ce.origin=Je)}),Ei(ie,"beforeChange",ie,ce),ie.cm&&Ei(ie.cm,"beforeChange",ie.cm,ce),ce.canceled?(ie.cm&&(ie.cm.curOp.updateInput=2),null):{from:ce.from,to:ce.to,text:ce.text,origin:ce.origin}}function ro(ie,ae,de){if(ie.cm){if(!ie.cm.curOp)return Yr(ie.cm,ro)(ie,ae,de);if(ie.cm.state.suppressEdits)return}if(!((vt(ie,"beforeChange")||ie.cm&&vt(ie.cm,"beforeChange"))&&(ae=pa(ie,ae,!0),!ae))){var ce=xa&&!de&&Na(ie,ae.from,ae.to);if(ce)for(var ge=ce.length-1;ge>=0;--ge)Jo(ie,{from:ce[ge].from,to:ce[ge].to,text:ge?[""]:ae.text,origin:ae.origin});else Jo(ie,ae)}}function Jo(ie,ae){if(!(ae.text.length==1&&ae.text[0]==""&&Xi(ae.from,ae.to)==0)){var de=Ai(ie,ae);Po(ie,ae,de,ie.cm?ie.cm.curOp.id:NaN),Pa(ie,ae,de,Va(ie,ae));var ce=[];ar(ie,function(ge,Me){!Me&&ke(ce,ge.history)==-1&&(ns(ge.history,ae),ce.push(ge.history)),Pa(ge,ae,null,Va(ge,ae))})}}function va(ie,ae,de){var ce=ie.cm&&ie.cm.state.suppressEdits;if(!(ce&&!de)){for(var ge=ie.history,Me,He=ie.sel,Je=ae=="undo"?ge.done:ge.undone,_e=ae=="undo"?ge.undone:ge.done,lt=0;lt<Je.length&&(Me=Je[lt],!(de?Me.ranges&&!Me.equals(ie.sel):!Me.ranges));lt++);if(lt!=Je.length){for(ge.lastOrigin=ge.lastSelOrigin=null;;)if(Me=Je.pop(),Me.ranges){if(zr(Me,_e),de&&!Me.equals(ie.sel)){Fi(ie,Me,{clearRedo:!1});return}He=Me}else if(ce){Je.push(Me);return}else break;var _t=[];zr(He,_e),_e.push({changes:_t,generation:ge.generation}),ge.generation=Me.generation||++ge.maxGeneration;for(var mt=vt(ie,"beforeChange")||ie.cm&&vt(ie.cm,"beforeChange"),Cn=function(Mi){var Yi=Me.changes[Mi];if(Yi.origin=ae,mt&&!pa(ie,Yi,!1))return Je.length=0,{};_t.push(Ti(ie,Yi));var Cr=Mi?Ai(ie,Yi):Gt(Je);Pa(ie,Yi,Cr,So(ie,Yi)),!Mi&&ie.cm&&ie.cm.scrollIntoView({from:Yi.from,to:yi(Yi)});var ao=[];ar(ie,function(Gr,wo){!wo&&ke(ao,Gr.history)==-1&&(ns(Gr.history,Yi),ao.push(Gr.history)),Pa(Gr,Yi,null,So(Gr,Yi))})},mn=Me.changes.length-1;mn>=0;--mn){var xi=Cn(mn);if(xi)return xi.v}}}}function ds(ie,ae){if(ae!=0&&(ie.first+=ae,ie.sel=new In(an(ie.sel.ranges,function(ge){return new Mn(kn(ge.anchor.line+ae,ge.anchor.ch),kn(ge.head.line+ae,ge.head.ch))}),ie.sel.primIndex),ie.cm)){xs(ie.cm,ie.first,ie.first-ae,ae);for(var de=ie.cm.display,ce=de.viewFrom;ce<de.viewTo;ce++)fi(ie.cm,ce,"gutter")}}function Pa(ie,ae,de,ce){if(ie.cm&&!ie.cm.curOp)return Yr(ie.cm,Pa)(ie,ae,de,ce);if(ae.to.line<ie.first){ds(ie,ae.text.length-1-(ae.to.line-ae.from.line));return}if(!(ae.from.line>ie.lastLine())){if(ae.from.line<ie.first){var ge=ae.text.length-1-(ie.first-ae.from.line);ds(ie,ge),ae={from:kn(ie.first,0),to:kn(ae.to.line+ge,ae.to.ch),text:[Gt(ae.text)],origin:ae.origin}}var Me=ie.lastLine();ae.to.line>Me&&(ae={from:ae.from,to:kn(Me,wn(ie,Me).text.length),text:[ae.text[0]],origin:ae.origin}),ae.removed=pi(ie,ae.from,ae.to),de||(de=Ai(ie,ae)),ie.cm?Ba(ie.cm,ae,ce):tr(ie,ae,ce),zi(ie,de,Lt),ie.cantEdit&&wa(ie,kn(ie.firstLine(),0))&&(ie.cantEdit=!1)}}function Ba(ie,ae,de){var ce=ie.doc,ge=ie.display,Me=ae.from,He=ae.to,Je=!1,_e=Me.line;ie.options.lineWrapping||(_e=Dt(Ua(wn(ce,Me.line))),ce.iter(_e,He.line+1,function(mn){if(mn==ge.maxLine)return Je=!0,!0})),ce.sel.contains(ae.from,ae.to)>-1&&uo(ie),tr(ce,ae,de,Ns(ie)),ie.options.lineWrapping||(ce.iter(_e,Me.line+ae.text.length,function(mn){var xi=$a(mn);xi>ge.maxLineLength&&(ge.maxLine=mn,ge.maxLineLength=xi,ge.maxLineChanged=!0,Je=!1)}),Je&&(ie.curOp.updateMaxLine=!0)),Oo(ce,Me.line),da(ie,400);var lt=ae.text.length-(He.line-Me.line)-1;ae.full?xs(ie):Me.line==He.line&&ae.text.length==1&&!Pi(ie.doc,ae)?fi(ie,Me.line,"text"):xs(ie,Me.line,He.line+1,lt);var _t=vt(ie,"changes"),mt=vt(ie,"change");if(mt||_t){var Cn={from:Me,to:He,text:ae.text,removed:ae.removed,origin:ae.origin};mt&&vr(ie,"change",ie,Cn),_t&&(ie.curOp.changeObjs||(ie.curOp.changeObjs=[])).push(Cn)}ie.display.selForContextMenu=null}function Bo(ie,ae,de,ce,ge){var Me;ce||(ce=de),Xi(ce,de)<0&&(Me=[ce,de],de=Me[0],ce=Me[1]),typeof ae=="string"&&(ae=ie.splitLines(ae)),ro(ie,{from:de,to:ce,text:ae,origin:ge})}function Za(ie,ae,de,ce){de<ie.line?ie.line+=ce:ae<ie.line&&(ie.line=ae,ie.ch=0)}function Fa(ie,ae,de,ce){for(var ge=0;ge<ie.length;++ge){var Me=ie[ge],He=!0;if(Me.ranges){Me.copied||(Me=ie[ge]=Me.deepCopy(),Me.copied=!0);for(var Je=0;Je<Me.ranges.length;Je++)Za(Me.ranges[Je].anchor,ae,de,ce),Za(Me.ranges[Je].head,ae,de,ce);continue}for(var _e=0;_e<Me.changes.length;++_e){var lt=Me.changes[_e];if(de<lt.from.line)lt.from=kn(lt.from.line+ce,lt.from.ch),lt.to=kn(lt.to.line+ce,lt.to.ch);else if(ae<=lt.to.line){He=!1;break}}He||(ie.splice(0,ge+1),ge=0)}}function ns(ie,ae){var de=ae.from.line,ce=ae.to.line,ge=ae.text.length-(ce-de)-1;Fa(ie.done,de,ce,ge),Fa(ie.undone,de,ce,ge)}function Vi(ie,ae,de,ce){var ge=ae,Me=ae;return typeof ae=="number"?Me=wn(ie,Zi(ie,ae)):ge=Dt(ae),ge==null?null:(ce(Me,ge)&&ie.cm&&fi(ie.cm,ge,de),Me)}function Ki(ie){this.lines=ie,this.parent=null;for(var ae=0,de=0;de<ie.length;++de)ie[de].parent=this,ae+=ie[de].height;this.height=ae}Ki.prototype={chunkSize:function(){return this.lines.length},removeInner:function(ie,ae){for(var de=ie,ce=ie+ae;de<ce;++de){var ge=this.lines[de];this.height-=ge.height,el(ge),vr(ge,"delete")}this.lines.splice(ie,ae)},collapse:function(ie){ie.push.apply(ie,this.lines)},insertInner:function(ie,ae,de){this.height+=de,this.lines=this.lines.slice(0,ie).concat(ae).concat(this.lines.slice(ie));for(var ce=0;ce<ae.length;++ce)ae[ce].parent=this},iterN:function(ie,ae,de){for(var ce=ie+ae;ie<ce;++ie)if(de(this.lines[ie]))return!0}};function or(ie){this.children=ie;for(var ae=0,de=0,ce=0;ce<ie.length;++ce){var ge=ie[ce];ae+=ge.chunkSize(),de+=ge.height,ge.parent=this}this.size=ae,this.height=de,this.parent=null}or.prototype={chunkSize:function(){return this.size},removeInner:function(ie,ae){this.size-=ae;for(var de=0;de<this.children.length;++de){var ce=this.children[de],ge=ce.chunkSize();if(ie<ge){var Me=Math.min(ae,ge-ie),He=ce.height;if(ce.removeInner(ie,Me),this.height-=He-ce.height,ge==Me&&(this.children.splice(de--,1),ce.parent=null),(ae-=Me)==0)break;ie=0}else ie-=ge}if(this.size-ae<25&&(this.children.length>1||!(this.children[0]instanceof Ki))){var Je=[];this.collapse(Je),this.children=[new Ki(Je)],this.children[0].parent=this}},collapse:function(ie){for(var ae=0;ae<this.children.length;++ae)this.children[ae].collapse(ie)},insertInner:function(ie,ae,de){this.size+=ae.length,this.height+=de;for(var ce=0;ce<this.children.length;++ce){var ge=this.children[ce],Me=ge.chunkSize();if(ie<=Me){if(ge.insertInner(ie,ae,de),ge.lines&&ge.lines.length>50){for(var He=ge.lines.length%25+25,Je=He;Je<ge.lines.length;){var _e=new Ki(ge.lines.slice(Je,Je+=25));ge.height-=_e.height,this.children.splice(++ce,0,_e),_e.parent=this}ge.lines=ge.lines.slice(0,He),this.maybeSpill()}break}ie-=Me}},maybeSpill:function(){if(!(this.children.length<=10)){var ie=this;do{var ae=ie.children.splice(ie.children.length-5,5),de=new or(ae);if(ie.parent){ie.size-=de.size,ie.height-=de.height;var ge=ke(ie.parent.children,ie);ie.parent.children.splice(ge+1,0,de)}else{var ce=new or(ie.children);ce.parent=ie,ie.children=[ce,de],ie=ce}de.parent=ie.parent}while(ie.children.length>10);ie.parent.maybeSpill()}},iterN:function(ie,ae,de){for(var ce=0;ce<this.children.length;++ce){var ge=this.children[ce],Me=ge.chunkSize();if(ie<Me){var He=Math.min(ae,Me-ie);if(ge.iterN(ie,He,de))return!0;if((ae-=He)==0)break;ie=0}else ie-=Me}}};var Jr=function(ie,ae,de){if(de)for(var ce in de)de.hasOwnProperty(ce)&&(this[ce]=de[ce]);this.doc=ie,this.node=ae};Jr.prototype.clear=function(){var ie=this.doc.cm,ae=this.line.widgets,de=this.line,ce=Dt(de);if(!(ce==null||!ae)){for(var ge=0;ge<ae.length;++ge)ae[ge]==this&&ae.splice(ge--,1);ae.length||(de.widgets=null);var Me=iu(this);Rn(de,Math.max(0,de.height-Me)),ie&&(er(ie,function(){ta(ie,de,-Me),fi(ie,ce,"widget")}),vr(ie,"lineWidgetCleared",ie,this,ce))}},Jr.prototype.changed=function(){var ie=this,ae=this.height,de=this.doc.cm,ce=this.line;this.height=null;var ge=iu(this)-ae;ge&&(fn(this.doc,ce)||Rn(ce,ce.height+ge),de&&er(de,function(){de.curOp.forceUpdate=!0,ta(de,ce,ge),vr(de,"lineWidgetChanged",de,ie,Dt(ce))}))},ei(Jr);function ta(ie,ae,de){Ao(ae)<(ie.curOp&&ie.curOp.scrollTop||ie.doc.scrollTop)&&fc(ie,de)}function Ha(ie,ae,de,ce){var ge=new Jr(ie,de,ce),Me=ie.cm;return Me&&ge.noHScroll&&(Me.display.alignWidgets=!0),Vi(ie,ae,"widget",function(He){var Je=He.widgets||(He.widgets=[]);if(ge.insertAt==null?Je.push(ge):Je.splice(Math.min(Je.length-1,Math.max(0,ge.insertAt)),0,ge),ge.line=He,Me&&!fn(ie,He)){var _e=Ao(He)<ie.scrollTop;Rn(He,He.height+iu(ge)),_e&&fc(Me,ge.height),Me.curOp.forceUpdate=!0}return!0}),Me&&vr(Me,"lineWidgetAdded",Me,ge,typeof ae=="number"?ae:Dt(ae)),ge}var ls=0,bt=function(ie,ae){this.lines=[],this.type=ae,this.doc=ie,this.id=++ls};bt.prototype.clear=function(){if(!this.explicitlyCleared){var ie=this.doc.cm,ae=ie&&!ie.curOp;if(ae&&gi(ie),vt(this,"clear")){var de=this.find();de&&vr(this,"clear",de.from,de.to)}for(var ce=null,ge=null,Me=0;Me<this.lines.length;++Me){var He=this.lines[Me],Je=Ws(He.markedSpans,this);ie&&!this.collapsed?fi(ie,Dt(He),"text"):ie&&(Je.to!=null&&(ge=Dt(He)),Je.from!=null&&(ce=Dt(He))),He.markedSpans=qa(He.markedSpans,Je),Je.from==null&&this.collapsed&&!fn(this.doc,He)&&ie&&Rn(He,Nu(ie.display))}if(ie&&this.collapsed&&!ie.options.lineWrapping)for(var _e=0;_e<this.lines.length;++_e){var lt=Ua(this.lines[_e]),_t=$a(lt);_t>ie.display.maxLineLength&&(ie.display.maxLine=lt,ie.display.maxLineLength=_t,ie.display.maxLineChanged=!0)}ce!=null&&ie&&this.collapsed&&xs(ie,ce,ge+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,ie&&io(ie.doc)),ie&&vr(ie,"markerCleared",ie,this,ce,ge),ae&&ii(ie),this.parent&&this.parent.clear()}},bt.prototype.find=function(ie,ae){ie==null&&this.type=="bookmark"&&(ie=1);for(var de,ce,ge=0;ge<this.lines.length;++ge){var Me=this.lines[ge],He=Ws(Me.markedSpans,this);if(He.from!=null&&(de=kn(ae?Me:Dt(Me),He.from),ie==-1))return de;if(He.to!=null&&(ce=kn(ae?Me:Dt(Me),He.to),ie==1))return ce}return de&&{from:de,to:ce}},bt.prototype.changed=function(){var ie=this,ae=this.find(-1,!0),de=this,ce=this.doc.cm;!ae||!ce||er(ce,function(){var ge=ae.line,Me=Dt(ae.line),He=Gl(ce,Me);if(He&&(nc(He),ce.curOp.selectionChanged=ce.curOp.forceUpdate=!0),ce.curOp.updateMaxLine=!0,!fn(de.doc,ge)&&de.height!=null){var Je=de.height;de.height=null;var _e=iu(de)-Je;_e&&Rn(ge,ge.height+_e)}vr(ce,"markerChanged",ce,ie)})},bt.prototype.attachLine=function(ie){if(!this.lines.length&&this.doc.cm){var ae=this.doc.cm.curOp;(!ae.maybeHiddenMarkers||ke(ae.maybeHiddenMarkers,this)==-1)&&(ae.maybeUnhiddenMarkers||(ae.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(ie)},bt.prototype.detachLine=function(ie){if(this.lines.splice(ke(this.lines,ie),1),!this.lines.length&&this.doc.cm){var ae=this.doc.cm.curOp;(ae.maybeHiddenMarkers||(ae.maybeHiddenMarkers=[])).push(this)}},ei(bt);function xo(ie,ae,de,ce,ge){if(ce&&ce.shared)return na(ie,ae,de,ce,ge);if(ie.cm&&!ie.cm.curOp)return Yr(ie.cm,xo)(ie,ae,de,ce,ge);var Me=new bt(ie,ge),He=Xi(ae,de);if(ce&&Dn(ce,Me,!1),He>0||He==0&&Me.clearWhenEmpty!==!1)return Me;if(Me.replacedWith&&(Me.collapsed=!0,Me.widgetNode=Nt("span",[Me.replacedWith],"CodeMirror-widget"),ce.handleMouseEvents||Me.widgetNode.setAttribute("cm-ignore-events","true"),ce.insertLeft&&(Me.widgetNode.insertLeft=!0)),Me.collapsed){if(nu(ie,ae.line,ae,de,Me)||ae.line!=de.line&&nu(ie,de.line,ae,de,Me))throw new Error("Inserting collapsed marker partially overlapping an existing one");Pn()}Me.addToHistory&&Po(ie,{from:ae,to:de,origin:"markText"},ie.sel,NaN);var Je=ae.line,_e=ie.cm,lt;if(ie.iter(Je,de.line+1,function(mt){_e&&Me.collapsed&&!_e.options.lineWrapping&&Ua(mt)==_e.display.maxLine&&(lt=!0),Me.collapsed&&Je!=ae.line&&Rn(mt,0),bl(mt,new jo(Me,Je==ae.line?ae.ch:null,Je==de.line?de.ch:null)),++Je}),Me.collapsed&&ie.iter(ae.line,de.line+1,function(mt){fn(ie,mt)&&Rn(mt,0)}),Me.clearOnEnter&&oi(Me,"beforeCursorEnter",function(){return Me.clear()}),Me.readOnly&&(Ya(),(ie.history.done.length||ie.history.undone.length)&&ie.clearHistory()),Me.collapsed&&(Me.id=++ls,Me.atomic=!0),_e){if(lt&&(_e.curOp.updateMaxLine=!0),Me.collapsed)xs(_e,ae.line,de.line+1);else if(Me.className||Me.startStyle||Me.endStyle||Me.css||Me.attributes||Me.title)for(var _t=ae.line;_t<=de.line;_t++)fi(_e,_t,"text");Me.atomic&&io(_e.doc),vr(_e,"markerAdded",_e,Me)}return Me}var zo=function(ie,ae){this.markers=ie,this.primary=ae;for(var de=0;de<ie.length;++de)ie[de].parent=this};zo.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var ie=0;ie<this.markers.length;++ie)this.markers[ie].clear();vr(this,"clear")}},zo.prototype.find=function(ie,ae){return this.primary.find(ie,ae)},ei(zo);function na(ie,ae,de,ce,ge){ce=Dn(ce),ce.shared=!1;var Me=[xo(ie,ae,de,ce,ge)],He=Me[0],Je=ce.widgetNode;return ar(ie,function(_e){Je&&(ce.widgetNode=Je.cloneNode(!0)),Me.push(xo(_e,cr(_e,ae),cr(_e,de),ce,ge));for(var lt=0;lt<_e.linked.length;++lt)if(_e.linked[lt].isParent)return;He=Gt(Me)}),new zo(Me,He)}function js(ie){return ie.findMarks(kn(ie.first,0),ie.clipPos(kn(ie.lastLine())),function(ae){return ae.parent})}function us(ie,ae){for(var de=0;de<ae.length;de++){var ce=ae[de],ge=ce.find(),Me=ie.clipPos(ge.from),He=ie.clipPos(ge.to);if(Xi(Me,He)){var Je=xo(ie,Me,He,ce.primary,ce.primary.type);ce.markers.push(Je),Je.parent=ce}}}function Hi(ie){for(var ae=function(ce){var ge=ie[ce],Me=[ge.primary.doc];ar(ge.primary.doc,function(_e){return Me.push(_e)});for(var He=0;He<ge.markers.length;He++){var Je=ge.markers[He];ke(Me,Je.doc)==-1&&(Je.parent=null,ge.markers.splice(He--,1))}},de=0;de<ie.length;de++)ae(de)}var Tr=0,nr=function(ie,ae,de,ce,ge){if(!(this instanceof nr))return new nr(ie,ae,de,ce,ge);de==null&&(de=0),or.call(this,[new Ki([new ms("",null)])]),this.first=de,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=de;var Me=kn(de,0);this.sel=ni(Me),this.history=new Mr(null),this.id=++Tr,this.modeOption=ae,this.lineSep=ce,this.direction=ge=="rtl"?"rtl":"ltr",this.extend=!1,typeof ie=="string"&&(ie=this.splitLines(ie)),tr(this,{from:Me,to:Me,text:ie}),Fi(this,ni(Me),Lt)};nr.prototype=be(or.prototype,{constructor:nr,iter:function(ie,ae,de){de?this.iterN(ie-this.first,ae-ie,de):this.iterN(this.first,this.first+this.size,ie)},insert:function(ie,ae){for(var de=0,ce=0;ce<ae.length;++ce)de+=ae[ce].height;this.insertInner(ie-this.first,ae,de)},remove:function(ie,ae){this.removeInner(ie-this.first,ae)},getValue:function(ie){var ae=ji(this,this.first,this.first+this.size);return ie===!1?ae:ae.join(ie||this.lineSeparator())},setValue:Wr(function(ie){var ae=kn(this.first,0),de=this.first+this.size-1;ro(this,{from:ae,to:kn(de,wn(this,de).text.length),text:this.splitLines(ie),origin:"setValue",full:!0},!0),this.cm&&Fh(this.cm,0,0),Fi(this,ni(ae),Lt)}),replaceRange:function(ie,ae,de,ce){ae=cr(this,ae),de=de?cr(this,de):ae,Bo(this,ie,ae,de,ce)},getRange:function(ie,ae,de){var ce=pi(this,cr(this,ie),cr(this,ae));return de===!1?ce:ce.join(de||this.lineSeparator())},getLine:function(ie){var ae=this.getLineHandle(ie);return ae&&ae.text},getLineHandle:function(ie){if(gr(this,ie))return wn(this,ie)},getLineNumber:function(ie){return Dt(ie)},getLineHandleVisualStart:function(ie){return typeof ie=="number"&&(ie=wn(this,ie)),Ua(ie)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(ie){return cr(this,ie)},getCursor:function(ie){var ae=this.sel.primary(),de;return ie==null||ie=="head"?de=ae.head:ie=="anchor"?de=ae.anchor:ie=="end"||ie=="to"||ie===!1?de=ae.to():de=ae.from(),de},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:Wr(function(ie,ae,de){Wi(this,cr(this,typeof ie=="number"?kn(ie,ae||0):ie),null,de)}),setSelection:Wr(function(ie,ae,de){Wi(this,cr(this,ie),cr(this,ae||ie),de)}),extendSelection:Wr(function(ie,ae,de){Vr(this,cr(this,ie),ae&&cr(this,ae),de)}),extendSelections:Wr(function(ie,ae){Do(this,Zo(this,ie),ae)}),extendSelectionsBy:Wr(function(ie,ae){var de=an(this.sel.ranges,ie);Do(this,Zo(this,de),ae)}),setSelections:Wr(function(ie,ae,de){if(ie.length){for(var ce=[],ge=0;ge<ie.length;ge++)ce[ge]=new Mn(cr(this,ie[ge].anchor),cr(this,ie[ge].head));ae==null&&(ae=Math.min(ie.length-1,this.sel.primIndex)),Fi(this,Kn(this.cm,ce,ae),de)}}),addSelection:Wr(function(ie,ae,de){var ce=this.sel.ranges.slice(0);ce.push(new Mn(cr(this,ie),cr(this,ae||ie))),Fi(this,Kn(this.cm,ce,ce.length-1),de)}),getSelection:function(ie){for(var ae=this.sel.ranges,de,ce=0;ce<ae.length;ce++){var ge=pi(this,ae[ce].from(),ae[ce].to());de=de?de.concat(ge):ge}return ie===!1?de:de.join(ie||this.lineSeparator())},getSelections:function(ie){for(var ae=[],de=this.sel.ranges,ce=0;ce<de.length;ce++){var ge=pi(this,de[ce].from(),de[ce].to());ie!==!1&&(ge=ge.join(ie||this.lineSeparator())),ae[ce]=ge}return ae},replaceSelection:function(ie,ae,de){for(var ce=[],ge=0;ge<this.sel.ranges.length;ge++)ce[ge]=ie;this.replaceSelections(ce,ae,de||"+input")},replaceSelections:Wr(function(ie,ae,de){for(var ce=[],ge=this.sel,Me=0;Me<ge.ranges.length;Me++){var He=ge.ranges[Me];ce[Me]={from:He.from(),to:He.to(),text:this.splitLines(ie[Me]),origin:de}}for(var Je=ae&&ae!="end"&&dr(this,ce,ae),_e=ce.length-1;_e>=0;_e--)ro(this,ce[_e]);Je?rr(this,Je):this.cm&&kh(this.cm)}),undo:Wr(function(){va(this,"undo")}),redo:Wr(function(){va(this,"redo")}),undoSelection:Wr(function(){va(this,"undo",!0)}),redoSelection:Wr(function(){va(this,"redo",!0)}),setExtending:function(ie){this.extend=ie},getExtending:function(){return this.extend},historySize:function(){for(var ie=this.history,ae=0,de=0,ce=0;ce<ie.done.length;ce++)ie.done[ce].ranges||++ae;for(var ge=0;ge<ie.undone.length;ge++)ie.undone[ge].ranges||++de;return{undo:ae,redo:de}},clearHistory:function(){var ie=this;this.history=new Mr(this.history.maxGeneration),ar(this,function(ae){return ae.history=ie.history},!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(ie){return ie&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(ie){return this.history.generation==(ie||this.cleanGeneration)},getHistory:function(){return{done:Ar(this.history.done),undone:Ar(this.history.undone)}},setHistory:function(ie){var ae=this.history=new Mr(this.history.maxGeneration);ae.done=Ar(ie.done.slice(0),null,!0),ae.undone=Ar(ie.undone.slice(0),null,!0)},setGutterMarker:Wr(function(ie,ae,de){return Vi(this,ie,"gutter",function(ce){var ge=ce.gutterMarkers||(ce.gutterMarkers={});return ge[ae]=de,!de&&Fe(ge)&&(ce.gutterMarkers=null),!0})}),clearGutter:Wr(function(ie){var ae=this;this.iter(function(de){de.gutterMarkers&&de.gutterMarkers[ie]&&Vi(ae,de,"gutter",function(){return de.gutterMarkers[ie]=null,Fe(de.gutterMarkers)&&(de.gutterMarkers=null),!0})})}),lineInfo:function(ie){var ae;if(typeof ie=="number"){if(!gr(this,ie)||(ae=ie,ie=wn(this,ie),!ie))return null}else if(ae=Dt(ie),ae==null)return null;return{line:ae,handle:ie,text:ie.text,gutterMarkers:ie.gutterMarkers,textClass:ie.textClass,bgClass:ie.bgClass,wrapClass:ie.wrapClass,widgets:ie.widgets}},addLineClass:Wr(function(ie,ae,de){return Vi(this,ie,ae=="gutter"?"gutter":"class",function(ce){var ge=ae=="text"?"textClass":ae=="background"?"bgClass":ae=="gutter"?"gutterClass":"wrapClass";if(!ce[ge])ce[ge]=de;else{if(Ge(de).test(ce[ge]))return!1;ce[ge]+=" "+de}return!0})}),removeLineClass:Wr(function(ie,ae,de){return Vi(this,ie,ae=="gutter"?"gutter":"class",function(ce){var ge=ae=="text"?"textClass":ae=="background"?"bgClass":ae=="gutter"?"gutterClass":"wrapClass",Me=ce[ge];if(Me)if(de==null)ce[ge]=null;else{var He=Me.match(Ge(de));if(!He)return!1;var Je=He.index+He[0].length;ce[ge]=Me.slice(0,He.index)+(!He.index||Je==Me.length?"":" ")+Me.slice(Je)||null}else return!1;return!0})}),addLineWidget:Wr(function(ie,ae,de){return Ha(this,ie,ae,de)}),removeLineWidget:function(ie){ie.clear()},markText:function(ie,ae,de){return xo(this,cr(this,ie),cr(this,ae),de,de&&de.type||"range")},setBookmark:function(ie,ae){var de={replacedWith:ae&&(ae.nodeType==null?ae.widget:ae),insertLeft:ae&&ae.insertLeft,clearWhenEmpty:!1,shared:ae&&ae.shared,handleMouseEvents:ae&&ae.handleMouseEvents};return ie=cr(this,ie),xo(this,ie,ie,de,"bookmark")},findMarksAt:function(ie){ie=cr(this,ie);var ae=[],de=wn(this,ie.line).markedSpans;if(de)for(var ce=0;ce<de.length;++ce){var ge=de[ce];(ge.from==null||ge.from<=ie.ch)&&(ge.to==null||ge.to>=ie.ch)&&ae.push(ge.marker.parent||ge.marker)}return ae},findMarks:function(ie,ae,de){ie=cr(this,ie),ae=cr(this,ae);var ce=[],ge=ie.line;return this.iter(ie.line,ae.line+1,function(Me){var He=Me.markedSpans;if(He)for(var Je=0;Je<He.length;Je++){var _e=He[Je];!(_e.to!=null&&ge==ie.line&&ie.ch>=_e.to||_e.from==null&&ge!=ie.line||_e.from!=null&&ge==ae.line&&_e.from>=ae.ch)&&(!de||de(_e.marker))&&ce.push(_e.marker.parent||_e.marker)}++ge}),ce},getAllMarks:function(){var ie=[];return this.iter(function(ae){var de=ae.markedSpans;if(de)for(var ce=0;ce<de.length;++ce)de[ce].from!=null&&ie.push(de[ce].marker)}),ie},posFromIndex:function(ie){var ae,de=this.first,ce=this.lineSeparator().length;return this.iter(function(ge){var Me=ge.text.length+ce;if(Me>ie)return ae=ie,!0;ie-=Me,++de}),cr(this,kn(de,ae))},indexFromPos:function(ie){ie=cr(this,ie);var ae=ie.ch;if(ie.line<this.first||ie.ch<0)return 0;var de=this.lineSeparator().length;return this.iter(this.first,ie.line,function(ce){ae+=ce.text.length+de}),ae},copy:function(ie){var ae=new nr(ji(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return ae.scrollTop=this.scrollTop,ae.scrollLeft=this.scrollLeft,ae.sel=this.sel,ae.extend=!1,ie&&(ae.history.undoDepth=this.history.undoDepth,ae.setHistory(this.getHistory())),ae},linkedDoc:function(ie){ie||(ie={});var ae=this.first,de=this.first+this.size;ie.from!=null&&ie.from>ae&&(ae=ie.from),ie.to!=null&&ie.to<de&&(de=ie.to);var ce=new nr(ji(this,ae,de),ie.mode||this.modeOption,ae,this.lineSep,this.direction);return ie.sharedHist&&(ce.history=this.history),(this.linked||(this.linked=[])).push({doc:ce,sharedHist:ie.sharedHist}),ce.linked=[{doc:this,isParent:!0,sharedHist:ie.sharedHist}],us(ce,js(this)),ce},unlinkDoc:function(ie){if(ie instanceof Es&&(ie=ie.doc),this.linked)for(var ae=0;ae<this.linked.length;++ae){var de=this.linked[ae];if(de.doc==ie){this.linked.splice(ae,1),ie.unlinkDoc(this),Hi(js(this));break}}if(ie.history==this.history){var ce=[ie.id];ar(ie,function(ge){return ce.push(ge.id)},!0),ie.history=new Mr(null),ie.history.done=Ar(this.history.done,ce),ie.history.undone=Ar(this.history.undone,ce)}},iterLinkedDocs:function(ie){ar(this,ie)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(ie){return this.lineSep?ie.split(this.lineSep):Fn(ie)},lineSeparator:function(){return this.lineSep||`
`},setDirection:Wr(function(ie){ie!="rtl"&&(ie="ltr"),ie!=this.direction&&(this.direction=ie,this.iter(function(ae){return ae.order=null}),this.cm&&hr(this.cm))})}),nr.prototype.eachLine=nr.prototype.iter;var ho=0;function Ca(ie){var ae=this;if(Eo(ae),!(Di(ae,ie)||yl(ae.display,ie))){co(ie),kt&&(ho=+new Date);var de=Bl(ae,ie,!0),ce=ie.dataTransfer.files;if(!(!de||ae.isReadOnly()))if(ce&&ce.length&&window.FileReader&&window.File)for(var ge=ce.length,Me=Array(ge),He=0,Je=function(){++He==ge&&Yr(ae,function(){de=cr(ae.doc,de);var mn={from:de,to:de,text:ae.doc.splitLines(Me.filter(function(xi){return xi!=null}).join(ae.doc.lineSeparator())),origin:"paste"};ro(ae.doc,mn),rr(ae.doc,ni(cr(ae.doc,de),cr(ae.doc,yi(mn))))})()},_e=function(mn,xi){if(ae.options.allowDropFileTypes&&ke(ae.options.allowDropFileTypes,mn.type)==-1){Je();return}var Mi=new FileReader;Mi.onerror=function(){return Je()},Mi.onload=function(){var Yi=Mi.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(Yi)){Je();return}Me[xi]=Yi,Je()},Mi.readAsText(mn)},lt=0;lt<ce.length;lt++)_e(ce[lt],lt);else{if(ae.state.draggingText&&ae.doc.sel.contains(de)>-1){ae.state.draggingText(ie),setTimeout(function(){return ae.display.input.focus()},20);return}try{var _t=ie.dataTransfer.getData("Text");if(_t){var mt;if(ae.state.draggingText&&!ae.state.draggingText.copy&&(mt=ae.listSelections()),zi(ae.doc,ni(de,de)),mt)for(var Cn=0;Cn<mt.length;++Cn)Bo(ae.doc,"",mt[Cn].anchor,mt[Cn].head,"drag");ae.replaceSelection(_t,"around","paste"),ae.display.input.focus()}}catch(mn){}}}}function Rr(ie,ae){if(kt&&(!ie.state.draggingText||+new Date-ho<100)){yo(ae);return}if(!(Di(ie,ae)||yl(ie.display,ae))&&(ae.dataTransfer.setData("Text",ie.getSelection()),ae.dataTransfer.effectAllowed="copyMove",ae.dataTransfer.setDragImage&&!Qt)){var de=it("img",null,null,"position: fixed; left: 0; top: 0;");de.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",wt&&(de.width=de.height=1,ie.display.wrapper.appendChild(de),de._top=de.offsetTop),ae.dataTransfer.setDragImage(de,0,0),wt&&de.parentNode.removeChild(de)}}function Qo(ie,ae){var de=Bl(ie,ae);if(de){var ce=document.createDocumentFragment();ka(ie,de,ce),ie.display.dragCursor||(ie.display.dragCursor=it("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),ie.display.lineSpace.insertBefore(ie.display.dragCursor,ie.display.cursorDiv)),st(ie.display.dragCursor,ce)}}function Eo(ie){ie.display.dragCursor&&(ie.display.lineSpace.removeChild(ie.display.dragCursor),ie.display.dragCursor=null)}function Go(ie){if(document.getElementsByClassName){for(var ae=document.getElementsByClassName("CodeMirror"),de=[],ce=0;ce<ae.length;ce++){var ge=ae[ce].CodeMirror;ge&&de.push(ge)}de.length&&de[0].operation(function(){for(var Me=0;Me<de.length;Me++)ie(de[Me])})}}var fa=!1;function Aa(){fa||(ll(),fa=!0)}function ll(){var ie;oi(window,"resize",function(){ie==null&&(ie=setTimeout(function(){ie=null,Go(Yl)},100))}),oi(window,"blur",function(){return Go(vu)})}function Yl(ie){var ae=ie.display;ae.cachedCharWidth=ae.cachedTextHeight=ae.cachedPaddingH=null,ae.scrollbarsClipped=!1,ie.setSize()}for(var ya={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Mod",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},Yo=0;Yo<10;Yo++)ya[Yo+48]=ya[Yo+96]=String(Yo);for(var Sa=65;Sa<=90;Sa++)ya[Sa]=String.fromCharCode(Sa);for(var is=1;is<=12;is++)ya[is+111]=ya[is+63235]="F"+is;var Bs={};Bs.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},Bs.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},Bs.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},Bs.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},Bs.default=he?Bs.macDefault:Bs.pcDefault;function tl(ie){var ae=ie.split(/-(?!$)/);ie=ae[ae.length-1];for(var de,ce,ge,Me,He=0;He<ae.length-1;He++){var Je=ae[He];if(/^(cmd|meta|m)$/i.test(Je))Me=!0;else if(/^a(lt)?$/i.test(Je))de=!0;else if(/^(c|ctrl|control)$/i.test(Je))ce=!0;else if(/^s(hift)?$/i.test(Je))ge=!0;else throw new Error("Unrecognized modifier name: "+Je)}return de&&(ie="Alt-"+ie),ce&&(ie="Ctrl-"+ie),Me&&(ie="Cmd-"+ie),ge&&(ie="Shift-"+ie),ie}function oo(ie){var ae={};for(var de in ie)if(ie.hasOwnProperty(de)){var ce=ie[de];if(/^(name|fallthrough|(de|at)tach)$/.test(de))continue;if(ce=="..."){delete ie[de];continue}for(var ge=an(de.split(" "),tl),Me=0;Me<ge.length;Me++){var He=void 0,Je=void 0;Me==ge.length-1?(Je=ge.join(" "),He=ce):(Je=ge.slice(0,Me+1).join(" "),He="...");var _e=ae[Je];if(!_e)ae[Je]=He;else if(_e!=He)throw new Error("Inconsistent bindings for "+Je)}delete ie[de]}for(var lt in ae)ie[lt]=ae[lt];return ie}function Ur(ie,ae,de,ce){ae=hl(ae);var ge=ae.call?ae.call(ie,ce):ae[ie];if(ge===!1)return"nothing";if(ge==="...")return"multi";if(ge!=null&&de(ge))return"handled";if(ae.fallthrough){if(Object.prototype.toString.call(ae.fallthrough)!="[object Array]")return Ur(ie,ae.fallthrough,de,ce);for(var Me=0;Me<ae.fallthrough.length;Me++){var He=Ur(ie,ae.fallthrough[Me],de,ce);if(He)return He}}}function hs(ie){var ae=typeof ie=="string"?ie:ya[ie.keyCode];return ae=="Ctrl"||ae=="Alt"||ae=="Shift"||ae=="Mod"}function ul(ie,ae,de){var ce=ie;return ae.altKey&&ce!="Alt"&&(ie="Alt-"+ie),(xe?ae.metaKey:ae.ctrlKey)&&ce!="Ctrl"&&(ie="Ctrl-"+ie),(xe?ae.ctrlKey:ae.metaKey)&&ce!="Mod"&&(ie="Cmd-"+ie),!de&&ae.shiftKey&&ce!="Shift"&&(ie="Shift-"+ie),ie}function nl(ie,ae){if(wt&&ie.keyCode==34&&ie.char)return!1;var de=ya[ie.keyCode];return de==null||ie.altGraphKey?!1:(ie.keyCode==3&&ie.code&&(de=ie.code),ul(de,ie,ae))}function hl(ie){return typeof ie=="string"?Bs[ie]:ie}function Os(ie,ae){for(var de=ie.doc.sel.ranges,ce=[],ge=0;ge<de.length;ge++){for(var Me=ae(de[ge]);ce.length&&Xi(Me.from,Gt(ce).to)<=0;){var He=ce.pop();if(Xi(He.from,Me.from)<0){Me.from=He.from;break}}ce.push(Me)}er(ie,function(){for(var Je=ce.length-1;Je>=0;Je--)Bo(ie.doc,"",ce[Je].from,ce[Je].to,"+delete");kh(ie)})}function Xl(ie,ae,de){var ce=ui(ie.text,ae+de,de);return ce<0||ce>ie.text.length?null:ce}function Ps(ie,ae,de){var ce=Xl(ie,ae.ch,de);return ce==null?null:new kn(ae.line,ce,de<0?"after":"before")}function Ol(ie,ae,de,ce,ge){if(ie){ae.doc.direction=="rtl"&&(ge=-ge);var Me=ti(de,ae.doc.direction);if(Me){var He=ge<0?Gt(Me):Me[0],Je=ge<0==(He.level==1),_e=Je?"after":"before",lt;if(He.level>0||ae.doc.direction=="rtl"){var _t=Qu(ae,de);lt=ge<0?de.text.length-1:0;var mt=pu(ae,_t,lt).top;lt=$n(function(Cn){return pu(ae,_t,Cn).top==mt},ge<0==(He.level==1)?He.from:He.to-1,lt),_e=="before"&&(lt=Xl(de,lt,1))}else lt=ge<0?He.to:He.from;return new kn(ce,lt,_e)}}return new kn(ce,ge<0?de.text.length:0,ge<0?"before":"after")}function eh(ie,ae,de,ce){var ge=ti(ae,ie.doc.direction);if(!ge)return Ps(ae,de,ce);de.ch>=ae.text.length?(de.ch=ae.text.length,de.sticky="before"):de.ch<=0&&(de.ch=0,de.sticky="after");var Me=Zt(ge,de.ch,de.sticky),He=ge[Me];if(ie.doc.direction=="ltr"&&He.level%2==0&&(ce>0?He.to>de.ch:He.from<de.ch))return Ps(ae,de,ce);var Je=function(Cr,ao){return Xl(ae,Cr instanceof kn?Cr.ch:Cr,ao)},_e,lt=function(Cr){return ie.options.lineWrapping?(_e=_e||Qu(ie,ae),Kh(ie,ae,_e,Cr)):{begin:0,end:ae.text.length}},_t=lt(de.sticky=="before"?Je(de,-1):de.ch);if(ie.doc.direction=="rtl"||He.level==1){var mt=He.level==1==ce<0,Cn=Je(de,mt?1:-1);if(Cn!=null&&(mt?Cn<=He.to&&Cn<=_t.end:Cn>=He.from&&Cn>=_t.begin)){var mn=mt?"before":"after";return new kn(de.line,Cn,mn)}}var xi=function(Cr,ao,Gr){for(var wo=function(fl,uu){return uu?new kn(de.line,Je(fl,1),"before"):new kn(de.line,fl,"after")};Cr>=0&&Cr<ge.length;Cr+=ao){var ua=ge[Cr],Hr=ao>0==(ua.level!=1),_a=Hr?Gr.begin:Je(Gr.end,-1);if(ua.from<=_a&&_a<ua.to||(_a=Hr?ua.from:Je(ua.to,-1),Gr.begin<=_a&&_a<Gr.end))return wo(_a,Hr)}},Mi=xi(Me+ce,ce,_t);if(Mi)return Mi;var Yi=ce>0?_t.end:Je(_t.begin,-1);return Yi!=null&&!(ce>0&&Yi==ae.text.length)&&(Mi=xi(ce>0?0:ge.length-1,ce,lt(Yi)),Mi)?Mi:null}var Vh={selectAll:Xo,singleSelection:function(ie){return ie.setSelection(ie.getCursor("anchor"),ie.getCursor("head"),Lt)},killLine:function(ie){return Os(ie,function(ae){if(ae.empty()){var de=wn(ie.doc,ae.head.line).text.length;return ae.head.ch==de&&ae.head.line<ie.lastLine()?{from:ae.head,to:kn(ae.head.line+1,0)}:{from:ae.head,to:kn(ae.head.line,de)}}else return{from:ae.from(),to:ae.to()}})},deleteLine:function(ie){return Os(ie,function(ae){return{from:kn(ae.from().line,0),to:cr(ie.doc,kn(ae.to().line+1,0))}})},delLineLeft:function(ie){return Os(ie,function(ae){return{from:kn(ae.from().line,0),to:ae.from()}})},delWrappedLineLeft:function(ie){return Os(ie,function(ae){var de=ie.charCoords(ae.head,"div").top+5,ce=ie.coordsChar({left:0,top:de},"div");return{from:ce,to:ae.from()}})},delWrappedLineRight:function(ie){return Os(ie,function(ae){var de=ie.charCoords(ae.head,"div").top+5,ce=ie.coordsChar({left:ie.display.lineDiv.offsetWidth+100,top:de},"div");return{from:ae.from(),to:ce}})},undo:function(ie){return ie.undo()},redo:function(ie){return ie.redo()},undoSelection:function(ie){return ie.undoSelection()},redoSelection:function(ie){return ie.redoSelection()},goDocStart:function(ie){return ie.extendSelection(kn(ie.firstLine(),0))},goDocEnd:function(ie){return ie.extendSelection(kn(ie.lastLine()))},goLineStart:function(ie){return ie.extendSelectionsBy(function(ae){return jc(ie,ae.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(ie){return ie.extendSelectionsBy(function(ae){return pd(ie,ae.head)},{origin:"+move",bias:1})},goLineEnd:function(ie){return ie.extendSelectionsBy(function(ae){return Lc(ie,ae.head.line)},{origin:"+move",bias:-1})},goLineRight:function(ie){return ie.extendSelectionsBy(function(ae){var de=ie.cursorCoords(ae.head,"div").top+5;return ie.coordsChar({left:ie.display.lineDiv.offsetWidth+100,top:de},"div")},vn)},goLineLeft:function(ie){return ie.extendSelectionsBy(function(ae){var de=ie.cursorCoords(ae.head,"div").top+5;return ie.coordsChar({left:0,top:de},"div")},vn)},goLineLeftSmart:function(ie){return ie.extendSelectionsBy(function(ae){var de=ie.cursorCoords(ae.head,"div").top+5,ce=ie.coordsChar({left:0,top:de},"div");return ce.ch<ie.getLine(ce.line).search(/\S/)?pd(ie,ae.head):ce},vn)},goLineUp:function(ie){return ie.moveV(-1,"line")},goLineDown:function(ie){return ie.moveV(1,"line")},goPageUp:function(ie){return ie.moveV(-1,"page")},goPageDown:function(ie){return ie.moveV(1,"page")},goCharLeft:function(ie){return ie.moveH(-1,"char")},goCharRight:function(ie){return ie.moveH(1,"char")},goColumnLeft:function(ie){return ie.moveH(-1,"column")},goColumnRight:function(ie){return ie.moveH(1,"column")},goWordLeft:function(ie){return ie.moveH(-1,"word")},goGroupRight:function(ie){return ie.moveH(1,"group")},goGroupLeft:function(ie){return ie.moveH(-1,"group")},goWordRight:function(ie){return ie.moveH(1,"word")},delCharBefore:function(ie){return ie.deleteH(-1,"codepoint")},delCharAfter:function(ie){return ie.deleteH(1,"char")},delWordBefore:function(ie){return ie.deleteH(-1,"word")},delWordAfter:function(ie){return ie.deleteH(1,"word")},delGroupBefore:function(ie){return ie.deleteH(-1,"group")},delGroupAfter:function(ie){return ie.deleteH(1,"group")},indentAuto:function(ie){return ie.indentSelection("smart")},indentMore:function(ie){return ie.indentSelection("add")},indentLess:function(ie){return ie.indentSelection("subtract")},insertTab:function(ie){return ie.replaceSelection(" ")},insertSoftTab:function(ie){for(var ae=[],de=ie.listSelections(),ce=ie.options.tabSize,ge=0;ge<de.length;ge++){var Me=de[ge].from(),He=nt(ie.getLine(Me.line),Me.ch,ce);ae.push(ft(ce-He%ce))}ie.replaceSelections(ae)},defaultTab:function(ie){ie.somethingSelected()?ie.indentSelection("add"):ie.execCommand("insertTab")},transposeChars:function(ie){return er(ie,function(){for(var ae=ie.listSelections(),de=[],ce=0;ce<ae.length;ce++)if(ae[ce].empty()){var ge=ae[ce].head,Me=wn(ie.doc,ge.line).text;if(Me){if(ge.ch==Me.length&&(ge=new kn(ge.line,ge.ch-1)),ge.ch>0)ge=new kn(ge.line,ge.ch+1),ie.replaceRange(Me.charAt(ge.ch-1)+Me.charAt(ge.ch-2),kn(ge.line,ge.ch-2),ge,"+transpose");else if(ge.line>ie.doc.first){var He=wn(ie.doc,ge.line-1).text;He&&(ge=new kn(ge.line,1),ie.replaceRange(Me.charAt(0)+ie.doc.lineSeparator()+He.charAt(He.length-1),kn(ge.line-1,He.length-1),ge,"+transpose"))}}de.push(new Mn(ge,ge))}ie.setSelections(de)})},newlineAndIndent:function(ie){return er(ie,function(){for(var ae=ie.listSelections(),de=ae.length-1;de>=0;de--)ie.replaceRange(ie.doc.lineSeparator(),ae[de].anchor,ae[de].head,"+input");ae=ie.listSelections();for(var ce=0;ce<ae.length;ce++)ie.indentLine(ae[ce].from().line,null,!0);kh(ie)})},openLine:function(ie){return ie.replaceSelection(`
`,"start")},toggleOverwrite:function(ie){return ie.toggleOverwrite()}};function jc(ie,ae){var de=wn(ie.doc,ae),ce=Ua(de);return ce!=de&&(ae=Dt(ce)),Ol(!0,ie,ce,ae,1)}function Lc(ie,ae){var de=wn(ie.doc,ae),ce=ps(de);return ce!=de&&(ae=Dt(ce)),Ol(!0,ie,de,ae,-1)}function pd(ie,ae){var de=jc(ie,ae.line),ce=wn(ie.doc,de.line),ge=ti(ce,ie.doc.direction);if(!ge||ge[0].level==0){var Me=Math.max(de.ch,ce.text.search(/\S/)),He=ae.line==de.line&&ae.ch<=Me&&ae.ch;return kn(de.line,He?0:Me,de.sticky)}return de}function zc(ie,ae,de){if(typeof ae=="string"&&(ae=Vh[ae],!ae))return!1;ie.display.input.ensurePolled();var ce=ie.display.shift,ge=!1;try{ie.isReadOnly()&&(ie.state.suppressEdits=!0),de&&(ie.display.shift=!1),ge=ae(ie)!=On}finally{ie.display.shift=ce,ie.state.suppressEdits=!1}return ge}function ed(ie,ae,de){for(var ce=0;ce<ie.state.keyMaps.length;ce++){var ge=Ur(ae,ie.state.keyMaps[ce],de,ie);if(ge)return ge}return ie.options.extraKeys&&Ur(ae,ie.options.extraKeys,de,ie)||Ur(ae,ie.options.keyMap,de,ie)}var dh=new ze;function cs(ie,ae,de,ce){var ge=ie.state.keySeq;if(ge){if(hs(ae))return"handled";if(/\'$/.test(ae)?ie.state.keySeq=null:dh.set(50,function(){ie.state.keySeq==ge&&(ie.state.keySeq=null,ie.display.input.reset())}),Qa(ie,ge+" "+ae,de,ce))return!0}return Qa(ie,ae,de,ce)}function Qa(ie,ae,de,ce){var ge=ed(ie,ae,ce);return ge=="multi"&&(ie.state.keySeq=ae),ge=="handled"&&vr(ie,"keyHandled",ie,ae,de),(ge=="handled"||ge=="multi")&&(co(de),ts(ie)),!!ge}function au(ie,ae){var de=nl(ae,!0);return de?ae.shiftKey&&!ie.state.keySeq?cs(ie,"Shift-"+de,ae,function(ce){return zc(ie,ce,!0)})||cs(ie,de,ae,function(ce){if(typeof ce=="string"?/^go[A-Z]/.test(ce):ce.motion)return zc(ie,ce)}):cs(ie,de,ae,function(ce){return zc(ie,ce)}):!1}function Jl(ie,ae,de){return cs(ie,"'"+de+"'",ae,function(ce){return zc(ie,ce,!0)})}var Qs=null;function Ea(ie){var ae=this;if(!(ie.target&&ie.target!=ae.display.input.getField())&&(ae.curOp.focus=cn(),!Di(ae,ie))){kt&&Ie<11&&ie.keyCode==27&&(ie.returnValue=!1);var de=ie.keyCode;ae.display.shift=de==16||ie.shiftKey;var ce=au(ae,ie);wt&&(Qs=ce?de:null,!ce&&de==88&&!Qn&&(he?ie.metaKey:ie.ctrlKey)&&ae.replaceSelection("",null,"cut")),Ne&&!he&&!ce&&de==46&&ie.shiftKey&&!ie.ctrlKey&&document.execCommand&&document.execCommand("cut"),de==18&&!/\bCodeMirror-crosshair\b/.test(ae.display.lineDiv.className)&&ba(ae)}}function ba(ie){var ae=ie.display.lineDiv;Tt(ae,"CodeMirror-crosshair");function de(ce){(ce.keyCode==18||!ce.altKey)&&(et(ae,"CodeMirror-crosshair"),fr(document,"keyup",de),fr(document,"mouseover",de))}oi(document,"keyup",de),oi(document,"mouseover",de)}function cl(ie){ie.keyCode==16&&(this.doc.sel.shift=!1),Di(this,ie)}function zs(ie){var ae=this;if(!(ie.target&&ie.target!=ae.display.input.getField())&&!(yl(ae.display,ie)||Di(ae,ie)||ie.ctrlKey&&!ie.altKey||he&&ie.metaKey)){var de=ie.keyCode,ce=ie.charCode;if(wt&&de==Qs){Qs=null,co(ie);return}if(!(wt&&(!ie.which||ie.which<10)&&au(ae,ie))){var ge=String.fromCharCode(ce==null?de:ce);ge!="\b"&&(Jl(ae,ie,ge)||ae.display.input.onKeyPress(ie))}}}var dl=400,Sl=function(ie,ae,de){this.time=ie,this.pos=ae,this.button=de};Sl.prototype.compare=function(ie,ae,de){return this.time+dl>ie&&Xi(ae,this.pos)==0&&de==this.button};var su,Vl;function Mc(ie,ae){var de=+new Date;return Vl&&Vl.compare(de,ie,ae)?(su=Vl=null,"triple"):su&&su.compare(de,ie,ae)?(Vl=new Sl(de,ie,ae),su=null,"double"):(su=new Sl(de,ie,ae),Vl=null,"single")}function Ku(ie){var ae=this,de=ae.display;if(!(Di(ae,ie)||de.activeTouch&&de.input.supportsTouch())){if(de.input.ensurePolled(),de.shift=ie.shiftKey,yl(de,ie)){$e||(de.scroller.draggable=!1,setTimeout(function(){return de.scroller.draggable=!0},100));return}if(!ug(ae,ie)){var ce=Bl(ae,ie),ge=Ka(ie),Me=ce?Mc(ce,ge):"single";window.focus(),ge==1&&ae.state.selectingText&&ae.state.selectingText(ie),!(ce&&kc(ae,ge,ce,Me,ie))&&(ge==1?ce?Hd(ae,ce,Me,ie):ha(ie)==de.scroller&&co(ie):ge==2?(ce&&Vr(ae.doc,ce),setTimeout(function(){return de.input.focus()},20)):ge==3&&(Ee?ae.display.input.onContextMenu(ie):ws(ae)))}}}function kc(ie,ae,de,ce,ge){var Me="Click";return ce=="double"?Me="Double"+Me:ce=="triple"&&(Me="Triple"+Me),Me=(ae==1?"Left":ae==2?"Middle":"Right")+Me,cs(ie,ul(Me,ge),ge,function(He){if(typeof He=="string"&&(He=Vh[He]),!He)return!1;var Je=!1;try{ie.isReadOnly()&&(ie.state.suppressEdits=!0),Je=He(ie,de)!=On}finally{ie.state.suppressEdits=!1}return Je})}function td(ie,ae,de){var ce=ie.getOption("configureMouse"),ge=ce?ce(ie,ae,de):{};if(ge.unit==null){var Me=le?de.shiftKey&&de.metaKey:de.altKey;ge.unit=Me?"rectangle":ae=="single"?"char":ae=="double"?"word":"line"}return(ge.extend==null||ie.doc.extend)&&(ge.extend=ie.doc.extend||de.shiftKey),ge.addNew==null&&(ge.addNew=he?de.metaKey:de.ctrlKey),ge.moveOnDrag==null&&(ge.moveOnDrag=!(he?de.altKey:de.ctrlKey)),ge}function Hd(ie,ae,de,ce){kt?setTimeout(zn(ss,ie),0):ie.curOp.focus=cn();var ge=td(ie,de,ce),Me=ie.doc.sel,He;ie.options.dragDrop&&Ra&&!ie.isReadOnly()&&de=="single"&&(He=Me.contains(ae))>-1&&(Xi((He=Me.ranges[He]).from(),ae)<0||ae.xRel>0)&&(Xi(He.to(),ae)>0||ae.xRel<0)?ep(ie,ce,ae,ge):t0(ie,ce,ae,ge)}function ep(ie,ae,de,ce){var ge=ie.display,Me=!1,He=Yr(ie,function(lt){$e&&(ge.scroller.draggable=!1),ie.state.draggingText=!1,fr(ge.wrapper.ownerDocument,"mouseup",He),fr(ge.wrapper.ownerDocument,"mousemove",Je),fr(ge.scroller,"dragstart",_e),fr(ge.scroller,"drop",He),Me||(co(lt),ce.addNew||Vr(ie.doc,de,null,null,ce.extend),$e&&!Qt||kt&&Ie==9?setTimeout(function(){ge.wrapper.ownerDocument.body.focus({preventScroll:!0}),ge.input.focus()},20):ge.input.focus())}),Je=function(lt){Me=Me||Math.abs(ae.clientX-lt.clientX)+Math.abs(ae.clientY-lt.clientY)>=10},_e=function(){return Me=!0};$e&&(ge.scroller.draggable=!0),ie.state.draggingText=He,He.copy=!ce.moveOnDrag,ge.scroller.dragDrop&&ge.scroller.dragDrop(),oi(ge.wrapper.ownerDocument,"mouseup",He),oi(ge.wrapper.ownerDocument,"mousemove",Je),oi(ge.scroller,"dragstart",_e),oi(ge.scroller,"drop",He),ws(ie),setTimeout(function(){return ge.input.focus()},20)}function tp(ie,ae,de){if(de=="char")return new Mn(ae,ae);if(de=="word")return ie.findWordAt(ae);if(de=="line")return new Mn(kn(ae.line,0),cr(ie.doc,kn(ae.line+1,0)));var ce=de(ie,ae);return new Mn(ce.from,ce.to)}function t0(ie,ae,de,ce){var ge=ie.display,Me=ie.doc;co(ae);var He,Je,_e=Me.sel,lt=_e.ranges;if(ce.addNew&&!ce.extend?(Je=Me.sel.contains(de),Je>-1?He=lt[Je]:He=new Mn(de,de)):(He=Me.sel.primary(),Je=Me.sel.primIndex),ce.unit=="rectangle")ce.addNew||(He=new Mn(de,de)),de=Bl(ie,ae,!0,!0),Je=-1;else{var _t=tp(ie,de,ce.unit);ce.extend?He=ur(He,_t.anchor,_t.head,ce.extend):He=_t}ce.addNew?Je==-1?(Je=lt.length,Fi(Me,Kn(ie,lt.concat([He]),Je),{scroll:!1,origin:"*mouse"})):lt.length>1&&lt[Je].empty()&&ce.unit=="char"&&!ce.extend?(Fi(Me,Kn(ie,lt.slice(0,Je).concat(lt.slice(Je+1)),0),{scroll:!1,origin:"*mouse"}),_e=Me.sel):Nr(Me,Je,He,xn):(Je=0,Fi(Me,new In([He],0),xn),_e=Me.sel);var mt=de;function Cn(Gr){if(Xi(mt,Gr)!=0)if(mt=Gr,ce.unit=="rectangle"){for(var wo=[],ua=ie.options.tabSize,Hr=nt(wn(Me,de.line).text,de.ch,ua),_a=nt(wn(Me,Gr.line).text,Gr.ch,ua),fl=Math.min(Hr,_a),uu=Math.max(Hr,_a),Cl=Math.min(de.line,Gr.line),gh=Math.min(ie.lastLine(),Math.max(de.line,Gr.line));Cl<=gh;Cl++){var Wu=wn(Me,Cl).text,ql=Xn(Wu,fl,ua);fl==uu?wo.push(new Mn(kn(Cl,ql),kn(Cl,ql))):Wu.length>ql&&wo.push(new Mn(kn(Cl,ql),kn(Cl,Xn(Wu,uu,ua))))}wo.length||wo.push(new Mn(de,de)),Fi(Me,Kn(ie,_e.ranges.slice(0,Je).concat(wo),Je),{origin:"*mouse",scroll:!1}),ie.scrollIntoView(Gr)}else{var Ah=He,Bu=tp(ie,Gr,ce.unit),$l=Ah.anchor,ks;Xi(Bu.anchor,$l)>0?(ks=Bu.head,$l=qi(Ah.from(),Bu.anchor)):(ks=Bu.anchor,$l=$o(Ah.to(),Bu.head));var kl=_e.ranges.slice(0);kl[Je]=am(ie,new Mn(cr(Me,$l),ks)),Fi(Me,Kn(ie,kl,Je),xn)}}var mn=ge.wrapper.getBoundingClientRect(),xi=0;function Mi(Gr){var wo=++xi,ua=Bl(ie,Gr,!0,ce.unit=="rectangle");if(ua)if(Xi(ua,mt)!=0){ie.curOp.focus=cn(),Cn(ua);var Hr=sa(ge,Me);(ua.line>=Hr.to||ua.line<Hr.from)&&setTimeout(Yr(ie,function(){xi==wo&&Mi(Gr)}),150)}else{var _a=Gr.clientY<mn.top?-20:Gr.clientY>mn.bottom?20:0;_a&&setTimeout(Yr(ie,function(){xi==wo&&(ge.scroller.scrollTop+=_a,Mi(Gr))}),50)}}function Yi(Gr){ie.state.selectingText=!1,xi=1/0,Gr&&(co(Gr),ge.input.focus()),fr(ge.wrapper.ownerDocument,"mousemove",Cr),fr(ge.wrapper.ownerDocument,"mouseup",ao),Me.history.lastSelOrigin=null}var Cr=Yr(ie,function(Gr){Gr.buttons===0||!Ka(Gr)?Yi(Gr):Mi(Gr)}),ao=Yr(ie,Yi);ie.state.selectingText=ao,oi(ge.wrapper.ownerDocument,"mousemove",Cr),oi(ge.wrapper.ownerDocument,"mouseup",ao)}function am(ie,ae){var de=ae.anchor,ce=ae.head,ge=wn(ie.doc,de.line);if(Xi(de,ce)==0&&de.sticky==ce.sticky)return ae;var Me=ti(ge);if(!Me)return ae;var He=Zt(Me,de.ch,de.sticky),Je=Me[He];if(Je.from!=de.ch&&Je.to!=de.ch)return ae;var _e=He+(Je.from==de.ch==(Je.level!=1)?0:1);if(_e==0||_e==Me.length)return ae;var lt;if(ce.line!=de.line)lt=(ce.line-de.line)*(ie.doc.direction=="ltr"?1:-1)>0;else{var _t=Zt(Me,ce.ch,ce.sticky),mt=_t-He||(ce.ch-de.ch)*(Je.level==1?-1:1);_t==_e-1||_t==_e?lt=mt<0:lt=mt>0}var Cn=Me[_e+(lt?-1:0)],mn=lt==(Cn.level==1),xi=mn?Cn.from:Cn.to,Mi=mn?"after":"before";return de.ch==xi&&de.sticky==Mi?ae:new Mn(new kn(de.line,xi,Mi),ce)}function lg(ie,ae,de,ce){var ge,Me;if(ae.touches)ge=ae.touches[0].clientX,Me=ae.touches[0].clientY;else try{ge=ae.clientX,Me=ae.clientY}catch(Cn){return!1}if(ge>=Math.floor(ie.display.gutters.getBoundingClientRect().right))return!1;ce&&co(ae);var He=ie.display,Je=He.lineDiv.getBoundingClientRect();if(Me>Je.bottom||!vt(ie,de))return Ui(ae);Me-=Je.top-He.viewOffset;for(var _e=0;_e<ie.display.gutterSpecs.length;++_e){var lt=He.gutters.childNodes[_e];if(lt&&lt.getBoundingClientRect().right>=ge){var _t=wi(ie.doc,Me),mt=ie.display.gutterSpecs[_e];return Ei(ie,de,ie,_t,mt.className,ae),Ui(ae)}}}function ug(ie,ae){return lg(ie,ae,"gutterClick",!0)}function hg(ie,ae){yl(ie.display,ae)||sm(ie,ae)||Di(ie,ae,"contextmenu")||Ee||ie.display.input.onContextMenu(ae)}function sm(ie,ae){return vt(ie,"gutterContextMenu")?lg(ie,ae,"gutterContextMenu",!1):!1}function cg(ie){ie.display.wrapper.className=ie.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+ie.options.theme.replace(/(^|\s)\s*/g," cm-s-"),qu(ie)}var md={toString:function(){return"CodeMirror.Init"}},np={},Bf={};function lm(ie){var ae=ie.optionHandlers;function de(ce,ge,Me,He){ie.defaults[ce]=ge,Me&&(ae[ce]=He?function(Je,_e,lt){lt!=md&&Me(Je,_e,lt)}:Me)}ie.defineOption=de,ie.Init=md,de("value","",function(ce,ge){return ce.setValue(ge)},!0),de("mode",null,function(ce,ge){ce.doc.modeOption=ge,Wn(ce)},!0),de("indentUnit",2,Wn,!0),de("indentWithTabs",!1),de("smartIndent",!0),de("tabSize",4,function(ce){Ji(ce),qu(ce),xs(ce)},!0),de("lineSeparator",null,function(ce,ge){if(ce.doc.lineSep=ge,!!ge){var Me=[],He=ce.doc.first;ce.doc.iter(function(_e){for(var lt=0;;){var _t=_e.text.indexOf(ge,lt);if(_t==-1)break;lt=_t+ge.length,Me.push(kn(He,_t))}He++});for(var Je=Me.length-1;Je>=0;Je--)Bo(ce.doc,ge,Me[Je],kn(Me[Je].line,Me[Je].ch+ge.length))}}),de("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200c\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,function(ce,ge,Me){ce.state.specialChars=new RegExp(ge.source+(ge.test(" ")?"":"| "),"g"),Me!=md&&ce.refresh()}),de("specialCharPlaceholder",Ll,function(ce){return ce.refresh()},!0),de("electricChars",!0),de("inputStyle",te?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),de("spellcheck",!1,function(ce,ge){return ce.getInputField().spellcheck=ge},!0),de("autocorrect",!1,function(ce,ge){return ce.getInputField().autocorrect=ge},!0),de("autocapitalize",!1,function(ce,ge){return ce.getInputField().autocapitalize=ge},!0),de("rtlMoveVisually",!pe),de("wholeLineUpdateBefore",!0),de("theme","default",function(ce){cg(ce),Bt(ce)},!0),de("keyMap","default",function(ce,ge,Me){var He=hl(ge),Je=Me!=md&&hl(Me);Je&&Je.detach&&Je.detach(ce,He),He.attach&&He.attach(ce,Je||null)}),de("extraKeys",null),de("configureMouse",null),de("lineWrapping",!1,um,!0),de("gutters",[],function(ce,ge){ce.display.gutterSpecs=ct(ge,ce.options.lineNumbers),Bt(ce)},!0),de("fixedGutter",!0,function(ce,ge){ce.display.gutters.style.left=ge?Du(ce.display)+"px":"0",ce.refresh()},!0),de("coverGutterNextToScrollbar",!1,function(ce){return En(ce)},!0),de("scrollbarStyle","native",function(ce){Si(ce),En(ce),ce.display.scrollbars.setScrollTop(ce.doc.scrollTop),ce.display.scrollbars.setScrollLeft(ce.doc.scrollLeft)},!0),de("lineNumbers",!1,function(ce,ge){ce.display.gutterSpecs=ct(ce.options.gutters,ge),Bt(ce)},!0),de("firstLineNumber",1,Bt,!0),de("lineNumberFormatter",function(ce){return ce},Bt,!0),de("showCursorWhenSelecting",!1,Zs,!0),de("resetSelectionOnContextMenu",!0),de("lineWiseCopyCut",!0),de("pasteLinesPerSelection",!0),de("selectionsMayTouch",!1),de("readOnly",!1,function(ce,ge){ge=="nocursor"&&(vu(ce),ce.display.input.blur()),ce.display.input.readOnlyChanged(ge)}),de("screenReaderLabel",null,function(ce,ge){ge=ge===""?null:ge,ce.display.input.screenReaderLabelChanged(ge)}),de("disableInput",!1,function(ce,ge){ge||ce.display.input.reset()},!0),de("dragDrop",!0,dg),de("allowDropFileTypes",null),de("cursorBlinkRate",530),de("cursorScrollMargin",0),de("cursorHeight",1,Zs,!0),de("singleCursorHeightPerLine",!0,Zs,!0),de("workTime",100),de("workDelay",100),de("flattenSpans",!0,Ji,!0),de("addModeClass",!1,Ji,!0),de("pollInterval",100),de("undoDepth",200,function(ce,ge){return ce.doc.history.undoDepth=ge}),de("historyEventDelay",1250),de("viewportMargin",10,function(ce){return ce.refresh()},!0),de("maxHighlightLength",1e4,Ji,!0),de("moveInputWithCursor",!0,function(ce,ge){ge||ce.display.input.resetPosition()}),de("tabindex",null,function(ce,ge){return ce.display.input.getField().tabIndex=ge||""}),de("autofocus",null),de("direction","ltr",function(ce,ge){return ce.doc.setDirection(ge)},!0),de("phrases",null)}function dg(ie,ae,de){var ce=de&&de!=md;if(!ae!=!ce){var ge=ie.display.dragFunctions,Me=ae?oi:fr;Me(ie.display.scroller,"dragstart",ge.start),Me(ie.display.scroller,"dragenter",ge.enter),Me(ie.display.scroller,"dragover",ge.over),Me(ie.display.scroller,"dragleave",ge.leave),Me(ie.display.scroller,"drop",ge.drop)}}function um(ie){ie.options.lineWrapping?(Tt(ie.display.wrapper,"CodeMirror-wrap"),ie.display.sizer.style.minWidth="",ie.display.sizerWidth=null):(et(ie.display.wrapper,"CodeMirror-wrap"),Ia(ie)),to(ie),xs(ie),qu(ie),setTimeout(function(){return En(ie)},100)}function Es(ie,ae){var de=this;if(!(this instanceof Es))return new Es(ie,ae);this.options=ae=ae?Dn(ae):{},Dn(np,ae,!1);var ce=ae.value;typeof ce=="string"?ce=new nr(ce,ae.mode,null,ae.lineSeparator,ae.direction):ae.mode&&(ce.modeOption=ae.mode),this.doc=ce;var ge=new Es.inputStyles[ae.inputStyle](this),Me=this.display=new hn(ie,ce,ge,ae);Me.wrapper.CodeMirror=this,cg(this),ae.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),Si(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new ze,keySeq:null,specialChars:null},ae.autofocus&&!te&&Me.input.focus(),kt&&Ie<11&&setTimeout(function(){return de.display.input.reset(!0)},20),df(this),Aa(),gi(this),this.curOp.forceUpdate=!0,ki(this,ce),ae.autofocus&&!te||this.hasFocus()?setTimeout(function(){de.hasFocus()&&!de.state.focused&&Ta(de)},20):vu(this);for(var He in Bf)Bf.hasOwnProperty(He)&&Bf[He](this,ae[He],md);Ke(this),ae.finishInit&&ae.finishInit(this);for(var Je=0;Je<Gd.length;++Je)Gd[Je](this);ii(this),$e&&ae.lineWrapping&&getComputedStyle(Me.lineDiv).textRendering=="optimizelegibility"&&(Me.lineDiv.style.textRendering="auto")}Es.defaults=np,Es.optionHandlers=Bf;function df(ie){var ae=ie.display;oi(ae.scroller,"mousedown",Yr(ie,Ku)),kt&&Ie<11?oi(ae.scroller,"dblclick",Yr(ie,function(_e){if(!Di(ie,_e)){var lt=Bl(ie,_e);if(!(!lt||ug(ie,_e)||yl(ie.display,_e))){co(_e);var _t=ie.findWordAt(lt);Vr(ie.doc,_t.anchor,_t.head)}}})):oi(ae.scroller,"dblclick",function(_e){return Di(ie,_e)||co(_e)}),oi(ae.scroller,"contextmenu",function(_e){return hg(ie,_e)}),oi(ae.input.getField(),"contextmenu",function(_e){ae.scroller.contains(_e.target)||hg(ie,_e)});var de,ce={end:0};function ge(){ae.activeTouch&&(de=setTimeout(function(){return ae.activeTouch=null},1e3),ce=ae.activeTouch,ce.end=+new Date)}function Me(_e){if(_e.touches.length!=1)return!1;var lt=_e.touches[0];return lt.radiusX<=1&&lt.radiusY<=1}function He(_e,lt){if(lt.left==null)return!0;var _t=lt.left-_e.left,mt=lt.top-_e.top;return _t*_t+mt*mt>20*20}oi(ae.scroller,"touchstart",function(_e){if(!Di(ie,_e)&&!Me(_e)&&!ug(ie,_e)){ae.input.ensurePolled(),clearTimeout(de);var lt=+new Date;ae.activeTouch={start:lt,moved:!1,prev:lt-ce.end<=300?ce:null},_e.touches.length==1&&(ae.activeTouch.left=_e.touches[0].pageX,ae.activeTouch.top=_e.touches[0].pageY)}}),oi(ae.scroller,"touchmove",function(){ae.activeTouch&&(ae.activeTouch.moved=!0)}),oi(ae.scroller,"touchend",function(_e){var lt=ae.activeTouch;if(lt&&!yl(ae,_e)&&lt.left!=null&&!lt.moved&&new Date-lt.start<300){var _t=ie.coordsChar(ae.activeTouch,"page"),mt;!lt.prev||He(lt,lt.prev)?mt=new Mn(_t,_t):!lt.prev.prev||He(lt,lt.prev.prev)?mt=ie.findWordAt(_t):mt=new Mn(kn(_t.line,0),cr(ie.doc,kn(_t.line+1,0))),ie.setSelection(mt.anchor,mt.head),ie.focus(),co(_e)}ge()}),oi(ae.scroller,"touchcancel",ge),oi(ae.scroller,"scroll",function(){ae.scroller.clientHeight&&(ht(ie,ae.scroller.scrollTop),xt(ie,ae.scroller.scrollLeft,!0),Ei(ie,"scroll",ie))}),oi(ae.scroller,"mousewheel",function(_e){return Jn(ie,_e)}),oi(ae.scroller,"DOMMouseScroll",function(_e){return Jn(ie,_e)}),oi(ae.wrapper,"scroll",function(){return ae.wrapper.scrollTop=ae.wrapper.scrollLeft=0}),ae.dragFunctions={enter:function(_e){Di(ie,_e)||yo(_e)},over:function(_e){Di(ie,_e)||(Qo(ie,_e),yo(_e))},start:function(_e){return Rr(ie,_e)},drop:Yr(ie,Ca),leave:function(_e){Di(ie,_e)||Eo(ie)}};var Je=ae.input.getField();oi(Je,"keyup",function(_e){return cl.call(ie,_e)}),oi(Je,"keydown",Yr(ie,Ea)),oi(Je,"keypress",Yr(ie,zs)),oi(Je,"focus",function(_e){return Ta(ie,_e)}),oi(Je,"blur",function(_e){return vu(ie,_e)})}var Gd=[];Es.defineInitHook=function(ie){return Gd.push(ie)};function lu(ie,ae,de,ce){var ge=ie.doc,Me;de==null&&(de="add"),de=="smart"&&(ge.mode.indent?Me=gs(ie,ae).state:de="prev");var He=ie.options.tabSize,Je=wn(ge,ae),_e=nt(Je.text,null,He);Je.stateAfter&&(Je.stateAfter=null);var lt=Je.text.match(/^\s*/)[0],_t;if(!ce&&!/\S/.test(Je.text))_t=0,de="not";else if(de=="smart"&&(_t=ge.mode.indent(Me,Je.text.slice(lt.length),Je.text),_t==On||_t>150)){if(!ce)return;de="prev"}de=="prev"?ae>ge.first?_t=nt(wn(ge,ae-1).text,null,He):_t=0:de=="add"?_t=_e+ie.options.indentUnit:de=="subtract"?_t=_e-ie.options.indentUnit:typeof de=="number"&&(_t=_e+de),_t=Math.max(0,_t);var mt="",Cn=0;if(ie.options.indentWithTabs)for(var mn=Math.floor(_t/He);mn;--mn)Cn+=He,mt+=" ";if(Cn<_t&&(mt+=ft(_t-Cn)),mt!=lt)return Bo(ge,mt,kn(ae,0),kn(ae,lt.length),"+input"),Je.stateAfter=null,!0;for(var xi=0;xi<ge.sel.ranges.length;xi++){var Mi=ge.sel.ranges[xi];if(Mi.head.line==ae&&Mi.head.ch<lt.length){var Yi=kn(ae,lt.length);Nr(ge,xi,new Mn(Yi,Yi));break}}}var fh=null;function Kd(ie){fh=ie}function Of(ie,ae,de,ce,ge){var Me=ie.doc;ie.display.shift=!1,ce||(ce=Me.sel);var He=+new Date-200,Je=ge=="paste"||ie.state.pasteIncoming>He,_e=Fn(ae),lt=null;if(Je&&ce.ranges.length>1)if(fh&&fh.text.join(`
`)==ae){if(ce.ranges.length%fh.text.length==0){lt=[];for(var _t=0;_t<fh.text.length;_t++)lt.push(Me.splitLines(fh.text[_t]))}}else _e.length==ce.ranges.length&&ie.options.pasteLinesPerSelection&&(lt=an(_e,function(Cr){return[Cr]}));for(var mt=ie.curOp.updateInput,Cn=ce.ranges.length-1;Cn>=0;Cn--){var mn=ce.ranges[Cn],xi=mn.from(),Mi=mn.to();mn.empty()&&(de&&de>0?xi=kn(xi.line,xi.ch-de):ie.state.overwrite&&!Je?Mi=kn(Mi.line,Math.min(wn(Me,Mi.line).text.length,Mi.ch+Gt(_e).length)):Je&&fh&&fh.lineWise&&fh.text.join(`
`)==_e.join(`
`)&&(xi=Mi=kn(xi.line,0)));var Yi={from:xi,to:Mi,text:lt?lt[Cn%lt.length]:_e,origin:ge||(Je?"paste":ie.state.cutIncoming>He?"cut":"+input")};ro(ie.doc,Yi),vr(ie,"inputRead",ie,Yi)}ae&&!Je&&rp(ie,ae),kh(ie),ie.curOp.updateInput<2&&(ie.curOp.updateInput=mt),ie.curOp.typing=!0,ie.state.pasteIncoming=ie.state.cutIncoming=-1}function ip(ie,ae){var de=ie.clipboardData&&ie.clipboardData.getData("Text");if(de)return ie.preventDefault(),!ae.isReadOnly()&&!ae.options.disableInput&&er(ae,function(){return Of(ae,de,0,null,"paste")}),!0}function rp(ie,ae){if(!(!ie.options.electricChars||!ie.options.smartIndent))for(var de=ie.doc.sel,ce=de.ranges.length-1;ce>=0;ce--){var ge=de.ranges[ce];if(!(ge.head.ch>100||ce&&de.ranges[ce-1].head.line==ge.head.line)){var Me=ie.getModeAt(ge.head),He=!1;if(Me.electricChars){for(var Je=0;Je<Me.electricChars.length;Je++)if(ae.indexOf(Me.electricChars.charAt(Je))>-1){He=lu(ie,ge.head.line,"smart");break}}else Me.electricInput&&Me.electricInput.test(wn(ie.doc,ge.head.line).text.slice(0,ge.head.ch))&&(He=lu(ie,ge.head.line,"smart"));He&&vr(ie,"electricInput",ie,ge.head.line)}}}function op(ie){for(var ae=[],de=[],ce=0;ce<ie.doc.sel.ranges.length;ce++){var ge=ie.doc.sel.ranges[ce].head.line,Me={anchor:kn(ge,0),head:kn(ge+1,0)};de.push(Me),ae.push(ie.getRange(Me.anchor,Me.head))}return{text:ae,ranges:de}}function ap(ie,ae,de,ce){ie.setAttribute("autocorrect",de?"":"off"),ie.setAttribute("autocapitalize",ce?"":"off"),ie.setAttribute("spellcheck",!!ae)}function sp(){var ie=it("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none"),ae=it("div",[ie],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return $e?ie.style.width="1000px":ie.setAttribute("wrap","off"),Re&&(ie.style.border="1px solid black"),ap(ie),ae}function vd(ie){var ae=ie.optionHandlers,de=ie.helpers={};ie.prototype={constructor:ie,focus:function(){window.focus(),this.display.input.focus()},setOption:function(ce,ge){var Me=this.options,He=Me[ce];Me[ce]==ge&&ce!="mode"||(Me[ce]=ge,ae.hasOwnProperty(ce)&&Yr(this,ae[ce])(this,ge,He),Ei(this,"optionChange",this,ce))},getOption:function(ce){return this.options[ce]},getDoc:function(){return this.doc},addKeyMap:function(ce,ge){this.state.keyMaps[ge?"push":"unshift"](hl(ce))},removeKeyMap:function(ce){for(var ge=this.state.keyMaps,Me=0;Me<ge.length;++Me)if(ge[Me]==ce||ge[Me].name==ce)return ge.splice(Me,1),!0},addOverlay:No(function(ce,ge){var Me=ce.token?ce:ie.getMode(this.options,ce);if(Me.startState)throw new Error("Overlays may not be stateful.");Jt(this.state.overlays,{mode:Me,modeSpec:ce,opaque:ge&&ge.opaque,priority:ge&&ge.priority||0},function(He){return He.priority}),this.state.modeGen++,xs(this)}),removeOverlay:No(function(ce){for(var ge=this.state.overlays,Me=0;Me<ge.length;++Me){var He=ge[Me].modeSpec;if(He==ce||typeof ce=="string"&&He.name==ce){ge.splice(Me,1),this.state.modeGen++,xs(this);return}}}),indentLine:No(function(ce,ge,Me){typeof ge!="string"&&typeof ge!="number"&&(ge==null?ge=this.options.smartIndent?"smart":"prev":ge=ge?"add":"subtract"),gr(this.doc,ce)&&lu(this,ce,ge,Me)}),indentSelection:No(function(ce){for(var ge=this.doc.sel.ranges,Me=-1,He=0;He<ge.length;He++){var Je=ge[He];if(Je.empty())Je.head.line>Me&&(lu(this,Je.head.line,ce,!0),Me=Je.head.line,He==this.doc.sel.primIndex&&kh(this));else{var _e=Je.from(),lt=Je.to(),_t=Math.max(Me,_e.line);Me=Math.min(this.lastLine(),lt.line-(lt.ch?0:1))+1;for(var mt=_t;mt<Me;++mt)lu(this,mt,ce);var Cn=this.doc.sel.ranges;_e.ch==0&&ge.length==Cn.length&&Cn[He].from().ch>0&&Nr(this.doc,He,new Mn(_e,Cn[He].to()),Lt)}}}),getTokenAt:function(ce,ge){return Wa(this,ce,ge)},getLineTokens:function(ce,ge){return Wa(this,kn(ce),ge,!0)},getTokenTypeAt:function(ce){ce=cr(this.doc,ce);var ge=Fs(this,wn(this.doc,ce.line)),Me=0,He=(ge.length-1)/2,Je=ce.ch,_e;if(Je==0)_e=ge[2];else for(;;){var lt=Me+He>>1;if((lt?ge[lt*2-1]:0)>=Je)He=lt;else if(ge[lt*2+1]<Je)Me=lt+1;else{_e=ge[lt*2+2];break}}var _t=_e?_e.indexOf("overlay "):-1;return _t<0?_e:_t==0?null:_e.slice(0,_t-1)},getModeAt:function(ce){var ge=this.doc.mode;return ge.innerMode?ie.innerMode(ge,this.getTokenAt(ce).state).mode:ge},getHelper:function(ce,ge){return this.getHelpers(ce,ge)[0]},getHelpers:function(ce,ge){var Me=[];if(!de.hasOwnProperty(ge))return Me;var He=de[ge],Je=this.getModeAt(ce);if(typeof Je[ge]=="string")He[Je[ge]]&&Me.push(He[Je[ge]]);else if(Je[ge])for(var _e=0;_e<Je[ge].length;_e++){var lt=He[Je[ge][_e]];lt&&Me.push(lt)}else Je.helperType&&He[Je.helperType]?Me.push(He[Je.helperType]):He[Je.name]&&Me.push(He[Je.name]);for(var _t=0;_t<He._global.length;_t++){var mt=He._global[_t];mt.pred(Je,this)&&ke(Me,mt.val)==-1&&Me.push(mt.val)}return Me},getStateAfter:function(ce,ge){var Me=this.doc;return ce=Zi(Me,ce==null?Me.first+Me.size-1:ce),gs(this,ce+1,ge).state},cursorCoords:function(ce,ge){var Me,He=this.doc.sel.primary();return ce==null?Me=He.head:typeof ce=="object"?Me=cr(this.doc,ce):Me=ce?He.from():He.to(),Ss(this,Me,ge||"page")},charCoords:function(ce,ge){return al(this,cr(this.doc,ce),ge||"page")},coordsChar:function(ce,ge){return ce=hh(this,ce,ge||"page"),Au(this,ce.left,ce.top)},lineAtHeight:function(ce,ge){return ce=hh(this,{top:ce,left:0},ge||"page").top,wi(this.doc,ce+this.display.viewOffset)},heightAtLine:function(ce,ge,Me){var He=!1,Je;if(typeof ce=="number"){var _e=this.doc.first+this.doc.size-1;ce<this.doc.first?ce=this.doc.first:ce>_e&&(ce=_e,He=!0),Je=wn(this.doc,ce)}else Je=ce;return Us(this,Je,{top:0,left:0},ge||"page",Me||He).top+(He?this.doc.height-Ao(Je):0)},defaultTextHeight:function(){return Nu(this.display)},defaultCharWidth:function(){return Tu(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(ce,ge,Me,He,Je){var _e=this.display;ce=Ss(this,cr(this.doc,ce));var lt=ce.bottom,_t=ce.left;if(ge.style.position="absolute",ge.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(ge),_e.sizer.appendChild(ge),He=="over")lt=ce.top;else if(He=="above"||He=="near"){var mt=Math.max(_e.wrapper.clientHeight,this.doc.height),Cn=Math.max(_e.sizer.clientWidth,_e.lineSpace.clientWidth);(He=="above"||ce.bottom+ge.offsetHeight>mt)&&ce.top>ge.offsetHeight?lt=ce.top-ge.offsetHeight:ce.bottom+ge.offsetHeight<=mt&&(lt=ce.bottom),_t+ge.offsetWidth>Cn&&(_t=Cn-ge.offsetWidth)}ge.style.top=lt+"px",ge.style.left=ge.style.right="",Je=="right"?(_t=_e.sizer.clientWidth-ge.offsetWidth,ge.style.right="0px"):(Je=="left"?_t=0:Je=="middle"&&(_t=(_e.sizer.clientWidth-ge.offsetWidth)/2),ge.style.left=_t+"px"),Me&&bc(this,{left:_t,top:lt,right:_t+ge.offsetWidth,bottom:lt+ge.offsetHeight})},triggerOnKeyDown:No(Ea),triggerOnKeyPress:No(zs),triggerOnKeyUp:cl,triggerOnMouseDown:No(Ku),execCommand:function(ce){if(Vh.hasOwnProperty(ce))return Vh[ce].call(null,this)},triggerElectric:No(function(ce){rp(this,ce)}),findPosH:function(ce,ge,Me,He){var Je=1;ge<0&&(Je=-1,ge=-ge);for(var _e=cr(this.doc,ce),lt=0;lt<ge&&(_e=Rf(this.doc,_e,Je,Me,He),!_e.hitSide);++lt);return _e},moveH:No(function(ce,ge){var Me=this;this.extendSelectionsBy(function(He){return Me.display.shift||Me.doc.extend||He.empty()?Rf(Me.doc,He.head,ce,ge,Me.options.rtlMoveVisually):ce<0?He.from():He.to()},vn)}),deleteH:No(function(ce,ge){var Me=this.doc.sel,He=this.doc;Me.somethingSelected()?He.replaceSelection("",null,"+delete"):Os(this,function(Je){var _e=Rf(He,Je.head,ce,ge,!1);return ce<0?{from:_e,to:Je.head}:{from:Je.head,to:_e}})}),findPosV:function(ce,ge,Me,He){var Je=1,_e=He;ge<0&&(Je=-1,ge=-ge);for(var lt=cr(this.doc,ce),_t=0;_t<ge;++_t){var mt=Ss(this,lt,"div");if(_e==null?_e=mt.left:mt.left=_e,lt=yd(this,mt,Je,Me),lt.hitSide)break}return lt},moveV:No(function(ce,ge){var Me=this,He=this.doc,Je=[],_e=!this.display.shift&&!He.extend&&He.sel.somethingSelected();if(He.extendSelectionsBy(function(_t){if(_e)return ce<0?_t.from():_t.to();var mt=Ss(Me,_t.head,"div");_t.goalColumn!=null&&(mt.left=_t.goalColumn),Je.push(mt.left);var Cn=yd(Me,mt,ce,ge);return ge=="page"&&_t==He.sel.primary()&&fc(Me,al(Me,Cn,"div").top-mt.top),Cn},vn),Je.length)for(var lt=0;lt<He.sel.ranges.length;lt++)He.sel.ranges[lt].goalColumn=Je[lt]}),findWordAt:function(ce){var ge=this.doc,Me=wn(ge,ce.line).text,He=ce.ch,Je=ce.ch;if(Me){var _e=this.getHelper(ce,"wordChars");(ce.sticky=="before"||Je==Me.length)&&He?--He:++Je;for(var lt=Me.charAt(He),_t=Ze(lt,_e)?function(mt){return Ze(mt,_e)}:/\s/.test(lt)?function(mt){return/\s/.test(mt)}:function(mt){return!/\s/.test(mt)&&!Ze(mt)};He>0&&_t(Me.charAt(He-1));)--He;for(;Je<Me.length&&_t(Me.charAt(Je));)++Je}return new Mn(kn(ce.line,He),kn(ce.line,Je))},toggleOverwrite:function(ce){ce!=null&&ce==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?Tt(this.display.cursorDiv,"CodeMirror-overwrite"):et(this.display.cursorDiv,"CodeMirror-overwrite"),Ei(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==cn()},isReadOnly:function(){return!!(this.options.readOnly||this.doc.cantEdit)},scrollTo:No(function(ce,ge){Fh(this,ce,ge)}),getScrollInfo:function(){var ce=this.display.scroller;return{left:ce.scrollLeft,top:ce.scrollTop,height:ce.scrollHeight-Dl(this)-this.display.barHeight,width:ce.scrollWidth-Dl(this)-this.display.barWidth,clientHeight:uh(this),clientWidth:ru(this)}},scrollIntoView:No(function(ce,ge){ce==null?(ce={from:this.doc.sel.primary().head,to:null},ge==null&&(ge=this.options.cursorScrollMargin)):typeof ce=="number"?ce={from:kn(ce,0),to:null}:ce.from==null&&(ce={from:ce,to:null}),ce.to||(ce.to=ce.from),ce.margin=ge||0,ce.from.line!=null?Br(this,ce):Ue(this,ce.from,ce.to,ce.margin)}),setSize:No(function(ce,ge){var Me=this,He=function(_e){return typeof _e=="number"||/^\d+$/.test(String(_e))?_e+"px":_e};ce!=null&&(this.display.wrapper.style.width=He(ce)),ge!=null&&(this.display.wrapper.style.height=He(ge)),this.options.lineWrapping&&Gh(this);var Je=this.display.viewFrom;this.doc.iter(Je,this.display.viewTo,function(_e){if(_e.widgets){for(var lt=0;lt<_e.widgets.length;lt++)if(_e.widgets[lt].noHScroll){fi(Me,Je,"widget");break}}++Je}),this.curOp.forceUpdate=!0,Ei(this,"refresh",this)}),operation:function(ce){return er(this,ce)},startOperation:function(){return gi(this)},endOperation:function(){return ii(this)},refresh:No(function(){var ce=this.display.cachedTextHeight;xs(this),this.curOp.forceUpdate=!0,qu(this),Fh(this,this.doc.scrollLeft,this.doc.scrollTop),Se(this.display),(ce==null||Math.abs(ce-Nu(this.display))>.5||this.options.lineWrapping)&&to(this),Ei(this,"refresh",this)}),swapDoc:No(function(ce){var ge=this.doc;return ge.cm=null,this.state.selectingText&&this.state.selectingText(),ki(this,ce),qu(this),this.display.input.reset(),Fh(this,ce.scrollLeft,ce.scrollTop),this.curOp.forceScroll=!0,vr(this,"swapDoc",this,ge),ge}),phrase:function(ce){var ge=this.options.phrases;return ge&&Object.prototype.hasOwnProperty.call(ge,ce)?ge[ce]:ce},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},ei(ie),ie.registerHelper=function(ce,ge,Me){de.hasOwnProperty(ce)||(de[ce]=ie[ce]={_global:[]}),de[ce][ge]=Me},ie.registerGlobalHelper=function(ce,ge,Me,He){ie.registerHelper(ce,ge,He),de[ce]._global.push({pred:Me,val:He})}}function Rf(ie,ae,de,ce,ge){var Me=ae,He=de,Je=wn(ie,ae.line),_e=ge&&ie.direction=="rtl"?-de:de;function lt(){var ao=ae.line+_e;return ao<ie.first||ao>=ie.first+ie.size?!1:(ae=new kn(ao,ae.ch,ae.sticky),Je=wn(ie,ao))}function _t(ao){var Gr;if(ce=="codepoint"){var wo=Je.text.charCodeAt(ae.ch+(ce>0?0:-1));isNaN(wo)?Gr=null:Gr=new kn(ae.line,Math.max(0,Math.min(Je.text.length,ae.ch+de*(wo>=55296&&wo<56320?2:1))),-de)}else ge?Gr=eh(ie.cm,Je,ae,de):Gr=Ps(Je,ae,de);if(Gr==null)if(!ao&&lt())ae=Ol(ge,ie.cm,Je,ae.line,_e);else return!1;else ae=Gr;return!0}if(ce=="char"||ce=="codepoint")_t();else if(ce=="column")_t(!0);else if(ce=="word"||ce=="group")for(var mt=null,Cn=ce=="group",mn=ie.cm&&ie.cm.getHelper(ae,"wordChars"),xi=!0;!(de<0&&!_t(!xi));xi=!1){var Mi=Je.text.charAt(ae.ch)||`
`,Yi=Ze(Mi,mn)?"w":Cn&&Mi==`
`?"n":!Cn||/\s/.test(Mi)?null:"p";if(Cn&&!xi&&!Yi&&(Yi="s"),mt&&mt!=Yi){de<0&&(de=1,_t(),ae.sticky="after");break}if(Yi&&(mt=Yi),de>0&&!_t(!xi))break}var Cr=wa(ie,ae,Me,He,!0);return Lo(Me,Cr)&&(Cr.hitSide=!0),Cr}function yd(ie,ae,de,ce){var ge=ie.doc,Me=ae.left,He;if(ce=="page"){var Je=Math.min(ie.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),_e=Math.max(Je-.5*Nu(ie.display),3);He=(de>0?ae.bottom:ae.top)+de*_e}else ce=="line"&&(He=de>0?ae.bottom+3:ae.top-3);for(var lt;lt=Au(ie,Me,He),!!lt.outside;){if(de<0?He<=0:He>=ge.height){lt.hitSide=!0;break}He+=de*5}return lt}var _s=function(ie){this.cm=ie,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new ze,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};_s.prototype.init=function(ie){var ae=this,de=this,ce=de.cm,ge=de.div=ie.lineDiv;ap(ge,ce.options.spellcheck,ce.options.autocorrect,ce.options.autocapitalize);function Me(Je){for(var _e=Je.target;_e;_e=_e.parentNode){if(_e==ge)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(_e.className))break}return!1}oi(ge,"paste",function(Je){!Me(Je)||Di(ce,Je)||ip(Je,ce)||Ie<=11&&setTimeout(Yr(ce,function(){return ae.updateFromDOM()}),20)}),oi(ge,"compositionstart",function(Je){ae.composing={data:Je.data,done:!1}}),oi(ge,"compositionupdate",function(Je){ae.composing||(ae.composing={data:Je.data,done:!1})}),oi(ge,"compositionend",function(Je){ae.composing&&(Je.data!=ae.composing.data&&ae.readFromDOMSoon(),ae.composing.done=!0)}),oi(ge,"touchstart",function(){return de.forceCompositionEnd()}),oi(ge,"input",function(){ae.composing||ae.readFromDOMSoon()});function He(Je){if(!(!Me(Je)||Di(ce,Je))){if(ce.somethingSelected())Kd({lineWise:!1,text:ce.getSelections()}),Je.type=="cut"&&ce.replaceSelection("",null,"cut");else if(ce.options.lineWiseCopyCut){var _e=op(ce);Kd({lineWise:!0,text:_e.text}),Je.type=="cut"&&ce.operation(function(){ce.setSelections(_e.ranges,0,Lt),ce.replaceSelection("",null,"cut")})}else return;if(Je.clipboardData){Je.clipboardData.clearData();var lt=fh.text.join(`
`);if(Je.clipboardData.setData("Text",lt),Je.clipboardData.getData("Text")==lt){Je.preventDefault();return}}var _t=sp(),mt=_t.firstChild;ce.display.lineSpace.insertBefore(_t,ce.display.lineSpace.firstChild),mt.value=fh.text.join(`
`);var Cn=document.activeElement;di(mt),setTimeout(function(){ce.display.lineSpace.removeChild(_t),Cn.focus(),Cn==ge&&de.showPrimarySelection()},50)}}oi(ge,"copy",He),oi(ge,"cut",He)},_s.prototype.screenReaderLabelChanged=function(ie){ie?this.div.setAttribute("aria-label",ie):this.div.removeAttribute("aria-label")},_s.prototype.prepareSelection=function(){var ie=mu(this.cm,!1);return ie.focus=document.activeElement==this.div,ie},_s.prototype.showSelection=function(ie,ae){!ie||!this.cm.display.view.length||((ie.focus||ae)&&this.showPrimarySelection(),this.showMultipleSelections(ie))},_s.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},_s.prototype.showPrimarySelection=function(){var ie=this.getSelection(),ae=this.cm,de=ae.doc.sel.primary(),ce=de.from(),ge=de.to();if(ae.display.viewTo==ae.display.viewFrom||ce.line>=ae.display.viewTo||ge.line<ae.display.viewFrom){ie.removeAllRanges();return}var Me=If(ae,ie.anchorNode,ie.anchorOffset),He=If(ae,ie.focusNode,ie.focusOffset);if(!(Me&&!Me.bad&&He&&!He.bad&&Xi(qi(Me,He),ce)==0&&Xi($o(Me,He),ge)==0)){var Je=ae.display.view,_e=ce.line>=ae.display.viewFrom&&fg(ae,ce)||{node:Je[0].measure.map[2],offset:0},lt=ge.line<ae.display.viewTo&&fg(ae,ge);if(!lt){var _t=Je[Je.length-1].measure,mt=_t.maps?_t.maps[_t.maps.length-1]:_t.map;lt={node:mt[mt.length-1],offset:mt[mt.length-2]-mt[mt.length-3]}}if(!_e||!lt){ie.removeAllRanges();return}var Cn=ie.rangeCount&&ie.getRangeAt(0),mn;try{mn=St(_e.node,_e.offset,lt.offset,lt.node)}catch(xi){}mn&&(!Ne&&ae.state.focused?(ie.collapse(_e.node,_e.offset),mn.collapsed||(ie.removeAllRanges(),ie.addRange(mn))):(ie.removeAllRanges(),ie.addRange(mn)),Cn&&ie.anchorNode==null?ie.addRange(Cn):Ne&&this.startGracePeriod()),this.rememberSelection()}},_s.prototype.startGracePeriod=function(){var ie=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){ie.gracePeriod=!1,ie.selectionChanged()&&ie.cm.operation(function(){return ie.cm.curOp.selectionChanged=!0})},20)},_s.prototype.showMultipleSelections=function(ie){st(this.cm.display.cursorDiv,ie.cursors),st(this.cm.display.selectionDiv,ie.selection)},_s.prototype.rememberSelection=function(){var ie=this.getSelection();this.lastAnchorNode=ie.anchorNode,this.lastAnchorOffset=ie.anchorOffset,this.lastFocusNode=ie.focusNode,this.lastFocusOffset=ie.focusOffset},_s.prototype.selectionInEditor=function(){var ie=this.getSelection();if(!ie.rangeCount)return!1;var ae=ie.getRangeAt(0).commonAncestorContainer;return Ft(this.div,ae)},_s.prototype.focus=function(){this.cm.options.readOnly!="nocursor"&&((!this.selectionInEditor()||document.activeElement!=this.div)&&this.showSelection(this.prepareSelection(),!0),this.div.focus())},_s.prototype.blur=function(){this.div.blur()},_s.prototype.getField=function(){return this.div},_s.prototype.supportsTouch=function(){return!0},_s.prototype.receivedFocus=function(){var ie=this;this.selectionInEditor()?this.pollSelection():er(this.cm,function(){return ie.cm.curOp.selectionChanged=!0});function ae(){ie.cm.state.focused&&(ie.pollSelection(),ie.polling.set(ie.cm.options.pollInterval,ae))}this.polling.set(this.cm.options.pollInterval,ae)},_s.prototype.selectionChanged=function(){var ie=this.getSelection();return ie.anchorNode!=this.lastAnchorNode||ie.anchorOffset!=this.lastAnchorOffset||ie.focusNode!=this.lastFocusNode||ie.focusOffset!=this.lastFocusOffset},_s.prototype.pollSelection=function(){if(!(this.readDOMTimeout!=null||this.gracePeriod||!this.selectionChanged())){var ie=this.getSelection(),ae=this.cm;if(ne&&Pt&&this.cm.display.gutterSpecs.length&&lp(ie.anchorNode)){this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),this.focus();return}if(!this.composing){this.rememberSelection();var de=If(ae,ie.anchorNode,ie.anchorOffset),ce=If(ae,ie.focusNode,ie.focusOffset);de&&ce&&er(ae,function(){Fi(ae.doc,ni(de,ce),Lt),(de.bad||ce.bad)&&(ae.curOp.selectionChanged=!0)})}}},_s.prototype.pollContent=function(){this.readDOMTimeout!=null&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var ie=this.cm,ae=ie.display,de=ie.doc.sel.primary(),ce=de.from(),ge=de.to();if(ce.ch==0&&ce.line>ie.firstLine()&&(ce=kn(ce.line-1,wn(ie.doc,ce.line-1).length)),ge.ch==wn(ie.doc,ge.line).text.length&&ge.line<ie.lastLine()&&(ge=kn(ge.line+1,0)),ce.line<ae.viewFrom||ge.line>ae.viewTo-1)return!1;var Me,He,Je;ce.line==ae.viewFrom||(Me=Pl(ie,ce.line))==0?(He=Dt(ae.view[0].line),Je=ae.view[0].node):(He=Dt(ae.view[Me].line),Je=ae.view[Me-1].node.nextSibling);var _e=Pl(ie,ge.line),lt,_t;if(_e==ae.view.length-1?(lt=ae.viewTo-1,_t=ae.lineDiv.lastChild):(lt=Dt(ae.view[_e+1].line)-1,_t=ae.view[_e+1].node.previousSibling),!Je)return!1;for(var mt=ie.doc.splitLines(gf(ie,Je,_t,He,lt)),Cn=pi(ie.doc,kn(He,0),kn(lt,wn(ie.doc,lt).text.length));mt.length>1&&Cn.length>1;)if(Gt(mt)==Gt(Cn))mt.pop(),Cn.pop(),lt--;else if(mt[0]==Cn[0])mt.shift(),Cn.shift(),He++;else break;for(var mn=0,xi=0,Mi=mt[0],Yi=Cn[0],Cr=Math.min(Mi.length,Yi.length);mn<Cr&&Mi.charCodeAt(mn)==Yi.charCodeAt(mn);)++mn;for(var ao=Gt(mt),Gr=Gt(Cn),wo=Math.min(ao.length-(mt.length==1?mn:0),Gr.length-(Cn.length==1?mn:0));xi<wo&&ao.charCodeAt(ao.length-xi-1)==Gr.charCodeAt(Gr.length-xi-1);)++xi;if(mt.length==1&&Cn.length==1&&He==ce.line)for(;mn&&mn>ce.ch&&ao.charCodeAt(ao.length-xi-1)==Gr.charCodeAt(Gr.length-xi-1);)mn--,xi++;mt[mt.length-1]=ao.slice(0,ao.length-xi).replace(/^\u200b+/,""),mt[0]=mt[0].slice(mn).replace(/\u200b+$/,"");var ua=kn(He,mn),Hr=kn(lt,Cn.length?Gt(Cn).length-xi:0);if(mt.length>1||mt[0]||Xi(ua,Hr))return Bo(ie.doc,mt,ua,Hr,"+input"),!0},_s.prototype.ensurePolled=function(){this.forceCompositionEnd()},_s.prototype.reset=function(){this.forceCompositionEnd()},_s.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},_s.prototype.readFromDOMSoon=function(){var ie=this;this.readDOMTimeout==null&&(this.readDOMTimeout=setTimeout(function(){if(ie.readDOMTimeout=null,ie.composing)if(ie.composing.done)ie.composing=null;else return;ie.updateFromDOM()},80))},_s.prototype.updateFromDOM=function(){var ie=this;(this.cm.isReadOnly()||!this.pollContent())&&er(this.cm,function(){return xs(ie.cm)})},_s.prototype.setUneditable=function(ie){ie.contentEditable="false"},_s.prototype.onKeyPress=function(ie){ie.charCode==0||this.composing||(ie.preventDefault(),this.cm.isReadOnly()||Yr(this.cm,Of)(this.cm,String.fromCharCode(ie.charCode==null?ie.keyCode:ie.charCode),0))},_s.prototype.readOnlyChanged=function(ie){this.div.contentEditable=String(ie!="nocursor")},_s.prototype.onContextMenu=function(){},_s.prototype.resetPosition=function(){},_s.prototype.needsContentAttribute=!0;function fg(ie,ae){var de=Gl(ie,ae.line);if(!de||de.hidden)return null;var ce=wn(ie.doc,ae.line),ge=zh(de,ce,ae.line),Me=ti(ce,ie.doc.direction),He="left";if(Me){var Je=Zt(Me,ae.ch);He=Je%2?"right":"left"}var _e=tc(ge.map,ae.ch,He);return _e.offset=_e.collapse=="right"?_e.end:_e.start,_e}function lp(ie){for(var ae=ie;ae;ae=ae.parentNode)if(/CodeMirror-gutter-wrapper/.test(ae.className))return!0;return!1}function ff(ie,ae){return ae&&(ie.bad=!0),ie}function gf(ie,ae,de,ce,ge){var Me="",He=!1,Je=ie.doc.lineSeparator(),_e=!1;function lt(mn){return function(xi){return xi.id==mn}}function _t(){He&&(Me+=Je,_e&&(Me+=Je),He=_e=!1)}function mt(mn){mn&&(_t(),Me+=mn)}function Cn(mn){if(mn.nodeType==1){var xi=mn.getAttribute("cm-text");if(xi){mt(xi);return}var Mi=mn.getAttribute("cm-marker"),Yi;if(Mi){var Cr=ie.findMarks(kn(ce,0),kn(ge+1,0),lt(+Mi));Cr.length&&(Yi=Cr[0].find(0))&&mt(pi(ie.doc,Yi.from,Yi.to).join(Je));return}if(mn.getAttribute("contenteditable")=="false")return;var ao=/^(pre|div|p|li|table|br)$/i.test(mn.nodeName);if(!/^br$/i.test(mn.nodeName)&&mn.textContent.length==0)return;ao&&_t();for(var Gr=0;Gr<mn.childNodes.length;Gr++)Cn(mn.childNodes[Gr]);/^(pre|p)$/i.test(mn.nodeName)&&(_e=!0),ao&&(He=!0)}else mn.nodeType==3&&mt(mn.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "))}for(;Cn(ae),ae!=de;)ae=ae.nextSibling,_e=!1;return Me}function If(ie,ae,de){var ce;if(ae==ie.display.lineDiv){if(ce=ie.display.lineDiv.childNodes[de],!ce)return ff(ie.clipPos(kn(ie.display.viewTo-1)),!0);ae=null,de=0}else for(ce=ae;;ce=ce.parentNode){if(!ce||ce==ie.display.lineDiv)return null;if(ce.parentNode&&ce.parentNode==ie.display.lineDiv)break}for(var ge=0;ge<ie.display.view.length;ge++){var Me=ie.display.view[ge];if(Me.node==ce)return hm(Me,ae,de)}}function hm(ie,ae,de){var ce=ie.text.firstChild,ge=!1;if(!ae||!Ft(ce,ae))return ff(kn(Dt(ie.line),0),!0);if(ae==ce&&(ge=!0,ae=ce.childNodes[de],de=0,!ae)){var Me=ie.rest?Gt(ie.rest):ie.line;return ff(kn(Dt(Me),Me.text.length),ge)}var He=ae.nodeType==3?ae:null,Je=ae;for(!He&&ae.childNodes.length==1&&ae.firstChild.nodeType==3&&(He=ae.firstChild,de&&(de=He.nodeValue.length));Je.parentNode!=ce;)Je=Je.parentNode;var _e=ie.measure,lt=_e.maps;function _t(Yi,Cr,ao){for(var Gr=-1;Gr<(lt?lt.length:0);Gr++)for(var wo=Gr<0?_e.map:lt[Gr],ua=0;ua<wo.length;ua+=3){var Hr=wo[ua+2];if(Hr==Yi||Hr==Cr){var _a=Dt(Gr<0?ie.line:ie.rest[Gr]),fl=wo[ua]+ao;return(ao<0||Hr!=Yi)&&(fl=wo[ua+(ao?1:0)]),kn(_a,fl)}}}var mt=_t(He,Je,de);if(mt)return ff(mt,ge);for(var Cn=Je.nextSibling,mn=He?He.nodeValue.length-de:0;Cn;Cn=Cn.nextSibling){if(mt=_t(Cn,Cn.firstChild,0),mt)return ff(kn(mt.line,mt.ch-mn),ge);mn+=Cn.textContent.length}for(var xi=Je.previousSibling,Mi=de;xi;xi=xi.previousSibling){if(mt=_t(xi,xi.firstChild,-1),mt)return ff(kn(mt.line,mt.ch+Mi),ge);Mi+=xi.textContent.length}}var Ql=function(ie){this.cm=ie,this.prevInput="",this.pollingFast=!1,this.polling=new ze,this.hasSelection=!1,this.composing=null};Ql.prototype.init=function(ie){var ae=this,de=this,ce=this.cm;this.createField(ie);var ge=this.textarea;ie.wrapper.insertBefore(this.wrapper,ie.wrapper.firstChild),Re&&(ge.style.width="0px"),oi(ge,"input",function(){kt&&Ie>=9&&ae.hasSelection&&(ae.hasSelection=null),de.poll()}),oi(ge,"paste",function(He){Di(ce,He)||ip(He,ce)||(ce.state.pasteIncoming=+new Date,de.fastPoll())});function Me(He){if(!Di(ce,He)){if(ce.somethingSelected())Kd({lineWise:!1,text:ce.getSelections()});else if(ce.options.lineWiseCopyCut){var Je=op(ce);Kd({lineWise:!0,text:Je.text}),He.type=="cut"?ce.setSelections(Je.ranges,null,Lt):(de.prevInput="",ge.value=Je.text.join(`
`),di(ge))}else return;He.type=="cut"&&(ce.state.cutIncoming=+new Date)}}oi(ge,"cut",Me),oi(ge,"copy",Me),oi(ie.scroller,"paste",function(He){if(!(yl(ie,He)||Di(ce,He))){if(!ge.dispatchEvent){ce.state.pasteIncoming=+new Date,de.focus();return}var Je=new Event("paste");Je.clipboardData=He.clipboardData,ge.dispatchEvent(Je)}}),oi(ie.lineSpace,"selectstart",function(He){yl(ie,He)||co(He)}),oi(ge,"compositionstart",function(){var He=ce.getCursor("from");de.composing&&de.composing.range.clear(),de.composing={start:He,range:ce.markText(He,ce.getCursor("to"),{className:"CodeMirror-composing"})}}),oi(ge,"compositionend",function(){de.composing&&(de.poll(),de.composing.range.clear(),de.composing=null)})},Ql.prototype.createField=function(ie){this.wrapper=sp(),this.textarea=this.wrapper.firstChild},Ql.prototype.screenReaderLabelChanged=function(ie){ie?this.textarea.setAttribute("aria-label",ie):this.textarea.removeAttribute("aria-label")},Ql.prototype.prepareSelection=function(){var ie=this.cm,ae=ie.display,de=ie.doc,ce=mu(ie);if(ie.options.moveInputWithCursor){var ge=Ss(ie,de.sel.primary().head,"div"),Me=ae.wrapper.getBoundingClientRect(),He=ae.lineDiv.getBoundingClientRect();ce.teTop=Math.max(0,Math.min(ae.wrapper.clientHeight-10,ge.top+He.top-Me.top)),ce.teLeft=Math.max(0,Math.min(ae.wrapper.clientWidth-10,ge.left+He.left-Me.left))}return ce},Ql.prototype.showSelection=function(ie){var ae=this.cm,de=ae.display;st(de.cursorDiv,ie.cursors),st(de.selectionDiv,ie.selection),ie.teTop!=null&&(this.wrapper.style.top=ie.teTop+"px",this.wrapper.style.left=ie.teLeft+"px")},Ql.prototype.reset=function(ie){if(!(this.contextMenuPending||this.composing)){var ae=this.cm;if(ae.somethingSelected()){this.prevInput="";var de=ae.getSelection();this.textarea.value=de,ae.state.focused&&di(this.textarea),kt&&Ie>=9&&(this.hasSelection=de)}else ie||(this.prevInput=this.textarea.value="",kt&&Ie>=9&&(this.hasSelection=null))}},Ql.prototype.getField=function(){return this.textarea},Ql.prototype.supportsTouch=function(){return!1},Ql.prototype.focus=function(){if(this.cm.options.readOnly!="nocursor"&&(!te||cn()!=this.textarea))try{this.textarea.focus()}catch(ie){}},Ql.prototype.blur=function(){this.textarea.blur()},Ql.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Ql.prototype.receivedFocus=function(){this.slowPoll()},Ql.prototype.slowPoll=function(){var ie=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){ie.poll(),ie.cm.state.focused&&ie.slowPoll()})},Ql.prototype.fastPoll=function(){var ie=!1,ae=this;ae.pollingFast=!0;function de(){var ce=ae.poll();!ce&&!ie?(ie=!0,ae.polling.set(60,de)):(ae.pollingFast=!1,ae.slowPoll())}ae.polling.set(20,de)},Ql.prototype.poll=function(){var ie=this,ae=this.cm,de=this.textarea,ce=this.prevInput;if(this.contextMenuPending||!ae.state.focused||we(de)&&!ce&&!this.composing||ae.isReadOnly()||ae.options.disableInput||ae.state.keySeq)return!1;var ge=de.value;if(ge==ce&&!ae.somethingSelected())return!1;if(kt&&Ie>=9&&this.hasSelection===ge||he&&/[\uf700-\uf7ff]/.test(ge))return ae.display.input.reset(),!1;if(ae.doc.sel==ae.display.selForContextMenu){var Me=ge.charCodeAt(0);if(Me==8203&&!ce&&(ce="\u200B"),Me==8666)return this.reset(),this.cm.execCommand("undo")}for(var He=0,Je=Math.min(ce.length,ge.length);He<Je&&ce.charCodeAt(He)==ge.charCodeAt(He);)++He;return er(ae,function(){Of(ae,ge.slice(He),ce.length-He,null,ie.composing?"*compose":null),ge.length>1e3||ge.indexOf(`
`)>-1?de.value=ie.prevInput="":ie.prevInput=ge,ie.composing&&(ie.composing.range.clear(),ie.composing.range=ae.markText(ie.composing.start,ae.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},Ql.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Ql.prototype.onKeyPress=function(){kt&&Ie>=9&&(this.hasSelection=null),this.fastPoll()},Ql.prototype.onContextMenu=function(ie){var ae=this,de=ae.cm,ce=de.display,ge=ae.textarea;ae.contextMenuPending&&ae.contextMenuPending();var Me=Bl(de,ie),He=ce.scroller.scrollTop;if(!Me||wt)return;var Je=de.options.resetSelectionOnContextMenu;Je&&de.doc.sel.contains(Me)==-1&&Yr(de,Fi)(de.doc,ni(Me),Lt);var _e=ge.style.cssText,lt=ae.wrapper.style.cssText,_t=ae.wrapper.offsetParent.getBoundingClientRect();ae.wrapper.style.cssText="position: static",ge.style.cssText=`position: absolute; width: 30px; height: 30px;
top: `+(ie.clientY-_t.top-5)+"px; left: "+(ie.clientX-_t.left-5)+`px;
z-index: 1000; background: `+(kt?"rgba(255, 255, 255, .05)":"transparent")+`;
outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);`;var mt;$e&&(mt=window.scrollY),ce.input.focus(),$e&&window.scrollTo(null,mt),ce.input.reset(),de.somethingSelected()||(ge.value=ae.prevInput=" "),ae.contextMenuPending=mn,ce.selForContextMenu=de.doc.sel,clearTimeout(ce.detectingSelectAll);function Cn(){if(ge.selectionStart!=null){var Mi=de.somethingSelected(),Yi="\u200B"+(Mi?ge.value:"");ge.value="\u21DA",ge.value=Yi,ae.prevInput=Mi?"":"\u200B",ge.selectionStart=1,ge.selectionEnd=Yi.length,ce.selForContextMenu=de.doc.sel}}function mn(){if(ae.contextMenuPending==mn&&(ae.contextMenuPending=!1,ae.wrapper.style.cssText=lt,ge.style.cssText=_e,kt&&Ie<9&&ce.scrollbars.setScrollTop(ce.scroller.scrollTop=He),ge.selectionStart!=null)){(!kt||kt&&Ie<9)&&Cn();var Mi=0,Yi=function(){ce.selForContextMenu==de.doc.sel&&ge.selectionStart==0&&ge.selectionEnd>0&&ae.prevInput=="\u200B"?Yr(de,Xo)(de):Mi++<10?ce.detectingSelectAll=setTimeout(Yi,500):(ce.selForContextMenu=null,ce.input.reset())};ce.detectingSelectAll=setTimeout(Yi,200)}}if(kt&&Ie>=9&&Cn(),Ee){yo(ie);var xi=function(){fr(window,"mouseup",xi),setTimeout(mn,20)};oi(window,"mouseup",xi)}else setTimeout(mn,50)},Ql.prototype.readOnlyChanged=function(ie){ie||this.reset(),this.textarea.disabled=ie=="nocursor",this.textarea.readOnly=!!ie},Ql.prototype.setUneditable=function(){},Ql.prototype.needsContentAttribute=!1;function cm(ie,ae){if(ae=ae?Dn(ae):{},ae.value=ie.value,!ae.tabindex&&ie.tabIndex&&(ae.tabindex=ie.tabIndex),!ae.placeholder&&ie.placeholder&&(ae.placeholder=ie.placeholder),ae.autofocus==null){var de=cn();ae.autofocus=de==ie||ie.getAttribute("autofocus")!=null&&de==document.body}function ce(){ie.value=Je.getValue()}var ge;if(ie.form&&(oi(ie.form,"submit",ce),!ae.leaveSubmitMethodAlone)){var Me=ie.form;ge=Me.submit;try{var He=Me.submit=function(){ce(),Me.submit=ge,Me.submit(),Me.submit=He}}catch(_e){}}ae.finishInit=function(_e){_e.save=ce,_e.getTextArea=function(){return ie},_e.toTextArea=function(){_e.toTextArea=isNaN,ce(),ie.parentNode.removeChild(_e.getWrapperElement()),ie.style.display="",ie.form&&(fr(ie.form,"submit",ce),!ae.leaveSubmitMethodAlone&&typeof ie.form.submit=="function"&&(ie.form.submit=ge))}},ie.style.display="none";var Je=Es(function(_e){return ie.parentNode.insertBefore(_e,ie.nextSibling)},ae);return Je}function pf(ie){ie.off=fr,ie.on=oi,ie.wheelEventPixels=yn,ie.Doc=nr,ie.splitLines=Fn,ie.countColumn=nt,ie.findColumn=Xn,ie.isWordChar=Be,ie.Pass=On,ie.signal=Ei,ie.Line=ms,ie.changeEnd=yi,ie.scrollbarModel=Gn,ie.Pos=kn,ie.cmpPos=Xi,ie.modes=ln,ie.mimeModes=gn,ie.resolveMode=jt,ie.getMode=zt,ie.modeExtensions=Ct,ie.extendMode=Yt,ie.copyState=ci,ie.startState=ai,ie.innerMode=vi,ie.commands=Vh,ie.keyMap=Bs,ie.keyName=nl,ie.isModifierKey=hs,ie.lookupKey=Ur,ie.normalizeKeyMap=oo,ie.StringStream=Kt,ie.SharedTextMarker=zo,ie.TextMarker=bt,ie.LineWidget=Jr,ie.e_preventDefault=co,ie.e_stopPropagation=bo,ie.e_stop=yo,ie.addClass=Tt,ie.contains=Ft,ie.rmClass=et,ie.keyNames=ya}lm(Es),vd(Es);var nd="iter insert remove copy getEditor constructor".split(" ");for(var jf in nr.prototype)nr.prototype.hasOwnProperty(jf)&&ke(nd,jf)<0&&(Es.prototype[jf]=function(ie){return function(){return ie.apply(this.doc,arguments)}}(nr.prototype[jf]));return ei(nr),Es.inputStyles={textarea:Ql,contenteditable:_s},Es.defineMode=function(ie){!Es.defaults.mode&&ie!="null"&&(Es.defaults.mode=ie),Vn.apply(this,arguments)},Es.defineMIME=_i,Es.defineMode("null",function(){return{token:function(ie){return ie.skipToEnd()}}}),Es.defineMIME("text/plain","null"),Es.defineExtension=function(ie,ae){Es.prototype[ie]=ae},Es.defineDocExtension=function(ie,ae){nr.prototype[ie]=ae},Es.fromTextArea=cm,pf(Es),Es.version="5.58.2",Es})},49047:function(jn,li,De){(function(Ne){Ne(De(4631),De(29589),De(52539))})(function(Ne){"use strict";Ne.defineMode("markdown",function(dt,Ut){var $t=Ne.getMode(dt,"text/html"),kt=$t.name=="null";function Ie(nt){if(Ne.findModeByName){var ze=Ne.findModeByName(nt);ze&&(nt=ze.mime||ze.mimes[0])}var ke=Ne.getMode(dt,nt);return ke.name=="null"?null:ke}Ut.highlightFormatting===void 0&&(Ut.highlightFormatting=!1),Ut.maxBlockquoteDepth===void 0&&(Ut.maxBlockquoteDepth=0),Ut.taskLists===void 0&&(Ut.taskLists=!1),Ut.strikethrough===void 0&&(Ut.strikethrough=!1),Ut.emoji===void 0&&(Ut.emoji=!1),Ut.fencedCodeBlockHighlighting===void 0&&(Ut.fencedCodeBlockHighlighting=!0),Ut.fencedCodeBlockDefaultMode===void 0&&(Ut.fencedCodeBlockDefaultMode="text/plain"),Ut.xml===void 0&&(Ut.xml=!0),Ut.tokenTypeOverrides===void 0&&(Ut.tokenTypeOverrides={});var $e={header:"header",code:"comment",quote:"quote",list1:"variable-2",list2:"variable-3",list3:"keyword",hr:"hr",image:"image",imageAltText:"image-alt-text",imageMarker:"image-marker",formatting:"formatting",linkInline:"link",linkEmail:"link",linkText:"link",linkHref:"string",em:"em",strong:"strong",strikethrough:"strikethrough",emoji:"builtin"};for(var Mt in $e)$e.hasOwnProperty(Mt)&&Ut.tokenTypeOverrides[Mt]&&($e[Mt]=Ut.tokenTypeOverrides[Mt]);var Pt=/^([*\-_])(?:\s*\1){2,}\s*$/,wt=/^(?:[*\-+]|^[0-9]+([.)]))\s+/,Qt=/^\[(x| )\](?=\s)/i,It=Ut.allowAtxHeaderWithoutSpace?/^(#+)/:/^(#+)(?: |$)/,sn=/^ {0,3}(?:\={1,}|-{2,})\s*$/,Re=/^[^#!\[\]*_\\<>` "'(~:]+/,ne=/^(~~~+|```+)[ \t]*([\w\/+#-]*)[^\n`]*$/,te=/^\s*\[[^\]]+?\]:.*$/,he=/[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E42\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC9\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDF3C-\uDF3E]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]/,le=" ";function pe(nt,ze,ke){return ze.f=ze.inline=ke,ke(nt,ze)}function me(nt,ze,ke){return ze.f=ze.block=ke,ke(nt,ze)}function xe(nt){return!nt||!/\S/.test(nt.string)}function Ee(nt){if(nt.linkTitle=!1,nt.linkHref=!1,nt.linkText=!1,nt.em=!1,nt.strong=!1,nt.strikethrough=!1,nt.quote=0,nt.indentedCode=!1,nt.f==et){var ze=kt;if(!ze){var ke=Ne.innerMode($t,nt.htmlState);ze=ke.mode.name=="xml"&&ke.state.tagStart===null&&!ke.state.context&&ke.state.tokenize.isInText}ze&&(nt.f=Nt,nt.block=Ge,nt.htmlState=null)}return nt.trailingSpace=0,nt.trailingSpaceNewLine=!1,nt.prevLine=nt.thisLine,nt.thisLine={stream:null},null}function Ge(nt,ze){var ke=nt.column()===ze.indentation,Wt=xe(ze.prevLine.stream),On=ze.indentedCode,Lt=ze.prevLine.hr,xn=ze.list!==!1,vn=(ze.listStack[ze.listStack.length-1]||0)+3;ze.indentedCode=!1;var Xn=ze.indentation;if(ze.indentationDiff===null&&(ze.indentationDiff=ze.indentation,xn)){for(ze.list=null;Xn<ze.listStack[ze.listStack.length-1];)ze.listStack.pop(),ze.listStack.length?ze.indentation=ze.listStack[ze.listStack.length-1]:ze.list=!1;ze.list!==!1&&(ze.indentationDiff=Xn-ze.listStack[ze.listStack.length-1])}var Ot=!Wt&&!Lt&&!ze.prevLine.header&&(!xn||!On)&&!ze.prevLine.fencedCodeEnd,ft=(ze.list===!1||Lt||Wt)&&ze.indentation<=vn&&nt.match(Pt),Gt=null;if(ze.indentationDiff>=4&&(On||ze.prevLine.fencedCodeEnd||ze.prevLine.header||Wt))return nt.skipToEnd(),ze.indentedCode=!0,$e.code;if(nt.eatSpace())return null;if(ke&&ze.indentation<=vn&&(Gt=nt.match(It))&&Gt[1].length<=6)return ze.quote=0,ze.header=Gt[1].length,ze.thisLine.header=!0,Ut.highlightFormatting&&(ze.formatting="header"),ze.f=ze.inline,st(ze);if(ze.indentation<=vn&&nt.eat(">"))return ze.quote=ke?1:ze.quote+1,Ut.highlightFormatting&&(ze.formatting="quote"),nt.eatSpace(),st(ze);if(!ft&&!ze.setext&&ke&&ze.indentation<=vn&&(Gt=nt.match(wt))){var an=Gt[1]?"ol":"ul";return ze.indentation=Xn+nt.current().length,ze.list=!0,ze.quote=0,ze.listStack.push(ze.indentation),ze.em=!1,ze.strong=!1,ze.code=!1,ze.strikethrough=!1,Ut.taskLists&&nt.match(Qt,!1)&&(ze.taskList=!0),ze.f=ze.inline,Ut.highlightFormatting&&(ze.formatting=["list","list-"+an]),st(ze)}else{if(ke&&ze.indentation<=vn&&(Gt=nt.match(ne,!0)))return ze.quote=0,ze.fencedEndRE=new RegExp(Gt[1]+"+ *$"),ze.localMode=Ut.fencedCodeBlockHighlighting&&Ie(Gt[2]||Ut.fencedCodeBlockDefaultMode),ze.localMode&&(ze.localState=Ne.startState(ze.localMode)),ze.f=ze.block=ut,Ut.highlightFormatting&&(ze.formatting="code-block"),ze.code=-1,st(ze);if(ze.setext||(!Ot||!xn)&&!ze.quote&&ze.list===!1&&!ze.code&&!ft&&!te.test(nt.string)&&(Gt=nt.lookAhead(1))&&(Gt=Gt.match(sn)))return ze.setext?(ze.header=ze.setext,ze.setext=0,nt.skipToEnd(),Ut.highlightFormatting&&(ze.formatting="header")):(ze.header=Gt[0].charAt(0)=="="?1:2,ze.setext=ze.header),ze.thisLine.header=!0,ze.f=ze.inline,st(ze);if(ft)return nt.skipToEnd(),ze.hr=!0,ze.thisLine.hr=!0,$e.hr;if(nt.peek()==="[")return pe(nt,ze,hi)}return pe(nt,ze,ze.inline)}function et(nt,ze){var ke=$t.token(nt,ze.htmlState);if(!kt){var Wt=Ne.innerMode($t,ze.htmlState);(Wt.mode.name=="xml"&&Wt.state.tagStart===null&&!Wt.state.context&&Wt.state.tokenize.isInText||ze.md_inside&&nt.current().indexOf(">")>-1)&&(ze.f=Nt,ze.block=Ge,ze.htmlState=null)}return ke}function ut(nt,ze){var ke=ze.listStack[ze.listStack.length-1]||0,Wt=ze.indentation<ke,On=ke+3;if(ze.fencedEndRE&&ze.indentation<=On&&(Wt||nt.match(ze.fencedEndRE))){Ut.highlightFormatting&&(ze.formatting="code-block");var Lt;return Wt||(Lt=st(ze)),ze.localMode=ze.localState=null,ze.block=Ge,ze.f=Nt,ze.fencedEndRE=null,ze.code=0,ze.thisLine.fencedCodeEnd=!0,Wt?me(nt,ze,ze.block):Lt}else return ze.localMode?ze.localMode.token(nt,ze.localState):(nt.skipToEnd(),$e.code)}function st(nt){var ze=[];if(nt.formatting){ze.push($e.formatting),typeof nt.formatting=="string"&&(nt.formatting=[nt.formatting]);for(var ke=0;ke<nt.formatting.length;ke++)ze.push($e.formatting+"-"+nt.formatting[ke]),nt.formatting[ke]==="header"&&ze.push($e.formatting+"-"+nt.formatting[ke]+"-"+nt.header),nt.formatting[ke]==="quote"&&(!Ut.maxBlockquoteDepth||Ut.maxBlockquoteDepth>=nt.quote?ze.push($e.formatting+"-"+nt.formatting[ke]+"-"+nt.quote):ze.push("error"))}if(nt.taskOpen)return ze.push("meta"),ze.length?ze.join(" "):null;if(nt.taskClosed)return ze.push("property"),ze.length?ze.join(" "):null;if(nt.linkHref?ze.push($e.linkHref,"url"):(nt.strong&&ze.push($e.strong),nt.em&&ze.push($e.em),nt.strikethrough&&ze.push($e.strikethrough),nt.emoji&&ze.push($e.emoji),nt.linkText&&ze.push($e.linkText),nt.code&&ze.push($e.code),nt.image&&ze.push($e.image),nt.imageAltText&&ze.push($e.imageAltText,"link"),nt.imageMarker&&ze.push($e.imageMarker)),nt.header&&ze.push($e.header,$e.header+"-"+nt.header),nt.quote&&(ze.push($e.quote),!Ut.maxBlockquoteDepth||Ut.maxBlockquoteDepth>=nt.quote?ze.push($e.quote+"-"+nt.quote):ze.push($e.quote+"-"+Ut.maxBlockquoteDepth)),nt.list!==!1){var Wt=(nt.listStack.length-1)%3;Wt?Wt===1?ze.push($e.list2):ze.push($e.list3):ze.push($e.list1)}return nt.trailingSpaceNewLine?ze.push("trailing-space-new-line"):nt.trailingSpace&&ze.push("trailing-space-"+(nt.trailingSpace%2?"a":"b")),ze.length?ze.join(" "):null}function it(nt,ze){if(nt.match(Re,!0))return st(ze)}function Nt(nt,ze){var ke=ze.text(nt,ze);if(typeof ke!="undefined")return ke;if(ze.list)return ze.list=null,st(ze);if(ze.taskList){var Wt=nt.match(Qt,!0)[1]===" ";return Wt?ze.taskOpen=!0:ze.taskClosed=!0,Ut.highlightFormatting&&(ze.formatting="task"),ze.taskList=!1,st(ze)}if(ze.taskOpen=!1,ze.taskClosed=!1,ze.header&&nt.match(/^#+$/,!0))return Ut.highlightFormatting&&(ze.formatting="header"),st(ze);var On=nt.next();if(ze.linkTitle){ze.linkTitle=!1;var Lt=On;On==="("&&(Lt=")"),Lt=(Lt+"").replace(/([.?*+^\[\]\\(){}|-])/g,"\\$1");var xn="^\\s*(?:[^"+Lt+"\\\\]+|\\\\\\\\|\\\\.)"+Lt;if(nt.match(new RegExp(xn),!0))return $e.linkHref}if(On==="`"){var vn=ze.formatting;Ut.highlightFormatting&&(ze.formatting="code"),nt.eatWhile("`");var Xn=nt.current().length;if(ze.code==0&&(!ze.quote||Xn==1))return ze.code=Xn,st(ze);if(Xn==ze.code){var Ot=st(ze);return ze.code=0,Ot}else return ze.formatting=vn,st(ze)}else if(ze.code)return st(ze);if(On==="\\"&&(nt.next(),Ut.highlightFormatting)){var ft=st(ze),Gt=$e.formatting+"-escape";return ft?ft+" "+Gt:Gt}if(On==="!"&&nt.match(/\[[^\]]*\] ?(?:\(|\[)/,!1))return ze.imageMarker=!0,ze.image=!0,Ut.highlightFormatting&&(ze.formatting="image"),st(ze);if(On==="["&&ze.imageMarker&&nt.match(/[^\]]*\](\(.*?\)| ?\[.*?\])/,!1))return ze.imageMarker=!1,ze.imageAltText=!0,Ut.highlightFormatting&&(ze.formatting="image"),st(ze);if(On==="]"&&ze.imageAltText){Ut.highlightFormatting&&(ze.formatting="image");var ft=st(ze);return ze.imageAltText=!1,ze.image=!1,ze.inline=ze.f=Ft,ft}if(On==="["&&!ze.image)return ze.linkText&&nt.match(/^.*?\]/)||(ze.linkText=!0,Ut.highlightFormatting&&(ze.formatting="link")),st(ze);if(On==="]"&&ze.linkText){Ut.highlightFormatting&&(ze.formatting="link");var ft=st(ze);return ze.linkText=!1,ze.inline=ze.f=nt.match(/\(.*?\)| ?\[.*?\]/,!1)?Ft:Nt,ft}if(On==="<"&&nt.match(/^(https?|ftps?):\/\/(?:[^\\>]|\\.)+>/,!1)){ze.f=ze.inline=St,Ut.highlightFormatting&&(ze.formatting="link");var ft=st(ze);return ft?ft+=" ":ft="",ft+$e.linkInline}if(On==="<"&&nt.match(/^[^> \\]+@(?:[^\\>]|\\.)+>/,!1)){ze.f=ze.inline=St,Ut.highlightFormatting&&(ze.formatting="link");var ft=st(ze);return ft?ft+=" ":ft="",ft+$e.linkEmail}if(Ut.xml&&On==="<"&&nt.match(/^(!--|\?|!\[CDATA\[|[a-z][a-z0-9-]*(?:\s+[a-z_:.\-]+(?:\s*=\s*[^>]+)?)*\s*(?:>|$))/i,!1)){var an=nt.string.indexOf(">",nt.pos);if(an!=-1){var Jt=nt.string.substring(nt.start,an);/markdown\s*=\s*('|"){0,1}1('|"){0,1}/.test(Jt)&&(ze.md_inside=!0)}return nt.backUp(1),ze.htmlState=Ne.startState($t),me(nt,ze,et)}if(Ut.xml&&On==="<"&&nt.match(/^\/\w*?>/))return ze.md_inside=!1,"tag";if(On==="*"||On==="_"){for(var Ve=1,be=nt.pos==1?" ":nt.string.charAt(nt.pos-2);Ve<3&&nt.eat(On);)Ve++;var Pe=nt.peek()||" ",Be=!/\s/.test(Pe)&&(!he.test(Pe)||/\s/.test(be)||he.test(be)),Ze=!/\s/.test(be)&&(!he.test(be)||/\s/.test(Pe)||he.test(Pe)),Fe=null,qe=null;if(Ve%2&&(!ze.em&&Be&&(On==="*"||!Ze||he.test(be))?Fe=!0:ze.em==On&&Ze&&(On==="*"||!Be||he.test(Pe))&&(Fe=!1)),Ve>1&&(!ze.strong&&Be&&(On==="*"||!Ze||he.test(be))?qe=!0:ze.strong==On&&Ze&&(On==="*"||!Be||he.test(Pe))&&(qe=!1)),qe!=null||Fe!=null){Ut.highlightFormatting&&(ze.formatting=Fe==null?"strong":qe==null?"em":"strong em"),Fe===!0&&(ze.em=On),qe===!0&&(ze.strong=On);var Ot=st(ze);return Fe===!1&&(ze.em=!1),qe===!1&&(ze.strong=!1),Ot}}else if(On===" "&&(nt.eat("*")||nt.eat("_"))){if(nt.peek()===" ")return st(ze);nt.backUp(1)}if(Ut.strikethrough){if(On==="~"&&nt.eatWhile(On)){if(ze.strikethrough){Ut.highlightFormatting&&(ze.formatting="strikethrough");var Ot=st(ze);return ze.strikethrough=!1,Ot}else if(nt.match(/^[^\s]/,!1))return ze.strikethrough=!0,Ut.highlightFormatting&&(ze.formatting="strikethrough"),st(ze)}else if(On===" "&&nt.match(/^~~/,!0)){if(nt.peek()===" ")return st(ze);nt.backUp(2)}}if(Ut.emoji&&On===":"&&nt.match(/^(?:[a-z_\d+][a-z_\d+-]*|\-[a-z_\d+][a-z_\d+-]*):/)){ze.emoji=!0,Ut.highlightFormatting&&(ze.formatting="emoji");var dn=st(ze);return ze.emoji=!1,dn}return On===" "&&(nt.match(/^ +$/,!1)?ze.trailingSpace++:ze.trailingSpace&&(ze.trailingSpaceNewLine=!0)),st(ze)}function St(nt,ze){var ke=nt.next();if(ke===">"){ze.f=ze.inline=Nt,Ut.highlightFormatting&&(ze.formatting="link");var Wt=st(ze);return Wt?Wt+=" ":Wt="",Wt+$e.linkInline}return nt.match(/^[^>]+/,!0),$e.linkInline}function Ft(nt,ze){if(nt.eatSpace())return null;var ke=nt.next();return ke==="("||ke==="["?(ze.f=ze.inline=Tt(ke==="("?")":"]"),Ut.highlightFormatting&&(ze.formatting="link-string"),ze.linkHref=!0,st(ze)):"error"}var cn={")":/^(?:[^\\\(\)]|\\.|\((?:[^\\\(\)]|\\.)*\))*?(?=\))/,"]":/^(?:[^\\\[\]]|\\.|\[(?:[^\\\[\]]|\\.)*\])*?(?=\])/};function Tt(nt){return function(ze,ke){var Wt=ze.next();if(Wt===nt){ke.f=ke.inline=Nt,Ut.highlightFormatting&&(ke.formatting="link-string");var On=st(ke);return ke.linkHref=!1,On}return ze.match(cn[nt]),ke.linkHref=!0,st(ke)}}function hi(nt,ze){return nt.match(/^([^\]\\]|\\.)*\]:/,!1)?(ze.f=di,nt.next(),Ut.highlightFormatting&&(ze.formatting="link"),ze.linkText=!0,st(ze)):pe(nt,ze,Nt)}function di(nt,ze){if(nt.match(/^\]:/,!0)){ze.f=ze.inline=zn,Ut.highlightFormatting&&(ze.formatting="link");var ke=st(ze);return ze.linkText=!1,ke}return nt.match(/^([^\]\\]|\\.)+/,!0),$e.linkText}function zn(nt,ze){return nt.eatSpace()?null:(nt.match(/^[^\s]+/,!0),nt.peek()===void 0?ze.linkTitle=!0:nt.match(/^(?:\s+(?:"(?:[^"\\]|\\\\|\\.)+"|'(?:[^'\\]|\\\\|\\.)+'|\((?:[^)\\]|\\\\|\\.)+\)))?/,!0),ze.f=ze.inline=Nt,$e.linkHref+" url")}var Dn={startState:function(){return{f:Ge,prevLine:{stream:null},thisLine:{stream:null},block:Ge,htmlState:null,indentation:0,inline:Nt,text:it,formatting:!1,linkText:!1,linkHref:!1,linkTitle:!1,code:0,em:!1,strong:!1,header:0,setext:0,hr:!1,taskList:!1,list:!1,listStack:[],quote:0,trailingSpace:0,trailingSpaceNewLine:!1,strikethrough:!1,emoji:!1,fencedEndRE:null}},copyState:function(nt){return{f:nt.f,prevLine:nt.prevLine,thisLine:nt.thisLine,block:nt.block,htmlState:nt.htmlState&&Ne.copyState($t,nt.htmlState),indentation:nt.indentation,localMode:nt.localMode,localState:nt.localMode?Ne.copyState(nt.localMode,nt.localState):null,inline:nt.inline,text:nt.text,formatting:!1,linkText:nt.linkText,linkTitle:nt.linkTitle,linkHref:nt.linkHref,code:nt.code,em:nt.em,strong:nt.strong,strikethrough:nt.strikethrough,emoji:nt.emoji,header:nt.header,setext:nt.setext,hr:nt.hr,taskList:nt.taskList,list:nt.list,listStack:nt.listStack.slice(0),quote:nt.quote,indentedCode:nt.indentedCode,trailingSpace:nt.trailingSpace,trailingSpaceNewLine:nt.trailingSpaceNewLine,md_inside:nt.md_inside,fencedEndRE:nt.fencedEndRE}},token:function(nt,ze){if(ze.formatting=!1,nt!=ze.thisLine.stream){if(ze.header=0,ze.hr=!1,nt.match(/^\s*$/,!0))return Ee(ze),null;if(ze.prevLine=ze.thisLine,ze.thisLine={stream:nt},ze.taskList=!1,ze.trailingSpace=0,ze.trailingSpaceNewLine=!1,!ze.localState&&(ze.f=ze.block,ze.f!=et)){var ke=nt.match(/^\s*/,!0)[0].replace(/\t/g,le).length;if(ze.indentation=ke,ze.indentationDiff=null,ke>0)return null}}return ze.f(nt,ze)},innerMode:function(nt){return nt.block==et?{state:nt.htmlState,mode:$t}:nt.localState?{state:nt.localState,mode:nt.localMode}:{state:nt,mode:Dn}},indent:function(nt,ze,ke){return nt.block==et&&$t.indent?$t.indent(nt.htmlState,ze,ke):nt.localState&&nt.localMode.indent?nt.localMode.indent(nt.localState,ze,ke):Ne.Pass},blankLine:Ee,getType:st,blockCommentStart:"<!--",blockCommentEnd:"-->",closeBrackets:"()[]{}''\"\"``",fold:"markdown"};return Dn},"xml"),Ne.defineMIME("text/markdown","markdown"),Ne.defineMIME("text/x-markdown","markdown")})},52539:function(jn,li,De){(function(Ne){Ne(De(4631))})(function(Ne){"use strict";Ne.modeInfo=[{name:"APL",mime:"text/apl",mode:"apl",ext:["dyalog","apl"]},{name:"PGP",mimes:["application/pgp","application/pgp-encrypted","application/pgp-keys","application/pgp-signature"],mode:"asciiarmor",ext:["asc","pgp","sig"]},{name:"ASN.1",mime:"text/x-ttcn-asn",mode:"asn.1",ext:["asn","asn1"]},{name:"Asterisk",mime:"text/x-asterisk",mode:"asterisk",file:/^extensions\.conf$/i},{name:"Brainfuck",mime:"text/x-brainfuck",mode:"brainfuck",ext:["b","bf"]},{name:"C",mime:"text/x-csrc",mode:"clike",ext:["c","h","ino"]},{name:"C++",mime:"text/x-c++src",mode:"clike",ext:["cpp","c++","cc","cxx","hpp","h++","hh","hxx"],alias:["cpp"]},{name:"Cobol",mime:"text/x-cobol",mode:"cobol",ext:["cob","cpy"]},{name:"C#",mime:"text/x-csharp",mode:"clike",ext:["cs"],alias:["csharp","cs"]},{name:"Clojure",mime:"text/x-clojure",mode:"clojure",ext:["clj","cljc","cljx"]},{name:"ClojureScript",mime:"text/x-clojurescript",mode:"clojure",ext:["cljs"]},{name:"Closure Stylesheets (GSS)",mime:"text/x-gss",mode:"css",ext:["gss"]},{name:"CMake",mime:"text/x-cmake",mode:"cmake",ext:["cmake","cmake.in"],file:/^CMakeLists\.txt$/},{name:"CoffeeScript",mimes:["application/vnd.coffeescript","text/coffeescript","text/x-coffeescript"],mode:"coffeescript",ext:["coffee"],alias:["coffee","coffee-script"]},{name:"Common Lisp",mime:"text/x-common-lisp",mode:"commonlisp",ext:["cl","lisp","el"],alias:["lisp"]},{name:"Cypher",mime:"application/x-cypher-query",mode:"cypher",ext:["cyp","cypher"]},{name:"Cython",mime:"text/x-cython",mode:"python",ext:["pyx","pxd","pxi"]},{name:"Crystal",mime:"text/x-crystal",mode:"crystal",ext:["cr"]},{name:"CSS",mime:"text/css",mode:"css",ext:["css"]},{name:"CQL",mime:"text/x-cassandra",mode:"sql",ext:["cql"]},{name:"D",mime:"text/x-d",mode:"d",ext:["d"]},{name:"Dart",mimes:["application/dart","text/x-dart"],mode:"dart",ext:["dart"]},{name:"diff",mime:"text/x-diff",mode:"diff",ext:["diff","patch"]},{name:"Django",mime:"text/x-django",mode:"django"},{name:"Dockerfile",mime:"text/x-dockerfile",mode:"dockerfile",file:/^Dockerfile$/},{name:"DTD",mime:"application/xml-dtd",mode:"dtd",ext:["dtd"]},{name:"Dylan",mime:"text/x-dylan",mode:"dylan",ext:["dylan","dyl","intr"]},{name:"EBNF",mime:"text/x-ebnf",mode:"ebnf"},{name:"ECL",mime:"text/x-ecl",mode:"ecl",ext:["ecl"]},{name:"edn",mime:"application/edn",mode:"clojure",ext:["edn"]},{name:"Eiffel",mime:"text/x-eiffel",mode:"eiffel",ext:["e"]},{name:"Elm",mime:"text/x-elm",mode:"elm",ext:["elm"]},{name:"Embedded Javascript",mime:"application/x-ejs",mode:"htmlembedded",ext:["ejs"]},{name:"Embedded Ruby",mime:"application/x-erb",mode:"htmlembedded",ext:["erb"]},{name:"Erlang",mime:"text/x-erlang",mode:"erlang",ext:["erl"]},{name:"Esper",mime:"text/x-esper",mode:"sql"},{name:"Factor",mime:"text/x-factor",mode:"factor",ext:["factor"]},{name:"FCL",mime:"text/x-fcl",mode:"fcl"},{name:"Forth",mime:"text/x-forth",mode:"forth",ext:["forth","fth","4th"]},{name:"Fortran",mime:"text/x-fortran",mode:"fortran",ext:["f","for","f77","f90","f95"]},{name:"F#",mime:"text/x-fsharp",mode:"mllike",ext:["fs"],alias:["fsharp"]},{name:"Gas",mime:"text/x-gas",mode:"gas",ext:["s"]},{name:"Gherkin",mime:"text/x-feature",mode:"gherkin",ext:["feature"]},{name:"GitHub Flavored Markdown",mime:"text/x-gfm",mode:"gfm",file:/^(readme|contributing|history)\.md$/i},{name:"Go",mime:"text/x-go",mode:"go",ext:["go"]},{name:"Groovy",mime:"text/x-groovy",mode:"groovy",ext:["groovy","gradle"],file:/^Jenkinsfile$/},{name:"HAML",mime:"text/x-haml",mode:"haml",ext:["haml"]},{name:"Haskell",mime:"text/x-haskell",mode:"haskell",ext:["hs"]},{name:"Haskell (Literate)",mime:"text/x-literate-haskell",mode:"haskell-literate",ext:["lhs"]},{name:"Haxe",mime:"text/x-haxe",mode:"haxe",ext:["hx"]},{name:"HXML",mime:"text/x-hxml",mode:"haxe",ext:["hxml"]},{name:"ASP.NET",mime:"application/x-aspx",mode:"htmlembedded",ext:["aspx"],alias:["asp","aspx"]},{name:"HTML",mime:"text/html",mode:"htmlmixed",ext:["html","htm","handlebars","hbs"],alias:["xhtml"]},{name:"HTTP",mime:"message/http",mode:"http"},{name:"IDL",mime:"text/x-idl",mode:"idl",ext:["pro"]},{name:"Pug",mime:"text/x-pug",mode:"pug",ext:["jade","pug"],alias:["jade"]},{name:"Java",mime:"text/x-java",mode:"clike",ext:["java"]},{name:"Java Server Pages",mime:"application/x-jsp",mode:"htmlembedded",ext:["jsp"],alias:["jsp"]},{name:"JavaScript",mimes:["text/javascript","text/ecmascript","application/javascript","application/x-javascript","application/ecmascript"],mode:"javascript",ext:["js"],alias:["ecmascript","js","node"]},{name:"JSON",mimes:["application/json","application/x-json"],mode:"javascript",ext:["json","map"],alias:["json5"]},{name:"JSON-LD",mime:"application/ld+json",mode:"javascript",ext:["jsonld"],alias:["jsonld"]},{name:"JSX",mime:"text/jsx",mode:"jsx",ext:["jsx"]},{name:"Jinja2",mime:"text/jinja2",mode:"jinja2",ext:["j2","jinja","jinja2"]},{name:"Julia",mime:"text/x-julia",mode:"julia",ext:["jl"]},{name:"Kotlin",mime:"text/x-kotlin",mode:"clike",ext:["kt"]},{name:"LESS",mime:"text/x-less",mode:"css",ext:["less"]},{name:"LiveScript",mime:"text/x-livescript",mode:"livescript",ext:["ls"],alias:["ls"]},{name:"Lua",mime:"text/x-lua",mode:"lua",ext:["lua"]},{name:"Markdown",mime:"text/x-markdown",mode:"markdown",ext:["markdown","md","mkd"]},{name:"mIRC",mime:"text/mirc",mode:"mirc"},{name:"MariaDB SQL",mime:"text/x-mariadb",mode:"sql"},{name:"Mathematica",mime:"text/x-mathematica",mode:"mathematica",ext:["m","nb","wl","wls"]},{name:"Modelica",mime:"text/x-modelica",mode:"modelica",ext:["mo"]},{name:"MUMPS",mime:"text/x-mumps",mode:"mumps",ext:["mps"]},{name:"MS SQL",mime:"text/x-mssql",mode:"sql"},{name:"mbox",mime:"application/mbox",mode:"mbox",ext:["mbox"]},{name:"MySQL",mime:"text/x-mysql",mode:"sql"},{name:"Nginx",mime:"text/x-nginx-conf",mode:"nginx",file:/nginx.*\.conf$/i},{name:"NSIS",mime:"text/x-nsis",mode:"nsis",ext:["nsh","nsi"]},{name:"NTriples",mimes:["application/n-triples","application/n-quads","text/n-triples"],mode:"ntriples",ext:["nt","nq"]},{name:"Objective-C",mime:"text/x-objectivec",mode:"clike",ext:["m"],alias:["objective-c","objc"]},{name:"Objective-C++",mime:"text/x-objectivec++",mode:"clike",ext:["mm"],alias:["objective-c++","objc++"]},{name:"OCaml",mime:"text/x-ocaml",mode:"mllike",ext:["ml","mli","mll","mly"]},{name:"Octave",mime:"text/x-octave",mode:"octave",ext:["m"]},{name:"Oz",mime:"text/x-oz",mode:"oz",ext:["oz"]},{name:"Pascal",mime:"text/x-pascal",mode:"pascal",ext:["p","pas"]},{name:"PEG.js",mime:"null",mode:"pegjs",ext:["jsonld"]},{name:"Perl",mime:"text/x-perl",mode:"perl",ext:["pl","pm"]},{name:"PHP",mimes:["text/x-php","application/x-httpd-php","application/x-httpd-php-open"],mode:"php",ext:["php","php3","php4","php5","php7","phtml"]},{name:"Pig",mime:"text/x-pig",mode:"pig",ext:["pig"]},{name:"Plain Text",mime:"text/plain",mode:"null",ext:["txt","text","conf","def","list","log"]},{name:"PLSQL",mime:"text/x-plsql",mode:"sql",ext:["pls"]},{name:"PostgreSQL",mime:"text/x-pgsql",mode:"sql"},{name:"PowerShell",mime:"application/x-powershell",mode:"powershell",ext:["ps1","psd1","psm1"]},{name:"Properties files",mime:"text/x-properties",mode:"properties",ext:["properties","ini","in"],alias:["ini","properties"]},{name:"ProtoBuf",mime:"text/x-protobuf",mode:"protobuf",ext:["proto"]},{name:"Python",mime:"text/x-python",mode:"python",ext:["BUILD","bzl","py","pyw"],file:/^(BUCK|BUILD)$/},{name:"Puppet",mime:"text/x-puppet",mode:"puppet",ext:["pp"]},{name:"Q",mime:"text/x-q",mode:"q",ext:["q"]},{name:"R",mime:"text/x-rsrc",mode:"r",ext:["r","R"],alias:["rscript"]},{name:"reStructuredText",mime:"text/x-rst",mode:"rst",ext:["rst"],alias:["rst"]},{name:"RPM Changes",mime:"text/x-rpm-changes",mode:"rpm"},{name:"RPM Spec",mime:"text/x-rpm-spec",mode:"rpm",ext:["spec"]},{name:"Ruby",mime:"text/x-ruby",mode:"ruby",ext:["rb"],alias:["jruby","macruby","rake","rb","rbx"]},{name:"Rust",mime:"text/x-rustsrc",mode:"rust",ext:["rs"]},{name:"SAS",mime:"text/x-sas",mode:"sas",ext:["sas"]},{name:"Sass",mime:"text/x-sass",mode:"sass",ext:["sass"]},{name:"Scala",mime:"text/x-scala",mode:"clike",ext:["scala"]},{name:"Scheme",mime:"text/x-scheme",mode:"scheme",ext:["scm","ss"]},{name:"SCSS",mime:"text/x-scss",mode:"css",ext:["scss"]},{name:"Shell",mimes:["text/x-sh","application/x-sh"],mode:"shell",ext:["sh","ksh","bash"],alias:["bash","sh","zsh"],file:/^PKGBUILD$/},{name:"Sieve",mime:"application/sieve",mode:"sieve",ext:["siv","sieve"]},{name:"Slim",mimes:["text/x-slim","application/x-slim"],mode:"slim",ext:["slim"]},{name:"Smalltalk",mime:"text/x-stsrc",mode:"smalltalk",ext:["st"]},{name:"Smarty",mime:"text/x-smarty",mode:"smarty",ext:["tpl"]},{name:"Solr",mime:"text/x-solr",mode:"solr"},{name:"SML",mime:"text/x-sml",mode:"mllike",ext:["sml","sig","fun","smackspec"]},{name:"Soy",mime:"text/x-soy",mode:"soy",ext:["soy"],alias:["closure template"]},{name:"SPARQL",mime:"application/sparql-query",mode:"sparql",ext:["rq","sparql"],alias:["sparul"]},{name:"Spreadsheet",mime:"text/x-spreadsheet",mode:"spreadsheet",alias:["excel","formula"]},{name:"SQL",mime:"text/x-sql",mode:"sql",ext:["sql"]},{name:"SQLite",mime:"text/x-sqlite",mode:"sql"},{name:"Squirrel",mime:"text/x-squirrel",mode:"clike",ext:["nut"]},{name:"Stylus",mime:"text/x-styl",mode:"stylus",ext:["styl"]},{name:"Swift",mime:"text/x-swift",mode:"swift",ext:["swift"]},{name:"sTeX",mime:"text/x-stex",mode:"stex"},{name:"LaTeX",mime:"text/x-latex",mode:"stex",ext:["text","ltx","tex"],alias:["tex"]},{name:"SystemVerilog",mime:"text/x-systemverilog",mode:"verilog",ext:["v","sv","svh"]},{name:"Tcl",mime:"text/x-tcl",mode:"tcl",ext:["tcl"]},{name:"Textile",mime:"text/x-textile",mode:"textile",ext:["textile"]},{name:"TiddlyWiki",mime:"text/x-tiddlywiki",mode:"tiddlywiki"},{name:"Tiki wiki",mime:"text/tiki",mode:"tiki"},{name:"TOML",mime:"text/x-toml",mode:"toml",ext:["toml"]},{name:"Tornado",mime:"text/x-tornado",mode:"tornado"},{name:"troff",mime:"text/troff",mode:"troff",ext:["1","2","3","4","5","6","7","8","9"]},{name:"TTCN",mime:"text/x-ttcn",mode:"ttcn",ext:["ttcn","ttcn3","ttcnpp"]},{name:"TTCN_CFG",mime:"text/x-ttcn-cfg",mode:"ttcn-cfg",ext:["cfg"]},{name:"Turtle",mime:"text/turtle",mode:"turtle",ext:["ttl"]},{name:"TypeScript",mime:"application/typescript",mode:"javascript",ext:["ts"],alias:["ts"]},{name:"TypeScript-JSX",mime:"text/typescript-jsx",mode:"jsx",ext:["tsx"],alias:["tsx"]},{name:"Twig",mime:"text/x-twig",mode:"twig"},{name:"Web IDL",mime:"text/x-webidl",mode:"webidl",ext:["webidl"]},{name:"VB.NET",mime:"text/x-vb",mode:"vb",ext:["vb"]},{name:"VBScript",mime:"text/vbscript",mode:"vbscript",ext:["vbs"]},{name:"Velocity",mime:"text/velocity",mode:"velocity",ext:["vtl"]},{name:"Verilog",mime:"text/x-verilog",mode:"verilog",ext:["v"]},{name:"VHDL",mime:"text/x-vhdl",mode:"vhdl",ext:["vhd","vhdl"]},{name:"Vue.js Component",mimes:["script/x-vue","text/x-vue"],mode:"vue",ext:["vue"]},{name:"XML",mimes:["application/xml","text/xml"],mode:"xml",ext:["xml","xsl","xsd","svg"],alias:["rss","wsdl","xsd"]},{name:"XQuery",mime:"application/xquery",mode:"xquery",ext:["xy","xquery"]},{name:"Yacas",mime:"text/x-yacas",mode:"yacas",ext:["ys"]},{name:"YAML",mimes:["text/x-yaml","text/yaml"],mode:"yaml",ext:["yaml","yml"],alias:["yml"]},{name:"Z80",mime:"text/x-z80",mode:"z80",ext:["z80"]},{name:"mscgen",mime:"text/x-mscgen",mode:"mscgen",ext:["mscgen","mscin","msc"]},{name:"xu",mime:"text/x-xu",mode:"mscgen",ext:["xu"]},{name:"msgenny",mime:"text/x-msgenny",mode:"mscgen",ext:["msgenny"]},{name:"WebAssembly",mime:"text/webassembly",mode:"wast",ext:["wat","wast"]}];for(var dt=0;dt<Ne.modeInfo.length;dt++){var Ut=Ne.modeInfo[dt];Ut.mimes&&(Ut.mime=Ut.mimes[0])}Ne.findModeByMIME=function($t){$t=$t.toLowerCase();for(var kt=0;kt<Ne.modeInfo.length;kt++){var Ie=Ne.modeInfo[kt];if(Ie.mime==$t)return Ie;if(Ie.mimes){for(var $e=0;$e<Ie.mimes.length;$e++)if(Ie.mimes[$e]==$t)return Ie}}if(/\+xml$/.test($t))return Ne.findModeByMIME("application/xml");if(/\+json$/.test($t))return Ne.findModeByMIME("application/json")},Ne.findModeByExtension=function($t){$t=$t.toLowerCase();for(var kt=0;kt<Ne.modeInfo.length;kt++){var Ie=Ne.modeInfo[kt];if(Ie.ext){for(var $e=0;$e<Ie.ext.length;$e++)if(Ie.ext[$e]==$t)return Ie}}},Ne.findModeByFileName=function($t){for(var kt=0;kt<Ne.modeInfo.length;kt++){var Ie=Ne.modeInfo[kt];if(Ie.file&&Ie.file.test($t))return Ie}var $e=$t.lastIndexOf("."),Mt=$e>-1&&$t.substring($e+1,$t.length);if(Mt)return Ne.findModeByExtension(Mt)},Ne.findModeByName=function($t){$t=$t.toLowerCase();for(var kt=0;kt<Ne.modeInfo.length;kt++){var Ie=Ne.modeInfo[kt];if(Ie.name.toLowerCase()==$t)return Ie;if(Ie.alias){for(var $e=0;$e<Ie.alias.length;$e++)if(Ie.alias[$e].toLowerCase()==$t)return Ie}}}})},80785:function(jn,li,De){(function(Ne){Ne(De(4631))})(function(Ne){"use strict";Ne.defineMode("stex",function(dt,Ut){"use strict";function $t(Re,ne){Re.cmdState.push(ne)}function kt(Re){return Re.cmdState.length>0?Re.cmdState[Re.cmdState.length-1]:null}function Ie(Re){var ne=Re.cmdState.pop();ne&&ne.closeBracket()}function $e(Re){for(var ne=Re.cmdState,te=ne.length-1;te>=0;te--){var he=ne[te];if(he.name!="DEFAULT")return he}return{styleIdentifier:function(){return null}}}function Mt(Re,ne,te){return function(){this.name=Re,this.bracketNo=0,this.style=ne,this.styles=te,this.argument=null,this.styleIdentifier=function(){return this.styles[this.bracketNo-1]||null},this.openBracket=function(){return this.bracketNo++,"bracket"},this.closeBracket=function(){}}}var Pt={};Pt.importmodule=Mt("importmodule","tag",["string","builtin"]),Pt.documentclass=Mt("documentclass","tag",["","atom"]),Pt.usepackage=Mt("usepackage","tag",["atom"]),Pt.begin=Mt("begin","tag",["atom"]),Pt.end=Mt("end","tag",["atom"]),Pt.label=Mt("label","tag",["atom"]),Pt.ref=Mt("ref","tag",["atom"]),Pt.eqref=Mt("eqref","tag",["atom"]),Pt.cite=Mt("cite","tag",["atom"]),Pt.bibitem=Mt("bibitem","tag",["atom"]),Pt.Bibitem=Mt("Bibitem","tag",["atom"]),Pt.RBibitem=Mt("RBibitem","tag",["atom"]),Pt.DEFAULT=function(){this.name="DEFAULT",this.style="tag",this.styleIdentifier=this.openBracket=this.closeBracket=function(){}};function wt(Re,ne){Re.f=ne}function Qt(Re,ne){var te;if(Re.match(/^\\[a-zA-Z@]+/)){var he=Re.current().slice(1);return te=Pt.hasOwnProperty(he)?Pt[he]:Pt.DEFAULT,te=new te,$t(ne,te),wt(ne,sn),te.style}if(Re.match(/^\\[$&%#{}_]/)||Re.match(/^\\[,;!\/\\]/))return"tag";if(Re.match("\\["))return wt(ne,function(pe,me){return It(pe,me,"\\]")}),"keyword";if(Re.match("\\("))return wt(ne,function(pe,me){return It(pe,me,"\\)")}),"keyword";if(Re.match("$$"))return wt(ne,function(pe,me){return It(pe,me,"$$")}),"keyword";if(Re.match("$"))return wt(ne,function(pe,me){return It(pe,me,"$")}),"keyword";var le=Re.next();if(le=="%")return Re.skipToEnd(),"comment";if(le=="}"||le=="]"){if(te=kt(ne),te)te.closeBracket(le),wt(ne,sn);else return"error";return"bracket"}else return le=="{"||le=="["?(te=Pt.DEFAULT,te=new te,$t(ne,te),"bracket"):/\d/.test(le)?(Re.eatWhile(/[\w.%]/),"atom"):(Re.eatWhile(/[\w\-_]/),te=$e(ne),te.name=="begin"&&(te.argument=Re.current()),te.styleIdentifier())}function It(Re,ne,te){if(Re.eatSpace())return null;if(te&&Re.match(te))return wt(ne,Qt),"keyword";if(Re.match(/^\\[a-zA-Z@]+/))return"tag";if(Re.match(/^[a-zA-Z]+/))return"variable-2";if(Re.match(/^\\[$&%#{}_]/)||Re.match(/^\\[,;!\/]/)||Re.match(/^[\^_&]/))return"tag";if(Re.match(/^[+\-<>|=,\/@!*:;'"`~#?]/))return null;if(Re.match(/^(\d+\.\d*|\d*\.\d+|\d+)/))return"number";var he=Re.next();return he=="{"||he=="}"||he=="["||he=="]"||he=="("||he==")"?"bracket":he=="%"?(Re.skipToEnd(),"comment"):"error"}function sn(Re,ne){var te=Re.peek(),he;return te=="{"||te=="["?(he=kt(ne),he.openBracket(te),Re.eat(te),wt(ne,Qt),"bracket"):/[ \t\r]/.test(te)?(Re.eat(te),null):(wt(ne,Qt),Ie(ne),Qt(Re,ne))}return{startState:function(){var Re=Ut.inMathMode?function(ne,te){return It(ne,te)}:Qt;return{cmdState:[],f:Re}},copyState:function(Re){return{cmdState:Re.cmdState.slice(),f:Re.f}},token:function(Re,ne){return ne.f(Re,ne)},blankLine:function(Re){Re.f=Qt,Re.cmdState.length=0},lineComment:"%"}}),Ne.defineMIME("text/x-stex","stex"),Ne.defineMIME("text/x-latex","stex")})},29589:function(jn,li,De){(function(Ne){Ne(De(4631))})(function(Ne){"use strict";var dt={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},Ut={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};Ne.defineMode("xml",function($t,kt){var Ie=$t.indentUnit,$e={},Mt=kt.htmlMode?dt:Ut;for(var Pt in Mt)$e[Pt]=Mt[Pt];for(var Pt in kt)$e[Pt]=kt[Pt];var wt,Qt;function It(St,Ft){function cn(di){return Ft.tokenize=di,di(St,Ft)}var Tt=St.next();if(Tt=="<")return St.eat("!")?St.eat("[")?St.match("CDATA[")?cn(ne("atom","]]>")):null:St.match("--")?cn(ne("comment","-->")):St.match("DOCTYPE",!0,!0)?(St.eatWhile(/[\w\._\-]/),cn(te(1))):null:St.eat("?")?(St.eatWhile(/[\w\._\-]/),Ft.tokenize=ne("meta","?>"),"meta"):(wt=St.eat("/")?"closeTag":"openTag",Ft.tokenize=sn,"tag bracket");if(Tt=="&"){var hi;return St.eat("#")?St.eat("x")?hi=St.eatWhile(/[a-fA-F\d]/)&&St.eat(";"):hi=St.eatWhile(/[\d]/)&&St.eat(";"):hi=St.eatWhile(/[\w\.\-:]/)&&St.eat(";"),hi?"atom":"error"}else return St.eatWhile(/[^&<]/),null}It.isInText=!0;function sn(St,Ft){var cn=St.next();if(cn==">"||cn=="/"&&St.eat(">"))return Ft.tokenize=It,wt=cn==">"?"endTag":"selfcloseTag","tag bracket";if(cn=="=")return wt="equals",null;if(cn=="<"){Ft.tokenize=It,Ft.state=me,Ft.tagName=Ft.tagStart=null;var Tt=Ft.tokenize(St,Ft);return Tt?Tt+" tag error":"tag error"}else return/[\'\"]/.test(cn)?(Ft.tokenize=Re(cn),Ft.stringStartCol=St.column(),Ft.tokenize(St,Ft)):(St.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function Re(St){var Ft=function(cn,Tt){for(;!cn.eol();)if(cn.next()==St){Tt.tokenize=sn;break}return"string"};return Ft.isInAttribute=!0,Ft}function ne(St,Ft){return function(cn,Tt){for(;!cn.eol();){if(cn.match(Ft)){Tt.tokenize=It;break}cn.next()}return St}}function te(St){return function(Ft,cn){for(var Tt;(Tt=Ft.next())!=null;){if(Tt=="<")return cn.tokenize=te(St+1),cn.tokenize(Ft,cn);if(Tt==">")if(St==1){cn.tokenize=It;break}else return cn.tokenize=te(St-1),cn.tokenize(Ft,cn)}return"meta"}}function he(St,Ft,cn){this.prev=St.context,this.tagName=Ft,this.indent=St.indented,this.startOfLine=cn,($e.doNotIndent.hasOwnProperty(Ft)||St.context&&St.context.noIndent)&&(this.noIndent=!0)}function le(St){St.context&&(St.context=St.context.prev)}function pe(St,Ft){for(var cn;;){if(!St.context||(cn=St.context.tagName,!$e.contextGrabbers.hasOwnProperty(cn)||!$e.contextGrabbers[cn].hasOwnProperty(Ft)))return;le(St)}}function me(St,Ft,cn){return St=="openTag"?(cn.tagStart=Ft.column(),xe):St=="closeTag"?Ee:me}function xe(St,Ft,cn){return St=="word"?(cn.tagName=Ft.current(),Qt="tag",ut):$e.allowMissingTagName&&St=="endTag"?(Qt="tag bracket",ut(St,Ft,cn)):(Qt="error",xe)}function Ee(St,Ft,cn){if(St=="word"){var Tt=Ft.current();return cn.context&&cn.context.tagName!=Tt&&$e.implicitlyClosed.hasOwnProperty(cn.context.tagName)&&le(cn),cn.context&&cn.context.tagName==Tt||$e.matchClosing===!1?(Qt="tag",Ge):(Qt="tag error",et)}else return $e.allowMissingTagName&&St=="endTag"?(Qt="tag bracket",Ge(St,Ft,cn)):(Qt="error",et)}function Ge(St,Ft,cn){return St!="endTag"?(Qt="error",Ge):(le(cn),me)}function et(St,Ft,cn){return Qt="error",Ge(St,Ft,cn)}function ut(St,Ft,cn){if(St=="word")return Qt="attribute",st;if(St=="endTag"||St=="selfcloseTag"){var Tt=cn.tagName,hi=cn.tagStart;return cn.tagName=cn.tagStart=null,St=="selfcloseTag"||$e.autoSelfClosers.hasOwnProperty(Tt)?pe(cn,Tt):(pe(cn,Tt),cn.context=new he(cn,Tt,hi==cn.indented)),me}return Qt="error",ut}function st(St,Ft,cn){return St=="equals"?it:($e.allowMissing||(Qt="error"),ut(St,Ft,cn))}function it(St,Ft,cn){return St=="string"?Nt:St=="word"&&$e.allowUnquoted?(Qt="string",ut):(Qt="error",ut(St,Ft,cn))}function Nt(St,Ft,cn){return St=="string"?Nt:ut(St,Ft,cn)}return{startState:function(St){var Ft={tokenize:It,state:me,indented:St||0,tagName:null,tagStart:null,context:null};return St!=null&&(Ft.baseIndent=St),Ft},token:function(St,Ft){if(!Ft.tagName&&St.sol()&&(Ft.indented=St.indentation()),St.eatSpace())return null;wt=null;var cn=Ft.tokenize(St,Ft);return(cn||wt)&&cn!="comment"&&(Qt=null,Ft.state=Ft.state(wt||cn,St,Ft),Qt&&(cn=Qt=="error"?cn+" error":Qt)),cn},indent:function(St,Ft,cn){var Tt=St.context;if(St.tokenize.isInAttribute)return St.tagStart==St.indented?St.stringStartCol+1:St.indented+Ie;if(Tt&&Tt.noIndent)return Ne.Pass;if(St.tokenize!=sn&&St.tokenize!=It)return cn?cn.match(/^(\s*)/)[0].length:0;if(St.tagName)return $e.multilineTagIndentPastTag!==!1?St.tagStart+St.tagName.length+2:St.tagStart+Ie*($e.multilineTagIndentFactor||1);if($e.alignCDATA&&/<!\[CDATA\[/.test(Ft))return 0;var hi=Ft&&/^<(\/)?([\w_:\.-]*)/.exec(Ft);if(hi&&hi[1])for(;Tt;)if(Tt.tagName==hi[2]){Tt=Tt.prev;break}else if($e.implicitlyClosed.hasOwnProperty(Tt.tagName))Tt=Tt.prev;else break;else if(hi)for(;Tt;){var di=$e.contextGrabbers[Tt.tagName];if(di&&di.hasOwnProperty(hi[2]))Tt=Tt.prev;else break}for(;Tt&&Tt.prev&&!Tt.startOfLine;)Tt=Tt.prev;return Tt?Tt.indent+Ie:St.baseIndent||0},electricInput:/<\/[\s\w:]+>$/,blockCommentStart:"<!--",blockCommentEnd:"-->",configuration:$e.htmlMode?"html":"xml",helperType:$e.htmlMode?"html":"xml",skipAttribute:function(St){St.state==it&&(St.state=ut)},xmlCurrentTag:function(St){return St.tagName?{name:St.tagName,close:St.type=="closeTag"}:null},xmlCurrentContext:function(St){for(var Ft=[],cn=St.context;cn;cn=cn.prev)cn.tagName&&Ft.push(cn.tagName);return Ft.reverse()}}}),Ne.defineMIME("text/xml","xml"),Ne.defineMIME("application/xml","xml"),Ne.mimeModes.hasOwnProperty("text/html")||Ne.defineMIME("text/html",{name:"xml",htmlMode:!0})})},23495:function(jn,li,De){"use strict";De.d(li,{$u:function(){return Pt},BD:function(){return Ve},E9:function(){return Mt},FF:function(){return ca},FJ:function(){return me},Hn:function(){return pe},KX:function(){return Ee},NB:function(){return rn},S0:function(){return Gt},UL:function(){return wt},Vk:function(){return le},Vm:function(){return Zt},YI:function(){return an},ZA:function(){return Ut},Zt:function(){return Qt},al:function(){return Fe},bn:function(){return Ze},bx:function(){return be},g2:function(){return Jt},h1:function(){return it},hD:function(){return ei},l4:function(){return Ie},rU:function(){return Hn},s_:function(){return Pe},uz:function(){return $n},z6:function(){return It}}),jn=De.hmd(jn),function(){var we;function Qn(a){var y=0;return function(){return y<a.length?{done:!1,value:a[y++]}:{done:!0}}}function bn(a){var y=typeof Symbol!="undefined"&&Symbol.iterator&&a[Symbol.iterator];return y?y.call(a):{next:Qn(a)}}function on(a){for(var y,x=[];!(y=a.next()).done;)x.push(y.value);return x}var ln=typeof Object.create=="function"?Object.create:function(a){function y(){}return y.prototype=a,new y},gn;if(typeof Object.setPrototypeOf=="function")gn=Object.setPrototypeOf;else{var Vn;e:{var _i={a:!0},jt={};try{jt.__proto__=_i,Vn=jt.a;break e}catch(a){}Vn=!1}gn=Vn?function(a,y){if(a.__proto__=y,a.__proto__!==y)throw new TypeError(a+" is not extensible");return a}:null}var zt=gn;function Ct(a,y){if(a.prototype=ln(y.prototype),a.prototype.constructor=a,zt)zt(a,y);else for(var x in y)if(x!="prototype")if(Object.defineProperties){var E=Object.getOwnPropertyDescriptor(y,x);E&&Object.defineProperty(a,x,E)}else a[x]=y[x];a.QA=y.prototype}var Yt=typeof De.g!="undefined"&&De.g!=null?De.g:self,ci=typeof Object.assign=="function"?Object.assign:function(a,y){for(var x=1;x<arguments.length;x++){var E=arguments[x];if(E)for(var b in E)Object.prototype.hasOwnProperty.call(E,b)&&(a[b]=E[b])}return a},vi=typeof Object.defineProperties=="function"?Object.defineProperty:function(a,y,x){a!=Array.prototype&&a!=Object.prototype&&(a[y]=x.value)};function ai(a,y){if(y){var x=Yt;a=a.split(".");for(var E=0;E<a.length-1;E++){var b=a[E];b in x||(x[b]={}),x=x[b]}a=a[a.length-1],E=x[a],y=y(E),y!=E&&y!=null&&vi(x,a,{writable:!0,value:y})}}ai("Object.assign",function(a){return a||ci}),ai("Array.prototype.fill",function(a){return a||function(y,x,E){var b=this.length||0;for(0>x&&(x=Math.max(0,b+x)),(E==null||E>b)&&(E=b),E=Number(E),0>E&&(E=Math.max(0,b+E)),x=Number(x||0);x<E;x++)this[x]=y;return this}});var Kt=typeof globalThis=="object"&&globalThis||typeof De.g=="object"&&De.g.global===De.g&&De.g||typeof self=="object"&&self.self===self&&self||{};Kt.requestAnimationFrame===void 0&&(Kt.setImmediate===void 0?Kt.requestAnimationFrame=function(a){Kt.setTimeout(a,0)}:Kt.requestAnimationFrame=Kt.setImmediate);function wn(){}function pi(a,y){var x=-1;return function(){var E=this,b=arguments;x!==-1&&Kt.clearTimeout(x),x=ji(function(){x=-1,a.apply(E,b)},y)}}function ji(a,y){return Kt.setTimeout(a,y)}function Rn(a){return Kt.document.createElement(a)}function Dt(a){throw Error(a)}function wi(a,y){a="The object is frozen, so its properties cannot be set: "+a.toString(),y!==void 0&&(a+=" to value: "+y),Dt(a)}function gr(a,y,x,E){x=x===null?"*":typeof x=="string"?x:typeof x=="function"&&typeof x.className=="string"?x.className:"",E!==void 0&&(x+="."+E),Dt(x+" is not in the range "+y+": "+a)}function eo(a){Kt.console&&Kt.console.log(a)}function kn(a){return typeof a=="object"&&a!==null}function Xi(a){return Array.isArray(a)||Kt.NodeList&&a instanceof Kt.NodeList||Kt.HTMLCollection&&a instanceof Kt.HTMLCollection}function Lo(a){return Array.prototype.slice.call(a)}function La(a,y,x){Array.isArray(a)?y>=a.length?a.push(x):a.splice(y,0,x):Dt("Cannot insert an object into an HTMLCollection or NodeList: "+x+" at "+y)}function $o(a,y){Array.isArray(a)?y>=a.length?a.pop():a.splice(y,1):Dt("Cannot remove an object from an HTMLCollection or NodeList at "+y)}function qi(){var a=gs.pop();return a===void 0?[]:a}function Zi(a){a.length=0,gs.push(a)}function cr(a){if(typeof a=="function"){if(a.className)return a.className;if(a.name)return a.name;var y=a.toString();if(y=y.substring(9,y.indexOf("(")).trim(),y!=="")return a._className=y}else if(kn(a)&&a.constructor)return cr(a.constructor);return typeof a}function Co(a){var y=a;return kn(a)&&(a.text?y=a.text:a.name?y=a.name:a.key!==void 0?y=a.key:a.id!==void 0?y=a.id:a.constructor===Object&&(a.Text?y=a.Text:a.Name?y=a.Name:a.Key!==void 0?y=a.Key:a.Id!==void 0?y=a.Id:a.ID!==void 0&&(y=a.ID))),y===void 0?"undefined":y===null?"null":y.toString()}function Zo(a,y){if(a.hasOwnProperty(y))return!0;for(a=Object.getPrototypeOf(a);a&&a!==Function;){if(a.hasOwnProperty(y))return!0;var x=a.CA;if(x&&x[y])return!0;a=Object.getPrototypeOf(a)}return!1}function ri(a,y,x){Object.defineProperty(sa.prototype,a,{get:y,set:x})}function Lr(a){for(var y=[],x=0;256>x;x++)y["0123456789abcdef".charAt(x>>4)+"0123456789abcdef".charAt(x&15)]=String.fromCharCode(x);a.length%2&&(a="0"+a),x=[];for(var E=0,b=0;b<a.length;b+=2)x[E++]=y[a.substr(b,2)];for(a=x.join(""),a=a===""?"0":a,y=[],x=0;256>x;x++)y[x]=x;for(x=E=0;256>x;x++)E=(E+y[x]+119)%256,b=y[x],y[x]=y[E],y[E]=b;E=x=0;for(var z="",ee=0;ee<a.length;ee++)x=(x+1)%256,E=(E+y[x])%256,b=y[x],y[x]=y[E],y[E]=b,z+=String.fromCharCode(a.charCodeAt(ee)^y[(y[x]+y[E])%256]);return z.indexOf("GoJS 2.1 evaluation")>-1||z.indexOf("\xA9 1998-2021 Northwoods Software")>-1||z.indexOf("Not for distribution or production use")>-1||z.indexOf("gojs.net")>-1?"":z}var ml=Kt.navigator!==void 0&&0<Kt.navigator.userAgent.indexOf("Trident/7"),Fs=Kt.navigator!==void 0&&Kt.navigator.platform!==void 0&&Kt.navigator.platform.match(/(iPhone|iPod|iPad|Mac)/i)!==null,gs=[];Object.freeze([]),wn.className="Util",wn.Dx="32ab5ff3b26f42dc0ed90f21472913b5",wn.adym="gojs.net",wn.vfo="28e645fdb266",wn.className="Util";function Vt(a,y,x){jo(this),this.j=a,this.xa=y,this.o=x}Vt.prototype.toString=function(){return"EnumValue."+this.xa};function Kr(a,y){return y==null||y===""?null:a[y]}Yt.Object.defineProperties(Vt.prototype,{classType:{get:function(){return this.j}},name:{get:function(){return this.xa}},value:{get:function(){return this.o}}}),Vt.className="EnumValue";function Ko(){this.ew=[]}Ko.prototype.toString=function(){return this.ew.join("")},Ko.prototype.add=function(a){a!==""&&this.ew.push(a)},Ko.className="StringBuilder";function Er(){}Er.className="PropertyCollection";var Wa={EA:!1,JA:!1,GA:!1,IA:!1,NA:!1,LA:!1,nx:!1,FA:null,trace:function(a){Kt.console&&Kt.console.log(a)},HA:function(a,y,x,E){a.strokeStyle="red",a.fillStyle="red",a.font="8px sans-serif",a.beginPath(),a.moveTo(-10,0),a.lineTo(10,0),a.moveTo(0,-10),a.lineTo(0,10),a.stroke(),a.setTransform(1,0,0,1,0,0),a.scale(x,x),a.transform(y.m11,y.m12,y.m21,y.m22,y.dx,y.dy),a.lineWidth=2,a.beginPath(),a.moveTo(E.left,E.top+20),a.lineTo(E.left,E.top),a.lineTo(E.left+20,E.top),a.moveTo(E.right,E.bottom-20),a.lineTo(E.right,E.bottom),a.lineTo(E.right-20,E.bottom),a.stroke(),a.fillText("DB: "+Math.round(E.x)+", "+Math.round(E.y)+", "+Math.round(E.width)+", "+Math.round(E.height),E.left,E.top-5)},DA:function(a){var y={},x;for(x in a){if(y.x=x,y.x!=="licenseKey"){var E=a[y.x];if(E.prototype!==void 0){y.Zl=Object.getOwnPropertyNames(E.prototype);for(var b={Tj:0};b.Tj<y.Zl.length;b={Tj:b.Tj},b.Tj++){var z=Object.getOwnPropertyDescriptor(E.prototype,y.Zl[b.Tj]);z.get!==void 0&&z.set===void 0&&Object.defineProperty(E.prototype,y.Zl[b.Tj],{set:function(ee,re){return function(){throw Error("Property "+ee.Zl[re.Tj]+" of "+ee.x+" is read-only.")}}(y,b)})}}}y={Zl:y.Zl,x:y.x}}}};function Wo(){}Wo.prototype.reset=function(){},Wo.prototype.next=function(){return!1},Wo.prototype.Ad=function(){return!1},Wo.prototype.first=function(){return null},Wo.prototype.any=function(){return!1},Wo.prototype.all=function(){return!0},Wo.prototype.each=function(){return this},Wo.prototype.map=function(){return this},Wo.prototype.filter=function(){return this},Wo.prototype.de=function(){},Wo.prototype.toString=function(){return"EmptyIterator"},Yt.Object.defineProperties(Wo.prototype,{iterator:{get:function(){return this}},count:{get:function(){return 0}}}),Wo.prototype.first=Wo.prototype.first,Wo.prototype.hasNext=Wo.prototype.Ad,Wo.prototype.next=Wo.prototype.next,Wo.prototype.reset=Wo.prototype.reset;var ea=null;Wo.className="EmptyIterator",ea=new Wo;function fo(a){this.key=-1,this.value=a}fo.prototype.reset=function(){this.key=-1},fo.prototype.next=function(){return this.key===-1?(this.key=0,!0):!1},fo.prototype.Ad=function(){return this.next()},fo.prototype.first=function(){return this.key=0,this.value},fo.prototype.any=function(a){return this.key=-1,a(this.value)},fo.prototype.all=function(a){return this.key=-1,a(this.value)},fo.prototype.each=function(a){return this.key=-1,a(this.value),this},fo.prototype.map=function(a){return new fo(a(this.value))},fo.prototype.filter=function(a){return a(this.value)?new fo(this.value):ea},fo.prototype.de=function(){this.value=null},fo.prototype.toString=function(){return"SingletonIterator("+this.value+")"},Yt.Object.defineProperties(fo.prototype,{iterator:{get:function(){return this}},count:{get:function(){return 1}}}),fo.prototype.first=fo.prototype.first,fo.prototype.hasNext=fo.prototype.Ad,fo.prototype.next=fo.prototype.next,fo.prototype.reset=fo.prototype.reset,fo.className="SingletonIterator";function Oo(a){this.Bb=a,this.qf=null,a.Sa=null,this.qa=a.Ja,this.Za=-1}Oo.prototype.reset=function(){var a=this.Bb;a.Sa=null,this.qa=a.Ja,this.Za=-1},Oo.prototype.next=function(){var a=this.Bb;if(a.Ja!==this.qa&&0>this.key)return!1;a=a.s;var y=a.length,x=++this.Za,E=this.qf;if(E!==null)for(;x<y;){var b=a[x];if(E(b))return this.key=this.Za=x,this.value=b,!0;x++}else{if(x<y)return this.key=x,this.value=a[x],!0;this.de()}return!1},Oo.prototype.Ad=function(){return this.next()},Oo.prototype.first=function(){var a=this.Bb;this.qa=a.Ja,this.Za=0,a=a.s;var y=a.length,x=this.qf;if(x!==null){for(var E=0;E<y;){var b=a[E];if(x(b))return this.key=this.Za=E,this.value=b;E++}return null}return 0<y?(a=a[0],this.key=0,this.value=a):null},Oo.prototype.any=function(a){var y=this.Bb;y.Sa=null,this.Za=-1,y=y.s;for(var x=y.length,E=this.qf,b=0;b<x;b++){var z=y[b];if((E===null||E(z))&&a(z))return!0}return!1},Oo.prototype.all=function(a){var y=this.Bb;y.Sa=null,this.Za=-1,y=y.s;for(var x=y.length,E=this.qf,b=0;b<x;b++){var z=y[b];if((E===null||E(z))&&!a(z))return!1}return!0},Oo.prototype.each=function(a){var y=this.Bb;y.Sa=null,this.Za=-1,y=y.s;for(var x=y.length,E=this.qf,b=0;b<x;b++){var z=y[b];(E===null||E(z))&&a(z)}return this},Oo.prototype.map=function(a){var y=this.Bb;y.Sa=null,this.Za=-1;var x=[];y=y.s;for(var E=y.length,b=this.qf,z=0;z<E;z++){var ee=y[z];(b===null||b(ee))&&x.push(a(ee))}return a=new An,a.s=x,a.xb(),a.iterator},Oo.prototype.filter=function(a){var y=this.Bb;y.Sa=null,this.Za=-1;var x=[];y=y.s;for(var E=y.length,b=this.qf,z=0;z<E;z++){var ee=y[z];(b===null||b(ee))&&a(ee)&&x.push(ee)}return a=new An,a.s=x,a.xb(),a.iterator},Oo.prototype.de=function(){this.key=-1,this.value=null,this.qa=-1,this.qf=null,this.Bb.Sa=this},Oo.prototype.toString=function(){return"ListIterator@"+this.Za+"/"+this.Bb.count},Yt.Object.defineProperties(Oo.prototype,{iterator:{get:function(){return this}},predicate:{get:function(){return this.qf},set:function(a){this.qf=a}},count:{get:function(){var a=this.qf;if(a!==null){for(var y=0,x=this.Bb.s,E=x.length,b=0;b<E;b++)a(x[b])&&y++;return y}return this.Bb.s.length}}}),Oo.prototype.first=Oo.prototype.first,Oo.prototype.hasNext=Oo.prototype.Ad,Oo.prototype.next=Oo.prototype.next,Oo.prototype.reset=Oo.prototype.reset,Oo.className="ListIterator";function xa(a){this.Bb=a,a.Hg=null,this.qa=a.Ja,this.Za=a.s.length}xa.prototype.reset=function(){var a=this.Bb;a.Hg=null,this.qa=a.Ja,this.Za=a.s.length},xa.prototype.next=function(){var a=this.Bb;if(a.Ja!==this.qa&&0>this.key)return!1;var y=--this.Za;return 0<=y?(this.key=y,this.value=a.s[y],!0):(this.de(),!1)},xa.prototype.Ad=function(){return this.next()},xa.prototype.first=function(){var a=this.Bb;this.qa=a.Ja;var y=a.s;return this.Za=a=y.length-1,0<=a?(y=y[a],this.key=a,this.value=y):null},xa.prototype.any=function(a){var y=this.Bb;y.Hg=null,y=y.s;var x=y.length;for(this.Za=x,--x;0<=x;x--)if(a(y[x]))return!0;return!1},xa.prototype.all=function(a){var y=this.Bb;y.Hg=null,y=y.s;var x=y.length;for(this.Za=x,--x;0<=x;x--)if(!a(y[x]))return!1;return!0},xa.prototype.each=function(a){var y=this.Bb;y.Hg=null,y=y.s;var x=y.length;for(this.Za=x,--x;0<=x;x--)a(y[x]);return this},xa.prototype.map=function(a){var y=this.Bb;y.Hg=null;var x=[];y=y.s;var E=y.length;for(this.Za=E,--E;0<=E;E--)x.push(a(y[E]));return a=new An,a.s=x,a.xb(),a.iterator},xa.prototype.filter=function(a){var y=this.Bb;y.Hg=null;var x=[];y=y.s;var E=y.length;for(this.Za=E,--E;0<=E;E--){var b=y[E];a(b)&&x.push(b)}return a=new An,a.s=x,a.xb(),a.iterator},xa.prototype.de=function(){this.key=-1,this.value=null,this.qa=-1,this.Bb.Hg=this},xa.prototype.toString=function(){return"ListIteratorBackwards("+this.Za+"/"+this.Bb.count+")"},Yt.Object.defineProperties(xa.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.Bb.s.length}}}),xa.prototype.first=xa.prototype.first,xa.prototype.hasNext=xa.prototype.Ad,xa.prototype.next=xa.prototype.next,xa.prototype.reset=xa.prototype.reset,xa.className="ListIteratorBackwards";function An(a){jo(this),this._isFrozen=!1,this.s=[],this.Ja=0,this.Hg=this.Sa=null,typeof a=="string"&&Dt("Error: Since 2.0 List/Map/Set constructors no longer take an argument that enforces type."),a!==void 0&&this.addAll(a)}we=An.prototype,we.xb=function(){var a=this.Ja;a++,999999999<a&&(a=0),this.Ja=a},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return this._isFrozen=!1,this},we.toString=function(){return"List()#"+qa(this)},we.add=function(a){return a===null?this:(this._isFrozen&&wi(this,a),this.s.push(a),this.xb(),this)},we.push=function(a){this.add(a)},we.addAll=function(a){if(a===null)return this;this._isFrozen&&wi(this);var y=this.s;if(Xi(a))for(var x=a.length,E=0;E<x;E++)y.push(a[E]);else for(a=a.iterator;a.next();)y.push(a.value);return this.xb(),this},we.clear=function(){this._isFrozen&&wi(this),this.s.length=0,this.xb()},we.contains=function(a){return a===null?!1:this.s.indexOf(a)!==-1},we.has=function(a){return this.contains(a)},we.indexOf=function(a){return a===null?-1:this.s.indexOf(a)},we.M=function(a){var y=this.s;return(0>a||a>=y.length)&&gr(a,"0 <= i < length",An,"elt:i"),y[a]},we.get=function(a){return this.M(a)},we.cd=function(a,y){var x=this.s;(0>a||a>=x.length)&&gr(a,"0 <= i < length",An,"setElt:i"),this._isFrozen&&wi(this,a),x[a]=y},we.set=function(a,y){this.cd(a,y)},we.first=function(){var a=this.s;return a.length===0?null:a[0]},we.jc=function(){var a=this.s,y=a.length;return 0<y?a[y-1]:null},we.pop=function(){this._isFrozen&&wi(this);var a=this.s;return 0<a.length?a.pop():null},An.prototype.any=function(a){for(var y=this.s,x=y.length,E=0;E<x;E++)if(a(y[E]))return!0;return!1},An.prototype.all=function(a){for(var y=this.s,x=y.length,E=0;E<x;E++)if(!a(y[E]))return!1;return!0},An.prototype.each=function(a){for(var y=this.s,x=y.length,E=0;E<x;E++)a(y[E]);return this},An.prototype.map=function(a){for(var y=new An,x=[],E=this.s,b=E.length,z=0;z<b;z++)x.push(a(E[z]));return y.s=x,y.xb(),y},An.prototype.filter=function(a){for(var y=new An,x=[],E=this.s,b=E.length,z=0;z<b;z++){var ee=E[z];a(ee)&&x.push(ee)}return y.s=x,y.xb(),y},we=An.prototype,we.Gb=function(a,y){0>a&&gr(a,">= 0",An,"insertAt:i"),this._isFrozen&&wi(this,a);var x=this.s;a>=x.length?x.push(y):x.splice(a,0,y),this.xb()},we.remove=function(a){if(a===null)return!1;this._isFrozen&&wi(this,a);var y=this.s;return a=y.indexOf(a),a===-1?!1:(a===y.length-1?y.pop():y.splice(a,1),this.xb(),!0)},we.delete=function(a){return this.remove(a)},we.mb=function(a){var y=this.s;(0>a||a>=y.length)&&gr(a,"0 <= i < length",An,"removeAt:i"),this._isFrozen&&wi(this,a),a===y.length-1?y.pop():y.splice(a,1),this.xb()},we.removeRange=function(a,y){var x=this.s,E=x.length;if(0>a)a=0;else if(a>=E)return this;if(0>y)return this;if(y>=E&&(y=E-1),a>y)return this;this._isFrozen&&wi(this);for(var b=a,z=y+1;z<E;)x[b++]=x[z++];return x.length=E-(y-a+1),this.xb(),this},An.prototype.copy=function(){var a=new An,y=this.s;return 0<y.length&&(a.s=Array.prototype.slice.call(y)),a},we=An.prototype,we.Fa=function(){for(var a=this.s,y=this.count,x=Array(y),E=0;E<y;E++)x[E]=a[E];return x},we.Iv=function(){for(var a=new Pn,y=this.s,x=this.count,E=0;E<x;E++)a.add(y[E]);return a},we.sort=function(a){return this._isFrozen&&wi(this),this.s.sort(a),this.xb(),this},we.zi=function(a,y,x){var E=this.s,b=E.length;y===void 0&&(y=0),x===void 0&&(x=b),this._isFrozen&&wi(this);var z=x-y;if(1>=z)return this;if((0>y||y>=b-1)&&gr(y,"0 <= from < length",An,"sortRange:from"),z===2)return x=E[y],b=E[y+1],0<a(x,b)&&(E[y]=b,E[y+1]=x,this.xb()),this;if(y===0)if(x>=b)E.sort(a);else for(y=E.slice(0,x),y.sort(a),a=0;a<x;a++)E[a]=y[a];else if(x>=b)for(x=E.slice(y),x.sort(a),a=y;a<b;a++)E[a]=x[a-y];else for(b=E.slice(y,x),b.sort(a),a=y;a<x;a++)E[a]=b[a-y];return this.xb(),this},we.reverse=function(){return this._isFrozen&&wi(this),this.s.reverse(),this.xb(),this},Yt.Object.defineProperties(An.prototype,{_dataArray:{get:function(){return this.s}},count:{get:function(){return this.s.length}},size:{get:function(){return this.s.length}},length:{get:function(){return this.s.length}},iterator:{get:function(){if(0>=this.s.length)return ea;var a=this.Sa;return a!==null?(a.reset(),a):new Oo(this)}},iteratorBackwards:{get:function(){if(0>=this.s.length)return ea;var a=this.Hg;return a!==null?(a.reset(),a):new xa(this)}}}),An.prototype.reverse=An.prototype.reverse,An.prototype.sortRange=An.prototype.zi,An.prototype.sort=An.prototype.sort,An.prototype.toSet=An.prototype.Iv,An.prototype.toArray=An.prototype.Fa,An.prototype.removeRange=An.prototype.removeRange,An.prototype.removeAt=An.prototype.mb,An.prototype.delete=An.prototype.delete,An.prototype.remove=An.prototype.remove,An.prototype.insertAt=An.prototype.Gb,An.prototype.pop=An.prototype.pop,An.prototype.last=An.prototype.jc,An.prototype.first=An.prototype.first,An.prototype.set=An.prototype.set,An.prototype.setElt=An.prototype.cd,An.prototype.get=An.prototype.get,An.prototype.elt=An.prototype.M,An.prototype.indexOf=An.prototype.indexOf,An.prototype.has=An.prototype.has,An.prototype.contains=An.prototype.contains,An.prototype.clear=An.prototype.clear,An.prototype.addAll=An.prototype.addAll,An.prototype.push=An.prototype.push,An.prototype.add=An.prototype.add,An.prototype.thaw=An.prototype.ka,An.prototype.freeze=An.prototype.freeze,An.className="List";function Ya(a){this.eg=a,a.Sa=null,this.qa=a.Ja,this.sa=null}Ya.prototype.reset=function(){var a=this.eg;a.Sa=null,this.qa=a.Ja,this.sa=null},Ya.prototype.next=function(){var a=this.eg;if(a.Ja!==this.qa&&this.key===null)return!1;var y=this.sa;return y=y===null?a.ea:y.va,y!==null?(this.sa=y,this.value=y.value,this.key=y.key,!0):(this.de(),!1)},Ya.prototype.Ad=function(){return this.next()},Ya.prototype.first=function(){var a=this.eg;if(this.qa=a.Ja,a=a.ea,a!==null){this.sa=a;var y=a.value;return this.key=a.key,this.value=y}return null},Ya.prototype.any=function(a){var y=this.eg;for(this.sa=y.Sa=null,y=y.ea;y!==null;){if(a(y.value))return!0;y=y.va}return!1},Ya.prototype.all=function(a){var y=this.eg;for(this.sa=y.Sa=null,y=y.ea;y!==null;){if(!a(y.value))return!1;y=y.va}return!0},Ya.prototype.each=function(a){var y=this.eg;for(this.sa=y.Sa=null,y=y.ea;y!==null;)a(y.value),y=y.va;return this},Ya.prototype.map=function(a){var y=this.eg;y.Sa=null;var x=new An;for(y=y.ea;y!==null;)x.add(a(y.value)),y=y.va;return x.iterator},Ya.prototype.filter=function(a){var y=this.eg;y.Sa=null;var x=new An;for(y=y.ea;y!==null;){var E=y.value;a(E)&&x.add(E),y=y.va}return x.iterator},Ya.prototype.de=function(){this.value=this.key=null,this.qa=-1,this.eg.Sa=this},Ya.prototype.toString=function(){return this.sa!==null?"SetIterator@"+this.sa.value:"SetIterator"},Yt.Object.defineProperties(Ya.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.eg.Sb}}}),Ya.prototype.first=Ya.prototype.first,Ya.prototype.hasNext=Ya.prototype.Ad,Ya.prototype.next=Ya.prototype.next,Ya.prototype.reset=Ya.prototype.reset,Ya.className="SetIterator";function Pn(a){jo(this),this._isFrozen=!1,this.Tb={},this.Sb=0,this.Sa=null,this.Ja=0,this.kf=this.ea=null,typeof a=="string"&&Dt("Error: Since 2.0 List/Map/Set constructors no longer take an argument that enforces type."),a!==void 0&&this.addAll(a)}we=Pn.prototype,we.xb=function(){var a=this.Ja;a++,999999999<a&&(a=0),this.Ja=a},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return this._isFrozen=!1,this},we.toString=function(){return"Set()#"+qa(this)},we.add=function(a){if(a===null)return this;this._isFrozen&&wi(this,a);var y=a;return kn(a)&&(y=Ws(a)),this.Tb[y]===void 0&&(this.Sb++,a=new il(a,a),this.Tb[y]=a,y=this.kf,y===null?this.ea=a:(a.ll=y,y.va=a),this.kf=a,this.xb()),this},we.addAll=function(a){if(a===null)return this;if(this._isFrozen&&wi(this),Xi(a))for(var y=a.length,x=0;x<y;x++)this.add(a[x]);else for(a=a.iterator;a.next();)this.add(a.value);return this},we.contains=function(a){if(a===null)return!1;var y=a;return kn(a)&&(y=qa(a),y===void 0)?!1:this.Tb[y]!==void 0},we.has=function(a){return this.contains(a)},we.Sy=function(a){if(a===null)return!0;for(a=a.iterator;a.next();)if(!this.contains(a.value))return!1;return!0},we.Ty=function(a){if(a===null)return!0;for(a=a.iterator;a.next();)if(this.contains(a.value))return!0;return!1},we.first=function(){var a=this.ea;return a===null?null:a.value},Pn.prototype.any=function(a){for(var y=this.ea;y!==null;){if(a(y.value))return!0;y=y.va}return!1},Pn.prototype.all=function(a){for(var y=this.ea;y!==null;){if(!a(y.value))return!1;y=y.va}return!0},Pn.prototype.each=function(a){for(var y=this.ea;y!==null;)a(y.value),y=y.va;return this},Pn.prototype.map=function(a){for(var y=new Pn,x=this.ea;x!==null;)y.add(a(x.value)),x=x.va;return y},Pn.prototype.filter=function(a){for(var y=new Pn,x=this.ea;x!==null;){var E=x.value;a(E)&&y.add(E),x=x.va}return y},we=Pn.prototype,we.remove=function(a){if(a===null)return!1;this._isFrozen&&wi(this,a);var y=a;if(kn(a)&&(y=qa(a),y===void 0)||(a=this.Tb[y],a===void 0))return!1;var x=a.va,E=a.ll;return x!==null&&(x.ll=E),E!==null&&(E.va=x),this.ea===a&&(this.ea=x),this.kf===a&&(this.kf=E),delete this.Tb[y],this.Sb--,this.xb(),!0},we.delete=function(a){return this.remove(a)},we.hp=function(a){if(a===null)return this;if(this._isFrozen&&wi(this),Xi(a))for(var y=a.length,x=0;x<y;x++)this.remove(a[x]);else for(a=a.iterator;a.next();)this.remove(a.value);return this},we.pA=function(a){if(a===null||this.count===0)return this;this._isFrozen&&wi(this);var y=new Pn;y.addAll(a),a=[];for(var x=this.iterator;x.next();){var E=x.value;y.contains(E)||a.push(E)}return this.hp(a),this},we.clear=function(){this._isFrozen&&wi(this),this.Tb={},this.Sb=0,this.Sa!==null&&this.Sa.reset(),this.kf=this.ea=null,this.xb()},Pn.prototype.copy=function(){var a=new Pn,y=this.Tb,x;for(x in y)a.add(y[x].value);return a},Pn.prototype.Fa=function(){var a=Array(this.Sb),y=this.Tb,x=0,E;for(E in y)a[x]=y[E].value,x++;return a},Pn.prototype.Hv=function(){var a=new An,y=this.Tb,x;for(x in y)a.add(y[x].value);return a};function jo(a){a.__gohashid=bl++}function Ws(a){var y=a.__gohashid;return y===void 0&&(y=bl++,a.__gohashid=y),y}function qa(a){return a.__gohashid}Yt.Object.defineProperties(Pn.prototype,{count:{get:function(){return this.Sb}},size:{get:function(){return this.Sb}},iterator:{get:function(){if(0>=this.Sb)return ea;var a=this.Sa;return a!==null?(a.reset(),a):new Ya(this)}}}),Pn.prototype.toList=Pn.prototype.Hv,Pn.prototype.toArray=Pn.prototype.Fa,Pn.prototype.clear=Pn.prototype.clear,Pn.prototype.retainAll=Pn.prototype.pA,Pn.prototype.removeAll=Pn.prototype.hp,Pn.prototype.delete=Pn.prototype.delete,Pn.prototype.remove=Pn.prototype.remove,Pn.prototype.first=Pn.prototype.first,Pn.prototype.containsAny=Pn.prototype.Ty,Pn.prototype.containsAll=Pn.prototype.Sy,Pn.prototype.has=Pn.prototype.has,Pn.prototype.contains=Pn.prototype.contains,Pn.prototype.addAll=Pn.prototype.addAll,Pn.prototype.add=Pn.prototype.add,Pn.prototype.thaw=Pn.prototype.ka,Pn.prototype.freeze=Pn.prototype.freeze;var bl=1;Pn.className="Set",Pn.uniqueHash=jo,Pn.hashIdUnique=Ws,Pn.hashId=qa;function Xa(a){this.ma=a,this.qa=a.Ja,this.sa=null}Xa.prototype.reset=function(){this.qa=this.ma.Ja,this.sa=null},Xa.prototype.next=function(){var a=this.ma;if(a.Ja!==this.qa&&this.key===null)return!1;var y=this.sa;return y=y===null?a.ea:y.va,y!==null?(this.sa=y,this.value=this.key=a=y.key,!0):(this.de(),!1)},Xa.prototype.Ad=function(){return this.next()},Xa.prototype.first=function(){var a=this.ma;return this.qa=a.Ja,a=a.ea,a!==null?(this.sa=a,this.value=this.key=a=a.key):null},Xa.prototype.any=function(a){var y=this.ma;for(this.sa=null,y=y.ea;y!==null;){if(a(y.key))return!0;y=y.va}return!1},Xa.prototype.all=function(a){var y=this.ma;for(this.sa=null,y=y.ea;y!==null;){if(!a(y.key))return!1;y=y.va}return!0},Xa.prototype.each=function(a){var y=this.ma;for(this.sa=null,y=y.ea;y!==null;)a(y.key),y=y.va;return this},Xa.prototype.map=function(a){var y=this.ma;this.sa=null;var x=new An;for(y=y.ea;y!==null;)x.add(a(y.key)),y=y.va;return x.iterator},Xa.prototype.filter=function(a){var y=this.ma;this.sa=null;var x=new An;for(y=y.ea;y!==null;){var E=y.key;a(E)&&x.add(E),y=y.va}return x.iterator},Xa.prototype.de=function(){this.value=this.key=null,this.qa=-1},Xa.prototype.toString=function(){return this.sa!==null?"MapKeySetIterator@"+this.sa.value:"MapKeySetIterator"},Yt.Object.defineProperties(Xa.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.ma.Sb}}}),Xa.prototype.first=Xa.prototype.first,Xa.prototype.hasNext=Xa.prototype.Ad,Xa.prototype.next=Xa.prototype.next,Xa.prototype.reset=Xa.prototype.reset,Xa.className="MapKeySetIterator";function _o(a){Pn.call(this),jo(this),this._isFrozen=!0,this.ma=a}Ct(_o,Pn),we=_o.prototype,we.freeze=function(){return this},we.ka=function(){return this},we.toString=function(){return"MapKeySet("+this.ma.toString()+")"},we.add=function(){Dt("This Set is read-only: "+this.toString())},we.contains=function(a){return this.ma.contains(a)},we.has=function(a){return this.contains(a)},we.remove=function(){Dt("This Set is read-only: "+this.toString())},we.delete=function(a){return this.remove(a)},we.clear=function(){Dt("This Set is read-only: "+this.toString())},we.first=function(){var a=this.ma.ea;return a!==null?a.key:null},_o.prototype.any=function(a){for(var y=this.ma.ea;y!==null;){if(a(y.key))return!0;y=y.va}return!1},_o.prototype.all=function(a){for(var y=this.ma.ea;y!==null;){if(!a(y.key))return!1;y=y.va}return!0},_o.prototype.each=function(a){for(var y=this.ma.ea;y!==null;)a(y.key),y=y.va;return this},_o.prototype.map=function(a){for(var y=new Pn,x=this.ma.ea;x!==null;)y.add(a(x.key)),x=x.va;return y},_o.prototype.filter=function(a){for(var y=new Pn,x=this.ma.ea;x!==null;){var E=x.key;a(E)&&y.add(E),x=x.va}return y},_o.prototype.copy=function(){return new _o(this.ma)},_o.prototype.Iv=function(){var a=new Pn,y=this.ma.Tb,x;for(x in y)a.add(y[x].key);return a},_o.prototype.Fa=function(){var a=this.ma.Tb,y=Array(this.ma.Sb),x=0,E;for(E in a)y[x]=a[E].key,x++;return y},_o.prototype.Hv=function(){var a=new An,y=this.ma.Tb,x;for(x in y)a.add(y[x].key);return a},Yt.Object.defineProperties(_o.prototype,{count:{get:function(){return this.ma.Sb}},size:{get:function(){return this.ma.Sb}},iterator:{get:function(){return 0>=this.ma.Sb?ea:new Xa(this.ma)}}}),_o.prototype.toList=_o.prototype.Hv,_o.prototype.toArray=_o.prototype.Fa,_o.prototype.toSet=_o.prototype.Iv,_o.prototype.first=_o.prototype.first,_o.prototype.clear=_o.prototype.clear,_o.prototype.delete=_o.prototype.delete,_o.prototype.remove=_o.prototype.remove,_o.prototype.has=_o.prototype.has,_o.prototype.contains=_o.prototype.contains,_o.prototype.add=_o.prototype.add,_o.prototype.thaw=_o.prototype.ka,_o.prototype.freeze=_o.prototype.freeze,_o.className="MapKeySet";function Va(a){this.ma=a,a.jf=null,this.qa=a.Ja,this.sa=null}Va.prototype.reset=function(){var a=this.ma;a.jf=null,this.qa=a.Ja,this.sa=null},Va.prototype.next=function(){var a=this.ma;if(a.Ja!==this.qa&&this.key===null)return!1;var y=this.sa;return y=y===null?a.ea:y.va,y!==null?(this.sa=y,this.value=y.value,this.key=y.key,!0):(this.de(),!1)},Va.prototype.Ad=function(){return this.next()},Va.prototype.first=function(){var a=this.ma;if(this.qa=a.Ja,a=a.ea,a!==null){this.sa=a;var y=a.value;return this.key=a.key,this.value=y}return null},Va.prototype.any=function(a){var y=this.ma;for(this.sa=y.jf=null,y=y.ea;y!==null;){if(a(y.value))return!0;y=y.va}return!1},Va.prototype.all=function(a){var y=this.ma;for(this.sa=y.jf=null,y=y.ea;y!==null;){if(!a(y.value))return!1;y=y.va}return!0},Va.prototype.each=function(a){var y=this.ma;for(this.sa=y.jf=null,y=y.ea;y!==null;)a(y.value),y=y.va;return this},Va.prototype.map=function(a){var y=this.ma;this.sa=y.jf=null;var x=new An;for(y=y.ea;y!==null;)x.add(a(y.value)),y=y.va;return x.iterator},Va.prototype.filter=function(a){var y=this.ma;this.sa=y.jf=null;var x=new An;for(y=y.ea;y!==null;){var E=y.value;a(E)&&x.add(E),y=y.va}return x.iterator},Va.prototype.de=function(){this.value=this.key=null,this.qa=-1,this.ma.jf=this},Va.prototype.toString=function(){return this.sa!==null?"MapValueSetIterator@"+this.sa.value:"MapValueSetIterator"},Yt.Object.defineProperties(Va.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.ma.Sb}}}),Va.prototype.first=Va.prototype.first,Va.prototype.hasNext=Va.prototype.Ad,Va.prototype.next=Va.prototype.next,Va.prototype.reset=Va.prototype.reset,Va.className="MapValueSetIterator";function il(a,y){this.key=a,this.value=y,this.ll=this.va=null}il.prototype.toString=function(){return"{"+this.key+":"+this.value+"}"},il.className="KeyValuePair";function Na(a){this.ma=a,a.Sa=null,this.qa=a.Ja,this.sa=null}Na.prototype.reset=function(){var a=this.ma;a.Sa=null,this.qa=a.Ja,this.sa=null},Na.prototype.next=function(){var a=this.ma;if(a.Ja!==this.qa&&this.key===null)return!1;var y=this.sa;return y=y===null?a.ea:y.va,y!==null?(this.sa=y,this.key=y.key,this.value=y.value,!0):(this.de(),!1)},Na.prototype.Ad=function(){return this.next()},Na.prototype.first=function(){var a=this.ma;return this.qa=a.Ja,a=a.ea,a!==null?(this.sa=a,this.key=a.key,this.value=a.value,a):null},Na.prototype.any=function(a){var y=this.ma;for(this.sa=y.Sa=null,y=y.ea;y!==null;){if(a(y))return!0;y=y.va}return!1},Na.prototype.all=function(a){var y=this.ma;for(this.sa=y.Sa=null,y=y.ea;y!==null;){if(!a(y))return!1;y=y.va}return!0},Na.prototype.each=function(a){var y=this.ma;for(this.sa=y.Sa=null,y=y.ea;y!==null;)a(y),y=y.va;return this},Na.prototype.map=function(a){var y=this.ma;this.sa=y.Sa=null;var x=new An;for(y=y.ea;y!==null;)x.add(a(y)),y=y.va;return x.iterator},Na.prototype.filter=function(a){var y=this.ma;this.sa=y.Sa=null;var x=new An;for(y=y.ea;y!==null;)a(y)&&x.add(y),y=y.va;return x.iterator},Na.prototype.de=function(){this.value=this.key=null,this.qa=-1,this.ma.Sa=this},Na.prototype.toString=function(){return this.sa!==null?"MapIterator@"+this.sa:"MapIterator"},Yt.Object.defineProperties(Na.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.ma.Sb}}}),Na.prototype.first=Na.prototype.first,Na.prototype.hasNext=Na.prototype.Ad,Na.prototype.next=Na.prototype.next,Na.prototype.reset=Na.prototype.reset,Na.className="MapIterator";function Li(a){jo(this),this._isFrozen=!1,this.Tb={},this.Sb=0,this.jf=this.Sa=null,this.Ja=0,this.kf=this.ea=null,typeof a=="string"&&Dt("Error: Since 2.0 List/Map/Set constructors no longer take an argument that enforces type."),a!==void 0&&this.addAll(a)}we=Li.prototype,we.xb=function(){var a=this.Ja;a++,999999999<a&&(a=0),this.Ja=a},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return this._isFrozen=!1,this},we.toString=function(){return"Map()#"+qa(this)},we.add=function(a,y){this._isFrozen&&wi(this,a);var x=a;kn(a)&&(x=Ws(a));var E=this.Tb[x];return E===void 0?(this.Sb++,a=new il(a,y),this.Tb[x]=a,x=this.kf,x===null?this.ea=a:(a.ll=x,x.va=a),this.kf=a,this.xb()):E.value=y,this},we.set=function(a,y){return this.add(a,y)},we.addAll=function(a){if(a===null)return this;if(Xi(a))for(var y=a.length,x=0;x<y;x++){var E=a[x];this.add(E.key,E.value)}else if(a instanceof Li)for(a=a.iterator;a.next();)this.add(a.key,a.value);else for(a=a.iterator;a.next();)y=a.value,this.add(y.key,y.value);return this},we.first=function(){return this.ea},Li.prototype.any=function(a){for(var y=this.ea;y!==null;){if(a(y))return!0;y=y.va}return!1},Li.prototype.all=function(a){for(var y=this.ea;y!==null;){if(!a(y))return!1;y=y.va}return!0},Li.prototype.each=function(a){for(var y=this.ea;y!==null;)a(y),y=y.va;return this},Li.prototype.map=function(a){for(var y=new Li,x=this.ea;x!==null;)y.add(x.key,a(x)),x=x.va;return y},Li.prototype.filter=function(a){for(var y=new Li,x=this.ea;x!==null;)a(x)&&y.add(x.key,x.value),x=x.va;return y},we=Li.prototype,we.contains=function(a){var y=a;return kn(a)&&(y=qa(a),y===void 0)?!1:this.Tb[y]!==void 0},we.has=function(a){return this.contains(a)},we.I=function(a){var y=a;return kn(a)&&(y=qa(a),y===void 0)?null:(a=this.Tb[y],a===void 0?null:a.value)},we.get=function(a){return this.I(a)},we.remove=function(a){if(a===null)return!1;this._isFrozen&&wi(this,a);var y=a;if(kn(a)&&(y=qa(a),y===void 0)||(a=this.Tb[y],a===void 0))return!1;var x=a.va,E=a.ll;return x!==null&&(x.ll=E),E!==null&&(E.va=x),this.ea===a&&(this.ea=x),this.kf===a&&(this.kf=E),delete this.Tb[y],this.Sb--,this.xb(),!0},we.delete=function(a){return this.remove(a)},we.clear=function(){this._isFrozen&&wi(this),this.Tb={},this.Sb=0,this.Sa!==null&&this.Sa.reset(),this.jf!==null&&this.jf.reset(),this.kf=this.ea=null,this.xb()},Li.prototype.copy=function(){var a=new Li,y=this.Tb,x;for(x in y){var E=y[x];a.add(E.key,E.value)}return a},Li.prototype.Fa=function(){var a=this.Tb,y=Array(this.Sb),x=0,E;for(E in a){var b=a[E];y[x]=new il(b.key,b.value),x++}return y},Li.prototype.Lf=function(){return new _o(this)},Yt.Object.defineProperties(Li.prototype,{count:{get:function(){return this.Sb}},size:{get:function(){return this.Sb}},iterator:{get:function(){if(0>=this.count)return ea;var a=this.Sa;return a!==null?(a.reset(),a):new Na(this)}},iteratorKeys:{get:function(){return 0>=this.count?ea:new Xa(this)}},iteratorValues:{get:function(){if(0>=this.count)return ea;var a=this.jf;return a!==null?(a.reset(),a):new Va(this)}}}),Li.prototype.toKeySet=Li.prototype.Lf,Li.prototype.toArray=Li.prototype.Fa,Li.prototype.clear=Li.prototype.clear,Li.prototype.delete=Li.prototype.delete,Li.prototype.remove=Li.prototype.remove,Li.prototype.get=Li.prototype.get,Li.prototype.getValue=Li.prototype.I,Li.prototype.has=Li.prototype.has,Li.prototype.contains=Li.prototype.contains,Li.prototype.first=Li.prototype.first,Li.prototype.addAll=Li.prototype.addAll,Li.prototype.set=Li.prototype.set,Li.prototype.add=Li.prototype.add,Li.prototype.thaw=Li.prototype.ka,Li.prototype.freeze=Li.prototype.freeze,Li.className="Map";function Qe(a,y){a===void 0?this.y=this.x=0:typeof a=="number"&&typeof y=="number"?(this.x=a,this.y=y):Dt("Invalid arguments to Point constructor: "+a+", "+y),this._isFrozen=!1}var bs,Ul,Zl,rl,tu;Qe.prototype.assign=function(a){return this.x=a.x,this.y=a.y,this},Qe.prototype.h=function(a,y){return this.x=a,this.y=y,this},Qe.prototype.sg=function(a,y){return this.x=a,this.y=y,this},Qe.prototype.set=function(a){return this.x=a.x,this.y=a.y,this},Qe.prototype.copy=function(){var a=new Qe;return a.x=this.x,a.y=this.y,a},we=Qe.prototype,we.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},we.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return Object.isFrozen(this)&&Dt("cannot thaw constant: "+this),this._isFrozen=!1,this};function Il(a){if(typeof a=="string"){a=a.split(" ");for(var y=0,x=0;a[y]==="";)y++;var E=a[y++];E&&(x=parseFloat(E));for(var b=0;a[y]==="";)y++;return(E=a[y++])&&(b=parseFloat(E)),new Qe(x,b)}return new Qe}function Hu(a){return a.x.toString()+" "+a.y.toString()}we.toString=function(){return"Point("+this.x+","+this.y+")"},we.D=function(a){return a instanceof Qe?this.x===a.x&&this.y===a.y:!1},we.hi=function(a,y){return this.x===a&&this.y===y},we.Xa=function(a){return yt.B(this.x,a.x)&&yt.B(this.y,a.y)},we.add=function(a){return this.x+=a.x,this.y+=a.y,this},we.re=function(a){return this.x-=a.x,this.y-=a.y,this},we.offset=function(a,y){return this.x+=a,this.y+=y,this},Qe.prototype.rotate=function(a){if(a===0)return this;var y=this.x,x=this.y;if(y===0&&x===0)return this;if(360<=a?a-=360:0>a&&(a+=360),a===90){a=0;var E=1}else a===180?(a=-1,E=0):a===270?(a=0,E=-1):(E=a*Math.PI/180,a=Math.cos(E),E=Math.sin(E));return this.x=a*y-E*x,this.y=E*y+a*x,this},we=Qe.prototype,we.scale=function(a,y){return this.x*=a,this.y*=y,this},we.Bf=function(a){var y=a.x-this.x;return a=a.y-this.y,y*y+a*a},we.zd=function(a,y){return a-=this.x,y-=this.y,a*a+y*y},we.normalize=function(){var a=this.x,y=this.y,x=Math.sqrt(a*a+y*y);return 0<x&&(this.x=a/x,this.y=y/x),this},we.ab=function(a){return nu(a.x-this.x,a.y-this.y)},we.direction=function(a,y){return nu(a-this.x,y-this.y)};function nu(a,y){if(a===0)return 0<y?90:0>y?270:0;if(y===0)return 0<a?0:180;if(isNaN(a)||isNaN(y))return 0;var x=180*Math.atan(Math.abs(y/a))/Math.PI;return 0>a?x=0>y?x+180:180-x:0>y&&(x=360-x),x}we.Ry=function(a,y){return yt.Fl(a.x,a.y,y.x,y.y,this.x,this.y)},we.fA=function(a,y,x,E){return yt.qh(a,y,x,E,this.x,this.y,this),this},we.gA=function(a,y){return yt.qh(a.x,a.y,y.x,y.y,this.x,this.y,this),this},we.uA=function(a,y,x,E){return yt.No(this.x,this.y,a,y,x,E,this),this},we.vA=function(a,y){return yt.No(this.x,this.y,a.x,a.y,y.width,y.height,this),this},we.xi=function(a,y){return this.x=a.x+y.x*a.width+y.offsetX,this.y=a.y+y.y*a.height+y.offsetY,this},we.yi=function(a,y,x,E,b){return this.x=a+b.x*x+b.offsetX,this.y=y+b.y*E+b.offsetY,this},we.transform=function(a){return a.Ga(this),this};function Ua(a,y){return y.Cd(a),a}function ps(a,y,x,E,b,z){var ee=b-x,re=z-E,oe=ee*ee+re*re;x-=a,E-=y;var se=-x*ee-E*re;return 0>=se||se>=oe?(ee=b-a,re=z-y,Math.min(x*x+E*E,ee*ee+re*re)):(a=ee*E-re*x,a*a/oe)}function Or(a,y,x,E){return a=x-a,y=E-y,a*a+y*y}function Pr(a,y,x,E){return a=x-a,y=E-y,a===0?0<y?90:0>y?270:0:y===0?0<a?0:180:isNaN(a)||isNaN(y)?0:(E=180*Math.atan(Math.abs(y/a))/Math.PI,0>a?E=0>y?E+180:180-E:0>y&&(E=360-E),E)}we.w=function(){return isFinite(this.x)&&isFinite(this.y)},Qe.alloc=function(){var a=so.pop();return a===void 0?new Qe:a},Qe.allocAt=function(a,y){var x=so.pop();return x===void 0?new Qe(a,y):(x.x=a,x.y=y,x)},Qe.free=function(a){so.push(a)},Qe.prototype.isReal=Qe.prototype.w,Qe.prototype.setSpot=Qe.prototype.yi,Qe.prototype.setRectSpot=Qe.prototype.xi,Qe.prototype.snapToGridPoint=Qe.prototype.vA,Qe.prototype.snapToGrid=Qe.prototype.uA,Qe.prototype.projectOntoLineSegmentPoint=Qe.prototype.gA,Qe.prototype.projectOntoLineSegment=Qe.prototype.fA,Qe.intersectingLineSegments=function(a,y,x,E,b,z,ee,re){return yt.Rl(a,y,x,E,b,z,ee,re)},Qe.prototype.compareWithLineSegmentPoint=Qe.prototype.Ry,Qe.compareWithLineSegment=function(a,y,x,E,b,z){return yt.Fl(a,y,x,E,b,z)},Qe.prototype.direction=Qe.prototype.direction,Qe.prototype.directionPoint=Qe.prototype.ab,Qe.prototype.normalize=Qe.prototype.normalize,Qe.prototype.distanceSquared=Qe.prototype.zd,Qe.prototype.distanceSquaredPoint=Qe.prototype.Bf,Qe.prototype.scale=Qe.prototype.scale,Qe.prototype.rotate=Qe.prototype.rotate,Qe.prototype.offset=Qe.prototype.offset,Qe.prototype.subtract=Qe.prototype.re,Qe.prototype.add=Qe.prototype.add,Qe.prototype.equalsApprox=Qe.prototype.Xa,Qe.prototype.equalTo=Qe.prototype.hi,Qe.prototype.equals=Qe.prototype.D,Qe.prototype.set=Qe.prototype.set,Qe.prototype.setTo=Qe.prototype.sg;var so=[];Qe.className="Point",Qe.parse=Il,Qe.stringify=Hu,Qe.distanceLineSegmentSquared=ps,Qe.distanceSquared=Or,Qe.direction=Pr,Qe.Origin=bs=new Qe(0,0).ja(),Qe.InfiniteTopLeft=Ul=new Qe(-1/0,-1/0).ja(),Qe.InfiniteBottomRight=Zl=new Qe(1/0,1/0).ja(),Qe.SixPoint=rl=new Qe(6,6).ja(),Qe.NoPoint=tu=new Qe(NaN,NaN).ja(),Qe.parse=Il,Qe.stringify=Hu,Qe.distanceLineSegmentSquared=ps,Qe.distanceSquared=Or,Qe.direction=Pr;function fn(a,y){a===void 0?this.height=this.width=0:typeof a=="number"&&(0<=a||isNaN(a))&&typeof y=="number"&&(0<=y||isNaN(y))?(this.width=a,this.height=y):Dt("Invalid arguments to Size constructor: "+a+", "+y),this._isFrozen=!1}var jr,Ao,$a,Ia,ms,Vs,el;fn.prototype.assign=function(a){return this.width=a.width,this.height=a.height,this},fn.prototype.h=function(a,y){return this.width=a,this.height=y,this},fn.prototype.sg=function(a,y){return this.width=a,this.height=y,this},fn.prototype.set=function(a){return this.width=a.width,this.height=a.height,this},fn.prototype.copy=function(){var a=new fn;return a.width=this.width,a.height=this.height,a},we=fn.prototype,we.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},we.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return Object.isFrozen(this)&&Dt("cannot thaw constant: "+this),this._isFrozen=!1,this};function vl(a){if(typeof a=="string"){a=a.split(" ");for(var y=0,x=0;a[y]==="";)y++;var E=a[y++];E&&(x=parseFloat(E));for(var b=0;a[y]==="";)y++;return(E=a[y++])&&(b=parseFloat(E)),new fn(x,b)}return new fn}function Gu(a){return a.width.toString()+" "+a.height.toString()}we.toString=function(){return"Size("+this.width+","+this.height+")"},we.D=function(a){return a instanceof fn?this.width===a.width&&this.height===a.height:!1},we.hi=function(a,y){return this.width===a&&this.height===y},we.Xa=function(a){return yt.B(this.width,a.width)&&yt.B(this.height,a.height)},we.Bc=function(a,y){return a=this.width+a,this.width=0<=a?a:0,y=this.height+y,this.height=0<=y?y:0,this},we.w=function(){return isFinite(this.width)&&isFinite(this.height)},fn.alloc=function(){var a=Fu.pop();return a===void 0?new fn:a},fn.free=function(a){Fu.push(a)},fn.prototype.isReal=fn.prototype.w,fn.prototype.inflate=fn.prototype.Bc,fn.prototype.equalsApprox=fn.prototype.Xa,fn.prototype.equalTo=fn.prototype.hi,fn.prototype.equals=fn.prototype.D,fn.prototype.set=fn.prototype.set,fn.prototype.setTo=fn.prototype.sg;var Fu=[];fn.className="Size",fn.parse=vl,fn.stringify=Gu,fn.ZeroSize=jr=new fn(0,0).ja(),fn.OneSize=Ao=new fn(1,1).ja(),fn.SixSize=$a=new fn(6,6).ja(),fn.EightSize=Ia=new fn(8,8).ja(),fn.TenSize=ms=new fn(10,10).ja(),fn.InfiniteSize=Vs=new fn(1/0,1/0).ja(),fn.NoSize=el=new fn(NaN,NaN).ja(),fn.parse=vl,fn.stringify=Gu;function Xt(a,y,x,E){a===void 0?this.height=this.width=this.y=this.x=0:typeof a=="number"&&typeof y=="number"&&typeof x=="number"&&(0<=x||isNaN(x))&&typeof E=="number"&&(0<=E||isNaN(E))?(this.x=a,this.y=y,this.width=x,this.height=E):a instanceof Qe?(x=a.x,a=a.y,y instanceof Qe?(E=y.x,y=y.y,this.x=Math.min(x,E),this.y=Math.min(a,y),this.width=Math.abs(x-E),this.height=Math.abs(a-y)):y instanceof fn?(this.x=x,this.y=a,this.width=y.width,this.height=y.height):Dt("Incorrect second argument supplied to Rect constructor "+y)):Dt("Invalid arguments to Rect constructor: "+a+", "+y+", "+x+", "+E),this._isFrozen=!1}we=Xt.prototype,we.assign=function(a){return this.x=a.x,this.y=a.y,this.width=a.width,this.height=a.height,this},we.h=function(a,y,x,E){return this.x=a,this.y=y,this.width=x,this.height=E,this};function Ll(a,y,x){a.width=y,a.height=x}we.sg=function(a,y,x,E){return this.x=a,this.y=y,this.width=x,this.height=E,this},we.set=function(a){return this.x=a.x,this.y=a.y,this.width=a.width,this.height=a.height,this},we.dd=function(a){return this.x=a.x,this.y=a.y,this},we.tA=function(a){return this.width=a.width,this.height=a.height,this},Xt.prototype.copy=function(){var a=new Xt;return a.x=this.x,a.y=this.y,a.width=this.width,a.height=this.height,a},we=Xt.prototype,we.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},we.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return Object.isFrozen(this)&&Dt("cannot thaw constant: "+this),this._isFrozen=!1,this};function zl(a){if(typeof a=="string"){a=a.split(" ");for(var y=0,x=0;a[y]==="";)y++;var E=a[y++];E&&(x=parseFloat(E));for(var b=0;a[y]==="";)y++;(E=a[y++])&&(b=parseFloat(E));for(var z=0;a[y]==="";)y++;(E=a[y++])&&(z=parseFloat(E));for(var ee=0;a[y]==="";)y++;return(E=a[y++])&&(ee=parseFloat(E)),new Xt(x,b,z,ee)}return new Xt}function fu(a){return a.x.toString()+" "+a.y.toString()+" "+a.width.toString()+" "+a.height.toString()}we.toString=function(){return"Rect("+this.x+","+this.y+","+this.width+","+this.height+")"},we.D=function(a){return a instanceof Xt?this.x===a.x&&this.y===a.y&&this.width===a.width&&this.height===a.height:!1},we.hi=function(a,y,x,E){return this.x===a&&this.y===y&&this.width===x&&this.height===E},we.Xa=function(a){return yt.B(this.x,a.x)&&yt.B(this.y,a.y)&&yt.B(this.width,a.width)&&yt.B(this.height,a.height)};function As(a,y){return yt.$(a.x,y.x)&&yt.$(a.y,y.y)&&yt.$(a.width,y.width)&&yt.$(a.height,y.height)}we.ca=function(a){return this.x<=a.x&&this.x+this.width>=a.x&&this.y<=a.y&&this.y+this.height>=a.y},we.Re=function(a){return this.x<=a.x&&a.x+a.width<=this.x+this.width&&this.y<=a.y&&a.y+a.height<=this.y+this.height},we.contains=function(a,y,x,E){return x===void 0&&(x=0),E===void 0&&(E=0),this.x<=a&&a+x<=this.x+this.width&&this.y<=y&&y+E<=this.y+this.height},we.offset=function(a,y){return this.x+=a,this.y+=y,this},we.Bc=function(a,y){return gu(this,y,a,y,a)},we.Co=function(a){return gu(this,a.top,a.right,a.bottom,a.left)},we.Fv=function(a){return gu(this,-a.top,-a.right,-a.bottom,-a.left)},we.Hz=function(a,y,x,E){return gu(this,a,y,x,E)};function gu(a,y,x,E,b){var z=a.width;return x+b<=-z?(a.x+=z/2,a.width=0):(a.x-=b,a.width+=x+b),x=a.height,y+E<=-x?(a.y+=x/2,a.height=0):(a.y-=y,a.height+=y+E),a}we.Ex=function(a){return xh(this,a.x,a.y,a.width,a.height)},we.Uu=function(a,y,x,E){return xh(this,a,y,x,E)};function xh(a,y,x,E,b){var z=Math.max(a.x,y),ee=Math.max(a.y,x);return y=Math.min(a.x+a.width,y+E),x=Math.min(a.y+a.height,x+b),a.x=z,a.y=ee,a.width=Math.max(0,y-z),a.height=Math.max(0,x-ee),a}we.Yc=function(a){return this.Vu(a.x,a.y,a.width,a.height)},we.Vu=function(a,y,x,E){var b=this.width,z=this.x;return b!==1/0&&x!==1/0&&(b+=z,x+=a,isNaN(x)||isNaN(b)||z>x||a>b)?!1:(a=this.height,x=this.y,!(a!==1/0&&E!==1/0&&(a+=x,E+=y,isNaN(E)||isNaN(a)||x>E||y>a)))};function Xu(a,y){var x=a.width,E=a.x,b=y.x-10;return E>y.width+10+10+b||b>x+E?!1:(x=a.height,a=a.y,E=y.y-10,!(a>y.height+10+10+E||E>x+a))}we.Ye=function(a){return es(this,a.x,a.y,0,0)},we.ed=function(a){return es(this,a.x,a.y,a.width,a.height)},we.Kv=function(a,y,x,E){return x===void 0&&(x=0),E===void 0&&(E=0),es(this,a,y,x,E)};function es(a,y,x,E,b){var z=Math.min(a.x,y),ee=Math.min(a.y,x);return y=Math.max(a.x+a.width,y+E),x=Math.max(a.y+a.height,x+b),a.x=z,a.y=ee,a.width=y-z,a.height=x-ee,a}we.yi=function(a,y,x){return this.x=a-x.offsetX-x.x*this.width,this.y=y-x.offsetY-x.y*this.height,this};function Ds(a,y,x,E,b,z,ee,re){return ee===void 0&&(ee=0),re===void 0&&(re=0),a<=b&&b+ee<=a+x&&y<=z&&z+re<=y+E}function Mo(a,y,x,E,b,z,ee,re){return a>ee+b||b>x+a?!1:!(y>re+z||z>E+y)}we.w=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},we.Mz=function(){return this.width===0&&this.height===0},Xt.alloc=function(){var a=Ls.pop();return a===void 0?new Xt:a},Xt.allocAt=function(a,y,x,E){var b=Ls.pop();return b===void 0?new Xt(a,y,x,E):b.h(a,y,x,E)},Xt.free=function(a){Ls.push(a)},Yt.Object.defineProperties(Xt.prototype,{left:{get:function(){return this.x},set:function(a){this.x=a}},top:{get:function(){return this.y},set:function(a){this.y=a}},right:{get:function(){return this.x+this.width},set:function(a){this.x+=a-(this.x+this.width)}},bottom:{get:function(){return this.y+this.height},set:function(a){this.y+=a-(this.y+this.height)}},position:{get:function(){return new Qe(this.x,this.y)},set:function(a){this.x=a.x,this.y=a.y}},size:{get:function(){return new fn(this.width,this.height)},set:function(a){this.width=a.width,this.height=a.height}},center:{get:function(){return new Qe(this.x+this.width/2,this.y+this.height/2)},set:function(a){this.x=a.x-this.width/2,this.y=a.y-this.height/2}},centerX:{get:function(){return this.x+this.width/2},set:function(a){this.x=a-this.width/2}},centerY:{get:function(){return this.y+this.height/2},set:function(a){this.y=a-this.height/2}}}),Xt.prototype.isEmpty=Xt.prototype.Mz,Xt.prototype.isReal=Xt.prototype.w,Xt.intersectsLineSegment=function(a,y,x,E,b,z,ee,re){return yt.Fx(a,y,x,E,b,z,ee,re)},Xt.prototype.setSpot=Xt.prototype.yi,Xt.prototype.union=Xt.prototype.Kv,Xt.prototype.unionRect=Xt.prototype.ed,Xt.prototype.unionPoint=Xt.prototype.Ye,Xt.prototype.intersects=Xt.prototype.Vu,Xt.prototype.intersectsRect=Xt.prototype.Yc,Xt.prototype.intersect=Xt.prototype.Uu,Xt.prototype.intersectRect=Xt.prototype.Ex,Xt.prototype.grow=Xt.prototype.Hz,Xt.prototype.subtractMargin=Xt.prototype.Fv,Xt.prototype.addMargin=Xt.prototype.Co,Xt.prototype.inflate=Xt.prototype.Bc,Xt.prototype.offset=Xt.prototype.offset,Xt.prototype.contains=Xt.prototype.contains,Xt.prototype.containsRect=Xt.prototype.Re,Xt.prototype.containsPoint=Xt.prototype.ca,Xt.prototype.equalsApprox=Xt.prototype.Xa,Xt.prototype.equalTo=Xt.prototype.hi,Xt.prototype.equals=Xt.prototype.D,Xt.prototype.setSize=Xt.prototype.tA,Xt.prototype.setPoint=Xt.prototype.dd,Xt.prototype.set=Xt.prototype.set,Xt.prototype.setTo=Xt.prototype.sg;var Ro=null,Ma=null,Ls=[];Xt.className="Rect",Xt.parse=zl,Xt.stringify=fu,Xt.contains=Ds,Xt.intersects=Mo,Xt.ZeroRect=Ro=new Xt(0,0,0,0).ja(),Xt.NoRect=Ma=new Xt(NaN,NaN,NaN,NaN).ja(),Xt.parse=zl,Xt.stringify=fu,Xt.contains=Ds,Xt.intersects=Mo;function vr(a,y,x,E){a===void 0?this.left=this.bottom=this.right=this.top=0:y===void 0?this.left=this.bottom=this.right=this.top=a:x===void 0?(this.top=a,this.right=y,this.bottom=a,this.left=y):E!==void 0?(this.top=a,this.right=y,this.bottom=x,this.left=E):Dt("Invalid arguments to Margin constructor: "+a+", "+y+", "+x+", "+E),this._isFrozen=!1}vr.prototype.assign=function(a){return this.top=a.top,this.right=a.right,this.bottom=a.bottom,this.left=a.left,this},vr.prototype.sg=function(a,y,x,E){return this.top=a,this.right=y,this.bottom=x,this.left=E,this},vr.prototype.set=function(a){return this.top=a.top,this.right=a.right,this.bottom=a.bottom,this.left=a.left,this},vr.prototype.copy=function(){var a=new vr;return a.top=this.top,a.right=this.right,a.bottom=this.bottom,a.left=this.left,a},we=vr.prototype,we.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},we.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return Object.isFrozen(this)&&Dt("cannot thaw constant: "+this),this._isFrozen=!1,this};function $h(a){if(typeof a=="string"){a=a.split(" ");for(var y=0,x=NaN;a[y]==="";)y++;var E=a[y++];if(E&&(x=parseFloat(E)),isNaN(x))return new vr;for(var b=NaN;a[y]==="";)y++;if((E=a[y++])&&(b=parseFloat(E)),isNaN(b))return new vr(x);for(var z=NaN;a[y]==="";)y++;if((E=a[y++])&&(z=parseFloat(E)),isNaN(z))return new vr(x,b);for(var ee=NaN;a[y]==="";)y++;return(E=a[y++])&&(ee=parseFloat(E)),isNaN(ee)?new vr(x,b):new vr(x,b,z,ee)}return new vr}function Nl(a){return a.top.toString()+" "+a.right.toString()+" "+a.bottom.toString()+" "+a.left.toString()}we.toString=function(){return"Margin("+this.top+","+this.right+","+this.bottom+","+this.left+")"},we.D=function(a){return a instanceof vr?this.top===a.top&&this.right===a.right&&this.bottom===a.bottom&&this.left===a.left:!1},we.hi=function(a,y,x,E){return this.top===a&&this.right===y&&this.bottom===x&&this.left===E},we.Xa=function(a){return yt.B(this.top,a.top)&&yt.B(this.right,a.right)&&yt.B(this.bottom,a.bottom)&&yt.B(this.left,a.left)},we.w=function(){return isFinite(this.top)&&isFinite(this.right)&&isFinite(this.bottom)&&isFinite(this.left)},vr.alloc=function(){var a=Ju.pop();return a===void 0?new vr:a},vr.free=function(a){Ju.push(a)},vr.prototype.isReal=vr.prototype.w,vr.prototype.equalsApprox=vr.prototype.Xa,vr.prototype.equalTo=vr.prototype.hi,vr.prototype.equals=vr.prototype.D,vr.prototype.set=vr.prototype.set,vr.prototype.setTo=vr.prototype.sg;var Tl=null,wh=null,Ju=[];vr.className="Margin",vr.parse=$h,vr.stringify=Nl,vr.ZeroMargin=Tl=new vr(0,0,0,0).ja(),vr.TwoMargin=wh=new vr(2,2,2,2).ja(),vr.parse=$h,vr.stringify=Nl;function Bi(a,y,x,E){a===void 0?this.offsetY=this.offsetX=this.y=this.x=0:(y===void 0&&(y=0),x===void 0&&(x=0),E===void 0&&(E=0),this.x=a,this.y=y,this.offsetX=x,this.offsetY=E),this._isFrozen=!1}var Ms,Cs,_l,lh,Ph,ko,Ch,iu,yl,Hl,Eh,ec,Dl,ru,uh,Ec,zh,Rc,dc,Gl,Qu,pu,bh,tc,Hh,vs,tn,nc,Gh,qu,Ml,ol,Rs,Us,hh,al;Bi.prototype.assign=function(a){return this.x=a.x,this.y=a.y,this.offsetX=a.offsetX,this.offsetY=a.offsetY,this},Bi.prototype.sg=function(a,y,x,E){return this.x=a,this.y=y,this.offsetX=x,this.offsetY=E,this},Bi.prototype.set=function(a){return this.x=a.x,this.y=a.y,this.offsetX=a.offsetX,this.offsetY=a.offsetY,this},Bi.prototype.copy=function(){var a=new Bi;return a.x=this.x,a.y=this.y,a.offsetX=this.offsetX,a.offsetY=this.offsetY,a},we=Bi.prototype,we.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},we.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return Object.isFrozen(this)&&Dt("cannot thaw constant: "+this),this._isFrozen=!1,this};function Ss(a,y){return a.x=NaN,a.y=NaN,a.offsetX=y,a}function os(a){if(typeof a=="string"){if(a=a.trim(),a==="None")return Ms;if(a==="TopLeft")return Cs;if(a==="Top"||a==="TopCenter"||a==="MiddleTop")return _l;if(a==="TopRight")return lh;if(a==="Left"||a==="LeftCenter"||a==="MiddleLeft")return Ph;if(a==="Center")return ko;if(a==="Right"||a==="RightCenter"||a==="MiddleRight")return Ch;if(a==="BottomLeft")return iu;if(a==="Bottom"||a==="BottomCenter"||a==="MiddleBottom")return yl;if(a==="BottomRight")return Hl;if(a==="TopSide")return Eh;if(a==="LeftSide")return ec;if(a==="RightSide")return Dl;if(a==="BottomSide")return ru;if(a==="TopBottomSides")return uh;if(a==="LeftRightSides")return Ec;if(a==="TopLeftSides")return zh;if(a==="TopRightSides")return Rc;if(a==="BottomLeftSides")return dc;if(a==="BottomRightSides")return Gl;if(a==="NotTopSide")return Qu;if(a==="NotLeftSide")return pu;if(a==="NotRightSide")return bh;if(a==="NotBottomSide")return tc;if(a==="AllSides")return Hh;if(a==="Default")return vs;a=a.split(" ");for(var y=0,x=0;a[y]==="";)y++;var E=a[y++];E!==void 0&&0<E.length&&(x=parseFloat(E));for(var b=0;a[y]==="";)y++;E=a[y++],E!==void 0&&0<E.length&&(b=parseFloat(E));for(var z=0;a[y]==="";)y++;E=a[y++],E!==void 0&&0<E.length&&(z=parseFloat(E));for(var ee=0;a[y]==="";)y++;return E=a[y++],E!==void 0&&0<E.length&&(ee=parseFloat(E)),new Bi(x,b,z,ee)}return new Bi}function Lh(a){return a.sb()?a.x.toString()+" "+a.y.toString()+" "+a.offsetX.toString()+" "+a.offsetY.toString():a.toString()}we.toString=function(){return this.sb()?this.offsetX===0&&this.offsetY===0?"Spot("+this.x+","+this.y+")":"Spot("+this.x+","+this.y+","+this.offsetX+","+this.offsetY+")":this.D(Ms)?"None":this.D(Cs)?"TopLeft":this.D(_l)?"Top":this.D(lh)?"TopRight":this.D(Ph)?"Left":this.D(ko)?"Center":this.D(Ch)?"Right":this.D(iu)?"BottomLeft":this.D(yl)?"Bottom":this.D(Hl)?"BottomRight":this.D(Eh)?"TopSide":this.D(ec)?"LeftSide":this.D(Dl)?"RightSide":this.D(ru)?"BottomSide":this.D(uh)?"TopBottomSides":this.D(Ec)?"LeftRightSides":this.D(zh)?"TopLeftSides":this.D(Rc)?"TopRightSides":this.D(dc)?"BottomLeftSides":this.D(Gl)?"BottomRightSides":this.D(Qu)?"NotTopSide":this.D(pu)?"NotLeftSide":this.D(bh)?"NotRightSide":this.D(tc)?"NotBottomSide":this.D(Hh)?"AllSides":this.D(vs)?"Default":"None"},we.D=function(a){return a instanceof Bi?(this.x===a.x||isNaN(this.x)&&isNaN(a.x))&&(this.y===a.y||isNaN(this.y)&&isNaN(a.y))&&this.offsetX===a.offsetX&&this.offsetY===a.offsetY:!1},we.gv=function(){return new Bi(.5-(this.x-.5),.5-(this.y-.5),-this.offsetX,-this.offsetY)},we.Hf=function(a){if(!this.$c())return!1;if(!a.$c())if(a.D(tn))a=ec;else if(a.D(nc))a=Dl;else if(a.D(Gh))a=Eh;else if(a.D(qu))a=ru;else return!1;return a=a.offsetY,(this.offsetY&a)===a},we.sb=function(){return!isNaN(this.x)&&!isNaN(this.y)},we.Mc=function(){return isNaN(this.x)||isNaN(this.y)},we.$c=function(){return isNaN(this.x)&&isNaN(this.y)&&this.offsetX===1&&this.offsetY!==0},we.ys=function(){return isNaN(this.x)&&isNaN(this.y)&&this.offsetX===0&&this.offsetY===0},we.Xb=function(){return isNaN(this.x)&&isNaN(this.y)&&this.offsetX===-1&&this.offsetY===0},Bi.alloc=function(){var a=Au.pop();return a===void 0?new Bi:a},Bi.free=function(a){Au.push(a)},Bi.prototype.isDefault=Bi.prototype.Xb,Bi.prototype.isNone=Bi.prototype.ys,Bi.prototype.isSide=Bi.prototype.$c,Bi.prototype.isNoSpot=Bi.prototype.Mc,Bi.prototype.isSpot=Bi.prototype.sb,Bi.prototype.includesSide=Bi.prototype.Hf,Bi.prototype.opposite=Bi.prototype.gv,Bi.prototype.equals=Bi.prototype.D,Bi.prototype.set=Bi.prototype.set,Bi.prototype.setTo=Bi.prototype.sg;var Au=[];Bi.className="Spot",Bi.parse=os,Bi.stringify=Lh,Bi.None=Ms=Ss(new Bi(0,0,0,0),0).ja(),Bi.Default=vs=Ss(new Bi(0,0,-1,0),-1).ja(),Bi.TopLeft=Cs=new Bi(0,0,0,0).ja(),Bi.TopCenter=_l=new Bi(.5,0,0,0).ja(),Bi.TopRight=lh=new Bi(1,0,0,0).ja(),Bi.LeftCenter=Ph=new Bi(0,.5,0,0).ja(),Bi.Center=ko=new Bi(.5,.5,0,0).ja(),Bi.RightCenter=Ch=new Bi(1,.5,0,0).ja(),Bi.BottomLeft=iu=new Bi(0,1,0,0).ja(),Bi.BottomCenter=yl=new Bi(.5,1,0,0).ja(),Bi.BottomRight=Hl=new Bi(1,1,0,0).ja(),Bi.MiddleTop=Ml=_l,Bi.MiddleLeft=ol=Ph,Bi.MiddleRight=Rs=Ch,Bi.MiddleBottom=Us=yl,Bi.Top=Gh=_l,Bi.Left=tn=Ph,Bi.Right=nc=Ch,Bi.Bottom=qu=yl,Bi.TopSide=Eh=Ss(new Bi(0,0,1,1),1).ja(),Bi.LeftSide=ec=Ss(new Bi(0,0,1,2),1).ja(),Bi.RightSide=Dl=Ss(new Bi(0,0,1,4),1).ja(),Bi.BottomSide=ru=Ss(new Bi(0,0,1,8),1).ja(),Bi.TopBottomSides=uh=Ss(new Bi(0,0,1,9),1).ja(),Bi.LeftRightSides=Ec=Ss(new Bi(0,0,1,6),1).ja(),Bi.TopLeftSides=zh=Ss(new Bi(0,0,1,3),1).ja(),Bi.TopRightSides=Rc=Ss(new Bi(0,0,1,5),1).ja(),Bi.BottomLeftSides=dc=Ss(new Bi(0,0,1,10),1).ja(),Bi.BottomRightSides=Gl=Ss(new Bi(0,0,1,12),1).ja(),Bi.NotTopSide=Qu=Ss(new Bi(0,0,1,14),1).ja(),Bi.NotLeftSide=pu=Ss(new Bi(0,0,1,13),1).ja(),Bi.NotRightSide=bh=Ss(new Bi(0,0,1,11),1).ja(),Bi.NotBottomSide=tc=Ss(new Bi(0,0,1,7),1).ja(),Bi.AllSides=Hh=Ss(new Bi(0,0,1,15),1).ja(),hh=new Bi(.156,.156).ja(),al=new Bi(.844,.844).ja(),Bi.parse=os,Bi.stringify=Lh;function kr(){this.m11=1,this.m21=this.m12=0,this.m22=1,this.dy=this.dx=0}kr.prototype.set=function(a){return this.m11=a.m11,this.m12=a.m12,this.m21=a.m21,this.m22=a.m22,this.dx=a.dx,this.dy=a.dy,this},kr.prototype.setTransform=function(a,y,x,E,b,z){return this.m11=a,this.m12=y,this.m21=x,this.m22=E,this.dx=b,this.dy=z,this},kr.prototype.copy=function(){var a=new kr;return a.m11=this.m11,a.m12=this.m12,a.m21=this.m21,a.m22=this.m22,a.dx=this.dx,a.dy=this.dy,a},kr.prototype.toString=function(){return"Transform("+this.m11+","+this.m12+","+this.m21+","+this.m22+","+this.dx+","+this.dy+")"},kr.prototype.D=function(a){return this.m11===a.m11&&this.m12===a.m12&&this.m21===a.m21&&this.m22===a.m22&&this.dx===a.dx&&this.dy===a.dy},kr.prototype.ws=function(){return this.dx===0&&this.dy===0&&this.m11===1&&this.m12===0&&this.m21===0&&this.m22===1},kr.prototype.reset=function(){return this.m11=1,this.m21=this.m12=0,this.m22=1,this.dy=this.dx=0,this},kr.prototype.multiply=function(a){var y=this.m11*a.m11+this.m21*a.m12,x=this.m12*a.m11+this.m22*a.m12,E=this.m11*a.m21+this.m21*a.m22,b=this.m12*a.m21+this.m22*a.m22;return this.dx=this.m11*a.dx+this.m21*a.dy+this.dx,this.dy=this.m12*a.dx+this.m22*a.dy+this.dy,this.m11=y,this.m12=x,this.m21=E,this.m22=b,this},kr.prototype.bv=function(a){var y=1/(a.m11*a.m22-a.m12*a.m21),x=a.m22*y,E=-a.m12*y,b=-a.m21*y,z=a.m11*y,ee=y*(a.m21*a.dy-a.m22*a.dx);return a=y*(a.m12*a.dx-a.m11*a.dy),y=this.m11*x+this.m21*E,x=this.m12*x+this.m22*E,E=this.m11*b+this.m21*z,b=this.m12*b+this.m22*z,this.dx=this.m11*ee+this.m21*a+this.dx,this.dy=this.m12*ee+this.m22*a+this.dy,this.m11=y,this.m12=x,this.m21=E,this.m22=b,this},kr.prototype.Vj=function(){var a=1/(this.m11*this.m22-this.m12*this.m21),y=-this.m12*a,x=-this.m21*a,E=this.m11*a,b=a*(this.m21*this.dy-this.m22*this.dx),z=a*(this.m12*this.dx-this.m11*this.dy);return this.m11=this.m22*a,this.m12=y,this.m21=x,this.m22=E,this.dx=b,this.dy=z,this},kr.prototype.rotate=function(a,y,x){if(360<=a?a-=360:0>a&&(a+=360),a===0)return this;if(this.translate(y,x),a===90){a=0;var E=1}else a===180?(a=-1,E=0):a===270?(a=0,E=-1):(E=a*Math.PI/180,a=Math.cos(E),E=Math.sin(E));var b=this.m12*a+this.m22*E,z=this.m11*-E+this.m21*a,ee=this.m12*-E+this.m22*a;return this.m11=this.m11*a+this.m21*E,this.m12=b,this.m21=z,this.m22=ee,this.translate(-y,-x),this},we=kr.prototype,we.translate=function(a,y){return this.dx+=this.m11*a+this.m21*y,this.dy+=this.m12*a+this.m22*y,this},we.scale=function(a,y){return y===void 0&&(y=a),this.m11*=a,this.m12*=a,this.m21*=y,this.m22*=y,this},we.Ga=function(a){var y=a.x,x=a.y;return a.h(y*this.m11+x*this.m21+this.dx,y*this.m12+x*this.m22+this.dy)},we.Cd=function(a){var y=1/(this.m11*this.m22-this.m12*this.m21),x=a.x,E=a.y;return a.h(x*this.m22*y+E*-this.m21*y+y*(this.m21*this.dy-this.m22*this.dx),x*-this.m12*y+E*this.m11*y+y*(this.m12*this.dx-this.m11*this.dy))},we.Eu=function(a){var y=1/(this.m11*this.m22-this.m12*this.m21),x=1.25*a.x,E=1.2*a.y;return a.h(x*this.m22*y+E*-this.m21*y+y*(this.m21*this.dy-this.m22*this.dx),x*-this.m12*y+E*this.m11*y+y*(this.m12*this.dx-this.m11*this.dy))},we.pp=function(a){var y=a.x,x=a.y,E=y+a.width,b=x+a.height,z=this.m11,ee=this.m12,re=this.m21,oe=this.m22,se=this.dx,ue=this.dy,fe=y*z+x*re+se,ve=y*ee+x*oe+ue,ye=E*z+x*re+se,Ce=E*ee+x*oe+ue;return x=y*z+b*re+se,y=y*ee+b*oe+ue,z=E*z+b*re+se,E=E*ee+b*oe+ue,b=Math.min(fe,ye),fe=Math.max(fe,ye),ye=Math.min(ve,Ce),ve=Math.max(ve,Ce),b=Math.min(b,x),fe=Math.max(fe,x),ye=Math.min(ye,y),ve=Math.max(ve,y),b=Math.min(b,z),fe=Math.max(fe,z),ye=Math.min(ye,E),ve=Math.max(ve,E),a.h(b,ye,fe-b,ve-ye),a},kr.alloc=function(){var a=Kh.pop();return a===void 0?new kr:a},kr.free=function(a){Kh.push(a)},kr.prototype.transformRect=kr.prototype.pp,kr.prototype.transformPoint=kr.prototype.Ga,kr.prototype.scale=kr.prototype.scale,kr.prototype.translate=kr.prototype.translate,kr.prototype.rotate=kr.prototype.rotate,kr.prototype.invert=kr.prototype.Vj,kr.prototype.multiplyInverted=kr.prototype.bv,kr.prototype.multiply=kr.prototype.multiply,kr.prototype.reset=kr.prototype.reset,kr.prototype.isIdentity=kr.prototype.ws,kr.prototype.equals=kr.prototype.D,kr.prototype.setTransform=kr.prototype.setTransform,kr.prototype.set=kr.prototype.set;var Kh=[];kr.className="Transform",kr.xF="54a702f3e53909c447824c6706603faf4c";var yt={AA:"7da71ca0ad381e90",wg:(Math.sqrt(2)-1)/3*4,Uv:null,sqrt:function(a){if(0>=a)return 0;var y=yt.Uv;if(y===null){y=[];for(var x=0;2e3>=x;x++)y[x]=Math.sqrt(x);yt.Uv=y}return 1>a?(x=1/a,2e3>=x?1/y[x|0]:Math.sqrt(a)):2e3>=a?y[a|0]:Math.sqrt(a)},B:function(a,y){return a-=y,.5>a&&-.5<a},$:function(a,y){return a-=y,5e-8>a&&-5e-8<a},Yb:function(a,y,x,E,b,z,ee){if(0>=b&&(b=1e-6),a<x)var re=a,oe=x;else re=x,oe=a;if(y<E)var se=y,ue=E;else se=E,ue=y;if(a===x)return se<=ee&&ee<=ue&&a-b<=z&&z<=a+b;if(y===E)return re<=z&&z<=oe&&y-b<=ee&&ee<=y+b;if(oe+=b,re-=b,re<=z&&z<=oe&&(ue+=b,se-=b,se<=ee&&ee<=ue))if(oe-re>ue-se)if(a-x>b||x-a>b){if(z=(E-y)/(x-a)*(z-a)+y,z-b<=ee&&ee<=z+b)return!0}else return!0;else if(y-E>b||E-y>b){if(ee=(x-a)/(E-y)*(ee-y)+a,ee-b<=z&&z<=ee+b)return!0}else return!0;return!1},cs:function(a,y,x,E,b,z,ee,re,oe,se,ue,fe){if(yt.Yb(a,y,ee,re,fe,x,E)&&yt.Yb(a,y,ee,re,fe,b,z))return yt.Yb(a,y,ee,re,fe,se,ue);var ve=(a+x)/2,ye=(y+E)/2,Ce=(x+b)/2,Ae=(E+z)/2;b=(b+ee)/2,z=(z+re)/2,E=(ve+Ce)/2,x=(ye+Ae)/2,Ce=(Ce+b)/2,Ae=(Ae+z)/2;var Ye=(E+Ce)/2,We=(x+Ae)/2;return yt.cs(a,y,ve,ye,E,x,Ye,We,oe,se,ue,fe)||yt.cs(Ye,We,Ce,Ae,b,z,ee,re,oe,se,ue,fe)},ax:function(a,y,x,E,b,z,ee,re,oe){var se=(x+b)/2,ue=(E+z)/2;return oe.h((((a+x)/2+se)/2+(se+(b+ee)/2)/2)/2,(((y+E)/2+ue)/2+(ue+(z+re)/2)/2)/2),oe},My:function(a,y,x,E,b,z,ee,re){var oe=(x+b)/2,se=(E+z)/2;return Pr(((a+x)/2+oe)/2,((y+E)/2+se)/2,(oe+(b+ee)/2)/2,(se+(z+re)/2)/2)},Dl:function(a,y,x,E,b,z,ee,re,oe,se){if(yt.Yb(a,y,ee,re,oe,x,E)&&yt.Yb(a,y,ee,re,oe,b,z))es(se,a,y,0,0),es(se,ee,re,0,0);else{var ue=(a+x)/2,fe=(y+E)/2,ve=(x+b)/2,ye=(E+z)/2;b=(b+ee)/2,z=(z+re)/2,E=(ue+ve)/2,x=(fe+ye)/2,ve=(ve+b)/2,ye=(ye+z)/2;var Ce=(E+ve)/2,Ae=(x+ye)/2;yt.Dl(a,y,ue,fe,E,x,Ce,Ae,oe,se),yt.Dl(Ce,Ae,ve,ye,b,z,ee,re,oe,se)}return se},Qe:function(a,y,x,E,b,z,ee,re,oe,se){if(yt.Yb(a,y,ee,re,oe,x,E)&&yt.Yb(a,y,ee,re,oe,b,z))se.length===0&&(se.push(a),se.push(y)),se.push(ee),se.push(re);else{var ue=(a+x)/2,fe=(y+E)/2,ve=(x+b)/2,ye=(E+z)/2;b=(b+ee)/2,z=(z+re)/2,E=(ue+ve)/2,x=(fe+ye)/2,ve=(ve+b)/2,ye=(ye+z)/2;var Ce=(E+ve)/2,Ae=(x+ye)/2;yt.Qe(a,y,ue,fe,E,x,Ce,Ae,oe,se),yt.Qe(Ce,Ae,ve,ye,b,z,ee,re,oe,se)}return se},jv:function(a,y,x,E,b,z,ee,re,oe,se){if(yt.Yb(a,y,b,z,se,x,E))return yt.Yb(a,y,b,z,se,re,oe);var ue=(a+x)/2,fe=(y+E)/2;x=(x+b)/2,E=(E+z)/2;var ve=(ue+x)/2,ye=(fe+E)/2;return yt.jv(a,y,ue,fe,ve,ye,ee,re,oe,se)||yt.jv(ve,ye,x,E,b,z,ee,re,oe,se)},OA:function(a,y,x,E,b,z,ee){return ee.h(((a+x)/2+(x+b)/2)/2,((y+E)/2+(E+z)/2)/2),ee},iv:function(a,y,x,E,b,z,ee,re){if(yt.Yb(a,y,b,z,ee,x,E))es(re,a,y,0,0),es(re,b,z,0,0);else{var oe=(a+x)/2,se=(y+E)/2;x=(x+b)/2,E=(E+z)/2;var ue=(oe+x)/2,fe=(se+E)/2;yt.iv(a,y,oe,se,ue,fe,ee,re),yt.iv(ue,fe,x,E,b,z,ee,re)}return re},ep:function(a,y,x,E,b,z,ee,re){if(yt.Yb(a,y,b,z,ee,x,E))re.length===0&&(re.push(a),re.push(y)),re.push(b),re.push(z);else{var oe=(a+x)/2,se=(y+E)/2;x=(x+b)/2,E=(E+z)/2;var ue=(oe+x)/2,fe=(se+E)/2;yt.ep(a,y,oe,se,ue,fe,ee,re),yt.ep(ue,fe,x,E,b,z,ee,re)}return re},Eo:function(a,y,x,E,b,z,ee,re,oe,se,ue,fe,ve,ye){if(yt.Yb(a,y,ee,re,ve,x,E)&&yt.Yb(a,y,ee,re,ve,b,z))return!yt.Rl(a,y,ee,re,oe,se,ue,fe)||(ve=(a-ee)*(se-fe)-(y-re)*(oe-ue),ve===0)?!1:(ye.h(((a*re-y*ee)*(oe-ue)-(a-ee)*(oe*fe-se*ue))/ve,((a*re-y*ee)*(se-fe)-(y-re)*(oe*fe-se*ue))/ve),!0);var Ce=(a+x)/2,Ae=(y+E)/2,Ye=(x+b)/2,We=(E+z)/2;b=(b+ee)/2,z=(z+re)/2,E=(Ce+Ye)/2,x=(Ae+We)/2,Ye=(Ye+b)/2,We=(We+z)/2;var tt=(E+Ye)/2,rt=(x+We)/2,at=1/0,gt=!1,At=0,Zn=0;return yt.Eo(a,y,Ce,Ae,E,x,tt,rt,oe,se,ue,fe,ve,ye)&&(a=(ye.x-oe)*(ye.x-oe)+(ye.y-se)*(ye.y-se),a<at&&(at=a,gt=!0,At=ye.x,Zn=ye.y)),yt.Eo(tt,rt,Ye,We,b,z,ee,re,oe,se,ue,fe,ve,ye)&&(ye.x-oe)*(ye.x-oe)+(ye.y-se)*(ye.y-se)<at&&(gt=!0,At=ye.x,Zn=ye.y),gt&&(ye.x=At,ye.y=Zn),gt},Fo:function(a,y,x,E,b,z,ee,re,oe,se,ue,fe,ve){var ye=0;if(yt.Yb(a,y,ee,re,ve,x,E)&&yt.Yb(a,y,ee,re,ve,b,z)){if(ve=(a-ee)*(se-fe)-(y-re)*(oe-ue),ve===0)return ye;var Ce=((a*re-y*ee)*(oe-ue)-(a-ee)*(oe*fe-se*ue))/ve,Ae=((a*re-y*ee)*(se-fe)-(y-re)*(oe*fe-se*ue))/ve;if(Ce>=ue)return ye;if((oe>ue?oe-ue:ue-oe)<(se>fe?se-fe:fe-se)){if(y<re?(oe=y,a=re):(oe=re,a=y),Ae<oe||Ae>a)return ye}else if(a<ee?(oe=a,a=ee):oe=ee,Ce<oe||Ce>a)return ye;0<ve?ye++:0>ve&&ye--}else{Ce=(a+x)/2,Ae=(y+E)/2;var Ye=(x+b)/2,We=(E+z)/2;b=(b+ee)/2,z=(z+re)/2,E=(Ce+Ye)/2,x=(Ae+We)/2,Ye=(Ye+b)/2,We=(We+z)/2;var tt=(E+Ye)/2,rt=(x+We)/2;ye+=yt.Fo(a,y,Ce,Ae,E,x,tt,rt,oe,se,ue,fe,ve),ye+=yt.Fo(tt,rt,Ye,We,b,z,ee,re,oe,se,ue,fe,ve)}return ye},qh:function(a,y,x,E,b,z,ee){return yt.$(a,x)?(y<E?(x=y,y=E):x=E,z<x?(ee.h(a,x),!1):z>y?(ee.h(a,y),!1):(ee.h(a,z),!0)):yt.$(y,E)?(a<x?(E=a,a=x):E=x,b<E?(ee.h(E,y),!1):b>a?(ee.h(a,y),!1):(ee.h(b,y),!0)):(b=((a-b)*(a-x)+(y-z)*(y-E))/((x-a)*(x-a)+(E-y)*(E-y)),-5e-6>b?(ee.h(a,y),!1):1.000005<b?(ee.h(x,E),!1):(ee.h(a+b*(x-a),y+b*(E-y)),!0))},Ve:function(a,y,x,E,b,z,ee,re,oe){return yt.B(a,x)&&yt.B(y,E)?(oe.h(a,y),!1):yt.$(b,ee)?yt.$(a,x)?(yt.qh(a,y,x,E,b,z,oe),!1):yt.qh(a,y,x,E,b,(E-y)/(x-a)*(b-a)+y,oe):(re=(re-z)/(ee-b),yt.$(a,x)?(x=re*(a-b)+z,y<E?(b=y,y=E):b=E,x<b?(oe.h(a,b),!1):x>y?(oe.h(a,y),!1):(oe.h(a,x),!0)):(ee=(E-y)/(x-a),yt.$(re,ee)?(yt.qh(a,y,x,E,b,z,oe),!1):(b=(ee*a-re*b+z-y)/(ee-re),yt.$(ee,0)?(a<x?(E=a,a=x):E=x,b<E?(oe.h(E,y),!1):b>a?(oe.h(a,y),!1):(oe.h(b,y),!0)):yt.qh(a,y,x,E,b,ee*(b-a)+y,oe))))},MA:function(a,y,x,E,b){return yt.Ve(x.x,x.y,E.x,E.y,a.x,a.y,y.x,y.y,b)},KA:function(a,y,x,E,b,z,ee,re,oe,se){function ue(Ye,We){var tt=(Ye-a)*(Ye-a)+(We-y)*(We-y);tt<fe&&(fe=tt,oe.h(Ye,We))}var fe=1/0;ue(oe.x,oe.y);var ve=0,ye=0,Ce=0,Ae=0;if(b<ee?(ve=b,ye=ee):(ve=ee,ye=b),z<re?(Ce=b,Ae=ee):(Ce=ee,Ae=b),ve=(ye-ve)/2+se,se=(Ae-Ce)/2+se,b=(b+ee)/2,z=(z+re)/2,ve===0||se===0)return oe;if(.5>(x>a?x-a:a-x)){if(ve=1-(x-b)*(x-b)/(ve*ve),0>ve)return oe;ve=Math.sqrt(ve),E=-se*ve+z,ue(x,se*ve+z),ue(x,E)}else{if(x=(E-y)/(x-a),E=1/(ve*ve)+x*x/(se*se),re=2*x*(y-x*a)/(se*se)-2*x*z/(se*se)-2*b/(ve*ve),ve=re*re-4*E*(2*x*a*z/(se*se)-2*y*z/(se*se)+z*z/(se*se)+b*b/(ve*ve)-1+(y-x*a)*(y-x*a)/(se*se)),0>ve)return oe;ve=Math.sqrt(ve),se=(-re+ve)/(2*E),ue(se,x*se-x*a+y),ve=(-re-ve)/(2*E),ue(ve,x*ve-x*a+y)}return oe},Ff:function(a,y,x,E,b,z,ee,re,oe){var se=1e21,ue=a,fe=y;if(yt.Ve(a,y,a,E,b,z,ee,re,oe)){var ve=(oe.x-b)*(oe.x-b)+(oe.y-z)*(oe.y-z);ve<se&&(se=ve,ue=oe.x,fe=oe.y)}return yt.Ve(x,y,x,E,b,z,ee,re,oe)&&(ve=(oe.x-b)*(oe.x-b)+(oe.y-z)*(oe.y-z),ve<se&&(se=ve,ue=oe.x,fe=oe.y)),yt.Ve(a,y,x,y,b,z,ee,re,oe)&&(y=(oe.x-b)*(oe.x-b)+(oe.y-z)*(oe.y-z),y<se&&(se=y,ue=oe.x,fe=oe.y)),yt.Ve(a,E,x,E,b,z,ee,re,oe)&&(a=(oe.x-b)*(oe.x-b)+(oe.y-z)*(oe.y-z),a<se&&(se=a,ue=oe.x,fe=oe.y)),oe.h(ue,fe),1e21>se},us:function(a,y,x){return yt.Fx(a.x,a.y,a.width,a.height,y.x,y.y,x.x,x.y)},Fx:function(a,y,x,E,b,z,ee,re){var oe=a+x,se=y+E;return b===ee?(z<re?(ee=z,z=re):ee=re,a<=b&&b<=oe&&ee<=se&&z>=y):z===re?(b<ee?(re=b,b=ee):re=ee,y<=z&&z<=se&&re<=oe&&b>=a):!!(Ds(a,y,x,E,b,z)||Ds(a,y,x,E,ee,re)||yt.Rl(a,y,oe,y,b,z,ee,re)||yt.Rl(oe,y,oe,se,b,z,ee,re)||yt.Rl(oe,se,a,se,b,z,ee,re)||yt.Rl(a,se,a,y,b,z,ee,re))},Rl:function(a,y,x,E,b,z,ee,re){return a===x&&y===E&&b===ee&&z===re?a===b&&y===z:0>=yt.Fl(a,y,x,E,b,z)*yt.Fl(a,y,x,E,ee,re)&&0>=yt.Fl(b,z,ee,re,a,y)*yt.Fl(b,z,ee,re,x,E)},Fl:function(a,y,x,E,b,z){return x-=a,E-=y,a=b-a,y=z-y,z=a*E-y*x,z===0&&(z=a*x+y*E,0<z&&(z=(a-x)*x+(y-E)*E,0>z&&(z=0))),z},bp:function(a){return 0>a&&(a+=360),360<=a&&(a-=360),a},jx:function(a,y,x,E,b,z){var ee=Math.PI;z||(E*=ee/180,b*=ee/180);var re=E>b?-1:1;z=[];var oe=ee/2,se=E;if(E=Math.min(2*ee,Math.abs(b-E)),1e-5>E)return oe=se+re*Math.min(E,oe),re=a+x*Math.cos(se),se=y+x*Math.sin(se),a+=x*Math.cos(oe),y+=x*Math.sin(oe),x=(re+a)/2,oe=(se+y)/2,z.push([re,se,x,oe,x,oe,a,y]),z;for(;1e-5<E;)b=se+re*Math.min(E,oe),z.push(yt.Vy(x,se,b,a,y)),E-=Math.abs(b-se),se=b;return z},Vy:function(a,y,x,E,b){var z=(x-y)/2,ee=a*Math.cos(z),re=a*Math.sin(z),oe=-re,se=ee*ee+oe*oe,ue=se+ee*ee+oe*re;return se=4/3*(Math.sqrt(2*se*ue)-ue)/(ee*re-oe*ee),re=ee-se*oe,ee=oe+se*ee,oe=-ee,se=z+y,z=Math.cos(se),se=Math.sin(se),[E+a*Math.cos(y),b+a*Math.sin(y),E+re*z-ee*se,b+re*se+ee*z,E+re*z-oe*se,b+re*se+oe*z,E+a*Math.cos(x),b+a*Math.sin(x)]},No:function(a,y,x,E,b,z,ee){x=Math.floor((a-x)/b)*b+x,E=Math.floor((y-E)/z)*z+E;var re=x;return x+b-a<b/2&&(re=x+b),a=E,E+z-y<z/2&&(a=E+z),ee.h(re,a),ee},vx:function(a,y){var x=Math.max(a,y);a=Math.min(a,y);var E;do y=x%a,x=E=a,a=y;while(0<y);return E},$y:function(a,y,x,E){var b=0>x,z=0>E;if(a<y)var ee=1,re=0;else ee=0,re=1;var oe=ee===0?a:y,se=ee===0?x:E;return(ee===0?b:z)&&(se=-se),ee=re,x=ee===0?x:E,(ee===0?b:z)&&(x=-x),yt.az(oe,ee===0?a:y,se,x,0,0)},az:function(a,y,x,E,b,z){if(0<E)if(0<x){b=a*a,z=y*y,a*=x;var ee=y*E,re=-z+ee,oe=-z+Math.sqrt(a*a+ee*ee);y=re;for(var se=0;9999999999>se&&(y=.5*(re+oe),!(y===re||y===oe));++se){var ue=a/(y+b),fe=ee/(y+z);if(ue=ue*ue+fe*fe-1,0<ue)re=y;else if(0>ue)oe=y;else break}x=b*x/(y+b)-x,E=z*E/(y+z)-E,x=Math.sqrt(x*x+E*E)}else x=Math.abs(E-y);else E=a*a-y*y,z=a*x,z<E?(E=z/E,z=y*Math.sqrt(Math.abs(1-E*E)),x=a*E-x,x=Math.sqrt(x*x+z*z)):x=Math.abs(x-a);return x},Ze:new Er,um:new Er,Mf:new Er,Nf:0,vm:100};yt.za=yt.AA;function Bn(a){jo(this),this.l=2,a===void 0&&(a=Bn.o),this.na=a,this.Ec=this.Dc=this.pd=this.od=0,a===Bn.o?this.ee=new An:(Bn.V===null&&(Bn.V=new An().freeze()),this.ee=Bn.V),this.aq=this.ee.Ja,this.Ip=new Xt().freeze(),this.ym=this.tk=null,this.zm=NaN,this.fg=Cs,this.gg=Hl,this.Rk=this.Sk=NaN,this.Uf=Cn}Bn.prototype.copy=function(){var a=new Bn;if(a.l=this.l&-2,a.na=this.na,a.od=this.od,a.pd=this.pd,a.Dc=this.Dc,a.Ec=this.Ec,this.na===Bn.o){for(var y=this.ee.s,x=a.ee,E=0;E<y.length;E++)x.add(y[E].copy());a.ee=x}else a.ee=this.ee;return a.aq=this.aq,a.Ip.assign(this.Ip),a.tk=this.tk,a.ym=this.ym,a.zm=this.zm,a.fg=this.fg.J(),a.gg=this.gg.J(),a.Sk=this.Sk,a.Rk=this.Rk,a.Uf=this.Uf,a},Bn.prototype.ja=function(){return this.freeze(),Object.freeze(this),this},Bn.prototype.freeze=function(){if(this._isFrozen=!0,this.type!==Bn.o)return this;var a=this.figures;a.freeze(),a=a.s;for(var y=a.length,x=0;x<y;x++)a[x].freeze();return this},Bn.prototype.ka=function(){if(Object.isFrozen(this)&&Dt("cannot thaw constant: "+this),this._isFrozen=!1,this.type!==Bn.o)return this;var a=this.figures;a.ka(),a=a.s;for(var y=a.length,x=0;x<y;x++)a[x].ka();return this},Bn.prototype.Xa=function(a){if(!(a instanceof Bn))return!1;if(this.type!==a.type)return this.type===Bn.j&&a.type===Bn.o?Kl(this,a):a.type===Bn.j&&this.type===Bn.o?Kl(a,this):!1;if(this.type===Bn.o){var y=this.figures.s;a=a.figures.s;var x=y.length;if(x!==a.length)return!1;for(var E=0;E<x;E++)if(!y[E].Xa(a[E]))return!1;return!0}return yt.B(this.startX,a.startX)&&yt.B(this.startY,a.startY)&&yt.B(this.endX,a.endX)&&yt.B(this.endY,a.endY)};function Kl(a,y){return a.type!==Bn.j||y.type!==Bn.o?!1:!!(y.figures.count===1&&(y=y.figures.M(0),y.segments.count===1&&yt.B(a.startX,y.startX)&&yt.B(a.startY,y.startY)&&(y=y.segments.M(0),y.type===fi&&yt.B(a.endX,y.endX)&&yt.B(a.endY,y.endY))))}Bn.ia=function(a){return a.toString()},Bn.prototype.qb=function(a){a.classType===Bn&&(this.type=a)},Bn.prototype.toString=function(a){switch(a===void 0&&(a=-1),this.type){case Bn.j:return 0>a?"M"+this.startX.toString()+" "+this.startY.toString()+"L"+this.endX.toString()+" "+this.endY.toString():"M"+this.startX.toFixed(a)+" "+this.startY.toFixed(a)+"L"+this.endX.toFixed(a)+" "+this.endY.toFixed(a);case Bn.u:var y=new Xt(this.startX,this.startY,0,0);return y.Kv(this.endX,this.endY,0,0),0>a?"M"+y.x.toString()+" "+y.y.toString()+"H"+y.right.toString()+"V"+y.bottom.toString()+"H"+y.left.toString()+"z":"M"+y.x.toFixed(a)+" "+y.y.toFixed(a)+"H"+y.right.toFixed(a)+"V"+y.bottom.toFixed(a)+"H"+y.left.toFixed(a)+"z";case Bn.F:if(y=new Xt(this.startX,this.startY,0,0),y.Kv(this.endX,this.endY,0,0),0>a)return a=y.left.toString()+" "+(y.y+y.height/2).toString(),"M"+a+"A"+(y.width/2).toString()+" "+(y.height/2).toString()+" 0 0 1 "+(y.right.toString()+" "+(y.y+y.height/2).toString())+"A"+(y.width/2).toString()+" "+(y.height/2).toString()+" 0 0 1 "+a;var x=y.left.toFixed(a)+" "+(y.y+y.height/2).toFixed(a);return"M"+x+"A"+(y.width/2).toFixed(a)+" "+(y.height/2).toFixed(a)+" 0 0 1 "+(y.right.toFixed(a)+" "+(y.y+y.height/2).toFixed(a))+"A"+(y.width/2).toFixed(a)+" "+(y.height/2).toFixed(a)+" 0 0 1 "+x;case Bn.o:y="",x=this.figures.s;for(var E=x.length,b=0;b<E;b++){var z=x[b];0<b&&(y+=" x "),z.isFilled&&(y+="F "),y+=z.toString(a)}return y;default:return this.type.toString()}},Bn.nb=function(a){a=a.split(/[Xx]/);for(var y=a.length,x="",E=0;E<y;E++){var b=a[E];x=b.match(/[Ff]/)!==null?E===0?x+b:x+("X"+(b[0]===" "?"":" ")+b):x+((E===0?"":"X ")+"F"+(b[0]===" "?"":" ")+b)}return x},Bn.parse=function(a,y){function x(){return Ae>=at-1?!0:se[Ae+1].match(gt)!==null}function E(){return Ae++,se[Ae]}function b(yr){var sr=parseFloat(E()),Io=parseFloat(E());Ye===Ye.toLowerCase()&&(sr=rt.x+sr,Io=rt.y+Io),yr.h(sr,Io)}function z(){return b(rt),rt}function ee(){return b(tt),tt}function re(){var yr=We.toLowerCase();return yr!=="c"&&yr!=="s"&&yr!=="q"&&yr!=="t"?rt:new Qe(2*rt.x-tt.x,2*rt.y-tt.y)}y===void 0&&(y=!1);var oe=/([UuBbMmZzLlHhVvCcSsQqTtAaFfXx])([UuBbMmZzLlHhVvCcSsQqTtAaFfXx])/gm;a=a.replace(/,/gm," "),a=a.replace(oe,"$1 $2"),a=a.replace(oe,"$1 $2"),a=a.replace(/([UuBbMmZzLlHhVvCcSsQqTtAaFfXx])([^s])/gm,"$1 $2"),a=a.replace(/([^s])([UuBbMmZzLlHhVvCcSsQqTtAaFfXx])/gm,"$1 $2"),a=a.replace(/([0-9])([+\-])/gm,"$1 $2"),a=a.replace(/[\s\r\t\n]+/gm," "),a=a.replace(/^\s+|\s+$/g,"");var se=a.split(" ");for(a=0;a<se.length;a++){var ue=se[a];if(ue.match(/(\.[0-9]*)(\.)/gm)!==null){oe=qi();for(var fe="",ve=!1,ye=0;ye<ue.length;ye++){var Ce=ue[ye];Ce!=="."||ve?Ce==="."?(oe.push(fe),fe="."):fe+=Ce:(ve=!0,fe+=Ce)}for(oe.push(fe),se.splice(a,1),ue=0;ue<oe.length;ue++)se.splice(a+ue,0,oe[ue]);a+=oe.length-1,Zi(oe)}}var Ae=-1,Ye="",We="";oe=new Qe(0,0);var tt=new Qe(0,0),rt=new Qe(0,0),at=se.length;a=AS(null),ve=fe=ue=!1,ye=!0,Ce=null;for(var gt=/[UuBbMmZzLlHhVvCcSsQqTtAaFfXx]/;!(Ae>=at-1);)if(We=Ye,Ye=E(),Ye!=="")switch(Ye.toUpperCase()){case"X":ye=!0,fe=ue=!1;break;case"M":for(Ce=z(),a.mc===null||ye===!0?(Mg(a,Ce.x,Ce.y,ue,!fe,ve),ye=!1):a.moveTo(Ce.x,Ce.y),oe.assign(rt);!x();)Ce=z(),a.lineTo(Ce.x,Ce.y);break;case"L":for(;!x();)Ce=z(),a.lineTo(Ce.x,Ce.y);break;case"H":for(;!x();)rt=new Qe((Ye===Ye.toLowerCase()?rt.x:0)+parseFloat(E()),rt.y),a.lineTo(rt.x,rt.y);break;case"V":for(;!x();)rt=new Qe(rt.x,(Ye===Ye.toLowerCase()?rt.y:0)+parseFloat(E())),a.lineTo(rt.x,rt.y);break;case"C":for(;!x();){Ce=new Qe,b(Ce);var At=ee(),Zn=z();Pd(a,Ce.x,Ce.y,At.x,At.y,Zn.x,Zn.y)}break;case"S":for(;!x();)Ce=re(),At=ee(),Zn=z(),Pd(a,Ce.x,Ce.y,At.x,At.y,Zn.x,Zn.y);break;case"Q":for(;!x();)Ce=ee(),At=z(),Gm(a,Ce.x,Ce.y,At.x,At.y);break;case"T":for(;!x();)tt=Ce=re(),At=z(),Gm(a,Ce.x,Ce.y,At.x,At.y);break;case"B":for(;!x();){Ce=parseFloat(E()),At=parseFloat(E()),Zn=parseFloat(E());var mi=parseFloat(E()),si=parseFloat(E()),Nn=si,pn=!1;x()||(Nn=parseFloat(E()),x()||(pn=parseFloat(E())!==0)),Ye===Ye.toLowerCase()&&(Zn+=rt.x,mi+=rt.y),a.arcTo(Ce,At,Zn,mi,si,Nn,pn)}break;case"A":for(;!x();)Ce=Math.abs(parseFloat(E())),At=Math.abs(parseFloat(E())),Zn=parseFloat(E()),si=mi=!1,pn=Nn=0,Nn=E(),Nn.length===1?(mi=!!parseFloat(Nn),si=!!parseFloat(E()),Nn=parseFloat(E())):Nn.length===2?(mi=!!parseFloat(Nn[0]),si=!!parseFloat(Nn[1]),Nn=parseFloat(E())):(mi=!!parseFloat(Nn[0]),si=!!parseFloat(Nn[1]),Nn=parseFloat(Nn.slice(2))),pn=parseFloat(E()),Ye===Ye.toLowerCase()&&(Nn=rt.x+Nn,pn=rt.y+pn),rt.h(Nn,pn),Px(a,Ce,At,Zn,mi,si,Nn,pn);break;case"Z":wx(a),rt.assign(oe);break;case"F":for(Ce="",At=1;se[Ae+At];)if(se[Ae+At]==="0")ve=!0,At++;else if(se[Ae+At].match(/[Uu]/)!==null)At++;else if(se[Ae+At].match(gt)===null)At++;else{Ce=se[Ae+At];break}Ce.match(/[Mm]/)?ue=!0:0<a.mc.segments.length&&(a.mc.isFilled=!0);break;case"U":for(Ce="",At=1;se[Ae+At];)if(se[Ae+At].match(/[Ff]/)!==null)At++;else if(se[Ae+At].match(gt)===null)At++;else{Ce=se[Ae+At];break}Ce.match(/[Mm]/)?fe=!0:a.mc.isShadowed=!1}if(oe=a.os,Km=a,y)for(y=oe.figures.iterator;y.next();)y.value.isFilled=!0;return oe},Bn.Ha=function(a,y){for(var x=a.length,E=Qe.alloc(),b=0;b<x;b++){var z=a[b];E.x=z[0],E.y=z[1],y.Ga(E),z[0]=E.x,z[1]=E.y,E.x=z[2],E.y=z[3],y.Ga(E),z[2]=E.x,z[3]=E.y,E.x=z[4],E.y=z[5],y.Ga(E),z[4]=E.x,z[5]=E.y,E.x=z[6],E.y=z[7],y.Ga(E),z[6]=E.x,z[7]=E.y}Qe.free(E)},Bn.prototype.Zu=function(){if(this._isInvalidBounds)return!0;if(this.type===Bn.o){if(this.aq!==this.figures.Ja)return!0;for(var a=this.figures.s,y=a.length,x=0;x<y;x++)if(a[x].Zu())return!0}return!1},Bn.prototype.computeBounds=function(){if(this._isInvalidBounds=!1,this.ym=this.tk=null,this.zm=NaN,this.type===Bn.o){this.aq=this.figures.Ja;for(var a=this.figures.s,y=a.length,x=0;x<y;x++){var E=a[x];E._isInvalidBounds=!1;var b=E.segments;E.sr=b.Ja,E=b.s,b=E.length;for(var z=0;z<b;z++){var ee=E[z];ee._isInvalidBounds=!1,ee.ae=null}}}a=this.Ip,a.ka(),isNaN(this.Sk)||isNaN(this.Rk)?a.h(0,0,0,0):a.h(0,0,this.Sk,this.Rk),ch(this,a,!1),es(a,0,0,0,0),a.freeze()},Bn.prototype.ix=function(){var a=new Xt;return ch(this,a,!0),a};function ch(a,y,x){switch(a.type){case Bn.j:case Bn.u:case Bn.F:x?y.h(a.od,a.pd,0,0):es(y,a.od,a.pd,0,0),es(y,a.Dc,a.Ec,0,0);break;case Bn.o:var E=a.figures;a=E.s,E=E.length;for(var b=0;b<E;b++){var z=a[b];x&&b===0?y.h(z.startX,z.startY,0,0):es(y,z.startX,z.startY,0,0);for(var ee=z.segments.s,re=ee.length,oe=z.startX,se=z.startY,ue=0;ue<re;ue++){var fe=ee[ue];switch(fe.type){case fi:case xs:oe=fe.endX,se=fe.endY,es(y,oe,se,0,0);break;case po:yt.Dl(oe,se,fe.point1X,fe.point1Y,fe.point2X,fe.point2Y,fe.endX,fe.endY,.5,y),oe=fe.endX,se=fe.endY;break;case Vo:yt.iv(oe,se,fe.point1X,fe.point1Y,fe.endX,fe.endY,.5,y),oe=fe.endX,se=fe.endY;break;case qo:case Ja:var ve=fe.type===qo?Bl(fe,z):Pl(fe,z,oe,se),ye=ve.length;if(ye===0){oe=fe.type===qo?fe.centerX:fe.endX,se=fe.type===qo?fe.centerY:fe.endY,es(y,oe,se,0,0);break}fe=null;for(var Ce=0;Ce<ye;Ce++)fe=ve[Ce],yt.Dl(fe[0],fe[1],fe[2],fe[3],fe[4],fe[5],fe[6],fe[7],.5,y);fe!==null&&(oe=fe[6],se=fe[7]);break;default:Dt("Unknown Segment type: "+fe.type)}}}break;default:Dt("Unknown Geometry type: "+a.type)}}Bn.prototype.normalize=function(){this._isFrozen&&wi(this);var a=this.ix();return this.offset(-a.x,-a.y),new Qe(-a.x,-a.y)},Bn.prototype.offset=function(a,y){return this._isFrozen&&wi(this),this.transform(1,0,0,1,a,y),this},Bn.prototype.scale=function(a,y){return this._isFrozen&&wi(this),this.transform(a,0,0,y,0,0),this},Bn.prototype.rotate=function(a,y,x){this._isFrozen&&wi(this),y===void 0&&(y=0),x===void 0&&(x=0);var E=kr.alloc();return E.reset(),E.rotate(a,y,x),this.transform(E.m11,E.m12,E.m21,E.m22,E.dx,E.dy),kr.free(E),this},we=Bn.prototype,we.transform=function(a,y,x,E,b,z){switch(this.type){case Bn.j:case Bn.u:case Bn.F:var ee=this.od,re=this.pd;this.od=ee*a+re*x+b,this.pd=ee*y+re*E+z,ee=this.Dc,re=this.Ec,this.Dc=ee*a+re*x+b,this.Ec=ee*y+re*E+z;break;case Bn.o:for(var oe=this.figures.s,se=oe.length,ue=0;ue<se;ue++){var fe=oe[ue];ee=fe.startX,re=fe.startY,fe.startX=ee*a+re*x+b,fe.startY=ee*y+re*E+z,fe=fe.segments.s;for(var ve=fe.length,ye=0;ye<ve;ye++){var Ce=fe[ye];switch(Ce.type){case fi:case xs:ee=Ce.endX,re=Ce.endY,Ce.endX=ee*a+re*x+b,Ce.endY=ee*y+re*E+z;break;case po:ee=Ce.point1X,re=Ce.point1Y,Ce.point1X=ee*a+re*x+b,Ce.point1Y=ee*y+re*E+z,ee=Ce.point2X,re=Ce.point2Y,Ce.point2X=ee*a+re*x+b,Ce.point2Y=ee*y+re*E+z,ee=Ce.endX,re=Ce.endY,Ce.endX=ee*a+re*x+b,Ce.endY=ee*y+re*E+z;break;case Vo:ee=Ce.point1X,re=Ce.point1Y,Ce.point1X=ee*a+re*x+b,Ce.point1Y=ee*y+re*E+z,ee=Ce.endX,re=Ce.endY,Ce.endX=ee*a+re*x+b,Ce.endY=ee*y+re*E+z;break;case qo:ee=Ce.centerX,re=Ce.centerY,Ce.centerX=ee*a+re*x+b,Ce.centerY=ee*y+re*E+z,y!==0&&(ee=180*Math.atan2(y,a)/Math.PI,0>ee&&(ee+=360),Ce.startAngle+=ee),0>a&&(Ce.startAngle=180-Ce.startAngle,Ce.sweepAngle=-Ce.sweepAngle),0>E&&(Ce.startAngle=-Ce.startAngle,Ce.sweepAngle=-Ce.sweepAngle),Ce.radiusX*=Math.sqrt(a*a+x*x),Ce.radiusY!==void 0&&(Ce.radiusY*=Math.sqrt(y*y+E*E));break;case Ja:if(ee=Ce.endX,re=Ce.endY,Ce.endX=ee*a+re*x+b,Ce.endY=ee*y+re*E+z,Ce.radiusX===0||Ce.radiusY===0)break;y!==0&&(ee=180*Math.atan2(y,a)/Math.PI,0>ee&&(ee+=360),Ce.xAxisRotation+=ee),0>a&&(Ce.xAxisRotation=180-Ce.xAxisRotation,Ce.isClockwiseArc=!Ce.isClockwiseArc),0>E&&(Ce.xAxisRotation=-Ce.xAxisRotation,Ce.isClockwiseArc=!Ce.isClockwiseArc),Ce.radiusX*=Math.sqrt(a*a+x*x),Ce.radiusY*=Math.sqrt(y*y+E*E);break;default:Dt("Unknown Segment type: "+Ce.type)}}}}return this._isInvalidBounds=!0,this},we.ca=function(a,y){y===void 0&&(y=0);var x=this.od,E=this.pd,b=this.Dc,z=this.Ec;switch(this.type){case Bn.j:return yt.Yb(x,E,b,z,y,a.x,a.y);case Bn.u:var ee=Xt.allocAt(Math.min(x,b)-y,Math.min(E,z)-y,Math.abs(b-x)+2*y,Math.abs(z-E)+2*y);return a=ee.ca(a),Xt.free(ee),a;case Bn.F:ee=Math.min(x,b)-y;var re=Math.min(E,z)-y;return x=(Math.abs(b-x)+2*y)/2,y=(Math.abs(z-E)+2*y)/2,0>=x||0>=y?!1:(ee=a.x-(ee+x),re=a.y-(re+y),1>=ee*ee/(x*x)+re*re/(y*y));case Bn.o:return $u(this,a,y,!0,!1);default:return!1}};function $u(a,y,x,E,b){var z=y.x;y=y.y;for(var ee=a.bounds.x-20,re=0,oe,se,ue,fe,ve=a.figures.s,ye=ve.length,Ce=0;Ce<ye;Ce++){var Ae=ve[Ce],Ye=!Ae.isEvenOdd;if(Ae.isFilled){if(E&&Ae.ca(z,y,x))return!0;var We=Ae.segments;oe=Ae.startX,se=Ae.startY;for(var tt=oe,rt=se,at=We.s,gt=0;gt<=We.length;gt++){var At=void 0;if(gt!==We.length){At=at[gt];var Zn=At.type;a=At.endX,fe=At.endY}else Zn=fi,a=tt,fe=rt;switch(Zn){case xs:if(tt=Nu(z,y,ee,y,oe,se,tt,rt),isNaN(tt))return!0;re+=tt,tt=a,rt=fe;break;case fi:if(oe=Nu(z,y,ee,y,oe,se,a,fe),isNaN(oe))return!0;re+=oe;break;case po:ue=yt.Fo(oe,se,At.point1X,At.point1Y,At.point2X,At.point2Y,a,fe,ee,y,z,y,.5),re+=ue;break;case Vo:ue=yt.Fo(oe,se,(oe+2*At.point1X)/3,(se+2*At.point1Y)/3,(2*At.point1X+a)/3,(2*At.point1Y+fe)/3,a,fe,ee,y,z,y,.5),re+=ue;break;case qo:case Ja:Zn=At.type===qo?Bl(At,Ae):Pl(At,Ae,oe,se);var mi=Zn.length;if(mi===0){if(oe=Nu(z,y,ee,y,oe,se,At.type===qo?At.centerX:At.endX,At.type===qo?At.centerY:At.endY),isNaN(oe))return!0;re+=oe;break}At=null;for(var si=0;si<mi;si++){if(At=Zn[si],si===0){if(ue=Nu(z,y,ee,y,oe,se,At[0],At[1]),isNaN(ue))return!0;re+=ue}ue=yt.Fo(At[0],At[1],At[2],At[3],At[4],At[5],At[6],At[7],ee,y,z,y,.5),re+=ue}At!==null&&(a=At[6],fe=At[7]);break;default:Dt("Unknown Segment type: "+At.type)}oe=a,se=fe}if(Ye){if(re!==0)return!0}else if(re%2!==0)return!0;re=0}else if(Ae.ca(z,y,b?x:x+2))return!0}return!1}function Nu(a,y,x,E,b,z,ee,re){if(yt.Yb(b,z,ee,re,.05,a,y))return NaN;var oe=(a-x)*(z-re);if(oe===0)return 0;var se=((a*E-y*x)*(b-ee)-(a-x)*(b*re-z*ee))/oe;if(y=(a*E-y*x)*(z-re)/oe,se>=a)return 0;if((b>ee?b-ee:ee-b)<(z>re?z-re:re-z)){if(z<re){if(y<z||y>re)return 0}else if(y<re||y>z)return 0}else if(b<ee){if(se<b||se>ee)return 0}else if(se<ee||se>b)return 0;return 0<oe?1:-1}function Tu(a,y,x,E){a=a.figures.s;for(var b=a.length,z=0;z<b;z++)if(a[z].ca(y,x,E))return!0;return!1}we.Pu=function(a,y){if(0>a?a=0:1<a&&(a=1),y===void 0&&(y=new Qe),this.type===Bn.j)return y.h(this.startX+a*(this.endX-this.startX),this.startY+a*(this.endY-this.startY)),y;for(var x=this.flattenedSegments,E=this.flattenedLengths,b=x.length,z=this.flattenedTotalLength*a,ee=0,re=0;re<b;re++){var oe=E[re],se=oe.length;for(a=0;a<se;a++){var ue=oe[a];if(ee+ue>=z)return E=z-ee,E=ue===0?0:E/ue,x=x[re],re=x[2*a],b=x[2*a+1],y.h(re+(x[2*a+2]-re)*E,b+(x[2*a+3]-b)*E),y;ee+=ue}}return y},we.wx=function(a){if(0>a?a=0:1<a&&(a=1),this.type===Bn.j)return 180*Math.atan2(this.endY-this.startY,this.endX-this.startX)/Math.PI;for(var y=this.flattenedSegments,x=this.flattenedLengths,E=y.length,b=this.flattenedTotalLength*a,z=0,ee=0;ee<E;ee++){var re=x[ee],oe=re.length;for(a=0;a<oe;a++){var se=re[a];if(z+se>=b)return b=y[ee],y=b[2*a],x=b[2*a+1],E=b[2*a+2],a=b[2*a+3],1>Math.abs(E-y)&&1>Math.abs(a-x)?0:1>Math.abs(E-y)?0<=a-x?90:270:1>Math.abs(a-x)?0<=E-y?0:180:180*Math.atan2(a-x,E-y)/Math.PI;z+=se}}return NaN},we.Qu=function(a,y){if(0>a?a=0:1<a&&(a=1),y===void 0&&(y=[]),y.length=3,this.type===Bn.j)return y[0]=this.startX+a*(this.endX-this.startX),y[1]=this.startY+a*(this.endY-this.startY),y[2]=180*Math.atan2(this.endY-this.startY,this.endX-this.startX)/Math.PI,y;for(var x=this.flattenedSegments,E=this.flattenedLengths,b=x.length,z=this.flattenedTotalLength*a,ee=0,re=0;re<b;re++){var oe=E[re],se=oe.length;for(a=0;a<se;a++){var ue=oe[a];if(ee+ue>=z)return E=z-ee,E=ue===0?0:E/ue,ue=x[re],x=ue[2*a],re=ue[2*a+1],b=ue[2*a+2],a=ue[2*a+3],y[0]=x+(b-x)*E,y[1]=re+(a-re)*E,y[2]=1>Math.abs(b-x)&&1>Math.abs(a-re)?0:1>Math.abs(b-x)?0<=a-re?90:270:1>Math.abs(a-re)?0<=b-x?0:180:180*Math.atan2(a-re,b-x)/Math.PI,y;ee+=ue}}return y},we.xx=function(a){if(this.type===Bn.j){var y=this.startX,x=this.startY,E=this.endX,b=this.endY;if(y!==E||x!==b){var z=a.x;if(a=a.y,y===E){if(x<b){var ee=x;E=b}else ee=b,E=x;return a<=ee?ee===x?0:1:a>=E?E===x?0:1:Math.abs(a-x)/(E-ee)}if(x===b)return y<E?ee=y:(ee=E,E=y),z<=ee?ee===y?0:1:z>=E?E===y?0:1:Math.abs(z-y)/(E-ee);ee=(E-y)*(E-y)+(b-x)*(b-x);var re=Qe.alloc();return yt.qh(y,x,E,b,z,a,re),a=re.x,z=re.y,Qe.free(re),Math.sqrt(((a-y)*(a-y)+(z-x)*(z-x))/ee)}}else if(this.type===Bn.u){ee=this.startX,re=this.startY;var oe=this.endX;if(b=this.endY,ee!==oe||re!==b){y=oe-ee,x=b-re,z=2*y+2*x,E=a.x,a=a.y,E=Math.min(Math.max(E,ee),oe),a=Math.min(Math.max(a,re),b),ee=Math.abs(E-ee),oe=Math.abs(E-oe),re=Math.abs(a-re),b=Math.abs(a-b);var se=Math.min(ee,oe,re,b);if(se===re)return E/z;if(se===oe)return(y+a)/z;if(se===b)return(2*y+x-E)/z;if(se===ee)return(2*y+2*x-a)/z}}else{y=this.flattenedSegments,x=this.flattenedLengths,z=this.flattenedTotalLength,E=Qe.alloc(),b=1/0,re=ee=0,oe=y.length;for(var ue=se=0,fe=0;fe<oe;fe++)for(var ve=y[fe],ye=x[fe],Ce=ve.length,Ae=0;Ae<Ce;Ae+=2){var Ye=ve[Ae],We=ve[Ae+1];if(Ae!==0){yt.qh(se,ue,Ye,We,a.x,a.y,E);var tt=(E.x-a.x)*(E.x-a.x)+(E.y-a.y)*(E.y-a.y);tt<b&&(b=tt,ee=re,ee+=Math.sqrt((E.x-se)*(E.x-se)+(E.y-ue)*(E.y-ue))),re+=ye[(Ae-2)/2]}se=Ye,ue=We}return Qe.free(E),a=ee/z,0>a?0:1<a?1:a}return 0};function Wh(a){if(a.tk===null){var y=a.tk=[],x=a.ym=[],E=[],b=[];if(a.type===Bn.j)E.push(a.startX),E.push(a.startY),E.push(a.endX),E.push(a.endY),y.push(E),b.push(Math.sqrt((a.startX-a.endX)*(a.startX-a.endX)+(a.startY-a.endY)*(a.startY-a.endY))),x.push(b);else if(a.type===Bn.u)E.push(a.startX),E.push(a.startY),E.push(a.endX),E.push(a.startY),E.push(a.endX),E.push(a.endY),E.push(a.startX),E.push(a.endY),E.push(a.startX),E.push(a.startY),y.push(E),b.push(Math.abs(a.startX-a.endX)),b.push(Math.abs(a.startY-a.endY)),b.push(Math.abs(a.startX-a.endX)),b.push(Math.abs(a.startY-a.endY)),x.push(b);else if(a.type===Bn.F){var z=new Ns;z.startX=a.endX,z.startY=(a.startY+a.endY)/2;var ee=new to(qo);if(ee.startAngle=0,ee.sweepAngle=360,ee.centerX=(a.startX+a.endX)/2,ee.centerY=(a.startY+a.endY)/2,ee.radiusX=Math.abs(a.startX-a.endX)/2,ee.radiusY=Math.abs(a.startY-a.endY)/2,z.add(ee),a=Bl(ee,z),b=a.length,b===0)E.push(ee.centerX),E.push(ee.centerY);else{ee=z.startX,z=z.startY;for(var re=0;re<b;re++){var oe=a[re];yt.Qe(ee,z,oe[2],oe[3],oe[4],oe[5],oe[6],oe[7],.5,E),ee=oe[6],z=oe[7]}}y.push(E),x.push(Du(E))}else for(a=a.figures.iterator;a.next();){b=a.value,E=[],E.push(b.startX),E.push(b.startY),ee=b.startX,z=b.startY,re=ee,oe=z;for(var se=b.segments.s,ue=se.length,fe=0;fe<ue;fe++){var ve=se[fe];switch(ve.type){case xs:4<=E.length&&(y.push(E),x.push(Du(E))),E=[],E.push(ve.endX),E.push(ve.endY),ee=ve.endX,z=ve.endY,re=ee,oe=z;break;case fi:E.push(ve.endX),E.push(ve.endY),ee=ve.endX,z=ve.endY;break;case po:yt.Qe(ee,z,ve.point1X,ve.point1Y,ve.point2X,ve.point2Y,ve.endX,ve.endY,.5,E),ee=ve.endX,z=ve.endY;break;case Vo:yt.ep(ee,z,ve.point1X,ve.point1Y,ve.endX,ve.endY,.5,E),ee=ve.endX,z=ve.endY;break;case qo:var ye=Bl(ve,b),Ce=ye.length;if(Ce===0){E.push(ve.centerX),E.push(ve.centerY),ee=ve.centerX,z=ve.centerY;break}for(var Ae=0;Ae<Ce;Ae++){var Ye=ye[Ae];yt.Qe(ee,z,Ye[2],Ye[3],Ye[4],Ye[5],Ye[6],Ye[7],.5,E),ee=Ye[6],z=Ye[7]}break;case Ja:if(ye=Pl(ve,b,ee,z),Ce=ye.length,Ae=ve.endX,Ye=ve.endY,Ce===0){E.push(Ae),E.push(Ye),ee=Ae,z=Ye;break}for(Ae=0;Ae<Ce;Ae++)Ye=ye[Ae],yt.Qe(ee,z,Ye[2],Ye[3],Ye[4],Ye[5],Ye[6],Ye[7],.5,E),ee=Ye[6],z=Ye[7];break;default:Dt("Segment not of valid type: "+ve.type)}ve.isClosed&&(E.push(re),E.push(oe))}4<=E.length&&(y.push(E),x.push(Du(E)))}}}function Du(a){for(var y=[],x=0,E=0,b=a.length,z=0;z<b;z+=2){var ee=a[z],re=a[z+1];z!==0&&y.push(Math.sqrt(Or(x,E,ee,re))),x=ee,E=re}return y}we.add=function(a){return this.ee.add(a),this},we.pm=function(a,y,x,E,b,z,ee,re){return this._isFrozen&&wi(this),this.fg=new Bi(a,y,b,z).freeze(),this.gg=new Bi(x,E,ee,re).freeze(),this},Yt.Object.defineProperties(Bn.prototype,{_isFrozen:{get:function(){return(this.l&1)!==0},set:function(a){this.l=a?this.l|1:this.l&-2}},_isInvalidBounds:{get:function(){return(this.l&2)!==0},set:function(a){this.l=a?this.l|2:this.l&-3}},flattenedSegments:{get:function(){return Wh(this),this.tk}},flattenedLengths:{get:function(){return Wh(this),this.ym}},flattenedTotalLength:{get:function(){var a=this.zm;if(isNaN(a)){if(this.type===Bn.j){a=Math.abs(this.endX-this.startX);var y=Math.abs(this.endY-this.startY);a=Math.sqrt(a*a+y*y)}else if(this.type===Bn.u)a=2*Math.abs(this.endX-this.startX)+2*Math.abs(this.endY-this.startY);else{y=this.flattenedLengths;for(var x=y.length,E=a=0;E<x;E++)for(var b=y[E],z=b.length,ee=0;ee<z;ee++)a+=b[ee]}this.zm=a}return a}},type:{get:function(){return this.na},set:function(a){this.na!==a&&(this._isFrozen&&wi(this,a),this.na=a,a===Bn.o?this.ee=new An:(Bn.V===null&&(Bn.V=new An().freeze()),this.ee=Bn.V),this._isInvalidBounds=!0)}},startX:{get:function(){return this.od},set:function(a){this.od!==a&&(this._isFrozen&&wi(this,a),this.od=a,this._isInvalidBounds=!0)}},startY:{get:function(){return this.pd},set:function(a){this.pd!==a&&(this._isFrozen&&wi(this,a),this.pd=a,this._isInvalidBounds=!0)}},endX:{get:function(){return this.Dc},set:function(a){this.Dc!==a&&(this._isFrozen&&wi(this,a),this.Dc=a,this._isInvalidBounds=!0)}},endY:{get:function(){return this.Ec},set:function(a){this.Ec!==a&&(this._isFrozen&&wi(this,a),this.Ec=a,this._isInvalidBounds=!0)}},figures:{get:function(){return this.ee},set:function(a){this.ee!==a&&(this._isFrozen&&wi(this,a),this.ee=a,this._isInvalidBounds=!0)}},spot1:{get:function(){return this.fg},set:function(a){this._isFrozen&&wi(this,a),this.fg=a.J()}},spot2:{get:function(){return this.gg},set:function(a){this._isFrozen&&wi(this,a),this.gg=a.J()}},defaultStretch:{get:function(){return this.Uf},set:function(a){this._isFrozen&&wi(this,a),this.Uf=a}},bounds:{get:function(){return this.Zu()&&this.computeBounds(),this.Ip}}}),Bn.prototype.setSpots=Bn.prototype.pm,Bn.prototype.add=Bn.prototype.add,Bn.prototype.getFractionForPoint=Bn.prototype.xx,Bn.prototype.getPointAndAngleAlongPath=Bn.prototype.Qu,Bn.prototype.getAngleAlongPath=Bn.prototype.wx,Bn.prototype.getPointAlongPath=Bn.prototype.Pu,Bn.prototype.containsPoint=Bn.prototype.ca,Bn.prototype.transform=Bn.prototype.transform,Bn.prototype.rotate=Bn.prototype.rotate,Bn.prototype.scale=Bn.prototype.scale,Bn.prototype.offset=Bn.prototype.offset,Bn.prototype.normalize=Bn.prototype.normalize,Bn.prototype.computeBoundsWithoutOrigin=Bn.prototype.ix,Bn.prototype.equalsApprox=Bn.prototype.Xa,Bn.className="Geometry",Bn.j=new Vt(Bn,"Line",0),Bn.u=new Vt(Bn,"Rectangle",1),Bn.F=new Vt(Bn,"Ellipse",2),Bn.o=new Vt(Bn,"Path",3),Bn.V=null,Bn.hb="UuBbMmZzLlHhVvCcSsQqTtAaFfXx",Bn.className="Geometry",Bn.stringify=Bn.ia,Bn.fillPath=Bn.nb,Bn.parse=Bn.parse,Bn.Line=Bn.j,Bn.Rectangle=Bn.u,Bn.Ellipse=Bn.F,Bn.Path=Bn.o;function Ns(a,y,x,E,b){jo(this),x===void 0&&(x=!0),E===void 0&&(E=!0),b===void 0&&(b=!1),this.l=2|(x?4:0)|(E?8:0)|(b?16:0),a!==void 0?this.od=a:this.od=0,y!==void 0?this.pd=y:this.pd=0,this.pl=new An,this.sr=this.pl.Ja,this.fw=null}Ns.prototype.copy=function(){var a=new Ns;a.l=this.l&-2,a.od=this.od,a.pd=this.pd;for(var y=this.pl.s,x=y.length,E=a.pl,b=0;b<x;b++){var z=y[b].copy();E.add(z)}return a.sr=this.sr,a.fw=this.fw,a},we=Ns.prototype,we.Xa=function(a){if(!(a instanceof Ns&&yt.B(this.startX,a.startX)&&yt.B(this.startY,a.startY)))return!1;var y=this.segments.s;a=a.segments.s;var x=y.length;if(x!==a.length)return!1;for(var E=0;E<x;E++)if(!y[E].Xa(a[E]))return!1;return!0},we.toString=function(a){a===void 0&&(a=-1);for(var y=0>a?"M"+this.startX.toString()+" "+this.startY.toString():"M"+this.startX.toFixed(a)+" "+this.startY.toFixed(a),x=this.segments.s,E=x.length,b=0;b<E;b++)y+=" "+x[b].toString(a);return y},we.freeze=function(){this._isFrozen=!0;var a=this.segments;a.freeze();var y=a.s;a=a.length;for(var x=0;x<a;x++)y[x].freeze();return this},we.ka=function(){this._isFrozen=!1;var a=this.segments;a.ka(),a=a.s;for(var y=a.length,x=0;x<y;x++)a[x].ka();return this},we.Zu=function(){if(this._isInvalidBounds)return!0;var a=this.segments;if(this.sr!==a.Ja)return!0;a=a.s;for(var y=a.length,x=0;x<y;x++)if(a[x]._isInvalidBounds)return!0;return!1},we.add=function(a){return this.pl.add(a),this},we.ca=function(a,y,x){for(var E=this.startX,b=this.startY,z=E,ee=b,re=this.segments.s,oe=re.length,se=0;se<oe;se++){var ue=re[se];switch(ue.type){case xs:z=ue.endX,ee=ue.endY,E=ue.endX,b=ue.endY;break;case fi:if(yt.Yb(E,b,ue.endX,ue.endY,x,a,y))return!0;E=ue.endX,b=ue.endY;break;case po:if(yt.cs(E,b,ue.point1X,ue.point1Y,ue.point2X,ue.point2Y,ue.endX,ue.endY,.5,a,y,x))return!0;E=ue.endX,b=ue.endY;break;case Vo:if(yt.jv(E,b,ue.point1X,ue.point1Y,ue.endX,ue.endY,.5,a,y,x))return!0;E=ue.endX,b=ue.endY;break;case qo:case Ja:var fe=ue.type===qo?Bl(ue,this):Pl(ue,this,E,b),ve=fe.length,ye=ue.type===qo?ue.centerX:ue.endX,Ce=ue.type===qo?ue.centerY:ue.endY;if(ve===0){if(yt.Yb(E,b,ye,Ce,x,a,y))return!0;E=ye,b=Ce;break}for(ye=null,Ce=0;Ce<ve;Ce++)if(ye=fe[Ce],Ce===0&&yt.Yb(E,b,ye[0],ye[1],x,a,y)||yt.cs(ye[0],ye[1],ye[2],ye[3],ye[4],ye[5],ye[6],ye[7],.5,a,y,x))return!0;ye!==null&&(E=ye[6],b=ye[7]);break;default:Dt("Unknown Segment type: "+ue.type)}if(ue.isClosed&&(E!==z||b!==ee)&&yt.Yb(E,b,z,ee,x,a,y))return!0}return!1},Yt.Object.defineProperties(Ns.prototype,{_isFrozen:{get:function(){return(this.l&1)!==0},set:function(a){this.l=a?this.l|1:this.l&-2}},_isInvalidBounds:{get:function(){return(this.l&2)!==0},set:function(a){this.l=a?this.l|2:this.l&-3}},isFilled:{get:function(){return(this.l&4)!==0},set:function(a){this._isFrozen&&wi(this,a),this.l=a?this.l|4:this.l&-5}},isShadowed:{get:function(){return(this.l&8)!==0},set:function(a){this._isFrozen&&wi(this,a),this.l=a?this.l|8:this.l&-9}},isEvenOdd:{get:function(){return(this.l&16)!==0},set:function(a){this._isFrozen&&wi(this,a),this.l=a?this.l|16:this.l&-17}},startX:{get:function(){return this.od},set:function(a){this._isFrozen&&wi(this,a),this.od=a,this._isInvalidBounds=!0}},startY:{get:function(){return this.pd},set:function(a){this._isFrozen&&wi(this,a),this.pd=a,this._isInvalidBounds=!0}},segments:{get:function(){return this.pl},set:function(a){this._isFrozen&&wi(this,a),this.pl=a,this._isInvalidBounds=!0}}}),Ns.prototype.add=Ns.prototype.add,Ns.prototype.equalsApprox=Ns.prototype.Xa,Ns.className="PathFigure";function to(a,y,x,E,b,z,ee,re){jo(this),a===void 0&&(a=fi),this.na=a,this.l=2,y!==void 0?this.Dc=y:this.Dc=0,x!==void 0?this.Ec=x:this.Ec=0,E===void 0&&(E=0),b===void 0&&(b=0),z===void 0&&(z=0),ee===void 0&&(ee=0),a===Ja?(a=z%360,0>a&&(a+=360),this.Ne=a,this.Vh=0,this.Wh=Math.max(E,0),this.Pg=Math.max(b,0),typeof ee=="boolean"?ee&&(this.isLargeArc=!0):typeof ee=="number"&&ee&&(this.isLargeArc=!0),re&&(this.isClockwiseArc=!0)):(this.Ne=E,this.Vh=b,a===qo&&(z=Math.max(z,0)),this.Wh=z,typeof ee=="number"?(a===qo&&(ee=Math.max(ee,0)),this.Pg=ee):this.Pg=0),this.ae=null}to.prototype.copy=function(){var a=new to;return a.na=this.na,a.l=this.l&-2,a.Dc=this.Dc,a.Ec=this.Ec,a.Ne=this.Ne,a.Vh=this.Vh,a.Wh=this.Wh,a.Pg=this.Pg,a},we=to.prototype,we.Xa=function(a){if(!(a instanceof to)||this.type!==a.type||this.isClosed!==a.isClosed)return!1;switch(this.type){case xs:case fi:return yt.B(this.endX,a.endX)&&yt.B(this.endY,a.endY);case po:return yt.B(this.endX,a.endX)&&yt.B(this.endY,a.endY)&&yt.B(this.point1X,a.point1X)&&yt.B(this.point1Y,a.point1Y)&&yt.B(this.point2X,a.point2X)&&yt.B(this.point2Y,a.point2Y);case Vo:return yt.B(this.endX,a.endX)&&yt.B(this.endY,a.endY)&&yt.B(this.point1X,a.point1X)&&yt.B(this.point1Y,a.point1Y);case qo:return yt.B(this.startAngle,a.startAngle)&&yt.B(this.sweepAngle,a.sweepAngle)&&yt.B(this.centerX,a.centerX)&&yt.B(this.centerY,a.centerY)&&yt.B(this.radiusX,a.radiusX)&&yt.B(this.radiusY,a.radiusY);case Ja:return this.isClockwiseArc===a.isClockwiseArc&&this.isLargeArc===a.isLargeArc&&yt.B(this.xAxisRotation,a.xAxisRotation)&&yt.B(this.endX,a.endX)&&yt.B(this.endY,a.endY)&&yt.B(this.radiusX,a.radiusX)&&yt.B(this.radiusY,a.radiusY);default:return!1}},we.qb=function(a){a.classType===to&&(this.type=a)},we.toString=function(a){switch(a===void 0&&(a=-1),this.type){case xs:a=0>a?"M"+this.endX.toString()+" "+this.endY.toString():"M"+this.endX.toFixed(a)+" "+this.endY.toFixed(a);break;case fi:a=0>a?"L"+this.endX.toString()+" "+this.endY.toString():"L"+this.endX.toFixed(a)+" "+this.endY.toFixed(a);break;case po:a=0>a?"C"+this.point1X.toString()+" "+this.point1Y.toString()+" "+this.point2X.toString()+" "+this.point2Y.toString()+" "+this.endX.toString()+" "+this.endY.toString():"C"+this.point1X.toFixed(a)+" "+this.point1Y.toFixed(a)+" "+this.point2X.toFixed(a)+" "+this.point2Y.toFixed(a)+" "+this.endX.toFixed(a)+" "+this.endY.toFixed(a);break;case Vo:a=0>a?"Q"+this.point1X.toString()+" "+this.point1Y.toString()+" "+this.endX.toString()+" "+this.endY.toString():"Q"+this.point1X.toFixed(a)+" "+this.point1Y.toFixed(a)+" "+this.endX.toFixed(a)+" "+this.endY.toFixed(a);break;case qo:a=0>a?"B"+this.startAngle.toString()+" "+this.sweepAngle.toString()+" "+this.centerX.toString()+" "+this.centerY.toString()+" "+this.radiusX.toString()+" "+this.radiusY.toString():"B"+this.startAngle.toFixed(a)+" "+this.sweepAngle.toFixed(a)+" "+this.centerX.toFixed(a)+" "+this.centerY.toFixed(a)+" "+this.radiusX.toFixed(a)+" "+this.radiusY.toFixed(a);break;case Ja:a=0>a?"A"+this.radiusX.toString()+" "+this.radiusY.toString()+" "+this.xAxisRotation.toString()+" "+(this.isLargeArc?1:0)+" "+(this.isClockwiseArc?1:0)+" "+this.endX.toString()+" "+this.endY.toString():"A"+this.radiusX.toFixed(a)+" "+this.radiusY.toFixed(a)+" "+this.xAxisRotation.toFixed(a)+" "+(this.isLargeArc?1:0)+" "+(this.isClockwiseArc?1:0)+" "+this.endX.toFixed(a)+" "+this.endY.toFixed(a);break;default:a=this.type.toString()}return a+(this.isClosed?"z":"")},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return this._isFrozen=!1,this},we.close=function(){return this.isClosed=!0,this};function Bl(a,y){if(a.ae!==null&&y._isInvalidBounds===!1)return a.ae;var x=a.radiusX,E=a.radiusY;if(E===void 0&&(E=x),x===0||E===0)return a.ae=[],a.ae;y=a.Ne;var b=a.Vh,z=yt.jx(0,0,x<E?x:E,a.startAngle,a.startAngle+a.sweepAngle,!1);if(x!==E){var ee=kr.alloc();ee.reset(),x<E?ee.scale(1,E/x):ee.scale(x/E,1),Bn.Ha(z,ee),kr.free(ee)}for(x=z.length,E=0;E<x;E++)ee=z[E],ee[0]+=y,ee[1]+=b,ee[2]+=y,ee[3]+=b,ee[4]+=y,ee[5]+=b,ee[6]+=y,ee[7]+=b;return a.ae=z,a.ae}function Pl(a,y,x,E){function b(Ae,Ye,We,tt){return(Ae*tt<Ye*We?-1:1)*Math.acos((Ae*We+Ye*tt)/(Math.sqrt(Ae*Ae+Ye*Ye)*Math.sqrt(We*We+tt*tt)))}if(a.ae!==null&&y._isInvalidBounds===!1)return a.ae;if(a.radiusX===0||a.radiusY===0)return a.ae=[],a.ae;y=a.Wh;var z=a.Pg;y===0&&(y=1e-4),z===0&&(z=1e-4);var ee=Math.PI/180*a.Ne,re=a.isLargeArc,oe=a.isClockwiseArc,se=a.Dc,ue=a.Ec,fe=Math.cos(ee),ve=Math.sin(ee),ye=fe*(x-se)/2+ve*(E-ue)/2;ee=-ve*(x-se)/2+fe*(E-ue)/2;var Ce=ye*ye/(y*y)+ee*ee/(z*z);return 1<Ce&&(y*=Math.sqrt(Ce),z*=Math.sqrt(Ce)),Ce=(re===oe?-1:1)*Math.sqrt((y*y*z*z-y*y*ee*ee-z*z*ye*ye)/(y*y*ee*ee+z*z*ye*ye)),isNaN(Ce)&&(Ce=0),re=Ce*y*ee/z,Ce=Ce*-z*ye/y,isNaN(re)&&(re=0),isNaN(Ce)&&(Ce=0),x=(x+se)/2+fe*re-ve*Ce,E=(E+ue)/2+ve*re+fe*Ce,ue=b(1,0,(ye-re)/y,(ee-Ce)/z),fe=(ye-re)/y,se=(ee-Ce)/z,ye=(-ye-re)/y,re=(-ee-Ce)/z,ee=b(fe,se,ye,re),ye=(fe*ye+se*re)/(Math.sqrt(fe*fe+se*se)*Math.sqrt(ye*ye+re*re)),-1>=ye?ee=Math.PI:1<=ye&&(ee=0),!oe&&0<ee&&(ee-=2*Math.PI),oe&&0>ee&&(ee+=2*Math.PI),oe=y>z?1:y/z,ye=y>z?z/y:1,y=yt.jx(0,0,y>z?y:z,ue,ue+ee,!0),z=kr.alloc(),z.reset(),z.translate(x,E),z.rotate(a.Ne,0,0),z.scale(oe,ye),Bn.Ha(y,z),kr.free(z),a.ae=y,a.ae}Yt.Object.defineProperties(to.prototype,{_isFrozen:{get:function(){return(this.l&1)!==0},set:function(a){this.l=a?this.l|1:this.l&-2}},_isInvalidBounds:{get:function(){return(this.l&2)!==0},set:function(a){this.l=a?this.l|2:this.l&-3}},isClosed:{get:function(){return(this.l&8)!==0},set:function(a){this.isClosed!==a&&(this.l=a?this.l|8:this.l&-9,this._isInvalidBounds=!0)}},type:{get:function(){return this.na},set:function(a){this._isFrozen&&wi(this,a),this.na=a,this._isInvalidBounds=!0}},endX:{get:function(){return this.Dc},set:function(a){this._isFrozen&&wi(this,a),this.Dc=a,this._isInvalidBounds=!0}},endY:{get:function(){return this.Ec},set:function(a){this._isFrozen&&wi(this,a),this.Ec=a,this._isInvalidBounds=!0}},point1X:{get:function(){return this.Ne},set:function(a){this._isFrozen&&wi(this,a),this.Ne=a,this._isInvalidBounds=!0}},point1Y:{get:function(){return this.Vh},set:function(a){this._isFrozen&&wi(this,a),this.Vh=a,this._isInvalidBounds=!0}},point2X:{get:function(){return this.Wh},set:function(a){this._isFrozen&&wi(this,a),this.Wh=a,this._isInvalidBounds=!0}},point2Y:{get:function(){return this.Pg},set:function(a){this._isFrozen&&wi(this,a),this.Pg=a,this._isInvalidBounds=!0}},centerX:{get:function(){return this.Ne},set:function(a){this._isFrozen&&wi(this,a),this.Ne=a,this._isInvalidBounds=!0}},centerY:{get:function(){return this.Vh},set:function(a){this._isFrozen&&wi(this,a),this.Vh=a,this._isInvalidBounds=!0}},radiusX:{get:function(){return this.Wh},set:function(a){0>a&&gr(a,">= zero",to,"radiusX"),this._isFrozen&&wi(this,a),this.Wh=a,this._isInvalidBounds=!0}},radiusY:{get:function(){return this.Pg},set:function(a){0>a&&gr(a,">= zero",to,"radiusY"),this._isFrozen&&wi(this,a),this.Pg=a,this._isInvalidBounds=!0}},startAngle:{get:function(){return this.Dc},set:function(a){this._isFrozen&&wi(this,a),a%=360,0>a&&(a+=360),this.Dc=a,this._isInvalidBounds=!0}},sweepAngle:{get:function(){return this.Ec},set:function(a){this._isFrozen&&wi(this,a),360<a&&(a=360),-360>a&&(a=-360),this.Ec=a,this._isInvalidBounds=!0}},isClockwiseArc:{get:function(){return(this.l&4)!==0},set:function(a){this._isFrozen&&wi(this,a),this.l=a?this.l|4:this.l&-5,this._isInvalidBounds=!0}},isLargeArc:{get:function(){return(this.l&16)!==0},set:function(a){this._isFrozen&&wi(this,a),this.l=a?this.l|16:this.l&-17,this._isInvalidBounds=!0}},xAxisRotation:{get:function(){return this.Ne},set:function(a){this._isFrozen&&wi(this,a),a%=360,0>a&&(a+=360),this.Ne=a,this._isInvalidBounds=!0}}}),to.prototype.equalsApprox=to.prototype.Xa;var xs=new Vt(to,"Move",0),fi=new Vt(to,"Line",1),po=new Vt(to,"Bezier",2),Vo=new Vt(to,"QuadraticBezier",3),qo=new Vt(to,"Arc",4),Ja=new Vt(to,"SvgArc",4);to.className="PathSegment",to.Move=xs,to.Line=fi,to.Bezier=po,to.QuadraticBezier=Vo,to.Arc=qo,to.SvgArc=Ja;function Zs(){this.H=null,this.xu=new Qe(0,0).freeze(),this.mt=new Qe(0,0).freeze(),this.Bp=this.Rq=0,this.Cp=1,this.xq="",this.Wr=this.Tp=!1,this.Rp=this.Ep=0,this.xg=this.nq=this.tq=!1,this.Zp=null,this.Rr=0,this.xd=this.Nr=null}Zs.prototype.copy=function(){var a=new Zs;return this.clone(a)},Zs.prototype.clone=function(a){return a.H=this.H,a.xu.assign(this.viewPoint),a.mt.assign(this.documentPoint),a.Rq=this.Rq,a.Bp=this.Bp,a.Cp=this.Cp,a.xq=this.xq,a.Tp=this.Tp,a.Wr=this.Wr,a.Ep=this.Ep,a.Rp=this.Rp,a.tq=this.tq,a.nq=this.nq,a.xg=this.xg,a.Zp=this.Zp,a.Rr=this.Rr,a.Nr=this.Nr,a.xd=this.xd,a},Zs.prototype.toString=function(){var a="^";return this.modifiers!==0&&(a+="M:"+this.modifiers),this.button!==0&&(a+="B:"+this.button),this.key!==""&&(a+="K:"+this.key),this.clickCount!==0&&(a+="C:"+this.clickCount),this.delta!==0&&(a+="D:"+this.delta),this.handled&&(a+="h"),this.bubbles&&(a+="b"),this.documentPoint!==null&&(a+="@"+this.documentPoint.toString()),a},Zs.prototype.So=function(a,y){var x=this.diagram;return x===null||ul(x,a,y),y},Zs.prototype.Bz=function(a,y){var x=this.diagram;return x===null||(ul(x,a,y),y.assign(x.Ps(y))),y},Yt.Object.defineProperties(Zs.prototype,{diagram:{get:function(){return this.H},set:function(a){this.H=a}},viewPoint:{get:function(){return this.xu},set:function(a){this.xu.assign(a)}},documentPoint:{get:function(){return this.mt},set:function(a){this.mt.assign(a)}},modifiers:{get:function(){return this.Rq},set:function(a){this.Rq=a}},button:{get:function(){return this.Bp},set:function(a){if(this.Bp=a,this.event===null)switch(a){case 0:this.buttons=1;break;case 1:this.buttons=4;break;case 2:this.buttons=2}}},buttons:{get:function(){return this.Cp},set:function(a){this.Cp=a}},key:{get:function(){return this.xq},set:function(a){this.xq=a}},down:{get:function(){return this.Tp},set:function(a){this.Tp=a}},up:{get:function(){return this.Wr},set:function(a){this.Wr=a}},clickCount:{get:function(){return this.Ep},set:function(a){this.Ep=a}},delta:{get:function(){return this.Rp},set:function(a){this.Rp=a}},isMultiTouch:{get:function(){return this.tq},set:function(a){this.tq=a}},handled:{get:function(){return this.nq},set:function(a){this.nq=a}},bubbles:{get:function(){return this.xg},set:function(a){this.xg=a}},event:{get:function(){return this.Zp},set:function(a){this.Zp=a}},isTouchEvent:{get:function(){var a=this.event;return a===null?!1:a.pointerType==="touch"||a.pointerType==="pen"}},timestamp:{get:function(){return this.Rr},set:function(a){this.Rr=a}},targetDiagram:{get:function(){return this.Nr},set:function(a){this.Nr=a}},targetObject:{get:function(){return this.xd},set:function(a){this.xd=a}},control:{get:function(){return(this.modifiers&1)!==0},set:function(a){this.modifiers=a?this.modifiers|1:this.modifiers&-2}},shift:{get:function(){return(this.modifiers&4)!==0},set:function(a){this.modifiers=a?this.modifiers|4:this.modifiers&-5}},alt:{get:function(){return(this.modifiers&2)!==0},set:function(a){this.modifiers=a?this.modifiers|2:this.modifiers&-3}},meta:{get:function(){return(this.modifiers&8)!==0},set:function(a){this.modifiers=a?this.modifiers|8:this.modifiers&-9}},left:{get:function(){var a=this.event;return a===null||a.type!=="mousedown"&&a.type!=="mouseup"&&a.type!=="pointerdown"&&a.type!=="pointerup"?(this.buttons&1)!==0:this.button===0},set:function(a){this.buttons=a?this.buttons|1:this.buttons&-2}},right:{get:function(){var a=this.event;return a===null||a.type!=="mousedown"&&a.type!=="mouseup"&&a.type!=="pointerdown"&&a.type!=="pointerup"?(this.buttons&2)!==0:this.button===2},set:function(a){this.buttons=a?this.buttons|2:this.buttons&-3}},middle:{get:function(){var a=this.event;return a===null||a.type!=="mousedown"&&a.type!=="mouseup"&&a.type!=="pointerdown"&&a.type!=="pointerup"?(this.buttons&4)!==0:this.button===1},set:function(a){this.buttons=a?this.buttons|4:this.buttons&-5}}}),Zs.prototype.getMultiTouchDocumentPoint=Zs.prototype.Bz,Zs.prototype.getMultiTouchViewPoint=Zs.prototype.So,Zs.className="InputEvent";function mu(){this.H=null,this.xa="",this.ar=this.Lr=null}mu.prototype.copy=function(){var a=new mu;return a.H=this.H,a.xa=this.xa,a.Lr=this.Lr,a.ar=this.ar,a},mu.prototype.toString=function(){var a="*"+this.name;return this.subject!==null&&(a+=":"+this.subject.toString()),this.parameter!==null&&(a+="("+this.parameter.toString()+")"),a},Yt.Object.defineProperties(mu.prototype,{diagram:{get:function(){return this.H},set:function(a){this.H=a}},name:{get:function(){return this.xa},set:function(a){this.xa=a}},subject:{get:function(){return this.Lr},set:function(a){this.Lr=a}},parameter:{get:function(){return this.ar},set:function(a){this.ar=a}}}),mu.className="DiagramEvent";function ka(){this.Fm=ga,this.rf=this.Qq="",this.Ln=this.Mn=this.Rn=this.Sn=this.Qn=this.H=this.cc=null}ka.prototype.clear=function(){this.Ln=this.Mn=this.Rn=this.Sn=this.Qn=this.H=this.cc=null},ka.prototype.copy=function(){var a=new ka;a.Fm=this.Fm,a.Qq=this.Qq,a.rf=this.rf,a.cc=this.cc,a.H=this.H,a.Qn=this.Qn;var y=this.Sn;return a.Sn=kn(y)&&typeof y.J=="function"?y.J():y,y=this.Rn,a.Rn=kn(y)&&typeof y.J=="function"?y.J():y,y=this.Mn,a.Mn=kn(y)&&typeof y.J=="function"?y.J():y,y=this.Ln,a.Ln=kn(y)&&typeof y.J=="function"?y.J():y,a},ka.prototype.qb=function(a){a.classType===ka&&(this.change=a)},ka.prototype.toString=function(){var a="";return a=this.change===sl?a+"* ":this.change===ga?a+(this.model!==null?"!m":"!d"):a+((this.model!==null?"!m":"!d")+this.change),this.propertyName&&typeof this.propertyName=="string"&&(a+=" "+this.propertyName),this.modelChange&&this.modelChange!==this.propertyName&&(a+=" "+this.modelChange),a+=": ",this.change===sl?this.oldValue!==null&&(a+=" "+this.oldValue):(this.object!==null&&(a+=Co(this.object)),this.oldValue!==null&&(a+=" old: "+Co(this.oldValue)),this.oldParam!==null&&(a+=" "+this.oldParam),this.newValue!==null&&(a+=" new: "+Co(this.newValue)),this.newParam!==null&&(a+=" "+this.newParam)),a},ka.prototype.I=function(a){return a?this.oldValue:this.newValue},ka.prototype.Dz=function(a){return a?this.oldParam:this.newParam},ka.prototype.canUndo=function(){return this.model!==null||this.diagram!==null},ka.prototype.undo=function(){this.canUndo()&&(this.model!==null?this.model.changeState(this,!0):this.diagram!==null&&this.diagram.changeState(this,!0))},ka.prototype.canRedo=function(){return this.model!==null||this.diagram!==null},ka.prototype.redo=function(){this.canRedo()&&(this.model!==null?this.model.changeState(this,!1):this.diagram!==null&&this.diagram.changeState(this,!1))},Yt.Object.defineProperties(ka.prototype,{model:{get:function(){return this.cc},set:function(a){this.cc=a}},diagram:{get:function(){return this.H},set:function(a){this.H=a}},change:{get:function(){return this.Fm},set:function(a){this.Fm=a}},modelChange:{get:function(){return this.Qq},set:function(a){this.Qq=a}},propertyName:{get:function(){return this.rf},set:function(a){this.rf=a}},isTransactionFinished:{get:function(){return this.Fm===sl&&(this.rf==="CommittedTransaction"||this.rf==="FinishedUndo"||this.rf==="FinishedRedo")}},object:{get:function(){return this.Qn},set:function(a){this.Qn=a}},oldValue:{get:function(){return this.Sn},set:function(a){this.Sn=a}},oldParam:{get:function(){return this.Rn},set:function(a){this.Rn=a}},newValue:{get:function(){return this.Mn},set:function(a){this.Mn=a}},newParam:{get:function(){return this.Ln},set:function(a){this.Ln=a}}}),ka.prototype.redo=ka.prototype.redo,ka.prototype.canRedo=ka.prototype.canRedo,ka.prototype.undo=ka.prototype.undo,ka.prototype.canUndo=ka.prototype.canUndo,ka.prototype.getParam=ka.prototype.Dz,ka.prototype.getValue=ka.prototype.I,ka.prototype.clear=ka.prototype.clear;var sl=new Vt(ka,"Transaction",-1),ga=new Vt(ka,"Property",0),ts=new Vt(ka,"Insert",1),ss=new Vt(ka,"Remove",2);ka.className="ChangedEvent",ka.Transaction=sl,ka.Property=ga,ka.Insert=ts,ka.Remove=ss;function ws(){this.o=new An().freeze(),this.xa="",this.j=!1}ws.prototype.toString=function(a){var y="Transaction: "+this.name+" "+this.changes.count.toString()+(this.isComplete?"":", incomplete");if(a!==void 0&&0<a){a=this.changes.count;for(var x=0;x<a;x++){var E=this.changes.M(x);E!==null&&(y+=`
`+E.toString())}}return y},ws.prototype.clear=function(){var a=this.changes;a.ka();for(var y=a.count-1;0<=y;y--){var x=a.M(y);x!==null&&x.clear()}a.clear(),a.freeze()},ws.prototype.canUndo=function(){return this.isComplete},ws.prototype.undo=function(){if(this.canUndo())for(var a=this.changes.count-1;0<=a;a--){var y=this.changes.M(a);y!==null&&y.undo()}},ws.prototype.canRedo=function(){return this.isComplete},ws.prototype.redo=function(){if(this.canRedo())for(var a=this.changes.count,y=0;y<a;y++){var x=this.changes.M(y);x!==null&&x.redo()}},ws.prototype.ak=function(){if(this.isComplete){var a=this.changes;a.ka();for(var y=new Li,x=0;x<a.count;x++){var E=a.M(x);if(E!==null&&E.change===ga&&E.object){var b=y.get(E.object);b||(b=new Li,y.set(E.object,b));var z=b.get(E.propertyName);z===null?b.set(E.propertyName,-1):(0<z&&a.cd(z,null),b.set(E.propertyName,x))}}for(x=y=0;x<a.count;x++)E=a.M(x),E!==null&&(x>y&&a.cd(y,E),y++);for(;a.length>y;)a.pop();a.freeze()}},Yt.Object.defineProperties(ws.prototype,{changes:{get:function(){return this.o}},name:{get:function(){return this.xa},set:function(a){this.xa=a}},isComplete:{get:function(){return this.j},set:function(a){this.j=a}}}),ws.prototype.optimize=ws.prototype.ak,ws.prototype.redo=ws.prototype.redo,ws.prototype.canRedo=ws.prototype.canRedo,ws.prototype.undo=ws.prototype.undo,ws.prototype.canUndo=ws.prototype.canUndo,ws.prototype.clear=ws.prototype.clear,ws.className="Transaction";function Ta(){this.Pt=new Pn,this.Jd=!1,this.u=new An().freeze(),this.Ce=-1,this.o=999,this.Fe=!1,this.Np=null,this.bi=0,this.j=!1,this.Ie=new An().freeze(),this.hl=new An,this.tt=!0,this.Dt=this.rq=this.Gt=this.Ft=!1}Ta.prototype.toString=function(a){var y="UndoManager "+this.historyIndex+"<"+this.history.count+"<="+this.maxHistoryLength;y+="[";for(var x=this.nestedTransactionNames.count,E=0;E<x;E++)0<E&&(y+=" "),y+=this.nestedTransactionNames.M(E);if(y+="]",a!==void 0&&0<a)for(x=this.history.count,E=0;E<x;E++)y+=`
`+this.history.M(E).toString(a-1);return y},Ta.prototype.clear=function(){var a=this.history;a.ka();for(var y=a.count-1;0<=y;y--){var x=a.M(y);x!==null&&x.clear()}a.clear(),this.Ce=-1,a.freeze(),this.Fe=!1,this.Np=null,this.bi=0,this.Ie.ka(),this.Ie.clear(),this.Ie.freeze(),this.hl.clear(),this.Dt=this.rq=this.Gt=this.Ft=!1},Ta.prototype.copyProperties=function(a){this.isEnabled=a.isEnabled,this.maxHistoryLength=a.maxHistoryLength,this.checksTransactionLevel=a.checksTransactionLevel},we=Ta.prototype,we.Xw=function(a){this.Pt.add(a)},we.Rx=function(a){this.Pt.remove(a)},we.Ea=function(a){if(a===void 0&&(a=""),a===null&&(a=""),this.isUndoingRedoing)return!1;this.tt===!0&&(this.tt=!1,this.bi++,this.isInternalTransaction||this.Ob("StartingFirstTransaction",a,this.currentTransaction),0<this.bi&&this.bi--),this.isEnabled&&(this.Ie.ka(),this.Ie.add(a),this.Ie.freeze(),this.currentTransaction===null?this.hl.add(0):this.hl.add(this.currentTransaction.changes.count)),this.bi++;var y=this.transactionLevel===1;return y&&(this.isInternalTransaction||this.Ob("StartedTransaction",a,this.currentTransaction)),y},we.eb=function(a){return a===void 0&&(a=""),vu(this,!0,a)},we.Kf=function(){return vu(this,!1,"")};function vu(a,y,x){if(a.isUndoingRedoing)return!1;a.checksTransactionLevel&&1>a.transactionLevel&&eo("Ending transaction without having started a transaction: "+x);var E=a.transactionLevel===1,b=a.currentTransaction;E&&y&&(a.isInternalTransaction||a.Ob("CommittingTransaction",x,b));var z=0;if(0<a.transactionLevel&&(a.bi--,a.isEnabled)){var ee=a.Ie.count;0<ee&&(x===""&&(x=a.Ie.M(0)),a.Ie.ka(),a.Ie.mb(ee-1),a.Ie.freeze()),ee=a.hl.count,0<ee&&(z=a.hl.M(ee-1),a.hl.mb(ee-1))}if(E){if(y)a.rq=!1,b===null&&x!==""&&(b=a.currentTransaction),a.isEnabled&&b!==null&&(b.isComplete||(b.isComplete=!0,b.name=x),a.lx(),y=a.history,y.ka(),E=a.maxHistoryLength,0<=E&&(E===0?y.clear():y.count>=E&&(z=y.M(0),z!==null&&z.clear(),y.mb(0),a.Ce--)),E===0||y.count!==0&&y.get(y.count-1)===b||(y.add(b),a.Ce++),y.freeze()),a.isInternalTransaction||a.Ob("CommittedTransaction",x,b);else{a.Fe=!0;try{a.isEnabled&&b!==null&&(b.isComplete=!0,b.undo())}finally{a.isInternalTransaction||a.Ob("RolledBackTransaction",x,b),a.Fe=!1}b!==null&&b.clear()}return a.Np=null,a.isPendingClear&&a.clear(),a.isPendingClear=!1,a.isPendingUnmodified=!1,!0}if(a.isEnabled&&!y&&b!==null){for(a=z,x=b.changes,b=x.count-1;b>=a;b--)y=x.M(b),y!==null&&y.undo(),x.ka(),x.mb(b);x.freeze()}return!1}we.lx=function(){if(!this.isUndoingRedoing&&this.canRedo()){var a=this.history;a.ka();for(var y=a.count-1;y>this.historyIndex;y--){var x=a.M(y);x!==null&&x.clear(),a.mb(y),this.rq=!0}a.freeze()}},Ta.prototype.canUndo=function(){if(!this.isEnabled||0<this.transactionLevel)return!1;var a=this.transactionToUndo;return!!(a!==null&&a.canUndo())},Ta.prototype.undo=function(){if(this.canUndo()){var a=this.transactionToUndo;try{this.Fe=!0,this.Ob("StartingUndo","Undo",a),this.Ce--,a.undo()}catch(y){eo("undo error: "+y.toString())}finally{this.Ob("FinishedUndo","Undo",a),this.Fe=!1}}},Ta.prototype.canRedo=function(){if(!this.isEnabled||0<this.transactionLevel)return!1;var a=this.transactionToRedo;return!!(a!==null&&a.canRedo())},Ta.prototype.redo=function(){if(this.canRedo()){var a=this.transactionToRedo;try{this.Fe=!0,this.Ob("StartingRedo","Redo",a),this.Ce++,a.redo()}catch(y){eo("redo error: "+y.toString())}finally{this.Ob("FinishedRedo","Redo",a),this.Fe=!1}}},Ta.prototype.Ob=function(a,y,x){x===void 0&&(x=null);var E=new ka;for(E.change=sl,E.propertyName=a,E.object=x,E.oldValue=y,a=this.models;a.next();)y=a.value,E.model=y,y.ds(E)},Ta.prototype.Tu=function(a){if(this.isEnabled&&!this.isUndoingRedoing&&!this.skipsEvent(a)){var y=this.currentTransaction;y===null&&(this.Np=y=new ws);var x=a.copy();y=y.changes,y.ka(),y.add(x),y.freeze(),this.checksTransactionLevel&&0>=this.transactionLevel&&!this.tt&&(a=a.diagram,a!==null&&a.pi===!1||eo("Change not within a transaction: "+x.toString()))}},Ta.prototype.skipsEvent=function(a){if(a===null||0>a.change.value)return!0;if(a=a.object,a===null)return!1;if(a.layer!==void 0){if(a=a.layer,a!==null&&a.isTemporary)return!0}else if(a.isTemporary)return!0;return!1},Yt.Object.defineProperties(Ta.prototype,{models:{get:function(){return this.Pt.iterator}},isEnabled:{get:function(){return this.Jd},set:function(a){this.Jd=a}},transactionToUndo:{get:function(){return 0<=this.historyIndex&&this.historyIndex<=this.history.count-1?this.history.M(this.historyIndex):null}},transactionToRedo:{get:function(){return this.historyIndex<this.history.count-1?this.history.M(this.historyIndex+1):null}},isUndoingRedoing:{get:function(){return this.Fe}},history:{get:function(){return this.u}},maxHistoryLength:{get:function(){return this.o},set:function(a){this.o=a}},historyIndex:{get:function(){return this.Ce}},currentTransaction:{get:function(){return this.Np}},transactionLevel:{get:function(){return this.bi}},isInTransaction:{get:function(){return 0<this.bi}},checksTransactionLevel:{get:function(){return this.j},set:function(a){this.j=a}},nestedTransactionNames:{get:function(){return this.Ie}},isPendingClear:{get:function(){return this.Ft},set:function(a){this.Ft=a}},isPendingUnmodified:{get:function(){return this.Gt},set:function(a){this.Gt=a}},isInternalTransaction:{get:function(){return this.Dt},set:function(a){this.Dt=a}},isJustDiscarded:{get:function(){return this.rq}}}),Ta.prototype.handleChanged=Ta.prototype.Tu,Ta.prototype.redo=Ta.prototype.redo,Ta.prototype.undo=Ta.prototype.undo,Ta.prototype.canUndo=Ta.prototype.canUndo,Ta.prototype.discardHistoryAfterIndex=Ta.prototype.lx,Ta.prototype.rollbackTransaction=Ta.prototype.Kf,Ta.prototype.commitTransaction=Ta.prototype.eb,Ta.prototype.startTransaction=Ta.prototype.Ea,Ta.prototype.removeModel=Ta.prototype.Rx,Ta.prototype.addModel=Ta.prototype.Xw,Ta.prototype.clear=Ta.prototype.clear,Ta.className="UndoManager";function Ni(){jo(this),this.H=zo,this.xa="",this.Jd=!0,this.nb=!1,this.wm=null,this.yy=new Zs,this.Zr=-1}Ni.prototype.toString=function(){return this.name!==""?this.name+" Tool":cr(this.constructor)},Ni.prototype.updateAdornments=function(){},Ni.prototype.canStart=function(){return this.isEnabled},Ni.prototype.doStart=function(){},Ni.prototype.doActivate=function(){this.isActive=!0},Ni.prototype.doDeactivate=function(){this.isActive=!1},Ni.prototype.doStop=function(){},Ni.prototype.doCancel=function(){this.transactionResult=null,this.stopTool()},Ni.prototype.stopTool=function(){var a=this.diagram;a.currentTool===this&&(a.currentTool=null,a.currentCursor="")},Ni.prototype.doMouseDown=function(){!this.isActive&&this.canStart()&&this.doActivate()},Ni.prototype.doMouseMove=function(){},Ni.prototype.doMouseUp=function(){this.stopTool()},Ni.prototype.doMouseWheel=function(){},Ni.prototype.canStartMultiTouch=function(){return!0},Ni.prototype.standardPinchZoomStart=function(){var a=this.diagram,y=a.lastInput,x=y.So(0,Qe.allocAt(NaN,NaN)),E=y.So(1,Qe.allocAt(NaN,NaN));if(x.w()&&E.w()&&(this.doCancel(),a.Ql("hasGestureZoom"))){a.Bw=a.scale;var b=E.x-x.x,z=E.y-x.y;a.Jw=Math.sqrt(b*b+z*z),y.bubbles=!1}Qe.free(x),Qe.free(E)},Ni.prototype.standardPinchZoomMove=function(){var a=this.diagram,y=a.lastInput,x=y.So(0,Qe.allocAt(NaN,NaN)),E=y.So(1,Qe.allocAt(NaN,NaN));if(x.w()&&E.w()&&(this.doCancel(),a.Ql("hasGestureZoom"))){var b=E.x-x.x,z=E.y-x.y;z=Math.sqrt(b*b+z*z)/a.Jw,b=new Qe((Math.min(E.x,x.x)+Math.max(E.x,x.x))/2,(Math.min(E.y,x.y)+Math.max(E.y,x.y))/2),z*=a.Bw;var ee=a.commandHandler;if(z!==a.scale&&ee.canResetZoom(z)){var re=a.zoomPoint;a.zoomPoint=b,ee.resetZoom(z),a.zoomPoint=re}y.bubbles=!1}Qe.free(x),Qe.free(E)},Ni.prototype.doKeyDown=function(){this.diagram.lastInput.key==="Esc"&&this.doCancel()},Ni.prototype.doKeyUp=function(){},Ni.prototype.Ea=function(a){return a===void 0&&(a=this.name),this.transactionResult=null,this.diagram.Ea(a)},Ni.prototype.stopTransaction=function(){var a=this.diagram;return this.transactionResult===null?a.Kf():a.eb(this.transactionResult)},Ni.prototype.standardMouseSelect=function(){var a=this.diagram;if(a.allowSelect){var y=a.lastInput,x=a.Ol(y.documentPoint,!1);if(x!==null){if(Fs?y.meta:y.control){for(a.R("ChangingSelection",a.selection),y=x;y!==null&&!y.canSelect();)y=y.containingGroup;y!==null&&(y.isSelected=!y.isSelected),a.R("ChangedSelection",a.selection)}else if(y.shift){if(!x.isSelected){for(a.R("ChangingSelection",a.selection),y=x;y!==null&&!y.canSelect();)y=y.containingGroup;y!==null&&(y.isSelected=!0),a.R("ChangedSelection",a.selection)}}else if(!x.isSelected){for(y=x;y!==null&&!y.canSelect();)y=y.containingGroup;y!==null&&a.select(y)}}else!y.left||(Fs?y.meta:y.control)||y.shift||a.clearSelection()}},Ni.prototype.standardMouseClick=function(a,y){a===void 0&&(a=null),y===void 0&&(y=function(b){return!b.layer.isTemporary});var x=this.diagram,E=x.lastInput;return a=x.ic(E.documentPoint,a,y),E.targetObject=a,ou(a,E,x),E.handled};function ou(a,y,x){if(y.handled=!1,a===null||a.If()){var E=0;y.left?E=y.clickCount===1?1:y.clickCount===2?2:1:y.right&&y.clickCount===1&&(E=3);var b="ObjectSingleClicked";if(a!==null){switch(E){case 1:b="ObjectSingleClicked";break;case 2:b="ObjectDoubleClicked";break;case 3:b="ObjectContextClicked"}E!==0&&x.R(b,a)}else{switch(E){case 1:b="BackgroundSingleClicked";break;case 2:b="BackgroundDoubleClicked";break;case 3:b="BackgroundContextClicked"}E!==0&&x.R(b)}if(a!==null)for(;a!==null;){switch(x=null,E){case 1:x=a.click;break;case 2:x=a.doubleClick?a.doubleClick:a.click;break;case 3:x=a.contextClick}if(x!==null&&(x(y,a),y.handled))break;a=a.panel}else{switch(a=null,E){case 1:a=x.click;break;case 2:a=x.doubleClick?x.doubleClick:x.click;break;case 3:a=x.contextClick}a!==null&&a(y)}}}Ni.prototype.standardMouseOver=function(){var a=this.diagram,y=a.lastInput;if(a.animationManager.zb!==!0){var x=a.skipsUndoManager;a.skipsUndoManager=!0;var E=a.viewportBounds.ca(y.documentPoint)?a.ic(y.documentPoint,null,null):null;!y.event||y.event.type!=="pointercancel"&&y.event.type!=="pointerout"||(E=null),y.targetObject=E;var b=!1;if(E!==a.Ck){var z=a.Ck,ee=z;for(a.Ck=E,this.doCurrentObjectChanged(z,E),y.handled=!1;z!==null;){var re=z.mouseLeave;if(re!==null&&(E===z||E!==null&&E.rg(z)||(re(y,z,E),b=!0,y.handled)))break;z=z.panel}for(z=ee,y.handled=!1;E!==null&&(ee=E.mouseEnter,!(ee!==null&&(z===E||z!==null&&z.rg(E)||(ee(y,E,z),b=!0,y.handled))));)E=E.panel;E=a.Ck}if(E!==null){for(z=E,ee="";z!==null&&(ee=z.cursor,ee==="");)z=z.panel;for(a.currentCursor=ee,y.handled=!1,z=E;z!==null&&(E=z.mouseOver,!(E!==null&&(E(y,z),b=!0,y.handled)));)z=z.panel}else this.doUpdateCursor(null),E=a.mouseOver,E!==null&&(E(y),b=!0);b&&a.$b(),a.skipsUndoManager=x}},Ni.prototype.doUpdateCursor=function(){var a=this.diagram;a&&(a.currentCursor="")},Ni.prototype.doCurrentObjectChanged=function(){},Ni.prototype.standardMouseWheel=function(){var a=this.diagram,y=a.lastInput,x=y.delta;if(x!==0&&a.documentBounds.w()){var E=a.commandHandler,b=a.toolManager.mouseWheelBehavior;if(E!==null&&(b===bc&&!y.shift||b===Mh&&y.control))(0<x?E.canIncreaseZoom():E.canDecreaseZoom())&&(b=a.zoomPoint,a.zoomPoint=y.viewPoint,0<x?E.increaseZoom():E.decreaseZoom(),a.zoomPoint=b),y.bubbles=!1;else if(b===bc&&y.shift||b===Mh&&!y.control){E=a.position.copy();var z=y.event;b=z.deltaMode;var ee=z.deltaX;z=z.deltaY;var re="pixel";if(ee===0&&z===0||y.shift)!y.shift&&a.allowVerticalScroll?(x=3*x*a.scrollVerticalLineChange,a.scroll(re,0<x?"up":"down",Math.abs(x))):y.shift&&a.allowHorizontalScroll&&(x=3*x*a.scrollHorizontalLineChange,a.scroll(re,0<x?"left":"right",Math.abs(x)));else{switch(b){case 0:re="pixel";break;case 1:re="line";break;case 2:re="page"}ee!==0&&a.allowHorizontalScroll&&(ee*=a.scrollHorizontalLineChange/16,a.scroll(re,0<ee?"right":"left",Math.abs(ee))),z!==0&&a.allowVerticalScroll&&(z*=a.scrollVerticalLineChange/16,a.scroll(re,0<z?"down":"up",Math.abs(z)))}this.doWheelChange(a,E,y)}}},Ni.prototype.doWheelChange=function(a,y,x){a.position.D(y)&&x.event.wheelDeltaX===0||(x.bubbles=!1)},Ni.prototype.standardWaitAfter=function(a,y){y===void 0&&(y=this.diagram.lastInput),this.cancelWaitAfter();var x=this,E=y.clone(this.yy);this.Zr=ji(function(){x.doWaitAfter(E)},a)},Ni.prototype.cancelWaitAfter=function(){this.Zr!==-1&&Kt.clearTimeout(this.Zr),this.Zr=-1},Ni.prototype.doWaitAfter=function(){},Ni.prototype.findToolHandleAt=function(a,y){return a=this.diagram.ic(a,function(x){for(;x!==null&&!(x.panel instanceof Fo);)x=x.panel;return x}),a===null?null:a.part.category===y?a:null},Ni.prototype.isBeyondDragSize=function(a,y){var x=this.diagram;a===void 0&&(a=x.firstInput.viewPoint),y===void 0&&(y=x.lastInput.viewPoint);var E=x.toolManager.dragSize,b=E.width;return E=E.height,x.firstInput.isTouchEvent&&(b+=6,E+=6),Math.abs(y.x-a.x)>b||Math.abs(y.y-a.y)>E},Yt.Object.defineProperties(Ni.prototype,{diagram:{get:function(){return this.H},set:function(a){a instanceof bt&&(this.H=a)}},name:{get:function(){return this.xa},set:function(a){this.xa=a}},isEnabled:{get:function(){return this.Jd},set:function(a){this.Jd=a}},isActive:{get:function(){return this.nb},set:function(a){this.nb=a}},transactionResult:{get:function(){return this.wm},set:function(a){this.wm=a}}}),Ni.prototype.startTransaction=Ni.prototype.Ea,Ni.className="Tool";function sa(){Ni.call(this),this.name="ToolManager",this.hb=new An,this.ob=new An,this.Hb=new An,this.F=this.V=850,this.o=new fn(2,2).ja(),this.Ha=5e3,this.ia=Mh,this.u=fc,this.Mp=this.j=null,this.zj=-1}Ct(sa,Ni),sa.prototype.initializeStandardTools=function(){},sa.prototype.updateAdornments=function(a){var y=this.currentToolTip;if(y instanceof Fo&&this.Mp===a){var x=y.adornedObject;(a!==null?x.part===a:x===null)?this.showToolTip(y,x):this.hideToolTip()}},sa.prototype.doMouseDown=function(){var a=this.diagram,y=a.lastInput;if(y.isTouchEvent&&this.gestureBehavior===kh&&(y.bubbles=!1),y.isMultiTouch){if(this.cancelWaitAfter(),this.gestureBehavior===Fh){y.bubbles=!0;return}if(this.gestureBehavior===kh)return;if(a.currentTool.canStartMultiTouch()){a.currentTool.standardPinchZoomStart();return}}for(var x=this.mouseDownTools.length,E=0;E<x;E++){var b=this.mouseDownTools.M(E);if(b.diagram=this.diagram,b.canStart()){a.doFocus(),a.currentTool=b,a.currentTool===b&&(b.isActive||b.doActivate(),b.doMouseDown());return}}a.lastInput.button===1&&(this.mouseWheelBehavior===Mh?this.mouseWheelBehavior=bc:this.mouseWheelBehavior===bc&&(this.mouseWheelBehavior=Mh)),this.doActivate(),this.standardWaitAfter(this.holdDelay,y)},sa.prototype.doMouseMove=function(){var a=this.diagram,y=a.lastInput;if(y.isMultiTouch){if(this.gestureBehavior===Fh){y.bubbles=!0;return}if(this.gestureBehavior===kh)return;if(a.currentTool.canStartMultiTouch()){a.currentTool.standardPinchZoomMove();return}}if(this.isActive)for(var x=this.mouseMoveTools.length,E=0;E<x;E++){var b=this.mouseMoveTools.M(E);if(b.diagram=this.diagram,b.canStart()){a.doFocus(),a.currentTool=b,a.currentTool===b&&(b.isActive||b.doActivate(),b.doMouseMove());return}}mo(this,a),a=y.event,a===null||a.type!=="pointermove"&&a.cancelable||(y.bubbles=!0)};function mo(a,y){a.standardMouseOver(),a.isBeyondDragSize()&&a.standardWaitAfter(a.isActive?a.holdDelay:a.hoverDelay,y.lastInput)}sa.prototype.doCurrentObjectChanged=function(a,y){a=this.currentToolTip,a===null||y!==null&&a instanceof Fo&&(y===a||y.rg(a))||this.hideToolTip()},sa.prototype.doWaitAfter=function(a){var y=this.diagram;y.ta!==null&&(this.doMouseHover(),this.isActive||this.doToolTip(),a.isTouchEvent&&!y.lastInput.handled&&(a=a.copy(),a.button=2,a.buttons=2,y.lastInput=a,y.qu=!0,y.doMouseUp()))},sa.prototype.doMouseHover=function(){var a=this.diagram,y=a.lastInput;y.targetObject===null&&(y.targetObject=a.ic(y.documentPoint,null,null));var x=y.targetObject;if(x!==null)for(y.handled=!1;x!==null&&(a=this.isActive?x.mouseHold:x.mouseHover,!(a!==null&&(a(y,x),y.handled)));)x=x.panel;else x=this.isActive?a.mouseHold:a.mouseHover,x!==null&&x(y)},sa.prototype.doToolTip=function(){var a=this.diagram,y=a.lastInput;if(y.targetObject===null&&(y.targetObject=a.ic(y.documentPoint,null,null)),y=y.targetObject,y!==null){if(a=this.currentToolTip,!(a instanceof Fo)||y!==a&&!y.rg(a)){for(;y!==null;){if(a=y.toolTip,a!==null){this.showToolTip(a,y);return}y=y.panel}this.hideToolTip()}}else y=a.toolTip,y!==null?this.showToolTip(y,null):this.hideToolTip()},sa.prototype.showToolTip=function(a,y){var x=this.diagram;if(a!==this.currentToolTip&&this.hideToolTip(),a instanceof Fo){a.layerName="Tool",a.selectable=!1,a.scale=1/x.scale,a.category="ToolTip",a.placeholder!==null&&(a.placeholder.scale=x.scale);var E=a.diagram;E!==null&&E!==x&&E.remove(a),x.add(a),y!==null?a.adornedObject=y:a.data=x.model,a.Va(),this.positionToolTip(a,y)}else a instanceof Sn&&a!==this.currentToolTip&&a.show(y,x,this);if(this.currentToolTip=a,this.zj!==-1&&(Kt.clearTimeout(this.zj),this.zj=-1),a=this.toolTipDuration,0<a&&a!==1/0){var b=this;this.zj=ji(function(){b.hideToolTip()},a)}},sa.prototype.positionToolTip=function(a){if(a.placeholder===null){var y=this.diagram,x=y.lastInput.documentPoint.copy(),E=a.measuredBounds,b=y.viewportBounds;y.lastInput.isTouchEvent&&(x.x-=E.width),x.x+E.width>b.right&&(x.x-=E.width+5/y.scale),x.x<b.x&&(x.x=b.x),x.y=x.y+20/y.scale+E.height>b.bottom?x.y-(E.height+5/y.scale):x.y+20/y.scale,x.y<b.y&&(x.y=b.y),a.position=x}},sa.prototype.hideToolTip=function(){this.zj!==-1&&(Kt.clearTimeout(this.zj),this.zj=-1);var a=this.diagram,y=this.currentToolTip;y!==null&&(y instanceof Fo?(a.remove(y),this.Mp!==null&&this.Mp.Jf(y.category),y.data=null,y.adornedObject=null):y instanceof Sn&&y.hide!==null&&y.hide(a,this),this.currentToolTip=null)},sa.prototype.doMouseUp=function(){this.cancelWaitAfter();var a=this.diagram;if(this.isActive)for(var y=this.mouseUpTools.length,x=0;x<y;x++){var E=this.mouseUpTools.M(x);if(E.diagram=this.diagram,E.canStart()){a.doFocus(),a.currentTool=E,a.currentTool===E&&(E.isActive||E.doActivate(),E.doMouseUp());return}}a.doFocus(),this.doDeactivate()},sa.prototype.doMouseWheel=function(){this.standardMouseWheel()},sa.prototype.doKeyDown=function(){var a=this.diagram;a.commandHandler!==null&&a.commandHandler.doKeyDown()},sa.prototype.doKeyUp=function(){var a=this.diagram;a.commandHandler!==null&&a.commandHandler.doKeyUp()},sa.prototype.findTool=function(a){for(var y=this.mouseDownTools.length,x=0;x<y;x++){var E=this.mouseDownTools.M(x);if(E.name===a)return E}for(y=this.mouseMoveTools.length,x=0;x<y;x++)if(E=this.mouseMoveTools.M(x),E.name===a)return E;for(y=this.mouseUpTools.length,x=0;x<y;x++)if(E=this.mouseUpTools.M(x),E.name===a)return E;return null},sa.prototype.replaceTool=function(a,y){y!==null&&(y.diagram=this.diagram);for(var x=this.mouseDownTools.length,E=0;E<x;E++){var b=this.mouseDownTools.M(E);if(b.name===a)return y!==null?this.mouseDownTools.cd(E,y):this.mouseDownTools.mb(E),b}for(x=this.mouseMoveTools.length,E=0;E<x;E++)if(b=this.mouseMoveTools.M(E),b.name===a)return y!==null?this.mouseMoveTools.cd(E,y):this.mouseMoveTools.mb(E),b;for(x=this.mouseUpTools.length,E=0;E<x;E++)if(b=this.mouseUpTools.M(E),b.name===a)return y!==null?this.mouseUpTools.cd(E,y):this.mouseUpTools.mb(E),b;return null},sa.prototype.gb=function(a,y,x){y!==null&&(y.name=a,y.diagram=this.diagram),this.findTool(a)?this.replaceTool(a,y):y!==null&&x.add(y)},Yt.Object.defineProperties(sa.prototype,{mouseWheelBehavior:{get:function(){return this.ia},set:function(a){this.ia=a}},gestureBehavior:{get:function(){return this.u},set:function(a){this.u=a}},currentToolTip:{get:function(){return this.j},set:function(a){this.j=a,this.Mp=a!==null&&a instanceof Fo?a.adornedPart:null}},mouseDownTools:{get:function(){return this.hb}},mouseMoveTools:{get:function(){return this.ob}},mouseUpTools:{get:function(){return this.Hb}},hoverDelay:{get:function(){return this.V},set:function(a){this.V=a}},holdDelay:{get:function(){return this.F},set:function(a){this.F=a}},dragSize:{get:function(){return this.o},set:function(a){this.o=a.J()}},toolTipDuration:{get:function(){return this.Ha},set:function(a){this.Ha=a}}}),sa.prototype.replaceStandardTool=sa.prototype.gb;var Mh=new Vt(sa,"WheelScroll",0),bc=new Vt(sa,"WheelZoom",1),Ic=new Vt(sa,"WheelNone",2),fc=new Vt(sa,"GestureZoom",3),kh=new Vt(sa,"GestureCancel",4),Fh=new Vt(sa,"GestureNone",5);sa.className="ToolManager",sa.WheelScroll=Mh,sa.WheelZoom=bc,sa.WheelNone=Ic,sa.GestureZoom=fc,sa.GestureCancel=kh,sa.GestureNone=Fh;function Br(){Ni.call(this),this.name="Dragging",this.u=this.Sw=this.ob=!0,this.o=this.Ha=this.V=this.Oe=null,this.Ym=this.Hb=!1,this.tl=new Qe(NaN,NaN),this.Fr=new Qe,this.hb=!0,this.Ik=100,this.Cg=[],this.te=new Pn().freeze(),this.ia=new ae,this.Bn=null,this.F="copy",this.Oc="",this.Pc="no-drop"}var Wl;Ct(Br,Ni),Br.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;if(a.isReadOnly&&!a.allowDragOut||!a.allowMove&&!a.allowCopy&&!a.allowDragOut||!a.allowSelect)return!1;var y=a.lastInput;return!y.left||a.currentTool!==this&&(!this.isBeyondDragSize()||y.isTouchEvent&&y.timestamp-a.firstInput.timestamp<this.Ik)?!1:this.findDraggablePart()!==null},Br.prototype.findDraggablePart=function(){var a=this.diagram;if(a=a.Ol(a.firstInput.documentPoint,!1),a===null)return null;for(;a!==null&&!a.canSelect();)a=a.containingGroup;return a!==null&&(a.canMove()||a.canCopy())?a:null},Br.prototype.standardMouseSelect=function(){var a=this.diagram;if(a.allowSelect){var y=a.Ol(a.firstInput.documentPoint,!1);if(y!==null){for(;y!==null&&!y.canSelect();)y=y.containingGroup;this.currentPart=y,this.currentPart===null||this.currentPart.isSelected||(a.R("ChangingSelection",a.selection),y=a.lastInput,(Fs?y.meta:y.control)||y.shift||a.clearSelection(!0),this.currentPart.isSelected=!0,a.R("ChangedSelection",a.selection))}}},Br.prototype.doActivate=function(){var a=this.diagram;this.Bn=null,this.currentPart===null&&this.standardMouseSelect();var y=this.currentPart;y!==null&&(y.canMove()||y.canCopy())&&(a.Fu(!0),Gi=null,this.isActive=!0,this.tl.set(a.position),Ue(this,a.selection),this.Cg.length=0,a.animationManager.Cc(),this.draggedParts=this.computeEffectiveCollection(a.selection,this.dragOptions),this.Sw=this.diagram.layout.isRealtime,this.diagram.layout.isRealtime=!1,a.Ns=!0,a.Gf("temporaryPixelRatio")===!0&&30<a.$w&&nr(a),Jl(a,this.draggedParts),this.Ea("Drag"),this.startPoint=a.firstInput.documentPoint,a.isMouseCaptured=!0,a.allowDragOut&&(this.isDragOutStarted=!0,this.Ym=!1,Gi=this,mr=this.diagram,this.doSimulatedDragOut()))};function Ue(a,y){if(a.dragsLink){var x=a.diagram;x.allowRelink&&(x.model.Wj()&&y.count===1&&y.first()instanceof Tn?(a.draggedLink=y.first(),a.draggedLink.canRelinkFrom()&&a.draggedLink.canRelinkTo()&&a.draggedLink.Ej(),a.Oe=x.toolManager.findTool("Relinking"),a.Oe===null&&(a.Oe=new Te,a.Oe.diagram=x),a.Oe.originalLink=a.draggedLink):(a.draggedLink=null,a.Oe=null))}}Br.prototype.computeEffectiveCollection=function(a,y){return this.diagram.commandHandler.computeEffectiveCollection(a,y)},Br.prototype.Pd=function(a){return a===void 0?new nd(bs):this.isGridSnapEnabled?new nd(new Qe(Math.round(1e3*a.x)/1e3,Math.round(1e3*a.y)/1e3)):new nd(a.copy())},Br.prototype.doDeactivate=function(){this.isActive=!1;var a=this.diagram;if(this.diagram.layout.isRealtime=this.Sw,a.Fu(!1),a.ug(),ht(this),Qs(a,this.draggedParts),this.draggedParts=this.currentPart=this.Bn=null,this.Ym=this.isDragOutStarted=!1,0<Wl.count){for(var y=Wl,x=y.length,E=0;E<x;E++){var b=y.M(E);en(b),Ht(b),ht(b),b.diagram.ug()}y.clear()}en(this),this.tl.h(NaN,NaN),mr!==null&&(mr.currentCursor=""),Gi=mr=null,Ht(this),a.isMouseCaptured=!1,a.currentCursor="",a.Ns=!1,this.stopTransaction(),ho(a,!0)},Br.prototype.stopTransaction=function(){var a=this.diagram,y=Ni.prototype.stopTransaction.call(this);return y&&a.undoManager.transactionToUndo!==null&&a.undoManager.transactionToUndo.ak(),y};function ht(a){var y=a.diagram,x=y.skipsUndoManager;y.skipsUndoManager=!0,Gn(a,y.lastInput,null),y.skipsUndoManager=x,a.Cg.length=0}function pt(){var a=Gi;Ht(a),En(a);var y=a.diagram;a.tl.w()&&(y.position=a.tl),y.ug()}Br.prototype.doCancel=function(){Ht(this),En(this);var a=this.diagram;this.tl.w()&&(a.position=this.tl),this.stopTool()},Br.prototype.doKeyDown=function(){var a=this.diagram,y=a.lastInput;this.isActive&&(y.key==="Esc"?this.doCancel():y.key!==a.previousInput.key&&this.doMouseMove())},Br.prototype.doKeyUp=function(){this.isActive&&this.doMouseMove()};function xt(a,y){if(a.copiedParts===null){var x=a.diagram;if((!y||!x.isReadOnly&&!x.isModelReadOnly)&&a.draggedParts!==null){var E=x.undoManager;for(E.isEnabled&&E.isInTransaction?E.currentTransaction!==null&&0<E.currentTransaction.changes.count&&(x.undoManager.Kf(),x.Ea("Drag")):En(a),x.skipsUndoManager=!y,x.partManager.addsToTemporaryLayer=!y,a.startPoint=x.firstInput.documentPoint,y=a.copiesEffectiveCollection?a.draggedParts.Lf():x.selection,y=x.Kj(y,x,!0),x=new Li,E=a.draggedParts.iterator;E.next();){var b=E.key;if(b.Zc()&&b.canCopy()){var z=y.I(b);z!==null&&(z.location=b.location,z.Va(),x.add(z,a.Pd(z.location)))}}for(y=y.iterator;y.next();)E=y.value,E instanceof Tn&&E.canCopy()&&x.add(E,a.Pd());a.copiedParts=x,Ue(a,x.Lf()),a.draggedLink!==null&&(x=a.draggedLink,y=x.routeBounds,bd(x,a.startPoint.x-(y.x+y.width/2),a.startPoint.y-(y.y+y.height/2))),a.doUpdateCursor(null)}}}function Ht(a){var y=a.diagram;if(a.copiedParts!==null){if(y.Is(a.copiedParts.Lf(),!1),a.copiedParts=null,a.draggedParts!==null)for(var x=a.draggedParts.iterator;x.next();)x.key instanceof Tn&&(x.value.point=new Qe(0,0));a.doUpdateCursor(null)}y.skipsUndoManager=!1,y.partManager.addsToTemporaryLayer=!1,a.startPoint=y.firstInput.documentPoint}function en(a){if(a.draggedLink!==null){if(a.dragsLink&&a.Oe!==null){var y=a.Oe;y.diagram.remove(y.temporaryFromNode),y.diagram.remove(y.temporaryToNode),a.Oe.originalLink=null}a.draggedLink=null,a.Oe=null}}function un(a,y,x){var E=a.diagram,b=a.startPoint,z=Qe.alloc();z.assign(E.lastInput.documentPoint),a.moveParts(y,z.re(b),x),Qe.free(z),E.Gf("temporaryPixelRatio")===!0&&E.Yh===null&&30<E.$w&&(nr(E),E.hk())}Br.prototype.moveParts=function(a,y,x){x===void 0&&(x=!1);var E=this.diagram;E!==null&&cs(E,a,y,this.dragOptions,x)};function En(a){if(a.draggedParts!==null){for(var y=a.diagram,x=a.draggedParts.iterator;x.next();){var E=x.key;E.Zc()&&(E.location=x.value.point)}for(x=a.draggedParts.iterator;x.next();)if(E=x.key,E instanceof Tn&&E.suspendsRouting){var b=x.value.point;a.draggedParts.add(E,a.Pd()),bd(E,-b.x,-b.y)}y.bd()}}function Yn(a,y){var x=a.diagram;a.dragsLink&&(a.draggedLink!==null&&(a.draggedLink.fromNode=null,a.draggedLink.toNode=null),gi(a,!1));var E=a.findDragOverObject(y),b=x.lastInput;b.targetObject=E,a.doUpdateCursor(E);var z=x.skipsUndoManager,ee=!1;try{if(x.skipsUndoManager=!0,ee=Gn(a,b,E),!a.isActive&&Gi===null)return;var re=E!==null?E.part:null;if(re===null||x.handlesDragDropForTopLevelParts&&re.isTopLevel&&!(re instanceof xr)){var oe=x.mouseDragOver;oe!==null&&(oe(b),ee=!0)}if(!a.isActive&&Gi===null||(a.doDragOver(y,E),!a.isActive&&Gi===null))return}finally{x.skipsUndoManager=z,ee&&x.bd()}a.Bn=E,x.isReadOnly||!x.allowMove&&!x.allowCopy||!x.allowHorizontalScroll&&!x.allowVerticalScroll||x.gs(b.viewPoint)}Br.prototype.findDragOverObject=function(a){var y=this;return ya(this.diagram,a,null,function(x){return x===null?x=!0:(x=x.part,x=!!(x===null||x instanceof Fo||x.layer.isTemporary||y.draggedParts&&y.draggedParts.contains(x)||y.copiedParts&&y.copiedParts.contains(x))),!x})},Br.prototype.doUpdateCursor=function(a){var y=this.diagram;(a===null||this.Bn!==a)&&(!this.diagram.currentTool.isActive||this.mayCopy()?y.currentCursor=this.copyCursor:this.mayMove()?y.currentCursor=this.moveCursor:this.mayDragOut()&&(y.currentCursor=this.nodropCursor))};function Gn(a,y,x){var E=!1,b=a.Cg.length,z=0<b?a.Cg[0]:null;if(x===z)return!1;y.handled=!1;for(var ee=0;ee<b;ee++){var re=a.Cg[ee],oe=re.mouseDragLeave;if(oe!==null&&(oe(y,re,x),E=!0,y.handled))break}if(a.Cg.length=0,!a.isActive&&Gi===null||x===null)return E;for(y.handled=!1,b=x;b!==null;)a.Cg.push(b),b=Si(b);for(b=a.Cg.length,x=0;x<b&&(ee=a.Cg[x],re=ee.mouseDragEnter,re===null||(re(y,ee,z),E=!0,!y.handled));x++);return E}function Si(a){var y=a.panel;return y!==null?y:a instanceof Ii&&!(a instanceof xr)&&(a=a.containingGroup,a!==null&&a.handlesDragDropForMembers)?a:null}function Un(a,y,x){var E=a.Oe;if(E===null)return null;var b=a.diagram.og(y,E.portGravity,function(se){return E.findValidLinkablePort(se,x)});a=Qe.alloc();var z=1/0,ee=null;for(b=b.iterator;b.next();){var re=b.value;if(re.part!==null){var oe=re.ga(ko,a);oe=y.Bf(oe),oe<z&&(ee=re,z=oe)}}return Qe.free(a),ee}function gi(a,y){var x=a.draggedLink;if(x!==null&&!(2>x.pointsCount)){var E=a.diagram;if(!E.isReadOnly){var b=a.Oe;if(b!==null){var z=null,ee=null;x.fromNode===null&&(z=Un(a,x.i(0),!1),z!==null&&(ee=z.part));var re=null,oe=null;x.toNode===null&&(re=Un(a,x.i(x.pointsCount-1),!0),re!==null&&(oe=re.part)),b.isValidLink(ee,z,oe,re)?y?(x.defaultFromPoint=x.i(0),x.defaultToPoint=x.i(x.pointsCount-1),x.suspendsRouting=!1,x.fromNode=ee,z!==null&&(x.fromPortId=z.portId),x.toNode=oe,re!==null&&(x.toPortId=re.portId),x.fromPort!==E.Mx&&E.R("LinkRelinked",x,E.Mx),x.toPort!==E.Nx&&E.R("LinkRelinked",x,E.Nx)):Oe(b,ee,z,oe,re):Oe(b,null,null,null,null)}}}}Br.prototype.doDragOver=function(){};function ii(a,y){var x=a.diagram;a.dragsLink&&gi(a,!0),ht(a);var E=a.findDragOverObject(y),b=x.lastInput;if(b.targetObject=E,E!==null){b.handled=!1;for(var z=E;z!==null;){var ee=z.mouseDrop;if(ee!==null&&(ee(b,z),b.handled))break;Oi(a,b,z),z=Si(z)}}else z=x.mouseDrop,z!==null&&z(b);if(a.isActive||Gi!==null){for(b=(a.copiedParts||a.draggedParts).iterator;b.next();)z=b.key,z instanceof qn&&z.linksConnected.each(function(re){re.suspendsRouting=!1});if(a.doDropOnto(y,E),a.isActive||Gi!==null){for(a=Xt.alloc(),y=x.selection.iterator;y.next();)E=y.value,E instanceof qn&&lr(x,E,a);Xt.free(a)}}}function Oi(a,y,x){a=a.diagram,x=x.part,!a.handlesDragDropForTopLevelParts||!x.isTopLevel||x instanceof xr||(x=a.mouseDrop,x!==null&&x(y))}function lr(a,y,x){var E=!1;if(x=y.getAvoidableRect(x),a.viewportBounds.Re(x)&&(E=!0),a=a.Nu(x,function(b){return b.part},function(b){return b instanceof Tn},!0,function(b){return b instanceof Tn},E),a.count!==0)for(a=a.iterator;a.next();)x=a.value,!x.Td(y)&&x.isAvoiding&&x.bb()}Br.prototype.doDropOnto=function(){},Br.prototype.doMouseMove=function(){if(this.isActive){var a=this.diagram,y=a.lastInput;this.simulatedMouseMove(y.event,y.documentPoint,y.targetDiagram)||this.currentPart===null||this.draggedParts===null||(this.mayCopy()?(xt(this,!1),Jl(a,this.copiedParts),un(this,this.copiedParts,!1),Qs(a,this.copiedParts)):this.mayMove()?(Ht(this),un(this,this.draggedParts,!0)):this.mayDragOut()?(xt(this,!1),un(this,this.copiedParts,!1)):Ht(this),Yn(this,a.lastInput.documentPoint))}},Br.prototype.doMouseUp=function(){if(this.isActive){var a=this.diagram,y=a.lastInput;if(!this.simulatedMouseUp(y.event,y.documentPoint,y.targetDiagram)){y=!1;var x=this.mayCopy();if(x&&this.copiedParts!==null?(Ht(this),xt(this,!0),Jl(a,this.copiedParts),un(this,this.copiedParts,!1),Qs(a,this.copiedParts),this.copiedParts!==null&&(a.R("ChangingSelection",a.selection),a.clearSelection(!0),this.copiedParts.iteratorKeys.each(function(b){b.isSelected=!0}))):(y=!0,Ht(this),this.mayMove()&&(un(this,this.draggedParts,!0),Yn(this,a.lastInput.documentPoint))),this.Ym=!0,ii(this,a.lastInput.documentPoint),this.isActive){var E=x?this.copiedParts.Lf():this.draggedParts.Lf();this.copiedParts=null,y&&br(this),a.Ya(),Qs(a,this.draggedParts),this.transactionResult=x?"Copy":"Move",a.R(x?"SelectionCopied":"SelectionMoved",E)}this.stopTool(),x&&a.R("ChangedSelection",a.selection)}}},Br.prototype.simulatedMouseMove=function(a,y,x){if(Gi===null)return!1;var E=Gi.diagram;x instanceof bt||(x=null);var b=mr;return x!==b&&(b!==null&&b!==E&&(b.ug(),Gi.isDragOutStarted=!1,b=b.toolManager.findTool("Dragging"),b!==null&&b.doSimulatedDragLeave()),mr=x,x!==null&&x!==E&&(pt(),b=x.toolManager.findTool("Dragging"),b!==null&&(Wl.contains(b)||Wl.add(b),b.doSimulatedDragEnter())),this.doUpdateCursor(null)),x===null||x===E||!x.allowDrop||x.isReadOnly||!x.allowInsert?!1:(E=x.toolManager.findTool("Dragging"),E!==null&&(a!==null&&(a.targetTouches!==void 0&&(0<a.targetTouches.length?a=a.targetTouches[0]:0<a.changedTouches.length&&(a=a.changedTouches[0])),y=x.getMouse(a)),x.lastInput.documentPoint=y,x.lastInput.viewPoint=x.op(y),x.lastInput.down=!1,x.lastInput.up=!1,E.doSimulatedDragOver()),!0)},Br.prototype.simulatedMouseUp=function(a,y,x){if(Gi===null)return!1;var E=mr,b=Gi.diagram;if(x===null)return Gi.doCancel(),!0;if(x!==E){var z=E.toolManager.findTool("Dragging");if(E!==null&&E!==b&&z!==null)return E.ug(),Gi.isDragOutStarted=!1,z.doSimulatedDragLeave(),!1;mr=x,E=x.toolManager.findTool("Dragging"),E!==null&&(pt(),Wl.contains(E)||Wl.add(E),E.doSimulatedDragEnter())}return x!==this.diagram?(a!==null?(a.targetTouches!==void 0&&(0<a.targetTouches.length?a=a.targetTouches[0]:0<a.changedTouches.length&&(a=a.changedTouches[0])),y=x.getMouse(a)):y===null&&(y=new Qe),x.lastInput.documentPoint=y,x.lastInput.viewPoint=x.op(y),x.lastInput.down=!1,x.lastInput.up=!0,a=x.toolManager.findTool("Dragging"),a!==null&&a.doSimulatedDrop(),a=Gi,a!==null&&(x=a.mayCopy(),a.transactionResult=x?"Copy":"Move",a.stopTool()),!0):!1};function br(a){if(a.draggedParts!==null)for(var y=a.draggedParts.iterator;y.next();){var x=y.key;x instanceof qn&&(x=x.containingGroup,x===null||x.placeholder===null||a.draggedParts.contains(x)||x.placeholder.v())}}Br.prototype.mayCopy=function(){if(!this.isCopyEnabled)return!1;var a=this.diagram;if(a.isReadOnly||a.isModelReadOnly||!a.allowInsert||!a.allowCopy||(Fs?!a.lastInput.alt:!a.lastInput.control))return!1;for(a=a.selection.iterator;a.next();)if(a.value.canCopy())return!0;return!!(this.draggedLink!==null&&this.dragsLink&&this.draggedLink.canCopy())},Br.prototype.mayDragOut=function(){if(!this.isCopyEnabled)return!1;var a=this.diagram;if(!a.allowDragOut||!a.allowCopy||a.allowMove)return!1;for(a=a.selection.iterator;a.next();)if(a.value.canCopy())return!0;return!!(this.draggedLink!==null&&this.dragsLink&&this.draggedLink.canCopy())},Br.prototype.mayMove=function(){var a=this.diagram;if(a.isReadOnly||!a.allowMove)return!1;for(a=a.selection.iterator;a.next();)if(a.value.canMove())return!0;return!!(this.draggedLink!==null&&this.dragsLink&&this.draggedLink.canMove())},Br.prototype.computeBorder=function(a,y,x){return this.Ym||this.draggedParts===null||this.draggedParts.contains(a)?null:x.assign(y)},Br.prototype.Az=function(){return Gi},Br.prototype.mayDragIn=function(){var a=this.diagram;if(!a.allowDrop||a.isReadOnly||a.isModelReadOnly||!a.allowInsert)return!1;var y=Gi;return!(y===null||y.diagram.model.dataFormat!==a.model.dataFormat)},Br.prototype.doSimulatedDragEnter=function(){if(this.mayDragIn()){var a=this.diagram;a.animationManager.Cc(),Os(a),a.animationManager.Cc(),a=Gi,a!==null&&(a.diagram.Ns=!1),this.doUpdateCursor(null)}},Br.prototype.doSimulatedDragLeave=function(){var a=Gi;a!==null&&a.doSimulatedDragOut(),this.doCancel()},Br.prototype.doSimulatedDragOver=function(){var a=this.diagram;a.animationManager.Dm=!0;var y=Gi;if(y!==null&&y.draggedParts!==null){if(!this.mayDragIn())return;Zr(this,y.draggedParts.Lf(),!1,a.firstInput),un(this,this.copiedParts,!1),Yn(this,a.lastInput.documentPoint)}a.animationManager.Dm=!1},Br.prototype.doSimulatedDrop=function(){var a=this.diagram,y=Gi;if(y!==null){var x=y.diagram;if(y.Ym=!0,Ht(this),!this.mayDragIn())return;a.animationManager.Dm=!0,a.R("ChangingSelection",a.selection),this.Ea("Drop"),Zr(this,y.draggedParts.Lf(),!0,a.lastInput),un(this,this.copiedParts,!1);var E=new Pn;this.copiedParts!==null&&(a.clearSelection(!0),this.copiedParts.iteratorKeys.each(function(b){b.isSelected=!0,E.add(b)})),ii(this,a.lastInput.documentPoint),a.Ya(),this.copiedParts!==null&&(this.transactionResult="ExternalCopy"),this.copiedParts=null,a.doFocus(),a.R("ExternalObjectsDropped",E,x),this.stopTransaction(),a.R("ChangedSelection",a.selection)}a.animationManager.Dm=!1};function Zr(a,y,x,E){if(a.copiedParts===null){var b=a.diagram;if(!b.isReadOnly&&!b.isModelReadOnly){b.skipsUndoManager=!x,b.partManager.addsToTemporaryLayer=!x,a.startPoint=E.documentPoint,x=b.Kj(y,b,!0);var z=Xt.alloc();b=E=1/0;for(var ee=-1/0,re=-1/0,oe=y.iterator;oe.next();){var se=oe.value;if(se.isVisible()){var ue=se.location;se=ue.x,ue=ue.y,isNaN(se)||isNaN(ue)||(se<E&&(E=se),ue<b&&(b=ue),se>ee&&(ee=se),ue>re&&(re=ue))}}for(E===1/0?z.h(0,0,0,0):z.h(E,b,ee-E,re-b),E=z.x+z.width/2,b=z.y+z.height/2,Xt.free(z),z=a.Fr,ee=new Li,re=Qe.alloc(),oe=y.iterator;oe.next();)se=oe.value,se instanceof Tn&&se.canCopy()&&(ue=x.I(se),ue!==null&&(ue.points=se.points,bd(ue,z.x-E,z.y-b),ue.suspendsRouting=!0,ee.add(ue,a.Pd())));for(y=y.iterator;y.next();)se=y.value,se.Zc()&&se.canCopy()&&(oe=x.I(se),oe!==null&&(se=se.location,re.h(z.x-(E-se.x),z.y-(b-se.y)),oe.location=re,oe.Va(),ee.add(oe,a.Pd(re))));Qe.free(re),a.copiedParts=ee,Ue(a,ee.Lf()),a.draggedLink!==null&&(x=a.draggedLink,y=x.routeBounds,bd(x,a.startPoint.x-(y.x+y.width/2),a.startPoint.y-(y.y+y.height/2))),a.doUpdateCursor(null)}}}Br.prototype.doSimulatedDragOut=function(){var a=this.diagram;a.Ns=!1,this.mayCopy()||this.mayMove()?a.currentCursor="":a.currentCursor=this.nodropCursor,this.Bn=null},Br.prototype.computeMove=function(a,y,x,E){return x=this.diagram,x!==null?x.computeMove(a,y,this.dragOptions,E):new Qe},Yt.Object.defineProperties(Br.prototype,{isCopyEnabled:{get:function(){return this.ob},set:function(a){this.ob=a}},copiesEffectiveCollection:{get:function(){return this.u},set:function(a){this.u=a}},dragOptions:{get:function(){return this.ia},set:function(a){this.ia=a}},isGridSnapEnabled:{get:function(){return this.dragOptions.isGridSnapEnabled},set:function(a){this.dragOptions.isGridSnapEnabled=a}},isComplexRoutingRealtime:{get:function(){return this.hb},set:function(a){this.hb=a}},isGridSnapRealtime:{get:function(){return this.dragOptions.isGridSnapRealtime},set:function(a){this.dragOptions.isGridSnapRealtime=a}},gridSnapCellSize:{get:function(){return this.dragOptions.gridSnapCellSize},set:function(a){this.dragOptions.gridSnapCellSize.D(a)||(a=a.J(),this.dragOptions.gridSnapCellSize=a)}},gridSnapCellSpot:{get:function(){return this.dragOptions.gridSnapCellSpot},set:function(a){this.dragOptions.gridSnapCellSpot.D(a)||(a=a.J(),this.dragOptions.gridSnapCellSpot=a)}},gridSnapOrigin:{get:function(){return this.dragOptions.gridSnapOrigin},set:function(a){this.dragOptions.gridSnapOrigin.D(a)||(a=a.J(),this.dragOptions.gridSnapOrigin=a)}},dragsLink:{get:function(){return this.dragOptions.dragsLink},set:function(a){this.dragOptions.dragsLink=a}},dragsTree:{get:function(){return this.dragOptions.dragsTree},set:function(a){this.dragOptions.dragsTree=a}},copyCursor:{get:function(){return this.F},set:function(a){this.F=a}},moveCursor:{get:function(){return this.Oc},set:function(a){this.Oc=a}},nodropCursor:{get:function(){return this.Pc},set:function(a){this.Pc=a}},currentPart:{get:function(){return this.V},set:function(a){this.V=a}},copiedParts:{get:function(){return this.o},set:function(a){this.o=a}},draggedParts:{get:function(){return this.Ha},set:function(a){this.Ha=a}},draggingParts:{get:function(){return this.copiedParts!==null?this.copiedParts.Lf():this.draggedParts!==null?this.draggedParts.Lf():this.te}},draggedLink:{get:function(){return this.diagram.draggedLink},set:function(a){this.diagram.draggedLink=a}},isDragOutStarted:{get:function(){return this.Hb},set:function(a){this.Hb=a}},startPoint:{get:function(){return this.Fr},set:function(a){this.Fr.D(a)||this.Fr.assign(a)}},delay:{get:function(){return this.Ik},set:function(a){this.Ik=a}}}),Br.prototype.getDraggingSource=Br.prototype.Az;var Gi=null,mr=null;Br.className="DraggingTool",Wl=new An,ri("draggingTool",function(){return this.findTool("Dragging")},function(a){this.gb("Dragging",a,this.mouseMoveTools)}),sa.prototype.doCancel=function(){Gi!==null&&Gi.doCancel(),Ni.prototype.doCancel.call(this)};function er(){Ni.call(this),this.te=100,this.Ha=!1,this.u="pointer";var a=new Tn,y=new Dr;y.isPanelMain=!0,y.stroke="blue",a.add(y),y=new Dr,y.toArrow="Standard",y.fill="blue",y.stroke="blue",a.add(y),a.layerName="Tool",this.Ci=a,a=new qn,y=new Dr,y.portId="",y.figure="Rectangle",y.fill=null,y.stroke="magenta",y.strokeWidth=2,y.desiredSize=Ao,a.add(y),a.selectable=!1,a.layerName="Tool",this.Bi=a,this.j=y,a=new qn,y=new Dr,y.portId="",y.figure="Rectangle",y.fill=null,y.stroke="magenta",y.strokeWidth=2,y.desiredSize=Ao,a.add(y),a.selectable=!1,a.layerName="Tool",this.Di=a,this.o=y,this.Pc=this.Oc=this.ob=this.hb=this.Hb=null,this.ia=!0,this.hy=new Li,this.Of=this.gj=this.Pf=null}Ct(er,Ni),er.prototype.doStop=function(){this.diagram.ug(),this.originalToPort=this.originalToNode=this.originalFromPort=this.originalFromNode=this.originalLink=null,this.validPortsCache.clear(),this.targetPort=null},er.prototype.copyPortProperties=function(a,y,x,E,b){if(a!==null&&y!==null&&x!==null&&E!==null){var z=y.Df(),ee=fn.alloc();ee.width=y.naturalBounds.width*z,ee.height=y.naturalBounds.height*z,E.desiredSize=ee,fn.free(ee),b?(E.toSpot=y.toSpot,E.toEndSegmentLength=y.toEndSegmentLength):(E.fromSpot=y.fromSpot,E.fromEndSegmentLength=y.fromEndSegmentLength),x.locationSpot=ko,z=Qe.alloc(),x.location=y.ga(ko,z),Qe.free(z),E.angle=y.li(),this.portTargeted!==null&&this.portTargeted(a,y,x,E,b)}},er.prototype.setNoTargetPortProperties=function(a,y,x){y!==null&&(y.desiredSize=Ao,y.fromSpot=Ms,y.toSpot=Ms),a!==null&&(a.location=this.diagram.lastInput.documentPoint),this.portTargeted!==null&&this.portTargeted(null,null,a,y,x)},er.prototype.doMouseDown=function(){this.isActive&&this.doMouseMove()},er.prototype.doMouseMove=function(){if(this.isActive){var a=this.diagram;if(this.targetPort=this.findTargetPort(this.isForwards),this.targetPort!==null&&this.targetPort.part instanceof qn){var y=this.targetPort.part;this.isForwards?this.copyPortProperties(y,this.targetPort,this.temporaryToNode,this.temporaryToPort,!0):this.copyPortProperties(y,this.targetPort,this.temporaryFromNode,this.temporaryFromPort,!1)}else this.isForwards?this.setNoTargetPortProperties(this.temporaryToNode,this.temporaryToPort,!0):this.setNoTargetPortProperties(this.temporaryFromNode,this.temporaryFromPort,!1);(a.allowHorizontalScroll||a.allowVerticalScroll)&&a.gs(a.lastInput.viewPoint)}},er.prototype.findValidLinkablePort=function(a,y){if(a===null)return null;var x=a.part;if(!(x instanceof qn))return null;for(;a!==null;){var E=y?a.toLinkable:a.fromLinkable;if(E===!0&&(a.portId!==null||a instanceof qn)&&(y?this.isValidTo(x,a):this.isValidFrom(x,a)))return a;if(E===!1)break;a=a.panel}return null},er.prototype.findTargetPort=function(a){var y=this.diagram,x=y.lastInput.documentPoint,E=this.portGravity;0>=E&&(E=.1);var b=this,z=y.og(x,E,function(fe){return b.findValidLinkablePort(fe,a)},null,!0);for(E=1/0,y=null,z=z.iterator;z.next();){var ee=z.value,re=ee.part;if(re instanceof qn){var oe=ee.ga(ko,Qe.alloc()),se=x.x-oe.x,ue=x.y-oe.y;Qe.free(oe),oe=se*se+ue*ue,oe<E&&(se=this.validPortsCache.I(ee),se!==null?se&&(y=ee,E=oe):a&&this.isValidLink(this.originalFromNode,this.originalFromPort,re,ee)||!a&&this.isValidLink(re,ee,this.originalToNode,this.originalToPort)?(this.validPortsCache.add(ee,!0),y=ee,E=oe):this.validPortsCache.add(ee,!1))}}return y!==null&&(x=y.part,x instanceof qn&&(x.layer===null||x.layer.allowLink))?y:null},er.prototype.isValidFrom=function(a,y){if(a===null||y===null)return this.isUnconnectedLinkValid;if(this.diagram.currentTool===this&&(a.layer!==null&&!a.layer.allowLink||y.fromLinkable!==!0))return!1;var x=y.fromMaxLinks;if(1/0>x){if(this.originalLink!==null&&a===this.originalFromNode&&y===this.originalFromPort)return!0;if(y=y.portId,y===null&&(y=""),a.Mo(y).count>=x)return!1}return!0},er.prototype.isValidTo=function(a,y){if(a===null||y===null)return this.isUnconnectedLinkValid;if(this.diagram.currentTool===this&&(a.layer!==null&&!a.layer.allowLink||y.toLinkable!==!0))return!1;var x=y.toMaxLinks;if(1/0>x){if(this.originalLink!==null&&a===this.originalToNode&&y===this.originalToPort)return!0;if(y=y.portId,y===null&&(y=""),a.Sd(y).count>=x)return!1}return!0},er.prototype.isInSameNode=function(a,y){return a===null||y===null?!1:a===y?!0:(a=a.part,y=y.part,a!==null&&a===y)},er.prototype.isLinked=function(a,y){if(a===null||y===null)return!1;var x=a.part;if(!(x instanceof qn))return!1;a=a.portId,a===null&&(a="");var E=y.part;if(!(E instanceof qn))return!1;for(y=y.portId,y===null&&(y=""),y=E.Sd(y);y.next();)if(E=y.value,E.fromNode===x&&E.fromPortId===a)return!0;return!1},er.prototype.isValidLink=function(a,y,x,E){if(!this.isValidFrom(a,y)||!this.isValidTo(x,E)||!(y===null||E===null||(y.fromLinkableSelfNode&&E.toLinkableSelfNode||!this.isInSameNode(y,E))&&(y.fromLinkableDuplicates&&E.toLinkableDuplicates||!this.isLinked(y,E)))||this.originalLink!==null&&(a!==null&&this.isLabelDependentOnLink(a,this.originalLink)||x!==null&&this.isLabelDependentOnLink(x,this.originalLink))||a!==null&&x!==null&&(a.data===null&&x.data!==null||a.data!==null&&x.data===null)||!this.isValidCycle(a,x,this.originalLink))return!1;if(a!==null){var b=a.linkValidation;if(b!==null&&!b(a,y,x,E,this.originalLink))return!1}return x!==null&&(b=x.linkValidation,b!==null&&!b(a,y,x,E,this.originalLink))?!1:(b=this.linkValidation,b!==null?b(a,y,x,E,this.originalLink):!0)},er.prototype.isLabelDependentOnLink=function(a,y){if(a===null)return!1;var x=a.labeledLink;if(x===null)return!1;if(x===y)return!0;var E=new Pn;return E.add(a),Yr(this,x,y,E)};function Yr(a,y,x,E){if(y===x)return!0;var b=y.fromNode;return b!==null&&b.isLinkLabel&&(E.add(b),Yr(a,b.labeledLink,x,E))?!0:(y=y.toNode,!!(y!==null&&y.isLinkLabel&&(E.add(y),Yr(a,y.labeledLink,x,E))))}er.prototype.isValidCycle=function(a,y,x){if(x===void 0&&(x=null),a===null||y===null)return this.isUnconnectedLinkValid;var E=this.diagram.validCycle;if(E!==Of){if(E===ap){if(E=x||this.temporaryLink,E!==null&&!E.isTreeLink)return!0;for(E=y.linksConnected;E.next();){var b=E.value;if(b!==x&&b.isTreeLink&&b.toNode===y)return!1}return!No(this,a,y,x,!0)}if(E===sp){if(E=x||this.temporaryLink,E!==null&&!E.isTreeLink)return!0;for(E=a.linksConnected;E.next();)if(b=E.value,b!==x&&b.isTreeLink&&b.fromNode===a)return!1;return!No(this,a,y,x,!0)}if(E===ip)return a===y?a=!0:(E=new Pn,E.add(y),a=Wr(this,E,a,y,x)),!a;if(E===rp)return!No(this,a,y,x,!1);if(E===op)return a===y?a=!0:(E=new Pn,E.add(y),a=da(this,E,a,y,x)),!a}return!0};function No(a,y,x,E,b){if(y===x)return!0;if(y===null||x===null)return!1;for(var z=y.linksConnected;z.next();){var ee=z.value;if(ee!==E&&(!b||ee.isTreeLink)&&ee.toNode===y&&(ee=ee.fromNode,ee!==y&&No(a,ee,x,E,b)))return!0}return!1}function Wr(a,y,x,E,b){if(x===E)return!0;if(x===null||E===null||y.contains(x))return!1;y.add(x);for(var z=x.linksConnected;z.next();){var ee=z.value;if(ee!==b&&ee.toNode===x&&(ee=ee.fromNode,ee!==x&&Wr(a,y,ee,E,b)))return!0}return!1}function da(a,y,x,E,b){if(x===E)return!0;if(x===null||E===null||y.contains(x))return!1;y.add(x);for(var z=x.linksConnected;z.next();){var ee=z.value;if(ee!==b){var re=ee.fromNode;if(ee=ee.toNode,re=re===x?ee:re,re!==x&&da(a,y,re,E,b))return!0}}return!1}Yt.Object.defineProperties(er.prototype,{portGravity:{get:function(){return this.te},set:function(a){0<=a&&(this.te=a)}},isUnconnectedLinkValid:{get:function(){return this.Ha},set:function(a){this.Ha=a}},linkingCursor:{get:function(){return this.u},set:function(a){this.u=a}},temporaryLink:{get:function(){return this.Ci},set:function(a){this.Ci=a}},temporaryFromNode:{get:function(){return this.Bi},set:function(a){(this.Bi=a)&&(this.j=a.port)}},temporaryFromPort:{get:function(){return this.j},set:function(a){if(this.j!==null){var y=this.j.panel;if(y!==null){var x=y.O.indexOf(this.j);y.mb(x),y.Gb(x,a)}}this.j=a}},temporaryToNode:{get:function(){return this.Di},set:function(a){(this.Di=a)&&(this.o=a.port)}},temporaryToPort:{get:function(){return this.o},set:function(a){if(this.o!==null){var y=this.o.panel;if(y!==null){var x=y.O.indexOf(this.o);y.mb(x),y.Gb(x,a)}}this.o=a}},originalLink:{get:function(){return this.Hb},set:function(a){this.Hb=a}},originalFromNode:{get:function(){return this.hb},set:function(a){this.hb=a}},originalFromPort:{get:function(){return this.ob},set:function(a){this.ob=a}},originalToNode:{get:function(){return this.Oc},set:function(a){this.Oc=a}},originalToPort:{get:function(){return this.Pc},set:function(a){this.Pc=a}},isForwards:{get:function(){return this.ia},set:function(a){this.ia=a}},validPortsCache:{get:function(){return this.hy}},targetPort:{get:function(){return this.Pf},set:function(a){this.Pf=a}},linkValidation:{get:function(){return this.gj},set:function(a){this.gj=a}},portTargeted:{get:function(){return this.Of},set:function(a){this.Of=a}}}),er.className="LinkingBaseTool";function To(){er.call(this),this.name="Linking",this.V={},this.F=null,this.K=la,this.Xd=null}Ct(To,er),To.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;return a.isReadOnly||a.isModelReadOnly||!a.allowLink||!a.model.xs()||!a.lastInput.left||a.currentTool!==this&&!this.isBeyondDragSize()?!1:this.findLinkablePort()!==null},To.prototype.findLinkablePort=function(){var a=this.diagram,y=this.startObject;if(y===null&&(y=a.ic(a.firstInput.documentPoint,null,null)),y===null||(a=y.part,!(a instanceof qn)))return null;var x=this.direction;if(x===la||x===ys){var E=this.findValidLinkablePort(y,!1);if(E!==null||this.startObject===a&&(E=a.port,this.findValidLinkablePort(E,!1)))return this.isForwards=!0,E}return(x===la||x===Da)&&(y=this.findValidLinkablePort(y,!0),y!==null||this.startObject===a&&(y=a.port,this.findValidLinkablePort(y,!0)))?(this.isForwards=!1,y):null},To.prototype.doActivate=function(){var a=this.diagram,y=this.findLinkablePort();y===null?this.stopTool():(this.Ea(this.name),a.isMouseCaptured=!0,a.currentCursor=this.linkingCursor,this.isForwards?(this.temporaryToNode!==null&&(this.temporaryToNode.location=a.lastInput.documentPoint),this.originalFromPort=y,y=this.originalFromPort.part,y instanceof qn&&(this.originalFromNode=y),this.copyPortProperties(this.originalFromNode,this.originalFromPort,this.temporaryFromNode,this.temporaryFromPort,!1)):(this.temporaryFromNode!==null&&(this.temporaryFromNode.location=a.lastInput.documentPoint),this.originalToPort=y,y=this.originalToPort.part,y instanceof qn&&(this.originalToNode=y),this.copyPortProperties(this.originalToNode,this.originalToPort,this.temporaryToNode,this.temporaryToPort,!0)),a.add(this.temporaryFromNode),this.temporaryFromNode&&this.temporaryFromNode.Va(),a.add(this.temporaryToNode),this.temporaryToNode&&this.temporaryToNode.Va(),this.temporaryLink!==null&&(this.temporaryFromNode!==null&&(this.temporaryLink.fromNode=this.temporaryFromNode),this.temporaryToNode!==null&&(this.temporaryLink.toNode=this.temporaryToNode),this.temporaryLink.isTreeLink=this.isNewTreeLink(),this.temporaryLink.bb(),a.add(this.temporaryLink)),this.isActive=!0)},To.prototype.doDeactivate=function(){this.isActive=!1;var a=this.diagram;a.remove(this.temporaryLink),a.remove(this.temporaryFromNode),a.remove(this.temporaryToNode),a.isMouseCaptured=!1,a.currentCursor="",this.stopTransaction()},To.prototype.doStop=function(){er.prototype.doStop.call(this),this.startObject=null},To.prototype.doMouseUp=function(){if(this.isActive){var a=this.diagram,y=this.transactionResult=null,x=null,E=null,b=null,z=null;try{var ee=this.targetPort=this.findTargetPort(this.isForwards);if(ee!==null){var re=ee.part;re instanceof qn&&(this.isForwards?(this.originalFromNode!==null&&(y=this.originalFromNode,x=this.originalFromPort),E=re,b=ee):(y=re,x=ee,this.originalToNode!==null&&(E=this.originalToNode,b=this.originalToPort)))}else this.isForwards?this.originalFromNode!==null&&this.isUnconnectedLinkValid&&(y=this.originalFromNode,x=this.originalFromPort):this.originalToNode!==null&&this.isUnconnectedLinkValid&&(E=this.originalToNode,b=this.originalToPort);y!==null||E!==null?(z=this.insertLink(y,x,E,b),z!==null?(ee===null&&(this.isForwards?z.defaultToPoint=a.lastInput.documentPoint:z.defaultFromPoint=a.lastInput.documentPoint),a.allowSelect&&(a.R("ChangingSelection",a.selection),a.clearSelection(!0),z.isSelected=!0),this.transactionResult=this.name,a.R("LinkDrawn",z)):this.doNoLink(y,x,E,b)):this.isForwards?this.doNoLink(this.originalFromNode,this.originalFromPort,null,null):this.doNoLink(null,null,this.originalToNode,this.originalToPort)}finally{this.stopTool(),z&&a.allowSelect&&a.R("ChangedSelection",a.selection)}}},To.prototype.isNewTreeLink=function(){var a=this.archetypeLinkData;if(a===null)return!0;if(a instanceof Tn)return a.isTreeLink;var y=this.diagram;return y===null?!0:(a=y.partManager.getLinkCategoryForData(a),y=y.partManager.findLinkTemplateForCategory(a),y!==null?y.isTreeLink:!0)},To.prototype.insertLink=function(a,y,x,E){return this.diagram.partManager.insertLink(a,y,x,E)},To.prototype.doNoLink=function(){},Yt.Object.defineProperties(To.prototype,{archetypeLinkData:{get:function(){return this.V},set:function(a){this.V=a}},archetypeLabelNodeData:{get:function(){return this.F},set:function(a){this.F=a}},direction:{get:function(){return this.K},set:function(a){this.K=a}},startObject:{get:function(){return this.Xd},set:function(a){this.Xd=a}}});var la=new Vt(To,"Either",0),ys=new Vt(To,"ForwardsOnly",0),Da=new Vt(To,"BackwardsOnly",0);To.className="LinkingTool",To.Either=la,To.ForwardsOnly=ys,To.BackwardsOnly=Da;function Te(){er.call(this),this.name="Relinking";var a=new Dr;a.figure="Diamond",a.desiredSize=Ia,a.fill="lightblue",a.stroke="dodgerblue",a.cursor=this.linkingCursor,a.segmentIndex=0,this.V=a,a=new Dr,a.figure="Diamond",a.desiredSize=Ia,a.fill="lightblue",a.stroke="dodgerblue",a.cursor=this.linkingCursor,a.segmentIndex=-1,this.Xd=a,this.F=null,this.Ew=new Xt}Ct(Te,er),Te.prototype.updateAdornments=function(a){if(a!==null&&a instanceof Tn){var y="RelinkFrom",x=null;if(a.isSelected&&!this.diagram.isReadOnly){var E=a.selectionObject;E!==null&&a.canRelinkFrom()&&a.actualBounds.w()&&a.isVisible()&&E.actualBounds.w()&&E.Ed()&&(x=a.Pj(y),x===null&&(x=this.makeAdornment(E,!1),a.bh(y,x)))}x===null&&a.Jf(y),y="RelinkTo",x=null,a.isSelected&&!this.diagram.isReadOnly&&(E=a.selectionObject,E!==null&&a.canRelinkTo()&&a.actualBounds.w()&&a.isVisible()&&E.actualBounds.w()&&E.Ed()&&(x=a.Pj(y),x===null?(x=this.makeAdornment(E,!0),a.bh(y,x)):x.v())),x===null&&a.Jf(y)}},Te.prototype.makeAdornment=function(a,y){var x=new Fo;return x.type=Ln.Link,y=y?this.toHandleArchetype:this.fromHandleArchetype,y!==null&&x.add(y.copy()),x.adornedObject=a,x},Te.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;if(a.isReadOnly||a.isModelReadOnly||!a.allowRelink||!a.model.xs()||!a.lastInput.left)return!1;var y=this.findToolHandleAt(a.firstInput.documentPoint,"RelinkFrom");return y===null&&(y=this.findToolHandleAt(a.firstInput.documentPoint,"RelinkTo")),y!==null},Te.prototype.doActivate=function(){var a=this.diagram;if(this.originalLink===null){var y=this.handle;if(y===null&&(y=this.findToolHandleAt(a.firstInput.documentPoint,"RelinkFrom"),y===null&&(y=this.findToolHandleAt(a.firstInput.documentPoint,"RelinkTo"))),y===null)return;var x=y.part;if(!(x instanceof Fo&&x.adornedPart instanceof Tn))return;this.handle=y,this.isForwards=x===null||x.category==="RelinkTo",this.originalLink=x.adornedPart}this.Ea(this.name),a.isMouseCaptured=!0,a.currentCursor=this.linkingCursor,this.originalFromPort=this.originalLink.fromPort,this.originalFromNode=this.originalLink.fromNode,this.originalToPort=this.originalLink.toPort,this.originalToNode=this.originalLink.toNode,this.Ew.set(this.originalLink.actualBounds),this.originalLink!==null&&0<this.originalLink.pointsCount&&(this.originalLink.fromNode===null&&(this.temporaryFromPort!==null&&(this.temporaryFromPort.desiredSize=jr),this.temporaryFromNode!==null&&(this.temporaryFromNode.location=this.originalLink.i(0))),this.originalLink.toNode===null&&(this.temporaryToPort!==null&&(this.temporaryToPort.desiredSize=jr),this.temporaryToNode!==null&&(this.temporaryToNode.location=this.originalLink.i(this.originalLink.pointsCount-1)))),this.copyPortProperties(this.originalFromNode,this.originalFromPort,this.temporaryFromNode,this.temporaryFromPort,!1),this.copyPortProperties(this.originalToNode,this.originalToPort,this.temporaryToNode,this.temporaryToPort,!0),a.add(this.temporaryFromNode),a.add(this.temporaryToNode),this.temporaryLink!==null&&(this.temporaryFromNode!==null&&(this.temporaryLink.fromNode=this.temporaryFromNode),this.temporaryToNode!==null&&(this.temporaryLink.toNode=this.temporaryToNode),this.copyLinkProperties(this.originalLink,this.temporaryLink),this.temporaryLink.bb(),a.add(this.temporaryLink)),this.isActive=!0},Te.prototype.copyLinkProperties=function(a,y){if(a!==null&&y!==null){y.adjusting=a.adjusting,y.corner=a.corner;var x=a.curve;(x===Ag||x===Ld)&&(x=Pu),y.curve=x,y.curviness=a.curviness,y.isTreeLink=a.isTreeLink,y.points=a.points,y.routing=a.routing,y.smoothness=a.smoothness,y.fromSpot=a.fromSpot,y.fromEndSegmentLength=a.fromEndSegmentLength,y.fromShortLength=a.fromShortLength,y.toSpot=a.toSpot,y.toEndSegmentLength=a.toEndSegmentLength,y.toShortLength=a.toShortLength}},Te.prototype.doDeactivate=function(){this.isActive=!1;var a=this.diagram;a.remove(this.temporaryLink),a.remove(this.temporaryFromNode),a.remove(this.temporaryToNode),a.isMouseCaptured=!1,a.currentCursor="",this.stopTransaction()},Te.prototype.doStop=function(){er.prototype.doStop.call(this),this.handle=null},Te.prototype.doMouseUp=function(){if(this.isActive){var a=this.diagram;this.transactionResult=null;var y=this.originalFromNode,x=this.originalFromPort,E=this.originalToNode,b=this.originalToPort,z=this.originalLink;try{if(this.targetPort=this.findTargetPort(this.isForwards),this.targetPort!==null){var ee=this.targetPort.part;ee instanceof qn&&(this.isForwards?(E=ee,b=this.targetPort):(y=ee,x=this.targetPort))}else this.isUnconnectedLinkValid?this.isForwards?b=E=null:x=y=null:z=null;z!==null?(this.reconnectLink(z,this.isForwards?E:y,this.isForwards?b:x,this.isForwards),this.targetPort===null&&(this.isForwards?z.defaultToPoint=a.lastInput.documentPoint:z.defaultFromPoint=a.lastInput.documentPoint,z.bb()),this.transactionResult=this.name,a.R("LinkRelinked",z,this.isForwards?this.originalToPort:this.originalFromPort)):this.doNoRelink(this.originalLink,this.isForwards),this.originalLink.Xo(this.Ew)}finally{this.stopTool()}}},Te.prototype.reconnectLink=function(a,y,x,E){return x=x!==null&&x.portId!==null?x.portId:"",E?(a.toNode=y,a.toPortId=x):(a.fromNode=y,a.fromPortId=x),!0},Te.prototype.doNoRelink=function(){};function Oe(a,y,x,E,b){y!==null?(a.copyPortProperties(y,x,a.temporaryFromNode,a.temporaryFromPort,!1),a.diagram.add(a.temporaryFromNode)):a.diagram.remove(a.temporaryFromNode),E!==null?(a.copyPortProperties(E,b,a.temporaryToNode,a.temporaryToPort,!0),a.diagram.add(a.temporaryToNode)):a.diagram.remove(a.temporaryToNode)}Yt.Object.defineProperties(Te.prototype,{fromHandleArchetype:{get:function(){return this.V},set:function(a){this.V=a}},toHandleArchetype:{get:function(){return this.Xd},set:function(a){this.Xd=a}},handle:{get:function(){return this.F},set:function(a){if(a!==null&&!(a.part instanceof Fo))throw Error("new handle is not in an Adornment: "+a);this.F=a}}}),Te.className="RelinkingTool",ri("linkingTool",function(){return this.findTool("Linking")},function(a){this.gb("Linking",a,this.mouseMoveTools)}),ri("relinkingTool",function(){return this.findTool("Relinking")},function(a){this.gb("Relinking",a,this.mouseDownTools)});function Xe(){Ni.call(this),this.name="LinkReshaping";var a=new Dr;a.figure="Rectangle",a.desiredSize=$a,a.fill="lightblue",a.stroke="dodgerblue",this.o=a,a=new Dr,a.figure="Diamond",a.desiredSize=Ia,a.fill="lightblue",a.stroke="dodgerblue",a.cursor="move",this.u=a,this.F=3,this.Ts=this.j=null,this.Fw=new Qe,this.Yq=new An}Ct(Xe,Ni),Xe.prototype.Ru=function(a){return a&&a.reshapingBehavior.value!==0?a.reshapingBehavior:Rt},Xe.prototype.om=function(a,y){a.reshapingBehavior=y},Xe.prototype.updateAdornments=function(a){if(a!==null&&a instanceof Tn){var y=null;if(a.isSelected&&!this.diagram.isReadOnly){var x=a.path;x!==null&&a.canReshape()&&a.actualBounds.w()&&a.isVisible()&&x.actualBounds.w()&&x.Ed()&&(y=a.Pj(this.name),y===null||y.Aw!==a.pointsCount||y.Uw!==a.resegmentable)&&(y=this.makeAdornment(x),y!==null&&(y.Aw=a.pointsCount,y.Uw=a.resegmentable,a.bh(this.name,y)))}y===null&&a.Jf(this.name)}},Xe.prototype.makeAdornment=function(a){var y=a.part,x=y.pointsCount,E=y.isOrthogonal,b=null;if(y.points!==null&&1<x){b=new Fo,b.type=Ln.Link,x=y.firstPickIndex;var z=y.lastPickIndex,ee=E?1:0;if(y.resegmentable&&y.computeCurve()!==vh)for(var re=x+ee;re<z-ee;re++){var oe=this.makeResegmentHandle(a,re);oe!==null&&(oe.segmentIndex=re,oe.segmentFraction=.5,oe.fromMaxLinks=999,b.add(oe))}for(ee=x+1;ee<z;ee++)if(re=this.makeHandle(a,ee),re!==null){if(re.segmentIndex=ee,ee!==x)if(ee===x+1&&E){oe=y.i(x);var se=y.i(x+1);yt.B(oe.x,se.x)&&yt.B(oe.y,se.y)&&(se=y.i(x-1)),yt.B(oe.x,se.x)?(this.om(re,Le),re.cursor="n-resize"):yt.B(oe.y,se.y)&&(this.om(re,Se),re.cursor="w-resize")}else ee===z-1&&E?(oe=y.i(z-1),se=y.i(z),yt.B(oe.x,se.x)&&yt.B(oe.y,se.y)&&(oe=y.i(z+1)),yt.B(oe.x,se.x)?(this.om(re,Le),re.cursor="n-resize"):yt.B(oe.y,se.y)&&(this.om(re,Se),re.cursor="w-resize")):ee!==z&&(this.om(re,je),re.cursor="move");b.add(re)}b.adornedObject=a}return b},Xe.prototype.makeHandle=function(){var a=this.handleArchetype;return a===null?null:a.copy()},Xe.prototype.makeResegmentHandle=function(){var a=this.midHandleArchetype;return a===null?null:a.copy()},Xe.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;return!a.isReadOnly&&a.allowReshape&&a.lastInput.left?this.findToolHandleAt(a.firstInput.documentPoint,this.name)!==null:!1},Xe.prototype.doActivate=function(){var a=this.diagram;if(this.handle===null&&(this.handle=this.findToolHandleAt(a.firstInput.documentPoint,this.name)),this.handle!==null){var y=this.handle.part.adornedPart;if(y instanceof Tn){if(this.Ts=y,a.isMouseCaptured=!0,this.Ea(this.name),y.resegmentable&&this.handle.fromMaxLinks===999){var x=y.points.copy(),E=this.getResegmentingPoint();if(x.Gb(this.handle.segmentIndex+1,E),y.isOrthogonal&&x.Gb(this.handle.segmentIndex+1,E),y.points=x,y.Wb(),y.updateAdornments(),this.handle=this.findToolHandleAt(a.firstInput.documentPoint,this.name),this.handle===null){this.doDeactivate();return}}this.Fw=y.i(this.handle.segmentIndex),this.Yq=y.points.copy(),this.isActive=!0}}},Xe.prototype.doDeactivate=function(){this.stopTransaction(),this.Ts=this.handle=null,this.isActive=this.diagram.isMouseCaptured=!1},Xe.prototype.stopTransaction=function(){var a=this.diagram,y=Ni.prototype.stopTransaction.call(this);return y&&a.undoManager.transactionToUndo!==null&&a.undoManager.transactionToUndo.ak(),y},Xe.prototype.doCancel=function(){var a=this.adornedLink;a!==null&&(a.points=this.Yq),this.stopTool()},Xe.prototype.getResegmentingPoint=function(){return this.handle.ga(ko)},Xe.prototype.doMouseMove=function(){var a=this.diagram;this.isActive&&(a=this.computeReshape(a.lastInput.documentPoint),this.reshape(a))},Xe.prototype.doMouseUp=function(){var a=this.diagram;if(this.isActive){var y=this.computeReshape(a.lastInput.documentPoint);if(this.reshape(y),y=this.adornedLink,y!==null&&y.resegmentable){var x=this.handle.segmentIndex,E=y.i(x-1),b=y.i(x),z=y.i(x+1);if(y.isOrthogonal){if(x>y.firstPickIndex+1&&x<y.lastPickIndex-1){var ee=y.i(x-2);if(Math.abs(E.x-b.x)<this.resegmentingDistance&&Math.abs(E.y-b.y)<this.resegmentingDistance&&(ot(this,ee,E,b,z,!0)||ot(this,ee,E,b,z,!1))){var re=y.points.copy();ot(this,ee,E,b,z,!0)?(re.cd(x-2,new Qe(ee.x,(z.y+ee.y)/2)),re.cd(x+1,new Qe(z.x,(z.y+ee.y)/2))):(re.cd(x-2,new Qe((z.x+ee.x)/2,ee.y)),re.cd(x+1,new Qe((z.x+ee.x)/2,z.y))),re.mb(x),re.mb(x-1),y.points=re,y.Wb()}else ee=y.i(x+2),Math.abs(b.x-z.x)<this.resegmentingDistance&&Math.abs(b.y-z.y)<this.resegmentingDistance&&(ot(this,E,b,z,ee,!0)||ot(this,E,b,z,ee,!1))&&(re=y.points.copy(),ot(this,E,b,z,ee,!0)?(re.cd(x-1,new Qe(E.x,(E.y+ee.y)/2)),re.cd(x+2,new Qe(ee.x,(E.y+ee.y)/2))):(re.cd(x-1,new Qe((E.x+ee.x)/2,E.y)),re.cd(x+2,new Qe((E.x+ee.x)/2,ee.y))),re.mb(x+1),re.mb(x),y.points=re,y.Wb())}}else ee=Qe.alloc(),yt.qh(E.x,E.y,z.x,z.y,b.x,b.y,ee)&&ee.Bf(b)<this.resegmentingDistance*this.resegmentingDistance&&(E=y.points.copy(),E.mb(x),y.points=E,y.Wb()),Qe.free(ee)}a.Ya(),this.transactionResult=this.name,a.R("LinkReshaped",this.adornedLink,this.Yq)}this.stopTool()};function ot(a,y,x,E,b,z){return z?Math.abs(y.y-x.y)<a.resegmentingDistance&&Math.abs(x.y-E.y)<a.resegmentingDistance&&Math.abs(E.y-b.y)<a.resegmentingDistance:Math.abs(y.x-x.x)<a.resegmentingDistance&&Math.abs(x.x-E.x)<a.resegmentingDistance&&Math.abs(E.x-b.x)<a.resegmentingDistance}Xe.prototype.reshape=function(a){var y=this.adornedLink;y.uh();var x=this.handle.segmentIndex,E=this.Ru(this.handle);if(y.isOrthogonal)if(x===y.firstPickIndex+1)x=y.firstPickIndex+1,E===Le?(y.L(x,y.i(x-1).x,a.y),y.L(x+1,y.i(x+2).x,a.y)):E===Se&&(y.L(x,a.x,y.i(x-1).y),y.L(x+1,a.x,y.i(x+2).y));else if(x===y.lastPickIndex-1)x=y.lastPickIndex-1,E===Le?(y.L(x-1,y.i(x-2).x,a.y),y.L(x,y.i(x+1).x,a.y)):E===Se&&(y.L(x-1,a.x,y.i(x-2).y),y.L(x,a.x,y.i(x+1).y));else{E=x;var b=y.i(E),z=y.i(E-1),ee=y.i(E+1);yt.B(z.x,b.x)&&yt.B(b.y,ee.y)?(yt.B(z.x,y.i(E-2).x)&&!yt.B(z.y,y.i(E-2).y)?(y.m(E,a.x,z.y),x++,E++):y.L(E-1,a.x,z.y),yt.B(ee.y,y.i(E+2).y)&&!yt.B(ee.x,y.i(E+2).x)?y.m(E+1,ee.x,a.y):y.L(E+1,ee.x,a.y)):yt.B(z.y,b.y)&&yt.B(b.x,ee.x)?(yt.B(z.y,y.i(E-2).y)&&!yt.B(z.x,y.i(E-2).x)?(y.m(E,z.x,a.y),x++,E++):y.L(E-1,z.x,a.y),yt.B(ee.x,y.i(E+2).x)&&!yt.B(ee.y,y.i(E+2).y)?y.m(E+1,a.x,ee.y):y.L(E+1,a.x,ee.y)):yt.B(z.x,b.x)&&yt.B(b.x,ee.x)?(yt.B(z.x,y.i(E-2).x)&&!yt.B(z.y,y.i(E-2).y)?(y.m(E,a.x,z.y),x++,E++):y.L(E-1,a.x,z.y),yt.B(ee.x,y.i(E+2).x)&&!yt.B(ee.y,y.i(E+2).y)?y.m(E+1,a.x,ee.y):y.L(E+1,a.x,ee.y)):yt.B(z.y,b.y)&&yt.B(b.y,ee.y)&&(yt.B(z.y,y.i(E-2).y)&&!yt.B(z.x,y.i(E-2).x)?(y.m(E,z.x,a.y),x++,E++):y.L(E-1,z.x,a.y),yt.B(ee.y,y.i(E+2).y)&&!yt.B(ee.x,y.i(E+2).x)?y.m(E+1,ee.x,a.y):y.L(E+1,ee.x,a.y)),y.L(x,a.x,a.y)}else y.L(x,a.x,a.y),E=y.fromNode,b=y.fromPort,E!==null&&(z=E.findVisibleNode(),z!==null&&z!==E&&(E=z,b=E.port)),x===1&&y.computeSpot(!0,b).Mc()&&(z=b.ga(ko,Qe.alloc()),E=y.getLinkPointFromPoint(E,b,z,a,!0,Qe.alloc()),y.L(0,E.x,E.y),Qe.free(z),Qe.free(E)),E=y.toNode,b=y.toPort,E!==null&&(z=E.findVisibleNode(),z!==null&&z!==E&&(E=z,b=E.port)),x===y.pointsCount-2&&y.computeSpot(!1,b).Mc()&&(x=b.ga(ko,Qe.alloc()),a=y.getLinkPointFromPoint(E,b,x,a,!1,Qe.alloc()),y.L(y.pointsCount-1,a.x,a.y),Qe.free(x),Qe.free(a));y.zf()},Xe.prototype.computeReshape=function(a){var y=this.adornedLink,x=this.handle.segmentIndex;switch(this.Ru(this.handle)){case je:return a;case Le:return new Qe(y.i(x).x,a.y);case Se:return new Qe(a.x,y.i(x).y);default:case Rt:return y.i(x)}},Yt.Object.defineProperties(Xe.prototype,{handleArchetype:{get:function(){return this.o},set:function(a){this.o=a}},midHandleArchetype:{get:function(){return this.u},set:function(a){this.u=a}},handle:{get:function(){return this.j},set:function(a){if(a!==null&&!(a.part instanceof Fo))throw Error("new handle is not in an Adornment: "+a);this.j=a}},adornedLink:{get:function(){return this.Ts}},resegmentingDistance:{get:function(){return this.F},set:function(a){this.F=a}},originalPoint:{get:function(){return this.Fw}},originalPoints:{get:function(){return this.Yq}}}),Xe.prototype.setReshapingBehavior=Xe.prototype.om,Xe.prototype.getReshapingBehavior=Xe.prototype.Ru;var Rt=new Vt(Xe,"None",0),Se=new Vt(Xe,"Horizontal",1),Le=new Vt(Xe,"Vertical",2),je=new Vt(Xe,"All",3);Xe.className="LinkReshapingTool",Xe.None=Rt,Xe.Horizontal=Se,Xe.Vertical=Le,Xe.All=je,ri("linkReshapingTool",function(){return this.findTool("LinkReshaping")},function(a){this.gb("LinkReshaping",a,this.mouseDownTools)});function Ke(){Ni.call(this),this.name="Resizing",this.o=new fn(1,1).freeze(),this.j=new fn(9999,9999).freeze(),this.yg=new fn(NaN,NaN).freeze(),this.V=!1,this.ia=!0,this.ue=null;var a=new Dr;a.alignmentFocus=ko,a.figure="Rectangle",a.desiredSize=$a,a.fill="lightblue",a.stroke="dodgerblue",a.strokeWidth=1,a.cursor="pointer",this.F=a,this.u=null,this.Xq=new Qe,this.Dw=new fn,this.Tn=new Qe,this.rt=new fn(0,0),this.qt=new fn(1/0,1/0),this.pt=new fn(1,1)}Ct(Ke,Ni),Ke.prototype.updateAdornments=function(a){if(!(a===null||a instanceof Tn)){if(a.isSelected&&!this.diagram.isReadOnly){var y=a.resizeObject,x=a.Pj(this.name);if(y!==null&&a.canResize()&&a.actualBounds.w()&&a.isVisible()&&y.actualBounds.w()&&y.Ed()&&((x===null||x.adornedObject!==y)&&(x=this.makeAdornment(y)),x!==null)){y=y.li(),Ud(a)&&this.updateResizeHandles(x,y),a.bh(this.name,x);return}}a.Jf(this.name)}},Ke.prototype.makeAdornment=function(a){var y=a.part.resizeAdornmentTemplate;if(y===null){y=new Fo,y.type=Ln.Spot,y.locationSpot=ko;var x=new wu;x.isPanelMain=!0,y.add(x),y.add(this.makeHandle(a,Cs)),y.add(this.makeHandle(a,lh)),y.add(this.makeHandle(a,Hl)),y.add(this.makeHandle(a,iu)),y.add(this.makeHandle(a,Ml)),y.add(this.makeHandle(a,Rs)),y.add(this.makeHandle(a,Us)),y.add(this.makeHandle(a,ol))}else if(_h(y),y=y.copy(),y===null)return null;return y.adornedObject=a,y},Ke.prototype.makeHandle=function(a,y){return a=this.handleArchetype,a===null?null:(a=a.copy(),a.alignment=y,a)},Ke.prototype.updateResizeHandles=function(a,y){if(a!==null){if(!a.alignment.Xb()&&(a.cursor==="pointer"||0<a.cursor.indexOf("resize")))e:{var x=a.alignment;if(x.Mc()&&(x=ko),0>=x.x)y=0>=x.y?y+225:1<=x.y?y+135:y+180;else if(1<=x.x)0>=x.y?y+=315:1<=x.y&&(y+=45);else if(0>=x.y)y+=270;else if(1<=x.y)y+=90;else break e;0>y?y+=360:360<=y&&(y-=360),a.cursor=22.5>y?"e-resize":67.5>y?"se-resize":112.5>y?"s-resize":157.5>y?"sw-resize":202.5>y?"w-resize":247.5>y?"nw-resize":292.5>y?"n-resize":337.5>y?"ne-resize":"e-resize"}else if(a instanceof Ln)for(a=a.elements;a.next();)this.updateResizeHandles(a.value,y)}},Ke.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;return!a.isReadOnly&&a.allowResize&&a.lastInput.left?this.findToolHandleAt(a.firstInput.documentPoint,this.name)!==null:!1},Ke.prototype.doActivate=function(){var a=this.diagram;this.handle===null&&(this.handle=this.findToolHandleAt(a.firstInput.documentPoint,this.name)),this.handle!==null&&(this.adornedObject=this.handle.part.adornedObject,this.adornedObject!==null&&(a.isMouseCaptured=!0,a.animationManager.Cc(),this.Ea(this.name),this.Xq.set(this.adornedObject.ga(this.handle.alignment.gv())),this.Tn.set(this.adornedObject.part.location),this.Dw.set(this.adornedObject.desiredSize),this.pt=this.computeCellSize(),this.rt=this.computeMinSize(),this.qt=this.computeMaxSize(),this.isActive=!0))},Ke.prototype.doDeactivate=function(){var a=this.diagram;this.stopTransaction(),this.ue=this.handle=null,this.isActive=a.isMouseCaptured=!1},Ke.prototype.stopTransaction=function(){var a=this.diagram,y=Ni.prototype.stopTransaction.call(this);return y&&a.undoManager.transactionToUndo!==null&&a.undoManager.transactionToUndo.ak(),y},Ke.prototype.doCancel=function(){this.adornedObject!==null&&(this.adornedObject.desiredSize=this.originalDesiredSize,this.adornedObject.part.location=this.originalLocation),this.stopTool()},Ke.prototype.doMouseMove=function(){var a=this.diagram;if(this.isActive){var y=this.rt,x=this.qt,E=this.pt,b=this.adornedObject.qs(a.lastInput.documentPoint,Qe.alloc()),z=this.computeReshape();y=this.computeResize(b,this.handle.alignment,y,x,E,z),this.resize(y),a.bd(),Qe.free(b)}},Ke.prototype.doMouseUp=function(){var a=this.diagram;if(this.isActive){var y=this.rt,x=this.qt,E=this.pt,b=this.adornedObject.qs(a.lastInput.documentPoint,Qe.alloc()),z=this.computeReshape();y=this.computeResize(b,this.handle.alignment,y,x,E,z),this.resize(y),Qe.free(b),a.Ya(),this.transactionResult=this.name,a.R("PartResized",this.adornedObject,this.originalDesiredSize)}this.stopTool()},Ke.prototype.resize=function(a){var y=this.diagram,x=this.adornedObject;if(x!==null){if(x.desiredSize=a.size,a=x.part,a.Va(),x=x.ga(this.handle.alignment.gv()),a instanceof xr){var E=new An;if(E.add(a),!this.dragsMembers&&a.placeholder===null){var b=new ae;b.dragsMembers=!1}y.moveParts(E,this.oppositePoint.copy().re(x),!0,b)}else a.location=a.location.copy().re(x).add(this.oppositePoint);y.bd()}},Ke.prototype.computeResize=function(a,y,x,E,b,z){y.Mc()&&(y=ko);var ee=this.adornedObject.naturalBounds,re=ee.x,oe=ee.y,se=ee.x+ee.width,ue=ee.y+ee.height,fe=1;if(!z){fe=ee.width;var ve=ee.height;0>=fe&&(fe=1),0>=ve&&(ve=1),fe=ve/fe}return ve=Qe.alloc(),yt.No(a.x,a.y,re,oe,b.width,b.height,ve),a=ee.copy(),0>=y.x?0>=y.y?(a.x=Math.max(ve.x,se-E.width),a.x=Math.min(a.x,se-x.width),a.width=Math.max(se-a.x,x.width),a.y=Math.max(ve.y,ue-E.height),a.y=Math.min(a.y,ue-x.height),a.height=Math.max(ue-a.y,x.height),z||(1<=a.height/a.width?(a.height=Math.max(Math.min(fe*a.width,E.height),x.height),a.width=a.height/fe):(a.width=Math.max(Math.min(a.height/fe,E.width),x.width),a.height=fe*a.width),a.x=se-a.width,a.y=ue-a.height)):1<=y.y?(a.x=Math.max(ve.x,se-E.width),a.x=Math.min(a.x,se-x.width),a.width=Math.max(se-a.x,x.width),a.height=Math.max(Math.min(ve.y-oe,E.height),x.height),z||(1<=a.height/a.width?(a.height=Math.max(Math.min(fe*a.width,E.height),x.height),a.width=a.height/fe):(a.width=Math.max(Math.min(a.height/fe,E.width),x.width),a.height=fe*a.width),a.x=se-a.width)):(a.x=Math.max(ve.x,se-E.width),a.x=Math.min(a.x,se-x.width),a.width=se-a.x,z||(a.height=Math.max(Math.min(fe*a.width,E.height),x.height),a.width=a.height/fe,a.y=oe+.5*(ue-oe-a.height))):1<=y.x?0>=y.y?(a.width=Math.max(Math.min(ve.x-re,E.width),x.width),a.y=Math.max(ve.y,ue-E.height),a.y=Math.min(a.y,ue-x.height),a.height=Math.max(ue-a.y,x.height),z||(1<=a.height/a.width?(a.height=Math.max(Math.min(fe*a.width,E.height),x.height),a.width=a.height/fe):(a.width=Math.max(Math.min(a.height/fe,E.width),x.width),a.height=fe*a.width),a.y=ue-a.height)):1<=y.y?(a.width=Math.max(Math.min(ve.x-re,E.width),x.width),a.height=Math.max(Math.min(ve.y-oe,E.height),x.height),z||(1<=a.height/a.width?(a.height=Math.max(Math.min(fe*a.width,E.height),x.height),a.width=a.height/fe):(a.width=Math.max(Math.min(a.height/fe,E.width),x.width),a.height=fe*a.width))):(a.width=Math.max(Math.min(ve.x-re,E.width),x.width),z||(a.height=Math.max(Math.min(fe*a.width,E.height),x.height),a.width=a.height/fe,a.y=oe+.5*(ue-oe-a.height))):0>=y.y?(a.y=Math.max(ve.y,ue-E.height),a.y=Math.min(a.y,ue-x.height),a.height=ue-a.y,z||(a.width=Math.max(Math.min(a.height/fe,E.width),x.width),a.height=fe*a.width,a.x=re+.5*(se-re-a.width))):1<=y.y&&(a.height=Math.max(Math.min(ve.y-oe,E.height),x.height),z||(a.width=Math.max(Math.min(a.height/fe,E.width),x.width),a.height=fe*a.width,a.x=re+.5*(se-re-a.width))),Qe.free(ve),a},Ke.prototype.computeReshape=function(){var a=mn;return this.adornedObject instanceof Dr&&(a=E0(this.adornedObject)),!(a===xi||this.diagram.lastInput.shift)},Ke.prototype.computeMinSize=function(){var a=this.adornedObject.minSize.copy(),y=this.minSize;return!isNaN(y.width)&&y.width>a.width&&(a.width=y.width),!isNaN(y.height)&&y.height>a.height&&(a.height=y.height),a},Ke.prototype.computeMaxSize=function(){var a=this.adornedObject.maxSize.copy(),y=this.maxSize;return!isNaN(y.width)&&y.width<a.width&&(a.width=y.width),!isNaN(y.height)&&y.height<a.height&&(a.height=y.height),a},Ke.prototype.computeCellSize=function(){var a=new fn(NaN,NaN),y=this.adornedObject.part;return y!==null&&(y=y.resizeCellSize,!isNaN(y.width)&&0<y.width&&(a.width=y.width),!isNaN(y.height)&&0<y.height&&(a.height=y.height)),y=this.cellSize,isNaN(a.width)&&!isNaN(y.width)&&0<y.width&&(a.width=y.width),isNaN(a.height)&&!isNaN(y.height)&&0<y.height&&(a.height=y.height),y=this.diagram,(isNaN(a.width)||isNaN(a.height))&&y&&(y=y.grid,y!==null&&y.visible&&this.isGridSnapEnabled&&(y=y.gridCellSize,isNaN(a.width)&&!isNaN(y.width)&&0<y.width&&(a.width=y.width),isNaN(a.height)&&!isNaN(y.height)&&0<y.height&&(a.height=y.height))),(isNaN(a.width)||a.width===0||a.width===1/0)&&(a.width=1),(isNaN(a.height)||a.height===0||a.height===1/0)&&(a.height=1),a},Yt.Object.defineProperties(Ke.prototype,{handleArchetype:{get:function(){return this.F},set:function(a){this.F=a}},handle:{get:function(){return this.u},set:function(a){if(a!==null&&!(a.part instanceof Fo))throw Error("new handle is not in an Adornment: "+a);this.u=a}},adornedObject:{get:function(){return this.ue},set:function(a){if(a!==null&&a.part instanceof Fo)throw Error("new handle must not be in an Adornment: "+a);this.ue=a}},minSize:{get:function(){return this.o},set:function(a){if(!this.o.D(a)){var y=a.width;isNaN(y)&&(y=0),a=a.height,isNaN(a)&&(a=0),this.o.h(y,a)}}},maxSize:{get:function(){return this.j},set:function(a){if(!this.j.D(a)){var y=a.width;isNaN(y)&&(y=1/0),a=a.height,isNaN(a)&&(a=1/0),this.j.h(y,a)}}},cellSize:{get:function(){return this.yg},set:function(a){this.yg.D(a)||this.yg.assign(a)}},isGridSnapEnabled:{get:function(){return this.V},set:function(a){this.V=a}},dragsMembers:{get:function(){return this.ia},set:function(a){this.ia=a}},oppositePoint:{get:function(){return this.Xq},set:function(a){this.Xq.D(a)||this.Xq.assign(a)}},originalDesiredSize:{get:function(){return this.Dw}},originalLocation:{get:function(){return this.Tn}}}),Ke.className="ResizingTool",ri("resizingTool",function(){return this.findTool("Resizing")},function(a){this.gb("Resizing",a,this.mouseDownTools)});function ct(){Ni.call(this),this.name="Rotating",this.ia=45,this.V=2,this.Tn=new Qe,this.ue=null;var a=new Dr;a.figure="Ellipse",a.desiredSize=Ia,a.fill="lightblue",a.stroke="dodgerblue",a.strokeWidth=1,a.cursor="pointer",this.o=a,this.j=null,this.Cw=0,this.kr=new Qe(NaN,NaN),this.u=0,this.F=50}Ct(ct,Ni),ct.prototype.updateAdornments=function(a){if(a!==null){if(a.ph()){var y=a.rotateObject;if(y===a||y===a.path||y.isPanelMain)return}if(a.isSelected&&!this.diagram.isReadOnly&&(y=a.rotateObject,y!==null&&a.canRotate()&&a.actualBounds.w()&&a.isVisible()&&y.actualBounds.w()&&y.Ed())){var x=a.Pj(this.name);if((x===null||x.adornedObject!==y)&&(x=this.makeAdornment(y)),x!==null){x.angle=y.li(),x.placeholder===null&&(x.location=this.computeAdornmentLocation(y)),a.bh(this.name,x);return}}a.Jf(this.name)}},ct.prototype.makeAdornment=function(a){var y=a.part.rotateAdornmentTemplate;if(y===null){y=new Fo,y.type=Ln.Position,y.locationSpot=ko;var x=this.handleArchetype;x!==null&&y.add(x.copy())}else if(_h(y),y=y.copy(),y===null)return null;return y.adornedObject=a,y},ct.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;return!a.isReadOnly&&a.allowRotate&&a.lastInput.left?this.findToolHandleAt(a.firstInput.documentPoint,this.name)!==null:!1},ct.prototype.doActivate=function(){var a=this.diagram;if(this.adornedObject===null){if(this.handle===null&&(this.handle=this.findToolHandleAt(a.firstInput.documentPoint,this.name)),this.handle===null)return;this.adornedObject=this.handle.part.adornedObject}this.adornedObject!==null&&(a.isMouseCaptured=!0,a.delaysLayout=!0,this.Ea(this.name),this.Cw=this.adornedObject.angle,this.kr=this.computeRotationPoint(this.adornedObject),this.Tn=this.adornedObject.part.location.copy(),this.isActive=!0)},ct.prototype.computeRotationPoint=function(a){var y=a.part,x=y.locationObject;return y.rotationSpot.sb()?a.ga(y.rotationSpot):a===y||a===x?x.ga(y.locationSpot):a.ga(ko)},ct.prototype.computeAdornmentLocation=function(a){var y=this.rotationPoint;y.w()||(y=this.computeRotationPoint(a)),y=a.qs(y);var x=this.handleAngle;0>x?x+=360:360<=x&&(x-=360),x=Math.round(45*Math.round(x/45));var E=this.handleDistance;return x===0?y.x=a.naturalBounds.width+E:x===45?(y.x=a.naturalBounds.width+E,y.y=a.naturalBounds.height+E):x===90?y.y=a.naturalBounds.height+E:x===135?(y.x=-E,y.y=a.naturalBounds.height+E):x===180?y.x=-E:x===225?(y.x=-E,y.y=-E):x===270?y.y=-E:x===315&&(y.x=a.naturalBounds.width+E,y.y=-E),a.ga(y)},ct.prototype.doDeactivate=function(){var a=this.diagram;this.stopTransaction(),this.ue=this.handle=null,this.kr=new Qe(NaN,NaN),this.isActive=a.isMouseCaptured=!1},ct.prototype.stopTransaction=function(){var a=this.diagram,y=Ni.prototype.stopTransaction.call(this);return y&&a.undoManager.transactionToUndo!==null&&a.undoManager.transactionToUndo.ak(),y},ct.prototype.doCancel=function(){this.diagram.delaysLayout=!1,this.rotate(this.originalAngle),this.stopTool()},ct.prototype.doMouseMove=function(){var a=this.diagram;this.isActive&&(a=this.computeRotate(a.lastInput.documentPoint),this.rotate(a))},ct.prototype.doMouseUp=function(){var a=this.diagram;if(this.isActive){a.delaysLayout=!1;var y=this.computeRotate(a.lastInput.documentPoint);this.rotate(y),a.Ya(),this.transactionResult=this.name,a.R("PartRotated",this.adornedObject,this.originalAngle)}this.stopTool()},ct.prototype.rotate=function(a){var y=this.adornedObject;if(y!==null){y.angle=a,y=y.part,y.Va();var x=y.locationObject,E=y.rotateObject;(x===E||x.rg(E))&&(x=this.Tn.copy(),y.location=x.re(this.rotationPoint).rotate(a-this.originalAngle).add(this.rotationPoint)),this.diagram.bd()}},ct.prototype.computeRotate=function(a){a=this.rotationPoint.ab(a)-this.handleAngle;var y=this.adornedObject.panel;y!==null&&(a-=y.li()),360<=a?a-=360:0>a&&(a+=360),y=Math.min(Math.abs(this.snapAngleMultiple),180);var x=Math.min(Math.abs(this.snapAngleEpsilon),y/2);return!this.diagram.lastInput.shift&&0<y&&0<x&&(a%y<x?a=Math.floor(a/y)*y:a%y>y-x&&(a=(Math.floor(a/y)+1)*y)),360<=a?a-=360:0>a&&(a+=360),a},Yt.Object.defineProperties(ct.prototype,{handleArchetype:{get:function(){return this.o},set:function(a){this.o=a}},handle:{get:function(){return this.j},set:function(a){if(a!==null&&!(a.part instanceof Fo))throw Error("new handle is not in an Adornment: "+a);this.j=a}},adornedObject:{get:function(){return this.ue},set:function(a){if(a!==null&&a.part instanceof Fo)throw Error("new handle must not be in an Adornment: "+a);this.ue=a}},snapAngleMultiple:{get:function(){return this.ia},set:function(a){this.ia=a}},snapAngleEpsilon:{get:function(){return this.V},set:function(a){this.V=a}},originalAngle:{get:function(){return this.Cw}},rotationPoint:{get:function(){return this.kr},set:function(a){this.kr=a.copy()}},handleAngle:{get:function(){return this.u},set:function(a){this.u=a}},handleDistance:{get:function(){return this.F},set:function(a){this.F=a}}}),ct.className="RotatingTool",ri("rotatingTool",function(){return this.findTool("Rotating")},function(a){this.gb("Rotating",a,this.mouseDownTools)});function Et(){Ni.call(this),this.name="ClickSelecting"}Ct(Et,Ni),Et.prototype.canStart=function(){return!(!this.isEnabled||this.isBeyondDragSize())},Et.prototype.doMouseUp=function(){this.isActive&&(this.standardMouseSelect(),!this.standardMouseClick()&&this.diagram.lastInput.isTouchEvent&&this.diagram.toolManager.doToolTip()),this.stopTool()},Et.className="ClickSelectingTool";function Bt(){Ni.call(this),this.name="Action",this.pk=null}Ct(Bt,Ni),Bt.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram,y=a.lastInput,x=a.ic(y.documentPoint,function(E){for(;E.panel!==null&&!E.isActionable;)E=E.panel;return E});return x!==null&&x.isActionable?(this.pk=x,a.Ck=a.ic(y.documentPoint,null,null),!0):!1},Bt.prototype.doMouseDown=function(){if(this.isActive){var a=this.diagram.lastInput,y=this.pk;y!==null&&(a.targetObject=y,y.actionDown!==null&&y.actionDown(a,y))}else this.canStart()&&this.doActivate()},Bt.prototype.doMouseMove=function(){if(this.isActive){var a=this.diagram.lastInput,y=this.pk;y!==null&&(a.targetObject=y,y.actionMove!==null&&y.actionMove(a,y))}},Bt.prototype.doMouseUp=function(){if(this.isActive){var a=this.diagram.lastInput,y=this.pk;if(y===null)return;a.targetObject=y,y.actionUp!==null&&y.actionUp(a,y),this.standardMouseClick(function(x){for(;x.panel!==null&&(!x.isActionable||x!==y);)x=x.panel;return x},function(x){return x===y})}this.stopTool()},Bt.prototype.doCancel=function(){var a=this.diagram.lastInput,y=this.pk;y!==null&&(a.targetObject=y,y.actionCancel!==null&&y.actionCancel(a,y),this.stopTool())},Bt.prototype.doStop=function(){this.pk=null},Bt.className="ActionTool";function hn(){Ni.call(this),this.name="ClickCreating",this.Ri=null,this.o=!0,this.j=!1,this.mw=new Qe(0,0)}Ct(hn,Ni),hn.prototype.canStart=function(){if(!this.isEnabled||this.archetypeNodeData===null)return!1;var a=this.diagram;if(a.isReadOnly||a.isModelReadOnly||!a.allowInsert||!a.lastInput.left||this.isBeyondDragSize())return!1;if(this.isDoubleClick){if(a.lastInput.clickCount===1&&(this.mw=a.lastInput.viewPoint.copy()),a.lastInput.clickCount!==2||this.isBeyondDragSize(this.mw))return!1}else if(a.lastInput.clickCount!==1)return!1;return!(a.currentTool!==this&&a.Ol(a.lastInput.documentPoint,!0)!==null)},hn.prototype.doMouseUp=function(){var a=this.diagram;this.isActive&&this.insertPart(a.lastInput.documentPoint),this.stopTool()},hn.prototype.insertPart=function(a){var y=this.diagram,x=this.archetypeNodeData;if(x===null)return null;var E=null;try{if(y.R("ChangingSelection",y.selection),this.Ea(this.name),x instanceof Ii)x.Zc()&&(_h(x),E=x.copy(),E!==null&&y.add(E));else if(x!==null){var b=y.model.copyNodeData(x);kn(b)&&(y.model.xf(b),E=y.Lc(b))}if(E!==null){var z=Qe.allocAt(a.x,a.y);this.isGridSnapEnabled&&au(this.diagram,E,a,z),E.location=z,y.allowSelect&&(y.clearSelection(!0),E.isSelected=!0),Qe.free(z)}y.Ya(),this.transactionResult=this.name,y.R("PartCreated",E)}finally{this.stopTransaction(),y.R("ChangedSelection",y.selection)}return E},Yt.Object.defineProperties(hn.prototype,{archetypeNodeData:{get:function(){return this.Ri},set:function(a){this.Ri=a}},isDoubleClick:{get:function(){return this.o},set:function(a){this.o=a}},isGridSnapEnabled:{get:function(){return this.j},set:function(a){this.j=a}}}),hn.className="ClickCreatingTool";function qt(){Ni.call(this),this.name="DragSelecting",this.Ik=175,this.o=!1;var a=new Ii;a.layerName="Tool",a.selectable=!1;var y=new Dr;y.name="SHAPE",y.figure="Rectangle",y.fill=null,y.stroke="magenta",a.add(y),this.j=a}Ct(qt,Ni),qt.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;if(!a.allowSelect)return!1;var y=a.lastInput;return!(!y.left||a.currentTool!==this&&(!this.isBeyondDragSize()||y.timestamp-a.firstInput.timestamp<this.delay||a.Ol(y.documentPoint,!0)!==null))},qt.prototype.doActivate=function(){var a=this.diagram;this.isActive=!0,a.isMouseCaptured=!0,a.skipsUndoManager=!0,a.add(this.box),this.doMouseMove()},qt.prototype.doDeactivate=function(){var a=this.diagram;a.ug(),a.remove(this.box),a.skipsUndoManager=!1,this.isActive=a.isMouseCaptured=!1},qt.prototype.doMouseMove=function(){var a=this.diagram;if(this.isActive&&this.box!==null){var y=this.computeBoxBounds(),x=this.box.fb("SHAPE");x===null&&(x=this.box.Pb());var E=fn.alloc().h(y.width,y.height);x.desiredSize=E,this.box.mm(y.x,y.y,!1),fn.free(E),(a.allowHorizontalScroll||a.allowVerticalScroll)&&a.gs(a.lastInput.viewPoint)}},qt.prototype.doMouseUp=function(){if(this.isActive){var a=this.diagram;a.remove(this.box);try{a.currentCursor="wait",a.R("ChangingSelection",a.selection),this.selectInRect(this.computeBoxBounds()),a.R("ChangedSelection",a.selection)}finally{a.currentCursor=""}}this.stopTool()},qt.prototype.computeBoxBounds=function(){var a=this.diagram;return new Xt(a.firstInput.documentPoint,a.lastInput.documentPoint)},qt.prototype.selectInRect=function(a){var y=this.diagram,x=y.lastInput;if(a=y.ux(a,this.isPartialInclusion),Fs?x.meta:x.control)if(x.shift)for(a=a.iterator;a.next();)y=a.value,y.isSelected&&(y.isSelected=!1);else for(a=a.iterator;a.next();)y=a.value,y.isSelected=!y.isSelected;else if(x.shift)for(a=a.iterator;a.next();)y=a.value,y.isSelected||(y.isSelected=!0);else{for(x=new An,y=y.selection.iterator;y.next();){var E=y.value;a.contains(E)||x.add(E)}for(y=x.iterator;y.next();)y.value.isSelected=!1;for(a=a.iterator;a.next();)y=a.value,y.isSelected||(y.isSelected=!0)}},Yt.Object.defineProperties(qt.prototype,{delay:{get:function(){return this.Ik},set:function(a){this.Ik=a}},isPartialInclusion:{get:function(){return this.o},set:function(a){this.o=a}},box:{get:function(){return this.j},set:function(a){this.j=a}}}),qt.className="DragSelectingTool";function nn(){Ni.call(this),this.name="Panning",this.Xt=new Qe,this.xy=new Qe,this.xg=!1;var a=this;this.Kw=function(){var y=a.diagram;y!==null&&y.removeEventListener(Kt.document,"scroll",a.Kw,!1),a.stopTool()}}Ct(nn,Ni),nn.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;return!(!a.allowHorizontalScroll&&!a.allowVerticalScroll||!a.lastInput.left||a.currentTool!==this&&!this.isBeyondDragSize())},nn.prototype.doActivate=function(){var a=this.diagram;this.xg?(a.lastInput.bubbles=!0,a.addEventListener(Kt.document,"scroll",this.Kw,!1)):(a.currentCursor="move",a.isMouseCaptured=!0,this.Xt.assign(a.position)),this.isActive=!0},nn.prototype.doDeactivate=function(){var a=this.diagram;a.currentCursor="",this.isActive=a.isMouseCaptured=!1},nn.prototype.doCancel=function(){var a=this.diagram;a.position=this.Xt,a.isMouseCaptured=!1,this.stopTool()},nn.prototype.doMouseMove=function(){this.move()},nn.prototype.doMouseUp=function(){this.move(),this.stopTool()},nn.prototype.move=function(){var a=this.diagram;if(this.isActive&&a)if(this.xg)a.lastInput.bubbles=!0;else{var y=a.position,x=a.firstInput.documentPoint,E=a.lastInput.documentPoint,b=y.x+x.x-E.x;x=y.y+x.y-E.y,a.allowHorizontalScroll||(b=y.x),a.allowVerticalScroll||(x=y.y),a.position=this.xy.h(b,x)}},Yt.Object.defineProperties(nn.prototype,{bubbles:{get:function(){return this.xg},set:function(a){this.xg=a}},originalPosition:{get:function(){return this.Xt}}}),nn.className="PanningTool",ri("clickCreatingTool",function(){return this.findTool("ClickCreating")},function(a){this.gb("ClickCreating",a,this.mouseUpTools)}),ri("clickSelectingTool",function(){return this.findTool("ClickSelecting")},function(a){this.gb("ClickSelecting",a,this.mouseUpTools)}),ri("panningTool",function(){return this.findTool("Panning")},function(a){this.gb("Panning",a,this.mouseMoveTools)}),ri("dragSelectingTool",function(){return this.findTool("DragSelecting")},function(a){this.gb("DragSelecting",a,this.mouseMoveTools)}),ri("actionTool",function(){return this.findTool("Action")},function(a){this.gb("Action",a,this.mouseDownTools)});function Sn(){this.F=this.u=this.j=this.o=null}Yt.Object.defineProperties(Sn.prototype,{mainElement:{get:function(){return this.u},set:function(a){this.u=a}},show:{get:function(){return this.o},set:function(a){this.o!==a&&(this.o=a)}},hide:{get:function(){return this.j},set:function(a){this.j!==a&&(this.j=a)}},valueFunction:{get:function(){return this.F},set:function(a){this.F=a}}}),Sn.className="HTMLInfo";function yn(a,y,x){this.text=a,this.hx=y,this.visible=x}yn.className="ContextMenuButtonInfo";function Jn(){Ni.call(this),this.name="ContextMenu",this.o=this.ht=this.j=null,this.yw=new Qe,this.jt=null,this.Et=!1;var a=this;this.tu=function(){a.stopTool()}}Ct(Jn,Ni);function In(a){var y=new Sn;y.show=function(b,z,ee){ee.showDefaultContextMenu()},y.hide=function(b,z){z.hideDefaultContextMenu()},$i=y,a.tu=function(){a.stopTool()},y=Rn("div");var x=Rn("div");y.style.cssText="top: 0px;z-index:10002;position: fixed;display: none;text-align: center;left: 25%;width: 50%;background-color: #F5F5F5;padding: 16px;border: 16px solid #444;border-radius: 10px;margin-top: 10px",x.style.cssText="z-index:10001;position: fixed;display: none;top: 0;left: 0;width: 100%;height: 100%;background-color: black;opacity: 0.8;";var E=Rn("style");Kt.document.getElementsByTagName("head")[0].appendChild(E),E.sheet.insertRule(".goCXul { list-style: none; }",0),E.sheet.insertRule(".goCXli {font:700 1.5em Helvetica, Arial, sans-serif;position: relative;min-width: 60px; }",0),E.sheet.insertRule(".goCXa {color: #444;display: inline-block;padding: 4px;text-decoration: none;margin: 2px;border: 1px solid gray;border-radius: 10px; }",0),E=a.diagram,E!==null&&(E.addEventListener(y,"contextmenu",Mn,!1),E.addEventListener(y,"selectstart",Mn,!1),E.addEventListener(x,"contextmenu",Mn,!1)),y.className="goCXforeground",x.className="goCXbackground",Kt.document.body&&(Kt.document.body.appendChild(y),Kt.document.body.appendChild(x)),dr=y,bi=x,Ai=!0}function Mn(a){return a.preventDefault(),!1}Jn.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;return this.isBeyondDragSize()||!a.lastInput.right||1<a.lastInput.clickCount?!1:!!(a.lastInput.isTouchEvent&&this.defaultTouchContextMenu!==null||this.findObjectWithContextMenu()!==null)},Jn.prototype.doStart=function(){this.yw.set(this.diagram.firstInput.documentPoint)},Jn.prototype.doStop=function(){this.hideContextMenu(),this.currentObject=null},Jn.prototype.findObjectWithContextMenu=function(a){a===void 0&&(a=null);var y=this.diagram,x=y.lastInput,E=null;if(a instanceof bt||(a instanceof mt?E=a:E=y.ic(x.documentPoint,null,function(b){return!b.layer.isTemporary})),E!==null){for(a=E;a!==null;){if(a.contextMenu!==null)return a;a=a.panel}if(y.lastInput.isTouchEvent&&this.defaultTouchContextMenu)return E.part}else if(y.contextMenu!==null)return y;return null},Jn.prototype.doActivate=function(){},Jn.prototype.doMouseDown=function(){if(Ni.prototype.doMouseDown.call(this),this.isActive&&this.currentContextMenu instanceof Fo){var a=this.diagram.toolManager.findTool("Action");a!==null&&a.canStart()&&(a.doActivate(),a.doMouseDown(),a.doDeactivate())}this.diagram.toolManager.mouseDownTools.contains(this)&&Kn(this)},Jn.prototype.doMouseUp=function(){if(this.isActive&&this.currentContextMenu instanceof Fo){var a=this.diagram.toolManager.findTool("Action");a!==null&&a.canStart()&&(a.doActivate(),a.doCancel(),a.doDeactivate())}Kn(this)};function Kn(a){var y=a.diagram;if(a.isActive){var x=a.currentContextMenu;if(x!==null){var E=null;x instanceof Sn||(E=y.ic(y.lastInput.documentPoint,null,null),E!==null&&E.rg(x)&&a.standardMouseClick(null,null)),a.maybeStopTool(E)}}else a.canStart()&&(ni(a,!0),a.isActive||a.stopTool())}Jn.prototype.maybeStopTool=function(){this.stopTool(),this.canStart()&&(this.diagram.currentTool=this,this.doMouseUp())};function ni(a,y,x){if(x===void 0&&(x=null),!a.Et&&(a.Et=!0,y&&a.standardMouseSelect(),y=a.standardMouseClick(),a.Et=!1,!y)){if(a.isActive=!0,y=$i,x===null&&(x=a.findObjectWithContextMenu()),x!==null){var E=x.contextMenu;E!==null?(a.currentObject=x instanceof mt?x:null,a.showContextMenu(E,a.currentObject)):y!==null&&a.showContextMenu(y,a.currentObject)}else y!==null&&a.showContextMenu(y,null);a.currentContextMenu instanceof Fo&&!a.currentContextMenu.visible&&a.stopTool()}}Jn.prototype.doMouseMove=function(){var a=this.diagram.toolManager.findTool("Action");a!==null&&a.doMouseMove(),this.isActive&&this.diagram.toolManager.doMouseMove()},Jn.prototype.showContextMenu=function(a,y){var x=this.diagram;if(a!==this.currentContextMenu&&this.hideContextMenu(),a instanceof Fo){a.layerName="Tool",a.selectable=!1,a.scale=1/x.scale,a.category=this.name,a.placeholder!==null&&(a.placeholder.scale=x.scale);var E=a.diagram;E!==null&&E!==x&&E.remove(a),x.add(a),y!==null?a.adornedObject=y:a.data=x.model,a.Va(),this.positionContextMenu(a,y)}else a instanceof Sn&&a.show(y,x,this);this.currentContextMenu=a},Jn.prototype.positionContextMenu=function(a){if(a.placeholder===null){var y=this.diagram,x=y.lastInput.documentPoint.copy(),E=a.measuredBounds,b=y.viewportBounds;y.lastInput.isTouchEvent&&(x.x-=E.width),x.x+E.width>b.right&&(x.x-=E.width+5/y.scale),x.x<b.x&&(x.x=b.x),x.y+E.height>b.bottom&&(x.y-=E.height+5/y.scale),x.y<b.y&&(x.y=b.y),a.position=x}},Jn.prototype.hideContextMenu=function(){var a=this.diagram,y=this.currentContextMenu;y!==null&&(y instanceof Fo?(a.remove(y),this.ht!==null&&this.ht.Jf(y.category),y.data=null,y.adornedObject=null):y instanceof Sn&&(y.hide!==null?y.hide(a,this):y.mainElement!==null&&(y.mainElement.style.display="none")),this.currentContextMenu=null,this.standardMouseOver())};function yi(a){var y=new An;return y.add(new yn("Copy",function(x){x.commandHandler.copySelection()},function(x){return x.commandHandler.canCopySelection()})),y.add(new yn("Cut",function(x){x.commandHandler.cutSelection()},function(x){return x.commandHandler.canCutSelection()})),y.add(new yn("Delete",function(x){x.commandHandler.deleteSelection()},function(x){return x.commandHandler.canDeleteSelection()})),y.add(new yn("Paste",function(x){x.commandHandler.pasteSelection(a.mouseDownPoint)},function(x){return x.commandHandler.canPasteSelection(a.mouseDownPoint)})),y.add(new yn("Select All",function(x){x.commandHandler.selectAll()},function(x){return x.commandHandler.canSelectAll()})),y.add(new yn("Undo",function(x){x.commandHandler.undo()},function(x){return x.commandHandler.canUndo()})),y.add(new yn("Redo",function(x){x.commandHandler.redo()},function(x){return x.commandHandler.canRedo()})),y.add(new yn("Scroll To Part",function(x){x.commandHandler.scrollToPart()},function(x){return x.commandHandler.canScrollToPart()})),y.add(new yn("Zoom To Fit",function(x){x.commandHandler.zoomToFit()},function(x){return x.commandHandler.canZoomToFit()})),y.add(new yn("Reset Zoom",function(x){x.commandHandler.resetZoom()},function(x){return x.commandHandler.canResetZoom()})),y.add(new yn("Group Selection",function(x){x.commandHandler.groupSelection()},function(x){return x.commandHandler.canGroupSelection()})),y.add(new yn("Ungroup Selection",function(x){x.commandHandler.ungroupSelection()},function(x){return x.commandHandler.canUngroupSelection()})),y.add(new yn("Edit Text",function(x){x.commandHandler.editTextBlock()},function(x){return x.commandHandler.canEditTextBlock()})),y}Jn.prototype.showDefaultContextMenu=function(){var a=this.diagram;this.jt===null&&(this.jt=yi(this)),dr.innerHTML="",bi.addEventListener("pointerdown",this.tu,!1);var y=this,x=Rn("ul");x.className="goCXul",dr.appendChild(x),x.innerHTML="";for(var E=this.jt.iterator;E.next();){var b=E.value,z=b.visible;if(typeof b.hx=="function"&&(typeof z!="function"||z(a))){z=Rn("li"),z.className="goCXli";var ee=Rn("a");ee.className="goCXa",ee.href="#",ee.ky=b.hx,ee.addEventListener("pointerdown",function(re){return this.ky(a),y.stopTool(),re.preventDefault(),!1},!1),ee.textContent=b.text,z.appendChild(ee),x.appendChild(z)}}dr.style.display="block",bi.style.display="block"},Jn.prototype.hideDefaultContextMenu=function(){if(this.currentContextMenu!==null&&this.currentContextMenu===$i){dr.style.display="none",bi.style.display="none";var a=this.diagram;a!==null&&a.removeEventListener(bi,"pointerdown",this.tu,!1),this.currentContextMenu=null}},Yt.Object.defineProperties(Jn.prototype,{currentContextMenu:{get:function(){return this.j},set:function(a){this.j=a,this.ht=a instanceof Fo?a.adornedPart:null}},defaultTouchContextMenu:{get:function(){return Ai===!1&&$i===null&&Es&&In(this),$i},set:function(a){a===null&&(Ai=!0),$i=a}},currentObject:{get:function(){return this.o},set:function(a){this.o=a}},mouseDownPoint:{get:function(){return this.yw}}});var $i=null,Ai=!1,bi=null,dr=null;Jn.className="ContextMenuTool",ri("contextMenuTool",function(){return this.findTool("ContextMenu")},function(a){this.gb("ContextMenu",a,this.mouseUpTools)});function Wn(){Ni.call(this),this.name="TextEditing",this.Zh=new ja,this.ia=null,this.V=Mr,this.vj=null,this.qa=pr,this.u=1,this.F=!0,this.o=null,this.j=new Sn,this.kt=null,Ji(this,this.j)}Ct(Wn,Ni);function Ji(a,y){if(Es){var x=Rn("textarea");a.kt=x,x.addEventListener("input",function(){if(a.textBlock!==null){var E=a.Lx(this.value);this.style.width=20+E.measuredBounds.width*this.wA+"px",this.rows=E.lineCount}},!1),x.addEventListener("keydown",function(E){if(!E.isComposing&&a.textBlock!==null){var b=E.key;b==="Enter"?(a.textBlock.isMultiline===!1&&E.preventDefault(),a.acceptText(Fr)):b==="Tab"?(a.acceptText(ki),E.preventDefault()):b==="Escape"&&(a.doCancel(),a.diagram!==null&&a.diagram.doFocus())}},!1),x.addEventListener("focus",function(){if(a.currentTextEditor!==null&&a.state!==pr){var E=a.kt;a.qa===qr&&(a.qa=Po),typeof E.select=="function"&&a.selectsTextOnActivate&&(E.select(),E.setSelectionRange(0,9999))}},!1),x.addEventListener("blur",function(){if(a.currentTextEditor!==null&&a.state!==pr){var E=a.kt;typeof E.focus=="function"&&E.focus(),typeof E.select=="function"&&a.selectsTextOnActivate&&(E.select(),E.setSelectionRange(0,9999))}},!1),y.valueFunction=function(){return x.value},y.mainElement=x,y.show=function(E,b,z){if(E instanceof ja&&z instanceof Wn)if(z.state===Qi)x.style.border="3px solid red",x.focus();else{var ee=E.ga(ko),re=b.position,oe=b.scale,se=E.Df()*oe;se<z.minimumEditorScale&&(se=z.minimumEditorScale);var ue=E.naturalBounds.width*se+6,fe=E.naturalBounds.height*se+2,ve=(ee.x-re.x)*oe;ee=(ee.y-re.y)*oe,re=E.verticalAlignment,oe=(E.lineHeight+E.spacingAbove+E.spacingBelow)*E.lineCount*se,fe=re.y*fe-re.y*oe+re.offsetY-(.5*fe-.5*oe)-oe/2,x.value=E.text,b.div.style.font=E.font,x.style.position="absolute",x.style.zIndex="100",x.style.font="inherit",x.style.fontSize=100*se+"%",x.style.lineHeight="normal",x.style.width=ue+"px",x.style.left=(ve-ue/2|0)-1+"px",x.style.top=(ee+fe|0)-1+"px",x.style.textAlign=E.textAlign,x.style.margin="0",x.style.padding="1px",x.style.border="0",x.style.outline="none",x.style.whiteSpace="pre-wrap",x.style.overflow="hidden",x.rows=E.lineCount,x.wA=se,x.className="goTXarea",b.div.appendChild(x),x.focus(),z.selectsTextOnActivate&&(x.select(),x.setSelectionRange(0,9999))}},y.hide=function(E){E.div.removeChild(x)}}}Wn.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;if(a===null||a.isReadOnly||$r&&$r!==this&&($r.acceptText(ar),$r&&$r!==this)||!a.lastInput.left||this.isBeyondDragSize())return!1;var y=a.ic(a.lastInput.documentPoint);return y!==null&&y instanceof ja&&y.editable&&y.part.canEdit()?(y=y.part,!(y===null||this.starting===Mr&&!y.isSelected||this.starting===Ti&&2>a.lastInput.clickCount)):!1},Wn.prototype.doStart=function(){$r=this,this.textBlock!==null&&this.doActivate()},Wn.prototype.doActivate=function(){if(!this.isActive){var a=this.diagram;if(a!==null){var y=this.textBlock;if(y===null&&(y=a.ic(a.lastInput.documentPoint)),y!==null&&y instanceof ja&&(this.textBlock=y,y.part!==null)){a.animationManager.Cc(),this.isActive=!0,this.qa=qr;var x=this.defaultTextEditor;y.textEditor!==null&&(x=y.textEditor),this.Zh=this.textBlock.copy();var E=new Xt(this.textBlock.ga(Cs),this.textBlock.ga(Hl));a.tv(E),x.show(y,a,this),this.currentTextEditor=x}}}},Wn.prototype.doCancel=function(){this.stopTool()},Wn.prototype.doMouseUp=function(){this.canStart()&&this.doActivate()},Wn.prototype.doMouseDown=function(){this.isActive&&this.acceptText(ar)},Wn.prototype.acceptText=function(a){switch(a){case ar:this.qa===zr?this.currentTextEditor instanceof HTMLElement&&this.currentTextEditor.focus():(this.qa===qr||this.qa===Qi||this.qa===Po)&&(this.qa=no,Pi(this));break;case tr:case Fr:case ki:(Fr!==a||this.textBlock.isMultiline!==!0)&&(this.qa===qr||this.qa===Qi||this.qa===Po)&&(this.qa=no,Pi(this))}};function Pi(a){var y=a.textBlock,x=a.diagram,E=a.currentTextEditor;if(y!==null&&E!==null){var b=y.text,z="";E.valueFunction!==null&&(z=E.valueFunction()),a.isValidText(y,b,z)?(a.Ea(a.name),a.qa=zr,a.transactionResult=a.name,y.text=z,a.doSuccess(b,z),x!==null&&x.R("TextEdited",y,b),a.stopTransaction(),a.stopTool(),x!==null&&x.doFocus()):(a.qa=Qi,a.doError(b,z))}}Wn.prototype.doError=function(a,y){var x=this.textBlock;x.errorFunction!==null&&x.errorFunction(this,a,y),(a=this.currentTextEditor)&&a.show(x,this.diagram,this)},Wn.prototype.doSuccess=function(a,y){var x=this.textBlock;x.textEdited!==null&&x.textEdited(x,a,y)},Wn.prototype.doDeactivate=function(){var a=this.diagram;a!==null&&(this.qa=pr,this.currentTextEditor!==null&&this.currentTextEditor.hide(a,this),this.textBlock=null,this.isActive=!1)},Wn.prototype.doStop=function(){$r=null},Wn.prototype.isValidText=function(a,y,x){var E=this.textValidation;return E!==null&&!E(a,y,x)?!1:(E=a.textValidation,!!(E===null||E(a,y,x)))},Wn.prototype.Lx=function(a){var y=this.Zh;return y.text=a,y.measure(this.textBlock.Ih,1/0),y},Yt.Object.defineProperties(Wn.prototype,{textBlock:{get:function(){return this.ia},set:function(a){this.ia=a}},currentTextEditor:{get:function(){return this.o},set:function(a){this.o=a}},defaultTextEditor:{get:function(){return this.j},set:function(a){this.j=a}},starting:{get:function(){return this.V},set:function(a){this.V=a}},textValidation:{get:function(){return this.vj},set:function(a){this.vj=a}},minimumEditorScale:{get:function(){return this.u},set:function(a){this.u=a}},selectsTextOnActivate:{get:function(){return this.F},set:function(a){this.F=a}},state:{get:function(){return this.qa},set:function(a){this.qa!==a&&(this.qa=a)}}}),Wn.prototype.measureTemporaryTextBlock=Wn.prototype.Lx;var tr=new Vt(Wn,"LostFocus",0),ar=new Vt(Wn,"MouseDown",1),ki=new Vt(Wn,"Tab",2),Fr=new Vt(Wn,"Enter",3),hr=new Vt(Wn,"SingleClick",0),Mr=new Vt(Wn,"SingleClickSelected",1),Ti=new Vt(Wn,"DoubleClick",2),pr=new Vt(Wn,"StateNone",0),qr=new Vt(Wn,"StateActive",1),Po=new Vt(Wn,"StateEditing",2),no=new Vt(Wn,"StateValidating",3),Qi=new Vt(Wn,"StateInvalid",4),zr=new Vt(Wn,"StateValidated",5),$r=null;Wn.className="TextEditingTool",Wn.LostFocus=tr,Wn.MouseDown=ar,Wn.Tab=ki,Wn.Enter=Fr,Wn.SingleClick=hr,Wn.SingleClickSelected=Mr,Wn.DoubleClick=Ti,Wn.StateNone=pr,Wn.StateActive=qr,Wn.StateEditing=Po,Wn.StateValidating=no,Wn.StateInvalid=Qi,Wn.StateValidated=zr,ri("textEditingTool",function(){return this.findTool("TextEditing")},function(a){this.gb("TextEditing",a,this.mouseUpTools)});function lo(a){Xr||(Sr(),Xr=!0),this.H=zo,this.Ok=this.zb=this.vq=this.bc=!1,this.Qw=!0,this.Pk=Ir,this.Dm=!1,this.Gh=this.Jd=!0,this.Dg=600,this.cw=this.Ow=!1,this.Zd=new Pn,this.ce=new Xo,this.ce.Yd=this,this.Ei=new Pn,this.pu=new Pn,this.Sr=new Pn,this.pr=new Pn,a&&Object.assign(this,a)}lo.prototype.Xe=function(a){this.H=a},lo.prototype.canStart=function(){return!0};function Uo(a,y){a.Jd&&a.canStart(y)&&(a.Zd.add(y),a.defaultAnimation.isAnimating&&a.Cc(),Ps(a.H),a.zb=!0)}function So(a){if(a.Jd&&a.zb){var y=a.ce,x=a.H,E=a.Zd.contains("Model");E&&(a.Ok=!0,a.Pk===Ir?(y.isViewportUnconstrained=!0,y.vc.clear(),y.add(x,"position",x.position.copy().offset(0,-200),x.position),y.add(x,"opacity",0,1)):a.Pk===ra&&y.vc.clear(),a.Qw=!!(a.Pk===wa&&x.du.D(x.pa)),x.R("InitialAnimationStarting",a)),E&&!a.Gh||y.vc.count===0?(a.Zd.clear(),a.zb=!1,y.vc.clear(),pa(y,x),a.Ok=!1,x.N()):(a.Zd.clear(),x.kg=!1,E=y.vc.get(x),x.autoScale!==lu&&E!==null&&(delete E.start.scale,delete E.end.scale),Kt.requestAnimationFrame(function(){a.zb===!1||y.bc||(x.Gf("temporaryPixelRatio")&&nr(x),Ca(x),a.zb=!1,y.start(),y.bc&&(Nr(a),x.Ya(),ds(y,0),Os(x,!0),Wi(a),x.R("AnimationStarting",a)))}))}}function Ar(a){return a.Zd.contains("Trigger")&&a.Zd.count===1}function ur(a,y,x,E){a.isTicking||Ar(a)||y instanceof Tn&&(y.fromNode!==null||y.toNode!==null)||a.ce.add(y,"position",x,E,!1)}we=lo.prototype,we.fv=function(a){return this.ce.fv(a)},we.Xu=function(a){return this.ce.Xu(a)};function Vr(a,y){function x(){if(0<b.Sr.count&&(E.addAll(b.Sr),b.Sr.clear(),b.bc=!0),b.bc!==!1&&E.count!==0){b.pu.addAll(E);for(var z=b.pu.iterator;z.next();){var ee=z.value;if(ee.bc!==!1){e:if(0<ee.yl.count)var re=!0;else{for(re=ee.vc.iterator;re.next();){var oe=re.key;if(oe instanceof mt&&oe.diagram!==null||oe instanceof bt){re=!0;break e}}re=!1}re?va(ee,!1):ee.Xk=!0}}b.pu.clear(),b.bc!==!1&&(Nr(b),Os(b.H),Wi(b)),Kt.requestAnimationFrame(x)}}var E=a.Ei,b=a;a.bc?a.Sr.add(y):(a.bc=!0,E.add(y),Kt.requestAnimationFrame(function(){x()}))}function Do(a){for(a=a.Ei.iterator;a.next();)a.value.Xk=!1}function Nr(a){if(!a.vq){var y=a.H;a.Ow=y.skipsUndoManager,a.cw=y.skipsModelSourceBindings,y.skipsUndoManager=!0,y.skipsModelSourceBindings=!0,a.vq=!0}}function Wi(a){var y=a.H;y.skipsUndoManager=a.Ow,y.skipsModelSourceBindings=a.cw,a.vq=!1}we.Cc=function(a){var y=this.ce;if(this.zb===!0&&(this.Ok=this.zb=!1,this.Zd.clear(),0<y.vc.count&&this.H.$b()),this.bc){if(y.Ml(!0),y.vc.clear(),pa(y,null),a===!0)for(a=this.Ei.Fa(),y=0;y<a.length;y++)a[y].Ml(!0)}else y.vc.clear(),pa(y,this.H)},we.Ml=function(a){a===this.defaultAnimation&&this.defaultAnimation.vc.clear(),this.Ei.remove(a),this.Ei.count===0&&(this.bc=!1,this.H.$b()),a===this.defaultAnimation&&(this.defaultAnimation.vc.clear(),this.H.R("AnimationFinished",this))},we.Cj=function(a,y){this.zb&&(this.Zd.contains("Expand Tree")||this.Zd.contains("Expand SubGraph"))&&(this.ce.Cj(a,y),Fi(this,a))},we.Aj=function(a,y){this.zb&&(this.Zd.contains("Collapse Tree")||this.Zd.contains("Collapse SubGraph"))&&(this.ce.Aj(a,y),ro(this.ce,y,"position",y.position,y.position),Fi(this,a))};function ir(a,y,x){!a.zb||y.D(x)||Ar(a)||(a.H.pi||(y=x.copy()),ro(a.ce,a.H,"position",y,x))}function rr(a,y,x){y.fd&&(y.Tg=x,a.pr.add(y))}function Fi(a,y){for(y=y.findLinksConnected();y.next();){var x=y.value;x.fd&&(x.Tg=x.points.copy(),a.pr.add(x))}}function zi(a,y,x,E,b){a===null&&(a=[0,0,0,0]),y===null&&(y=[0,0,0,0]);var z=a[0],ee=a[1],re=a[2];a=a[3];var oe=y[0],se=y[1],ue=y[2];return y=y[3],re===0||re===100?(z=oe,ee=se):(ue===0||ue===100)&&(oe=z,se=ee),180<Math.abs(oe-z)&&(oe>z?z+=360:oe+=360),z=b(x,z,oe-z,E)%360,ee=b(x,ee,se-ee,E),re=b(x,re,ue-re,E),x=b(x,a,y-a,E),"hsla("+z+", "+ee+"%, "+re+"%, "+x+")"}function Sr(){function a(x,E,b,z,ee,re){x.position=new Qe(z(ee,E.x,b.x-E.x,re),z(ee,E.y,b.y-E.y,re))}var y=new Li;y.add("position:diagram",a),y.add("position",a),y.add("position:part",function(x,E,b,z,ee,re){ee<re?x.mm(z(ee,E.x,b.x-E.x,re),z(ee,E.y,b.y-E.y,re),!1):x.position=new Qe(z(ee,E.x,b.x-E.x,re),z(ee,E.y,b.y-E.y,re))}),y.add("location",function(x,E,b,z,ee,re){ee<re?x.mm(z(ee,E.x,b.x-E.x,re),z(ee,E.y,b.y-E.y,re),!0):x.location=new Qe(z(ee,E.x,b.x-E.x,re),z(ee,E.y,b.y-E.y,re))}),y.add("position:placeholder",function(x,E,b,z,ee,re){ee<re?x.mm(z(ee,E.x,b.x-E.x,re),z(ee,E.y,b.y-E.y,re),!1):x.position=new Qe(z(ee,E.x,b.x-E.x,re),z(ee,E.y,b.y-E.y,re))}),y.add("position:nodeCollapse",function(x,E,b,z,ee,re){var oe=x.actualBounds,se=b.actualBounds;b=se.x+se.width/2-oe.width/2,oe=se.y+se.height/2-oe.height/2,ee<re?x.mm(z(ee,E.x,b-E.x,re),z(ee,E.y,oe-E.y,re),!1):x.position=new Qe(z(ee,E.x,b-E.x,re),z(ee,E.y,oe-E.y,re))}),y.add("desiredSize",function(x,E,b,z,ee,re){x.desiredSize=new Xt(z(ee,E.width,b.width-E.width,re),z(ee,E.height,b.height-E.height,re))}),y.add("width",function(x,E,b,z,ee,re){x.width=z(ee,E,b-E,re)}),y.add("height",function(x,E,b,z,ee,re){x.height=z(ee,E,b-E,re)}),y.add("fill",function(x,E,b,z,ee,re){x.fill=zi(E,b,ee,re,z)}),y.add("stroke",function(x,E,b,z,ee,re){x.stroke=zi(E,b,ee,re,z)}),y.add("strokeWidth",function(x,E,b,z,ee,re){x.strokeWidth=z(ee,E,b-E,re)}),y.add("strokeDashOffset",function(x,E,b,z,ee,re){x.strokeDashOffset=z(ee,E,b-E,re)}),y.add("background",function(x,E,b,z,ee,re){x.background=zi(E,b,ee,re,z)}),y.add("areaBackground",function(x,E,b,z,ee,re){x.areaBackground=zi(E,b,ee,re,z)}),y.add("opacity",function(x,E,b,z,ee,re){x.opacity=z(ee,E,b-E,re)}),y.add("scale",function(x,E,b,z,ee,re){x.scale=z(ee,E,b-E,re)}),y.add("angle",function(x,E,b,z,ee,re){x.angle=z(ee,E,b-E,re)}),io=y}Yt.Object.defineProperties(lo.prototype,{animationReasons:{get:function(){return this.Zd}},isEnabled:{get:function(){return this.Jd},set:function(a){(this.Jd=a)&&this.Ei.each(function(y){y.isAnimating||y.runCount!==1/0||y.start()})}},duration:{get:function(){return this.Dg},set:function(a){1>a&&gr(a,">= 1",lo,"duration"),this.Dg=a}},isAnimating:{get:function(){return this.bc}},isTicking:{get:function(){return this.vq}},isInitial:{get:function(){return this.Gh},set:function(a){this.Gh=a}},defaultAnimation:{get:function(){return this.ce}},activeAnimations:{get:function(){return this.Ei}},initialAnimationStyle:{get:function(){return this.Pk},set:function(a){this.Pk=a}}}),lo.prototype.stopAnimation=lo.prototype.Cc;var io=null,Xr=!1,Ir=new Vt(lo,"Default",1),wa=new Vt(lo,"AnimateLocations",2),ra=new Vt(lo,"None",3);lo.className="AnimationManager",lo.defineAnimationEffect=function(a,y){Xr||(Sr(),Xr=!0),io.add(a,y)},lo.Default=Ir,lo.AnimateLocations=wa,lo.None=ra;function Xo(a){this.vu=this.Nw=this.Yd=this.H=null,this.Xk=this.bc=this.j=!1,this.cn=this.Qd=0,this.Lp=this.ot=Pa,this.Wk=this.ho=!1,this.cu=1,this.au=0,this.Gd=this.Dg=NaN,this.gw=0,this.dn=null,this.o=bs,this.vc=new Li,this.Tt=new Li,this.yl=new Pn,this.Ut=new Pn,this.dw=vd,a&&Object.assign(this,a)}Xo.prototype.suspend=function(){this.Xk=!0},Xo.prototype.advanceTo=function(a,y){y&&(this.Xk=!1),this.ho&&a>=this.Gd&&(this.Wk=!0,a-=this.Gd),this.gw=a,va(this,!0),Nr(this.Yd),Os(this.H),Wi(this.Yd),this.H.redraw()};function pa(a,y){if(a.Tt.clear(),a.Wk=!1,a.au=0,a.Gd=NaN,0<a.yl.count&&a.yl.clear(),0<a.Ut.count&&a.Ut.clear(),y!==null)for(a=y.links;a.next();)a.value.Tg=null}we=Xo.prototype,we.start=function(){if(this.vc.count===0||this.bc)return this;for(var a=this.H,y=this.vc.iterator;y.next();){var x=y.key;a===null&&(x instanceof bt?a=x:x instanceof mt&&(a=x.diagram))}if(a!==null)this.H=a,this.Yd=a.animationManager;else return this;return y=this.Yd,y.isEnabled===!1?this:(this.Gd=isNaN(this.Dg)?y.duration:this.Dg,this.Lp=this.ot,y.Ok&&y.Pk===Ir&&this===y.defaultAnimation&&(this.Lp=Ba,this.Gd=isNaN(this.Dg)?y.duration===600?900:y.duration:this.Dg),this.dw=a.scrollMode,this.isViewportUnconstrained&&(a.sj=Rf),Nr(y),this.yl.each(function(E){E.data=null,a.add(E)}),Wi(y),this.bc=!0,this.Qd=+new Date,this.cn=this.Qd+this.Gd,Vr(y,this),this)},we.Iy=function(a,y){return a.Zc()?(this.yl.add(a),this.H=y,this):this},we.add=function(a,y,x,E,b){if(y==="position"&&x.Xa(E))return this;if(this.H===null&&(a instanceof bt?this.H=a:a instanceof mt&&a.diagram!==null&&(this.H=a.diagram)),a instanceof Ii){if(!a.isAnimated)return this;y==="position"&&(y="position:part")}return ro(this,a,y,x,E,b),this};function ro(a,y,x,E,b,z){var ee=a.vc;if(y instanceof bt&&x==="position"&&(x="position:diagram"),(x==="fill"||x==="stroke"||x==="background"||x==="areaBackground")&&(rd(E),a0(),E=[mh.j,mh.u,mh.o,mh.F],rd(b),a0(),b=[mh.j,mh.u,mh.o,mh.F]),ee.contains(y)){var re=ee.I(y),oe=re.start,se=re.end;oe[x]===void 0&&(oe[x]=Jo(E)),se[x]=Jo(b)}else oe={},se={},oe[x]=Jo(E),se[x]=Jo(b),re=oe.position,y instanceof mt&&re instanceof Qe&&!re.w()&&y.diagram.animationManager.Zd.contains("Expand SubGraph")&&re.assign(se.position),re=new Bo(oe,se,z),ee.add(y,re);ee=oe[x],ee instanceof Qe&&!ee.w()&&ee.assign(a.o),z&&x.indexOf("position:")===0&&y instanceof Ii?re.Ku.location=Jo(y.location):z&&(re.Ku[x]=Jo(E))}function Jo(a){return a instanceof Qe||a instanceof fn?a.copy():a}we.fv=function(a){return this.bc?(a=this.vc.I(a),a!==null&&a.nv):!1},we.Xu=function(a){return this.bc?(a=this.vc.I(a),a!==null&&(a.start.position||a.start.location)):!1};function va(a,y){if(!a.Xk||y){var x=a.Yd;if(a.bc!==!1){var E=+new Date,b=E>a.cn?a.Gd:E-a.Qd;y&&(b=a.gw,b<a.Gd?(a.Qd=+new Date-b,a.cn=a.Qd+a.Gd):b=a.Gd),Nr(x),ds(a,b),Os(a.H,!0),Wi(x),E>a.cn&&(a.ho&&!a.Wk?(a.Qd=+new Date,a.cn=a.Qd+a.Gd,a.Wk=!0):a.Ml(!1))}}}function ds(a,y){for(var x=a.Gd,E=a.vc.iterator,b=a.Wk;E.next();){var z=E.key;if(!(z instanceof mt&&z.diagram===null)){var ee=E.value,re=b?ee.end:ee.start;ee=b?ee.start:ee.end;var oe=io,se;for(se in ee)se==="position"&&(ee["position:placeholder"]||ee["position:nodeCollapse"])||oe.get(se)===null||oe.get(se)(z,re[se],ee[se],a.Lp,y,x,a)}}}we.stop=function(){return this.bc?(this.Ml(!0),this):this},we.Ml=function(a){if(this.vu!==null&&this.vu.jo.remove(this.Nw),this.bc){var y=this.H,x=this.Yd;this.Xk=this.bc=x.Ok=!1,Nr(x);for(var E=this.vc,b=this.yl.iterator;b.next();)y.remove(b.value);for(b=this.Ut.iterator;b.next();)b.value.v();b=this.ho,E=E.iterator;for(var z=io;E.next();){var ee=E.key,re=E.value,oe=b?re.end:re.start,se=b?re.start:re.end,ue=re.Ku,fe;for(fe in se)if(z.get(fe)!==null){var ve=fe;!re.Hu||ve!=="position:nodeCollapse"&&ve!=="position:placeholder"||(ve="position"),z.get(ve)(ee,oe[fe],ue[fe]!==void 0?ue[fe]:re.Hu?oe[fe]:se[fe],this.Lp,this.Gd,this.Gd,this)}re.Hu&&ue.location!==void 0&&ee instanceof Ii&&(ee.location=ue.location),re.nv&&ee instanceof Ii&&ee.Zb(!1)}if(y.As.clear(),ho(y,!1),y.Ya(),y.N(),Os(y,!0),x.defaultAnimation===this){for(fe=x.pr.iterator;fe.next();)b=fe.value,b.Tg!==null&&(b.points=b.Tg,b.Tg=null);x.pr.clear()}Os(y,!0),this.isViewportUnconstrained&&(y.scrollMode=this.dw),Wi(x),this.au++,!a&&this.cu>this.au?(this.Wk=!1,this.start()):(this.dn&&this.dn(this),pa(this,null),x.Ml(this),y.$b())}},we.Cj=function(a,y){var x=y.actualBounds,E=null;if(y instanceof xr&&(E=y.placeholder),E!==null?(x=E.ga(Cs),E=E.padding,x.x+=E.left,x.y+=E.top,this.add(a,"position",x,a.position,!1)):this.add(a,"position",new Qe(x.x+x.width/2,x.y+x.height/2),a.position,!1),this.add(a,"scale",.01,a.scale,!1),a instanceof xr)for(a=a.memberParts;a.next();)E=a.value,E instanceof qn&&this.Cj(E,y)},we.Aj=function(a,y){if(a.isVisible()){var x=null;if(y instanceof xr&&(x=y.placeholder),x!==null){var E=x.ga(Cs);x=x.padding,E.x+=x.left,E.y+=x.top,this.add(a,"position:placeholder",a.position,E,!0)}else this.add(a,"position:nodeCollapse",a.position,y,!0);if(this.add(a,"scale",a.scale,.01,!0),E=this.vc,E.contains(a)&&(E.I(a).nv=!0),a instanceof xr)for(a=a.memberParts;a.next();)E=a.value,E instanceof qn&&this.Aj(E,y)}},we.Ez=function(a){var y=this.Tt.get(a);return y===null&&(y={},this.Tt.add(a,y)),y},Yt.Object.defineProperties(Xo.prototype,{duration:{get:function(){return this.Dg},set:function(a){1>a&&gr(a,">= 1",Xo,"duration"),this.Dg=a}},reversible:{get:function(){return this.ho},set:function(a){this.ho=a}},runCount:{get:function(){return this.cu},set:function(a){0<a?this.cu=a:Dt("Animation.runCount value must be a positive integer.")}},finished:{get:function(){return this.dn},set:function(a){this.dn!==a&&(this.dn=a)}},easing:{get:function(){return this.ot},set:function(a){this.ot=a}},isViewportUnconstrained:{get:function(){return this.j},set:function(a){this.j=a}},isAnimating:{get:function(){return this.bc}}}),Xo.prototype.getTemporaryState=Xo.prototype.Ez,Xo.prototype.stop=Xo.prototype.stop,Xo.prototype.add=Xo.prototype.add,Xo.prototype.addTemporaryPart=Xo.prototype.Iy;function Pa(a,y,x,E){return a/=E/2,1>a?x/2*a*a+y:-x/2*(--a*(a-2)-1)+y}function Ba(a,y,x,E){return a===E?y+x:x*(-Math.pow(2,-10*a/E)+1)+y}Xo.className="Animation",Xo.EaseLinear=function(a,y,x,E){return x*a/E+y},Xo.EaseInOutQuad=Pa,Xo.EaseInQuad=function(a,y,x,E){return x*(a/=E)*a+y},Xo.EaseOutQuad=function(a,y,x,E){return-x*(a/=E)*(a-2)+y},Xo.EaseInExpo=function(a,y,x,E){return a===0?y:x*Math.pow(2,10*(a/E-1))+y},Xo.EaseOutExpo=Ba;function Bo(a,y,x){this.start=a,this.end=y,this.Ku={},this.Hu=x,this.nv=!1}Bo.className="AnimationState";function Za(a,y,x){this.xd=null,this.rf=a,this.so=x||ns,this.uk=null,y!==void 0&&(this.uk=y,x===void 0&&(this.so=Vi))}Za.prototype.copy=function(){var a=new Za(this.rf);a.so=this.so;var y=this.uk;if(y!==null){var x={};y.duration!==void 0&&(x.duration=y.duration),y.finished!==void 0&&(x.finished=y.finished),y.easing!==void 0&&(x.easing=y.easing),a.uk=x}return a};function Fa(a,y){a=a.uk,a!==null&&(a.duration&&(y.duration=a.duration),a.finished&&(y.finished=a.finished),a.easing&&(y.easing=a.easing))}Yt.Object.defineProperties(Za.prototype,{propertyName:{get:function(){return this.rf},set:function(a){this.rf=a}},animationSettings:{get:function(){return this.uk},set:function(a){this.uk=a}},startCondition:{get:function(){return this.so},set:function(a){this.so=a}}});var ns=new Vt(Za,"Default",1),Vi=new Vt(Za,"Immediate",2),Ki=new Vt(Za,"Bundled",3);Za.className="AnimationTrigger",Za.Default=ns,Za.Immediate=Vi,Za.Bundled=Ki;function or(a){jo(this),this.H=null,this.Pa=new An,this.xa="",this.pb=1,this.o=!1,this.j=this.Uh=this.u=this.Oi=this.Ni=this.Mi=this.Li=this.Ji=this.Ki=this.Ii=this.Qi=this.Hi=this.Pi=this.Gi=this.Fi=!0,this.Zq=[],a&&Object.assign(this,a)}we=or.prototype,we.clear=function(){for(var a=this.Pa,y=0;y<a.length;y++){var x=a.s[y];x.Ig=null,$l(x)}a.clear(),this.Zq.length=0},we.Xe=function(a){this.H=a},we.toString=function(a){a===void 0&&(a=0);var y='Layer "'+this.name+'"';if(0>=a)return y;for(var x=0,E=0,b=0,z=0,ee=0,re=this.Pa.iterator;re.next();){var oe=re.value;oe instanceof xr?b++:oe instanceof qn?E++:oe instanceof Tn?z++:oe instanceof Fo?ee++:x++}if(re="",0<x&&(re+=x+" Parts "),0<E&&(re+=E+" Nodes "),0<b&&(re+=b+" Groups "),0<z&&(re+=z+" Links "),0<ee&&(re+=ee+" Adornments "),1<a)for(a=this.Pa.iterator;a.next();)x=a.value,re+=`
`+x.toString(),E=x.data,E!==null&&qa(E)&&(re+=" #"+qa(E)),x instanceof qn?re+=" "+Co(E):x instanceof Tn&&(re+=" "+Co(x.fromNode)+" "+Co(x.toNode));return y+" "+this.Pa.count+": "+re},we.ic=function(a,y,x){if(y===void 0&&(y=null),x===void 0&&(x=null),this.Uh===!1)return null;var E=!1;this.diagram!==null&&this.diagram.viewportBounds.ca(a)&&(E=!0);for(var b=Qe.alloc(),z=this.Pa.s,ee=z.length;ee--;){var re=z[ee];if((E!==!0||Ud(re)!==!1)&&re.isVisible()&&(b.assign(a),Ua(b,re.oe),re=re.ic(b,y,x),re!==null&&(y!==null&&(re=y(re)),re!==null&&(x===null||x(re)))))return Qe.free(b),re}return Qe.free(b),null},we.ji=function(a,y,x,E){if(y===void 0&&(y=null),x===void 0&&(x=null),E instanceof An||E instanceof Pn||(E=new Pn),this.Uh===!1)return E;var b=!1;this.diagram!==null&&this.diagram.viewportBounds.ca(a)&&(b=!0);for(var z=Qe.alloc(),ee=this.Pa.s,re=ee.length;re--;){var oe=ee[re];if((b!==!0||Ud(oe)!==!1)&&oe.isVisible()){z.assign(a),Ua(z,oe.oe);var se=oe;oe.ji(z,y,x,E)&&(y!==null&&(se=y(se)),se===null||x!==null&&!x(se)||E.add(se))}}return Qe.free(z),E},we.Cf=function(a,y,x,E,b){if(y===void 0&&(y=null),x===void 0&&(x=null),E===void 0&&(E=!1),b instanceof An||b instanceof Pn||(b=new Pn),this.Uh===!1)return b;var z=!1;this.diagram!==null&&this.diagram.viewportBounds.Re(a)&&(z=!0);for(var ee=this.Pa.s,re=ee.length;re--;){var oe=ee[re];if((z!==!0||Ud(oe)!==!1)&&oe.isVisible()){var se=oe;oe.Cf(a,y,x,E,b)&&(y!==null&&(se=y(se)),se===null||x!==null&&!x(se)||b.add(se))}}return b},we.Nu=function(a,y,x,E,b,z,ee){if(this.Uh===!1)return b;for(var re=this.Pa.s,oe=re.length;oe--;){var se=re[oe];if((ee!==!0||Ud(se)!==!1)&&z(se)&&se.isVisible()){var ue=se;se.Cf(a,y,x,E,b)&&(y!==null&&(ue=y(ue)),ue===null||x!==null&&!x(ue)||b.add(ue))}}return b},we.og=function(a,y,x,E,b,z){if(x===void 0&&(x=null),E===void 0&&(E=null),b===void 0&&(b=!0),b!==!1&&b!==!0&&((b instanceof An||b instanceof Pn)&&(z=b),b=!0),z instanceof An||z instanceof Pn||(z=new Pn),this.Uh===!1)return z;var ee=!1;this.diagram!==null&&this.diagram.viewportBounds.ca(a)&&(ee=!0);for(var re=Qe.alloc(),oe=Qe.alloc(),se=this.Pa.s,ue=se.length;ue--;){var fe=se[ue];if((ee!==!0||Ud(fe)!==!1)&&fe.isVisible()){re.assign(a),Ua(re,fe.oe),oe.h(a.x+y,a.y),Ua(oe,fe.oe);var ve=fe;fe.og(re,oe,x,E,b,z)&&(x!==null&&(ve=x(ve)),ve===null||E!==null&&!E(ve)||z.add(ve))}}return Qe.free(re),Qe.free(oe),z},we.Fd=function(a,y){if(this.visible){var x=this.Pa.s,E=x.length;if(E!==0){a=qi();for(var b=qi(),z=0;z<E;z++){var ee=x[z];if(ee.vw=z,ee instanceof Tn){if(ee.fd===!1)continue}else if(ee instanceof Fo&&ee.adornedPart!==null)continue;var re=ee.actualBounds;ee.isVisible()&&Xu(re,y)?(ee.Fd(!0),a.push(ee)):(ee.Fd(!1),ee.adornments!==null&&0<ee.adornments.count&&b.push(ee))}for(y=0;y<a.length;y++)for(x=a[y],O0(x),x=x.adornments;x.next();)E=x.value,E.measure(1/0,1/0),E.arrange(),E.Fd(!0);for(y=0;y<b.length;y++)O0(b[y]);Zi(a),Zi(b)}}};function Jr(a,y){var x=1;return a.pb!==1&&(x=y.globalAlpha,y.globalAlpha=x*a.pb),x}we.gc=function(a,y,x){if(this.visible&&this.pb!==0&&(x===void 0&&(x=!0),x||!this.isTemporary)){x=this.Pa.s;var E=x.length;if(E!==0){if(a.isTemporary)for(var b=0;b<E;b++)x[b].Gj();b=Jr(this,a);var z=this.Zq;z.length=0;for(var ee=y.scale,re=Xt.alloc(),oe=0;oe<E;oe++)this.Oj(a,x[oe],y,z,ee,re,!0);if(Xt.free(re),a.isTemporary)for(y=0;y<E;y++)x[y].Gj();a.globalAlpha=b}}};function ta(a,y,x,E,b){if(a.visible&&a.pb!==0&&(b||!a.isTemporary)){b=a.Pa.s;var z=b.length;if(z!==0){var ee=Jr(a,y),re=a.Zq;re.length=0;for(var oe=x.scale,se=Xt.alloc(),ue=0;ue<z;ue++){var fe=b[ue];E.contains(fe)&&a.Oj(y,fe,x,re,oe,se,!1)}Xt.free(se),y.globalAlpha=ee}}}we.Oj=function(a,y,x,E,b,z,ee){if(ee&&!Ud(y))a.Hs(y);else{if(E!==null&&y instanceof Tn&&(y.isOrthogonal&&E.push(y),y.fd===!1)){a.Hs(y);return}for(ee=!1,E=y.containingGroup;E!==null;)ee?E.tb!==null&&z.Ex(E.tb):E.tb!==null&&(ee=!0,z.assign(E.tb)),E=E.containingGroup;var re=y.actualBounds;if(E=!1,ee&&y.isVisible()){if(!z.Yc(re)){a.Hs(y);return}E=!z.Re(re)}E&&(a.save(),a instanceof th?a.bk=z.copy():(a.beginPath(),a.rect(z.x,z.y,z.width,z.height),a.clip())),re.width*b>x.Oq||re.height*b>x.Oq?y.gc(a,x):(b=y.actualBounds,z=y.naturalBounds,b.width===0||b.height===0||isNaN(b.x)||isNaN(b.y)||!y.isVisible()||(x=y.transform,y.areaBackground!==null&&(ks(y,a,y.areaBackground,!0,!0,z,b),a.fillRect(b.x,b.y,b.width,b.height)),y.areaBackground===null&&y.background===null&&(ks(y,a,"rgba(0,0,0,0.3)",!0,!1,z,b),a.fillRect(b.x,b.y,b.width,b.height)),y.background!==null&&(a.transform(x.m11,x.m12,x.m21,x.m22,x.dx,x.dy),ks(y,a,y.background,!0,!1,z,b),a.fillRect(0,0,z.width/2,z.height/2),x.ws()||(y=1/(x.m11*x.m22-x.m12*x.m21),a.transform(x.m22*y,-x.m12*y,-x.m21*y,x.m11*y,y*(x.m21*x.dy-x.m22*x.dx),y*(x.m12*x.dx-x.m11*x.dy)))))),E&&(a.restore(),a.Vc(!0))}},we.g=function(a,y,x,E,b){var z=this.diagram;z!==null&&z.cb(ga,a,this,y,x,E,b)},we.oi=function(a,y,x){var E=this.Pa;if(y.Ig=this,this===null&&$l(y),a>=E.count)a=E.count;else if(E.M(a)===y)return-1;return E.Gb(a,y),y.Vo(x),E=this.diagram,E!==null&&(x?E.N():E.oi(y)),Ha(this,a,y),a},we.pc=function(a,y,x){if(!x&&y.layer!==this&&y.layer!==null)return y.layer.pc(a,y,x);var E=this.Pa;if(0>a||a>=E.length){if(a=E.indexOf(y),0>a)return-1}else if(E.M(a)!==y&&(a=E.indexOf(y),0>a))return-1;return y.Wo(x),E.mb(a),E=this.diagram,E!==null&&(x?E.N():E.pc(y)),y.Ig=null,$l(y),a};function Ha(a,y,x){if(y=ls(a,y,x),x instanceof xr&&x!==null&&isNaN(x.zOrder)){if(x.memberParts.count!==0){for(var E=-1,b=a.Pa.s,z=b.length,ee=0;ee<z;ee++){var re=b[ee];if(re===x&&(y=ee,0<=E)||0>E&&re.containingGroup===x&&(E=ee,0<=y))break}!(0>E)&&E<y&&(b=a.Pa,b.mb(y),b.Gb(E,x))}y=x.containingGroup,y!==null&&Ha(a,-1,y)}x.svg!==null&&x.svg.remove()}function ls(a,y,x){var E=x.zOrder;if(isNaN(E))return y;a=a.Pa;var b=a.count;if(1>=b)return y;if(0>y&&(y=a.indexOf(x)),0>y)return-1;for(var z=y-1,ee=NaN;0<=z&&(ee=a.M(z).zOrder,!!isNaN(ee));)z--;for(var re=y+1,oe=NaN;re<b&&(oe=a.M(re).zOrder,!!isNaN(oe));)re++;if(!isNaN(ee)&&ee>E)for(;;){if(z===-1||ee<=E){if(z++,z===y)break;return a.mb(y),a.Gb(z,x),z}for(ee=NaN;0<=--z&&(ee=a.M(z).zOrder,isNaN(ee)););}else if(!isNaN(oe)&&oe<E)for(;;){if(re===b||oe>=E){if(re--,re===y)break;return a.mb(y),a.Gb(re,x),re}for(oe=NaN;++re<b&&(oe=a.M(re).zOrder,isNaN(oe)););}return y}Yt.Object.defineProperties(or.prototype,{parts:{get:function(){return this.Pa.iterator}},partsBackwards:{get:function(){return this.Pa.iteratorBackwards}},diagram:{get:function(){return this.H}},name:{get:function(){return this.xa},set:function(a){var y=this.xa;if(y!==a){var x=this.diagram;if(x!==null)for(y===""&&Dt("Cannot rename default Layer to: "+a),x=x.layers;x.next();)x.value.name===a&&Dt("Layer.name is already present in this diagram: "+a);for(this.xa=a,this.g("name",y,a),a=this.Pa.iterator;a.next();)a.value.layerName=this.xa}}},opacity:{get:function(){return this.pb},set:function(a){var y=this.pb;y!==a&&((0>a||1<a)&&gr(a,"0 <= value <= 1",or,"opacity"),this.pb=a,this.g("opacity",y,a),a=this.diagram,a!==null&&a.N())}},isTemporary:{get:function(){return this.o},set:function(a){var y=this.o;y!==a&&((this.o=a)&&(this.isInDocumentBounds=!1),this.g("isTemporary",y,a))}},visible:{get:function(){return this.u},set:function(a){var y=this.u;if(y!==a){for(this.u=a,this.g("visible",y,a),y=this.Pa.iterator;y.next();)y.value.Zb(a);a=this.diagram,a!==null&&a.N()}}},pickable:{get:function(){return this.Uh},set:function(a){var y=this.Uh;y!==a&&(this.Uh=a,this.g("pickable",y,a))}},isInDocumentBounds:{get:function(){return this.j},set:function(a){this.j!==a&&(this.j=a,this.diagram!==null&&this.diagram.Ya())}},allowCopy:{get:function(){return this.Fi},set:function(a){var y=this.Fi;y!==a&&(this.Fi=a,this.g("allowCopy",y,a))}},allowDelete:{get:function(){return this.Gi},set:function(a){var y=this.Gi;y!==a&&(this.Gi=a,this.g("allowDelete",y,a))}},allowTextEdit:{get:function(){return this.Pi},set:function(a){var y=this.Pi;y!==a&&(this.Pi=a,this.g("allowTextEdit",y,a))}},allowGroup:{get:function(){return this.Hi},set:function(a){var y=this.Hi;y!==a&&(this.Hi=a,this.g("allowGroup",y,a))}},allowUngroup:{get:function(){return this.Qi},set:function(a){var y=this.Qi;y!==a&&(this.Qi=a,this.g("allowUngroup",y,a))}},allowLink:{get:function(){return this.Ii},set:function(a){var y=this.Ii;y!==a&&(this.Ii=a,this.g("allowLink",y,a))}},allowRelink:{get:function(){return this.Ki},set:function(a){var y=this.Ki;y!==a&&(this.Ki=a,this.g("allowRelink",y,a))}},allowMove:{get:function(){return this.Ji},set:function(a){var y=this.Ji;y!==a&&(this.Ji=a,this.g("allowMove",y,a))}},allowReshape:{get:function(){return this.Li},set:function(a){var y=this.Li;y!==a&&(this.Li=a,this.g("allowReshape",y,a))}},allowResize:{get:function(){return this.Mi},set:function(a){var y=this.Mi;y!==a&&(this.Mi=a,this.g("allowResize",y,a))}},allowRotate:{get:function(){return this.Ni},set:function(a){var y=this.Ni;y!==a&&(this.Ni=a,this.g("allowRotate",y,a))}},allowSelect:{get:function(){return this.Oi},set:function(a){var y=this.Oi;y!==a&&(this.Oi=a,this.g("allowSelect",y,a))}}}),or.prototype.findObjectsNear=or.prototype.og,or.prototype.findObjectsIn=or.prototype.Cf,or.prototype.findObjectsAt=or.prototype.ji,or.prototype.findObjectAt=or.prototype.ic,or.className="Layer";function bt(a,y){if(hm||(Ql(),hm=!0),jo(this),zo=this,this.vb=!0,this.Ka=null,this.ya=this.Aa=0,this.ta=null,Es){var x=this,E=function(){x.removeEventListener(Kt.document,"DOMContentLoaded",E,!1),x.setRTL()};Kt.document.body!==null?this.setRTL():x.addEventListener(Kt.document,"DOMContentLoaded",E,!1)}this.ol=null,dg.add("Model",oa);var b=this;return this.Hb=function(z){var ee=b.partManager;if(z.model===ee.diagram.model&&ee.diagram.aa){ee.diagram.aa=!1;try{var re=z.change;z.modelChange===""&&re===ga&&ee.updateDataBindings(z.object,z.propertyName)}finally{ee.diagram.aa=!0}}},this.Oc=function(z){b.partManager.doModelChanged(z)},this.hu=this.ku=null,na(this),this.model=hy(),this.Wg=!0,Rr(this),this.layout=new as,this.Wg=!1,this.ck=this.ek=this.fk=this.dk=this.ui=this.aA=this.$j=this.Ov=null,this.hk=function(){},this.preventDefault=null,this.rn=!1,this.Yf=new cm,a!==void 0&&(typeof a=="string"||Kt.Element&&a instanceof Element?Hi(this,a):y=a),this.vb=!1,y&&this.nm(y),this}var xo,zo;function na(a){a.Yd=new lo,a.Yd.Xe(a),a.Db=17,a.Gw=!1,a.tn=!1,a.bu="default",a.Wa=new An,a.pj=new Li,a.nl="default",a.Tx(),a.Sx(),a.pb=1,a.pa=new Qe(NaN,NaN).freeze(),a.du=new Qe(NaN,NaN),a.Ca=1,a.Pp=1,a.zt=new Qe(NaN,NaN).freeze(),a.At=NaN,a.Ot=1e-4,a.Mt=100,a.Ab=new kr,a.zu=new Qe(NaN,NaN).freeze(),a.ut=new Xt(NaN,NaN,NaN,NaN).freeze(),a.rj=new vr(0,0,0,0).freeze(),a.sj=vd,a.nu=!1,a.Zt=null,a.fu=null,a.yh=lu,a.zk=vs,a.Fg=lu,a.pq=vs,a.yt=Cs,a.Bt=Cs,a.Fc=!0,a.pn=!1,a.De=new Pn,a.Eh=new Li,a.Xm=!0,a.vp=250,a.vk=-1,a.xp=new vr(16,16,16,16).freeze(),a.kg=!1,a.Jk=!1,a.fn=!0,a.bq=new Zs,a.bq.diagram=a,a.Qg=new Zs,a.Qg.diagram=a,a.cj=new Zs,a.cj.diagram=a,a.zg=null,a.pf=null,a.qu=!1,t0(a),a.ai=new Pn,a.Ht=!0,a.uu=yd,a.pw=!1,a.wu=Of,a.it="auto",a.Op="auto",a.zh=null,a.Fh=null,a.Bh=null,a.Qh=null,a.Oh=null,a.Nh=null,a.Qt=null,a.Lh=null,a.xt=!1,a.Mh=null,a.Ph=null,a.$h=null,a.Ch=null,a.Rt=!1,a.Yt={},a.oj=[null,null],a.Wg=!1,a.Iw=!1,a.ou=!1,a.lt=!1,a.rw=!0,a.ld=!1,a.$i=!1,a.Tw=!0,a.Ce=-2,a.Og=new Li,a.Xn=new An,a.Gg=!1,a.Jd=!0,a.Us=!0,a.Fi=!0,a.Gi=!0,a.Vs=!1,a.Ws=!0,a.Pi=!0,a.Hi=!0,a.Qi=!0,a.Ys=!0,a.Ii=!0,a.Ki=!0,a.Ji=!0,a.Li=!0,a.Mi=!0,a.Ni=!0,a.Oi=!0,a.Zs=!0,a.at=!0,a.qw=!1,a.Vk=!1,a.mn=!0,a.nn=!0,a.Xs=!0,a.$s=!0,a.iu=16,a.mu=16,a.qr=!1,a.gu=!1,a.lu=0,a.ju=0,a.yb=new vr(5).freeze(),a.Hw=new Pn().freeze(),a.Nt=999999999,a.nw=new Pn().freeze(),a.Zi=!0,a.Ee=!0,a.vd=!0,a.Be=!1,a.gf=!1,a.xh=!0,a.hf=!1,a.sy=new Pn,a.ow=new Pn,a.Xh=null,a.aw=new fn(8,8),a.bw=999,a.Bw=1,a.Jw=0,a.fc={scale:1,position:new Qe,bounds:new Xt,Py:new fn,bA:new fn,Oz:!1},a.fc.canvasSize=a.fc.Py,a.fc.newCanvasSize=a.fc.bA,a.fc.isScroll=!1,a.Rw=new Xt(NaN,NaN,NaN,NaN).freeze(),a.wo=new fn(NaN,NaN).freeze(),a.Sp=new Xt(NaN,NaN,NaN,NaN).freeze(),a.It=!1,a.Lg=new Li;var y=new qn,x=new ja;x.bind(new Hs("text","",Co)),y.add(x),a.ny=y,a.Lg.add("",y),y=new qn,x=new ja,x.stroke="brown",x.bind(new Hs("text","",Co)),y.add(x),a.Lg.add("Comment",y),y=new qn,y.selectable=!1,y.avoidable=!1,x=new Dr,x.figure="Ellipse",x.fill="black",x.stroke=null,x.desiredSize=new fn(3,3).ja(),y.add(x),a.Lg.add("LinkLabel",y),a.Yi=new Li,y=new xr,y.selectionObjectName="GROUPPANEL",y.type=Ln.Vertical,x=new ja,x.font="bold 12pt sans-serif",x.bind(new Hs("text","",Co)),y.add(x),x=new Ln(Ln.Auto),x.name="GROUPPANEL";var E=new Dr;E.figure="Rectangle",E.fill="rgba(128,128,128,0.2)",E.stroke="black",x.add(E),E=new wu,E.padding=new vr(5,5,5,5).ja(),x.add(E),y.add(x),a.ly=y,a.Yi.add("",y),a.Kh=new Li,y=new Tn,x=new Dr,x.isPanelMain=!0,y.add(x),x=new Dr,x.toArrow="Standard",x.fill="black",x.stroke=null,x.strokeWidth=0,y.add(x),a.my=y,a.Kh.add("",y),y=new Tn,x=new Dr,x.isPanelMain=!0,x.stroke="brown",y.add(x),a.Kh.add("Comment",y),y=new Fo,y.type=Ln.Auto,x=new Dr,x.fill=null,x.stroke="dodgerblue",x.strokeWidth=3,y.add(x),x=new wu,x.margin=new vr(1.5,1.5,1.5,1.5).ja(),y.add(x),a.St=y,a.wt=y,y=new Fo,y.type=Ln.Link,x=new Dr,x.isPanelMain=!0,x.fill=null,x.stroke="dodgerblue",x.strokeWidth=3,y.add(x),a.Kt=y,a.fe=null,a.mq=!1,a.Ck=null,a.partManager=new oa,a.toolManager=new sa,a.toolManager.initializeStandardTools(),a.defaultTool=a.toolManager,a.currentTool=a.defaultTool,a.nt=null,a.Wm=new ae,a.Vt=null,a.Wt=null,a.Mr=!1,a.commandHandler=us(),a.eq=null,a.fq=tu,a.Pw=!1,a.Mb=1,a.Yh=null,a.Oq=1,a.Sq=0,a.zw=[0,0,0,0,0],a.Tq=0,a.yq=1,a.tw=0,a.uw=new Qe,a.zy=500,a.wp=new Qe,a.wq=!1}bt.prototype.clear=function(){this.animationManager.Cc(),this.model.clear(),df=null,Gd="",js(this,!1),this.Xn.clear(),bg(),this.Og.clear(),this.Xh=null,this.Ya(),this.Va(),this.N()};function js(a,y){a.animationManager.Cc(!0),a.Hw=new Pn().freeze(),a.nw=new Pn().freeze();var x=a.skipsUndoManager,E=a.cc!==null&&a.cc!==void 0;E&&(a.skipsUndoManager=!0);var b=null;a.fe!==null&&(b=a.fe.part,b!==null&&a.remove(b));var z=[],ee=a.Wa.length;if(y){for(y=0;y<ee;y++)for(var re=a.Wa.s[y].parts;re.next();){var oe=re.value;oe!==b&&oe.data===null&&z.push(oe)}for(y=0;y<z.length;y++)a.remove(z[y])}for(y=0;y<ee;y++)a.Wa.s[y].clear();return a.partManager.clear(),a.De.clear(),a.Eh.clear(),a.ai.clear(),a.Ck=null,a.Xn.clear(),bg(),a.Og.clear(),gs=[],b!==null&&(a.add(b),a.partManager.parts.remove(b)),E&&(a.skipsUndoManager=x),z}function us(){return null}bt.prototype.reset=function(){this.clear(),this.vb=!0,na(this),Ku(this),this.Wg=!0,Rr(this),this.layout=new as,this.Wg=!1,this.model=hy(),this.model.undoManager=new Ta,this.vb=this.rn=!1,this.N()},bt.prototype.setRTL=function(a){a=a===void 0?this.div:a,a===null&&(a=Kt.document.body);var y=Rn("div");y.dir="rtl",y.style.cssText="font-size: 14px; width: 1px; height: 1px; position: absolute; top: -1000px; overflow: scroll;",y.textContent="A",a.appendChild(y);var x="reverse";0<y.scrollLeft?x="default":(y.scrollLeft=1,y.scrollLeft===0&&(x="negative")),a.removeChild(y),this.bu=x},bt.prototype.setScrollWidth=function(a){a=a===void 0?this.div:a,a===null&&(a=Kt.document.body);var y=0;if(Es){var x=um;y=xo,x===null&&(x=um=Rn("p"),x.style.width="100%",x.style.height="200px",x.style.boxSizing="content-box",y=xo=Rn("div"),y.style.position="absolute",y.style.visibility="hidden",y.style.width="200px",y.style.height="150px",y.style.boxSizing="content-box",y.appendChild(x)),y.style.overflow="hidden",a.appendChild(y);var E=x.offsetWidth;y.style.overflow="scroll",x=x.offsetWidth,E===x&&(x=y.clientWidth),a.removeChild(y),y=E-x,y!==0||Fs||(y=11)}this.Db=y,this.Gw=!0},bt.prototype.qb=function(a){a.classType===bt&&(this.autoScale=a)},bt.prototype.toString=function(a){a===void 0&&(a=0);var y="";if(this.div&&this.div.id&&(y=this.div.id),y='Diagram "'+y+'"',0>=a)return y;for(var x=this.Wa.iterator;x.next();)y+=`
`+x.value.toString(a-1);return y};function Hi(a,y){if(Es){if(y!=null||Dt("Diagram setup requires an argument DIV."),a.Ka!==null&&Dt("Diagram has already completed setup."),typeof y=="string"?a.Ka=Kt.document.getElementById(y):y instanceof HTMLDivElement?a.Ka=y:Dt("No DIV or DIV id supplied: "+y),a.Ka===null&&Dt("Invalid DIV id; could not get element with id: "+y),a.Ka.H!==void 0&&Dt("Invalid div id; div already has a Diagram associated with it."),!a.ol&&Kt.ResizeObserver){var x=pi(function(){a.$b()},250);a.ol=new Kt.ResizeObserver(function(){x()}),a.ol.observe(a.Ka)}Kt.getComputedStyle(a.Ka,null).position==="static"&&(a.Ka.style.position="relative"),y=5;var E="rgba(2"+y+"5, 255, 255, 0)";y--,a.Ka.style["-webkit-tap-highlight-color"]=E,a.Ka.innerHTML="",a.Ka.H=a,a.Ka.goDiagram=a,a.Ka.go=Kt.go;var b=new Zh(a);if(b.style!==void 0&&(b.style.position="absolute",b.style.top="0px",b.style.left="0px",Kt.getComputedStyle(a.Ka,null).getPropertyValue("direction")==="rtl"&&(a.tn=!0),b.style.zIndex="2",b.style.userSelect="none",b.style.MozUserSelect="none",b.style.touchAction="none",b.style.letterSpacing="normal !important",b.style.wordSpacing="normal !important"),a.ta=b,a.ib=b.context,E=a.ib,a.Mb=a.computePixelRatio(),a.viewSize.w()||(a.Aa=a.Ka.clientWidth||1,a.ya=a.Ka.clientHeight||1),pd(a,a.Aa,a.ya),a.Ka.insertBefore(b.Oa,a.Ka.firstChild),b=new Zh(null),b.width=1,b.height=1,a.jw=b,a.oy=b.context,Es){b=Rn("div");var z=Rn("div");b.style.position="absolute",b.style.overflow="auto",b.style.width=a.Aa+"px",b.style.height=a.ya+"px",b.style.zIndex="1",z.style.position="absolute",z.style.width="1px",z.style.height="1px",a.Ka.appendChild(b),b.appendChild(z),b.onscroll=Eo,b.addEventListener("pointerdown",Go),b.H=a,b.uy=!0,b.vy=!0,a.ku=b,a.hu=z}a.hk=pi(function(){a.Yh=null,a.N()},300),a.Ov=pi(function(){Ca(a)},250),a.preventDefault=function(ee){return ee.preventDefault(),!1},a.$j=function(ee){if(a.isEnabled){var re=Bs(a,ee,!0);re.bubbles=!0;var oe=0,se=0;re.delta=0,ee.deltaX!==void 0?(ee.deltaX!==0&&(oe=0<ee.deltaX?1:-1),ee.deltaY!==0&&(se=0<ee.deltaY?1:-1),re.delta=Math.abs(ee.deltaX)>Math.abs(ee.deltaY)?-oe:-se):ee.wheelDeltaX!==void 0?(ee.wheelDeltaX!==0&&(oe=0<ee.wheelDeltaX?-1:1),ee.wheelDeltaY!==0&&(se=0<ee.wheelDeltaY?-1:1),re.delta=Math.abs(ee.wheelDeltaX)>Math.abs(ee.wheelDeltaY)?-oe:-se):ee.wheelDelta!==void 0&&ee.wheelDelta!==0&&(re.delta=0<ee.wheelDelta?1:-1),a.doMouseWheel(),Ur(re,ee)}},a.aA=function(ee){a.isEnabled&&(a.Vk=!1,Bs(a,ee,!0),ee=a.currentTool,ee.cancelWaitAfter(),ee.standardMouseOver())},a.ui=function(ee){if(a.isEnabled){a.Vk=!0;var re=a.Yt;re[ee.pointerId]===void 0&&(re[ee.pointerId]=ee),re=a.oj;var oe=!1;if(re[0]===null||re[0].pointerId!==ee.pointerId&&re[0].pointerType===ee.pointerType)if(re[1]!==null&&re[1].pointerId===ee.pointerId)re[1]=ee,oe=!0;else if(re[0]===null)re[0]=ee;else if(re[1]===null)re[1]=ee,oe=!0;else{ee.preventDefault();return}else re[0]=ee;(re=ee.pointerType==="touch"||ee.pointerType==="pen")&&(a.qu=!1,a.wq=!0);var se=oe;oe=oo(a,ee,!0,!1,!0,se),hs(a,ee,oe),oe.targetDiagram=tl(ee,ee.target),oe.targetObject=null,se||oe.clone(a.bq),se=a.uw,re=re?25:10,ee.timeStamp-a.tw<a.zy&&!(Math.abs(se.x-ee.screenX)>re||Math.abs(se.y-ee.screenY)>re)?a.yq++:a.yq=1,oe.clickCount=a.yq,a.tw=ee.timeStamp,a.uw.sg(ee.screenX,ee.screenY),a.doMouseDown(),ee.button===1?ee.preventDefault():Ur(oe,ee)}},a.dk=function(ee){if(a.isEnabled){a.Vk=!0;var re=a.oj;if(re[0]===null||re[0].pointerId!==ee.pointerId&&re[0].pointerType===ee.pointerType){if(re[1]!==null&&re[1].pointerId===ee.pointerId){re[1]=ee;return}if(re[0]===null)re[0]=ee;else return}else re[0]=ee;if(re[0].pointerId===ee.pointerId){re=oo(a,ee,!1,!1,!1,re[1]!==null);var oe=Kt.document.elementFromPoint(ee.clientX,ee.clientY)||null;oe!==null&&oe.shadowRoot!==void 0&&oe.shadowRoot!==null&&(oe=oe.shadowRoot.elementFromPoint(ee.clientX,ee.clientY));var se=a,ue=ee;oe&&oe.H&&(ue=ee,se=oe.H),re.targetDiagram=se,hs(a,ue,re),re.targetObject=null,a.doMouseMove(),Ur(re,ee)}}},a.fk=function(ee){if(a.isEnabled){a.Vk=!0;var re=ee.pointerType==="touch"||ee.pointerType==="pen",oe=a.Yt;if(re&&a.qu)delete oe[ee.pointerId],ee.preventDefault();else if(oe=a.oj,oe[0]===null||oe[0].pointerId!==ee.pointerId&&oe[0].pointerType===ee.pointerType)oe[1]!==null&&oe[1].pointerId===ee.pointerId&&(oe[1]=null);else{oe[0]=null,oe=oo(a,ee,!1,!0,!0,!1);var se=Kt.document.elementFromPoint(ee.clientX,ee.clientY)||null;se!==null&&se.shadowRoot!==void 0&&se.shadowRoot!==null&&(se=se.shadowRoot.elementFromPoint(ee.clientX,ee.clientY)),se!==null&&se.H instanceof bt&&se.H!==a&&hs(se.H,ee,oe),se===null&&(se=ee.target),hs(a,ee,oe),oe.clickCount=a.yq,oe.targetDiagram=tl(ee,se),oe.targetObject=null,a.doMouseUp(),Ur(oe,ee),re&&(a.wq=!1)}}},a.ek=function(ee){if(a.isEnabled){a.Vk=!1;var re=a.Yt;re[ee.pointerId]&&delete re[ee.pointerId],re=a.oj,re[0]!==null&&re[0].pointerId===ee.pointerId&&(re[0]=null),re[1]!==null&&re[1].pointerId===ee.pointerId&&(re[1]=null),ee.pointerType!=="touch"&&ee.pointerType!=="pen"&&(ee=a.currentTool,ee.cancelWaitAfter(),ee.standardMouseOver())}},a.ck=function(ee){var re=a.oj;re[0]!==null&&re[0].pointerId===ee.pointerId?(re[0]=null,a.wq=!1):re[1]!==null&&re[1].pointerId===ee.pointerId&&(re[1]=null)},a.Vp=E.Z["d"+jf[1]+jf[2]+"wI"+gf.slice(1,5)]["b"+Tx.slice(1,y)](E.Z,If,y,y),E.Vc(!0),Tr(a),a.nl==="svg"&&(y=a.pj.get("svg"),a.Ka.appendChild(y.Oa),a.ib=y.context)}}bt.prototype.addEventListener=function(a,y,x,E){a.addEventListener(y,x,{capture:E,passive:!1})},bt.prototype.removeEventListener=function(a,y,x,E){a.removeEventListener(y,x,{capture:E})};function Tr(a){var y=a.ta.Oa;y instanceof HTMLCanvasElement||(y=a.div),a.addEventListener(y,"pointerdown",a.ui,!1),a.addEventListener(y,"pointermove",a.dk,!1),a.addEventListener(y,"pointerup",a.fk,!1),a.addEventListener(y,"pointerout",a.ek,!1),a.addEventListener(y,"pointercancel",a.ck,!1),a.addEventListener(y,"pointerenter",a.bz,!1),a.addEventListener(y,"pointerleave",a.cz,!1),a.addEventListener(y,"wheel",a.$j,!1),a.addEventListener(y,"keydown",a.Qz,!1),a.addEventListener(y,"keyup",a.Rz,!1),a.addEventListener(y,"blur",a.Ny,!1),a.addEventListener(y,"focus",a.Oy,!1),a.addEventListener(y,"selectstart",function(x){return x.preventDefault(),!1},!1),a.addEventListener(y,"contextmenu",function(x){return x.preventDefault(),!1},!1),a.addEventListener(Kt,"resize",a.Ov,!1)}function nr(a){30<a.Sq&&(a.Yh=1)}function ho(a,y){a.Yh!==null&&(a.Yh=null,y&&a.hk(),Wa&&Wa.nx||(a.Sq=0,a.zw=[0,0,0,0,0],a.Tq=0))}bt.prototype.computePixelRatio=function(){return this.Yh!==null?this.Yh:Kt.devicePixelRatio||1},bt.prototype.doMouseMove=function(){this.currentTool.doMouseMove()},bt.prototype.doMouseDown=function(){this.currentTool.doMouseDown()},bt.prototype.doMouseUp=function(){this.currentTool.doMouseUp()},bt.prototype.doMouseWheel=function(){this.currentTool.doMouseWheel()},bt.prototype.doKeyDown=function(){this.currentTool.doKeyDown()},bt.prototype.doKeyUp=function(){this.currentTool.doKeyUp()},bt.prototype.doFocus=function(){this.focus()},bt.prototype.focus=function(){if(this.ta)if(this.scrollsPageOnFocus)this.ta.focus();else{var a=Kt.scrollX||Kt.pageXOffset,y=Kt.scrollY||Kt.pageYOffset;this.ta.focus(),Kt.scrollTo(a,y)}},bt.prototype.Oy=function(){this.H.R("GainedFocus")},bt.prototype.Ny=function(){this.H.R("LostFocus")};function Ca(a){if(a.ta!==null){var y=a.Ka;if(y!==null&&y.clientWidth!==0&&y.clientHeight!==0){a.Gw||a.setScrollWidth();var x=a.gf?a.Db:0,E=a.Be?a.Db:0,b=a.Mb;a.Mb=a.computePixelRatio(),a.Mb!==b&&(a.pn=!0,a.$b()),(y.clientWidth!==a.Aa+x||y.clientHeight!==a.ya+E)&&(a.Ee=!0,a.Fc=!0,y=a.layout,y!==null&&y.isViewportSized&&a.autoScale===lu&&(a.Jk=!0,y.C()),a.ld||a.$b())}}}function Rr(a){var y=new or;y.name="Background",a.Al(y),y=new or,y.name="",a.Al(y),y=new or,y.name="Foreground",a.Al(y),y=new or,y.name="Adornment",y.isTemporary=!0,y.isInDocumentBounds=!1,a.Al(y),y=new or,y.name="Tool",y.isTemporary=!0,y.isInDocumentBounds=!0,a.Al(y),y=new or,y.name="Grid",y.allowSelect=!1,y.pickable=!1,y.isTemporary=!0,y.isInDocumentBounds=!1,a.Ww(y,a.Qj("Background"))}function Qo(a){var y=new Ln(Ln.Grid);y.name="GRID";var x=new Dr;return x.figure="LineH",x.stroke="lightgray",x.strokeWidth=.5,x.interval=1,y.add(x),x=new Dr,x.figure="LineH",x.stroke="gray",x.strokeWidth=.5,x.interval=5,y.add(x),x=new Dr,x.figure="LineH",x.stroke="gray",x.strokeWidth=1,x.interval=10,y.add(x),x=new Dr,x.figure="LineV",x.stroke="lightgray",x.strokeWidth=.5,x.interval=1,y.add(x),x=new Dr,x.figure="LineV",x.stroke="gray",x.strokeWidth=.5,x.interval=5,y.add(x),x=new Dr,x.figure="LineV",x.stroke="gray",x.strokeWidth=1,x.interval=10,y.add(x),x=new Ii,x.add(y),x.layerName="Grid",x.zOrder=0,x.isInDocumentBounds=!1,x.isAnimated=!1,x.pickable=!1,x.locationObjectName="GRID",a.add(x),a.partManager.parts.remove(x),y.visible=!1,y}function Eo(){this.H.gu?this.H.gu=!1:this.H.isEnabled?this.H.kx(this):zc(this.H)}function Go(a){this.H.isEnabled?(this.H.lu=a.target.scrollTop,this.H.ju=a.target.scrollLeft):zc(this.H)}bt.prototype.kx=function(a){if(this.ta!==null){var y=this.ku,x=this.hu;this.qr=!0;var E=this.documentBounds,b=this.viewportBounds,z=this.rj,ee=E.x-z.left,re=E.y-z.top,oe=E.width+z.left+z.right,se=E.height+z.top+z.bottom,ue=E.right+z.right;z=E.bottom+z.bottom;var fe=b.x;E=b.y;var ve=b.width,ye=b.height,Ce=b.right,Ae=b.bottom;b=this.scale;var Ye=a.scrollLeft;if(this.tn)switch(this.bu){case"negative":Ye=Ye+a.scrollWidth-a.clientWidth;break;case"reverse":Ye=a.scrollWidth-Ye-a.clientWidth}var We=Ye;ve<oe||ye<se?(Ye=Qe.allocAt(this.position.x,this.position.y),this.allowHorizontalScroll&&this.ju!==We&&(Ye.x=We/b+ee,this.ju=We),this.allowVerticalScroll&&this.lu!==a.scrollTop&&(Ye.y=a.scrollTop/b+re,this.lu=a.scrollTop),this.position=Ye,Qe.free(Ye),this.Ee=this.qr=!1):(Ye=Qe.alloc(),a.uy&&this.allowHorizontalScroll&&(ee<fe&&(this.position=Ye.h(We+ee,this.position.y)),ue>Ce&&(this.position=Ye.h(-(y.scrollWidth-this.Aa)+We-this.Aa/b+ue,this.position.y))),a.vy&&this.allowVerticalScroll&&(re<E&&(this.position=Ye.h(this.position.x,a.scrollTop+re)),z>Ae&&(this.position=Ye.h(this.position.x,-(y.scrollHeight-this.ya)+a.scrollTop-this.ya/b+z))),Qe.free(Ye),this.vd=!0,this.Ee=this.qr=!1,E=this.documentBounds,b=this.viewportBounds,ue=E.right,Ce=b.right,z=E.bottom,Ae=b.bottom,ee=E.x,fe=b.x,re=E.y,E=b.y,ve>=oe&&ee>=fe&&ue<=Ce&&(x.style.width="1px"),ye>=se&&re>=E&&z<=Ae&&(x.style.height="1px"))}},bt.prototype.computeBounds=function(a){return a===void 0&&(a=new Xt),Ps(this),fa(this,a)};function fa(a,y){if(a.fixedBounds.w())return y.assign(a.fixedBounds),y.Co(a.yb),y;for(var x=!0,E=a.Wa.s,b=E.length,z=0;z<b;z++){var ee=E[z];if(ee.visible&&ee.isInDocumentBounds){ee=ee.Pa.s;for(var re=ee.length,oe=0;oe<re;oe++){var se=ee[oe];se.isInDocumentBounds&&se.isVisible()&&(se=se.actualBounds,se.w()&&(x?(x=!1,y.assign(se)):y.ed(se)))}}}return x&&y.h(0,0,0,0),y.Co(a.yb),y}bt.prototype.computePartsBounds=function(a,y){y===void 0&&(y=!1);var x=null;if(Xi(a))for(var E=0;E<a.length;E++){var b=a[E];!y&&b instanceof Tn||(b.Va(),x===null?x=b.actualBounds.copy():x.ed(b.actualBounds))}else for(a=a.iterator;a.next();)E=a.value,!y&&E instanceof Tn||(E.Va(),x===null?x=E.actualBounds.copy():x.ed(E.actualBounds));return x===null?new Xt(NaN,NaN,0,0):x};function Aa(a,y){if((y||a.hf)&&!a.vb&&a.ta!==null&&a.documentBounds.w()){if(a.vb=!0,y){var x=a.initialPosition;if(x.w()){a.vb=!1,a.position=x;return}x=Qe.alloc(),x.xi(a.documentBounds,a.initialDocumentSpot);var E=a.viewportBounds;E=Xt.allocAt(0,0,E.width,E.height);var b=Qe.alloc();b.xi(E,a.initialViewportSpot),b.h(x.x-b.x,x.y-b.y),a.position=b,Xt.free(E),Qe.free(b),Qe.free(x)}x=a.yh,y&&a.Fg!==lu&&(x=a.Fg);var z=x!==lu?ll(a,x):a.scale;x=a.pa.x,E=a.pa.y,b=a.Aa/z;var ee=a.ya/z,re=a.zk,oe=a.pq;y&&!re.sb()&&(oe.sb()||oe.Xb())&&(re=oe.Xb()?ko:oe),Yl(a,a.documentBounds,b,ee,re,y),y=a.scale,a.scale=z,a.vb=!1,z=a.viewportBounds,yt.B(z.x,x)&&yt.B(z.y,E)&&yt.B(z.width,b)&&yt.B(z.height,ee)||a.onViewportBoundsChanged(new Xt(x,E,b,ee),z,y,!1)}}function ll(a,y){var x=a.Pp;if(a.ta===null)return x;a.Va();var E=a.documentBounds;if(!E.w())return x;var b=E.width;E=E.height;var z=a.Aa+(a.gf?a.Db:0),ee=a.ya+(a.Be?a.Db:0),re=z/b,oe=ee/E;return y===fh?(y=Math.min(oe,re),y>x&&(y=x),y<a.minScale&&(y=a.minScale),y>a.maxScale&&(y=a.maxScale),y):y===Kd?(y=oe>re?(ee-a.Db)/E:(z-a.Db)/b,y>x&&(y=x),y<a.minScale&&(y=a.minScale),y>a.maxScale&&(y=a.maxScale),y):a.scale}bt.prototype.zoomToFit=function(){var a=this.sj;this.sj=vd,this.scale=ll(this,fh),a!==vd&&(Aa(this,!1),Yl(this,this.documentBounds,this.Aa/this.Ca,this.ya/this.Ca,this.zk,!1)),this.sj=a},we=bt.prototype,we.BA=function(a,y){y===void 0&&(y=fh);var x=a.width,E=a.height;if(!(x===0||E===0||isNaN(x)&&isNaN(E))){var b=1;if(y===fh||y===Kd)if(isNaN(x))b=this.viewportBounds.height*this.scale/E;else if(isNaN(E))b=this.viewportBounds.width*this.scale/x;else{b=this.Aa;var z=this.ya;b=y===Kd?z/E>b/x?(z-(this.Be?this.Db:0))/E:(b-(this.gf?this.Db:0))/x:Math.min(z/E,b/x)}this.scale=b,this.position=new Qe(a.x,a.y)}},we.Jy=function(a,y){this.Va();var x=this.documentBounds,E=this.viewportBounds;this.position=new Qe(x.x+(a.x*x.width+a.offsetX)-(y.x*E.width-y.offsetX),x.y+(a.y*x.height+a.offsetY)-(y.y*E.height-y.offsetY))},we.zz=function(a){if(a instanceof mt){this.eq=a;var y=Qe.alloc();this.fq=this.op(a.ga(Cs,y)),Qe.free(y)}else this.eq=null,this.fq=tu};function Yl(a,y,x,E,b,z){var ee=Qe.allocAt(a.pa.x,a.pa.y),re=ee.x,oe=ee.y;if(a.eq!==null){var se=Qe.alloc();se=a.eq.ga(Cs,se),re=se.x-a.fq.x/a.scale,oe=se.y-a.fq.y/a.scale,b=Ms,Qe.free(se)}(z||a.scrollMode===vd)&&(b.sb()&&(x>y.width&&(re=y.x+(b.x*y.width+b.offsetX)-(b.x*x-b.offsetX)),E>y.height&&(oe=y.y+(b.y*y.height+b.offsetY)-(b.y*E-b.offsetY))),b=a.rj,z=x-y.width,x<y.width+b.left+b.right?(re=Math.min(re+x/2,y.right+Math.max(z,b.right)-x/2),re=Math.max(re,y.left-Math.max(z,b.left)+x/2),re-=x/2):re>y.left?re=y.left:re<y.right-x&&(re=y.right-x),x=E-y.height,E<y.height+b.top+b.bottom?(oe=Math.min(oe+E/2,y.bottom+Math.max(x,b.bottom)-E/2),oe=Math.max(oe,y.top-Math.max(x,b.top)+E/2),oe-=E/2):oe>y.top?oe=y.top:oe<y.bottom-E&&(oe=y.bottom-E)),ee.x=isFinite(re)?re:-a.yb.left,ee.y=isFinite(oe)?oe:-a.yb.top,a.positionComputation!==null&&(y=a.positionComputation(a,ee),ee.x=y.x,ee.y=y.y),ir(a.Yd,a.pa,ee),a.pa.h(ee.x,ee.y),Ku(a),Qe.free(ee)}we.Ol=function(a,y){if(y===void 0&&(y=!0),y){if(a=ya(this,a,function(x){return x.part},function(x){return x.canSelect()}),a instanceof Ii)return a}else if(a=ya(this,a,function(x){return x.part}),a instanceof Ii)return a;return null},we.ic=function(a,y,x){y===void 0&&(y=null),x===void 0&&(x=null),Ps(this);for(var E=this.Wa.iteratorBackwards;E.next();){var b=E.value;if(b.visible&&(b=b.ic(a,y,x),b!==null))return b}return null};function ya(a,y,x,E){for(x===void 0&&(x=null),E===void 0&&(E=null),Ps(a),a=a.Wa.iteratorBackwards;a.next();){var b=a.value;if(b.visible&&!b.isTemporary&&(b=b.ic(y,x,E),b!==null))return b}return null}we.lz=function(a,y,x){return y===void 0&&(y=!0),Yo(this,a,function(E){return E.part},y?function(E){return E instanceof Ii&&E.canSelect()}:null,x)};function Yo(a,y,x,E,b){for(x===void 0&&(x=null),E===void 0&&(E=null),b instanceof An||b instanceof Pn||(b=new Pn),Ps(a),a=a.Wa.iteratorBackwards;a.next();){var z=a.value;z.visible&&!z.isTemporary&&z.ji(y,x,E,b)}return b}we.ji=function(a,y,x,E){y===void 0&&(y=null),x===void 0&&(x=null),E instanceof An||E instanceof Pn||(E=new Pn),Ps(this);for(var b=this.Wa.iteratorBackwards;b.next();){var z=b.value;z.visible&&z.ji(a,y,x,E)}return E},we.ux=function(a,y,x,E){return y===void 0&&(y=!1),x===void 0&&(x=!0),Sa(this,a,function(b){return b instanceof Ii&&(!x||b.canSelect())},y,E)},we.Cf=function(a,y,x,E,b){y===void 0&&(y=null),x===void 0&&(x=null),E===void 0&&(E=!1),b instanceof An||b instanceof Pn||(b=new Pn),Ps(this);for(var z=this.Wa.iteratorBackwards;z.next();){var ee=z.value;ee.visible&&ee.Cf(a,y,x,E,b)}return b},we.Nu=function(a,y,x,E,b,z){var ee=new Pn;Ps(this);for(var re=this.Wa.iteratorBackwards;re.next();){var oe=re.value;oe.visible&&oe.Nu(a,y,x,E,ee,b,z)}return ee};function Sa(a,y,x,E,b){var z=null;for(z===void 0&&(z=null),x===void 0&&(x=null),E===void 0&&(E=!1),b instanceof An||b instanceof Pn||(b=new Pn),Ps(a),a=a.Wa.iteratorBackwards;a.next();){var ee=a.value;ee.visible&&!ee.isTemporary&&ee.Cf(y,z,x,E,b)}return b}we.mz=function(a,y,x,E,b){return x===void 0&&(x=!0),E===void 0&&(E=!0),is(this,a,y,function(z){return z instanceof Ii&&(!E||z.canSelect())},x,b)},we.og=function(a,y,x,E,b,z){x===void 0&&(x=null),E===void 0&&(E=null),b===void 0&&(b=!0),b!==!1&&b!==!0&&((b instanceof An||b instanceof Pn)&&(z=b),b=!0),z instanceof An||z instanceof Pn||(z=new Pn),Ps(this);for(var ee=this.Wa.iteratorBackwards;ee.next();){var re=ee.value;re.visible&&re.og(a,y,x,E,b,z)}return z};function is(a,y,x,E,b,z){var ee=null;for(ee===void 0&&(ee=null),E===void 0&&(E=null),b===void 0&&(b=!0),b!==!1&&b!==!0&&((b instanceof An||b instanceof Pn)&&(z=b),b=!0),z instanceof An||z instanceof Pn||(z=new Pn),Ps(a),a=a.Wa.iteratorBackwards;a.next();){var re=a.value;re.visible&&!re.isTemporary&&re.og(y,x,ee,E,b,z)}return z}bt.prototype.acceptEvent=function(a){return Bs(this,a,a instanceof MouseEvent)};function Bs(a,y,x){var E=a.Qg;return a.Qg=a.cj,a.cj=E,E.diagram=a,E.event=y,x?hs(a,y,E):(E.viewPoint=a.Qg.viewPoint,E.documentPoint=a.Qg.documentPoint),a=0,y.ctrlKey&&(a+=1),y.altKey&&(a+=2),y.shiftKey&&(a+=4),y.metaKey&&(a+=8),E.modifiers=a,E.button=y.button,y.buttons!==void 0&&(E.buttons=y.buttons),Fs&&y.button===0&&y.ctrlKey&&(E.button=2),E.down=!1,E.up=!1,E.clickCount=1,E.delta=0,E.handled=!1,E.bubbles=!1,E.timestamp=y.timeStamp,E.isMultiTouch=!1,E.targetDiagram=tl(y,y.target),E.targetObject=null,E}function tl(a,y){return y===null?null:(y=y.H)?y:((y=a.path)||typeof a.composedPath!="function"||(y=a.composedPath()),y&&y[0]&&y[0].H?y[0].H:null)}function oo(a,y,x,E,b,z){var ee=a.Qg;return a.Qg=a.cj,a.cj=ee,ee.diagram=a,ee.clickCount=1,a=ee.delta=0,y.ctrlKey&&(a+=1),y.altKey&&(a+=2),y.shiftKey&&(a+=4),y.metaKey&&(a+=8),ee.modifiers=a,ee.event=y,ee.timestamp=y.timeStamp,ee.button=y.button,ee.buttons=y.buttons,Fs&&y.button===0&&y.ctrlKey&&(ee.button=2),ee.down=x,ee.up=E,ee.handled=!1,ee.bubbles=b,ee.isMultiTouch=z,ee}function Ur(a,y){return a.bubbles?!0:(y.stopPropagation!==void 0&&y.stopPropagation(),y.cancelable!==!1&&y.preventDefault(),y.cancelBubble=!0,!1)}bt.prototype.Qz=function(a){var y=this.H;if(!this.H.isEnabled)return!1;var x=Bs(y,a,!1);switch(x.key=String.fromCharCode(a.which),x.down=!0,a.which){case 8:x.key="Backspace";break;case 33:x.key="PageUp";break;case 34:x.key="PageDown";break;case 35:x.key="End";break;case 36:x.key="Home";break;case 37:x.key="Left";break;case 38:x.key="Up";break;case 39:x.key="Right";break;case 40:x.key="Down";break;case 45:x.key="Insert";break;case 46:x.key="Del";break;case 48:x.key="0";break;case 187:case 61:case 107:x.key="Add";break;case 189:case 173:case 109:x.key="Subtract";break;case 27:x.key="Esc"}return y.doKeyDown(),Ur(x,a)},bt.prototype.Rz=function(a){var y=this.H;if(!y.isEnabled)return!1;var x=Bs(y,a,!1);switch(x.key=String.fromCharCode(a.which),x.up=!0,a.which){case 8:x.key="Backspace";break;case 33:x.key="PageUp";break;case 34:x.key="PageDown";break;case 35:x.key="End";break;case 36:x.key="Home";break;case 37:x.key="Left";break;case 38:x.key="Up";break;case 39:x.key="Right";break;case 40:x.key="Down";break;case 45:x.key="Insert";break;case 46:x.key="Del"}return y.doKeyUp(),Ur(x,a)},bt.prototype.bz=function(a){var y=this.H;if(!y.isEnabled)return!1;var x=Bs(y,a,!0);return y.mouseEnter!==null&&y.mouseEnter(x),y.currentTool.standardMouseOver(),Ur(x,a)},bt.prototype.cz=function(a){var y=this.H;if(!y.isEnabled)return!1;var x=Bs(y,a,!0);return y.mouseLeave!==null&&y.mouseLeave(x),Ur(x,a)},bt.prototype.getMouse=function(a){var y=this.ta;if(y===null)return new Qe(0,0);var x=y.getBoundingClientRect();return y=a.clientX-this.Aa/x.width*x.left,a=a.clientY-this.ya/x.height*x.top,this.Ab!==null?Ua(new Qe(y,a),this.Ab):new Qe(y,a)};function hs(a,y,x){var E=a.ta,b=a.Aa,z=a.ya,ee=0,re=0;E!==null&&(E=E.getBoundingClientRect(),ee=y.clientX-b/E.width*E.left,re=y.clientY-z/E.height*E.top),x.viewPoint.h(ee,re),a.Ab!==null?(y=Qe.allocAt(ee,re),a.Ab.Cd(y),x.documentPoint.assign(y),Qe.free(y)):x.documentPoint.h(ee,re)}function ul(a,y,x){if(a.oj[0]!==null){y=a.oj[y];var E=a.ta;E!==null&&(E=E.getBoundingClientRect(),x.h(y.clientX-a.Aa/E.width*E.left,y.clientY-a.ya/E.height*E.top))}}bt.prototype.Ya=function(){this.Zi||(this.Zi=!0,this.$b(!1))};function nl(a){a.ld||Ps(a),a.Va()}bt.prototype.redraw=function(){this.vb||this.ld||(this.N(),this.bd())},we=bt.prototype,we.Pz=function(){return this.kg},we.Xy=function(a){a===void 0&&(a=null);var y=this.animationManager,x=y.isEnabled;y.Cc(),y.isEnabled=!1,Os(this),this.hf=!1,this.du=new Qe(NaN,NaN),y.isEnabled=x,this.ld=!0;var E=this;a!==null&&ji(function(){E.ld=!1,Uo(y,"Model"),a(E)},1)},we.$b=function(a){if(a===void 0&&(a=!1),this.kg!==!0&&!(this.vb||a===!1&&this.ld)){this.kg=!0;var y=this;Kt.requestAnimationFrame(function(){y.kg&&y.bd()})}},we.bd=function(){(!this.fn||this.kg)&&(this.fn&&(this.fn=!1),Os(this))};function hl(a,y,x){!a.Ee||a.vb||a.animationManager.defaultAnimation.isAnimating||zc(a)||(y&&Ps(a),x&&Aa(a,!1))}function Os(a,y){if(!a.ld&&(a.kg=!1,a.Ka!==null||a.wo.w())){a.ld=!0;var x=a.animationManager,E=a.Xn;if(!x.isAnimating&&E.length!==0){for(var b=E.s,z=b.length,ee=0;ee<z;ee++){var re=b[ee];Ys(re,!1),re.v()}E.clear()}E=a.ow,0<E.count&&(E.each(function(oe){oe.Nv()}),E.clear()),b=E=!1,x.defaultAnimation.isAnimating&&(b=!0,E=a.skipsUndoManager,a.skipsUndoManager=!0),x.zb||Ca(a),hl(a,!1,!0),a.fe!==null&&(a.fe.visible&&!a.mq&&(zs(a),a.mq=!0),!a.fe.visible&&a.mq&&(a.mq=!1)),Ps(a),z=!1,(!a.hf||a.xh)&&(a.hf?ep(a,!a.Jk):(a.Ea("Initial Layout"),x.isEnabled===!1&&x.Cc(),ep(a,!1)),z=!0),a.Jk=!1,Ps(a),a.ou||nl(a),hl(a,!0,!1),ee=!1,z?(x=Xt.alloc(),x.assign(a.viewportBounds),a.hf||(ee=a.hf=!0,a.skipsUndoManager||(a.undoManager.isPendingClear=!0),a.undoManager.isPendingUnmodified=!0,Xl(a)),a.R("LayoutCompleted"),hl(a,!0,!1),Xt.free(x)):x.Ok&&x.Qw&&(a.Fg!==lu?a.scale=ll(a,a.Fg):a.yh!==lu?a.scale=ll(a,a.yh):(x=a.initialScale,isFinite(x)&&0<x&&(a.scale=x)),Aa(a,!0)),z&&ee&&a.eb("Initial Layout"),Ps(a),y||a.gc(a.ib),b&&(a.skipsUndoManager=E),a.ld=!1}}function Xl(a){if(a.Fg!==lu)a.scale=ll(a,a.Fg);else if(a.yh!==lu)a.scale=ll(a,a.yh);else{var y=a.initialScale;isFinite(y)&&0<y&&(a.scale=y)}Aa(a,!0),y=a.Wa.s,a.Fd(y,y.length,a,a.viewportBounds),a.R("InitialLayoutCompleted"),a.du.assign(a.pa),zs(a)}function Ps(a){if(a.De.count!==0&&(a.ld||!a.animationManager.isTicking)){for(var y=0;23>y;y++){var x=a.De.iterator;if(x===null||a.De.count===0)break;a.De=new Pn,a.Nv(x,a.De)}a.nodes.each(function(E){E instanceof xr&&E.U&65536&&(E.U=E.U^65536)})}}we.Nv=function(a,y){for(a.reset();a.next();){var x=a.value;!x.Zc()||x instanceof xr||(x.si()?(x.measure(1/0,1/0),x.arrange()):y.add(x))}for(a.reset();a.next();)x=a.value,x instanceof xr&&x.isVisible()&&Ol(this,x);for(a.reset();a.next();)x=a.value,x instanceof Tn&&x.isVisible()&&(x.si()?(x.measure(1/0,1/0),x.arrange()):y.add(x));for(a.reset();a.next();)x=a.value,x instanceof Fo&&x.isVisible()&&(x.si()?(x.measure(1/0,1/0),x.arrange()):y.add(x))};function Ol(a,y){for(var x=qi(),E=qi(),b=y.memberParts;b.next();){var z=b.value;z.isVisible()&&(z instanceof xr?(ph(z)||Su(z)||Vd(z))&&Ol(a,z):z instanceof Tn?z.fromNode===y||z.toNode===y?E.push(z):x.push(z):(z.measure(1/0,1/0),z.arrange()))}for(a=x.length,b=0;b<a;b++)z=x[b],z.measure(1/0,1/0),z.arrange();for(Zi(x),y.measure(1/0,1/0),y.arrange(),a=E.length,y=0;y<a;y++)x=E[y],x.measure(1/0,1/0),x.arrange();Zi(E)}we.Fd=function(a,y,x,E){if(this.vd||this.animationManager.isAnimating)for(var b=0;b<y;b++)a[b].Fd(x,E)},we.gc=function(a){if(this.Ka!==null){if(this.ta===null&&Dt("No canvas specified"),this.nl==="svg"){if(this.Ka!==null){var y=this.animationManager;if(!y.zb&&(!y.isAnimating||y.isTicking)){Lc(this);var x=this.Aa,E=this.ya;if(a.Gv.resize(x,E,x,E),x=this.Wa.s,E=x.length,this.Fd(x,E,this,this.viewportBounds),this.Fc||y.isAnimating){y=this.pa;var b=this.Ca,z=Math.round(y.x*b)/b,ee=Math.round(y.y*b)/b,re=this.Ab;for(re.reset(),b!==1&&re.scale(b),y.x===0&&y.y===0||re.translate(-z,-ee),a.ti=null,Yy(a,re.m11,re.m12,re.m21,re.m22,re.dx,re.dy),this.pb!==1&&(a.globalAlpha=this.pb),Vh(this,a),y=this.Mb,this.ta.context.setTransform(y,0,0,y,0,0),this.ta.context.clearRect(0,0,this.Aa,this.ya),y=0;y<E;y++)x[y].gc(a,this);a=!1,this.Yf?pf(this.Yf,this)&&(a=this.Vp()):a=!0,a&&(kr.prototype.Cd=kr.prototype.Eu),this.Fc=this.vd=!1}}}}else e:if(z=this.animationManager,!z.zb&&(!z.isAnimating||z.isTicking)&&(x=new Date,Lc(this),this.Ka.style.opacity!=="0")){if(E=a!==this.ib,y=this.Wa.s,b=y.length,this.Fd(y,b,this,this.viewportBounds),E)a.Vc(!0),this.vd=!0;else if(!this.Fc&&!z.isAnimating)break e;z=this.Ab,z.reset(),ee=this.Mb,re=this.pa;var oe=this.Ca,se=Math.round(re.x*oe)/oe,ue=Math.round(re.y*oe)/oe;for(oe!==1&&z.scale(oe),re.x===0&&re.y===0||z.translate(-se,-ue),a.setTransform(ee,0,0,ee,0,0),a.clearRect(0,0,this.Aa,this.ya),this.pb!==1&&(a.globalAlpha=this.pb),Vh(this,a),re=0;re<b;re++)a.setTransform(ee,0,0,ee,0,0),a.transform(z.m11,z.m12,z.m21,z.m22,z.dx,z.dy),a.yc(),y[re].gc(a,this);if(y=!1,this.Yf?pf(this.Yf,this)&&(y=this.Vp()):y=!0,y&&(kr.prototype.Cd=kr.prototype.Eu),E?(this.ib.Vc(!0),this.vd=!0):this.Fc=this.vd=!1,y=+new Date-+x,E=Wa&&Wa.nx,x=this.zw,E||this.Yh===null){for(x[this.Tq]=y,this.Tq=(this.Tq+1)%x.length,b=y=0;b<x.length;b++)y+=x[b];this.Sq=y/x.length}if(this.pb!==1&&(a.globalAlpha=1),E)for(a.setTransform(1,0,0,1,0,0),E=0;E<x.length;E++)a.fillText(x[E].toString(),20,150+ +(20*E))}}};function eh(a,y,x,E,b,z,ee,re,oe,se){if(a.Ka!==null){a.ta===null&&Dt("No canvas specified"),ee===void 0&&(ee=null),re===void 0&&(re=null),oe===void 0&&(oe=!1),se===void 0&&(se=!1),Lc(a),a.ib.Vc(!0),a.vd=!0,a.$i=!0;var ue=a.Ca;a.Ca=b;var fe=a.Wa.s,ve=fe.length;try{var ye=new Xt(z.x,z.y,E.width/b,E.height/b),Ce=ye.copy();Ce.Co(x),zs(a,Ce),Ps(a),a.Fd(fe,ve,a,ye),y.setTransform(1,0,0,1,0,0),y.clearRect(0,0,E.width,E.height),re!==null&&re!==""&&(y.fillStyle=re,y.ox(0,0,E.width,E.height));var Ae=a.Mb;y.scale(Ae,Ae);var Ye=kr.alloc();Ye.reset(),Ye.translate(x.left,x.top),Ye.scale(b),z.x===0&&z.y===0||Ye.translate(-z.x,-z.y),y.setTransform(Ye.m11,Ye.m12,Ye.m21,Ye.m22,Ye.dx,Ye.dy),y.yc(),y instanceof th&&Yy(y,Ye.m11,Ye.m12,Ye.m21,Ye.m22,Ye.dx,Ye.dy),kr.free(Ye),Vh(a,y),y.globalAlpha=a.pb;var We=a.Qj("Grid");if(ee){var tt=new Pn,rt=ee.iterator;for(rt.reset();rt.next();){var at=rt.value;at instanceof Ii&&(se||at.layer!==We)&&(at.Gj(),tt.add(at))}for(se=0;se<ve;se++)ta(fe[se],y,a,tt,oe);tt.each(function(At){return At.Gj()})}else for(tt=0;tt<ve;tt++){var gt=fe[tt];gt===We?se&&gt.gc(y,a,!0):gt.gc(y,a,oe)}a.$i=!1,a.Yf&&pf(a.Yf,a)&&a.Vp()}finally{a.Ca=ue,a.ib.Vc(!0),a.vd=!0,a.Fd(fe,ve,a,a.viewportBounds),zs(a),a.ib instanceof th&&(a.ib.Nj.PA(),a.redraw())}}}we.Gf=function(a){return this.Rg[a]},we.Xx=function(a,y){a==="minDrawingLength"&&(this.Oq=y),this.Rg[a]=y,this.redraw()},we.Tx=function(){this.Rg=new Er,this.Rg.drawShadows=!0,this.Rg.textGreeking=!0,this.Rg.viewportOptimizations=!(Fs||ml),this.Rg.temporaryPixelRatio=!0,this.Rg.pictureRatioOptimization=!0,this.Oq=this.Rg.minDrawingLength=1};function Vh(a,y){a=a.Rg,a!==null&&(a.imageSmoothingEnabled!==void 0&&y.Wx(!!a.imageSmoothingEnabled),a=a.defaultFont,a!=null&&(y.font=a))}we.Ql=function(a){return this.on[a]},we.sA=function(a,y){this.on[a]=y},we.Sx=function(){this.on=new Er,this.on.extraTouchArea=10,this.on.extraTouchThreshold=10,this.on.hasGestureZoom=!0},we.set=function(a){return Object.assign(this,a),this},we.Du=function(a){return this.nm(a)},we.nm=function(a){return jc(this,a),this};function jc(a,y){var x=a instanceof Ln,E=a instanceof bt,b;for(b in y){b===""&&Dt("Setting properties requires non-empty property names");var z=a,ee=b;if(x||E){var re=b.indexOf(".");if(0<re){var oe=b.substring(0,re);x?z=a.fb(oe):(z=a[oe],z==null&&(z=a.toolManager[oe])),kn(z)?ee=b.substr(re+1):Dt("Unable to find object named: "+oe+" in "+a.toString()+" when trying to set property: "+b)}}if(ee[0]!=="_"&&!Zo(z,ee))if(E&&ee==="ModelChanged"){a.Yw(y[ee]);continue}else if(E&&ee==="Changed"){a.Pe(y[ee]);continue}else if(E&&Zo(a.toolManager,ee))z=a.toolManager;else if(E&&am(a,ee)){a.Bj(ee,y[ee]);continue}else if(a instanceof Ci&&ee==="Changed"){a.Pe(y[ee]);continue}else Dt('Trying to set undefined property "'+ee+'" on object: '+z.toString());z[ee]=y[b],ee[0]==="_"&&z instanceof mt&&z.Vw(ee)}}we.bx=function(){if(this.Eh.count!==0&&!(1<this.undoManager.transactionLevel)){for(;0<this.Eh.count;){var a=this.Eh;for(this.Eh=new Li,a=a.iterator;a.next();){var y=a.key;y.Xo(a.value),y.qc()}}this.N()}},we.N=function(a){if(a===void 0)this.Fc=!0,this.$b();else{var y=this.viewportBounds;a.w()&&y.Yc(a)&&(this.Fc=!0,this.$b())}this.R("InvalidateDraw")},bt.prototype.invalidateViewport=function(a,y){if(this.Fc!==!0)if(this.Fc=!0,this.nl==="svg")this.bd();else{var x=this.Gf("temporaryPixelRatio")===!0;if(this.Gf("viewportOptimizations")===!0&&this.scrollMode!==Rf&&this.rj.hi(0,0,0,0)&&y.width===a.width&&y.height===a.height){var E=this.scale,b=Math.max(a.y,y.y),z=Math.min(a.y+a.height,y.y+y.height);if(0<Math.max(0,Math.min(a.x+a.width,y.x+y.width)-Math.max(a.x,y.x))*E&&0<Math.max(0,z-b)*E){if(!(this.ld||(this.kg=!1,this.Ka===null||(this.ld=!0,this.documentBounds.w()||(E=Xt.alloc(),kc(this,this.computeBounds(E)),Xt.free(E)),E=this.ta,E===null||E instanceof Fc)))){var ee=this.Mb;b=this.Aa*ee;var re=this.ya*ee,oe=this.scale*ee;z=Math.round(Math.round(y.x*oe)-Math.round(a.x*oe)),y=Math.round(Math.round(y.y*oe)-Math.round(a.y*oe)),oe=this.jw,a=this.oy,oe.width!==b&&(oe.width=b),oe.height!==re&&(oe.height=re),a.clearRect(0,0,b,re),oe=190*ee;var se=70*ee,ue=Math.max(z,0),fe=Math.max(y,0),ve=Math.floor(b-ue),ye=Math.floor(re-fe);a.drawImage(E.Oa,ue,fe,ve,ye,0,0,ve,ye),pf(this.Yf,this)&&a.clearRect(0,0,oe,se),E=qi(),a=qi(),ye=Math.abs(z),ve=Math.abs(y);var Ce=ue===0?0:b-ye;ue=Qe.allocAt(Ce,0),ye=Qe.allocAt(ye+Ce,re),a.push(new Xt(Math.min(ue.x,ye.x),Math.min(ue.y,ye.y),Math.abs(ue.x-ye.x),Math.abs(ue.y-ye.y)));var Ae=this.Ab;if(Ae.reset(),Ae.scale(ee,ee),this.Ca!==1&&Ae.scale(this.Ca),ee=this.pa,(ee.x!==0||ee.y!==0)&&isFinite(ee.x)&&isFinite(ee.y)&&Ae.translate(-ee.x,-ee.y),Ua(ue,Ae),Ua(ye,Ae),E.push(new Xt(Math.min(ue.x,ye.x),Math.min(ue.y,ye.y),Math.abs(ue.x-ye.x),Math.abs(ue.y-ye.y))),Ce=fe===0?0:re-ve,ue.h(0,Ce),ye.h(b,ve+Ce),a.push(new Xt(Math.min(ue.x,ye.x),Math.min(ue.y,ye.y),Math.abs(ue.x-ye.x),Math.abs(ue.y-ye.y))),Ua(ue,Ae),Ua(ye,Ae),E.push(new Xt(Math.min(ue.x,ye.x),Math.min(ue.y,ye.y),Math.abs(ue.x-ye.x),Math.abs(ue.y-ye.y))),pf(this.Yf,this)&&(b=0<z?0:-z,re=0<y?0:-y,ue.h(b,re),ye.h(oe+b,se+re),a.push(new Xt(Math.min(ue.x,ye.x),Math.min(ue.y,ye.y),Math.abs(ue.x-ye.x),Math.abs(ue.y-ye.y))),Ua(ue,Ae),Ua(ye,Ae),E.push(new Xt(Math.min(ue.x,ye.x),Math.min(ue.y,ye.y),Math.abs(ue.x-ye.x),Math.abs(ue.y-ye.y)))),Qe.free(ue),Qe.free(ye),hl(this,!1,!0),this.Ka===null&&Dt("No div specified"),this.ta===null&&Dt("No canvas specified"),!this.animationManager.zb&&(b=this.ib,this.Fc)){for(Lc(this),re=this.Mb,b.setTransform(1,0,0,1,0,0),b.clearRect(0,0,this.Aa*re,this.ya*re),b.drawImage(this.jw.Oa,0<z?0:Math.round(-z),0<y?0:Math.round(-y)),z=this.pa,ee=this.Ca,oe=Math.round(z.x*ee)/ee,se=Math.round(z.y*ee)/ee,y=this.Ab,y.reset(),ee!==1&&y.scale(ee),z.x===0&&z.y===0||y.translate(-oe,-se),b.save(),b.beginPath(),z=a.length,ee=0;ee<z;ee++)oe=a[ee],oe.width!==0&&oe.height!==0&&b.rect(Math.floor(oe.x),Math.floor(oe.y),Math.ceil(oe.width),Math.ceil(oe.height));for(b.clip(),b.setTransform(re,0,0,re,0,0),b.transform(y.m11,y.m12,y.m21,y.m22,y.dx,y.dy),b.yc(),y=this.Wa.s,z=y.length,this.Fd(y,z,this,this.viewportBounds),Vh(this,b),b.globalAlpha=this.pb,re=0;re<z;re++)if(ee=y[re],oe=E,ee.visible&&ee.pb!==0){se=Jr(ee,b),fe=ee.Zq,fe.length=0,ue=this.scale,ve=Xt.alloc(),ye=ee.Pa.s,Ae=ye.length,Ce=oe.length;for(var Ye=0;Ye<Ae;Ye++){var We=ye[Ye],tt=Pf(We,We.actualBounds);e:{for(var rt=2/ue,at=4/ue,gt=0;gt<Ce;gt++){var At=oe[gt];if(At.width!==0&&At.height!==0&&tt.Vu(At.x-rt,At.y-rt,At.width+at,At.height+at)){tt=!0;break e}}tt=!1}tt&&ee.Oj(b,We,this,fe,ue,ve,!0)}Xt.free(ve),b.globalAlpha=se}b.restore(),b.Vc(!0),this.Yf&&pf(this.Yf,this)&&this.Vp(),this.Fc=this.vd=!1,this.hk()}Zi(E),Zi(a),this.ld=!1}}else this.bd();x&&(nr(this),this.bd(),ho(this,!0))}else x?(nr(this),this.bd(),ho(this,!0)):this.bd()}};function Lc(a){a.pn!==!1&&(a.pn=!1,pd(a,a.Aa,a.ya))}function pd(a,y,x){Ku(a);var E=a.Mb;a.ta.resize(y*E,x*E,y,x)&&(a.Fc=!0,a.ib.Vc(!0))}function zc(a){var y=a.ta;if(y===null||a.wo.w())return!0;var x=a.Aa,E=a.ya,b=a.Ka,z=!1,ee=a.gf?a.Db:0,re=a.Be?a.Db:0,oe=b.clientWidth||x+ee,se=b.clientHeight||E+re,ue=a.viewportBounds;b=ue.x;var fe=ue.y,ve=ue.width,ye=ue.height;if((oe!==x+ee||se!==E+re)&&(a.gf=!1,a.Be=!1,re=ee=0,a.Aa=oe,a.ya=se,z=a.pn=!0,Ku(a)),!a.hf||!a.viewportBounds.w())return!0;var Ce=a.ku,Ae=a.hu;if(a.Ee=!1,!(z||a.gf||a.Be||a.mn||a.nn))return!0;var Ye=a.documentBounds,We=0,tt=0,rt=0,at=0,gt=ue.width,At=ue.height,Zn=a.rj;a.contentAlignment.sb()?(Ye.width>gt&&(We=Zn.left,tt=Zn.right),Ye.height>At&&(rt=Zn.top,at=Zn.bottom)):(We=Zn.left,tt=Zn.right,rt=Zn.top,at=Zn.bottom);var mi=Ye.width+We+tt,si=Ye.height+rt+at;Zn=a.scale;var Nn=mi>oe/Zn,pn=si>se/Zn;if(!(z||a.gf||a.Be||Nn||pn))return!0;We=Ye.x-We,oe=ue.x,tt=Ye.right+tt,se=ue.right+ee,rt=Ye.y-rt;var yr=ue.y;Ye=Ye.bottom+at,ue=ue.bottom+re;var sr="1px";if(at="1px",a.scrollMode===vd&&(Nn||pn)&&(Nn&&a.hasHorizontalScrollbar&&a.allowHorizontalScroll&&(Nn=1,We+1<oe&&(Nn=Math.max((oe-We)*Zn+a.Aa,Nn)),tt>se+1&&(Nn=Math.max((tt-se)*Zn+a.Aa,Nn)),gt+ee+1<mi&&(Nn=Math.max((mi-gt)*Zn+a.Aa,Nn)),sr=Nn.toString()+"px"),pn&&a.hasVerticalScrollbar&&a.allowVerticalScroll&&(Nn=1,rt+1<yr&&(Nn=Math.max((yr-rt)*Zn+a.ya,Nn)),Ye>ue+1&&(Nn=Math.max((Ye-ue)*Zn+a.ya,Nn)),At+re+1<si&&(Nn=Math.max((si-At)*Zn+a.ya,Nn)),at=Nn.toString()+"px")),Nn=sr!=="1px",pn=at!=="1px",Nn&&pn||!Nn&&!pn||(pn&&(se-=a.Db),Nn&&(ue-=a.Db),mi<gt+ee||!a.hasHorizontalScrollbar||!a.allowHorizontalScroll||(ee=1,We+1<oe&&(ee=Math.max((oe-We)*Zn+a.Aa,ee)),tt>se+1&&(ee=Math.max((tt-se)*Zn+a.Aa,ee)),gt+1<mi&&(ee=Math.max((mi-gt)*Zn+a.Aa,ee)),sr=ee.toString()+"px"),Nn=sr!=="1px",ee=a.ya,Nn!==a.Be&&(ee=Nn?a.ya-a.Db:a.ya+a.Db),si<At+re||!a.hasVerticalScrollbar||!a.allowVerticalScroll||(re=1,rt+1<yr&&(re=Math.max((yr-rt)*Zn+ee,re)),Ye>ue+1&&(re=Math.max((Ye-ue)*Zn+ee,re)),At+1<si&&(re=Math.max((si-At)*Zn+ee,re)),at=re.toString()+"px"),pn=at!=="1px"),a.qr&&Nn===a.Be&&pn===a.gf)return x===a.Aa&&E===a.ya||a.bd(),!1;if(Nn!==a.Be&&(sr==="1px"?a.ya=a.ya+a.Db:a.ya=Math.max(a.ya-a.Db,1),z=!0),a.Be=Nn,Ae.style.width=sr,pn!==a.gf&&(at==="1px"?a.Aa=a.Aa+a.Db:a.Aa=Math.max(a.Aa-a.Db,1),z=!0,a.tn&&(re=Qe.alloc(),pn?(y.style.left=a.Db+"px",a.position=re.h(a.pa.x+a.Db/a.scale,a.pa.y)):(y.style.left="0px",a.position=re.h(a.pa.x-a.Db/a.scale,a.pa.y)),Qe.free(re))),z&&Ku(a),a.gf=pn,Ae.style.height=at,a.gu=!0,z&&(a.pn=!0),y=Ce.scrollLeft,a.hasHorizontalScrollbar&&a.allowHorizontalScroll&&(gt+1<mi?y=(a.position.x-We)*Zn:We+1<oe?y=Ce.scrollWidth-Ce.clientWidth:tt>se+1&&(y=a.position.x*Zn)),a.tn)switch(a.bu){case"negative":y=-(Ce.scrollWidth-y-Ce.clientWidth);break;case"reverse":y=Ce.scrollWidth-y-Ce.clientWidth}return Ce.scrollLeft=y,a.hasVerticalScrollbar&&a.allowVerticalScroll&&(At+1<si?Ce.scrollTop=(a.position.y-rt)*Zn:rt+1<yr?Ce.scrollTop=Ce.scrollHeight-Ce.clientHeight:Ye>ue+1&&(Ce.scrollTop=a.position.y*Zn)),oe=a.Aa,se=a.ya,Ce.style.width=oe+(a.gf?a.Db:0)+"px",Ce.style.height=se+(a.Be?a.Db:0)+"px",x!==oe||E!==se||a.animationManager.zb?(x=Xt.allocAt(b,fe,ve,ye),a.onViewportBoundsChanged(x,a.viewportBounds,Zn,z),Xt.free(x),!1):!0}we=bt.prototype,we.add=function(a){var y=a.diagram;if(y!==this&&(y!==null&&Dt("Cannot add part "+a.toString()+" to "+this.toString()+". It is already a part of "+y.toString()),y=this.Qj(a.layerName),y===null&&(y=this.Qj("")),y===null&&Dt('Cannot add a Part when unable find a Layer named "'+a.layerName+'" and there is no default Layer'),a.layer!==y)){var x=y.oi(99999999,a,a.diagram===this);0<=x&&this.cb(ts,"parts",y,null,a,null,x),y.isTemporary||this.Ya(),a.C(1),x=a.layerChanged,x!==null&&x(a,null,y)}},we.oi=function(a){this.partManager.oi(a);var y=this;Sf(a,function(x){su(y,x)}),(a instanceof Fo||a instanceof xr&&a.placeholder!==null)&&a.v(),a.data!==null&&Sf(a,function(x){sy(y.partManager,x)}),Su(a)!==!0&&Vd(a)!==!0||this.De.add(a),IS(a,!0,this),zS(a)?(a.actualBounds.w()&&this.N(Pf(a,a.actualBounds)),this.Ya()):a.isVisible()&&a.actualBounds.w()&&this.N(Pf(a,a.actualBounds)),this.$b()},we.pc=function(a){a.Ej(),this.partManager.pc(a);var y=this;a.data!==null&&Sf(a,function(x){ly(y.partManager,x,y)}),this.De.remove(a),zS(a)?(a.actualBounds.w()&&this.N(Pf(a,a.actualBounds)),this.Ya()):a.isVisible()&&a.actualBounds.w()&&this.N(Pf(a,a.actualBounds)),this.$b()},we.remove=function(a){ed(this,a,!0)};function ed(a,y,x){var E=y.layer;E!==null&&E.diagram===a&&(y.isSelected=!1,y.isHighlighted=!1,y.C(2),x&&y.Lj(),x=E.pc(-1,y,!1),0<=x&&a.cb(ss,"parts",E,y,null,x,null),a=y.layerChanged,a!==null&&a(y,E,null))}we.Is=function(a,y){if(y===void 0&&(y=!1),Xi(a))for(var x=a.length,E=0;E<x;E++){var b=a[E];y&&!b.canDelete()||this.remove(b)}else for(x=new Pn,x.addAll(a),a=x.iterator;a.next();)x=a.value,y&&!x.canDelete()||this.remove(x)},we.Kj=function(a,y,x){return x===void 0&&(x=!1),this.partManager.Kj(a,y,x)},bt.prototype.moveParts=function(a,y,x,E){if(x===void 0&&(x=!1),E===void 0&&(E=Qa(this)),this.toolManager!==null){var b=new Li;if(a!==null)if(Xi(a))for(var z=0;z<a.length;z++)dh(this,b,a[z],x,E);else for(a=a.iterator;a.next();)dh(this,b,a.value,x,E);else{for(a=this.parts;a.next();)dh(this,b,a.value,x,E);for(a=this.nodes;a.next();)dh(this,b,a.value,x,E);for(a=this.links;a.next();)dh(this,b,a.value,x,E)}cs(this,b,y,E,x)}};function dh(a,y,x,E,b,z){if(!y.contains(x)&&(z===void 0&&(z=!1),!E||z||x.canMove()||x.canCopy()))if(b===void 0&&(b=Qa(a)),x instanceof qn){if(y.add(x,a.Pd(b,x,x.location)),x instanceof xr&&(x.placeholder!==null||b.dragsMembers))for(z=x.memberParts;z.next();)dh(a,y,z.value,E,b,b.groupsAlwaysMove);for(z=x.linksConnected;z.next();){var ee=z.value;if(!y.contains(ee)){var re=ee.fromNode,oe=ee.toNode;re!==null&&y.contains(re)&&oe!==null&&y.contains(oe)&&dh(a,y,ee,E,b)}}if(b.dragsTree)for(x=x.Ou();x.next();)dh(a,y,x.value,E,b)}else if(x instanceof Tn)for(y.add(x,a.Pd(b,x)),x=x.labelNodes;x.next();)dh(a,y,x.value,E,b);else x instanceof Fo||y.add(x,a.Pd(b,x,x.location))}function cs(a,y,x,E,b){if(y!==null&&y.count!==0){var z=Qe.alloc(),ee=Qe.alloc();ee.assign(x),isNaN(ee.x)&&(ee.x=0),isNaN(ee.y)&&(ee.y=0),(x=a.Mr)||Jl(a,y);for(var re=qi(),oe=qi(),se=y.iterator,ue=Qe.alloc();se.next();){var fe=se.key,ve=se.value;if(fe.Zc()){var ye=Ea(a,fe,y);ye!==null?re.push(new ie(fe,ve,ye)):(!b||fe.canMove())&&(ye=ve.point,z.assign(ye),a.computeMove(fe,z.add(ee),E,ue),fe.location=ue,ve.shifted===void 0&&(ve.shifted=new Qe),ve.shifted.assign(ue.re(ye)))}else se.key instanceof Tn&&oe.push(se.sa)}for(Qe.free(ue),b=re.length,se=0;se<b;se++)fe=re[se],z.assign(fe.info.point),fe.Su.shifted===void 0&&(fe.Su.shifted=new Qe),fe.node.location=z.add(fe.Su.shifted);for(b=Qe.alloc(),se=Qe.alloc(),fe=oe.length,ve=0;ve<fe;ve++){var Ce=oe[ve];if(ye=Ce.key,ye instanceof Tn)if(ye.suspendsRouting){ye.Tg=null,ue=ye.fromNode;var Ae=ye.toNode;if(a.draggedLink!==null&&E.dragsLink)if(Ae=Ce.value.point,ye.dragComputation===null)y.add(ye,a.Pd(E,ye,ee)),bd(ye,ee.x-Ae.x,ee.y-Ae.y);else{Ce=Qe.allocAt(0,0),(ue=ye.i(0))&&ue.w()&&Ce.assign(ue);var Ye=ue=Qe.alloc().assign(Ce).add(ee);E.isGridSnapEnabled&&(E.isGridSnapRealtime||a.lastInput.up)&&(Ye=Qe.alloc(),au(a,ye,ue,Ye,E)),ue.assign(ye.dragComputation(ye,ue,Ye)).re(Ce),y.add(ye,a.Pd(E,ye,ue)),bd(ye,ue.x-Ae.x,ue.y-Ae.y),Qe.free(Ce),Qe.free(ue),Ye!==ue&&Qe.free(Ye)}else ue!==null&&(b.assign(ue.location),Ye=y.I(ue),Ye!==null&&b.re(Ye.point)),Ae!==null&&(se.assign(Ae.location),Ye=y.I(Ae),Ye!==null&&se.re(Ye.point)),ue!==null&&Ae!==null?b.Xa(se)?(ue=Ce.value.point,Ae=z,Ae.assign(b),Ae.re(ue),y.add(ye,a.Pd(E,ye,b)),bd(ye,Ae.x,Ae.y)):(ye.suspendsRouting=!1,ye.bb()):(Ce=Ce.value.point,ue=ue!==null?b:Ae!==null?se:ee,y.add(ye,a.Pd(E,ye,ue)),bd(ye,ue.x-Ce.x,ue.y-Ce.y))}else(ye.fromNode===null||ye.toNode===null)&&(ue=Ce.value.point,y.add(ye,a.Pd(E,ye,ee)),bd(ye,ee.x-ue.x,ee.y-ue.y))}Qe.free(z),Qe.free(ee),Qe.free(b),Qe.free(se),Zi(re),Zi(oe),x||(Ps(a),Qs(a,y))}}bt.prototype.computeMove=function(a,y,x,E){if(E===void 0&&(E=new Qe),E.assign(y),a===null)return E;var b=y,z=x.isGridSnapEnabled;z&&(x.isGridSnapRealtime||this.lastInput.up)&&(b=Qe.alloc(),au(this,a,y,b,x)),x=a.dragComputation!==null?a.dragComputation(a,y,b):b;var ee=a.minLocation,re=ee.x;isNaN(re)&&(re=z?Math.round(1e3*a.location.x)/1e3:a.location.x),ee=ee.y,isNaN(ee)&&(ee=z?Math.round(1e3*a.location.y)/1e3:a.location.y);var oe=a.maxLocation,se=oe.x;return isNaN(se)&&(se=z?Math.round(1e3*a.location.x)/1e3:a.location.x),oe=oe.y,isNaN(oe)&&(oe=z?Math.round(1e3*a.location.y)/1e3:a.location.y),E.h(Math.max(re,Math.min(x.x,se)),Math.max(ee,Math.min(x.y,oe))),b!==y&&Qe.free(b),E};function Qa(a){var y=a.toolManager.findTool("Dragging");return y!==null?y.dragOptions:a.Wm}function au(a,y,x,E,b){if(b===void 0&&(b=Qa(a)),E.assign(x),y!==null){var z=a.grid;y=b.gridSnapCellSize,a=y.width,y=y.height;var ee=b.gridSnapOrigin,re=ee.x;if(ee=ee.y,b=b.gridSnapCellSpot,z!==null){var oe=z.gridCellSize;isNaN(a)&&(a=oe.width),isNaN(y)&&(y=oe.height),z=z.gridOrigin,isNaN(re)&&(re=z.x),isNaN(ee)&&(ee=z.y)}z=Qe.allocAt(0,0),z.yi(0,0,a,y,b),yt.No(x.x,x.y,re+z.x,ee+z.y,a,y,E),Qe.free(z)}}function Jl(a,y){if(y!==null)for(a.Mr=!0,a=y.iterator;a.next();)y=a.key,y instanceof Tn&&(y.suspendsRouting=!0)}function Qs(a,y){if(y!==null){for(y=y.iterator;y.next();){var x=y.key;x instanceof Tn&&(x.suspendsRouting=!1,_0(x)&&x.bb())}a.Mr=!1}}function Ea(a,y,x){return y=y.containingGroup,y!==null&&(a=Ea(a,y,x),a!==null||(a=x.I(y),a!==null))?a:null}we=bt.prototype,we.Pd=function(a,y,x){if(x===void 0)return new nd(bs);var E=a.isGridSnapEnabled;return a.groupsSnapMembers||y.containingGroup===null||(E=!1),E?new nd(new Qe(Math.round(1e3*x.x)/1e3,Math.round(1e3*x.y)/1e3)):new nd(x.copy())};function ba(a,y,x){if(y.diagram!==null&&y.diagram!==a&&Dt("Cannot share a Layer with another Diagram: "+y+" of "+y.diagram),x===null?y.diagram!==null&&Dt("Cannot add an existing Layer to this Diagram again: "+y):(x.diagram!==a&&Dt("Existing Layer must be in this Diagram: "+x+" not in "+x.diagram),y===x&&Dt("Cannot move a Layer before or after itself: "+y)),y.diagram!==a){y=y.name,a=a.Wa,x=a.count;for(var E=0;E<x;E++)a.M(E).name===y&&Dt("Cannot add Layer with the name '"+y+"'; a Layer with the same name is already present in this Diagram.")}}we.Al=function(a){ba(this,a,null),a.Xe(this);var y=this.Wa,x=y.count-1;if(!a.isTemporary)for(;0<=x&&y.M(x).isTemporary;)x--;return y.Gb(x+1,a),this.cc!==null&&this.cb(ts,"layers",this,null,a,null,x+1),this.N(),this.Ya(),this},we.Ww=function(a,y){ba(this,a,y),a.Xe(this);var x=this.Wa,E=x.indexOf(a);0<=E&&(x.remove(a),this.cc!==null&&this.cb(ss,"layers",this,a,null,E,null));var b=x.count,z;for(z=0;z<b;z++)if(x.M(z)===y){x.Gb(z,a);break}return this.cc!==null&&this.cb(ts,"layers",this,null,a,null,z),this.N(),0>E&&this.Ya(),this},we.Cy=function(a,y){ba(this,a,y),a.Xe(this);var x=this.Wa,E=x.indexOf(a);0<=E&&(x.remove(a),this.cc!==null&&this.cb(ss,"layers",this,a,null,E,null));var b=x.count,z;for(z=0;z<b;z++)if(x.M(z)===y){x.Gb(z+1,a);break}return this.cc!==null&&this.cb(ts,"layers",this,null,a,null,z+1),this.N(),0>E&&this.Ya(),this},we.kA=function(a){if(a.diagram!==this&&Dt("Cannot remove a Layer from another Diagram: "+a+" of "+a.diagram),a.name!==""){var y=this.Wa,x=y.indexOf(a);if(y.remove(a)){for(y=a.Pa.copy().iterator;y.next();){var E=y.value,b=E.layerName;b!==a.name?E.layerName=b:E.layerName=""}this.cc!==null&&this.cb(ss,"layers",this,a,null,x,null),this.N(),this.Ya()}}},we.Qj=function(a){for(var y=this.layers;y.next();){var x=y.value;if(x.name===a)return x}return null},we.Yw=function(a){return this.pf===null&&(this.pf=new An),this.pf.add(a),this.model.Pe(a),this},we.mA=function(a){this.pf!==null&&(this.pf.remove(a),this.pf.count===0&&(this.pf=null)),this.model.ik(a)},we.Pe=function(a){return this.zg===null&&(this.zg=new An),this.zg.add(a),this},we.ik=function(a){this.zg!==null&&(this.zg.remove(a),this.zg.count===0&&(this.zg=null))},we.ds=function(a){if(this.skipsUndoManager||this.model.skipsUndoManager||this.model.undoManager.Tu(a),a.change!==sl&&(this.isModified=!0),this.zg!==null)for(var y=this.zg,x=y.length,E=0;E<x;E++)y.M(E)(a)},we.cb=function(a,y,x,E,b,z,ee){z===void 0&&(z=null),ee===void 0&&(ee=null);var re=new ka;re.diagram=this,re.change=a,re.propertyName=y,re.object=x,re.oldValue=E,re.oldParam=z,re.newValue=b,re.newParam=ee,this.ds(re)},we.g=function(a,y,x,E,b){this.cb(ga,a,this,y,x,E,b)},bt.prototype.changeState=function(a,y){if(a!==null&&a.diagram===this){var x=this.skipsModelSourceBindings;try{this.skipsModelSourceBindings=!0;var E=a.change;if(E===ga){var b=a.object;if(rs(b,a.propertyName,a.I(y)),b instanceof mt){var z=b.part;z!==null&&z.Wb()}this.isModified=!0}else if(E===ts){var ee=a.object,re=a.newParam,oe=a.newValue;if(ee instanceof Ln)if(typeof re=="number"&&oe instanceof mt){y?ee.pc(re):ee.Gb(re,oe);var se=ee.part;se!==null&&se.Wb()}else typeof re=="number"&&oe instanceof Xs&&(oe.isRow?hS(ee,re,y?void 0:oe):cS(ee,re,y?void 0:oe));else if(ee instanceof or){var ue=a.oldParam===!0;typeof re=="number"&&oe instanceof Ii&&(y?(oe.isSelected=!1,oe.isHighlighted=!1,oe.Wb(),ee.pc(ue?re:-1,oe,ue)):ee.oi(re,oe,ue))}else ee instanceof bt?typeof re=="number"&&oe instanceof or&&(y?this.Wa.mb(re):(oe.Xe(this),this.Wa.Gb(re,oe))):Dt("unknown ChangedEvent.Insert object: "+a.toString());this.isModified=!0}else if(E===ss){var fe=a.object,ve=a.oldParam,ye=a.oldValue;if(fe instanceof Ln)typeof ve=="number"&&ye instanceof mt?y?fe.Gb(ve,ye):fe.pc(ve):typeof ve=="number"&&ye instanceof Xs&&(ye.isRow?hS(fe,ve,y?ye:void 0):cS(fe,ve,y?ye:void 0));else if(fe instanceof or){var Ce=a.newParam===!0;typeof ve=="number"&&ye instanceof Ii&&(y?0>fe.Pa.indexOf(ye)&&fe.oi(ve,ye,Ce):(ye.isSelected=!1,ye.isHighlighted=!1,ye.Wb(),fe.pc(Ce?ve:-1,ye,Ce)))}else fe instanceof bt?typeof ve=="number"&&ye instanceof or&&(y?(ye.Xe(this),this.Wa.Gb(ve,ye)):this.Wa.mb(ve)):Dt("unknown ChangedEvent.Remove object: "+a.toString());this.isModified=!0}else E!==sl&&Dt("unknown ChangedEvent: "+a.toString())}finally{this.skipsModelSourceBindings=x}}},bt.prototype.Ea=function(a){return this.undoManager.Ea(a)},bt.prototype.eb=function(a){return this.undoManager.eb(a)},bt.prototype.Kf=function(){return this.undoManager.Kf()},bt.prototype.commit=function(a,y){y===void 0&&(y="");var x=this.skipsUndoManager;y===null&&(this.skipsUndoManager=!0,y=""),this.undoManager.Ea(y);var E=!1;try{a(this),E=!0}finally{E?this.undoManager.eb(y):this.undoManager.Kf(),this.skipsUndoManager=x}},bt.prototype.updateAllTargetBindings=function(a){this.partManager.updateAllTargetBindings(a)},bt.prototype.rp=function(){this.partManager.rp()};function cl(a,y,x){var E=a.animationManager;if(a.vb||a.ld)a.Ca=x,Ku(a),a.N(),a.Ee=!0,E.zb&&(Ar(E)||E.ce.add(E.H,"scale",y,a.Ca));else if(a.ta===null)a.Ca=x,Ku(a);else{a.vb=!0;var b=a.viewportBounds.copy(),z=a.Aa,ee=a.ya,re=a.zoomPoint.x,oe=a.zoomPoint.y,se=a.contentAlignment;isNaN(re)&&(se.$c()?se.Hf(ec)?re=0:se.Hf(Dl)&&(re=z-1):re=se.sb()?se.x*(z-1):z/2),isNaN(oe)&&(se.$c()?se.Hf(Eh)?oe=0:se.Hf(ru)&&(oe=ee-1):oe=se.sb()?se.y*(ee-1):ee/2),a.scaleComputation===null||a.animationManager.defaultAnimation.isAnimating||(x=a.scaleComputation(a,x)),x<a.minScale&&(x=a.minScale),x>a.maxScale&&(x=a.maxScale),z=Qe.allocAt(a.pa.x+re/y-re/x,a.pa.y+oe/y-oe/x),a.position=z,Qe.free(z),a.Ca=x,Ku(a),a.vb=!1,a.onViewportBoundsChanged(b,a.viewportBounds,y,!1),Aa(a,!1),E.zb&&(Ar(E)||E.ce.add(E.H,"scale",y,a.Ca))}}bt.prototype.onViewportBoundsChanged=function(a,y,x,E){if(!a.D(y)){E===void 0&&(E=!1),E||(this.Ee=!0),this.vd=!0;var b=this.layout;b===null||!b.isViewportSized||this.autoScale!==lu||a.width===y.width&&a.height===y.height||b.C(),b=this.currentTool,this.Vk===!0&&b instanceof sa&&(this.lastInput.documentPoint=this.Ps(this.lastInput.viewPoint),mo(b,this)),this.vb||this.invalidateViewport(a,y),zs(this),this.fc.scale=x,this.fc.position.x=a.x,this.fc.position.y=a.y,this.fc.bounds.assign(a),this.fc.canvasSize.width=Math.round(a.width*x),this.fc.canvasSize.height=Math.round(a.height*x),this.fc.newCanvasSize.width=this.Aa,this.fc.newCanvasSize.height=this.ya,this.fc.isScroll=E,this.R("ViewportBoundsChanged",this.fc,a),this.isVirtualized&&this.links.each(function(z){z.isAvoiding&&z.actualBounds.Yc(y)&&z.bb()})}};function zs(a,y){var x=a.fe;if(x!==null&&x.visible){for(var E=fn.alloc(),b=1,z=1,ee=x.O.s,re=ee.length,oe=0;oe<re;oe++){var se=ee[oe],ue=Math.abs(se.interval);2>ue||(p0(se.figure)?z=z*ue/yt.vx(z,ue):b=b*ue/yt.vx(b,ue))}if(ee=x.gridCellSize,E.h(z*ee.width,b*ee.height),y!==void 0)b=y.width,z=y.height,a=y.x,ee=y.y;else{if(y=Xt.alloc(),a=a.viewportBounds,y.h(a.x,a.y,a.width,a.height),!y.w()){Xt.free(y);return}b=y.width,z=y.height,a=y.x,ee=y.y,Xt.free(y)}x.width=b+2*E.width,x.height=z+2*E.height,y=Qe.alloc(),yt.No(a,ee,0,0,E.width,E.height,y),y.offset(-E.width,-E.height),fn.free(E),x.part.location=y,Qe.free(y)}}bt.prototype.clearSelection=function(a){a===void 0&&(a=!1);var y=this.selection;if(y.count!==0){a||this.R("ChangingSelection",y);for(var x=y.Fa(),E=x.length,b=0;b<E;b++)x[b].isSelected=!1;y.ka(),y.clear(),y.freeze(),a||this.R("ChangedSelection",y)}},bt.prototype.select=function(a){a!==null&&a.diagram===this&&(!a.isSelected||1<this.selection.count)&&(this.R("ChangingSelection",this.selection),this.clearSelection(!0),a.isSelected=!0,this.R("ChangedSelection",this.selection))},bt.prototype.rA=function(a){if(this.R("ChangingSelection",this.selection),this.clearSelection(!0),Xi(a))for(var y=a.length,x=0;x<y;x++){var E=a[x];E instanceof Ii||Dt("Diagram.selectCollection given something that is not a Part: "+E),E.isSelected=!0}else for(a=a.iterator;a.next();)y=a.value,y instanceof Ii||Dt("Diagram.selectCollection given something that is not a Part: "+y),y.isSelected=!0;this.R("ChangedSelection",this.selection)},bt.prototype.clearHighlighteds=function(){var a=this.highlighteds;if(0<a.count){for(var y=a.Fa(),x=y.length,E=0;E<x;E++)y[E].isHighlighted=!1;a.ka(),a.clear(),a.freeze()}},we=bt.prototype,we.Iz=function(a){a!==null&&a.diagram===this&&(!a.isHighlighted||1<this.highlighteds.count)&&(this.clearHighlighteds(),a.isHighlighted=!0)},we.Jz=function(a){a=new Pn().addAll(a);for(var y=this.highlighteds.copy().hp(a).iterator;y.next();)y.value.isHighlighted=!1;for(a=a.iterator;a.next();)y=a.value,y instanceof Ii||Dt("Diagram.highlightCollection given something that is not a Part: "+y),y.isHighlighted=!0},we.scroll=function(a,y,x){x===void 0&&(x=1);var E=y==="up"||y==="down",b=0,z=Qe.alloc();if(a==="pixel")b=x;else if(a==="line")b=x*(E?this.scrollVerticalLineChange:this.scrollHorizontalLineChange);else if(a==="page")a=E?this.viewportBounds.height:this.viewportBounds.width,a*=this.scale,a!==0&&(b=x*Math.max(a-(E?this.scrollVerticalLineChange:this.scrollHorizontalLineChange),0));else{if(a==="document"){b=this.documentBounds,x=this.viewportBounds,y==="up"?this.position=z.h(x.x,b.y):y==="left"?this.position=z.h(b.x,x.y):y==="down"?this.position=z.h(x.x,b.bottom-x.height):y==="right"&&(this.position=z.h(b.right-x.width,x.y)),Qe.free(z);return}Dt("scrolling unit must be 'pixel', 'line', 'page', or 'document', not: "+a)}b/=this.scale,x=this.position,y==="up"?this.position=z.h(x.x,x.y-b):y==="down"?this.position=z.h(x.x,x.y+b):y==="left"?this.position=z.h(x.x-b,x.y):y==="right"?this.position=z.h(x.x+b,x.y):Dt("scrolling direction must be 'up', 'down', 'left', or 'right', not: "+y),Qe.free(z)},we.tv=function(a){var y=this.viewportBounds;y.Re(a)||(a=a.center,a.x-=y.width/2,a.y-=y.height/2,this.position=a)},we.es=function(a){var y=this.viewportBounds;a=a.center,a.x-=y.width/2,a.y-=y.height/2,this.position=a},we.op=function(a){var y=this.Ab;y.reset(),this.Ca!==1&&y.scale(this.Ca);var x=this.pa;return(x.x!==0||x.y!==0)&&isFinite(x.x)&&isFinite(x.y)&&y.translate(-x.x,-x.y),a.copy().transform(this.Ab)},we.zA=function(a){var y=this.Ab,x=a.x,E=a.y,b=x+a.width,z=E+a.height,ee=y.m11,re=y.m12,oe=y.m21,se=y.m22,ue=y.dx,fe=y.dy,ve=x*ee+E*oe+ue;y=x*re+E*se+fe;var ye=b*ee+E*oe+ue;return a=b*re+E*se+fe,E=x*ee+z*oe+ue,x=x*re+z*se+fe,ee=b*ee+z*oe+ue,b=b*re+z*se+fe,z=Math.min(ve,ye),ve=Math.max(ve,ye),ye=Math.min(y,a),y=Math.max(y,a),z=Math.min(z,E),ve=Math.max(ve,E),ye=Math.min(ye,x),y=Math.max(y,x),z=Math.min(z,ee),ve=Math.max(ve,ee),ye=Math.min(ye,b),y=Math.max(y,b),new Xt(z,ye,ve-z,y-ye)},we.Ps=function(a){var y=this.Ab;y.reset(),this.Ca!==1&&y.scale(this.Ca);var x=this.pa;return(x.x!==0||x.y!==0)&&isFinite(x.x)&&isFinite(x.y)&&y.translate(-x.x,-x.y),Ua(a.copy(),this.Ab)};function dl(a){var y=a.isModified;a.Tw!==y&&(a.Tw=y,a.R("Modified"))}function Sl(a){return a=dg.get(a),a!==null?new a:new oa}bt.prototype.doModelChanged=function(a){var y=this;if(a.model===this.model){var x=a.change,E=a.propertyName;if(x===sl&&E[0]==="S")if(E==="StartingFirstTransaction"){var b=this;a=this.toolManager,a.mouseDownTools.each(function(oe){return oe.diagram=b}),a.mouseMoveTools.each(function(oe){return oe.diagram=b}),a.mouseUpTools.each(function(oe){return oe.diagram=b}),this.ld||this.hf||(this.Jk=!0,this.fn&&(this.kg=!0))}else E==="StartingUndo"||E==="StartingRedo"?(a=this.animationManager,a.defaultAnimation.isAnimating&&!this.skipsUndoManager&&a.Cc(),this.R("ChangingSelection",this.selection)):E==="StartedTransaction"&&(a=this.animationManager,a.defaultAnimation.isAnimating&&!this.skipsUndoManager&&a.Cc());else if(this.aa){this.aa=!1;try{if(a.modelChange===""&&x===sl){(E==="FinishedUndo"||E==="FinishedRedo")&&(this.R("ChangedSelection",this.selection),Ps(this));var z=this.animationManager;E==="RolledBackTransaction"&&z.Cc(),this.bx(),this.Jk=!0,this.bd(),this.undoManager.transactionLevel!==0&&this.undoManager.transactionLevel!==1||So(z),E==="CommittedTransaction"&&this.undoManager.isJustDiscarded&&(this.Ce=Math.min(this.Ce,this.undoManager.historyIndex-1)),E!=="CommittedTransaction"&&E!=="RolledBackTransaction"||!this.undoManager.isPendingUnmodified||setTimeout(function(){y.isModified=!1},1);var ee=a.isTransactionFinished;if(ee&&(dl(this),this.As.clear(),Do(this.animationManager)),!this.Rt&&ee&&this.lastInput.targetDiagram){this.Rt=!0;var re=this;ji(function(){re.currentTool.standardMouseOver(),re.Rt=!1},10)}}}finally{this.aa=!0}}}};function su(a,y){y=y.O.s;for(var x=y.length,E=0;E<x;E++)Vl(a,y[E])}function Vl(a,y){if(y instanceof Iu){var x=y.element;if(x!==null&&x instanceof HTMLImageElement){x.Bg instanceof Pn&&x.Bg.add(a);var E=y.Eg;if(E!==null&&E.sq===!0&&y.diagram!==null&&y.diagram.Xn.add(y),x.hn)if(x=x.getAttribute("src")||"",E=a.Og.I(x),E===null)E=[],E.push(y),a.Og.add(x,E);else{for(a=0;a<E.length;a++)if(E[a]===y)return;E.push(y)}}}}function Mc(a,y){if(y instanceof Iu){var x=y.element;if(x!==null&&x instanceof HTMLImageElement&&x.hn){var E=x.getAttribute("src")||"",b=a.Og.I(E);if(b!==null){for(var z=0;z<b.length;z++)if(b[z]===y){b.splice(z,1),b.length===0&&(a.Og.remove(E),x.Fq&&x.removeEventListener("load",x.Fq),x.Yp&&x.removeEventListener("error",x.Yp),delete x.Fq,delete x.Yp,x.Bg instanceof Pn&&x.Bg.remove(a),bg(E));break}}}}}bt.prototype.Wd=function(){this.partManager.Wd()},bt.prototype.Aj=function(a,y){this.Yd.Aj(a,y)},bt.prototype.Cj=function(a,y){this.Yd.Cj(a,y)},bt.prototype.findPartForKey=function(a){return this.partManager.findPartForKey(a)},bt.prototype.Vb=function(a){return this.partManager.Vb(a)},bt.prototype.findLinkForKey=function(a){return this.partManager.findLinkForKey(a)},we=bt.prototype,we.Lc=function(a){return this.partManager.Lc(a)},we.ii=function(a){return this.partManager.ii(a)},we.Kc=function(a){return this.partManager.Kc(a)},we.ms=function(a){for(var y=[],x=0;x<arguments.length;++x)y[x]=arguments[x];return this.partManager.ms.apply(this.partManager,y instanceof Array?y:on(bn(y)))},we.ls=function(a){for(var y=[],x=0;x<arguments.length;++x)y[x]=arguments[x];return this.partManager.ls.apply(this.partManager,y instanceof Array?y:on(bn(y)))};function Ku(a){var y=a.pa,x=a.Ca;a.Rw.h(y.x,y.y,Math.max(a.Aa,0)/x,Math.max(a.ya,0)/x),a.vd=!0}function kc(a,y){a.Zi=!1;var x=a.Sp;x.D(y)||(x=x.copy(),a.Sp.assign(y),Aa(a,!1),a.R("DocumentBoundsChanged",void 0,x),a.Ee=!0,a.N())}we.Va=function(){if(this.Zi){var a=Xt.alloc();kc(this,this.computeBounds(a)),Xt.free(a)}},we.rz=function(){for(var a=new Pn,y=this.nodes;y.next();){var x=y.value;x.isTopLevel&&a.add(x)}for(y=this.links;y.next();)x=y.value,x.isTopLevel&&a.add(x);return a.iterator},we.qz=function(){return this.ai.iterator},we.Uz=function(a){Ps(this),a&&td(this,!0),this.ld?ep(this,!1):(this.Jk=!0,Os(this))};function td(a,y){for(var x=a.ai.iterator;x.next();)Hd(a,x.value,y);a.layout&&(y?a.layout.isValidLayout=!1:a.layout.C())}function Hd(a,y,x){if(y!==null){for(var E=y.gl.iterator;E.next();)Hd(a,E.value,x);y.layout!==null&&(x?y.layout.isValidLayout=!1:y.layout.C())}}function ep(a,y){if(a.xh&&!a.lt){var x=a.aa;a.aa=!0;var E=a.undoManager.transactionLevel,b=a.layout,z=a.animationManager;try{E===0&&(a.undoManager.isInternalTransaction=!0,a.Ea("Layout")),1>=E&&!z.defaultAnimation.isAnimating&&!z.zb&&(y||Uo(z,"Layout")),a.xh=!1;for(var ee=a.ai.iterator;ee.next();)tp(a,ee.value,y,E);b.isValidLayout||(!y||b.isRealtime||b.isRealtime===null||E===0?(b.doLayout(a),Ps(a),b.isValidLayout=!0):a.xh=!0)}finally{y=a.undoManager.isInternalTransaction,E===0&&(a.eb("Layout"),a.undoManager.isInternalTransaction=!1),!y||E!==0&&E!==1||So(z),a.aa=x}}}function tp(a,y,x,E){if(y!==null){for(var b=y.gl.iterator;b.next();)tp(a,b.value,x,E);b=y.layout,b===null||b.isValidLayout||(!x||b.isRealtime||E===0?(y.rh=!y.location.w(),b.doLayout(y),y.C(32),Ol(a,y),b.isValidLayout=!0):a.xh=!0)}}we.yz=function(){for(var a=new An,y=this.nodes;y.next();){var x=y.value;x.isTopLevel&&x.kh()===null&&a.add(x)}return a.iterator};function t0(a){function y(b){var z=b.toLowerCase(),ee=new An;x.add(b,ee),x.add(z,ee),E.add(b,b),E.add(z,b)}var x=new Li,E=new Li;y("InitialAnimationStarting"),y("AnimationStarting"),y("AnimationFinished"),y("BackgroundSingleClicked"),y("BackgroundDoubleClicked"),y("BackgroundContextClicked"),y("ClipboardChanged"),y("ClipboardPasted"),y("DocumentBoundsChanged"),y("ExternalObjectsDropped"),y("GainedFocus"),y("InitialLayoutCompleted"),y("LayoutCompleted"),y("LinkDrawn"),y("LinkRelinked"),y("LinkReshaped"),y("LostFocus"),y("Modified"),y("ObjectSingleClicked"),y("ObjectDoubleClicked"),y("ObjectContextClicked"),y("PartCreated"),y("PartResized"),y("PartRotated"),y("SelectionMoved"),y("SelectionCopied"),y("SelectionDeleting"),y("SelectionDeleted"),y("SelectionGrouped"),y("SelectionUngrouped"),y("ChangingSelection"),y("ChangedSelection"),y("SubGraphCollapsed"),y("SubGraphExpanded"),y("TextEdited"),y("TreeCollapsed"),y("TreeExpanded"),y("ViewportBoundsChanged"),y("InvalidateDraw"),a.iw=x,a.hw=E}function am(a,y){var x=a.hw.I(y);return x!==null?x:a.hw.I(y.toLowerCase())}function lg(a,y){var x=a.iw.I(y);if(x!==null||(x=a.iw.I(y.toLowerCase()),x!==null))return x;Dt("Unknown DiagramEvent name: "+y)}we.Bj=function(a,y){return a=lg(this,a),a!==null&&a.add(y),this},we.am=function(a,y){a=lg(this,a),a!==null&&a.remove(y)},we.R=function(a,y,x){var E=lg(this,a),b=new mu;if(b.diagram=this,a=am(this,a),a!==null&&(b.name=a),y!==void 0&&(b.subject=y),x!==void 0&&(b.parameter=x),y=E.length,y===1)E.M(0)(b);else if(y!==0)for(E=E.Fa(),x=0;x<y;x++)(0,E[x])(b)};function ug(a){if(a.animationManager.isTicking)return!1;var y=a.currentTool;return y===a.toolManager.findTool("Dragging")?!a.Mr||y.isComplexRoutingRealtime:!0}we.Yj=function(a,y){return hg(this,!1,null,y||null).Yj(a.x,a.y,a.width,a.height)},bt.prototype.computeOccupiedArea=function(a){return this.isVirtualized?this.viewportBounds.copy():this.Zi?fa(this,a):a.assign(this.documentBounds)};function hg(a,y,x,E){var b=a.Xh;if(b===null&&(a.Xh=b=new Ap(a.avoidanceCellSize)),b.vs||b.group!==x||b.Yx!==E){if(b.Hx=Math.max(b.Os+1,Math.floor(a.avoidanceLimit/a.avoidanceCellSize.width)),b.Ix=Math.max(b.Os+1,Math.floor(a.avoidanceLimit/a.avoidanceCellSize.height)),x!==null&&(x=sm(a,x)),x===null){y=Xt.alloc(),a.computeOccupiedArea(y),y.Bc(100,100),b.initialize(y);for(var z=a.nodes;z.next();){var ee=z.value,re=ee.layer;re!==null&&re.visible&&!re.isTemporary&&cg(a,ee,E,y)}Xt.free(y)}else{for(0<x.memberParts.count&&(y=a.computePartsBounds(x.memberParts,!1),y.Bc(20,20),b.initialize(y)),y=Xt.alloc(),z=x.memberParts;z.next();)ee=z.value,ee instanceof qn&&cg(a,ee,E,y);Xt.free(y)}b.group=x,b.Yx=E,b.vs=!1}else y&&r1(b);return b}function sm(a,y){return y.avoidable&&!y.isLinkLabel?y:y.containingGroup!==null?sm(a,y.containingGroup):null}function cg(a,y,x,E){if(y!==x&&y.isVisible()){if(y.avoidable&&!y.isLinkLabel){y=y.getAvoidableRect(E),a=a.Xh;var b=y.x,z=y.y;if(Ng(a,b,z))for(x=(z-a.Od)/a.sc|0,E=Math.min((b+y.width-a.Nd)/a.rc|0,a.di),y=Math.min((z+y.height-a.Od)/a.sc|0,a.ei),b=(b-a.Nd)/a.rc|0;b<=E;b++)if(z=a.ac[b],z.fill)z.fill(Md,x,y+1);else for(var ee=x;ee<=y;ee++)z[ee]=Md}else if(y instanceof xr)for(y=y.memberParts;y.next();)b=y.value,b instanceof qn&&cg(a,b,x,E)}}function md(a,y){a.Xh===null||a.Xh.vs||y!==void 0&&(!y.avoidable||y.isLinkLabel)||(a.Xh.vs=!0)}bt.prototype.gs=function(a){this.wp.assign(a),this.computeAutoScrollPosition(this.wp).Xa(this.position)?this.ug():np(this)};function np(a){a.vk===-1&&(a.vk=ji(function(){if(a.vk!==-1&&(a.ug(),a.lastInput.event!==null)){var y=a.computeAutoScrollPosition(a.wp);y.Xa(a.position)||(a.position=y,a.lastInput.documentPoint=a.Ps(a.wp),a.doMouseMove(),a.Zi=!0,y=Xt.alloc(),a.computeBounds(y),y.ed(a.documentBounds),kc(a,y),Xt.free(y),a.Fc=!0,a.bd(),np(a))}},a.vp))}bt.prototype.ug=function(){this.vk!==-1&&(Kt.clearTimeout(this.vk),this.vk=-1)},bt.prototype.computeAutoScrollPosition=function(a){var y=this.position,x=this.xp;if(0>=x.top&&0>=x.left&&0>=x.right&&0>=x.bottom)return y;var E=this.viewportBounds,b=this.scale;E=Xt.allocAt(0,0,E.width*b,E.height*b);var z=Qe.allocAt(0,0);if(a.x>=E.x&&a.x<E.x+x.left&&this.allowHorizontalScroll){var ee=Math.max(this.scrollHorizontalLineChange,1);ee|=0,z.x-=ee,a.x<E.x+x.left/2&&(z.x-=ee),a.x<E.x+x.left/4&&(z.x-=4*ee)}else a.x<=E.x+E.width&&a.x>E.x+E.width-x.right&&this.allowHorizontalScroll&&(ee=Math.max(this.scrollHorizontalLineChange,1),ee|=0,z.x+=ee,a.x>E.x+E.width-x.right/2&&(z.x+=ee),a.x>E.x+E.width-x.right/4&&(z.x+=4*ee));return a.y>=E.y&&a.y<E.y+x.top&&this.allowVerticalScroll?(ee=Math.max(this.scrollVerticalLineChange,1),ee|=0,z.y-=ee,a.y<E.y+x.top/2&&(z.y-=ee),a.y<E.y+x.top/4&&(z.y-=4*ee)):a.y<=E.y+E.height&&a.y>E.y+E.height-x.bottom&&this.allowVerticalScroll&&(ee=Math.max(this.scrollVerticalLineChange,1),ee|=0,z.y+=ee,a.y>E.y+E.height-x.bottom/2&&(z.y+=ee),a.y>E.y+E.height-x.bottom/4&&(z.y+=4*ee)),z.Xa(bs)||(y=new Qe(y.x+z.x/b,y.y+z.y/b)),Xt.free(E),Qe.free(z),y},we=bt.prototype,we.Cs=function(){return null},we.av=function(){return null},we.bs=function(a,y){this.pj.add(a,y)},we.Fu=function(a){(this.Pw=a)||this.nodes.each(function(y){y instanceof xr&&(y.$p=null)})};function Bf(a,y,x){function E(){var ue=+new Date;for(z=!0,ee.reset();ee.next();)if(!ee.value[0].al){z=!1;break}z||ue-se>oe?y(x,b,re):Kt.requestAnimationFrame(E)}for(var b=x.callback,z=!0,ee=a.Og.iterator;ee.next();)if(!ee.value[0].al){z=!1;break}if(typeof b!="function"||z)return y(x,b,a);var re=a,oe=x.callbackTimeout||300,se=+new Date;return Kt.requestAnimationFrame(function(){E()}),null}we.Wz=function(a){return Es?(a===void 0&&(a={}),a.returnType="Image",this.Jx(a)):null},we.Jx=function(a){return a===void 0&&(a={}),Bf(this,this.Xz,a)},we.Xz=function(a,y,x){var E=lm(x,a,"canvas",null);if(E===null)return null;x=E.Z.canvas;var b=null;if(x!==null)switch(b=a.returnType,b===void 0?b="string":b=b.toLowerCase(),b){case gf+"data":b=E.getImageData(0,0,x.width,x.height);break;case gf:E=(a.document||document).createElement("img"),E.src=x.toDataURL(a.type,a.details),b=E;break;case"blob":return typeof y!="function"&&Dt('Error: Diagram.makeImageData called with "returnType: toBlob", but no required "callback" function property defined.'),typeof x.toBlob=="function"?(x.toBlob(y,a.type,a.details),"toBlob"):(y(null),null);default:b=x.toDataURL(a.type,a.details)}return typeof y=="function"?(y(b),null):b};function lm(a,y,x,E){if(a.animationManager.Cc(),a.bd(),a.ta===null)return null;typeof y!="object"&&Dt("properties argument must be an Object.");var b=y.size||null,z=y.scale||null;y.scale!==void 0&&isNaN(y.scale)&&(z="NaN");var ee=y.maxSize;y.maxSize===void 0&&(ee=x==="SVG"?new fn(1/0,1/0):new fn(2e3,2e3));var re=y.position||null,oe=y.parts||null,se=y.padding===void 0?1:y.padding,ue=y.background||null,fe=y.omitTemporary;fe===void 0&&(fe=!0);var ve=y.document||document,ye=y.elementFinished||null,Ce=y.showTemporary;Ce===void 0&&(Ce=!fe),y=y.showGrid,y===void 0&&(y=Ce),b!==null&&isNaN(b.width)&&isNaN(b.height)&&(b=null),typeof se=="number"?se=new vr(se):se instanceof vr||Dt("MakeImage padding must be a Margin or a number."),se.left=Math.max(se.left,0),se.right=Math.max(se.right,0),se.top=Math.max(se.top,0),se.bottom=Math.max(se.bottom,0),a.ib.Vc(!0),fe=new Zh(null,ve,void 0,!0);var Ae=fe.context;if(!(b||z||oe||re))return fe.width=a.Aa+Math.ceil(se.left+se.right),fe.height=a.ya+Math.ceil(se.top+se.bottom),x==="SVG"?E===null?null:(E.resize(fe.width,fe.height,fe.width,fe.height),E.ownerDocument=ve,E.hs=ye,eh(a,E.context,se,new fn(fe.width,fe.height),a.Ca,a.pa,oe,ue,Ce,y),E.context):(a.Xm=!1,eh(a,Ae,se,new fn(fe.width,fe.height),a.Ca,a.pa,oe,ue,Ce,y),a.Xm=!0,fe.context);var Ye=a.Pp,We=a.documentBounds.copy();if(We.Fv(a.yb),Ce)for(var tt=a.Wa.s,rt=tt.length,at=0;at<rt;at++){var gt=tt[at];if(gt.visible&&gt.isTemporary){gt=gt.Pa.s;for(var At=gt.length,Zn=0;Zn<At;Zn++){var mi=gt[Zn];mi.isInDocumentBounds&&mi.isVisible()&&(mi=mi.actualBounds,mi.w()&&We.ed(mi))}}}if(tt=new Qe(We.x,We.y),oe!==null){for(rt=new Xt(0,0,0,0),at=!0,gt=oe.iterator,gt.reset();gt.next();)At=gt.value,At instanceof Ii&&(Zn=At.layer,Zn!==null&&!Zn.visible||Zn!==null&&!Ce&&Zn.isTemporary||!At.isVisible()||(At=At.actualBounds,At.w()&&(at?(at=!1,rt.assign(At)):rt.ed(At))));We.width=rt.width,We.height=rt.height,tt.x=rt.x,tt.y=rt.y}return re!==null&&re.w()&&(tt=re,z||(z=Ye)),rt=re=0,se!==null&&(re=se.left+se.right,rt=se.top+se.bottom),at=gt=0,b!==null&&(gt=b.width,at=b.height,isFinite(gt)&&(gt=Math.max(0,gt-re)),isFinite(at)&&(at=Math.max(0,at-rt))),b!==null&&z!==null?(z==="NaN"&&(z=Ye),b.w()?(b=gt,We=at):isNaN(at)?(b=gt,We=We.height*z):(b=We.width*z,We=at)):b!==null?b.w()?(z=Math.min(gt/We.width,at/We.height),b=gt,We=at):isNaN(at)?(z=gt/We.width,b=gt,We=We.height*z):(z=at/We.height,b=We.width*z,We=at):z!==null?z==="NaN"&&ee.w()?(z=Math.min((ee.width-re)/We.width,(ee.height-rt)/We.height),z>Ye?(z=Ye,b=We.width,We=We.height):(b=ee.width,We=ee.height)):(b=We.width*z,We=We.height*z):(z=Ye,b=We.width,We=We.height),se!==null?(b+=re,We+=rt):se=new vr(0),ee!==null&&(Ye=ee.width,ee=ee.height,isNaN(Ye)&&(Ye=2e3),isNaN(ee)&&(ee=2e3),isFinite(Ye)&&(b=Math.min(b,Ye)),isFinite(ee)&&(We=Math.min(We,ee))),fe.width=Math.ceil(b),fe.height=Math.ceil(We),x==="SVG"?E===null?null:(E.resize(fe.width,fe.height,fe.width,fe.height),E.ownerDocument=ve,E.hs=ye,eh(a,E.context,se,new fn(Math.ceil(b),Math.ceil(We)),z,tt,oe,ue,Ce,y),E.context):(a.Xm=!1,eh(a,Ae,se,new fn(Math.ceil(b),Math.ceil(We)),z,tt,oe,ue,Ce,y),a.Xm=!0,fe.context)}Yt.Object.defineProperties(bt.prototype,{renderer:{get:function(){return this.nl},set:function(a){this instanceof ge||(a===""&&(a="default"),a=a.toLowerCase(),a!==this.nl&&(this.nl=a,a==="default"||a==="canvas"?(a=this.pj.get("svg"),a!==null&&a.Oa.remove(),this.ta&&(this.ib=this.ta.context)):a==="svg"?(this.pj.contains("svg")?a=this.pj.get("svg"):(a=new Fc(this,Kt.document),this.bs("svg",a)),this.div!==null&&this.div.appendChild(a.Oa),this.ib=a.context,this.ta&&(this.ta.context.setTransform(this.Mb,0,0,this.Mb,0,0),this.ta.context.clearRect(0,0,this.Aa,this.ya))):a!=="debug"||this.pj.contains("SVG")||(a=new Fc(this,Kt.document),this.bs("SVG",a),a.Oa.style.backgroundColor="whitesmoke",this.div!==null&&this.div.after(a.Oa)),this.hk()))}},div:{get:function(){return this.Ka},set:function(a){if(this.Ka!==a){var y=this.Ka;y!==null?(y.H=void 0,y.goDiagram=void 0,y.go=void 0,y.innerHTML="",this.ta!==null&&(y=this.ta.Oa,this.removeEventListener(y,"pointermove",this.dk,!1),this.removeEventListener(y,"pointerdown",this.ui,!1),this.removeEventListener(y,"pointerup",this.fk,!1),this.removeEventListener(y,"pointerout",this.ek,!1),this.removeEventListener(y,"pointercancel",this.ck,!1),this.ta.mx()),this.ol&&(this.ol.disconnect(),this.ol=null),y=this.toolManager,y!==null&&(y.mouseDownTools.each(function(x){x.cancelWaitAfter()}),y.mouseMoveTools.each(function(x){x.cancelWaitAfter()}),y.mouseUpTools.each(function(x){x.cancelWaitAfter()})),y.cancelWaitAfter(),this.currentTool.doCancel(),this.ta=null,this.removeEventListener(Kt,"resize",this.Ov,!1),this.removeEventListener(Kt,"wheel",this.$j,!0),zo===this&&(zo=null)):this.ui===null&&(this.hf=!1),this.Ka=null,a!==null&&((y=a.H)&&(y.div=null),Hi(this,a),this.hk())}}},$w:{get:function(){return this.Sq}},pi:{get:function(){return this.hf}},draggedLink:{get:function(){return this.nt},set:function(a){this.nt!==a&&(this.nt=a,a!==null&&(this.Vt=a.fromPort,this.Wt=a.toPort))}},Mx:{get:function(){return this.Vt},set:function(a){this.Vt=a}},Nx:{get:function(){return this.Wt},set:function(a){this.Wt=a}},animationManager:{get:function(){return this.Yd}},undoManager:{get:function(){return this.cc.undoManager}},skipsUndoManager:{get:function(){return this.Wg},set:function(a){this.Wg=a,this.cc.skipsUndoManager=a}},delaysLayout:{get:function(){return this.lt},set:function(a){this.lt=a}},opacity:{get:function(){return this.pb},set:function(a){var y=this.pb;y!==a&&((0>a||1<a)&&gr(a,"0 <= value <= 1",bt,"opacity"),this.pb=a,this.g("opacity",y,a),this.N())}},validCycle:{get:function(){return this.wu},set:function(a){var y=this.wu;y!==a&&(this.wu=a,this.g("validCycle",y,a))}},layers:{get:function(){return this.Wa.iterator}},isModelReadOnly:{get:function(){var a=this.cc;return a===null?!1:a.isReadOnly},set:function(a){var y=this.cc;y!==null&&(y.isReadOnly=a)}},isReadOnly:{get:function(){return this.Gg},set:function(a){var y=this.Gg;y!==a&&(this.Gg=a,this.g("isReadOnly",y,a))}},isEnabled:{get:function(){return this.Jd},set:function(a){var y=this.Jd;y!==a&&(this.Jd=a,this.g("isEnabled",y,a))}},allowClipboard:{get:function(){return this.Us},set:function(a){var y=this.Us;y!==a&&(this.Us=a,this.g("allowClipboard",y,a))}},allowCopy:{get:function(){return this.Fi},set:function(a){var y=this.Fi;y!==a&&(this.Fi=a,this.g("allowCopy",y,a))}},allowDelete:{get:function(){return this.Gi},set:function(a){var y=this.Gi;y!==a&&(this.Gi=a,this.g("allowDelete",y,a))}},allowDragOut:{get:function(){return this.Vs},set:function(a){var y=this.Vs;y!==a&&(this.Vs=a,this.g("allowDragOut",y,a))}},allowDrop:{get:function(){return this.Ws},set:function(a){var y=this.Ws;y!==a&&(this.Ws=a,this.g("allowDrop",y,a))}},allowTextEdit:{get:function(){return this.Pi},set:function(a){var y=this.Pi;y!==a&&(this.Pi=a,this.g("allowTextEdit",y,a))}},allowGroup:{get:function(){return this.Hi},set:function(a){var y=this.Hi;y!==a&&(this.Hi=a,this.g("allowGroup",y,a))}},allowUngroup:{get:function(){return this.Qi},set:function(a){var y=this.Qi;y!==a&&(this.Qi=a,this.g("allowUngroup",y,a))}},allowInsert:{get:function(){return this.Ys},set:function(a){var y=this.Ys;y!==a&&(this.Ys=a,this.g("allowInsert",y,a))}},allowLink:{get:function(){return this.Ii},set:function(a){var y=this.Ii;y!==a&&(this.Ii=a,this.g("allowLink",y,a))}},allowRelink:{get:function(){return this.Ki},set:function(a){var y=this.Ki;y!==a&&(this.Ki=a,this.g("allowRelink",y,a))}},allowMove:{get:function(){return this.Ji},set:function(a){var y=this.Ji;y!==a&&(this.Ji=a,this.g("allowMove",y,a))}},allowReshape:{get:function(){return this.Li},set:function(a){var y=this.Li;y!==a&&(this.Li=a,this.g("allowReshape",y,a))}},allowResize:{get:function(){return this.Mi},set:function(a){var y=this.Mi;y!==a&&(this.Mi=a,this.g("allowResize",y,a))}},allowRotate:{get:function(){return this.Ni},set:function(a){var y=this.Ni;y!==a&&(this.Ni=a,this.g("allowRotate",y,a))}},allowSelect:{get:function(){return this.Oi},set:function(a){var y=this.Oi;y!==a&&(this.Oi=a,this.g("allowSelect",y,a))}},allowUndo:{get:function(){return this.Zs},set:function(a){var y=this.Zs;y!==a&&(this.Zs=a,this.g("allowUndo",y,a))}},allowZoom:{get:function(){return this.at},set:function(a){var y=this.at;y!==a&&(this.at=a,this.g("allowZoom",y,a))}},hasVerticalScrollbar:{get:function(){return this.nn},set:function(a){var y=this.nn;y!==a&&(this.nn=a,this.Ee=!0,this.N(),this.g("hasVerticalScrollbar",y,a),Aa(this,!1))}},hasHorizontalScrollbar:{get:function(){return this.mn},set:function(a){var y=this.mn;y!==a&&(this.mn=a,this.Ee=!0,this.N(),this.g("hasHorizontalScrollbar",y,a),Aa(this,!1))}},allowHorizontalScroll:{get:function(){return this.Xs},set:function(a){var y=this.Xs;y!==a&&(this.Xs=a,this.g("allowHorizontalScroll",y,a),Aa(this,!1))}},allowVerticalScroll:{get:function(){return this.$s},set:function(a){var y=this.$s;y!==a&&(this.$s=a,this.g("allowVerticalScroll",y,a),Aa(this,!1))}},scrollHorizontalLineChange:{get:function(){return this.iu},set:function(a){var y=this.iu;y!==a&&(0>a&&gr(a,">= 0",bt,"scrollHorizontalLineChange"),this.iu=a,this.g("scrollHorizontalLineChange",y,a))}},scrollVerticalLineChange:{get:function(){return this.mu},set:function(a){var y=this.mu;y!==a&&(0>a&&gr(a,">= 0",bt,"scrollVerticalLineChange"),this.mu=a,this.g("scrollVerticalLineChange",y,a))}},lastInput:{get:function(){return this.cj},set:function(a){this.cj=a}},previousInput:{get:function(){return this.Qg},set:function(a){this.Qg=a}},firstInput:{get:function(){return this.bq},set:function(a){this.bq=a}},currentCursor:{get:function(){return this.it},set:function(a){if(a===""&&(a=this.Op),this.it!==a){var y=this.ta,x=this.Ka;if(y!==null&&x!==null){this.it=a;var E=y.style.cursor;y.style.cursor=a,x.style.cursor=a,y.style.cursor===E&&(y.style.cursor="-webkit-"+a,x.style.cursor="-webkit-"+a,y.style.cursor===E&&(y.style.cursor="-moz-"+a,x.style.cursor="-moz-"+a,y.style.cursor===E&&(y.style.cursor=a,x.style.cursor=a)))}}}},defaultCursor:{get:function(){return this.Op},set:function(a){a===""&&(a="auto");var y=this.Op;y!==a&&(this.Op=a,this.g("defaultCursor",y,a))}},click:{get:function(){return this.zh},set:function(a){var y=this.zh;y!==a&&(this.zh=a,this.g("click",y,a))}},doubleClick:{get:function(){return this.Fh},set:function(a){var y=this.Fh;y!==a&&(this.Fh=a,this.g("doubleClick",y,a))}},contextClick:{get:function(){return this.Bh},set:function(a){var y=this.Bh;y!==a&&(this.Bh=a,this.g("contextClick",y,a))}},mouseOver:{get:function(){return this.Qh},set:function(a){var y=this.Qh;y!==a&&(this.Qh=a,this.g("mouseOver",y,a))}},mouseHover:{get:function(){return this.Oh},set:function(a){var y=this.Oh;y!==a&&(this.Oh=a,this.g("mouseHover",y,a))}},mouseHold:{get:function(){return this.Nh},set:function(a){var y=this.Nh;y!==a&&(this.Nh=a,this.g("mouseHold",y,a))}},mouseDragOver:{get:function(){return this.Qt},set:function(a){var y=this.Qt;y!==a&&(this.Qt=a,this.g("mouseDragOver",y,a))}},mouseDrop:{get:function(){return this.Lh},set:function(a){var y=this.Lh;y!==a&&(this.Lh=a,this.g("mouseDrop",y,a))}},handlesDragDropForTopLevelParts:{get:function(){return this.xt},set:function(a){var y=this.xt;y!==a&&(this.xt=a,this.g("handlesDragDropForTopLevelParts",y,a))}},mouseEnter:{get:function(){return this.Mh},set:function(a){var y=this.Mh;y!==a&&(this.Mh=a,this.g("mouseEnter",y,a))}},mouseLeave:{get:function(){return this.Ph},set:function(a){var y=this.Ph;y!==a&&(this.Ph=a,this.g("mouseLeave",y,a))}},toolTip:{get:function(){return this.$h},set:function(a){var y=this.$h;y!==a&&(this.$h=a,this.g("toolTip",y,a))}},contextMenu:{get:function(){return this.Ch},set:function(a){var y=this.Ch;y!==a&&(this.Ch=a,this.g("contextMenu",y,a))}},commandHandler:{get:function(){return this.nb},set:function(a){this.nb!==a&&(this.nb=a,a.Xe(this))}},toolManager:{get:function(){return this.te},set:function(a){this.te!==a&&(this.te=a,a.diagram=this)}},defaultTool:{get:function(){return this.ob},set:function(a){var y=this.ob;y!==a&&(this.ob=a,a.diagram=this,this.currentTool===y&&(this.currentTool=a))}},currentTool:{get:function(){return this.hb},set:function(a){var y=this.hb;y&&(y.isActive&&y.doDeactivate(),y.cancelWaitAfter(),y.doStop()),a===null&&(a=this.defaultTool),a!==null&&(this.hb=a,a.diagram=this,a.doStart())}},selection:{get:function(){return this.Hw}},maxSelectionCount:{get:function(){return this.Nt},set:function(a){var y=this.Nt;if(y!==a)if(0<=a&&!isNaN(a)){if(this.Nt=a,this.g("maxSelectionCount",y,a),!this.undoManager.isUndoingRedoing&&(a=this.selection.count-a,0<a)){this.R("ChangingSelection",this.selection),y=this.selection.Fa();for(var x=0;x<a;x++)y[x].isSelected=!1;this.R("ChangedSelection",this.selection)}}else gr(a,">= 0",bt,"maxSelectionCount")}},nodeSelectionAdornmentTemplate:{get:function(){return this.St},set:function(a){var y=this.St;y!==a&&(this.St=a,this.g("nodeSelectionAdornmentTemplate",y,a))}},groupSelectionAdornmentTemplate:{get:function(){return this.wt},set:function(a){var y=this.wt;y!==a&&(this.wt=a,this.g("groupSelectionAdornmentTemplate",y,a))}},linkSelectionAdornmentTemplate:{get:function(){return this.Kt},set:function(a){var y=this.Kt;y!==a&&(this.Kt=a,this.g("linkSelectionAdornmentTemplate",y,a))}},highlighteds:{get:function(){return this.nw}},isModified:{get:function(){var a=this.undoManager;return a.isEnabled?a.currentTransaction!==null?!0:this.rn&&this.Ce!==a.historyIndex:this.rn},set:function(a){if(this.rn!==a){this.rn=a;var y=this.undoManager;!a&&y.isEnabled&&(this.Ce=y.historyIndex),a||dl(this)}}},model:{get:function(){return this.cc},set:function(a){var y=this.cc;if(y!==a){this.currentTool.doCancel(),y&&y.undoManager!==a.undoManager&&y.undoManager.isInTransaction&&Dt("Do not replace a Diagram.model while a transaction is in progress."),this.animationManager.Cc(!0);var x=js(this,!0);this.hf=!1,this.fn=!0,this.Ce=-2,this.kg=!1;var E=this.vb;this.vb=!0,Uo(this.animationManager,"Model"),y&&(this.pf!==null&&this.pf.each(function(z){return y.ik(z)}),y.ik(this.Oc)),this.cc=a,this.partManager=Sl(this.cc.type);for(var b=0;b<x.length;b++)this.add(x[b]);a.Pe(this.Hb),this.partManager.addAllModeledParts(),a.ik(this.Hb),a.Pe(this.Oc),this.pf!==null&&this.pf.each(function(z){return a.Pe(z)}),this.vb=E,this.Ya(),this.vb||this.N(),y&&a.undoManager.copyProperties(y.undoManager)}}},aa:{get:function(){return this.rw},set:function(a){this.rw=a}},As:{get:function(){return this.sy}},skipsModelSourceBindings:{get:function(){return this.Iw},set:function(a){this.Iw=a}},Ns:{get:function(){return this.ou},set:function(a){this.ou=a}},nodeTemplate:{get:function(){return this.Lg.I("")},set:function(a){var y=this.Lg.I("");y!==a&&(this.Lg.add("",a),this.g("nodeTemplate",y,a),this.undoManager.isUndoingRedoing||this.Wd())}},nodeTemplateMap:{get:function(){return this.Lg},set:function(a){var y=this.Lg;y!==a&&(this.Lg=a,this.g("nodeTemplateMap",y,a),this.undoManager.isUndoingRedoing||this.Wd())}},groupTemplate:{get:function(){return this.Yi.I("")},set:function(a){var y=this.Yi.I("");y!==a&&(this.Yi.add("",a),this.g("groupTemplate",y,a),this.undoManager.isUndoingRedoing||this.Wd())}},groupTemplateMap:{get:function(){return this.Yi},set:function(a){var y=this.Yi;y!==a&&(this.Yi=a,this.g("groupTemplateMap",y,a),this.undoManager.isUndoingRedoing||this.Wd())}},linkTemplate:{get:function(){return this.Kh.I("")},set:function(a){var y=this.Kh.I("");y!==a&&(this.Kh.add("",a),this.g("linkTemplate",y,a),this.undoManager.isUndoingRedoing||this.Wd())}},linkTemplateMap:{get:function(){return this.Kh},set:function(a){var y=this.Kh;y!==a&&(this.Kh=a,this.g("linkTemplateMap",y,a),this.undoManager.isUndoingRedoing||this.Wd())}},isMouseCaptured:{get:function(){return this.qw},set:function(a){var y=this.ta;y!==null&&(y=y.Oa,y instanceof SVGElement||(a?(this.lastInput.bubbles=!1,this.removeEventListener(y,"pointermove",this.dk,!1),this.removeEventListener(y,"pointerdown",this.ui,!1),this.removeEventListener(y,"pointerup",this.fk,!1),this.removeEventListener(y,"pointerout",this.ek,!1),this.removeEventListener(y,"pointercancel",this.ck,!1),this.addEventListener(Kt,"pointermove",this.dk,!0),this.addEventListener(Kt,"pointerdown",this.ui,!0),this.addEventListener(Kt,"pointerup",this.fk,!0),this.addEventListener(Kt,"pointerout",this.ek,!0),this.addEventListener(Kt,"pointercancel",this.ck,!0),this.removeEventListener(y,"wheel",this.$j,!1),this.addEventListener(Kt,"wheel",this.$j,!0),this.addEventListener(Kt,"selectstart",this.preventDefault,!1)):(this.removeEventListener(Kt,"pointermove",this.dk,!0),this.removeEventListener(Kt,"pointerdown",this.ui,!0),this.removeEventListener(Kt,"pointerup",this.fk,!0),this.removeEventListener(Kt,"pointerout",this.ek,!0),this.removeEventListener(Kt,"pointercancel",this.ck,!0),this.addEventListener(y,"pointermove",this.dk,!1),this.addEventListener(y,"pointerdown",this.ui,!1),this.addEventListener(y,"pointerup",this.fk,!1),this.addEventListener(y,"pointerout",this.ek,!1),this.addEventListener(y,"pointercancel",this.ck,!1),this.removeEventListener(Kt,"wheel",this.$j,!0),this.removeEventListener(Kt,"selectstart",this.preventDefault,!1),this.addEventListener(y,"wheel",this.$j,!1)),this.qw=a))}},position:{get:function(){return this.pa},set:function(a){var y=Qe.alloc().assign(this.pa);if(!y.D(a)){var x=this.viewportBounds.copy();this.pa.assign(a),ir(this.animationManager,y,this.pa),this.vb||this.ta===null&&!this.wo.w()?Ku(this):(this.vb=!0,a=this.scale,Yl(this,this.Sp,this.Aa/a,this.ya/a,this.zk,!1),this.vb=!1),this.vb||this.onViewportBoundsChanged(x,this.viewportBounds,this.Ca,!1)}Qe.free(y)}},initialPosition:{get:function(){return this.zt},set:function(a){this.zt.D(a)||(this.zt=a.J())}},initialScale:{get:function(){return this.At},set:function(a){this.At!==a&&(this.At=a)}},grid:{get:function(){return this.fe===null&&(this.fe=Qo(this)),this.fe},set:function(a){var y=this.fe;if(y!==a){y===null&&(y=this.fe=Qo(this)),a.type!==Ln.Grid&&Dt("Diagram.grid must be a Panel of type Panel.Grid");var x=y.panel;x!==null&&x.remove(y),this.fe=a,a.name="GRID",x!==null&&x.add(a),zs(this),this.N(),this.g("grid",y,a)}}},viewportBounds:{get:function(){return this.Rw}},viewSize:{get:function(){return this.wo},set:function(a){var y=this.viewSize;y.D(a)||(this.wo=a=a.J(),this.ya=this.Aa=0,a.w()?(this.Aa=a.width,this.ya=a.height):this.Ka!==null&&(this.Aa=this.Ka.clientWidth||1,this.ya=this.Ka.clientHeight||1),Ku(this),this.Ya(),this.g("viewSize",y,a),this.redraw())}},fixedBounds:{get:function(){return this.ut},set:function(a){var y=this.ut;y.D(a)||(a.width!==-1/0&&a.height!==1/0&&a.height!==-1/0||Dt("fixedBounds width/height must not be Infinity"),this.ut=a=a.J(),this.Ya(),this.g("fixedBounds",y,a))}},scrollMargin:{get:function(){return this.rj},set:function(a){typeof a=="number"&&(a=new vr(a));var y=this.rj;y.D(a)||(this.rj=a=a.J(),this.g("scrollMargin",y,a),this.hk())}},scrollMode:{get:function(){return this.sj},set:function(a){var y=this.sj;y!==a&&(this.sj=a,a===vd&&Aa(this,!1),this.g("scrollMode",y,a),this.Ee=!0,this.N())}},scrollsPageOnFocus:{get:function(){return this.nu},set:function(a){var y=this.nu;y!==a&&(this.nu=a,this.g("scrollsPageOnFocus",y,a))}},positionComputation:{get:function(){return this.Zt},set:function(a){var y=this.Zt;y!==a&&(this.Zt=a,Aa(this,!1),this.g("positionComputation",y,a))}},scaleComputation:{get:function(){return this.fu},set:function(a){var y=this.fu;y!==a&&(this.fu=a,cl(this,this.scale,this.scale),this.g("scaleComputation",y,a))}},documentBounds:{get:function(){return this.Sp}},isVirtualized:{get:function(){return this.It},set:function(a){var y=this.It;y!==a&&(this.It=a,this.g("isVirtualized",y,a))}},scale:{get:function(){return this.Ca},set:function(a){var y=this.Ca;y!==a&&cl(this,y,a)}},defaultScale:{get:function(){return this.Pp},set:function(a){this.Pp=a}},autoScale:{get:function(){return this.yh},set:function(a){var y=this.yh;y!==a&&(this.yh=a,this.g("autoScale",y,a),a!==lu&&Aa(this,!1))}},initialAutoScale:{get:function(){return this.Fg},set:function(a){var y=this.Fg;y!==a&&(this.Fg=a,this.g("initialAutoScale",y,a))}},initialViewportSpot:{get:function(){return this.Bt},set:function(a){var y=this.Bt;y!==a&&(a.sb()||Dt("initialViewportSpot must be a specific Spot: "+a),this.Bt=a,this.g("initialViewportSpot",y,a))}},initialDocumentSpot:{get:function(){return this.yt},set:function(a){var y=this.yt;y!==a&&(a.sb()||Dt("initialViewportSpot must be a specific Spot: "+a),this.yt=a,this.g("initialDocumentSpot",y,a))}},minScale:{get:function(){return this.Ot},set:function(a){var y=this.Ot;y!==a&&(0<a?(this.Ot=a,this.g("minScale",y,a),a>this.scale&&(this.scale=a)):gr(a,"> 0",bt,"minScale"))}},maxScale:{get:function(){return this.Mt},set:function(a){var y=this.Mt;y!==a&&(0<a?(this.Mt=a,this.g("maxScale",y,a),a<this.scale&&(this.scale=a)):gr(a,"> 0",bt,"maxScale"))}},zoomPoint:{get:function(){return this.zu},set:function(a){this.zu.D(a)||(this.zu=a=a.J())}},contentAlignment:{get:function(){return this.zk},set:function(a){var y=this.zk;y.D(a)||(this.zk=a=a.J(),this.g("contentAlignment",y,a),Aa(this,!1))}},initialContentAlignment:{get:function(){return this.pq},set:function(a){var y=this.pq;y.D(a)||(this.pq=a=a.J(),this.g("initialContentAlignment",y,a))}},padding:{get:function(){return this.yb},set:function(a){typeof a=="number"&&(a=new vr(a));var y=this.yb;y.D(a)||(this.yb=a=a.J(),this.Ya(),this.g("padding",y,a))}},partManager:{get:function(){return this.Pc},set:function(a){var y=this.Pc;y!==a&&(a.diagram!==null&&Dt("Cannot share PartManagers between Diagrams: "+a.toString()),y&&y.Xe(null),this.Pc=a,a.Xe(this))}},nodes:{get:function(){return this.partManager.nodes.iterator}},links:{get:function(){return this.partManager.links.iterator}},parts:{get:function(){return this.partManager.parts.iterator}},layout:{get:function(){return this.Sc},set:function(a){var y=this.Sc;y!==a&&(this.Sc=a,a.diagram=this,a.group=null,this.xh=!0,this.g("layout",y,a),this.$b())}},isTreePathToChildren:{get:function(){return this.Ht},set:function(a){var y=this.Ht;if(y!==a&&(this.Ht=a,this.g("isTreePathToChildren",y,a),!this.undoManager.isUndoingRedoing))for(a=this.nodes;a.next();)xp(a.value)}},treeCollapsePolicy:{get:function(){return this.uu},set:function(a){var y=this.uu;y!==a&&(a!==yd&&a!==_s&&a!==fg&&Dt("Unknown Diagram.treeCollapsePolicy: "+a),this.uu=a,this.g("treeCollapsePolicy",y,a))}},Ue:{get:function(){return this.pw},set:function(a){this.pw=a}},avoidanceCellSize:{get:function(){return this.aw},set:function(a){this.Xh=null,this.aw=new fn(Math.max(1,a.width),Math.max(1,a.height))}},avoidanceLimit:{get:function(){return this.bw},set:function(a){this.bw=Math.max(1,a)}},autoScrollInterval:{get:function(){return this.vp},set:function(a){var y=this.vp;y!==a&&(this.vp=a,this.g("autoScrollInterval",y,a))}},autoScrollRegion:{get:function(){return this.xp},set:function(a){typeof a=="number"&&(a=new vr(a));var y=this.xp;y.D(a)||(this.xp=a=a.J(),this.Ya(),this.g("autoScrollRegion",y,a))}}}),Yt.Object.defineProperties(bt,{licenseKey:{get:function(){return lp.jc()},set:function(a){lp.add(a.replace(/\s/g,""))}},version:{get:function(){return ff}}}),bt.prototype.makeImageData=bt.prototype.Jx,bt.prototype.makeImage=bt.prototype.Wz,bt.prototype.cacheGroupExternalLinks=bt.prototype.Fu,bt.prototype.addRenderer=bt.prototype.bs,bt.prototype.makeSVG=bt.prototype.av,bt.prototype.makeSvg=bt.prototype.Cs,bt.prototype.stopAutoScroll=bt.prototype.ug,bt.prototype.doAutoScroll=bt.prototype.gs,bt.prototype.isUnoccupied=bt.prototype.Yj,bt.prototype.raiseDiagramEvent=bt.prototype.R,bt.prototype.removeDiagramListener=bt.prototype.am,bt.prototype.addDiagramListener=bt.prototype.Bj,bt.prototype.findTreeRoots=bt.prototype.yz,bt.prototype.layoutDiagram=bt.prototype.Uz,bt.prototype.findTopLevelGroups=bt.prototype.qz,bt.prototype.findTopLevelNodesAndLinks=bt.prototype.rz,bt.prototype.ensureBounds=bt.prototype.Va,bt.prototype.findLinksByExample=bt.prototype.ls,bt.prototype.findNodesByExample=bt.prototype.ms,bt.prototype.findLinkForData=bt.prototype.Kc,bt.prototype.findNodeForData=bt.prototype.ii,bt.prototype.findPartForData=bt.prototype.Lc,bt.prototype.findLinkForKey=bt.prototype.findLinkForKey,bt.prototype.findNodeForKey=bt.prototype.Vb,bt.prototype.findPartForKey=bt.prototype.findPartForKey,bt.prototype.rebuildParts=bt.prototype.Wd,bt.prototype.transformViewToDoc=bt.prototype.Ps,bt.prototype.transformRectDocToView=bt.prototype.zA,bt.prototype.transformDocToView=bt.prototype.op,bt.prototype.centerRect=bt.prototype.es,bt.prototype.scrollToRect=bt.prototype.tv,bt.prototype.scroll=bt.prototype.scroll,bt.prototype.highlightCollection=bt.prototype.Jz,bt.prototype.highlight=bt.prototype.Iz,bt.prototype.selectCollection=bt.prototype.rA,bt.prototype.select=bt.prototype.select,bt.prototype.updateAllRelationshipsFromData=bt.prototype.rp,bt.prototype.updateAllTargetBindings=bt.prototype.updateAllTargetBindings,bt.prototype.commit=bt.prototype.commit,bt.prototype.rollbackTransaction=bt.prototype.Kf,bt.prototype.commitTransaction=bt.prototype.eb,bt.prototype.startTransaction=bt.prototype.Ea,bt.prototype.raiseChanged=bt.prototype.g,bt.prototype.raiseChangedEvent=bt.prototype.cb,bt.prototype.removeChangedListener=bt.prototype.ik,bt.prototype.addChangedListener=bt.prototype.Pe,bt.prototype.removeModelChangedListener=bt.prototype.mA,bt.prototype.addModelChangedListener=bt.prototype.Yw,bt.prototype.findLayer=bt.prototype.Qj,bt.prototype.removeLayer=bt.prototype.kA,bt.prototype.addLayerAfter=bt.prototype.Cy,bt.prototype.addLayerBefore=bt.prototype.Ww,bt.prototype.addLayer=bt.prototype.Al,bt.prototype.moveParts=bt.prototype.moveParts,bt.prototype.copyParts=bt.prototype.Kj,bt.prototype.removeParts=bt.prototype.Is,bt.prototype.remove=bt.prototype.remove,bt.prototype.add=bt.prototype.add,bt.prototype.clearDelayedGeometries=bt.prototype.bx,bt.prototype.setProperties=bt.prototype.nm,bt.prototype.attach=bt.prototype.Du,bt.prototype.set=bt.prototype.set,bt.prototype.resetInputOptions=bt.prototype.Sx,bt.prototype.setInputOption=bt.prototype.sA,bt.prototype.getInputOption=bt.prototype.Ql,bt.prototype.resetRenderingHints=bt.prototype.Tx,bt.prototype.setRenderingHint=bt.prototype.Xx,bt.prototype.getRenderingHint=bt.prototype.Gf,bt.prototype.maybeUpdate=bt.prototype.bd,bt.prototype.requestUpdate=bt.prototype.$b,bt.prototype.delayInitialization=bt.prototype.Xy,bt.prototype.isUpdateRequested=bt.prototype.Pz,bt.prototype.invalidateDocumentBounds=bt.prototype.Ya,bt.prototype.findObjectsNear=bt.prototype.og,bt.prototype.findPartsNear=bt.prototype.mz,bt.prototype.findObjectsIn=bt.prototype.Cf,bt.prototype.findPartsIn=bt.prototype.ux,bt.prototype.findObjectsAt=bt.prototype.ji,bt.prototype.findPartsAt=bt.prototype.lz,bt.prototype.findObjectAt=bt.prototype.ic,bt.prototype.findPartAt=bt.prototype.Ol,bt.prototype.focusObject=bt.prototype.zz,bt.prototype.alignDocument=bt.prototype.Jy,bt.prototype.zoomToRect=bt.prototype.BA,bt.prototype.zoomToFit=bt.prototype.zoomToFit,bt.prototype.diagramScroll=bt.prototype.kx,bt.prototype.focus=bt.prototype.focus;var dg=new Li,um=null,Es=Kt.document!==void 0,df=null,Gd="",lu=new Vt(bt,"None",0),fh=new Vt(bt,"Uniform",1),Kd=new Vt(bt,"UniformToFill",2),Of=new Vt(bt,"CycleAll",10),ip=new Vt(bt,"CycleNotDirected",11),rp=new Vt(bt,"CycleNotDirectedFast",12),op=new Vt(bt,"CycleNotUndirected",13),ap=new Vt(bt,"CycleDestinationTree",14),sp=new Vt(bt,"CycleSourceTree",15),vd=new Vt(bt,"DocumentScroll",1),Rf=new Vt(bt,"InfiniteScroll",2),yd=new Vt(bt,"TreeParentCollapsed",21),_s=new Vt(bt,"AllParentsCollapsed",22),fg=new Vt(bt,"AnyParentsCollapsed",23),lp=new An,ff="2.3.10",gf="image",If=null,hm=!1;function Ql(){if(Es){var a=Kt.document.createElement("canvas"),y=a.getContext("2d"),x=Lr("7ca11abfd022028846");y[x]=Lr("398c3597c01238");for(var E=["5da73c80a36455d7038e4972187c3cae51fd22",wn.Dx+"4ae6247590da4bb21c324ba3a84e385776",kr.xF+"fb236cdfda5de14c134ba1a95a2d4c7cc6f93c1387",yt.za],b=1;5>b;b++)y[Lr("7ca11abfd7330390")](Lr(E[b-1]),10,15*b);for(y[x]=Lr("39f046ebb36e4b"),x=1;5>x;x++)y[Lr("7ca11abfd7330390")](Lr(E[x-1]),10,15*x);(E.length!==4||E[0][0]!=="5"||E[3][0]!=="7")&&(kr.prototype.Cd=kr.prototype.Eu),If=a}}bt.className="Diagram",bt.fromDiv=function(a){var y=a;return typeof a=="string"&&(y=Kt.document.getElementById(a)),y instanceof HTMLDivElement&&y.H instanceof bt?y.H:null},bt.inherit=function(a,y){function x(){}if(Object.getPrototypeOf(a).prototype)throw Error(`Used go.Diagram.inherit defining already defined class
`+a);x.prototype=y.prototype,a.prototype=new x,a.prototype.constructor=a},bt.useDOM=function(a){Es=a?Kt.document!==void 0:!1},bt.isUsingDOM=function(){return Es},bt.None=lu,bt.Uniform=fh,bt.UniformToFill=Kd,bt.CycleAll=Of,bt.CycleNotDirected=ip,bt.CycleNotDirectedFast=rp,bt.CycleNotUndirected=op,bt.CycleDestinationTree=ap,bt.CycleSourceTree=sp,bt.DocumentScroll=vd,bt.InfiniteScroll=Rf,bt.TreeParentCollapsed=yd,bt.AllParentsCollapsed=_s,bt.AnyParentsCollapsed=fg;function cm(){this.wy=null,this.j="zz@orderNum",this._tk==="63ad05bbe23a1786468a4c741b6d2"?this.Rc=this.j=!0:this.Rc=null}function pf(a,y){if(y.ib.setTransform(y.Mb,0,0,y.Mb,0,0),y.ib.yc(),a.Rc===null)e:{y="f";var x=Kt[Lr("76a715b2f73f148a")][Lr("72ba13b5")]||"";if(a.Rc=!0,Es){var E=bt[Lr("76a115b6ed251eaf4692")];if(E)for(var b=lp.iterator;b.next()&&(E=b.value,E=Lr(E).split(Lr("39e9")),!(6>E.length));){var z=Lr(E[1]).split(".");if(E[4]!=="7da71ca0")break;var ee=Lr(wn[Lr("6cae19")]).split(".");if(z[0]>ee[0]||z[0]===ee[0]&&z[1]>=ee[1]){var re=Kt[Lr("74a900bae4370f8b51")][Lr("6fbb13a1c2311e8a57")].toLowerCase();if(ee=re[Lr("73a612b6fb191d")](Lr("3aad1ab6e022098b4dc4")),z=Lr(E[2]),-1<ee&&(re=re[Lr("73a612b6fb191d")](z.toLowerCase()+"/"),a.Rc=!(-1<re&&re<ee),!a.Rc))break;for(ee=x[Lr("76ad18b4f73e")],re=x[Lr("73a612b6fb191d")](Lr("35e7"))+2;re<ee;re++)y+=x[re];if(ee=y[Lr("73a612b6fb191d")](z),0>ee&&z!==Lr("7da71ca0ad381e90")&&(ee=y[Lr("73a612b6fb191d")](Lr("76a715b2ef3e149757"))),0>ee&&(ee=y[Lr("73a612b6fb191d")](Lr("76a715b2ef3e149757"))),0>ee&&(ee=y[Lr("73a612b6fb191d")](Lr("2bfa41fdb3784bca12"))),0>ee&&(ee=x[Lr("73a612b6fb191d")](Lr("7baa19a6f76c1988428554"))),a.Rc=!(0<=ee&&ee<y[Lr("73a612b6fb191d")](Lr("35"))||y[Lr("73a612b6fb191d")](Lr("35"))===-1),!a.Rc||x[Lr("73a612b6fb191d")](Lr("7fb002b6ed25128b4da25b2e"))&&(a.Rc=!(-1<x[Lr("73a612b6fb191d")](z)),!a.Rc)||(ee=Kt[Lr("76a715b2f73f148a")][Lr("69ad17a1e03e")],re=ee[Lr("73a612b6fb191d")](Lr("7fb002b6ed25128b4da25b2e")),-1<re&&(a.Rc=!(ee[Lr("73a612b6fb191d")](z)>re),!a.Rc)))break;if(z[0]==="#"){ee=Kt.document.createElement("div");for(var oe=E[0].replace(/[A-Za-z]/g,"");4>oe.length;)oe+="9";if(re=oe,oe=oe.substr(oe.length-4),E="",E+=["gsh","gsf"][parseInt(oe.substr(0,1),10)%2],E+=["Header","Background","Display","Feedback"][parseInt(oe.substr(0,1),10)%4],ee[Lr("79a417a0f0181a8946")]=E,Kt.document[Lr("78a712aa")]){Kt.document[Lr("78a712aa")][Lr("7bb806b6ed32388c4a875b")](ee),oe=Kt.getComputedStyle(ee).getPropertyValue(Lr("78a704b7e62456904c9b12701b6532a8"));var se=Kt.getComputedStyle(ee).getPropertyValue(Lr("75b817b0ea2202"));if(Kt.document[Lr("78a712aa")][Lr("68ad1bbcf533388c4a875b")](ee),oe){if(ee=Kt[Lr("77a902b0eb1b1e804a8a")],se==="0."+parseInt(re,10)%100||oe.indexOf(parseInt(z[1]+z[2],16))!==-1&&oe.indexOf(parseInt(z[3]+z[4],16))!==-1){a.Rc=!1;break}else if(ee&&ee(Lr("32ae19a1e0331fc94084537c067a67fa59f1386b89d006")).matches)for(E="."+E,z=0;z<document.styleSheets.length;z++){ee=document.styleSheets[z].rules||document.styleSheets[z].cssRules;for(var ue in ee)if(E===ee[ue].selectorText){a.Rc=!1;break e}}}}else a.Rc=null,a.Rc=!1}}}else{for(ue=x[Lr("76ad18b4f73e")],b=x[Lr("73a612b6fb191d")](Lr("35e7"))+2;b<ue;b++)y+=x[b];x=y[Lr("73a612b6fb191d")](Lr("7da71ca0ad381e90")),a.Rc=!(0<=x&&x<y[Lr("73a612b6fb191d")](Lr("35")))}}}return 0<a.Rc&&a!==a.wy}cm.className="DiagramHelper";function nd(a){this.j=a===void 0?new Qe:a,this.o=new Qe}Yt.Object.defineProperties(nd.prototype,{point:{get:function(){return this.j},set:function(a){this.j=a}},shifted:{get:function(){return this.o},set:function(a){this.o=a}}});var jf="DraggingInfo";nd.className="DraggingInfo";function ie(a,y,x){this.node=a,this.info=y,this.Su=x}ie.className="DraggingNodeInfoPair";function ae(){this.reset()}ae.prototype.reset=function(){this.isGridSnapEnabled=!1,this.isGridSnapRealtime=!0,this.gridSnapCellSize=new fn(NaN,NaN).freeze(),this.gridSnapCellSpot=Cs,this.gridSnapOrigin=new Qe(NaN,NaN).freeze(),this.groupsSnapMembers=this.dragsTree=this.dragsLink=!1,this.dragsMembers=this.groupsAlwaysMove=!0},ae.className="DraggingOptions";function de(a,y){if(typeof a=="string"||Kt.Element&&a instanceof Element)var x=bt.call(this,a)||this;else x=bt.call(this)||this,y=a;return ce(x),y&&x.nm(y),x}Ct(de,bt);function ce(a){a.allowDragOut=!0,a.allowMove=!1,a.isReadOnly=!0,a.contentAlignment=_l,a.layout=new Fl}de.prototype.reset=function(){bt.prototype.reset.call(this),ce(this)},de.className="Palette";function ge(a,y){if(typeof a=="string"||Kt.Element&&a instanceof Element)var x=bt.call(this,a)||this;else x=bt.call(this)||this,y=a;var E=x;x.animationManager.isEnabled=!1,x.vb=!0,x.V=null,x.mn=!1,x.nn=!1,x.F=!0,x.u=!0,x.ia=0,x.o=!1,x.ql=null,x.Xx("drawShadows",!1),a=new Ii;var b=new Dr;return b.stroke="magenta",b.strokeWidth=2,b.fill="transparent",b.name="BOXSHAPE",a.selectable=!0,a.selectionAdorned=!1,a.selectionObjectName="BOXSHAPE",a.locationObjectName="BOXSHAPE",a.resizeObjectName="BOXSHAPE",a.cursor="move",a.add(b),x.j=a,x.allowCopy=!1,x.allowDelete=!1,x.allowSelect=!0,x.autoScrollRegion=new vr(0,0,0,0),x.pa.h(0,0),x.toolManager.gb("Dragging",new Je,x.toolManager.mouseMoveTools),x.click=function(){var z=E.observed;if(z!==null){var ee=z.viewportBounds,re=E.lastInput.documentPoint;z.position=new Qe(re.x-ee.width/2,re.y-ee.height/2)}},x.Pf=function(){E.Ya(),He(E)},x.Xd=function(){E.observed!==null&&(E.Ya(),E.N())},x.Ha=function(){1>E.updateDelay?E.N():E.o||(E.o=!0,setTimeout(function(){return E.redraw()},E.updateDelay))},x.Of=function(){E.observed!==null&&He(E)},x.autoScale=fh,x.vb=!1,y&&Object.assign(x,y),x}Ct(ge,bt),ge.prototype.computePixelRatio=function(){return 1},ge.prototype.redraw=function(){if(this.o&&1<=this.updateDelay){this.o=!1;var a=this.ta,y=this.ib;if(a!==null&&y!==null){if(Lc(this),this.ql===null){var x=new Zh(null);x.width=a.width,x.height=a.height,this.ql=x}try{this.ta=this.ql,this.ib=this.ta.context,this.ib.Vc(!0),this.ib.setTransform(1,0,0,1,0,0),this.ib.clearRect(0,0,this.ta.width,this.ta.height),Me(this)}finally{this.ta=a,this.ib=y}}}bt.prototype.redraw.call(this)},ge.prototype.gc=function(){if(this.Ka===null&&Dt("No div specified"),this.ta===null&&Dt("No canvas specified"),!(this.ta instanceof Fc)&&(O0(this.box),this.Fc)){var a=this.observed;if(a!==null&&!a.animationManager.defaultAnimation.isAnimating&&a.pi){Lc(this);var y=this.ta;a=this.ib,a.Vc(!0),a.setTransform(1,0,0,1,0,0),a.clearRect(0,0,y.width,y.height),1>this.updateDelay?Me(this):this.ql!==null&&(a.drawImage(this.ql.Oa,0,0),y=this.Ab,y.reset(),this.scale!==1&&y.scale(this.scale),this.position.x===0&&this.position.y===0||y.translate(-this.position.x,-this.position.y),a.scale(this.Mb,this.Mb),a.transform(y.m11,y.m12,y.m21,y.m22,y.dx,y.dy),a.yc()),y=this.Wa.s;for(var x=y.length,E=0;E<x;E++)y[E].gc(a,this);this.Fc=this.vd=!1}}};function Me(a){var y=a.observed;if(y!==null){var x=a.drawsTemporaryLayers,E=a.drawsGrid&&x,b=y.grid;E&&b!==null&&b.visible&&!isNaN(b.width)&&!isNaN(b.height)&&(b=Xt.alloc().assign(a.viewportBounds).ed(y.viewportBounds),zs(y,b),Xt.free(b),Ps(y));var z=a.Ab;z.reset(),a.scale!==1&&z.scale(a.scale),a.position.x===0&&a.position.y===0||z.translate(-a.position.x,-a.position.y),b=a.ib,b.scale(a.Mb,a.Mb),b.transform(z.m11,z.m12,z.m21,z.m22,z.dx,z.dy),b.yc(),y=y.Wa.s,z=y.length;for(var ee=0;ee<z;ee++){var re=y[ee],oe=a;if(re.visible&&re.opacity!==0){var se=re.diagram.grid.part;if(!x&&re.isTemporary)E&&se.layer===re&&(re=Jr(re,b),se.gc(b,oe),b.globalAlpha=re);else{for(var ue=Jr(re,b),fe=oe.scale,ve=Xt.alloc(),ye=re.Pa.s,Ce=ye.length,Ae=0;Ae<Ce;Ae++){var Ye=ye[Ae];(E||Ye!==se)&&re.Oj(b,Ye,oe,null,fe,ve,!1)}Xt.free(ve),b.globalAlpha=ue}}}}}function He(a){var y=a.box;if(y!==null){var x=a.observed;if(x!==null){a.Fc=!0,x=x.viewportBounds;var E=y.selectionObject,b=fn.alloc();b.h(x.width,x.height),E.desiredSize=b,fn.free(b),a=2/a.scale,E instanceof Dr&&(E.strokeWidth=a),y.location=new Qe(x.x-a/2,x.y-a/2),y.isSelected=!0}}}ge.prototype.computeBounds=function(){var a=this.observed;if(a===null)return Ro;var y=a.documentBounds.copy();return y.ed(a.viewportBounds),y},ge.prototype.invalidateViewport=function(){this.Fc!==!0&&(this.Fc=!0,this.$b())},ge.prototype.onViewportBoundsChanged=function(a,y,x,E){this.vb||(this.vd=!0,this.N(),this.Ee=!0,this.Ya(),He(this),this.fc.scale=x,this.fc.position.x=a.x,this.fc.position.y=a.y,this.fc.bounds.assign(a),this.fc.Oz=E,this.R("ViewportBoundsChanged",this.fc,a))},Yt.Object.defineProperties(ge.prototype,{observed:{get:function(){return this.V},set:function(a){var y=this.V;if(a instanceof ge&&Dt("Overview.observed Diagram may not be an Overview itself: "+a),y!==a){if(y!==null&&(this.remove(this.box),y.am("ViewportBoundsChanged",this.Pf),y.am("DocumentBoundsChanged",this.Xd),y.am("InvalidateDraw",this.Ha),y.am("AnimationFinished",this.Of)),this.V=a,a!==null&&(a.Bj("ViewportBoundsChanged",this.Pf),a.Bj("DocumentBoundsChanged",this.Xd),a.Bj("InvalidateDraw",this.Ha),a.Bj("AnimationFinished",this.Of),this.add(this.box)),this.Ya(),a===null){this.ql=null;var x=this.ta,E=this.ib;x&&E&&(E.setTransform(1,0,0,1,0,0),E.clearRect(0,0,x.width,x.height))}else this.Ha(null),He(this),this.N();this.g("observed",y,a)}}},box:{get:function(){return this.j},set:function(a){var y=this.j;y!==a&&(this.j=a,this.remove(y),this.add(this.j),He(this),this.g("box",y,a))}},drawsTemporaryLayers:{get:function(){return this.F},set:function(a){this.F!==a&&(this.F=a,this.redraw())}},drawsGrid:{get:function(){return this.u},set:function(a){this.u!==a&&(this.u=a,this.redraw())}},updateDelay:{get:function(){return this.ia},set:function(a){0>a&&(a=0),this.ia!==a&&(this.ia=a)}}}),ge.className="Overview";function Je(){Br.call(this),this.j=null}Ct(Je,Br),Je.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram;if(a===null||!a.allowMove||!a.allowSelect)return!1;var y=a.observed;if(y===null)return!1;var x=a.lastInput;return!x.left||a.currentTool!==this&&(!this.isBeyondDragSize()||x.isTouchEvent&&x.timestamp-a.firstInput.timestamp<this.delay)?!1:(this.findDraggablePart()===null&&(x=y.viewportBounds,this.j=new Qe(x.width/2,x.height/2),a=a.firstInput.documentPoint,y.position=new Qe(a.x-this.j.x,a.y-this.j.y)),!0)},Je.prototype.doActivate=function(){this.j=null,Br.prototype.doActivate.call(this)},Je.prototype.doUpdateCursor=function(){var a=this.diagram,y=a.box;y!==null&&y.cursor&&(a.currentCursor=y.cursor)},Je.prototype.moveParts=function(){var a=this.diagram,y=a.observed;if(y!==null){var x=a.box;if(x!==null){if(this.j===null){var E=a.firstInput.documentPoint;x=x.location,this.j=new Qe(E.x-x.x,E.y-x.y)}a=a.lastInput.documentPoint,y.position=new Qe(a.x-this.j.x,a.y-this.j.y)}}},Je.className="OverviewDraggingTool";function _e(){jo(this),this.H=zo,this.Ha=this.u=this.o=!0,this.F=this.V=this.nb=this.ia=!1,this.ij=this.j=null,this.Hb=1.05,this.Jt=NaN,this.sw=null,this.Au=NaN,this.yu=Ro,this.hb=!0,this.cg=null,this.ob=200}_e.prototype.toString=function(){return"CommandHandler"},_e.prototype.Xe=function(a){this.H=a},_e.prototype.doKeyDown=function(){var a=this.diagram,y=a.lastInput,x=Fs?y.meta:y.control,E=y.shift,b=y.alt,z=y.key;!x||z!=="C"&&z!=="Insert"?x&&z==="X"||E&&z==="Del"?this.canCutSelection()&&this.cutSelection():x&&z==="V"||E&&z==="Insert"?this.canPasteSelection()&&this.pasteSelection():x&&z==="Y"||b&&E&&z==="Backspace"?this.canRedo()&&this.redo():x&&z==="Z"||b&&z==="Backspace"?this.canUndo()&&this.undo():z==="Del"||z==="Backspace"?this.canDeleteSelection()&&this.deleteSelection():x&&z==="A"?this.canSelectAll()&&this.selectAll():z==="Esc"?this.canStopCommand()&&this.stopCommand():z==="Up"?a.allowVerticalScroll&&(x?a.scroll("pixel","up"):a.scroll("line","up")):z==="Down"?a.allowVerticalScroll&&(x?a.scroll("pixel","down"):a.scroll("line","down")):z==="Left"?a.allowHorizontalScroll&&(x?a.scroll("pixel","left"):a.scroll("line","left")):z==="Right"?a.allowHorizontalScroll&&(x?a.scroll("pixel","right"):a.scroll("line","right")):z==="PageUp"?E&&a.allowHorizontalScroll?a.scroll("page","left"):a.allowVerticalScroll&&a.scroll("page","up"):z==="PageDown"?E&&a.allowHorizontalScroll?a.scroll("page","right"):a.allowVerticalScroll&&a.scroll("page","down"):z==="Home"?x&&a.allowVerticalScroll?a.scroll("document","up"):!x&&a.allowHorizontalScroll&&a.scroll("document","left"):z==="End"?x&&a.allowVerticalScroll?a.scroll("document","down"):!x&&a.allowHorizontalScroll&&a.scroll("document","right"):z===" "?this.canScrollToPart()&&this.scrollToPart():z==="Subtract"?this.canDecreaseZoom()&&this.decreaseZoom():z==="Add"?this.canIncreaseZoom()&&this.increaseZoom():x&&z==="0"?this.canResetZoom()&&this.resetZoom():E&&z==="Z"?this.canZoomToFit()&&this.zoomToFit():x&&!E&&z==="G"?this.canGroupSelection()&&this.groupSelection():x&&E&&z==="G"?this.canUngroupSelection()&&this.ungroupSelection():z==="F2"||y.event&&y.event.key==="F2"?this.canEditTextBlock()&&this.editTextBlock():z==="ContextMenu"||y.event&&y.event.key==="ContextMenu"?this.canShowContextMenu()&&this.showContextMenu():y.bubbles=!0:this.canCopySelection()&&this.copySelection()},_e.prototype.doKeyUp=function(){this.diagram.lastInput.bubbles=!0},_e.prototype.stopCommand=function(){var a=this.diagram,y=a.currentTool;y instanceof sa&&a.allowSelect&&a.clearSelection(),y!==null&&y.doCancel()},_e.prototype.canStopCommand=function(){return!0},_e.prototype.selectAll=function(){var a=this.diagram;a.N();try{a.currentCursor="wait",a.R("ChangingSelection",a.selection);for(var y=a.parts;y.next();)y.value.isSelected=!0;for(var x=a.nodes;x.next();)x.value.isSelected=!0;for(var E=a.links;E.next();)E.value.isSelected=!0}finally{a.R("ChangedSelection",a.selection),a.currentCursor=""}},_e.prototype.canSelectAll=function(){return this.diagram.allowSelect},_e.prototype.deleteSelection=function(){var a=this.diagram;try{a.currentCursor="wait",a.R("ChangingSelection",a.selection),a.Ea("Delete"),a.R("SelectionDeleting",a.selection);for(var y=new Pn,x=a.selection.iterator;x.next();)Zd(y,x.value,!0,this.deletesTree?1/0:0,this.deletesConnectedLinks?null:!1,function(E){return E.canDelete()});a.Is(y,!0),a.R("SelectionDeleted",y)}finally{a.eb("Delete"),a.R("ChangedSelection",a.selection),a.currentCursor=""}},_e.prototype.canDeleteSelection=function(){var a=this.diagram;return!(a.isReadOnly||a.isModelReadOnly||!a.allowDelete||a.selection.count===0)},_e.prototype.copySelection=function(){var a=this.diagram,y=new Pn;for(a=a.selection.iterator;a.next();)Zd(y,a.value,!0,this.copiesTree?1/0:0,this.copiesConnectedLinks,function(x){return x.canCopy()});this.copyToClipboard(y)},_e.prototype.canCopySelection=function(){var a=this.diagram;return!!(a.allowCopy&&a.allowClipboard&&a.selection.count!==0)},_e.prototype.cutSelection=function(){this.copySelection(),this.deleteSelection()},_e.prototype.canCutSelection=function(){var a=this.diagram;return!!(!a.isReadOnly&&!a.isModelReadOnly&&a.allowCopy&&a.allowDelete&&a.allowClipboard&&a.selection.count!==0)},_e.prototype.copyToClipboard=function(a){var y=this.diagram,x=null;if(a===null)df=null,Gd="";else{x=y.model;var E=!1,b=!1,z=null;try{x.Tl()&&(E=x.Jj,x.Jj=this.copiesParentKey),x.Wj()&&(b=x.Ij,x.Ij=this.copiesGroupKey),z=y.Kj(a,null,!0)}finally{x.Tl()&&(x.Jj=E),x.Wj()&&(x.Ij=b),x=new An,x.addAll(z),df=x,Gd=y.model.dataFormat}}y.R("ClipboardChanged",x)},_e.prototype.pasteFromClipboard=function(){var a=new Pn,y=df;if(y===null)return a;var x=this.diagram;if(Gd!==x.model.dataFormat)return a;var E=x.model,b=!1,z=!1,ee=null;try{E.Tl()&&(b=E.Jj,E.Jj=this.copiesParentKey),E.Wj()&&(z=E.Ij,E.Ij=this.copiesGroupKey),ee=x.Kj(y,x,!1)}finally{for(E.Tl()&&(E.Jj=b),E.Wj()&&(E.Ij=z),y=ee.iterator;y.next();)x=y.value,E=y.key,x.location.w()||(E.location.w()?x.location=E.location:!x.position.w()&&E.position.w()&&(x.position=E.position)),a.add(x)}return a},_e.prototype.pasteSelection=function(a){a===void 0&&(a=null);var y=this.diagram;try{y.currentCursor="wait",y.R("ChangingSelection",y.selection),y.Ea("Paste");var x=this.pasteFromClipboard();0<x.count&&y.clearSelection(!0);for(var E=x.iterator;E.next();)E.value.isSelected=!0;if(a!==null){var b=y.computePartsBounds(y.selection);if(b.w()){var z=this.computeEffectiveCollection(y.selection,y.Wm);cs(y,z,new Qe(a.x-b.centerX,a.y-b.centerY),y.Wm,!1)}}y.R("ClipboardPasted",x)}finally{y.eb("Paste"),y.R("ChangedSelection",y.selection),y.currentCursor=""}},_e.prototype.canPasteSelection=function(){var a=this.diagram;return!(a.isReadOnly||a.isModelReadOnly||!a.allowInsert||!a.allowClipboard||df===null||df.count===0||Gd!==a.model.dataFormat)},_e.prototype.undo=function(){this.diagram.undoManager.undo()},_e.prototype.canUndo=function(){var a=this.diagram;return a.isReadOnly||a.isModelReadOnly?!1:a.allowUndo&&a.undoManager.canUndo()},_e.prototype.redo=function(){this.diagram.undoManager.redo()},_e.prototype.canRedo=function(){var a=this.diagram;return a.isReadOnly||a.isModelReadOnly?!1:a.allowUndo&&a.undoManager.canRedo()},_e.prototype.decreaseZoom=function(a){a===void 0&&(a=1/this.zoomFactor);var y=this.diagram;y.autoScale===lu&&(a=y.scale*a,a<y.minScale||a>y.maxScale||(y.scale=a))},_e.prototype.canDecreaseZoom=function(a){a===void 0&&(a=1/this.zoomFactor);var y=this.diagram;return y.autoScale!==lu?!1:(a=y.scale*a,a<y.minScale||a>y.maxScale?!1:y.allowZoom)},_e.prototype.increaseZoom=function(a){a===void 0&&(a=this.zoomFactor);var y=this.diagram;y.autoScale===lu&&(a=y.scale*a,a<y.minScale||a>y.maxScale||(y.scale=a))},_e.prototype.canIncreaseZoom=function(a){a===void 0&&(a=this.zoomFactor);var y=this.diagram;return y.autoScale!==lu?!1:(a=y.scale*a,a<y.minScale||a>y.maxScale?!1:y.allowZoom)},_e.prototype.resetZoom=function(a){a===void 0&&(a=this.defaultScale);var y=this.diagram;a<y.minScale||a>y.maxScale||(y.scale=a)},_e.prototype.canResetZoom=function(a){a===void 0&&(a=this.defaultScale);var y=this.diagram;return a<y.minScale||a>y.maxScale?!1:y.allowZoom},_e.prototype.zoomToFit=function(){var a=this.diagram,y=a.animationManager;y.Cc(),a.redraw();var x=a.position,E=a.scale;Uo(y,"Zoom To Fit"),this.isZoomToFitRestoreEnabled&&E===this.Au&&!isNaN(this.Jt)&&a.documentBounds.D(this.yu)?(a.scale=this.Jt,a.position=this.sw,this.Au=NaN,this.yu=Ro):(this.Jt=E,this.sw=x.copy(),a.zoomToFit(),this.Au=a.scale,this.yu=a.documentBounds.copy()),So(y)},_e.prototype.canZoomToFit=function(){return this.diagram.allowZoom},_e.prototype.scrollToPart=function(a){a===void 0&&(a=null);var y=this.diagram;if(y.Va(),a===null){try{this.cg!==null&&(this.cg.next()?a=this.cg.value:this.cg=null)}catch(oe){this.cg=null}a===null&&(0<y.highlighteds.count?this.cg=y.highlighteds.iterator:0<y.selection.count&&(this.cg=y.selection.iterator),this.cg!==null&&this.cg.next()&&(a=this.cg.value))}if(a!==null){var x=y.animationManager;Uo(x,"Scroll To Part");var E=this.scrollToPartPause;if(0<E){var b=lt(this,a,[a]);if(b.length===1)y.Ea(),y.es(a.actualBounds),y.eb("Scroll To Part");else{var z=function(){y.Ea();for(var oe=b.pop();0<b.length&&oe instanceof qn&&oe.isTreeExpanded&&(!(oe instanceof xr)||oe.isSubGraphExpanded);)oe=b.pop();0<b.length?(oe instanceof Ii&&y.tv(oe.actualBounds),oe instanceof qn&&!oe.isTreeExpanded&&(oe.isTreeExpanded=!0),oe instanceof xr&&!oe.isSubGraphExpanded&&(oe.isSubGraphExpanded=!0)):(oe instanceof Ii&&y.es(oe.actualBounds),y.am("LayoutCompleted",ee)),y.eb("Scroll To Part")},ee=function(){ji(z,(x.isEnabled?x.duration:0)+E)};y.Bj("LayoutCompleted",ee),z()}}else{var re=y.position.copy();y.es(a.actualBounds),re.Xa(y.position)&&x.Cc()}}};function lt(a,y,x){if(y.isVisible())return x;if(y instanceof Fo)lt(a,y.adornedPart,x);else if(y instanceof Tn){var E=y.fromNode;E!==null&&lt(a,E,x),y=y.toNode,y!==null&&lt(a,y,x)}else y instanceof qn&&(E=y.labeledLink,E!==null&&lt(a,E,x),E=y.pg(),E!==null&&(E.isTreeExpanded||E.wasTreeExpanded||x.push(E),lt(a,E,x))),y=y.containingGroup,y!==null&&(y.isSubGraphExpanded||y.wasSubGraphExpanded||x.push(y),lt(a,y,x));return x}_e.prototype.canScrollToPart=function(a){return a===void 0&&(a=null),a!==null&&!(a instanceof Ii)?!1:(a=this.diagram,a.selection.count===0&&a.highlighteds.count===0?!1:a.allowHorizontalScroll&&a.allowVerticalScroll)},_e.prototype.collapseTree=function(a){a===void 0&&(a=null);var y=this.diagram;try{y.Ea("Collapse Tree"),Uo(y.animationManager,"Collapse Tree");var x=new An;if(a!==null&&a.isTreeExpanded)a.collapseTree(),x.add(a);else if(a===null)for(var E=y.selection.iterator;E.next();){var b=E.value;b instanceof qn&&b.isTreeExpanded&&(b.collapseTree(),x.add(b))}y.R("TreeCollapsed",x)}finally{y.eb("Collapse Tree")}},_e.prototype.canCollapseTree=function(a){a===void 0&&(a=null);var y=this.diagram;if(y.isReadOnly)return!1;if(a!==null){if(!(a instanceof qn&&a.isTreeExpanded))return!1;if(0<a.Qo().count)return!0}else for(a=y.selection.iterator;a.next();)if(y=a.value,y instanceof qn&&y.isTreeExpanded&&0<y.Qo().count)return!0;return!1},_e.prototype.expandTree=function(a){a===void 0&&(a=null);var y=this.diagram;try{y.Ea("Expand Tree"),Uo(y.animationManager,"Expand Tree");var x=new An;if(a!==null&&!a.isTreeExpanded)a.expandTree(),x.add(a);else if(a===null)for(var E=y.selection.iterator;E.next();){var b=E.value;b instanceof qn&&!b.isTreeExpanded&&(b.expandTree(),x.add(b))}y.R("TreeExpanded",x)}finally{y.eb("Expand Tree")}},_e.prototype.canExpandTree=function(a){a===void 0&&(a=null);var y=this.diagram;if(y.isReadOnly)return!1;if(a!==null){if(!(a instanceof qn)||a.isTreeExpanded)return!1;if(0<a.Qo().count)return!0}else for(a=y.selection.iterator;a.next();)if(y=a.value,y instanceof qn&&!y.isTreeExpanded&&0<y.Qo().count)return!0;return!1},_e.prototype.groupSelection=function(){var a=this.diagram,y=a.model;if(y.Xj()){var x=this.archetypeGroupData;if(x!==null){var E=null;try{a.currentCursor="wait",a.R("ChangingSelection",a.selection),a.Ea("Group");for(var b=new An,z=a.selection.iterator;z.next();){var ee=z.value;ee.Zc()&&ee.canGroup()&&b.add(ee)}for(var re=new An,oe=b.iterator;oe.next();){var se=oe.value;z=!1;for(var ue=b.iterator;ue.next();)if(se.Td(ue.value)){z=!0;break}z||re.add(se)}if(0<re.count){var fe=re.first().containingGroup;if(fe!==null)for(;fe!==null;){b=!1;for(var ve=re.iterator;ve.next();)if(!ve.value.Td(fe)){b=!0;break}if(b)fe=fe.containingGroup;else break}if(x instanceof xr)_h(x),E=x.copy(),E!==null&&a.add(E);else if(y.Yu(x)){var ye=y.copyNodeData(x);kn(ye)&&(y.xf(ye),E=a.ii(ye))}if(E!==null){fe!==null&&this.isValidMember(fe,E)&&(E.containingGroup=fe);for(var Ce=re.iterator;Ce.next();){var Ae=Ce.value;this.isValidMember(E,Ae)&&(Ae.containingGroup=E)}a.clearSelection(!0),E.isSelected=!0}}a.R("SelectionGrouped",E)}finally{a.eb("Group"),a.R("ChangedSelection",a.selection),a.currentCursor=""}}}},_e.prototype.canGroupSelection=function(){var a=this.diagram;if(a.isReadOnly||a.isModelReadOnly||!a.allowInsert||!a.allowGroup||!a.model.Xj()||this.archetypeGroupData===null)return!1;for(a=a.selection.iterator;a.next();){var y=a.value;if(y.Zc()&&y.canGroup())return!0}return!1};function _t(a){var y=qi();for(a=a.iterator;a.next();){var x=a.value;x instanceof Tn||y.push(x)}a=new Pn,x=y.length;for(var E=0;E<x;E++){for(var b=y[E],z=!0,ee=0;ee<x;ee++)if(b.Td(y[ee])){z=!1;break}z&&a.add(b)}return Zi(y),a}_e.prototype.isValidMember=function(a,y){if(y===null||a===y||y instanceof Tn)return!1;if(a!==null){if(a===y||a.Td(y))return!1;var x=a.memberValidation;if(x!==null&&!x(a,y)||a.data===null&&y.data!==null||a.data!==null&&y.data===null)return!1}return x=this.memberValidation,x!==null?x(a,y):!0},_e.prototype.ungroupSelection=function(a){a===void 0&&(a=null);var y=this.diagram,x=y.model;if(x.Xj())try{y.currentCursor="wait",y.R("ChangingSelection",y.selection),y.Ea("Ungroup");var E=new An;if(a!==null)E.add(a);else for(var b=y.selection.iterator;b.next();){var z=b.value;z instanceof xr&&z.canUngroup()&&E.add(z)}var ee=new An;if(0<E.count){y.clearSelection(!0);for(var re=E.iterator;re.next();){var oe=re.value;oe.expandSubGraph();var se=oe.containingGroup,ue=se!==null&&se.data!==null?x.wa(se.data):void 0;ee.addAll(oe.memberParts);for(var fe=ee.iterator;fe.next();){var ve=fe.value;if(ve.isSelected=!0,!(ve instanceof Tn)){var ye=ve.data;ye!==null?x.mp(ye,ue):ve.containingGroup=se}}y.remove(oe)}}y.R("SelectionUngrouped",E,ee)}finally{y.eb("Ungroup"),y.R("ChangedSelection",y.selection),y.currentCursor=""}},_e.prototype.canUngroupSelection=function(a){a===void 0&&(a=null);var y=this.diagram;if(y.isReadOnly||y.isModelReadOnly||!y.allowDelete||!y.allowUngroup||!y.model.Xj())return!1;if(a!==null){if(!(a instanceof xr))return!1;if(a.canUngroup())return!0}else for(a=y.selection.iterator;a.next();)if(y=a.value,y instanceof xr&&y.canUngroup())return!0;return!1},_e.prototype.addTopLevelParts=function(a,y){var x=!0;for(a=_t(a).iterator;a.next();){var E=a.value;E.containingGroup!==null&&(!y||this.isValidMember(null,E)?E.containingGroup=null:x=!1)}return x},_e.prototype.collapseSubGraph=function(a){a===void 0&&(a=null);var y=this.diagram;try{y.Ea("Collapse SubGraph"),Uo(y.animationManager,"Collapse SubGraph");var x=new An;if(a!==null&&a.isSubGraphExpanded)a.collapseSubGraph(),x.add(a);else if(a===null)for(var E=y.selection.iterator;E.next();){var b=E.value;b instanceof xr&&b.isSubGraphExpanded&&(b.collapseSubGraph(),x.add(b))}y.R("SubGraphCollapsed",x)}finally{y.eb("Collapse SubGraph")}},_e.prototype.canCollapseSubGraph=function(a){a===void 0&&(a=null);var y=this.diagram;if(y.isReadOnly)return!1;if(a!==null)return!!(a instanceof xr&&a.isSubGraphExpanded);for(a=y.selection.iterator;a.next();)if(y=a.value,y instanceof xr&&y.isSubGraphExpanded)return!0;return!1},_e.prototype.expandSubGraph=function(a){a===void 0&&(a=null);var y=this.diagram;try{y.Ea("Expand SubGraph"),Uo(y.animationManager,"Expand SubGraph");var x=new An;if(a!==null&&!a.isSubGraphExpanded)a.expandSubGraph(),x.add(a);else if(a===null)for(var E=y.selection.iterator;E.next();){var b=E.value;b instanceof xr&&!b.isSubGraphExpanded&&(b.expandSubGraph(),x.add(b))}y.R("SubGraphExpanded",x)}finally{y.eb("Expand SubGraph")}},_e.prototype.canExpandSubGraph=function(a){a===void 0&&(a=null);var y=this.diagram;if(y.isReadOnly)return!1;if(a!==null)return a instanceof xr&&!a.isSubGraphExpanded;for(a=y.selection.iterator;a.next();)if(y=a.value,y instanceof xr&&!y.isSubGraphExpanded)return!0;return!1},_e.prototype.editTextBlock=function(a){a===void 0&&(a=null);var y=this.diagram,x=y.toolManager.findTool("TextEditing");if(x!==null){if(a===null){a=null;for(var E=y.selection.iterator;E.next();){var b=E.value;if(b.canEdit()){a=b;break}}if(a===null)return;a=a.Nl(function(z){return z instanceof ja&&z.editable})}a!==null&&(y.currentTool=null,x.textBlock=a,y.currentTool=x)}},_e.prototype.canEditTextBlock=function(a){a===void 0&&(a=null);var y=this.diagram;if(y.isReadOnly||y.isModelReadOnly||!y.allowTextEdit||y.toolManager.findTool("TextEditing")===null)return!1;if(a!==null){if(!(a instanceof ja))return!1;if(a=a.part,a!==null&&a.canEdit())return!0}else for(y=y.selection.iterator;y.next();)if(a=y.value,a.canEdit()&&(a=a.Nl(function(x){return x instanceof ja&&x.editable}),a!==null))return!0;return!1},_e.prototype.showContextMenu=function(a){var y=this.diagram,x=y.toolManager.findTool("ContextMenu");if(x!==null&&(a===void 0&&(a=0<y.selection.count?y.selection.first():y),a=x.findObjectWithContextMenu(a),a!==null)){var E=y.lastInput,b=null;a instanceof mt?b=a.ga(ko):y.viewportBounds.ca(E.documentPoint)||(b=y.viewportBounds,b=new Qe(b.x+b.width/2,b.y+b.height/2)),b!==null&&(E.viewPoint=y.op(b),E.documentPoint=b,E.left=!1,E.right=!0,E.up=!0),y.currentTool=x,ni(x,!1,a)}},_e.prototype.canShowContextMenu=function(a){var y=this.diagram,x=y.toolManager.findTool("ContextMenu");return x===null?!1:(a===void 0&&(a=0<y.selection.count?y.selection.first():y),x.findObjectWithContextMenu(a)!==null)},_e.prototype.computeEffectiveCollection=function(a,y){var x=this.diagram,E=x.toolManager.findTool("Dragging"),b=x.currentTool===E;if(y===void 0&&(y=b?E.dragOptions:x.Wm),E=new Li,a===null)return E;for(var z=a.iterator;z.next();)dh(x,E,z.value,b,y);if(x.draggedLink!==null&&y.dragsLink)return E;for(z=a.iterator;z.next();)a=z.value,a instanceof Tn&&(y=a.fromNode,y===null||E.contains(y)?(y=a.toNode,y===null||E.contains(y)||E.remove(a)):E.remove(a));return E},Yt.Object.defineProperties(_e.prototype,{diagram:{get:function(){return this.H}},copiesClipboardData:{get:function(){return this.o},set:function(a){this.o=a}},copiesConnectedLinks:{get:function(){return this.u},set:function(a){this.u=a}},deletesConnectedLinks:{get:function(){return this.Ha},set:function(a){this.Ha=a}},copiesTree:{get:function(){return this.ia},set:function(a){this.ia=a}},deletesTree:{get:function(){return this.nb},set:function(a){this.nb=a}},copiesParentKey:{get:function(){return this.V},set:function(a){this.V=a}},copiesGroupKey:{get:function(){return this.F},set:function(a){this.F=a}},archetypeGroupData:{get:function(){return this.j},set:function(a){this.j=a}},memberValidation:{get:function(){return this.ij},set:function(a){this.ij=a}},defaultScale:{get:function(){return this.diagram.defaultScale},set:function(a){this.diagram.defaultScale=a}},zoomFactor:{get:function(){return this.Hb},set:function(a){1<a||Dt("zoomFactor must be larger than 1.0, not: "+a),this.Hb=a}},isZoomToFitRestoreEnabled:{get:function(){return this.hb},set:function(a){this.hb=a}},scrollToPartPause:{get:function(){return this.ob},set:function(a){this.ob=a}}}),_e.className="CommandHandler",us=function(){return new _e};function mt(){jo(this),this.l=30723,this.pb=1,this.bn="",this.Ma=this.Me=null,this.pa=new Qe(NaN,NaN).freeze(),this.jd=el,this.Ab=new kr,this.wh=new kr,this.Lb=null,this.Ca=this.Kk=1,this.Kb=0,this.Kg=Tl,this.uc=new Xt(NaN,NaN,NaN,NaN).freeze(),this.Ib=new Xt(NaN,NaN,NaN,NaN).freeze(),this.dc=new Xt(0,0,NaN,NaN).freeze(),this.ba=this.Yn=this.Zn=null,this.sk=this.Jb=vs,this.Ag=this.io=0,this.V=this.tb=this.Dh=this.A=this.Ua=null,this.Uc=!1,this.jo=this.Ng=null}var Cn,mn,xi,Mi,Yi,Cr,ao,Gr,wo,ua;mt.prototype.cloneProtected=function(a){a.l=this.l|6144,a.pb=this.pb,a.bn=this.bn,a.Ma=this.Ma,a.pa.assign(this.pa),a.jd=this.jd.J(),this.Lb!==null?a.Lb=this.Lb.copy():a.Lb=null,a.Ca=this.Ca,a.Kb=this.Kb,a.Kg=this.Kg.J(),a.uc.assign(this.uc),a.Ib.assign(this.Ib),a.dc.assign(this.dc),a.Yn=this.Yn,this.ba!==null&&(a.ba=this.ba.copy()),a.Jb=this.Jb.J(),a.sk=this.sk.J(),a.io=this.io,a.Ag=this.Ag,this.Ua!==null&&(a.Ua=this.Ua.copy()),this.A!==null&&(a.A=this.A.nc?this.A:this.A.copy()),this.Dh!==null&&(a.Dh=Lo(this.Dh)),this.tb!==null&&(a.tb=this.tb.copy())},mt.prototype.Vw=function(a){var y=this.Dh;if(Xi(y)){for(var x=0;x<y.length;x++)if(y[x]===a)return}else this.Dh=y=[];y.push(a)},mt.prototype.Af=function(a){a.Zn=null,a.Ng=null,a.v()},mt.prototype.clone=function(){var a=new this.constructor;if(this.cloneProtected(a),this.Dh!==null)for(var y=0;y<this.Dh.length;y++){var x=this.Dh[y];a[x]=this[x]}return a},mt.prototype.copy=function(){return this.clone()},we=mt.prototype,we.qb=function(a){a.classType===Tn?a.name.indexOf("Orient")===0?this.segmentOrientation=a:Dt("Unknown Link enum value for GraphObject.segmentOrientation property: "+a):a.classType===mt&&(this.stretch=a)},we.toString=function(){return cr(this.constructor)+"#"+qa(this)},we.th=function(){this.A!==null&&(this.A.nc=!0)};function Hr(a){a.A===null?a.A=new Hf:a.A.nc&&(a.A=a.A.copy())}we.Xc=function(){if(this.ba===null){var a=new up;a.Xi=Ms,a.yj=Ms,a.Vi=10,a.wj=10,a.Wi=0,a.xj=0,this.ba=a}},we.cb=function(a,y,x,E,b,z,ee){var re=this.part;if(re!==null&&(re.gk(a,y,x,E,b,z,ee),x===this&&a===ga&&Rl(this)&&_a(this,re,y),z=this.diagram,this.animationTriggers===null||z===null||!z.pi||z.undoManager.isUndoingRedoing||z.animationManager.Dm||(a=this.animationTriggers.get(y),a!==null&&z.animationManager.isEnabled&&!z.animationManager.isTicking&&(this.jo===null&&(this.jo=new Li),ee=z.undoManager.transactionLevel===0,a.startCondition===Vi?ee=!0:a.startCondition===Ki&&(ee=!1),ee?(z=new Xo,Fa(a,z),ee=this.jo.get(a),ee!==null&&ee.stop(),this.jo.add(a,z),z.vu=this,z.Nw=a,z.add(this,y,E,b),z.start()):(Uo(z.animationManager,"Trigger"),z.animationManager.defaultAnimation.add(this,y,E,b)))),this instanceof Ln&&x===re&&(re.l&16777216)!==0&&re.data!==null))for(x=this.O.s,E=x.length,b=0;b<E;b++)re=x[b],re instanceof Ln&&Sf(re,function(oe){oe.data!==null&&oe.l&16777216&&oe.La(y)})};function _a(a,y,x){var E=a.ih();if(E!==null)for(var b=a.localBindings.iterator;b.next();){var z=b.value,ee=null;if(z.sourceName!==null){if(ee=L1(z,E,a),ee===null)continue;z.sp(a,ee,x,null)}else if(z.isToModel){var re=y.diagram;re===null||re.skipsModelSourceBindings||z.sp(a,re.model.modelData,x,E)}else{if(re=E.data,re===null)continue;var oe=y.diagram;oe===null||oe.skipsModelSourceBindings||z.sp(a,re,x,E)}ee===a&&(re=E.ks(z.Ai),re!==null&&z.Mv(re,ee,x))}}we.ks=function(a){return this.bindingId===a?this:null},we.g=function(a,y,x){this.cb(ga,a,this,y,x)},we.Ge=function(a,y,x,E){var b=this.uc;if(b.h(a,y,x,E),this.Ca!==1||this.Kb!==0){this.Lb===null&&(this.Lb=new kr);var z=this.Lb;z.reset(),this.no(z,a,y,x,E),z.pp(b)}};function fl(a,y,x,E){return a.pickable===!1?!1:(E.multiply(a.transform),x?a.Yc(y,E):a.fh(y,E))}we.tx=function(a,y,x){if(this.pickable===!1)return!1;var E=this.naturalBounds;return y=a.Bf(y),x?ps(a.x,a.y,0,0,0,E.height)<=y||ps(a.x,a.y,0,E.height,E.width,E.height)<=y||ps(a.x,a.y,E.width,E.height,E.width,0)<=y||ps(a.x,a.y,E.width,0,0,0)<=y:a.zd(0,0)<=y&&a.zd(0,E.height)<=y&&a.zd(E.width,0)<=y&&a.zd(E.width,E.height)<=y},we.se=function(){return!0},we.ca=function(a){var y=Qe.alloc();y.assign(a),this.transform.Ga(y);var x=this.actualBounds;if(!x.w())return Qe.free(y),!1;var E=this.diagram;if(E!==null&&E.wq){var b=E.Ql("extraTouchThreshold"),z=E.Ql("extraTouchArea"),ee=z/2,re=this.naturalBounds;E=this.Df()*E.scale;var oe=1/E;if(re.width*E<b&&re.height*E<b)return a=Ds(x.x-ee*oe,x.y-ee*oe,x.width+z*oe,x.height+z*oe,y.x,y.y),Qe.free(y),a}return b=!1,(this instanceof Fo||this instanceof Dr?Ds(x.x-5,x.y-5,x.width+10,x.height+10,y.x,y.y):x.ca(y))&&(this.tb&&!this.tb.ca(y)?b=!1:this.areaBackground!==null&&x.ca(y)||this.Ma!==null&&this.dc.ca(a)?b=!0:b=this.gh(a)),Qe.free(y),b},we.gh=function(a){var y=this.naturalBounds;return Ds(0,0,y.width,y.height,a.x,a.y)},we.Re=function(a){if(this.angle===0)return this.actualBounds.Re(a);var y=this.naturalBounds;y=Xt.allocAt(0,0,y.width,y.height);var x=this.transform,E=!1,b=Qe.allocAt(a.x,a.y);return y.ca(x.Cd(b))&&(b.h(a.x,a.bottom),y.ca(x.Cd(b))&&(b.h(a.right,a.bottom),y.ca(x.Cd(b))&&(b.h(a.right,a.y),y.ca(x.Cd(b))&&(E=!0)))),Qe.free(b),Xt.free(y),E},we.fh=function(a,y){if(y===void 0)return a.Re(this.actualBounds);var x=this.naturalBounds,E=!1,b=Qe.allocAt(0,0);return a.ca(y.Ga(b))&&(b.h(0,x.height),a.ca(y.Ga(b))&&(b.h(x.width,x.height),a.ca(y.Ga(b))&&(b.h(x.width,0),a.ca(y.Ga(b))&&(E=!0)))),Qe.free(b),E},we.Yc=function(a,y){if(y===void 0&&(y=this.transform,this.angle===0))return a.Yc(this.actualBounds);var x=this.naturalBounds,E=Qe.allocAt(0,0),b=Qe.allocAt(0,x.height),z=Qe.allocAt(x.width,x.height),ee=Qe.allocAt(x.width,0),re=!1;if(a.ca(y.Ga(E))||a.ca(y.Ga(b))||a.ca(y.Ga(z))||a.ca(y.Ga(ee)))re=!0;else{x=Xt.allocAt(0,0,x.width,x.height);var oe=Qe.allocAt(a.x,a.y);x.ca(y.Cd(oe))?re=!0:(oe.h(a.x,a.bottom),x.ca(y.Cd(oe))?re=!0:(oe.h(a.right,a.bottom),x.ca(y.Cd(oe))?re=!0:(oe.h(a.right,a.y),x.ca(y.Cd(oe))&&(re=!0)))),Qe.free(oe),Xt.free(x),!re&&(yt.us(a,E,b)||yt.us(a,b,z)||yt.us(a,z,ee)||yt.us(a,ee,E))&&(re=!0)}return Qe.free(E),Qe.free(b),Qe.free(z),Qe.free(ee),re},we.ga=function(a,y){if(y===void 0&&(y=new Qe),a instanceof Bi){var x=this.naturalBounds;y.h(a.x*x.width+a.offsetX,a.y*x.height+a.offsetY)}else y.set(a);return this.oe.Ga(y),y},we.mi=function(a){a===void 0&&(a=new Xt);var y=this.naturalBounds,x=this.oe,E=Qe.allocAt(0,0).transform(x);return a.h(E.x,E.y,0,0),E.h(y.width,0).transform(x),es(a,E.x,E.y,0,0),E.h(y.width,y.height).transform(x),es(a,E.x,E.y,0,0),E.h(0,y.height).transform(x),es(a,E.x,E.y,0,0),Qe.free(E),a},we.li=function(){var a=this.oe;return a.m11===1&&a.m12===0?a=0:(a=180*Math.atan2(a.m12,a.m11)/Math.PI,0>a&&(a+=360)),a},we.Df=function(){if(!(this.l&4096))return this.Kk;var a=this.Ca;return this.panel!==null?a*this.panel.Df():a},we.qs=function(a,y){return y===void 0&&(y=new Qe),y.assign(a),this.oe.Cd(y),y},we.rs=function(a,y,x){return this.Sj(a.x,a.y,y.x,y.y,x)},we.Sj=function(a,y,x,E,b){var z=this.transform,ee=1/(z.m11*z.m22-z.m12*z.m21),re=z.m22*ee,oe=-z.m12*ee,se=-z.m21*ee,ue=z.m11*ee,fe=ee*(z.m21*z.dy-z.m22*z.dx),ve=ee*(z.m12*z.dx-z.m11*z.dy);return this.areaBackground!==null?(z=this.actualBounds,yt.Ff(z.left,z.top,z.right,z.bottom,a,y,x,E,b)):(ee=a*re+y*se+fe,a=a*oe+y*ue+ve,y=x*re+E*se+fe,x=x*oe+E*ue+ve,b.h(0,0),E=this.naturalBounds,x=yt.Ff(0,0,E.width,E.height,ee,a,y,x,b),b.transform(z),x)},mt.prototype.measure=function(a,y,x,E){if(ph(this)!==!1){var b=this.Kg,z=b.right+b.left;b=b.top+b.bottom,a=Math.max(a-z,0),y=Math.max(y-b,0),x=Math.max((x||0)-z,0),E=Math.max((E||0)-b,0),z=this.angle,b=this.desiredSize;var ee=this.kq();z===90||z===270?(a=isFinite(b.height)?b.height+ee:a,y=isFinite(b.width)?b.width+ee:y):(a=isFinite(b.width)?b.width+ee:a,y=isFinite(b.height)?b.height+ee:y),b=x||0,ee=E||0;var re=this instanceof Ln;switch(Ou(this,!0)){case mn:ee=b=0,re&&(y=a=1/0);break;case Cn:isFinite(a)&&a>x&&(b=a),isFinite(y)&&y>E&&(ee=y);break;case Mi:isFinite(a)&&a>x&&(b=a),ee=0,re&&(y=1/0);break;case Yi:isFinite(y)&&y>E&&(ee=y),b=0,re&&(a=1/0)}re=this.maxSize;var oe=this.minSize;b>re.width&&oe.width<re.width&&(b=re.width),ee>re.height&&oe.height<re.height&&(ee=re.height),x=Math.max(b,oe.width),E=Math.max(ee,oe.height),re.width<x&&(x=Math.min(oe.width,x)),re.height<E&&(E=Math.min(oe.height,E)),a=Math.min(re.width,a),y=Math.min(re.height,y),a=Math.max(x,a),y=Math.max(E,y),(z===90||z===270)&&(z=a,a=y,y=z,z=x,x=E,E=z),this.uc.ka(),this.Wl(a,y,x,E),this.uc.freeze(),this.uc.w()||Dt("Non-real measuredBounds has been set. Object "+this+", measuredBounds: "+this.uc.toString()),Ys(this,!1)}},mt.prototype.Wl=function(){},mt.prototype.Dd=function(){return!1},mt.prototype.arrange=function(a,y,x,E,b){this.Uk();var z=Xt.alloc();z.assign(this.Ib),this.Ib.ka(),Su(this)===!1?this.Ib.h(a,y,x,E):this.eh(a,y,x,E),this.Ib.freeze(),b===void 0?this.tb=null:this.tb=b,x=!1,b!==void 0?x=!0:(b=this.panel,b!==null&&wd(b)&&(b=b.panel),b!==null&&(b=b.dc,E=this.measuredBounds,this.areaBackground!==null&&(E=this.Ib),x=y+E.height,E=a+E.width,x=!(0<=a+.05&&E<=b.width+.05&&0<=y+.05&&x<=b.height+.05),this instanceof ja&&(a=this.naturalBounds,this.Lq>a.height||this.Cb>a.width))&&(x=!0)),this.l=x?this.l|256:this.l&-257,this.Ib.w()||Dt("Non-real actualBounds has been set. Object "+this+", actualBounds: "+this.Ib.toString()),this.Xl(z,this.Ib),Hc(this,!1),Xt.free(z)},we=mt.prototype,we.eh=function(){};function uu(a,y,x,E,b){if(a.Ib.h(y,x,E,b),!a.desiredSize.w()){var z=a.uc;x=a.Kg,y=x.right+x.left;var ee=x.top+x.bottom;switch(x=z.width+y,z=z.height+ee,E+=y,b+=ee,y=Ou(a,!0),x===E&&z===b&&(y=mn),y){case mn:(x>E||z>b)&&(Ys(a,!0),a.measure(x>E?E:x,z>b?b:z,0,0));break;case Cn:Ys(a,!0),a.measure(E,b,0,0);break;case Mi:Ys(a,!0),a.measure(E,z,0,0);break;case Yi:Ys(a,!0),a.measure(x,b,0,0)}}}we.Xl=function(a,y){var x=this.part;x!==null&&x.diagram!==null&&(x.selectionObject!==this&&x.resizeObject!==this&&x.rotateObject!==this||j0(x,!0),this.N(),As(a,y)||(x.oh(),this.Pn(x)))},we.Pn=function(a){this.portId!==null&&(j0(a,!0),a instanceof qn&&WS(a,this))},we.gc=function(a,y){if(!Ah(this,a,y)&&this.visible){var x=this.opacity;if(x!==0){var E=1;x!==1&&(E=a.globalAlpha,a.globalAlpha=E*x);var b="";this.filter!==""&&(b=a.filter,a.filter=this.filter);var z=this instanceof Ln&&wd(this),ee=this.Ib;if(z){var re=this.Ib,oe=this.dc,se=this.areaBackground,ue=this.Ma;se===null&&ue===null||a.yc(),se!==null&&(ks(this,a,se,!0,!0,oe,re),se instanceof ia&&se.type===Dh?(a.beginPath(),a.rect(re.x,re.y,re.width,re.height),a.ng(se)):a.fillRect(re.x,re.y,re.width,re.height)),ue!==null&&(ks(this,a,ue,!0,!1,oe,re),ue instanceof ia&&ue.type===Dh?(a.beginPath(),a.rect(re.x,re.y,re.width,re.height),a.ng(ue)):a.fillRect(re.x,re.y,re.width,re.height)),this.hh(a,y)}if(!z&&(z||ee.width!==0&&ee.height!==0&&!isNaN(ee.x)&&!isNaN(ee.y))){z=this.transform,re=this.panel,this.l&4096&&kl(this),se=this.part,oe=!1;var fe=0;se&&y.Gf("drawShadows")&&(oe=se.isShadowed)&&(ue=se.shadowOffset,fe=Math.max(ue.y,ue.x)*y.scale*y.Mb),ue=this.Dd();var ve;if(!(ve=y.$i||!ue)){var ye=this.naturalBounds;ve=this.wh;var Ce=ve.m11,Ae=ve.m21,Ye=ve.dx,We=ve.m12,tt=ve.m22,rt=ve.dy,at,gt=at=0;ve=at*Ce+gt*Ae+Ye;var At=at*We+gt*tt+rt;at=ye.width+fe,gt=0;var Zn=at*Ce+gt*Ae+Ye;at=at*We+gt*tt+rt,gt=Math.min(ve,Zn);var mi=Math.min(At,at),si=Math.max(ve+0,Zn)-gt,Nn=Math.max(At+0,at)-mi;ve=gt,At=mi,at=ye.width+fe,gt=ye.height+fe,Zn=at*Ce+gt*Ae+Ye,at=at*We+gt*tt+rt,gt=Math.min(ve,Zn),mi=Math.min(At,at),si=Math.max(ve+si,Zn)-gt,Nn=Math.max(At+Nn,at)-mi,ve=gt,At=mi,at=0,gt=ye.height+fe,Zn=at*Ce+gt*Ae+Ye,at=at*We+gt*tt+rt,gt=Math.min(ve,Zn),mi=Math.min(At,at),si=Math.max(ve+si,Zn)-gt,Nn=Math.max(At+Nn,at)-mi,ve=gt,At=mi,fe=y.viewportBounds,ye=fe.x,Ce=fe.y,ve=!(ve>fe.width+ye||ye>si+ve||At>fe.height+Ce||Ce>Nn+At)}if(ve){if(ve=(this.l&256)!==0,a.clipInsteadOfFill&&(ve=!1),this instanceof ja&&(a.font=this.font),ve){if(At=re.se()?re.naturalBounds:re.actualBounds,si=Math.max(ee.x,At.x),Nn=Math.max(ee.y,At.y),fe=Math.min(ee.right,At.right)-si,ye=Math.min(ee.bottom,At.bottom)-Nn,Ce=this.tb,Ce!==null&&(si=Ce.x,Nn=Ce.y,fe=Ce.width,ye=Ce.height),si>ee.width+ee.x||ee.x>At.width+At.x){x!==1&&(a.globalAlpha=E),this.filter!==""&&(a.filter=b);return}a.save(),a.beginPath(),a.rect(si,Nn,fe,ye),a.clip()}if(ue){if(!se.isVisible()){x!==1&&(a.globalAlpha=E),this.filter!==""&&(a.filter=b);return}oe&&(At=se.shadowOffset,a.Ev(At.x*y.scale*this.scale*y.Mb,At.y*y.scale*this.scale*y.Mb,se.shadowBlur),id(a),a.shadowColor=se.shadowColor)}oe&&this.shadowVisible===!0?id(a):oe&&this.shadowVisible===!1&&Gc(a),se=this.naturalBounds,this.areaBackground!==null&&(a.yc(),gh(this,a,se,ee)),a.transform(z.m11,z.m12,z.m21,z.m22,z.dx,z.dy),oe&&Cl(this,re)&&this.shadowVisible===null&&Gc(a),this.Ma!==null&&(a.yc(),Wu(this,a,se,ee)),oe&&(this.Ma!==null||this.areaBackground!==null||Cl(this,re))?(ic(this,!0),this.shadowVisible===null&&Gc(a)):ic(this,!1),this.hh(a,y),oe&&this.l&512&&id(a),ue&&oe&&Gc(a),ve&&(a.restore(),a.Vc(this instanceof Ln)),z.ws()||(y=1/(z.m11*z.m22-z.m12*z.m21),a.transform(z.m22*y,-z.m12*y,-z.m21*y,z.m11*y,y*(z.m21*z.dy-z.m22*z.dx),y*(z.m12*z.dx-z.m11*z.dy)))}}x!==1&&(a.globalAlpha=E),this.filter!==""&&(a.filter=b)}}};function Cl(a,y){return y===null?!1:(wd(y)&&(y=y.panel),(y.l&512)!==0||(y.type===Ln.Auto||y.type===Ln.Spot)&&y.Pb()!==a)}we.Dv=function(){};function gh(a,y,x,E){ks(a,y,a.areaBackground,!0,!0,x,E),a.areaBackground instanceof ia&&a.areaBackground.type===Dh?(y.beginPath(),y.rect(E.x,E.y,E.width,E.height),y.ng(a.areaBackground)):y.fillRect(E.x,E.y,E.width,E.height)}function Wu(a,y,x,E){var b=a.kq(),z=x.x,ee=x.y,re=x.width+b,oe=x.height+b;ks(a,y,a.Ma,!0,!1,x,E),a.Ma instanceof ia&&a.Ma.type===Dh?(y.beginPath(),y.rect(z-b/2,ee-b/2,re,oe),y.ng(a.Ma)):y.fillRect(z-b/2,ee-b/2,re,oe)}function ql(a,y,x){for(var E=y.O.s,b=E.length,z=-1,ee=0;ee<b;ee++)if(E[ee]===a){z=ee;break}if(a=z,a!==-1)if(a===0)y.svg.gd?y.svg.gd.after(x):y.svg.Ma?y.svg.Ma.after(x):y.type===Ln.Table?(y=y.svg.getElementsByClassName("gojs-ts"),y=y.length!==0?y[0]:null,y!==null&&y.after(x)):y.svg.prepend(x);else{for(;a!==0&&!y.M(a-1).Ed();)a--;a===0?y.svg.prepend(x):(a=y.M(a-1).svg,a!==null?a.after(x):y.svg.appendChild(x))}}function Ah(a,y,x){if(!(y instanceof th))return!1;if(!a.visible||a.opacity===0||a.Dd()&&!a.isVisible())return a.svg!==null&&a.svg.parentNode!==null&&a.svg.remove(),!0;var E=a.panel,b=a.nk(y);if(a.kk(y,x,b))return a.svg.parentElement!==null?(a.Dd()&&(y.ti=a.svg),!0):(a.Dd()?(y.ti!==null?y.ti.after(a.svg):y.Nj.prepend(a.svg),y.ti=a.svg):E&&ql(a,E,a.svg),!0);if(a.Dd()&&a.isShadowed){var z=a.shadowOffset;y.Ev(z.x*x.scale*a.scale*x.Mb,z.y*x.scale*a.scale*x.Mb,a.shadowBlur),id(y),y.shadowColor=a.shadowColor}a instanceof ja&&(y.font=a.font),y.yd=null;var ee=a.transform;z=a instanceof Ln;var re=a instanceof Ln?wd(a):!1;a.l&4096&&kl(a);var oe=a.Ib;if(y.rb.ha=[1,0,0,1,0,0],y.o=!1,b&&(y.o=!0,z&&re?(hp(y,1,0,0,1,0,0),a.svg=y.ad):z?(hp(y,ee.m11,ee.m12,ee.m21,ee.m22,ee.dx,ee.dy),a.svg=y.ad):hp(y,1,0,0,1,0,0)),b=a.naturalBounds,a.areaBackground!==null){var se=ee.copy().Vj();y.rb.ha=[se.m11,se.m12,se.m21,se.m22,se.dx,se.dy],gh(a,y,b,oe),y.rb.ha=[1,0,0,1,0,0],y.yd.gd=y.ad,y.yd.prepend(y.ad)}return z||(y.rb.ha=[ee.m11,ee.m12,ee.m21,ee.m22,ee.dx,ee.dy]),a.background!==null&&(z?(re&&(y.rb.ha=[ee.m11,ee.m12,ee.m21,ee.m22,ee.dx,ee.dy]),Wu(a,y,b,oe),re&&(y.rb.ha=[1,0,0,1,0,0])):(y.rb.ha=[ee.m11,ee.m12,ee.m21,ee.m22,ee.dx,ee.dy],Wu(a,y,b,oe)),y.yd.Ma=y.ad,y.yd.prepend(y.ad)),ee=y.yd,b=a.part,re=!1,b&&x.Gf("drawShadows")&&(re=b.isShadowed),y.clipInsteadOfFill&&(re=!1),a.Dd()&&re&&id(y),re&&a.shadowVisible===!0?id(y):re&&a.shadowVisible===!1&&Gc(y),b=a.panel,re&&Cl(a,b)&&a.shadowVisible===null&&Gc(y),y.Il&&(se=x.computePixelRatio(),se="drop-shadow("+y.shadowOffsetX/se+"px "+y.shadowOffsetY/se+"px "+y.shadowBlur/se/2+"px "+y.shadowColor+")",a.background!==null&&ee.Ma.setAttributeNS(null,"filter",se),a.areaBackground!==null&&ee.gd.setAttributeNS(null,"filter",se)),re&&(a.Ma!==null||a.areaBackground!==null||Cl(a,b))?(ic(a,!0),a.shadowVisible===null&&Gc(y)):ic(a,!1),b=re,a.hh(y,x),z&&y.nh.pop(),y.o&&y.nh.pop(),ee=y.Gv.hs,re=z?a.svg:y.yd,se=a.svg,!z&&se!==null&&re!==se&&se.parentNode===a.panel.svg?(a.svg.replaceWith(re),a.svg=re,re!==null&&a.$o(y,E,oe,re),Bu(y,se),!0):(a.svg=re,ee!==null&&re===null&&(fm(y),y.nh.pop()),re===null||(a.$o(y,E,oe,re),y.Il&&(x=x.computePixelRatio(),a.Dv(re,"drop-shadow("+y.shadowOffsetX/x+"px "+y.shadowOffsetY/x+"px "+y.shadowBlur/x/2+"px "+y.shadowColor+")")),b&&a.l&512&&id(y),a.Dd()&&Gc(y),x=a.Dd()?a.opacity*y.globalAlpha:a.opacity,x!==1&&re.setAttributeNS(null,"opacity",x.toString()),a.filter!==""&&re.setAttributeNS(null,"filter",a.filter),a.Dd()?(y.ti?y.ti.after(re):y.Nj.prepend(re),y.ti=re):E!==null&&ql(a,E,re),ee!==null&&ee(a,re)),!0)}we.$o=function(a,y,x,E){var b=(this.l&256)!==0;if(a.clipInsteadOfFill&&(b=!1),b){var z=y.se()?y.naturalBounds:y.actualBounds;y=Math.max(x.x,z.x),b=Math.max(x.y,z.y);var ee=Math.min(x.right,z.right)-y;x=Math.min(x.bottom,z.bottom)-b,z=this.tb,z!==null&&(y=z.x,b=z.y,ee=z.width,x=z.height),z=E.getAttribute("clip-path");var re=null;z!==null&&(re=a.svg.getElementById(z.split("#")[1].slice(0,-1))),re===null?(z="CLIP"+bl++,re=a.Ud("clipPath",{id:z}),y=a.Ud("rect",{x:y,y:b,width:ee,height:x}),this instanceof Ln&&(b=this.transform.copy().Vj(),y.setAttribute("transform","matrix("+b.m11+", "+b.m12+", "+b.m21+", "+b.m22+", "+b.dx+", "+b.dy+")")),re.appendChild(y),a.svg.appendChild(re),E.setAttributeNS(null,"clip-path","url(#"+z+")")):(a=re.firstElementChild,a.setAttribute("x",y.toString()),a.setAttribute("y",b.toString()),a.setAttribute("width",ee.toString()),a.setAttribute("height",x.toString()))}else E.removeAttributeNS(null,"clip-path"),Bu(a,E)};function Bu(a,y){y=y.getAttribute("clip-path"),y!==null&&(a=a.svg.getElementById(y.split("#")[1].slice(0,-1)),a!==null&&a.remove())}function $l(a){if(a.svg!==null){var y=a.svg.innerHTML.match(/url\(#((CLIP|GRAD).+?)\)/g),x=a.svg.ownerDocument;if(y!==null){y=bn(y);for(var E=y.next();!E.done;E=y.next())E=x.getElementById(E.value.split("#")[1].slice(0,-1)),E!==null&&E.remove()}a.svg.remove()}}we.hh=function(){},we.lv=function(){this.Uc=!0},we.kk=function(a,y,x){if(this.Uc)return this.lv(),this.Uc=!1;if(y=this.svg,y===null)return!1;if(!this.visible)return y.remove(),!1;if(y.nodeName!=="g"&&x||y.nodeName==="g"&&!x)return!1;var E=this.transform,b=this instanceof Ln?wd(this):!1;if(!(this instanceof Ln&&b))if(this instanceof Iu){var z=this.bt;a.rb.ha=[E.m11,E.m12,E.m21,E.m22,E.dx,E.dy],z!==null&&Xy(a,z[0],z[1],z[2],z[3],z[4],z[5],z[6],z[7]),x?y.lastElementChild.setAttributeNS(null,"transform",Jy(a)):y.setAttributeNS(null,"transform",Jy(a))}else if(!x||this instanceof Ln)y.setAttributeNS(null,"transform","matrix("+E.m11+", "+E.m12+", "+E.m21+", "+E.m22+", "+E.dx+", "+E.dy+")");else if(this instanceof Dr){z=y.getElementsByTagName("path");for(var ee=0;ee<z.length;ee++)z[ee].setAttributeNS(null,"transform","matrix("+E.m11+", "+E.m12+", "+E.m21+", "+E.m22+", "+E.dx+", "+E.dy+")")}else y.lastElementChild.setAttributeNS(null,"transform","matrix("+E.m11+", "+E.m12+", "+E.m21+", "+E.m22+", "+E.dx+", "+E.dy+")");return z=this.Dd()?this.opacity*a.globalAlpha:this.opacity,z===1?y.removeAttribute("opacity"):y.setAttributeNS(null,"opacity",z.toString()),a.rb.ha=[1,0,0,1,0,0],(this.areaBackground!==null||y.gd!==void 0)&&(z=y.gd,this.areaBackground===null?(y.gd.remove(),y.gd=void 0):(ee=E.copy().Vj(),a.rb.ha=[ee.m11,ee.m12,ee.m21,ee.m22,ee.dx,ee.dy],gh(this,a,this.naturalBounds,this.actualBounds),a.rb.ha=[1,0,0,1,0,0],y.gd?(ee=y.gd.getAttribute("filter"),ee!==null&&a.ad.setAttribute("filter",ee),y.gd.replaceWith(a.ad)):y.prepend(a.ad),y.gd=a.ad),z&&gm(a,z)),(this.background!==null||y.Ma!==void 0)&&(z=y.Ma,this.background===null?(gm(a,y.Ma),y.Ma.remove(),y.Ma=void 0):((b||x&&!(this instanceof Ln))&&(a.rb.ha=[E.m11,E.m12,E.m21,E.m22,E.dx,E.dy]),Wu(this,a,this.naturalBounds,this.actualBounds),y.Ma?(gm(a,y.Ma),x=y.Ma.getAttribute("filter"),x!==null&&a.ad.setAttribute("filter",x),y.Ma.replaceWith(a.ad)):y.prepend(a.ad),y.Ma=a.ad),z&&gm(a,z)),this.$o(a,this.panel,this.actualBounds,y),!0},we.nk=function(a){if(this.background!==null||this.areaBackground!==null)return!0;var y=(this.l&256)!==0;return a.clipInsteadOfFill&&(y=!1),!!y};function ks(a,y,x,E,b,z,ee){if(x!==null){var re=1,oe=1;if(typeof x=="string")E?y.fillStyle=x:y.strokeStyle=x;else if(x.type===xd)E?y.fillStyle=x.color:y.strokeStyle=x.color;else{var se=a.kq();if(re=z.width,oe=z.height,b?(re=ee.width,oe=ee.height):E||(re+=se,oe+=se),(z=y instanceof yf)&&x.xe&&(x.type===xg||x.yk===re&&x.ft===oe))var ue=x.xe;else{var fe=0,ve=0,ye=0,Ce=0,Ae=0,Ye=0;if(Ye=Ae=0,b?(Ae=ee.x,Ye=ee.y):E||(Ae-=se/2,Ye-=se/2),fe=x.start.x*re+x.start.offsetX,ve=x.start.y*oe+x.start.offsetY,ye=x.end.x*re+x.end.offsetX,Ce=x.end.y*oe+x.end.offsetY,fe+=Ae,ye+=Ae,ve+=Ye,Ce+=Ye,x.type===od)ue=y.createLinearGradient(fe,ve,ye,Ce);else if(x.type===Dh)Ye=isNaN(x.endRadius)?Math.max(re,oe)/2:x.endRadius,isNaN(x.startRadius)?(Ae=0,Ye=Math.max(re,oe)/2):Ae=x.startRadius,ue=y.createRadialGradient(fe,ve,Ae,ye,Ce,Ye);else if(x.type===xg)try{ue=y.createPattern(x.pattern,"repeat")}catch(tt){ue=null}if(x.type!==xg&&(b=x.colorStops,b!==null))for(b=b.iterator;b.next();)ue.addColorStop(b.key,b.value);if(z&&(x.xe=ue,ue!==null&&(x.yk=re,x.ft=oe),ue===null&&x.type===xg&&x.yk!==-1)){x.yk=-1;var We=a.diagram;We!==null&&x.yk===-1&&ji(function(){We.redraw()},600)}}E?y.fillStyle=ue:y.strokeStyle=ue}}}we.rg=function(a){if(a instanceof Ln)e:{if(this!==a&&a!==null)for(var y=this.panel;y!==null;){if(y===a){a=!0;break e}y=y.panel}a=!1}else a=!1;return a},we.Ed=function(){if(!this.visible)return!1;var a=this.panel;return a!==null?a.Ed():!0},we.If=function(){for(var a=this instanceof Ln?this:this.panel;a!==null&&a.isEnabled;)a=a.panel;return a===null};function kl(a){if(a.l&2048){var y=a.Ab;if(y.reset(),!a.Ib.w()||!a.uc.w()){Uh(a,!1);return}if(y.translate(a.Ib.x-a.uc.x,a.Ib.y-a.uc.y),a.scale!==1||a.angle!==0){var x=a.naturalBounds;a.no(y,x.x,x.y,x.width,x.height)}Uh(a,!1),Nh(a,!0)}a.l&4096&&(y=a.panel,y===null?(a.wh.set(a.Ab),a.Kk=a.scale,Nh(a,!1)):y.oe!==null&&(x=a.wh,x.reset(),y.se()?x.multiply(y.wh):y.panel!==null&&x.multiply(y.panel.wh),x.multiply(a.Ab),a.Kk=a.scale*y.Kk,Nh(a,!1)))}we.no=function(a,y,x,E,b){if(this.Ca!==1&&a.scale(this.Ca),this.Kb!==0){var z=Qe.alloc();z.yi(y,x,E,b,ko),a.rotate(this.Kb,z.x,z.y),Qe.free(z)}},we.v=function(a){if(!ph(this)){a===void 0&&(a=!1),Ys(this,!0),Hc(this,!0);var y=this.panel;y===null||a||y.v()}},we.Uj=function(){ph(this)||(Ys(this,!0),Hc(this,!0))};function yu(a){if(!Su(a)){var y=a.panel;y!==null?y.v():a.Dd()&&(y=a.diagram,y!==null&&(y.De.add(a),a instanceof qn&&a.Bd(),y.$b())),Hc(a,!0)}}we.Uk=function(){!(this.l&2048)&&(Uh(this,!0),Nh(this,!0))},we.Wu=function(){Nh(this,!0)},we.N=function(){var a=this.part;a!==null&&a.N()};function Ou(a,y){var x=a.stretch,E=a.panel;return E!==null&&E.type===Ln.Table?gc(a,E.Fb(a.row),E.Eb(a.column),y):E!==null&&E.type===Ln.Auto&&E.Pb()===a?El(a,Cn,y):x===Cr?E!==null?E.type===Ln.Spot&&E.Pb()===a?El(a,Cn,y):(x=E.defaultStretch,x===Cr?El(a,mn,y):El(a,x,y)):El(a,mn,y):El(a,x,y)}function gc(a,y,x,E){var b=a.stretch;if(b!==Cr)return El(a,b,E);var z=b=null;switch(y.stretch){case Yi:z=!0;break;case Cn:z=!0}switch(x.stretch){case Mi:b=!0;break;case Cn:b=!0}return y=a.panel.defaultStretch,b===null&&(b=y===Mi||y===Cn),z===null&&(z=y===Yi||y===Cn),b===!0&&z===!0?El(a,Cn,E):b===!0?El(a,Mi,E):z===!0?El(a,Yi,E):El(a,mn,E)}function El(a,y,x){if(x)return y;if(y===mn||(x=a.desiredSize,x.w()))return mn;if(a=a.angle,!isNaN(x.width))if(a!==90&&a!==270){if(y===Mi)return mn;if(y===Cn)return Yi}else{if(y===Yi)return mn;if(y===Cn)return Mi}if(!isNaN(x.height))if(a!==90&&a!==270){if(y===Yi)return mn;if(y===Cn)return Mi}else{if(y===Mi)return mn;if(y===Cn)return Yi}return y}function ic(a,y){a.l=y?a.l|512:a.l&-513}function Rl(a){return(a.l&1024)!==0}function zf(a,y){a.l=y?a.l|1024:a.l&-1025}function Uh(a,y){a.l=y?a.l|2048:a.l&-2049}function Nh(a,y){a.l=y?a.l|4096:a.l&-4097}function ph(a){return(a.l&8192)!==0}function Ys(a,y){a.l=y?a.l|8192:a.l&-8193}function Su(a){return(a.l&16384)!==0}function Hc(a,y){a.l=y?a.l|16384:a.l&-16385}we.Gj=function(){this.svg=null},we.wi=function(a){this.Me=a,this.svg!==null&&this.svg.remove()},we.Av=function(){},we.zv=function(a){return this.pa=a,yu(this),!0},we.mm=function(a,y){(this.pa.x!==a||this.pa.y!==y)&&(this.pa.h(a,y),this.Uk())},we.kq=function(){return 0};function mf(a){var y=a.part;if(y instanceof qn&&(a.portId!==null||a===y.port)){var x=y.diagram;x===null||x.undoManager.isUndoingRedoing||WS(y,a)}}function _y(a){var y=a.diagram;y===null||y.undoManager.isUndoingRedoing||(a instanceof Ln?a instanceof qn?a.Bd():a.qm(a,function(x){mf(x)}):mf(a))}we.bind=function(a,y,x,E){var b=null;return typeof a=="string"?b=new Hs(a,y,x,E):b=a,b.xd=this,a=this.ih(),a!==null&&dS(a)&&Dt("Cannot add a Binding to a template that has already been copied: "+b),this.localBindings===null&&(this.localBindings=new An),this.localBindings.add(b),this},we.set=function(a){return Object.assign(this,a),this},we.Du=function(a){return n0(this,a),this},we.apply=function(a){return a(this),this},we.nm=function(a){return jc(this,a),this},we.pz=function(){return this.ih()},we.ih=function(){for(var a=this instanceof Ln?this:this.panel;a!==null;){if(a.allBindings!==null)return a;a=a.panel}return null},we.Jv=function(a){return a.xd=this,this.animationTriggers===null&&(this.animationTriggers=new Li),this.animationTriggers.add(a.propertyName,a),this};function Th(a,y){for(var x=1;x<arguments.length;++x);x=arguments;var E=null,b=null;if(typeof a=="function")b=a;else if(typeof a=="string"){var z=gg.I(a);typeof z=="function"?(x=Lo(arguments),E=z(x),kn(E)||Dt('GraphObject.make invoked object builder "'+a+'", but it did not return an Object')):b=Kt.go[a]}if(E===null&&(b!=null&&b.constructor||Dt("GraphObject.make requires a class function or GoJS class name or name of an object builder, not: "+a),E=new b),b=1,E instanceof bt&&1<x.length){z=E;var ee=x[1];(typeof ee=="string"||ee instanceof HTMLDivElement)&&(Hi(z,ee),b++)}for(;b<x.length;b++)z=x[b],z===void 0?Dt("Undefined value at argument "+b+" for object being constructed by GraphObject.make: "+E):n0(E,z);return E}function n0(a,y){if(typeof y=="string")if(a instanceof ja)a.text=y;else if(a instanceof Dr)a.figure=y;else if(a instanceof Iu)a.source=y;else if(a instanceof Ln)y=rc.I(y),y!==null&&(a.type=y);else if(a instanceof ia){var x=Kr(ia,y);x!==null?a.type=x:Dt("Unknown Brush type as an argument to GraphObject.make: "+y)}else a instanceof Bn?(y=Kr(Bn,y),y!==null&&(a.type=y)):a instanceof to&&(y=Kr(to,y),y!==null&&(a.type=y));else if(y instanceof mt)a instanceof Ln||Dt("A GraphObject can only be added to a Panel, not to: "+a),a.add(y);else if(y instanceof Xs){var E;y.isRow&&typeof a.getRowDefinition=="function"?E=a.getRowDefinition(y.index):y.isRow||typeof a.getColumnDefinition!="function"||(E=a.getColumnDefinition(y.index)),E instanceof Xs?Am(E,y):Dt("A RowColumnDefinition can only be added to an object that implements getRowDefinition/getColumnDefinition, not to: "+a)}else if(y instanceof Vt)typeof a.qb=="function"&&a.qb(y);else if(y instanceof qs)a.type=y;else if(y instanceof Hs)a instanceof mt||a instanceof Xs?a.bind(y):Dt("A Binding can only be applied to a GraphObject or RowColumnDefinition, not to: "+a);else if(y instanceof Za)a instanceof mt?a.Jv(y):Dt("An AnimationTrigger can only be applied to a GraphObject, not to: "+a);else if(y instanceof Ns)a instanceof Bn&&a.type===Bn.o?a.figures.add(y):Dt("A PathFigure can only be added to a Path Geometry, not to: "+a);else if(y instanceof to)a instanceof Ns?a.segments.add(y):Dt("A PathSegment can only be added to a PathFigure, not to: "+a);else if(y instanceof as)a instanceof bt||a instanceof xr?a.layout=y:Dt("A Layout can only be assigned to a Diagram or a Group, not to: "+a);else if(Array.isArray(y))for(x=0;x<y.length;x++)n0(a,y[x]);else if(typeof y=="object"&&y!==null)if(a instanceof ia){x=new Er;for(var b in y)E=parseFloat(b),isNaN(E)?x[b]=y[b]:a.addColorStop(E,y[b]);jc(a,x)}else if(a instanceof Xs){y.row!==void 0?(b=y.row,(b==null||b===1/0||isNaN(b)||0>b)&&Dt("Must specify non-negative integer row for RowColumnDefinition "+y+", not: "+b),a.isRow=!0,a.index=b):y.column!==void 0&&(b=y.column,(b==null||b===1/0||isNaN(b)||0>b)&&Dt("Must specify non-negative integer column for RowColumnDefinition "+y+", not: "+b),a.isRow=!1,a.index=b),b=new Er;for(x in y)x!=="row"&&x!=="column"&&(b[x]=y[x]);jc(a,b)}else jc(a,y);else Dt('Unknown initializer "'+y+'" for object being constructed by GraphObject.make: '+a)}function Sd(a,y){gg.add(a,y)}function dm(a,y,x){x===void 0&&(x=null);var E=a[1];if(typeof x=="function"?x(E):typeof E=="string")return a.splice(1,1),E;if(y===void 0)throw Error("no "+(typeof x=="function"?"satisfactory":"string")+" argument for GraphObject builder "+a[0]);return y}Yt.Object.defineProperties(mt.prototype,{bindingId:{get:function(){return this.A!==null?this.A.zp:-1},set:function(a){this.bindingId!==a&&(this.A===null&&(this.A=new Hf),this.A.zp=a)}},localBindings:{get:function(){return this.A!==null?this.A.te:null},set:function(a){this.localBindings!==a&&(this.A===null&&(this.A=new Hf),this.A.te=a)}},srcBindings:{get:function(){return this.A!==null?this.A.wm:null},set:function(a){this.srcBindings!==a&&(this.A===null&&(this.A=new Hf),this.A.wm=a)}},shadowVisible:{get:function(){return this.A!==null?this.A.Ci:null},set:function(a){var y=this.shadowVisible;y!==a&&(Hr(this),this.A.Ci=a,this.Uc=!0,this.N(),this.g("shadowVisible",y,a))}},enabledChanged:{get:function(){return this.A!==null?this.A.Hb:null},set:function(a){var y=this.enabledChanged;y!==a&&(Hr(this),this.A.Hb=a,this.g("enabledChanged",y,a))}},segmentOrientation:{get:function(){return this.Ua!==null?this.Ua.rr:Pu},set:function(a){var y=this.segmentOrientation;y!==a&&(this.Ua===null&&(this.Ua=new Wd),this.Ua.rr=a,this.v(),this.g("segmentOrientation",y,a),a===Pu&&(this.angle=0))}},segmentIndex:{get:function(){return this.Ua!==null?this.Ua.u:-1/0},set:function(a){a=Math.round(a);var y=this.segmentIndex;y!==a&&(this.Ua===null&&(this.Ua=new Wd),this.Ua.u=a,this.v(),this.g("segmentIndex",y,a))}},segmentFraction:{get:function(){return this.Ua!==null?this.Ua.o:0},set:function(a){isNaN(a)||0>a?a=0:1<a&&(a=1);var y=this.segmentFraction;y!==a&&(this.Ua===null&&(this.Ua=new Wd),this.Ua.o=a,this.v(),this.g("segmentFraction",y,a))}},segmentOffset:{get:function(){return this.Ua!==null?this.Ua.F:bs},set:function(a){var y=this.segmentOffset;y.D(a)||(a=a.J(),this.Ua===null&&(this.Ua=new Wd),this.Ua.F=a,this.v(),this.g("segmentOffset",y,a))}},stretch:{get:function(){return this.A!==null?this.A.hg:Cr},set:function(a){var y=this.stretch;y!==a&&(Hr(this),this.A.hg=a,this.v(),this.g("stretch",y,a))}},name:{get:function(){return this.A!==null?this.A.xa:""},set:function(a){var y=this.name;y!==a&&(Hr(this),this.A.xa=a,this.part!==null&&(this.part.Rh=null),this.g("name",y,a))}},opacity:{get:function(){return this.pb},set:function(a){var y=this.pb;y!==a&&((0>a||1<a)&&gr(a,"0 <= value <= 1",mt,"opacity"),this.pb=a,this.g("opacity",y,a),a=this.diagram,y=this.part,a!==null&&y!==null&&a.N(Pf(y,y.actualBounds)))}},filter:{get:function(){return this.bn},set:function(a){var y=this.bn;y!==a&&(this.bn=a,this.Uc=!0,this.g("filter",y,a),a=this.diagram,y=this.part,a!==null&&y!==null&&a.N(Pf(y,y.actualBounds)))}},visible:{get:function(){return(this.l&1)!==0},set:function(a){var y=(this.l&1)!==0;y!==a&&(this.l^=1,this.g("visible",y,a),y=this.panel,y!==null?y.v():this.Dd()&&this.Zb(a),this.N(),_y(this))}},pickable:{get:function(){return(this.l&2)!==0},set:function(a){var y=(this.l&2)!==0;y!==a&&(this.l^=2,this.g("pickable",y,a))}},fromLinkableDuplicates:{get:function(){return(this.l&4)!==0},set:function(a){var y=(this.l&4)!==0;y!==a&&(this.l^=4,this.g("fromLinkableDuplicates",y,a))}},fromLinkableSelfNode:{get:function(){return(this.l&8)!==0},set:function(a){var y=(this.l&8)!==0;y!==a&&(this.l^=8,this.g("fromLinkableSelfNode",y,a))}},toLinkableDuplicates:{get:function(){return(this.l&16)!==0},set:function(a){var y=(this.l&16)!==0;y!==a&&(this.l^=16,this.g("toLinkableDuplicates",y,a))}},toLinkableSelfNode:{get:function(){return(this.l&32)!==0},set:function(a){var y=(this.l&32)!==0;y!==a&&(this.l^=32,this.g("toLinkableSelfNode",y,a))}},isPanelMain:{get:function(){return(this.l&64)!==0},set:function(a){var y=(this.l&64)!==0;y!==a&&(this.l^=64,this.v(),this.g("isPanelMain",y,a))}},isActionable:{get:function(){return(this.l&128)!==0},set:function(a){var y=(this.l&128)!==0;y!==a&&(this.l^=128,this.g("isActionable",y,a))}},areaBackground:{get:function(){return this.A!==null?this.A.gd:null},set:function(a){var y=this.areaBackground;y!==a&&(a!==null&&Kf(a,"GraphObject.areaBackground"),a instanceof ia&&a.freeze(),Hr(this),this.A.gd=a,this.N(),this.g("areaBackground",y,a))}},background:{get:function(){return this.Ma},set:function(a){var y=this.Ma;y!==a&&(a!==null&&Kf(a,"GraphObject.background"),a instanceof ia&&a.freeze(),this.Ma=a,this.N(),this.g("background",y,a))}},part:{get:function(){if(this.Dd())return this;if(this.Ng!==null)return this.Ng;var a;for(a=this.panel;a;){if(a instanceof Ii)return this.Ng=a;a=a.panel}return null}},svg:{get:function(){return this.V},set:function(a){this.V=a}},panel:{get:function(){return this.Me}},layer:{get:function(){var a=this.part;return a!==null?a.layer:null}},diagram:{get:function(){var a=this.part;return a!==null?a.diagram:null}},position:{get:function(){return this.pa},set:function(a){var y=a.x,x=a.y,E=this.pa,b=E.x;E=E.y,(b===y||isNaN(b)&&isNaN(y))&&(E===x||isNaN(E)&&isNaN(x))?this.Av():(a=a.copy(),this.zv(a,b,E)&&this.g("position",new Qe(b,E),a))}},actualBounds:{get:function(){return this.Ib}},scale:{get:function(){return this.Ca},set:function(a){var y=this.Ca;y!==a&&(0>=a&&Dt("GraphObject.scale for "+this+" must be greater than zero, not: "+a),this.Ca=a,this.v(),this.g("scale",y,a))}},angle:{get:function(){return this.Kb},set:function(a){var y=this.Kb;y!==a&&(a%=360,0>a&&(a+=360),y!==a&&(this.Kb=a,_y(this),this.v(),this.g("angle",y,a)))}},desiredSize:{get:function(){return this.jd},set:function(a){var y=a.width,x=a.height,E=this.jd,b=E.width,z=E.height;(b===y||isNaN(b)&&isNaN(y))&&(z===x||isNaN(z)&&isNaN(x))||(this.jd=a=a.J(),this.v(),this instanceof Dr&&this.qc(),this.g("desiredSize",E,a),Rl(this)&&(a=this.part,a!==null&&(_a(this,a,"width"),_a(this,a,"height"))))}},width:{get:function(){return this.jd.width},set:function(a){var y=this.jd.width;y===a||isNaN(y)&&isNaN(a)||(y=this.jd,this.jd=a=new fn(a,this.jd.height).freeze(),this.v(),this instanceof Dr&&this.qc(),this.g("desiredSize",y,a),Rl(this)&&(a=this.part,a!==null&&_a(this,a,"width")))}},height:{get:function(){return this.jd.height},set:function(a){var y=this.jd.height;y===a||isNaN(y)&&isNaN(a)||(y=this.jd,this.jd=a=new fn(this.jd.width,a).freeze(),this.v(),this instanceof Dr&&this.qc(),this.g("desiredSize",y,a),Rl(this)&&(a=this.part,a!==null&&_a(this,a,"height")))}},minSize:{get:function(){return this.A!==null?this.A.u:jr},set:function(a){var y=this.minSize;y.D(a)||(a=a.copy(),isNaN(a.width)&&(a.width=0),isNaN(a.height)&&(a.height=0),a.freeze(),Hr(this),this.A.u=a,this.v(),this.g("minSize",y,a))}},maxSize:{get:function(){return this.A!==null?this.A.o:Vs},set:function(a){var y=this.maxSize;y.D(a)||(a=a.copy(),isNaN(a.width)&&(a.width=1/0),isNaN(a.height)&&(a.height=1/0),a.freeze(),Hr(this),this.A.o=a,this.v(),this.g("maxSize",y,a))}},measuredBounds:{get:function(){return this.uc}},naturalBounds:{get:function(){return this.dc}},margin:{get:function(){return this.Kg},set:function(a){typeof a=="number"&&(a=new vr(a));var y=this.Kg;y.D(a)||(this.Kg=a=a.J(),this.v(),this.g("margin",y,a))}},transform:{get:function(){return this.l&2048&&kl(this),this.Ab}},oe:{get:function(){return this.l&4096&&kl(this),this.wh}},animationTriggers:{get:function(){return this.A!==null?this.A.hb:null},set:function(a){this.animationTriggers!==a&&(Hr(this),this.A.hb=a)}},reshapingBehavior:{get:function(){return this.A!==null?this.A.Pf:mn},set:function(a){this.reshapingBehavior!==a&&(Hr(this),this.A.Pf=a)}},alignment:{get:function(){return this.Jb},set:function(a){var y=this.Jb;y.D(a)||(a.Mc()&&!a.Xb()&&Dt("GraphObject.alignment for "+this+" must be a real Spot or Spot.Default, not: "+a),this.Jb=a=a.J(),yu(this),this.g("alignment",y,a))}},column:{get:function(){return this.Ag},set:function(a){a=Math.round(a);var y=this.Ag;y!==a&&(0>a&&gr(a,">= 0",mt,"column"),this.Ag=a,this.v(),this.g("column",y,a),this.svg!==null&&this.svg.remove())}},columnSpan:{get:function(){return this.A!==null?this.A.ob:1},set:function(a){a=Math.round(a);var y=this.columnSpan;y!==a&&(1>a&&gr(a,">= 1",mt,"columnSpan"),Hr(this),this.A.ob=a,this.v(),this.g("columnSpan",y,a))}},row:{get:function(){return this.io},set:function(a){a=Math.round(a);var y=this.io;y!==a&&(0>a&&gr(a,">= 0",mt,"row"),this.io=a,this.v(),this.g("row",y,a),this.svg!==null&&this.svg.remove())}},rowSpan:{get:function(){return this.A!==null?this.A.Bi:1},set:function(a){a=Math.round(a);var y=this.rowSpan;y!==a&&(1>a&&gr(a,">= 1",mt,"rowSpan"),Hr(this),this.A.Bi=a,this.v(),this.g("rowSpan",y,a))}},spanAllocation:{get:function(){return this.A!==null?this.A.Di:null},set:function(a){var y=this.spanAllocation;y!==a&&(Hr(this),this.A.Di=a,this.v(),this.g("spanAllocation",y,a))}},alignmentFocus:{get:function(){return this.sk},set:function(a){var y=this.sk;y.D(a)||(this.sk=a=a.J(),this.v(),this.g("alignmentFocus",y,a))}},portId:{get:function(){return this.Yn},set:function(a){var y=this.Yn;if(y!==a){var x=this.part;x===null||x instanceof qn||Dt("Cannot set portID on a Link: "+a),y!==null&&x!==null&&K0(x,this),this.Yn=a,a!==null&&x!==null&&(x.Te=!0,ZS(x,this)),this.g("portId",y,a)}}},toSpot:{get:function(){return this.ba!==null?this.ba.yj:Ms},set:function(a){var y=this.toSpot;y.D(a)||(a=a.J(),this.Xc(),this.ba.yj=a,this.g("toSpot",y,a),mf(this))}},toEndSegmentLength:{get:function(){return this.ba!==null?this.ba.wj:10},set:function(a){var y=this.toEndSegmentLength;y!==a&&(0>a&&gr(a,">= 0",mt,"toEndSegmentLength"),this.Xc(),this.ba.wj=a,this.g("toEndSegmentLength",y,a),mf(this))}},toShortLength:{get:function(){return this.ba!==null?this.ba.xj:0},set:function(a){var y=this.toShortLength;y!==a&&(this.Xc(),this.ba.xj=a,this.g("toShortLength",y,a),mf(this))}},toLinkable:{get:function(){return this.ba!==null?this.ba.Tr:null},set:function(a){var y=this.toLinkable;y!==a&&(this.Xc(),this.ba.Tr=a,this.g("toLinkable",y,a))}},toMaxLinks:{get:function(){return this.ba!==null?this.ba.Ur:1/0},set:function(a){var y=this.toMaxLinks;y!==a&&(0>a&&gr(a,">= 0",mt,"toMaxLinks"),this.Xc(),this.ba.Ur=a,this.g("toMaxLinks",y,a))}},fromSpot:{get:function(){return this.ba!==null?this.ba.Xi:Ms},set:function(a){var y=this.fromSpot;y.D(a)||(a=a.J(),this.Xc(),this.ba.Xi=a,this.g("fromSpot",y,a),mf(this))}},fromEndSegmentLength:{get:function(){return this.ba!==null?this.ba.Vi:10},set:function(a){var y=this.fromEndSegmentLength;y!==a&&(0>a&&gr(a,">= 0",mt,"fromEndSegmentLength"),this.Xc(),this.ba.Vi=a,this.g("fromEndSegmentLength",y,a),mf(this))}},fromShortLength:{get:function(){return this.ba!==null?this.ba.Wi:0},set:function(a){var y=this.fromShortLength;y!==a&&(this.Xc(),this.ba.Wi=a,this.g("fromShortLength",y,a),mf(this))}},fromLinkable:{get:function(){return this.ba!==null?this.ba.hq:null},set:function(a){var y=this.fromLinkable;y!==a&&(this.Xc(),this.ba.hq=a,this.g("fromLinkable",y,a))}},fromMaxLinks:{get:function(){return this.ba!==null?this.ba.iq:1/0},set:function(a){var y=this.fromMaxLinks;y!==a&&(0>a&&gr(a,">= 0",mt,"fromMaxLinks"),this.Xc(),this.ba.iq=a,this.g("fromMaxLinks",y,a))}},cursor:{get:function(){return this.A!==null?this.A.j:""},set:function(a){var y=this.cursor;y!==a&&(Hr(this),this.A.j=a,this.g("cursor",y,a))}},click:{get:function(){return this.A!==null?this.A.zh:null},set:function(a){var y=this.click;y!==a&&(Hr(this),this.A.zh=a,this.g("click",y,a))}},doubleClick:{get:function(){return this.A!==null?this.A.Fh:null},set:function(a){var y=this.doubleClick;y!==a&&(Hr(this),this.A.Fh=a,this.g("doubleClick",y,a))}},contextClick:{get:function(){return this.A!==null?this.A.Bh:null},set:function(a){var y=this.contextClick;y!==a&&(Hr(this),this.A.Bh=a,this.g("contextClick",y,a))}},mouseEnter:{get:function(){return this.A!==null?this.A.Mh:null},set:function(a){var y=this.mouseEnter;y!==a&&(Hr(this),this.A.Mh=a,this.g("mouseEnter",y,a))}},mouseLeave:{get:function(){return this.A!==null?this.A.Ph:null},set:function(a){var y=this.mouseLeave;y!==a&&(Hr(this),this.A.Ph=a,this.g("mouseLeave",y,a))}},mouseOver:{get:function(){return this.A!==null?this.A.Qh:null},set:function(a){var y=this.mouseOver;y!==a&&(Hr(this),this.A.Qh=a,this.g("mouseOver",y,a))}},mouseHover:{get:function(){return this.A!==null?this.A.Oh:null},set:function(a){var y=this.mouseHover;y!==a&&(Hr(this),this.A.Oh=a,this.g("mouseHover",y,a))}},mouseHold:{get:function(){return this.A!==null?this.A.Nh:null},set:function(a){var y=this.mouseHold;y!==a&&(Hr(this),this.A.Nh=a,this.g("mouseHold",y,a))}},mouseDragEnter:{get:function(){return this.A!==null?this.A.Of:null},set:function(a){var y=this.mouseDragEnter;y!==a&&(Hr(this),this.A.Of=a,this.g("mouseDragEnter",y,a))}},mouseDragLeave:{get:function(){return this.A!==null?this.A.Xd:null},set:function(a){var y=this.mouseDragLeave;y!==a&&(Hr(this),this.A.Xd=a,this.g("mouseDragLeave",y,a))}},mouseDrop:{get:function(){return this.A!==null?this.A.Lh:null},set:function(a){var y=this.mouseDrop;y!==a&&(Hr(this),this.A.Lh=a,this.g("mouseDrop",y,a))}},actionDown:{get:function(){return this.A!==null?this.A.V:null},set:function(a){var y=this.actionDown;y!==a&&(Hr(this),this.A.V=a,this.g("actionDown",y,a))}},actionMove:{get:function(){return this.A!==null?this.A.ia:null},set:function(a){var y=this.actionMove;y!==a&&(Hr(this),this.A.ia=a,this.g("actionMove",y,a))}},actionUp:{get:function(){return this.A!==null?this.A.Ha:null},set:function(a){var y=this.actionUp;y!==a&&(Hr(this),this.A.Ha=a,this.g("actionUp",y,a))}},actionCancel:{get:function(){return this.A!==null?this.A.F:null},set:function(a){var y=this.actionCancel;y!==a&&(Hr(this),this.A.F=a,this.g("actionCancel",y,a))}},toolTip:{get:function(){return this.A!==null?this.A.$h:null},set:function(a){var y=this.toolTip;y!==a&&(Hr(this),this.A.$h=a,this.g("toolTip",y,a))}},contextMenu:{get:function(){return this.A!==null?this.A.Ch:null},set:function(a){var y=this.contextMenu;y!==a&&(Hr(this),this.A.Ch=a,this.g("contextMenu",y,a))}}}),mt.prototype.trigger=mt.prototype.Jv,mt.prototype.findBindingPanel=mt.prototype.ih,mt.prototype.findTemplateBinder=mt.prototype.pz,mt.prototype.setProperties=mt.prototype.nm,mt.prototype.apply=mt.prototype.apply,mt.prototype.attach=mt.prototype.Du,mt.prototype.set=mt.prototype.set,mt.prototype.isEnabledObject=mt.prototype.If,mt.prototype.isVisibleObject=mt.prototype.Ed,mt.prototype.isContainedBy=mt.prototype.rg,mt.prototype.getNearestIntersectionPoint=mt.prototype.rs,mt.prototype.getLocalPoint=mt.prototype.qs,mt.prototype.getDocumentScale=mt.prototype.Df,mt.prototype.getDocumentAngle=mt.prototype.li,mt.prototype.getDocumentBounds=mt.prototype.mi,mt.prototype.getDocumentPoint=mt.prototype.ga,mt.prototype.intersectsRect=mt.prototype.Yc,mt.prototype.containedInRect=mt.prototype.fh,mt.prototype.containsRect=mt.prototype.Re,mt.prototype.containsPoint=mt.prototype.ca,mt.prototype.raiseChanged=mt.prototype.g,mt.prototype.raiseChangedEvent=mt.prototype.cb,mt.prototype.addCopyProperty=mt.prototype.Vw;var gg=null;mt.className="GraphObject",gg=new Li,Sd("Button",function(){function a(x,E){return x.diagram.ic(x.documentPoint,function(b){for(;b.panel!==null&&!b.isActionable;)b=b.panel;return b},function(b){return b===E})!==null}var y=Th(Ln,Ln.Auto,{isActionable:!0,enabledChanged:function(x,E){if(x instanceof Ln){var b=x.fb("ButtonBorder");b!==null&&(b.fill=E?x._buttonFillNormal:x._buttonFillDisabled)}},cursor:"pointer",_buttonFillNormal:"#F5F5F5",_buttonStrokeNormal:"#BDBDBD",_buttonFillOver:"#E0E0E0",_buttonStrokeOver:"#9E9E9E",_buttonFillPressed:"#BDBDBD",_buttonStrokePressed:"#9E9E9E",_buttonFillDisabled:"#E5E5E5"},Th(Dr,{name:"ButtonBorder",figure:"RoundedRectangle",spot1:new Bi(0,0,2.76142374915397,2.761423749153969),spot2:new Bi(1,1,-2.76142374915397,-2.761423749153969),parameter1:2,parameter2:2,fill:"#F5F5F5",stroke:"#BDBDBD"}));return y.mouseEnter=function(x,E){if(E.If()&&E instanceof Ln&&(x=E.fb("ButtonBorder"),x instanceof Dr)){var b=E._buttonFillOver;E._buttonFillNormal=x.fill,x.fill=b,b=E._buttonStrokeOver,E._buttonStrokeNormal=x.stroke,x.stroke=b}},y.mouseLeave=function(x,E){E.If()&&E instanceof Ln&&(x=E.fb("ButtonBorder"),x instanceof Dr&&(x.fill=E._buttonFillNormal,x.stroke=E._buttonStrokeNormal))},y.actionDown=function(x,E){if(E.If()&&E instanceof Ln&&E._buttonFillPressed!==null&&x.button===0){var b=E.fb("ButtonBorder");if(b instanceof Dr){x=x.diagram;var z=x.skipsUndoManager;x.skipsUndoManager=!0;var ee=E._buttonFillPressed;E._buttonFillOver=b.fill,b.fill=ee,ee=E._buttonStrokePressed,E._buttonStrokeOver=b.stroke,b.stroke=ee,x.skipsUndoManager=z}}},y.actionUp=function(x,E){if(E.If()&&E instanceof Ln&&E._buttonFillPressed!==null&&x.button===0){var b=E.fb("ButtonBorder");if(b instanceof Dr){var z=x.diagram,ee=z.skipsUndoManager;z.skipsUndoManager=!0,a(x,E)?(b.fill=E._buttonFillOver,b.stroke=E._buttonStrokeOver):(b.fill=E._buttonFillNormal,b.stroke=E._buttonStrokeNormal),z.skipsUndoManager=ee}}},y.actionCancel=function(x,E){if(E.If()&&E instanceof Ln&&E._buttonFillPressed!==null){var b=E.fb("ButtonBorder");if(b instanceof Dr){var z=x.diagram,ee=z.skipsUndoManager;z.skipsUndoManager=!0,a(x,E)?(b.fill=E._buttonFillOver,b.stroke=E._buttonStrokeOver):(b.fill=E._buttonFillNormal,b.stroke=E._buttonStrokeNormal),z.skipsUndoManager=ee}}},y.actionMove=function(x,E){if(E.If()&&E instanceof Ln&&E._buttonFillPressed!==null){var b=x.diagram;if(b.firstInput.button===0&&(b.currentTool.standardMouseOver(),a(x,E)&&(x=E.fb("ButtonBorder"),x instanceof Dr))){var z=b.skipsUndoManager;b.skipsUndoManager=!0;var ee=E._buttonFillPressed;x.fill!==ee&&(x.fill=ee),ee=E._buttonStrokePressed,x.stroke!==ee&&(x.stroke=ee),b.skipsUndoManager=z}}},y}),Sd("TreeExpanderButton",function(){var a=Th("Button",{_treeExpandedFigure:"MinusLine",_treeCollapsedFigure:"PlusLine"},Th(Dr,{name:"ButtonIcon",figure:"MinusLine",stroke:"#424242",strokeWidth:2,desiredSize:Ia},new Hs("figure","isTreeExpanded",function(y,x){return x=x.panel,y?x._treeExpandedFigure:x._treeCollapsedFigure}).cp()),{visible:!1},new Hs("visible","isTreeLeaf",function(y){return!y}).cp());return a.click=function(y,x){if(x=x.part,x instanceof Fo&&(x=x.adornedPart),x instanceof qn){var E=x.diagram;if(E!==null){if(E=E.commandHandler,x.isTreeExpanded){if(!E.canCollapseTree(x))return}else if(!E.canExpandTree(x))return;y.handled=!0,x.isTreeExpanded?E.collapseTree(x):E.expandTree(x)}}},a}),Sd("SubGraphExpanderButton",function(){var a=Th("Button",{_subGraphExpandedFigure:"MinusLine",_subGraphCollapsedFigure:"PlusLine"},Th(Dr,{name:"ButtonIcon",figure:"MinusLine",stroke:"#424242",strokeWidth:2,desiredSize:Ia},new Hs("figure","isSubGraphExpanded",function(y,x){return x=x.panel,y?x._subGraphExpandedFigure:x._subGraphCollapsedFigure}).cp()));return a.click=function(y,x){if(x=x.part,x instanceof Fo&&(x=x.adornedPart),x instanceof xr){var E=x.diagram;if(E!==null){if(E=E.commandHandler,x.isSubGraphExpanded){if(!E.canCollapseSubGraph(x))return}else if(!E.canExpandSubGraph(x))return;y.handled=!0,x.isSubGraphExpanded?E.collapseSubGraph(x):E.expandSubGraph(x)}}},a}),Sd("ToolTip",function(){return Th(Fo,Ln.Auto,{isShadowed:!0,shadowColor:"rgba(0, 0, 0, .4)",shadowOffset:new Qe(0,3),shadowBlur:5},Th(Dr,{name:"Border",figure:"RoundedRectangle",parameter1:1,parameter2:1,fill:"#F5F5F5",stroke:"#F0F0F0",spot1:new Bi(0,0,4,6),spot2:new Bi(1,1,-4,-4)}))}),Sd("ContextMenu",function(){return Th(Fo,Ln.Vertical,{background:"#F5F5F5",isShadowed:!0,shadowColor:"rgba(0, 0, 0, .4)",shadowOffset:new Qe(0,3),shadowBlur:5},new Hs("background","",function(a){return a.adornedPart!==null&&a.placeholder!==null?null:"#F5F5F5"}))}),Sd("ContextMenuButton",function(){var a=Th("Button");a.stretch=Mi;var y=a.fb("ButtonBorder");return y instanceof Dr&&(y.figure="Rectangle",y.strokeWidth=0,y.spot1=new Bi(0,0,2,3),y.spot2=new Bi(1,1,-2,-2)),a}),Sd("PanelExpanderButton",function(a){var y=dm(a,"COLLAPSIBLE"),x=Th("Button",{_buttonExpandedFigure:"M0 0 M0 6 L4 2 8 6 M8 8",_buttonCollapsedFigure:"M0 0 M0 2 L4 6 8 2 M8 8",_buttonFillNormal:"rgba(0, 0, 0, 0)",_buttonStrokeNormal:null,_buttonFillOver:"rgba(0, 0, 0, .2)",_buttonStrokeOver:null,_buttonFillPressed:"rgba(0, 0, 0, .4)",_buttonStrokePressed:null},Th(Dr,{name:"ButtonIcon",strokeWidth:2},new Hs("geometryString","visible",function(E){return E?x._buttonExpandedFigure:x._buttonCollapsedFigure}).cp(y)));return a=x.fb("ButtonBorder"),a instanceof Dr&&(a.stroke=null,a.fill="rgba(0, 0, 0, 0)"),x.click=function(E,b){var z=b.diagram;if(z!==null&&!z.isReadOnly){var ee=b.ih();ee===null&&(ee=b.part),ee!==null&&(b=ee.fb(y),b!==null&&(E.handled=!0,z.Ea("Collapse/Expand Panel"),b.visible=!b.visible,z.eb("Collapse/Expand Panel")))}},x}),Sd("CheckBoxButton",function(a){var y=dm(a);return a=Th("Button",{desiredSize:new fn(14,14)},Th(Dr,{name:"ButtonIcon",geometryString:"M0 0 M0 8.85 L4.9 13.75 16.2 2.45 M16.2 16.2",strokeWidth:2,stretch:Cn,geometryStretch:xi,visible:!1},y!==""?new Hs("visible",y).Kx():[])),a.click=function(x,E){if(E instanceof Ln){var b=x.diagram;if(!(b===null||b.isReadOnly||y!==""&&b.model.isReadOnly)){x.handled=!0;var z=E.fb("ButtonIcon");b.Ea("checkbox"),z.visible=!z.visible,typeof E._doClick=="function"&&E._doClick(x,E),b.eb("checkbox")}}},a}),Sd("CheckBox",function(a){a=dm(a),a=Th("CheckBoxButton",a,{name:"Button",isActionable:!1,margin:new vr(0,1,0,0)});var y=Th(Ln,"Horizontal",a,{isActionable:!0,cursor:a.cursor,margin:new vr(1),_buttonFillNormal:a._buttonFillNormal,_buttonStrokeNormal:a._buttonStrokeNormal,_buttonFillOver:a._buttonFillOver,_buttonStrokeOver:a._buttonStrokeOver,_buttonFillPressed:a._buttonFillPressed,_buttonStrokePressed:a._buttonStrokePressed,_buttonFillDisabled:a._buttonFillDisabled,mouseEnter:a.mouseEnter,mouseLeave:a.mouseLeave,actionDown:a.actionDown,actionUp:a.actionUp,actionCancel:a.actionCancel,actionMove:a.actionMove,click:a.click,_buttonClick:a.click});return a.mouseEnter=null,a.mouseLeave=null,a.actionDown=null,a.actionUp=null,a.actionCancel=null,a.actionMove=null,a.click=null,y}),mt.None=mn=new Vt(mt,"None",0),mt.Default=Cr=new Vt(mt,"Default",0),mt.Vertical=Yi=new Vt(mt,"Vertical",4),mt.Horizontal=Mi=new Vt(mt,"Horizontal",5),mt.Fill=Cn=new Vt(mt,"Fill",3),mt.Uniform=xi=new Vt(mt,"Uniform",1),mt.UniformToFill=ao=new Vt(mt,"UniformToFill",2),mt.FlipVertical=Gr=new Vt(mt,"FlipVertical",1),mt.FlipHorizontal=wo=new Vt(mt,"FlipHorizontal",2),mt.FlipBoth=ua=new Vt(mt,"FlipBoth",3),mt.make=Th,mt.getBuilders=function(){var a=new Li,y;for(y in gg)if(y!==y.toLowerCase()){var x=gg.I(y);typeof x=="function"&&a.add(y,x)}return a.freeze(),a},mt.defineBuilder=Sd,mt.build=function(a,y,x){for(var E=[],b=2;b<arguments.length;++b)E[b-2]=arguments[b];if(b=gg.I(a),typeof b=="function"&&(E=b([a].concat(E)),E instanceof mt))return y&&E.set(y),E;Dt('GraphObject.build invoked object builder "'+a+'", but it did not return an Object')},mt.takeBuilderArgument=dm;function Hf(){this.nc=!1,this.xa="",this.zp=-1,this.nb=this.wm=this.te=null,this.j="",this.hb=this.Di=this.Hb=this.Ch=this.$h=this.F=this.Ha=this.ia=this.V=this.Lh=this.Xd=this.Of=this.Nh=this.Oh=this.Qh=this.Ph=this.Mh=this.Bh=this.Fh=this.zh=null,this.u=jr,this.o=Vs,this.hg=Cr,this.ob=this.Bi=1,this.Pf=mn,this.Pc=this.Ci=this.gd=null,this.Oc="category"}Hf.prototype.copy=function(){var a=new Hf;return a.xa=this.xa,a.zp=this.zp,a.te=this.te,a.nb=this.nb,a.j=this.j,a.zh=this.zh,a.Fh=this.Fh,a.Bh=this.Bh,a.Mh=this.Mh,a.Ph=this.Ph,a.Qh=this.Qh,a.Oh=this.Oh,a.Nh=this.Nh,a.Of=this.Of,a.Xd=this.Xd,a.Lh=this.Lh,a.V=this.V,a.ia=this.ia,a.Ha=this.Ha,a.F=this.F,a.$h=this.$h,a.Ch=this.Ch,a.Hb=this.Hb,a.Di=this.Di,a.hb=this.hb,a.u=this.u.J(),a.o=this.o.J(),a.hg=this.hg,a.Bi=this.Bi,a.ob=this.ob,a.Pf=this.Pf,a.gd=this.gd,a.Ci=this.Ci,a.Pc=this.Pc,a.Oc=this.Oc,a};function Wd(){this.u=-1/0,this.o=0,this.F=bs,this.rr=Pu,this.j=this.V="None"}Wd.prototype.copy=function(){var a=new Wd;return a.u=this.u,a.o=this.o,a.F=this.F.J(),a.rr=this.rr,a.V=this.V,a.j=this.j,a},Wd.className="LinkElementSettings";function up(){this.yj=this.Xi=vs,this.xj=this.Wi=this.wj=this.Vi=NaN,this.Tr=this.hq=null,this.Ur=this.iq=1/0}up.prototype.copy=function(){var a=new up;return a.Xi=this.Xi.J(),a.yj=this.yj.J(),a.Vi=this.Vi,a.wj=this.wj,a.Wi=this.Wi,a.xj=this.xj,a.hq=this.hq,a.Tr=this.Tr,a.iq=this.iq,a.Ur=this.Ur,a},up.className="LinkSettings";function vf(){this.ha=[1,0,0,1,0,0]}vf.prototype.copy=function(){var a=new vf;return a.ha[0]=this.ha[0],a.ha[1]=this.ha[1],a.ha[2]=this.ha[2],a.ha[3]=this.ha[3],a.ha[4]=this.ha[4],a.ha[5]=this.ha[5],a},vf.prototype.translate=function(a,y){this.ha[4]+=this.ha[0]*a+this.ha[2]*y,this.ha[5]+=this.ha[1]*a+this.ha[3]*y},vf.prototype.scale=function(a,y){this.ha[0]*=a,this.ha[1]*=a,this.ha[2]*=y,this.ha[3]*=y},vf.prototype.rotate=function(a,y,x){if(360<=a?a-=360:0>a&&(a+=360),a!==0){if(this.translate(y,x),a===90){a=0;var E=1}else a===180?(a=-1,E=0):a===270?(a=0,E=-1):(E=a*Math.PI/180,a=Math.cos(E),E=Math.sin(E));var b=this.ha[1]*a+this.ha[3]*E,z=this.ha[0]*-E+this.ha[2]*a,ee=this.ha[1]*-E+this.ha[3]*a;this.ha[0]=this.ha[0]*a+this.ha[2]*E,this.ha[1]=b,this.ha[2]=z,this.ha[3]=ee,this.translate(-y,-x)}},vf.className="STransform";function Gf(a){this.type=a,this.r2=this.y2=this.x2=this.r1=this.y1=this.x1=0,this.gx=[],this.pattern=null}Gf.prototype.addColorStop=function(a,y){this.gx.push({offset:a,color:y})},Gf.className="SGradient";function Fc(a,y,x){this.ownerDocument=a=y===void 0?Kt.document:y,this.cA="http://www.w3.org/2000/svg",a!==void 0&&(this.Oa=this.Ud("svg",{width:"1px",height:"1px",viewBox:"0 0 1 1"}),this.style.display="block",this.style.letterSpacing="normal",this.style.wordSpacing="normal",this.Oa.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns","http://www.w3.org/2000/svg"),this.Oa.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink","http://www.w3.org/1999/xlink")),this.hs=null,this.context=new th(this,x)}Fc.prototype.resize=function(a,y,x,E){return this.width!==a||this.height!==y?(this.width=a,this.height=y,this.style.width=x+"px",this.style.height=E+"px",this.Oa.setAttributeNS(null,"width",x+"px"),this.Oa.setAttributeNS(null,"height",E+"px"),this.Oa.setAttributeNS(null,"viewBox","0 0 "+x+" "+E),this.context.ww.firstElementChild.setAttributeNS(null,"width",x+"px"),this.context.ww.firstElementChild.setAttributeNS(null,"height",E+"px"),!0):!1},Fc.prototype.Ud=function(a,y,x){if(a=this.ownerDocument.createElementNS(this.cA,a),kn(y))for(var E in y)a.setAttributeNS(E==="href"?"http://www.w3.org/1999/xlink":"",E,y[E]);return x!==void 0&&(a.textContent=x),a},Fc.prototype.getBoundingClientRect=function(){return this.Oa.getBoundingClientRect()},Fc.prototype.focus=function(){this.Oa.focus()},Fc.prototype.mx=function(){this.ownerDocument=null},Yt.Object.defineProperties(Fc.prototype,{width:{get:function(){return this.Oa.width.baseVal.value},set:function(a){this.Oa.setAttribute("width",a+"px")}},height:{get:function(){return this.Oa.height.baseVal.value},set:function(a){this.Oa.setAttribute("height",a+"px")}},style:{get:function(){return this.Oa.style}}}),Fc.className="SVGSurface";function th(a,y){this.Gv=a,this.svg=a.Oa,this.stack=[],this.nh=[],this.fillStyle="#000000",this.font="10px sans-serif",this.globalAlpha=1,this.lineCap="butt",this.lineDashOffset=0,this.lineJoin="miter",this.lineWidth=1,this.miterLimit=10,this.shadowBlur=0,this.shadowColor="rgba(0, 0, 0, 0)",this.shadowOffsetY=this.shadowOffsetX=0,this.Il=!1,this.strokeStyle="#000000",this.textAlign="start",this.clipInsteadOfFill=!1,this.Vg=this.Br=this.Ar=0,this.yd=this.ad=null,this.path=[],this.Yl={},this.Ct=!1,this.Yg=null,this.uj=0,this.rb=new vf,this.j=fm(this),this.Nj=fm(this,"gojs-diagram"),this.Hl=this.ti=null;var x=bl++,E=this.Ud("clipPath",{id:"mainClip"+x});E.appendChild(this.Ud("rect",{x:0,y:0,width:a.width,height:a.height})),this.ww=E,this.svg.appendChild(this.j),this.j.appendChild(this.Nj),this.svg.appendChild(E),this.j.setAttributeNS(null,"clip-path","url(#mainClip"+x+")"),this.eA={},this.isTemporary=!!y,this.filter="",this.bk=null}function Yy(a,y,x,E,b,z,ee){a.Nj===void 0?hp(a,y,x,E,b,z,ee):a.Nj.setAttribute("transform","matrix("+y+", "+x+", "+E+", "+b+", "+z+", "+ee+")")}we=th.prototype,we.arc=function(a,y,x,E,b,z,ee,re){var oe=2*Math.PI,se=oe-1e-6,ue=x*Math.cos(E),fe=x*Math.sin(E),ve=a+ue,ye=y+fe,Ce=z?0:1;E=z?E-b:b-E,(1e-6<Math.abs(ee-ve)||1e-6<Math.abs(re-ye))&&this.path.push(["L",ve,+ye]),0>E&&(E=E%oe+oe),E>se?(this.path.push(["A",x,x,0,1,Ce,a-ue,y-fe]),this.path.push(["A",x,x,0,1,Ce,ve,ye])):1e-6<E&&this.path.push(["A",x,x,0,+(E>=Math.PI),Ce,a+x*Math.cos(b),y+x*Math.sin(b)])},we.beginPath=function(){this.path=[],this.Yl={stroke:"none",fill:"none"}},we.Se=function(a){this.addPath(this.path,this.rb,a||0)},we.bezierCurveTo=function(a,y,x,E,b,z){this.path.push(["C",a,y,x,E,b,z])},we.clearRect=function(){},we.clip=function(){this.Yl.clipPath=!0},we.closePath=function(){this.path.push(["z"])},we.createLinearGradient=function(a,y,x,E){var b=new Gf("linear");return b.x1=a,b.y1=y,b.x2=x,b.y2=E,b},we.createPattern=function(a){var y="";a instanceof HTMLCanvasElement&&(y=a.toDataURL()),a instanceof HTMLImageElement&&(y=a.getAttribute("src"));var x=this.eA;if(x[y])return"url(#"+x[y]+")";var E="PATTERN"+bl++,b={x:0,y:0,width:a.width,height:a.height,href:y};return a=this.Ud("pattern",{width:a.width,height:a.height,id:E,patternUnits:"userSpaceOnUse"}),a.appendChild(this.Ud(gf,b)),this.svg.appendChild(a),x[y]=E,"url(#"+E+")"},we.createRadialGradient=function(a,y,x,E,b,z){var ee=new Gf("radial");return ee.x1=a,ee.y1=y,ee.r1=x,ee.x2=E,ee.y2=b,ee.r2=z,ee};function Xy(a,y,x,E,b,z,ee,re,oe){E=re/E,b=oe/b,z===0&&ee===0||a.rb.translate(z,ee),E===1&&b===1||a.rb.scale(E,b),y===0&&x===0||a.rb.translate(-y,-x)}we.drawImage=function(a,y,x,E,b,z,ee,re,oe){var se="";a instanceof HTMLCanvasElement&&(se=a.toDataURL()),a instanceof HTMLImageElement&&(se=a.getAttribute("src"));var ue=a instanceof HTMLImageElement?a.naturalWidth:a.width;a=a instanceof HTMLImageElement?a.naturalHeight:a.height,E===void 0&&(z=y,ee=x,re=E=ue,oe=b=a),E=E||0,b=b||0,re=re||0,oe=oe||0,Xy(this,y,x,E,b,z||0,ee||0,re,oe),z={x:0,y:0,width:ue||E,height:a||b,href:se},yt.$(E,re)&&yt.$(b,oe)?se.toLowerCase().indexOf(".svg")===-1&&se.toLowerCase().indexOf("data:image/svg")===-1&&(z.preserveAspectRatio="xMidYMid slice"):z.preserveAspectRatio="none",(y!==0||x!==0||E!==ue||b!==a)&&(E+=y,b+=x,z["clip-path"]="path('M "+y+","+x+" L "+E+" "+x+" L "+E+" "+b+" L "+y+" "+b+" z')"),pg(this,gf,z,this.rb),this.addElement(gf,z)},we.fill=function(a){a&&(this.Yl["fill-rule"]="evenodd"),i0(this,this.Yl)},we.ng=function(a,y){this.clipInsteadOfFill?this.clip():this.fill(y)},we.fillRect=function(a,y,x,E){a=[a,y,x,E],a={x:a[0],y:a[1],width:a[2],height:a[3]},pg(this,"fill",a,this.rb),this.addElement("rect",a)},we.ox=function(a,y,x,E){a={x:a,y,width:x,height:E},pg(this,"fill",a,this.rb),i0(this,a),this.svg.prepend(this.Ud("rect",a))},we.fillText=function(a,y,x){a=[a,y,x],y=this.textAlign,y==="left"?y="start":y==="right"?y="end":y==="center"&&(y="middle"),y={x:a[1],y:a[2],style:"font: "+this.font,"text-anchor":y},pg(this,"fill",y,this.rb),this.addElement("text",y,a[0])},we.lineTo=function(a,y){this.path.push(["L",a,y])},we.moveTo=function(a,y){this.path.push(["M",a,y])},we.quadraticCurveTo=function(a,y,x,E){this.path.push(["Q",a,y,x,E])},we.rect=function(a,y,x,E){this.path.push(["M",a,y],["L",a+x,y],["L",a+x,y+E],["L",a,y+E],["z"])},we.restore=function(){this.rb=this.stack.pop(),this.path=this.stack.pop();var a=this.stack.pop();this.fillStyle=a.fillStyle,this.font=a.font,this.globalAlpha=a.globalAlpha,this.lineCap=a.lineCap,this.lineDashOffset=a.lineDashOffset,this.lineJoin=a.lineJoin,this.lineWidth=a.lineWidth,this.miterLimit=a.miterLimit,this.shadowBlur=a.shadowBlur,this.shadowColor=a.shadowColor,this.shadowOffsetX=a.shadowOffsetX,this.shadowOffsetY=a.shadowOffsetY,this.strokeStyle=a.strokeStyle,this.textAlign=a.textAlign,this.bk=a.bk},we.save=function(){this.stack.push({fillStyle:this.fillStyle,font:this.font,globalAlpha:this.globalAlpha,lineCap:this.lineCap,lineDashOffset:this.lineDashOffset,lineJoin:this.lineJoin,lineWidth:this.lineWidth,miterLimit:this.miterLimit,shadowBlur:this.shadowBlur,shadowColor:this.shadowColor,shadowOffsetX:this.shadowOffsetX,shadowOffsetY:this.shadowOffsetY,strokeStyle:this.strokeStyle,textAlign:this.textAlign,bk:this.bk});for(var a=[],y=0;y<this.path.length;y++)a.push(this.path[y]);this.stack.push(a),this.stack.push(this.rb.copy())},we.setTransform=function(a,y,x,E,b,z){a===1&&y===0&&x===0&&E===1&&b===0&&z===0||hp(this,a,y,x,E,b,z)};function Jy(a){return a=a.rb.ha,"matrix("+a[0]+", "+a[1]+", "+a[2]+", "+a[3]+", "+a[4]+", "+a[5]+")"}we.scale=function(a,y){this.rb.scale(a,y)},we.translate=function(a,y){this.rb.translate(a,y)},we.transform=function(){},we.yc=function(){},we.stroke=function(){qy(this,this.Yl)},we.jk=function(){this.clipInsteadOfFill||this.stroke()},we.Ud=function(a,y,x){return this.Gv.Ud(a,y,x)},we.addElement=function(a,y,x){return a=this.Ud(a,y,x),this.yd!==null?this.yd.appendChild(a):this.yd=a,this.ad=a};function pg(a,y,x,E){y==="fill"?i0(a,x):y==="stroke"&&qy(a,x),E!==null&&(a=E.ha,x.transform="matrix("+a[0]+", "+a[1]+", "+a[2]+", "+a[3]+", "+a[4]+", "+a[5]+")")}function i0(a,y){a.fillStyle instanceof Gf?y.fill=r0(a,a.fillStyle,!0):/^rgba\(/.test(a.fillStyle)?(a=/^\s*rgba\s*\(([^,\s]+)\s*,\s*([^,\s]+)\s*,\s*([^,\s]+)\s*,\s*([^,\s]+)\)\s*$/i.exec(a.fillStyle),y.fill="rgb("+a[1]+","+a[2]+","+a[3]+")",y["fill-opacity"]=a[4]):y.fill=a.fillStyle}function Qy(a,y,x){x=x?"fill":"stroke",a.fillStyle instanceof Gf?y.setAttributeNS(null,"fill",r0(a,a.fillStyle,!0)):/^rgba\(/.test(a.fillStyle)?(a=/^\s*rgba\s*\(([^,\s]+)\s*,\s*([^,\s]+)\s*,\s*([^,\s]+)\s*,\s*([^,\s]+)\)\s*$/i.exec(a.fillStyle),y.setAttributeNS(null,x,"rgb("+a[1]+","+a[2]+","+a[3]+")"),y.setAttributeNS(null,x+"-opacity",a[4])):y.setAttributeNS(null,x,a.fillStyle)}function qy(a,y){if(a.strokeStyle instanceof Gf)y.stroke=r0(a,a.strokeStyle,!1);else if(/^rgba\(/.test(a.strokeStyle)){var x=/^\s*rgba\s*\(([^,\s]+)\s*,\s*([^,\s]+)\s*,\s*([^,\s]+)\s*,\s*([^,\s]+)\)\s*$/i.exec(a.strokeStyle);y.stroke="rgb("+x[1]+","+x[2]+","+x[3]+")",y["stroke-opacity"]=x[4]}else y.stroke=a.strokeStyle;y["stroke-width"]=a.lineWidth,y["stroke-linecap"]=a.lineCap,y["stroke-linejoin"]=a.lineJoin,y["stroke-miterlimit"]=a.miterLimit,a.Ct&&(y["stroke-dasharray"]=a.Yg.toString(),y["stroke-dashoffset"]=a.uj)}function r0(a,y,x){var E="";if(E=a.Hl!==null?a.Hl.getAttribute(x?"fill":"stroke"):null,E!==null&&E.indexOf("GRAD")!==-1?(E=E.split("#")[1].slice(0,-1),x=a.svg.getElementById(E),x!==null&&x.remove()):E="GRAD"+bl++,y.type==="linear")x=a.Ud("linearGradient",{x1:y.x1,x2:y.x2,y1:y.y1,y2:y.y2,id:E,gradientUnits:"userSpaceOnUse"});else if(y.type==="radial")x=a.Ud("radialGradient",{x1:y.x1,x2:y.x2,y1:y.y1,y2:y.y2,r1:y.r1,r2:y.r2,id:E});else throw Error("invalid gradient");var b=y.gx;y=b.length;for(var z=[],ee=0;ee<y;ee++){var re=b[ee],oe=re.color;re={offset:re.offset,"stop-color":oe},/^rgba\(/.test(oe)&&(oe=/^\s*rgba\s*\(([^,\s]+)\s*,\s*([^,\s]+)\s*,\s*([^,\s]+)\s*,\s*([^,\s]+)\)\s*$/i.exec(oe),re["stop-color"]="rgb("+oe[1]+","+oe[2]+","+oe[3]+")",re["stop-opacity"]=oe[4]),z.push(re)}for(z.sort(function(se,ue){return se.offset>ue.offset?1:-1}),b=0;b<y;b++)x.appendChild(a.Ud("stop",z[b]));return a.svg.appendChild(x),"url(#"+E+")"}we.addPath=function(a,y,x){for(var E=[],b=0;b<a.length;b++){var z=Lo(a[b]),ee=[z.shift()];if(ee[0]==="A")ee.push(z.shift()+","+z.shift(),z.shift(),z.shift()+","+z.shift(),z.shift()+","+z.shift());else for(;z.length;)ee.push(z.shift()+","+z.shift());E.push(ee.join(" "))}if(E=E.join(" "),a=this.Yl,a.clipPath)0<this.nh.length&&this.nh[this.nh.length-1].setAttributeNS(null,"clip-path",'path("'+E+'")');else if(a.d=E,pg(this,"",a,y),this.Hl!==null)if(y=this.Hl,y.nodeName!=="g")for(var re in a)re!=="transform"&&y.setAttributeNS(null,re,a[re]);else{re=y.getElementsByTagName("path");for(var oe in a)oe!=="transform"&&re[x].setAttributeNS(null,oe,a[oe])}else this.addElement("path",a)};function hp(a,y,x,E,b,z,ee){var re=new vf;re.ha=[y,x,E,b,z,ee],y={},pg(a,"g",y,re),re=a.addElement("g",y),a.nh.push(re)}function fm(a,y){var x={};return y&&(x.class=y),y=a.addElement("g",x),a.nh.push(y),y}we.Ev=function(a,y,x){this.Ar=a,this.Br=y,this.Vg=x};function Gc(a){a.Il=!1,a.shadowOffsetX=0,a.shadowOffsetY=0,a.shadowBlur=0}function id(a){a.Il=!0,a.shadowOffsetX=a.Ar,a.shadowOffsetY=a.Br,a.shadowBlur=a.Vg}we.js=function(a,y){this.Ct=!0,this.Yg=a,this.uj=y},we.fs=function(){this.Ct=!1},we.Vc=function(){},we.Wx=function(){},th.prototype.rotate=function(a){this.rb.rotate(57.2958*a,0,0)},th.prototype.getImageData=function(){return null},th.prototype.measureText=function(){return null};function gm(a,y){y=y.getAttribute("fill"),y!==null&&(y=y.split("#"),y.length!==1&&(y=a.svg.getElementById(y[1].slice(0,-1)),y!==null&&a.svg.innerHTML.match(new RegExp(y.id,"g")).length===1&&y.remove()))}th.prototype.Hs=function(a){a.svg!==null&&a.svg.parentNode===this.Nj&&a.svg.remove()},th.className="SVGContext",bt.prototype.Cs=function(a){this.pj.contains("SVG")||this.bs("SVG",new Fc(this,Kt.document));var y=new Fc(this,Kt.document,!0);a===void 0&&(a=new Er);var x=this;return Bf(this,function(E,b){return E=lm(x,E,"SVG",y),E=E!==null?E.svg:null,typeof b=="function"?(b(E),null):E},a)},bt.prototype.makeSvg=bt.prototype.Cs,bt.prototype.av=function(a){return this.Cs(a)},bt.prototype.makeSVG=bt.prototype.av;function Zh(a,y,x,E){this.ownerDocument=y=y===void 0?Kt.document:y,this.hs=null,y=y.createElement("canvas"),y.tabIndex=0,this.Oa=y,this.context=new yf(y,x,E),y.H=a}Zh.prototype.resize=function(a,y,x,E){return this.width!==a||this.height!==y?(this.width=a,this.height=y,this.style.width=x+"px",this.style.height=E+"px",!0):!1},Zh.prototype.toDataURL=function(a,y){return this.Oa.toDataURL(a,y)},Zh.prototype.getBoundingClientRect=function(){return this.Oa.getBoundingClientRect()},Zh.prototype.focus=function(){this.Oa.focus()},Zh.prototype.mx=function(){this.ownerDocument=this.Oa.H=null},Yt.Object.defineProperties(Zh.prototype,{width:{get:function(){return this.Oa.width},set:function(a){this.Oa.width=a}},height:{get:function(){return this.Oa.height},set:function(a){this.Oa.height=a}},style:{get:function(){return this.Oa.style}}}),Zh.className="CanvasSurface";function yf(a,y,x){this.Z=a.getContext?a.getContext("2d",y):null,this.Z===null&&Dt("Browser does not support HTML Canvas Element"),this.ct=this.et=this.dt="",this.Hm=!1,this.Vg=this.Br=this.Ar=0,this.Il=!1,this.El=new kr,this.isTemporary=!!x}we=yf.prototype,we.Wx=function(a){this.Z.imageSmoothingEnabled=a},we.arc=function(a,y,x,E,b,z){this.Z.arc(a,y,x,E,b,z)},we.beginPath=function(){this.Z.beginPath()},we.Se=function(){},we.bezierCurveTo=function(a,y,x,E,b,z){this.Z.bezierCurveTo(a,y,x,E,b,z)},we.clearRect=function(a,y,x,E){this.yc(),this.Z.clearRect(a,y,x,E)},we.clip=function(){this.Z.clip()},we.closePath=function(){this.Z.closePath()},we.createLinearGradient=function(a,y,x,E){return this.Z.createLinearGradient(a,y,x,E)},we.createPattern=function(a,y){return this.Z.createPattern(a,y)},we.createRadialGradient=function(a,y,x,E,b,z){return this.Z.createRadialGradient(a,y,x,E,b,z)},we.drawImage=function(a,y,x,E,b,z,ee,re,oe){E===void 0?this.Z.drawImage(a,y,x):this.Z.drawImage(a,y,x,E,b,z,ee,re,oe)},we.fill=function(a){this.Z.fill(a?"evenodd":"nonzero")},we.fillRect=function(a,y,x,E){this.Z.fillRect(a,y,x,E)},we.ox=function(a,y,x,E){this.Z.fillRect(a,y,x,E)},we.fillText=function(a,y,x){this.Z.fillText(a,y,x)},we.getImageData=function(a,y,x,E){return this.Z.getImageData(a,y,x,E)},we.lineTo=function(a,y){this.Z.lineTo(a,y)},we.measureText=function(a){return this.Z.measureText(a)},we.moveTo=function(a,y){this.Z.moveTo(a,y)},we.quadraticCurveTo=function(a,y,x,E){this.Z.quadraticCurveTo(a,y,x,E)},we.rect=function(a,y,x,E){this.Z.rect(a,y,x,E)},we.restore=function(){this.Z.restore()},we.save=function(){this.yc(),this.Z.save()},yf.prototype.rotate=function(a){this.El.rotate(57.2958*a,0,0)},we=yf.prototype,we.setTransform=function(a,y,x,E,b,z){this.El.setTransform(a,y,x,E,b,z)},we.scale=function(a,y){this.El.scale(a,y)},we.translate=function(a,y){this.El.translate(a,y)},we.stroke=function(){this.Z.stroke()},we.transform=function(a,y,x,E,b,z){if(a!==1||y!==0||x!==0||E!==1||b!==0||z!==0){var ee=this.El,re=ee.m11*a+ee.m21*y;a=ee.m12*a+ee.m22*y,y=ee.m11*x+ee.m21*E,x=ee.m12*x+ee.m22*E,ee.dx=ee.m11*b+ee.m21*z+ee.dx,ee.dy=ee.m12*b+ee.m22*z+ee.dy,ee.m11=re,ee.m12=a,ee.m21=y,ee.m22=x}},we.yc=function(){var a=this.El;this.Z.setTransform(a.m11,a.m12,a.m21,a.m22,a.dx,a.dy)},we.ng=function(a,y){if(a instanceof ia&&a.type===Dh){var x=a.yk;a=a.ft,a>x?(this.scale(x/a,1),this.translate((a-x)/2,0)):x>a&&(this.scale(1,a/x),this.translate(0,(x-a)/2)),this.Hm?this.clip():this.fill(y),a>x?(this.translate(-(a-x)/2,0),this.scale(1/(x/a),1)):x>a&&(this.translate(0,-(x-a)/2),this.scale(1,1/(a/x)))}else this.Hm?this.clip():this.fill(y)},we.jk=function(){this.Hm||this.stroke()},we.Ev=function(a,y,x){this.Ar=a,this.Br=y,this.Vg=x},we.js=function(a,y){var x=this.Z;x.setLineDash!==void 0&&(x.setLineDash(a),x.lineDashOffset=y)},we.fs=function(){var a=this.Z;a.setLineDash!==void 0&&(a.setLineDash(mx),a.lineDashOffset=0)},we.Vc=function(a){a&&(this.dt=""),this.ct=this.et=""},we.Hs=function(){},Yt.Object.defineProperties(yf.prototype,{fillStyle:{get:function(){return this.Z.fillStyle},set:function(a){this.ct!==a&&(this.ct=this.Z.fillStyle=a)}},font:{get:function(){return this.Z.font},set:function(a){this.dt!==a&&(this.dt=this.Z.font=a)}},globalAlpha:{get:function(){return this.Z.globalAlpha},set:function(a){this.Z.globalAlpha=a}},lineCap:{get:function(){return this.Z.lineCap},set:function(a){this.Z.lineCap=a}},lineDashOffset:{get:function(){return this.Z.lineDashOffset},set:function(a){this.Z.lineDashOffset=a}},lineJoin:{get:function(){return this.Z.lineJoin},set:function(a){this.Z.lineJoin=a}},lineWidth:{get:function(){return this.Z.lineWidth},set:function(a){this.Z.lineWidth=a}},miterLimit:{get:function(){return this.Z.miterLimit},set:function(a){this.Z.miterLimit=a}},shadowBlur:{get:function(){return this.Z.shadowBlur},set:function(a){this.Z.shadowBlur=a}},shadowColor:{get:function(){return this.Z.shadowColor},set:function(a){this.Z.shadowColor=a}},shadowOffsetX:{get:function(){return this.Z.shadowOffsetX},set:function(a){this.Z.shadowOffsetX=a}},shadowOffsetY:{get:function(){return this.Z.shadowOffsetY},set:function(a){this.Z.shadowOffsetY=a}},strokeStyle:{get:function(){return this.Z.strokeStyle},set:function(a){this.et!==a&&(this.et=this.Z.strokeStyle=a)}},textAlign:{get:function(){return this.Z.textAlign},set:function(a){this.Z.textAlign=a}},imageSmoothingEnabled:{get:function(){return this.Z.imageSmoothingEnabled},set:function(a){this.Z.imageSmoothingEnabled=a}},filter:{get:function(){return this.Z.filter},set:function(a){this.Z.filter=a===""?"none":a}},clipInsteadOfFill:{get:function(){return this.Hm},set:function(a){this.Hm=a}}});var mx=Object.freeze([]);yf.className="CanvasSurfaceContext";function cp(){this.F=this.o=this.u=this.j=0}cp.className="ColorNumbers";function ia(a,y){Sg||(h0(),Sg=!0),jo(this),this._isFrozen=!1,a===void 0?(this.na=xd,this.xk="black"):typeof a=="string"?(this.na=xd,this.xk=a):(this.na=a,this.xk="black"),a=this.na,a===od?(this.Qd=_l,this.Lk=yl):this.Lk=a===Dh?this.Qd=ko:this.Qd=Ms,this.Gr=0,this.Xp=NaN,this.xe=this.cr=this.we=null,this.ft=this.yk=0,y&&Object.assign(this,y)}ia.prototype.copy=function(){var a=new ia;return a.na=this.na,a.xk=this.xk,a.Qd=this.Qd.J(),a.Lk=this.Lk.J(),a.Gr=this.Gr,a.Xp=this.Xp,this.we!==null&&(a.we=this.we.copy()),a.cr=this.cr,a},we=ia.prototype,we.freeze=function(){return this._isFrozen=!0,this.we!==null&&this.we.freeze(),this},we.ka=function(){return Object.isFrozen(this)&&Dt("cannot thaw constant: "+this),this._isFrozen=!1,this.we!==null&&this.we.ka(),this},we.qb=function(a){a.classType===ia&&(this.type=a)},we.toString=function(){var a="Brush(";if(this.type===xd)a+=this.color;else if(a=this.type===od?a+"Linear ":this.type===Dh?a+"Radial ":this.type===xg?a+"Pattern ":a+"(unknown) ",a+=this.start+" "+this.end,this.colorStops!==null)for(var y=this.colorStops.iterator;y.next();)a+=" "+y.key+":"+y.value;return a+")"},we.addColorStop=function(a,y){return this._isFrozen&&wi(this),(typeof a!="number"||!isFinite(a)||1<a||0>a)&&gr(a,"0 <= loc <= 1",ia,"addColorStop:loc"),this.we===null&&(this.we=new Li),this.we.add(a,y),this.na===xd&&(this.type=od),this.xe=null,this},we.Vz=function(a,y){if(this._isFrozen&&wi(this),a=a===void 0||typeof a!="number"?.2:a,y=y===void 0?wg:y,this.type===xd)rd(this.color),this.color=vg(a,y);else if((this.type===od||this.type===Dh)&&this.colorStops!==null)for(var x=this.colorStops.iterator;x.next();)rd(x.value),this.addColorStop(x.key,vg(a,y));return this};function $y(a,y,x){return y=y===void 0||typeof y!="number"?.2:y,x=x===void 0?wg:x,rd(a),vg(y,x)}we.Wy=function(a,y){if(this._isFrozen&&wi(this),a=a===void 0||typeof a!="number"?.2:a,y=y===void 0?wg:y,this.type===xd)rd(this.color),this.color=vg(-a,y);else if((this.type===od||this.type===Dh)&&this.colorStops!==null)for(var x=this.colorStops.iterator;x.next();)rd(x.value),this.addColorStop(x.key,vg(-a,y));return this};function eS(a,y,x){return y=y===void 0||typeof y!="number"?.2:y,x=x===void 0?wg:x,rd(a),vg(-y,x)}function o0(a,y,x){rd(a),a=Ga.j;var E=Ga.u,b=Ga.o,z=Ga.F;return rd(y),x===void 0&&(x=.5),"rgba("+Math.round((Ga.j-a)*x+a)+", "+Math.round((Ga.u-E)*x+E)+", "+Math.round((Ga.o-b)*x+b)+", "+Math.round((Ga.F-z)*x+z)+")"}we.Gx=function(){if(this.type===xd)return mg(this.color);if((this.type===od||this.type===Dh)&&this.colorStops!==null){var a=this.colorStops;if(this.type===Dh)return mg(a.first().value);if(a.get(.5)!==null)return mg(a.get(.5));if(a.count===2)return a=a.Fa(),mg(o0(a[0].value,a[1].value));for(var y=a.iterator,x=-1,E=-1,b=1,z=1;y.next();){var ee=y.key,re=Math.abs(.5-y.key);b>z&&re<b?(x=ee,b=re):z>=b&&re<z&&(E=ee,z=re)}return x>E&&(z=x,x=E,E=z,z=b),b=E-x,mg(o0(a.get(x),a.get(E),1-z/b))}return!1};function mg(a){return a?a instanceof ia?a.Gx():(rd(a),128>(299*Ga.j+587*Ga.u+114*Ga.o)/1e3):!1}function vg(a,y){switch(y){case wg:y=100*s0(Ga.j);var x=100*s0(Ga.u),E=100*s0(Ga.o);return xu.j=.4124564*y+.3575761*x+.1804375*E,xu.u=.2126729*y+.7151522*x+.072175*E,xu.o=.0193339*y+.119192*x+.9503041*E,xu.F=Ga.F,y=u0(xu.j/yg[0]),x=u0(xu.u/yg[1]),E=u0(xu.o/yg[2]),Kc.j=116*x-16,Kc.u=500*(y-x),Kc.o=200*(x-E),Kc.F=xu.F,Kc.j=Math.min(100,Math.max(0,Kc.j+100*a)),a=(Kc.j+16)/116,y=a-Kc.o/200,xu.j=yg[0]*tS(Kc.u/500+a),xu.u=yg[1]*(Kc.j>pm*c0?Math.pow(a,3):Kc.j/pm),xu.o=yg[2]*tS(y),xu.F=Kc.F,a=-.969266*xu.j+1.8760108*xu.u+.041556*xu.o,y=.0556434*xu.j+-.2040259*xu.u+1.0572252*xu.o,Ga.j=255*l0((3.2404542*xu.j+-1.5371385*xu.u+-.4985314*xu.o)/100),Ga.u=255*l0(a/100),Ga.o=255*l0(y/100),Ga.F=xu.F,Ga.j=Math.round(Ga.j),255<Ga.j?Ga.j=255:0>Ga.j&&(Ga.j=0),Ga.u=Math.round(Ga.u),255<Ga.u?Ga.u=255:0>Ga.u&&(Ga.u=0),Ga.o=Math.round(Ga.o),255<Ga.o?Ga.o=255:0>Ga.o&&(Ga.o=0),"rgba("+Ga.j+", "+Ga.u+", "+Ga.o+", "+Ga.F+")";case nS:return a0(),mh.o=Math.min(100,Math.max(0,mh.o+100*a)),"hsla("+mh.j+", "+mh.u+"%, "+mh.o+"%, "+mh.F+")";default:Dt("Unknown color space: "+y)}}function rd(a){Sg||(h0(),Sg=!0);var y=d0;if(y!==null){y.clearRect(0,0,1,1),y.fillStyle="#000000";var x=y.fillStyle;y.fillStyle=a,y.fillStyle!==x?(y.fillRect(0,0,1,1),a=y.getImageData(0,0,1,1).data,Ga.j=a[0],Ga.u=a[1],Ga.o=a[2],Ga.F=a[3]/255):(y.fillStyle="#FFFFFF",y.fillStyle=a,Ga.j=0,Ga.u=0,Ga.o=0,Ga.F=1)}}function a0(){var a=Ga.j/255,y=Ga.u/255,x=Ga.o/255,E=Math.max(a,y,x),b=Math.min(a,y,x),z=E-b;if(b=(E+b)/2,z===0)var ee=a=0;else{switch(E){case a:ee=(y-x)/z%6;break;case y:ee=(x-a)/z+2;break;case x:ee=(a-y)/z+4}ee*=60,0>ee&&(ee+=360),a=z/(1-Math.abs(2*b-1))}mh.j=Math.round(ee),mh.u=Math.round(100*a),mh.o=Math.round(100*b),mh.F=Ga.F}function s0(a){return a/=255,.04045>=a?a/12.92:Math.pow((a+.055)/1.055,2.4)}function l0(a){return .0031308>=a?12.92*a:1.055*Math.pow(a,1/2.4)-.055}function u0(a){return a>c0?Math.pow(a,1/3):(pm*a+16)/116}function tS(a){var y=a*a*a;return y>c0?y:(116*a-16)/pm}function Kf(a,y){typeof a!="string"&&(a instanceof ia||Dt("Value for "+y+" must be a color string or a Brush, not "+a))}function h0(){d0=Es?new Zh(null,void 0,{willReadFrequently:!0}).context:null}Yt.Object.defineProperties(ia.prototype,{type:{get:function(){return this.na},set:function(a){this._isFrozen&&wi(this,a),this.na=a,this.start.Mc()&&(a===od?this.start=_l:a===Dh&&(this.start=ko)),this.end.Mc()&&(a===od?this.end=yl:a===Dh&&(this.end=ko)),this.xe=null}},color:{get:function(){return this.xk},set:function(a){this._isFrozen&&wi(this,a),this.xk=a,this.xe=null}},start:{get:function(){return this.Qd},set:function(a){this._isFrozen&&wi(this,a),this.Qd=a.J(),this.xe=null}},end:{get:function(){return this.Lk},set:function(a){this._isFrozen&&wi(this,a),this.Lk=a.J(),this.xe=null}},startRadius:{get:function(){return this.Gr},set:function(a){this._isFrozen&&wi(this,a),0>a&&gr(a,">= zero",ia,"startRadius"),this.Gr=a,this.xe=null}},endRadius:{get:function(){return this.Xp},set:function(a){this._isFrozen&&wi(this,a),0>a&&gr(a,">= zero",ia,"endRadius"),this.Xp=a,this.xe=null}},colorStops:{get:function(){return this.we},set:function(a){this._isFrozen&&wi(this,a),this.we=a,this.xe=null}},pattern:{get:function(){return this.cr},set:function(a){this._isFrozen&&wi(this,a),this.cr=a,this.xe=null}}}),ia.prototype.isDark=ia.prototype.Gx,ia.prototype.darkenBy=ia.prototype.Wy,ia.prototype.lightenBy=ia.prototype.Vz,ia.prototype.addColorStop=ia.prototype.addColorStop;var c0=216/24389,pm=24389/27,yg=[95.047,100,108.883],d0=null,Ga=new cp,mh=new cp,xu=new cp,Kc=new cp,Sg=!1;ia.className="Brush";var xd;ia.Solid=xd=new Vt(ia,"Solid",0);var od;ia.Linear=od=new Vt(ia,"Linear",1);var Dh;ia.Radial=Dh=new Vt(ia,"Radial",2);var xg;ia.Pattern=xg=new Vt(ia,"Pattern",4);var wg;ia.Lab=wg=new Vt(ia,"Lab",5);var nS;ia.HSL=nS=new Vt(ia,"HSL",6),ia.randomColor=function(a,y){a===void 0&&(a=128),y===void 0&&(y=Math.max(a,255));var x=Math.abs(y-a);y=Math.floor(a+Math.random()*x).toString(16);var E=Math.floor(a+Math.random()*x).toString(16);return a=Math.floor(a+Math.random()*x).toString(16),2>y.length&&(y="0"+y),2>E.length&&(E="0"+E),2>a.length&&(a="0"+a),"#"+y+E+a},ia.isValidColor=function(a){if(a==="black")return!0;if(a==="")return!1;Sg||(h0(),Sg=!0);var y=d0;if(y===null)return!0;y.fillStyle="#000000";var x=y.fillStyle;return y.fillStyle=a,y.fillStyle!==x?!0:(y.fillStyle="#FFFFFF",x=y.fillStyle,y.fillStyle=a,y.fillStyle!==x)},ia.lighten=function(a){return $y(a)},ia.lightenBy=$y,ia.darken=function(a){return eS(a)},ia.darkenBy=eS,ia.mix=o0,ia.isDark=mg;function qs(){this.xa="Base"}qs.prototype.measure=function(){},qs.prototype.Yz=function(a,y,x,E,b){a.measure(y,x,E,b)},qs.prototype.arrange=function(){},qs.prototype.Ly=function(a,y,x,E,b,z){a.arrange(y,x,E,b,z)},qs.prototype.iA=function(a){a.Uj()},qs.prototype.gc=function(){},Yt.Object.defineProperties(qs.prototype,{name:{get:function(){return this.xa},set:function(a){this.xa=a}},classType:{get:function(){return Ln}}}),qs.prototype.remeasureObject=qs.prototype.iA,qs.prototype.arrangeElement=qs.prototype.Ly,qs.prototype.measureElement=qs.prototype.Yz,qs.className="PanelLayout";function mm(){this.xa="Base"}Ct(mm,qs),mm.prototype.measure=function(a,y,x,E,b,z,ee){var re=E.length;a=ad(a);for(var oe=0;oe<re;oe++){var se=E[oe];if(se.visible||se===a){var ue=se.margin,fe=ue.right+ue.left;ue=ue.top+ue.bottom,se.measure(y,x,z,ee);var ve=se.measuredBounds;fe=Math.max(ve.width+fe,0),ue=Math.max(ve.height+ue,0),ve=se.position.x;var ye=se.position.y;isFinite(ve)||(ve=0),isFinite(ye)||(ye=0),se instanceof Dr&&se.isGeometryPositioned&&(se=se.strokeWidth/2,ve-=se,ye-=se),es(b,ve,ye,fe,ue)}}},mm.prototype.arrange=function(a,y,x){var E=y.length,b=a.padding;for(a=x.x-b.left,x=x.y-b.top,b=0;b<E;b++){var z=y[b],ee=z.measuredBounds,re=z.margin,oe=z.position.x,se=z.position.y;if(oe=isNaN(oe)?-a:oe-a,se=isNaN(se)?-x:se-x,z instanceof Dr&&z.isGeometryPositioned){var ue=z.strokeWidth/2;oe-=ue,se-=ue}z.visible&&z.arrange(oe+re.left,se+re.top,ee.width,ee.height)}};function vm(){this.xa="Base"}Ct(vm,qs),vm.prototype.measure=function(a,y,x,E,b,z,ee){var re=E.length;y=qi(),z=ad(a);for(var oe=0;oe<re;oe++){var se=E[oe];if(se.visible||se===z){var ue=Ou(se,!1);if(ue!==mn&&ue!==Mi)y.push(se);else{se.measure(1/0,x,0,ee),ue=se.margin,se=se.measuredBounds;var fe=Math.max(se.height+ue.top+ue.bottom,0);b.width+=Math.max(se.width+ue.right+ue.left,0),b.height=Math.max(b.height,fe)}}}for(E=y.length,a.desiredSize.height?x=Math.min(a.desiredSize.height,a.maxSize.height):b.height!==0&&(x=Math.min(b.height,a.maxSize.height)),a=0;a<E;a++)oe=y[a],(oe.visible||oe===z)&&(ue=oe.margin,re=ue.right+ue.left,ue=ue.top+ue.bottom,oe.measure(1/0,x,0,ee),oe=oe.measuredBounds,ue=Math.max(oe.height+ue,0),b.width+=Math.max(oe.width+re,0),b.height=Math.max(b.height,ue));Zi(y)},vm.prototype.arrange=function(a,y,x){for(var E=y.length,b=a.padding,z=b.top,ee=a.isOpposite,re=ee?x.width:b.left,oe=0;oe<E;oe++){var se=z,ue=y[oe];if(ue.visible){var fe=ue.measuredBounds,ve=ue.margin,ye=ve.top+ve.bottom,Ce=z+b.bottom,Ae=fe.height,Ye=Ou(ue,!1);(isNaN(ue.desiredSize.height)&&Ye===Cn||Ye===Yi)&&(Ae=Math.max(x.height-ye-Ce,0)),ye=Ae+ye+Ce,Ce=ue.alignment,Ce.Xb()&&(Ce=a.defaultAlignment),Ce.sb()||(Ce=ko),ee&&(re-=fe.width+ve.left+ve.right),ue.arrange(re+Ce.offsetX+ve.left,se+Ce.offsetY+ve.top+(x.height*Ce.y-ye*Ce.y),fe.width,Ae),ee||(re+=fe.width+ve.left+ve.right)}}};function ym(){this.xa="Base"}Ct(ym,qs),ym.prototype.measure=function(a,y,x,E,b,z){var ee=E.length;x=qi();for(var re=ad(a),oe=0;oe<ee;oe++){var se=E[oe];if(se.visible||se===re){var ue=Ou(se,!1);if(ue!==mn&&ue!==Yi)x.push(se);else{var fe=se.margin;ue=fe.right+fe.left,fe=fe.top+fe.bottom,se.measure(y,1/0,z,0),se=se.measuredBounds,Ll(b,Math.max(b.width,Math.max(se.width+ue,0)),b.height+Math.max(se.height+fe,0))}}}if(E=x.length,E!==0){for(a.desiredSize.width?y=Math.min(a.desiredSize.width,a.maxSize.width):b.width!==0&&(y=Math.min(b.width,a.maxSize.width)),a=0;a<E;a++)oe=x[a],(oe.visible||oe===re)&&(se=oe.margin,ee=se.right+se.left,se=se.top+se.bottom,oe.measure(y,1/0,z,0),oe=oe.measuredBounds,se=Math.max(oe.height+se,0),b.width=Math.max(b.width,Math.max(oe.width+ee,0)),b.height+=se);Zi(x)}},ym.prototype.arrange=function(a,y,x){for(var E=y.length,b=a.padding,z=b.left,ee=a.isOpposite,re=ee?x.height:b.top,oe=0;oe<E;oe++){var se=z,ue=y[oe];if(ue.visible){var fe=ue.measuredBounds,ve=ue.margin,ye=ve.left+ve.right,Ce=z+b.right,Ae=fe.width,Ye=Ou(ue,!1);(isNaN(ue.desiredSize.width)&&Ye===Cn||Ye===Mi)&&(Ae=Math.max(x.width-ye-Ce,0)),ye=Ae+ye+Ce,Ce=ue.alignment,Ce.Xb()&&(Ce=a.defaultAlignment),Ce.sb()||(Ce=ko),ee&&(re-=fe.height+ve.bottom+ve.top),ue.arrange(se+Ce.offsetX+ve.left+(x.width*Ce.x-ye*Ce.x),re+Ce.offsetY+ve.top,Ae,fe.height),ee||(re+=fe.height+ve.bottom+ve.top)}}};function Sm(){this.xa="Base"}Ct(Sm,qs),Sm.prototype.measure=function(a,y,x,E,b,z,ee){var re=E.length,oe=a.Pb(),se=oe.margin,ue=se.right+se.left,fe=se.top+se.bottom;oe.measure(y,x,z,ee);var ve=oe.measuredBounds;z=ve.width,ee=ve.height;var ye=Math.max(z+ue,0),Ce=Math.max(ee+fe,0),Ae=a.isClipping,Ye=Xt.allocAt(-se.left,-se.top,ye,Ce),We=Xt.allocAt(0,0,z,ee);f0(oe,We,!0),z=We.width,ee=We.height;for(var tt=!0,rt=ad(a),at=0;at<re;at++){var gt=E[at];ve=y;var At=x;if(gt!==oe&&(gt.visible||gt===rt)){se=gt.margin;var Zn=se.left,mi=se.top;switch(ye=se.right+se.left,Ce=se.top+se.bottom,se=Ou(gt,!1),se){case Cn:ve=z,At=ee,mi=Zn=Ce=ye=0;break;case Mi:ve=z,Zn=ye=0;break;case Yi:At=ee,mi=Ce=0}gt.measure(ve,At,0,0),ve=gt.measuredBounds,ye=Math.max(ve.width+ye,0),Ce=Math.max(ve.height+Ce,0),se=gt.alignment,se.Xb()&&(se=a.defaultAlignment),se.sb()||(se=ko);var si=gt.alignmentFocus;if(si.Xb()&&(si=ko),At=null,gt instanceof Ln&&gt.$e!==""&&(At=gt.fb(gt.$e),At===gt&&(At=null)),Zn=We.x-Zn,mi=We.y-mi,At!==null){for(gt.arrange(0,0,ve.width,ve.height),ve=At.actualBounds,ve=Qe.allocAt(ve.x+(si.x*ve.width-si.offsetX),ve.y+(si.y*ve.height-si.offsetY)),At=At.panel;At!==gt;)At.transform.Ga(ve),At=At.panel;Zn+=se.x*z+se.offsetX-ve.x,mi+=se.y*ee+se.offsetY-ve.y,Qe.free(ve)}else Zn+=se.x*z+se.offsetX-(si.x*ve.width+si.offsetX),mi+=se.y*ee+se.offsetY-(si.y*ve.height+si.offsetY);tt?(tt=!1,b.h(Zn,mi,ye,Ce)):es(b,Zn,mi,ye,Ce)}}switch(tt?b.assign(Ye):Ae?b.Uu(We.x,We.y,We.width,We.height):es(b,Ye.x,Ye.y,Ye.width,Ye.height),Xt.free(Ye),Xt.free(We),se=oe.stretch,se===Cr&&(se=Ou(oe,!1)),se){case mn:return;case Cn:if(!isFinite(y)&&!isFinite(x))return;break;case Mi:if(!isFinite(y))return;break;case Yi:if(!isFinite(x))return}for(ve=oe.measuredBounds,z=ve.width,ee=ve.height,ye=Math.max(z+ue,0),Ce=Math.max(ee+fe,0),se=oe.margin,We=Xt.allocAt(-se.left,-se.top,ye,Ce),f0(oe,We,!0),z=We.width,ee=We.height,y=0;y<re;y++)x=E[y],x===oe||!x.visible&&x!==rt||(se=x.margin,ye=se.right+se.left,Ce=se.top+se.bottom,ve=x.measuredBounds,ye=Math.max(ve.width+ye,0),Ce=Math.max(ve.height+Ce,0),ue=x.alignment,ue.Xb()&&(ue=a.defaultAlignment),ue.sb()||(ue=ko),x=x.alignmentFocus,x.Xb()&&(x=ko),tt?(tt=!1,b.h(ue.x*z+ue.offsetX-(x.x*ve.width+x.offsetX)-se.left,ue.y*ee+ue.offsetY-(x.y*ve.height+x.offsetY)-se.top,ye,Ce)):es(b,ue.x*z+ue.offsetX-(x.x*ve.width+x.offsetX)-se.left,ue.y*ee+ue.offsetY-(x.y*ve.height+x.offsetY)-se.top,ye,Ce));tt?b.assign(Ye):Ae?b.Uu(We.x,We.y,We.width,We.height):es(b,Ye.x,Ye.y,Ye.width,Ye.height),Xt.free(We)},Sm.prototype.arrange=function(a,y,x){var E=y.length,b=a.Pb(),z=b.measuredBounds,ee=z.width,re=z.height,oe=a.padding;z=oe.left,oe=oe.top;var se=z-x.x,ue=oe-x.y;for(b.arrange(se,ue,ee,re),ee=Xt.allocAt(0,0,ee,re),f0(b,ee,!1),re=0;re<E;re++){var fe=y[re];if(fe!==b){se=fe.measuredBounds;var ve=se.width,ye=se.height;ue=fe.alignment,ue.Xb()&&(ue=a.defaultAlignment),ue.sb()||(ue=ko);var Ce=fe.alignmentFocus;if(Ce.Xb()&&(Ce=ko),se=null,fe instanceof Ln&&fe.$e!==""&&(se=fe.fb(fe.$e),se===fe&&(se=null)),se!==null){var Ae=se.actualBounds;for(Ce=Qe.allocAt(Ae.x+(Ce.x*Ae.width-Ce.offsetX),Ae.y+(Ce.y*Ae.height-Ce.offsetY)),se=se.panel;se!==fe;)se.transform.Ga(Ce),se=se.panel;se=ue.x*ee.width+ue.offsetX-Ce.x,ue=ue.y*ee.height+ue.offsetY-Ce.y,Qe.free(Ce)}else se=ue.x*ee.width+ue.offsetX-(Ce.x*ve+Ce.offsetX),ue=ue.y*ee.height+ue.offsetY-(Ce.y*ye+Ce.offsetY);se+=ee.x-x.x,ue+=ee.y-x.y,fe.visible&&fe.arrange(z+se,oe+ue,ve,ye)}}Xt.free(ee)};function f0(a,y,x){var E=null;if(a instanceof Ln&&a.$e!==""&&(E=a.fb(a.$e),E===a&&(E=null)),E!==null)for(x&&a.arrange(0,0,y.width,y.height),y.assign(E.actualBounds),E=E.panel;E!==a;)E.transform.pp(y),E=E.panel}function xm(){this.xa="Base"}Ct(xm,qs),xm.prototype.measure=function(a,y,x,E,b,z,ee){var re=E.length,oe=a.Pb(),se=oe.margin,ue=y,fe=x,ve=se.right+se.left,ye=se.top+se.bottom;oe.measure(y,x,z,ee),se=oe.measuredBounds;var Ce=0,Ae=null;oe instanceof Dr&&(Ae=oe,Ce=Ae.strokeWidth*Ae.scale);var Ye=Math.max(se.width+ve,0);se=Math.max(se.height+ye,0);var We=v0(oe),tt=We.x*Ye+We.offsetX;We=We.y*se+We.offsetY;var rt=y0(oe),at=rt.x*Ye+rt.offsetX;for(rt=rt.y*se+rt.offsetY,isFinite(y)&&(ue=Math.max(Math.abs(tt-at)-Ce,0)),isFinite(x)&&(fe=Math.max(Math.abs(We-rt)-Ce,0)),Ce=fn.alloc(),Ce.h(0,0),a=ad(a),rt=0;rt<re;rt++)We=E[rt],We===oe||!We.visible&&We!==a||(se=We.margin,Ye=se.right+se.left,tt=se.top+se.bottom,We.measure(ue,fe,0,0),se=We.measuredBounds,Ye=Math.max(se.width+Ye,0),se=Math.max(se.height+tt,0),Ce.h(Math.max(Ye,Ce.width),Math.max(se,Ce.height)));if(re===1)b.width=Ye,b.height=se,fn.free(Ce);else{switch(We=v0(oe),rt=y0(oe),re=E=0,rt.x!==We.x&&rt.y!==We.y&&(E=Ce.width/Math.abs(rt.x-We.x),re=Ce.height/Math.abs(rt.y-We.y)),fn.free(Ce),Ce=0,Ae!==null&&(Ce=Ae.strokeWidth*Ae.scale,E0(Ae)===xi&&(E=re=Math.max(E,re))),E+=Math.abs(We.offsetX)+Math.abs(rt.offsetX)+Ce,re+=Math.abs(We.offsetY)+Math.abs(rt.offsetY)+Ce,Ae=oe.stretch,Ae===Cr&&(Ae=Ou(oe,!1)),Ae){case mn:ee=z=0;break;case Cn:isFinite(y)&&(E=y),isFinite(x)&&(re=x);break;case Mi:isFinite(y)&&(E=y),ee=0;break;case Yi:z=0,isFinite(x)&&(re=x)}oe.Uj(),oe.measure(E,re,z,ee),b.width=oe.measuredBounds.width+ve,b.height=oe.measuredBounds.height+ye}},xm.prototype.arrange=function(a,y){var x=y.length,E=a.Pb(),b=E.measuredBounds,z=Xt.alloc();z.h(0,0,1,1);var ee=E.margin,re=ee.left;ee=ee.top;var oe=a.padding,se=oe.left;oe=oe.top,E.arrange(se+re,oe+ee,b.width,b.height);var ue=v0(E),fe=y0(E),ve=ue.y*b.height+ue.offsetY,ye=fe.x*b.width+fe.offsetX;for(fe=fe.y*b.height+fe.offsetY,z.x=ue.x*b.width+ue.offsetX,z.y=ve,es(z,ye,fe,0,0),z.x+=re+se,z.y+=ee+oe,b=0;b<x;b++)re=y[b],re!==E&&(se=re.measuredBounds,ee=re.margin,oe=Math.max(se.width+ee.right+ee.left,0),ue=Math.max(se.height+ee.top+ee.bottom,0),ve=re.alignment,ve.Xb()&&(ve=a.defaultAlignment),ve.sb()||(ve=ko),oe=z.width*ve.x+ve.offsetX-oe*ve.x+ee.left+z.x,ee=z.height*ve.y+ve.offsetY-ue*ve.y+ee.top+z.y,re.visible&&(Ds(z.x,z.y,z.width,z.height,oe,ee,se.width,se.height)?re.arrange(oe,ee,se.width,se.height):re.arrange(oe,ee,se.width,se.height,new Xt(z.x,z.y,z.width,z.height))));Xt.free(z)};function wm(){this.xa="Base",this.name="Table"}Ct(wm,qs),wm.prototype.measure=function(a,y,x,E,b){for(var z=E.length,ee=qi(),re=qi(),oe=0;oe<z;oe++){var se=E[oe],ue=se instanceof Ln?se:null;if(ue!==null&&wd(ue)&&se.visible){re.push(ue);for(var fe=ue.O.s,ve=fe.length,ye=0;ye<ve;ye++){var Ce=fe[ye];ue.type===Ln.TableRow?Ce.row=se.row:ue.type===Ln.TableColumn&&(Ce.column=se.column),ee.push(Ce)}}else ee.push(se)}z=ee.length,z===0&&(a.Fb(0),a.Eb(0));for(var Ae=[],Ye=0;Ye<z;Ye++){var We=ee[Ye];We.visible&&(Ys(We,!0),Hc(We,!0),Ae[We.row]||(Ae[We.row]=[]),Ae[We.row][We.column]||(Ae[We.row][We.column]=[]),Ae[We.row][We.column].push(We))}Zi(ee);var tt=qi(),rt=qi(),at=qi(),gt={count:0},At={count:0},Zn=y,mi=x,si=a.rowDefs,Nn=a.colDefs,pn=null;z=si.length;for(var yr=0;yr<z;yr++)pn=si[yr],pn!==void 0&&(pn.actual=0);z=Nn.length;for(var sr=0;sr<z;sr++)pn=Nn[sr],pn!==void 0&&(pn.actual=0);for(var Io=Ae.length,Oa=0,gl=0;gl<Io;gl++)Ae[gl]&&(Oa=Math.max(Oa,Ae[gl].length));var wl=Math.min(a.topIndex,Io-1),hu=Math.min(a.leftIndex,Oa-1),pl=0;Io=Ae.length;for(var Nd=ad(a),Gs=0;Gs<Io;Gs++)if(Ae[Gs]){Oa=Ae[Gs].length;var Sc=a.Fb(Gs);Sc.actual=0;for(var cu=Sc.oc=0;cu<Oa;cu++)if(Ae[Gs][cu]){var Td=a.Eb(cu);tt[cu]===void 0&&(Td.actual=0,Td.oc=0,tt[cu]=!0);for(var Sh=Ae[Gs][cu],Jh=Sh.length,rh=0;rh<Jh;rh++){var Uu=Sh[rh];if(Uu.visible||Uu===Nd){var rf=1<Uu.rowSpan||1<Uu.columnSpan;rf&&(Gs<wl||cu<hu||rt.push(Uu));var xc=Uu.margin,Vg=xc.right+xc.left,oh=xc.top+xc.bottom,du=gc(Uu,Sc,Td,!1),qp=Uu.desiredSize,eg=!isNaN(qp.height),Tc=!isNaN(qp.width)&&eg;if(rf||du===mn||Tc||Gs<wl||cu<hu||(gt[cu]!==void 0||du!==Cn&&du!==Mi||(gt[cu]=-1,gt.count++),At[Gs]!==void 0||du!==Cn&&du!==Yi||(At[Gs]=-1,At.count++),at.push(Uu)),Uu.measure(1/0,1/0,0,0),!(Gs<wl||cu<hu)){var Zu=Uu.measuredBounds,Mf=Math.max(Zu.width+Vg,0),ah=Math.max(Zu.height+oh,0);if(Uu.rowSpan===1&&(du===mn||du===Mi)){pn=a.Fb(Gs);var of=pn.Wc();pl=Math.max(ah-pn.actual,0),pl+of>mi&&(pl=Math.max(mi-of,0));var Vv=pn.oa===0;pn.oc=pn.oc+pl,pn.actual=pn.oa+pl,mi=Math.max(mi-(pl+(Vv?of:0)),0)}if(Uu.columnSpan===1&&(du===mn||du===Yi)){pn=a.Eb(cu);var $p=pn.Wc();pl=Math.max(Mf-pn.actual,0),pl+$p>Zn&&(pl=Math.max(Zn-$p,0));var Hy=pn.oa===0;pn.oc=pn.oc+pl,pn.actual=pn.oa+pl,Zn=Math.max(Zn-(pl+(Hy?$p:0)),0)}rf&&Uu.Uj()}}}}}Zi(tt);var Qc=0,ud=0;z=a.columnCount;for(var tg=0;tg<z;tg++){var af=Nn[tg];af!==void 0&&(Qc+=isNaN(af.Hc)?af.oc:af.Hc,af.oc!==0&&(Qc+=af.Wc()))}z=a.rowCount;for(var Ug=0;Ug<z;Ug++){var sf=si[Ug];sf!==void 0&&(ud+=isNaN(sf.Hc)?sf.oc:sf.Hc,sf.oc!==0&&(ud+=sf.Wc()))}Zn=Math.max(y-Qc,0);var qc=mi=Math.max(x-ud,0),Dd=Zn;z=at.length;for(var _u=0;_u<z;_u++){var Dc=at[_u],Uv=a.Fb(Dc.row),hd=a.Eb(Dc.column),Zg=Dc.measuredBounds,wc=Dc.margin,kf=wc.right+wc.left,Bc=wc.top+wc.bottom;gt[Dc.column]=hd.oc===0&&gt[Dc.column]!==void 0?Math.max(Zg.width+kf,gt[Dc.column]):null,At[Dc.row]=Uv.oc===0&&At[Dc.row]!==void 0?Math.max(Zg.height+Bc,At[Dc.row]):null}var ng=0,_g=0,hc;for(hc in At)hc!=="count"&&(ng+=At[hc]);for(hc in gt)hc!=="count"&&(_g+=gt[hc]);for(var Al=fn.alloc(),em=0;em<z;em++){var Mu=at[em];if(Mu.visible||Mu===Nd){var Ks=a.Fb(Mu.row),ku=a.Eb(Mu.column),cd=0;isFinite(ku.width)?cd=ku.width:(isFinite(Zn)&&gt[Mu.column]!==null?_g===0?cd=ku.actual+Zn:cd=gt[Mu.column]/_g*Dd:gt[Mu.column]!==null?cd=Zn:cd=ku.actual||Zn,cd=Math.max(0,cd-ku.Wc()));var Bd=0;switch(isFinite(Ks.height)?Bd=Ks.height:(isFinite(mi)&&At[Mu.row]!==null?ng===0?Bd=Ks.actual+mi:Bd=At[Mu.row]/ng*qc:At[Mu.row]!==null?Bd=mi:Bd=Ks.actual||mi,Bd=Math.max(0,Bd-Ks.Wc())),Al.h(Math.max(ku.minimum,Math.min(cd,ku.maximum)),Math.max(Ks.minimum,Math.min(Bd,Ks.maximum))),du=gc(Mu,Ks,ku,!1),du){case Mi:Al.height=Math.max(Al.height,Ks.actual+mi);break;case Yi:Al.width=Math.max(Al.width,ku.actual+Zn)}var Ff=Mu.margin,Gy=Ff.right+Ff.left,Zv=Ff.top+Ff.bottom;Mu.Uj(),Mu.measure(Al.width,Al.height,ku.minimum,Ks.minimum);var Yg=Mu.measuredBounds,Af=Math.max(Yg.width+Gy,0),ig=Math.max(Yg.height+Zv,0);isFinite(Zn)&&(Af=Math.min(Af,Al.width)),isFinite(mi)&&(ig=Math.min(ig,Al.height));var Yu=0;Yu=Ks.actual,Ks.actual=Math.max(Ks.actual,ig),Ks.oc=Math.max(Ks.oc,ig),pl=Ks.actual-Yu,mi=Math.max(mi-pl,0),At[Mu.row]===null&&(qc=Math.max(qc-pl,0)),Yu=ku.actual,ku.actual=Math.max(ku.actual,Af),ku.oc=Math.max(ku.oc,Af),pl=ku.actual-Yu,Zn=Math.max(Zn-pl,0),gt[Mu.column]===null&&(Dd=Math.max(Dd-pl,0))}}Zi(at);var dd=fn.alloc(),Pc=qi(),jh=qi();if(z=rt.length,z!==0){for(var lf=0;lf<Io;lf++)if(Ae[lf]){Oa=Ae[lf].length;var Xg=a.Fb(lf);Pc[lf]=Xg.actual;for(var uf=0;uf<Oa;uf++)if(Ae[lf][uf]){var _v=a.Eb(uf);jh[uf]=_v.actual}}}for(var Jg=0;Jg<z;Jg++){var Ts=rt[Jg];if(Ts.visible||Ts===Nd){var cc=a.Fb(Ts.row),Qh=a.Eb(Ts.column);switch(Al.h(Math.max(Qh.minimum,Math.min(y,Qh.maximum)),Math.max(cc.minimum,Math.min(x,cc.maximum))),du=gc(Ts,cc,Qh,!1),du){case Cn:jh[Qh.index]!==0&&(Al.width=Math.min(Al.width,jh[Qh.index])),Pc[cc.index]!==0&&(Al.height=Math.min(Al.height,Pc[cc.index]));break;case Mi:jh[Qh.index]!==0&&(Al.width=Math.min(Al.width,jh[Qh.index]));break;case Yi:Pc[cc.index]!==0&&(Al.height=Math.min(Al.height,Pc[cc.index]))}isFinite(Qh.width)&&(Al.width=Qh.width),isFinite(cc.height)&&(Al.height=cc.height),dd.h(0,0);for(var Yv=Qh.minimum,sh=cc.minimum,Od=1;Od<Ts.rowSpan&&!(Ts.row+Od>=a.rowCount);Od++)pn=a.Fb(Ts.row+Od),pl=0,pl=du===Cn||du===Yi?Math.max(pn.minimum,Pc[Ts.row+Od]===0?pn.maximum:Math.min(Pc[Ts.row+Od],pn.maximum)):Math.max(pn.minimum,isNaN(pn.Hc)?pn.maximum:Math.min(pn.Hc,pn.maximum)),dd.height+=pl,sh+=pn.minimum;for(var qh=1;qh<Ts.columnSpan&&!(Ts.column+qh>=a.columnCount);qh++)pn=a.Eb(Ts.column+qh),pl=0,pl=du===Cn||du===Mi?Math.max(pn.minimum,jh[Ts.column+qh]===0?pn.maximum:Math.min(jh[Ts.column+qh],pn.maximum)):Math.max(pn.minimum,isNaN(pn.Hc)?pn.maximum:Math.min(pn.Hc,pn.maximum)),dd.width+=pl,Yv+=pn.minimum;Al.width+=dd.width,Al.height+=dd.height;var Qg=Ts.margin,hf=Qg.right+Qg.left,tm=Qg.top+Qg.bottom;Ts.measure(Al.width,Al.height,Yv,sh);for(var qg=Ts.measuredBounds,Oc=Math.max(qg.width+hf,0),Nf=Math.max(qg.height+tm,0),cf=0,$g=0;$g<Ts.rowSpan&&!(Ts.row+$g>=a.rowCount);$g++)pn=a.Fb(Ts.row+$g),cf+=pn.total||0;if(cf<Nf){var Rd=Nf-cf,$c=Nf-cf;if(Ts.spanAllocation!==null)for(var Id=Ts.spanAllocation,fd=0;fd<Ts.rowSpan&&!(0>=Rd)&&!(Ts.row+fd>=a.rowCount);fd++){pn=a.Fb(Ts.row+fd);var jd=pn.oa||0,Tf=Id(Ts,pn,$c);pn.actual=Math.min(pn.maximum,jd+Tf),pn.oa!==jd&&(Rd-=pn.oa-jd)}for(;0<Rd;){var Cc=pn.oa||0;if(isNaN(pn.height)&&pn.maximum>Cc&&(pn.actual=Math.min(pn.maximum,Cc+Rd),pn.oa!==Cc&&(Rd-=pn.oa-Cc)),pn.index===0)break;pn=a.Fb(pn.index-1)}}for(var rg=0,zd=0;zd<Ts.columnSpan&&!(Ts.column+zd>=a.columnCount);zd++)pn=a.Eb(Ts.column+zd),rg+=pn.total||0;if(rg<Oc){var og=Oc-rg,Ky=Oc-rg;if(Ts.spanAllocation!==null)for(var gd=Ts.spanAllocation,Df=0;Df<Ts.columnSpan&&!(0>=og)&&!(Ts.column+Df>=a.columnCount);Df++){pn=a.Eb(Ts.column+Df);var nm=pn.oa||0,Wy=gd(Ts,pn,Ky);pn.actual=Math.min(pn.maximum,nm+Wy),pn.oa!==nm&&(og-=pn.oa-nm)}for(;0<og;){var Xv=pn.oa||0;if(isNaN(pn.width)&&pn.maximum>Xv&&(pn.actual=Math.min(pn.maximum,Xv+og),pn.oa!==Xv&&(og-=pn.oa-Xv)),pn.index===0)break;pn=a.Eb(pn.index-1)}}}}Zi(rt),fn.free(dd),fn.free(Al),Pc!==void 0&&Zi(Pc),jh!==void 0&&Zi(jh);var ag=0,sg=0,Jv=a.desiredSize,gx=a.maxSize;du=Ou(a,!0);var im=ud=Qc=0,rm=0;z=a.columnCount;for(var Qv=0;Qv<z;Qv++)Nn[Qv]!==void 0&&(pn=a.Eb(Qv),isFinite(pn.width)?(im+=pn.width,im+=pn.Wc()):Nm(pn)===pp?(im+=pn.oa,im+=pn.Wc()):pn.oa!==0&&(Qc+=pn.oa,Qc+=pn.Wc()));isFinite(Jv.width)?ag=Math.min(Jv.width,gx.width):ag=du!==mn&&isFinite(y)?y:Qc,ag=Math.max(ag,a.minSize.width),ag=Math.max(ag-im,0);for(var Qx=Qc===0?1:Math.max(ag/Qc,1),qv=0;qv<z;qv++)Nn[qv]!==void 0&&(pn=a.Eb(qv),isFinite(pn.width)||Nm(pn)===pp||(pn.actual=pn.oa*Qx),pn.position=b.width,pn.oa!==0&&(b.width+=pn.oa,b.width+=pn.Wc()));z=a.rowCount;for(var $v=0;$v<z;$v++)si[$v]!==void 0&&(pn=a.Fb($v),isFinite(pn.height)?(rm+=pn.height,rm+=pn.Wc()):Nm(pn)===pp?(rm+=pn.oa,rm+=pn.Wc()):pn.oa!==0&&(ud+=pn.oa,ud+=pn.Wc()));isFinite(Jv.height)?sg=Math.min(Jv.height,gx.height):sg=du!==mn&&isFinite(x)?x:ud,sg=Math.max(sg,a.minSize.height),sg=Math.max(sg-rm,0);for(var qx=ud===0?1:Math.max(sg/ud,1),e0=0;e0<z;e0++)si[e0]!==void 0&&(pn=a.Fb(e0),isFinite(pn.height)||Nm(pn)===pp||(pn.actual=pn.oa*qx),pn.position=b.height,pn.oa!==0&&(b.height+=pn.oa,b.height+=pn.Wc()));z=re.length;for(var Vy=0;Vy<z;Vy++){var om=re[Vy],Uy=0,Zy=0;om.type===Ln.TableRow?(Uy=b.width,pn=a.Fb(om.row),Zy=pn.actual):(pn=a.Eb(om.column),Uy=pn.actual,Zy=b.height),om.measuredBounds.h(0,0,Uy,Zy),Ys(om,!1)}Zi(re),a.inRowsCols=Ae},wm.prototype.arrange=function(a,y,x){var E=y.length,b=a.padding,z=b.left;b=b.top;var ee=a.inRowsCols;if(ee!==null){for(var re,oe,se=ee.length,ue=0,fe=0;fe<se;fe++)ee[fe]&&(ue=Math.max(ue,ee[fe].length));oe=a.rowDefs,re=a.colDefs;var ve=fe=0,ye=Math.min(a.topIndex,se-1);if(0<oe.length){for(;ye!==se&&(oe[ye]===void 0||oe[ye].oa===0);)ye++;ye=Math.max(Math.min(ye,se-1),0),fe=-oe[ye].position}var Ce=Math.min(a.leftIndex,ue-1);if(0<re.length){for(;Ce!==ue&&(re[Ce]===void 0||re[Ce].oa===0);)Ce++;Ce=Math.max(Math.min(Ce,ue-1),0),ve=-re[Ce].position}for(var Ae=0,Ye=0;Ae!==se&&oe[Ae]===void 0;)Ae++;for(;Ye!==se&&re[Ye]===void 0;)Ye++;ue=a.part,a.Fb(Ae),a.Eb(Ye);for(var We=0;We<y.length;We++){var tt=y[We];if(tt instanceof Ln&&tt.visible&&wd(tt)){if(tt.type===Ln.TableRow){re=a.Fb(tt.row);var rt=a.Eb(Ye)}else re=a.Fb(Ae),rt=a.Eb(tt.column);oe=re.position+fe+b,re.oa!==0&&(oe+=re.Io(Math.max(Ae,ye))),re=rt.position+ve+z,rt.oa!==0&&(re+=rt.Io(Math.max(Ye,Ce))),rt=tt.measuredBounds,tt.Uk(),tt.actualBounds.ka();var at=tt.actualBounds,gt=Xt.allocAt(at.x,at.y,at.width,at.height);at.x=tt.type===Ln.TableRow?z:re,at.y=tt.type===Ln.TableColumn?b:oe,at.width=rt.width,at.height=rt.height,tt.actualBounds.freeze(),Hc(tt,!1),As(gt,at)||ue===null||(ue.oh(),tt.Pn(ue)),Xt.free(gt)}}for(We=fn.alloc(),tt=0;tt<se;tt++)if(ee[tt]){for(ue=ee[tt].length,rt=a.Fb(tt),oe=rt.position+fe+b,rt.oa!==0&&(oe+=rt.Io(Math.max(Ae,ye))),at=0;at<ue;at++)if(ee[tt][at]){gt=a.Eb(at),re=gt.position+ve+z,gt.oa!==0&&(re+=gt.Io(Math.max(Ye,Ce)));for(var At=ee[tt][at],Zn=At.length,mi=0;mi<Zn;mi++){var si=At[mi],Nn=si.measuredBounds;We.h(0,0);for(var pn=1;pn<si.rowSpan&&!(tt+pn>=a.rowCount);pn++){var yr=a.Fb(tt+pn);yr.oa!==0&&(We.height+=yr.total)}for(pn=1;pn<si.columnSpan&&!(at+pn>=a.columnCount);pn++)yr=a.Eb(at+pn),yr.oa!==0&&(We.width+=yr.total);var sr=gt.oa+We.width,Io=rt.oa+We.height;pn=re,yr=oe;var Oa=sr,gl=Io,wl=re,hu=oe,pl=sr,Nd=Io;re+sr>x.width&&(pl=Math.max(x.width-re,0)),oe+Io>x.height&&(Nd=Math.max(x.height-oe,0));var Gs=si.alignment;if(Gs.Xb()){Gs=a.defaultAlignment,Gs.sb()||(Gs=ko);var Sc=Gs.x,cu=Gs.y,Td=Gs.offsetX;Gs=Gs.offsetY;var Sh=gt.alignment,Jh=rt.alignment;Sh.sb()&&(Sc=Sh.x,Td=Sh.offsetX),Jh.sb()&&(cu=Jh.y,Gs=Jh.offsetY)}else Sc=Gs.x,cu=Gs.y,Td=Gs.offsetX,Gs=Gs.offsetY;(isNaN(Sc)||isNaN(cu))&&(cu=Sc=.5,Gs=Td=0),Sh=Nn.width,Jh=Nn.height;var rh=si.margin,Uu=rh.left+rh.right,rf=rh.top+rh.bottom,xc=gc(si,rt,gt,!1);!isNaN(si.desiredSize.width)||xc!==Cn&&xc!==Mi||(Sh=Math.max(sr-Uu,0)),!isNaN(si.desiredSize.height)||xc!==Cn&&xc!==Yi||(Jh=Math.max(Io-rf,0)),sr=si.maxSize,Io=si.minSize,Sh=Math.min(sr.width,Sh),Jh=Math.min(sr.height,Jh),Sh=Math.max(Io.width,Sh),Jh=Math.max(Io.height,Jh),sr=Jh+rf,pn+=Oa*Sc-(Sh+Uu)*Sc+Td+rh.left,yr+=gl*cu-sr*cu+Gs+rh.top,si.visible&&(Ds(wl,hu,pl,Nd,pn,yr,Nn.width,Nn.height)?si.arrange(pn,yr,Sh,Jh):si.arrange(pn,yr,Sh,Jh,new Xt(wl,hu,pl,Nd)))}}}for(fn.free(We),a=0;a<E;a++)x=y[a],z=x instanceof Ln?x:null,z!==null&&wd(z)&&(z=x.actualBounds,x.naturalBounds.ka(),x.naturalBounds.h(0,0,z.width,z.height),x.naturalBounds.freeze())}};function Pm(){this.xa="Base"}Ct(Pm,qs),Pm.prototype.measure=function(){},Pm.prototype.arrange=function(){};function Cm(){this.xa="Base"}Ct(Cm,qs),Cm.prototype.measure=function(){},Cm.prototype.arrange=function(){};function Em(){this.xa="Base"}Ct(Em,qs),Em.prototype.measure=function(a,y,x,E,b,z,ee){1<E.length&&Dt("Viewbox Panel cannot contain more than one GraphObject."),E=E[0],E.Ca=1,E.Uj(),E.measure(1/0,1/0,z,ee);var re=E.measuredBounds,oe=E.margin,se=oe.right+oe.left;if(oe=oe.top+oe.bottom,isFinite(y)||isFinite(x)){var ue=E.scale,fe=re.width;re=re.height;var ve=Math.max(y-se,0),ye=Math.max(x-oe,0),Ce=1;a.viewboxStretch===xi?fe!==0&&re!==0&&(Ce=Math.min(ve/fe,ye/re)):fe!==0&&re!==0&&(Ce=Math.max(ve/fe,ye/re)),Ce===0&&(Ce=1e-4),E.Ca*=Ce,ue!==E.scale&&(Ys(E,!0),E.measure(1/0,1/0,z,ee))}re=E.measuredBounds,b.width=isFinite(y)?y:Math.max(re.width+se,0),b.height=isFinite(x)?x:Math.max(re.height+oe,0)},Em.prototype.arrange=function(a,y,x){y=y[0];var E=y.measuredBounds,b=y.margin,z=Math.max(E.width+(b.right+b.left),0);b=Math.max(E.height+(b.top+b.bottom),0);var ee=y.alignment;ee.Xb()&&(ee=a.defaultAlignment),ee.sb()||(ee=ko),y.arrange(x.width*ee.x-z*ee.x+ee.offsetX,x.height*ee.y-b*ee.y+ee.offsetY,E.width,E.height)};function dp(){this.xa="Base"}Ct(dp,qs),dp.prototype.measure=function(){},dp.prototype.arrange=function(){},dp.prototype.gc=function(a,y,x){x=a.Df()*x.scale,0>=x&&(x=1);var E=a.gridCellSize,b=E.width;E=E.height;var z=a.naturalBounds,ee=a.actualBounds,re=z.width,oe=z.height,se=Math.ceil(re/b),ue=Math.ceil(oe/E),fe=a.gridOrigin,ve=fe.x;fe=fe.y,y.save(),y.beginPath(),y.rect(0,0,re,oe),y.clip(),y.Se();for(var ye=[],Ce=a.O.s,Ae=Ce.length,Ye=0;Ye<Ae;Ye++){var We=Ce[Ye],tt=[];if(ye.push(tt),We.visible){var rt=We.interval;if(!(0>rt)){We=p0(We.figure);for(var at=0;at<Ae;at++)if(at!==Ye){var gt=Ce[at];gt.visible&&p0(gt.figure)===We&&(gt=gt.interval,gt>rt&&tt.push(gt))}}}}for(Ce=a.O.s,Ae=Ce.length,Ye=0;Ye<Ae;Ye++){var At=Ce[Ye];if(At.visible&&(tt=At.interval||1,We=Math.abs(tt),!(2>b*We*x))){if(rt=At.segmentIndex,(!isFinite(rt)||isNaN(rt))&&(rt=0),0>rt&&(rt=We-Math.min(-rt,We)),rt=Math.round(rt%We),We=At.opacity,at=1,We!==1){if(We===0)continue;at=y.globalAlpha,y.globalAlpha=at*We}gt=ye[Ye];var Zn=!1,mi=At.strokeDashArray;if(mi!==null&&(Zn=!0,y.js(mi,At.strokeDashOffset)),At.figure==="LineV"&&At.stroke!==null&&0<At.strokeWidth){for(y.lineWidth=At.strokeWidth,ks(a,y,At.stroke,!1,!1,z,ee),y.beginPath(),mi=At=Math.floor((ve-b)/b);mi<=At+se;mi++){var si=mi*b+ve;0<=si&&si<=re&&bm(mi,tt,rt,gt)&&(y.moveTo(si,0),y.lineTo(si,oe))}y.stroke(),y.Se()}else if(At.figure==="LineH"&&At.stroke!==null&&0<At.strokeWidth){for(y.lineWidth=At.strokeWidth,ks(a,y,At.stroke,!1,!1,z,ee),y.beginPath(),mi=At=Math.floor((fe-E)/E);mi<=At+ue;mi++)si=mi*E+fe,0<=si&&si<=oe&&bm(mi,tt,rt,gt)&&(y.moveTo(0,si),y.lineTo(re,si));y.stroke(),y.Se()}else if(At.figure==="BarV"&&At.fill!==null)for(ks(a,y,At.fill,!0,!1,z,ee),At=At.width,isNaN(At)&&(At=b),si=mi=Math.floor((ve-b)/b);si<=mi+se;si++){var Nn=si*b+ve;0<=Nn+At&&Nn<=re&&bm(si,tt,rt,gt)&&y.fillRect(Nn,0,At,oe)}else if(At.figure==="BarH"&&At.fill!==null)for(ks(a,y,At.fill,!0,!1,z,ee),At=At.height,isNaN(At)&&(At=E),si=mi=Math.floor((fe-E)/E);si<=mi+ue;si++)Nn=si*E+fe,0<=Nn+At&&Nn<=oe&&bm(si,tt,rt,gt)&&y.fillRect(0,Nn,re,At);Zn&&y.fs(),We!==1&&(y.globalAlpha=at)}}y.restore(),y.Vc(!1)};function bm(a,y,x,E){if(0>y)return a%y===x;if(a%y!==x)return!1;y=E.length;for(var b=0;b<y;b++)if(a%E[b]===x)return!1;return!0}function Lm(){this.xa="Base"}Ct(Lm,qs),Lm.prototype.measure=function(a,y,x,E,b){var z=E.length;if(a instanceof Fo||a instanceof Tn){var ee=null,re=null;if(a instanceof Tn&&(ee=a),a instanceof Fo&&(re=a,ee=re.adornedPart,a.j===null&&(a.j=[])),ee instanceof Tn){var oe=ee;if(z===0)Ll(a.naturalBounds,0,0),a.measuredBounds.h(0,0,0,0);else{var se=a instanceof Fo?null:ee.path;y=ee.routeBounds,x=a.jg,x.h(0,0,y.width,y.height);var ue=oe.points,fe=ee.pointsCount;re!==null?re.Ul(!1):ee!==null&&ee.Ul(!1),re=y.width;var ve=y.height,ye=a.j;if(ye.length=0,se!==null){iS(a,re,ve,se);var Ce=se.measuredBounds;x.ed(Ce),ye.push(Ce)}Ce=kr.alloc();for(var Ae=Qe.alloc(),Ye=Qe.alloc(),We=0;We<z;We++){var tt=E[We];if(tt!==se)if(tt.isPanelMain&&tt instanceof Dr){iS(a,re,ve,tt);var rt=tt.measuredBounds;x.ed(rt),ye.push(rt)}else if(2>fe)tt.measure(1/0,1/0,0,0),rt=tt.measuredBounds,x.ed(rt),ye.push(rt);else{var at=tt.segmentIndex,gt=tt.segmentFraction,At=tt.alignmentFocus;At.Mc()&&(At=ko);var Zn=tt.segmentOrientation,mi=tt.segmentOffset;if(isNaN(at)){var si=oe.ua;rt=qi(),si.Qu(gt,rt);var Nn=Qe.allocAt(rt[0],rt[1]);if(Nn.add(oe.i(0)),si.type===Bn.j?Nn.offset(-si.startX,-si.startY):(si=si.figures.first(),si!==null&&Nn.offset(-si.startX,-si.startY)),si=rt[2],Zn!==Pu){var pn=oe.computeAngle(tt,Zn,si);tt.Kb=pn}pn=Nn.x-y.x;var yr=Nn.y-y.y;Qe.free(Nn),Zi(rt)}else if(at<-fe||at>=fe)rt=Qe.alloc(),oe.vg(),oe.computeMidPoint(rt),si=oe.midAngle,Zn!==Pu&&(pn=oe.computeAngle(tt,Zn,si),tt.Kb=pn),pn=rt.x-y.x,yr=rt.y-y.y,Qe.free(rt);else{if(pn=0,0<=at?(yr=ue.M(at),rt=at<fe-1?ue.M(at+1):yr):(pn=fe+at,yr=ue.M(pn),rt=0<pn?ue.M(pn-1):yr),yr.Xa(rt)){0<=at?(si=0<at?ue.M(at-1):yr,pn=at<fe-2?ue.M(at+2):rt):(si=pn<fe-1?ue.M(pn+1):yr,pn=1<pn?ue.M(pn-2):rt),Nn=si.Bf(yr);var sr=rt.Bf(pn);si=Nn>sr+10?0<=at?si.ab(yr):yr.ab(si):sr>Nn+10?0<=at?rt.ab(pn):pn.ab(rt):0<=at?si.ab(pn):pn.ab(si)}else si=0<=at?yr.ab(rt):rt.ab(yr);Zn!==Pu&&(pn=oe.computeAngle(tt,Zn,si),tt.Kb=pn),pn=yr.x+(rt.x-yr.x)*gt-y.x,yr=yr.y+(rt.y-yr.y)*gt-y.y}tt.measure(1/0,1/0,0,0),rt=tt.measuredBounds,Nn=tt.naturalBounds;var Io=0;tt instanceof Dr&&(Io=tt.strokeWidth),sr=Nn.width+Io;var Oa=Nn.height+Io;Ce.reset(),Ce.translate(-rt.x,-rt.y),Ce.scale(tt.scale,tt.scale),Ce.rotate(Zn===Pu?tt.angle:si,sr/2,Oa/2),Zn!==bp&&Zn!==Mp||Ce.rotate(90,sr/2,Oa/2),Zn!==Lp&&Zn!==kp||Ce.rotate(-90,sr/2,Oa/2),Zn===nv&&(45<si&&135>si||225<si&&315>si)&&Ce.rotate(-si,sr/2,Oa/2),Nn=new Xt(0,0,sr,Oa),Ae.xi(Nn,At),Ce.Ga(Ae),At=-Ae.x+Io/2*tt.scale,tt=-Ae.y+Io/2*tt.scale,Ye.assign(mi),Io=isNaN(mi.x);var gl=isNaN(mi.y);if(Io||gl){sr=sr/2+3,Oa=Oa/2+3;var wl=45<=si&&135>=si,hu=225<=si&&315>=si;Zn===Pu&&(wl||hu)?(Ye.x=gl?sr:mi.y,Ye.y=Io?Oa:mi.x,wl?0<=at||isNaN(at)&&.5>gt||!Io||(Ye.y=-Oa):hu&&((0<=at||isNaN(at)&&.5>gt)&&Io&&(Ye.y=-Oa),gl&&(Ye.x=-sr))):(Io&&(Ye.x=0<=at||isNaN(at)&&.5>gt?sr:-sr),gl&&(Ye.y=-Oa),Ye.rotate(si))}else Ye.rotate(si);pn+=Ye.x,yr+=Ye.y,Nn.set(rt),Nn.h(pn+At,yr+tt,rt.width,rt.height),ye.push(Nn),x.ed(Nn)}}if(ee!==null)for(E=ee.labelNodes;E.next();)E.value.measure(1/0,1/0);a.jg=x,a.position.h(y.x+x.x,y.y+x.y),Ll(b,x.width||0,x.height||0),kr.free(Ce),Qe.free(Ae),Qe.free(Ye)}}}},Lm.prototype.arrange=function(a,y){var x=y.length;if(a instanceof Fo||a instanceof Tn){var E=a,b=null;a instanceof Fo&&(b=a,E=b.adornedPart);var z=a instanceof Fo?null:E.path,ee=a.j;if(ee.length!==0){var re=0;if(z!==null&&re<ee.length){var oe=ee[re];re++,z.arrange(oe.x-a.jg.x,oe.y-a.jg.y,oe.width,oe.height)}for(oe=0;oe<x;oe++){var se=y[oe];if(se!==z&&re<ee.length){var ue=ee[re];re++,se.arrange(ue.x-a.jg.x,ue.y-a.jg.y,ue.width,ue.height)}}}if(y=E.points,x=y.count,2<=x&&a instanceof Tn)for(z=a.labelNodes;z.next();){var fe=a;ee=z.value,re=ee.segmentIndex,oe=ee.segmentFraction;var ve=ee.alignmentFocus;if(se=ee.segmentOrientation,ue=ee.segmentOffset,isNaN(re)){var ye=fe.ua,Ce=qi();ye.Qu(oe,Ce);var Ae=Qe.allocAt(Ce[0],Ce[1]);Ae.add(fe.i(0)),ye.type===Bn.j||(ye=ye.figures.first()),Ae.offset(-ye.startX,-ye.startY),ye=Ce[2],se!==Pu&&(fe=fe.computeAngle(ee,se,ye),ee.angle=fe),fe=Ae.x;var Ye=Ae.y;Qe.free(Ae),Zi(Ce)}else if(re<-x||re>=x)Ce=Qe.alloc(),ye=fe,Ye=Ce,ye.vg(),ye.computeMidPoint(Ye),ye=fe.midAngle,se!==Pu&&(fe=fe.computeAngle(ee,se,ye),ee.angle=fe),fe=Ce.x,Ye=Ce.y,Qe.free(Ce);else{if(Ae=0,0<=re?(Ce=y.s[re],Ye=re<x-1?y.s[re+1]:Ce):(Ae=x+re,Ce=y.s[Ae],Ye=0<Ae?y.s[Ae-1]:Ce),Ce.Xa(Ye)){0<=re?(ye=0<re?y.s[re-1]:Ce,Ae=re<x-2?y.s[re+2]:Ye):(ye=Ae<x-1?y.s[Ae+1]:Ce,Ae=1<Ae?y.s[Ae-2]:Ye);var We=ye.Bf(Ce),tt=Ye.Bf(Ae);ye=We>tt+10?0<=re?ye.ab(Ce):Ce.ab(ye):tt>We+10?0<=re?Ye.ab(Ae):Ae.ab(Ye):0<=re?ye.ab(Ae):Ae.ab(ye)}else ye=0<=re?Ce.ab(Ye):Ye.ab(Ce);se!==Pu&&(fe=fe.computeAngle(ee,se,ye),ee.angle=fe),fe=Ce.x+(Ye.x-Ce.x)*oe,Ye=Ce.y+(Ye.y-Ce.y)*oe}if(ve.ys())ee.location=new Qe(fe,Ye);else{ve.Mc()&&(ve=ko),Ce=kr.alloc(),Ce.reset(),Ce.scale(ee.scale,ee.scale),Ce.rotate(ee.angle,0,0);var rt=ee.naturalBounds;Ae=Xt.allocAt(0,0,rt.width,rt.height),We=Qe.alloc(),We.xi(Ae,ve),Ce.Ga(We),ve=-We.x,tt=-We.y;var at=rt.width,gt=rt.height;rt=Qe.alloc(),rt.assign(ue);var At=isNaN(ue.x),Zn=isNaN(ue.y);if(At||Zn){at=at/2+3,gt=gt/2+3;var mi=45<=ye&&135>=ye,si=225<=ye&&315>=ye;se===Pu&&(mi||si)?(rt.x=Zn?at:ue.y,rt.y=At?gt:ue.x,mi?0<=re||isNaN(re)&&.5>oe||!At||(rt.y=-gt):si&&((0<=re||isNaN(re)&&.5>oe)&&At&&(rt.y=-gt),Zn&&(rt.x=-at))):(At&&(rt.x=0<=re||isNaN(re)&&.5>oe?at:-at),Zn&&(rt.y=-gt),rt.rotate(ye))}else rt.rotate(ye);fe+=rt.x,Ye+=rt.y,Ce.pp(Ae),ve+=Ae.x,tt+=Ae.y,re=Qe.allocAt(fe+ve,Ye+tt),ee.move(re),Qe.free(re),Qe.free(rt),Qe.free(We),Xt.free(Ae),kr.free(Ce)}}b!==null?b.Ul(!1):E.Ul(!1),E=TS(a),a.location.h(a.position.x+E.x,a.position.y+E.y),Qe.free(E)}};function iS(a,y,x,E){if(ph(E)!==!1){var b=E.strokeWidth;b===0&&a instanceof Fo&&a.type===Ln.Link&&a.adornedObject instanceof Dr&&(b=a.adornedObject.strokeWidth),b*=E.Ca,a instanceof Tn&&a.ua!==null?(a=a.geometry.bounds,E.Ge(a.x-b/2,a.y-b/2,a.width+b,a.height+b)):a instanceof Fo&&a.adornedPart.ua!==null?(a=a.adornedPart.ua.bounds,E.Ge(a.x-b/2,a.y-b/2,a.width+b,a.height+b)):E.Ge(-(b/2),-(b/2),y+b,x+b),b=E.desiredSize,b.w()||E.ua===null?E.dc.h(0,0,b.width,b.height):E.dc.assign(E.ua.bounds),Ys(E,!1)}}function fp(){this.xa="Base"}Ct(fp,qs),fp.prototype.measure=function(a,y,x,E,b,z,ee){var re=a.Pb();a.graduatedBounds=[];var oe=re.margin,se=oe.right+oe.left,ue=oe.top+oe.bottom;re.measure(y,x,z,ee);var fe=re.measuredBounds,ve=new Xt(-oe.left,-oe.top,Math.max(fe.width+se,0),Math.max(fe.height+ue,0));a.graduatedBounds.push(ve),b.assign(ve);for(var ye=re.geometry,Ce=re.strokeWidth,Ae=ye.flattenedSegments,Ye=ye.flattenedLengths,We=ye.flattenedTotalLength,tt=Ae.length,rt=0,at=0,gt=qi(),At=0;At<tt;At++){var Zn=Ae[At],mi=[];at=rt=0;for(var si=Zn.length,Nn=0;Nn<si;Nn+=2){var pn=Zn[Nn],yr=Zn[Nn+1];if(Nn!==0){var sr=180*Math.atan2(yr-at,pn-rt)/Math.PI;0>sr&&(sr+=360),mi.push(sr)}rt=pn,at=yr}gt.push(mi)}if(a.graduatedIntervals===null){for(var Io=[],Oa=a.O.s,gl=Oa.length,wl=0;wl<gl;wl++){var hu=Oa[wl],pl=[];if(Io.push(pl),hu.visible){var Nd=hu.interval;if(!(0>Nd)){for(var Gs=0;Gs<gl;Gs++)if(Gs!==wl){var Sc=Oa[Gs];if(Sc.visible&&hu.constructor===Sc.constructor){var cu=Sc.interval;cu>Nd&&pl.push(cu)}}}}}a.graduatedIntervals=Io}var Td=a.graduatedIntervals,Sh=a.O.s,Jh=Sh.length,rh=0,Uu=0,rf=We;a.graduatedMarks=[];for(var xc,Vg=0;Vg<Jh;Vg++){var oh=Sh[Vg];if(xc=[],oh.visible&&oh!==re){var du=Math.abs(oh.interval),qp=a.graduatedTickUnit;if(!(2>qp*du*We/a.graduatedRange&&oh.graduatedSkip===null)){var eg=Ye[0][0],Tc=0,Zu=0;Uu=We*oh.graduatedStart-1e-4,rf=We*oh.graduatedEnd+1e-4;var Mf=qp*du,ah=a.graduatedTickBase;if(ah<a.graduatedMin){var of=(a.graduatedMin-ah)/Mf;of=of%1===0?of:Math.floor(of+1),ah+=of*Mf}else ah>a.graduatedMin+Mf&&(ah-=Math.floor((ah-a.graduatedMin)/Mf)*Mf);for(var Vv=Td[Vg],$p=ah,Hy=1e-6*a.graduatedMax,Qc=1;ah<=a.graduatedMax+Hy;Qc++){e:{for(var ud=Vv.length,tg=0;tg<ud;tg++){var af=(ah-a.graduatedTickBase)%(Vv[tg]*a.graduatedTickUnit),Ug=1e-6*a.graduatedTickUnit;if(af<Ug&&af>-Ug){var sf=!1;break e}}sf=!0}if(sf&&(ah>a.graduatedMax&&(ah=a.graduatedMax),oh.graduatedSkip===null||oh instanceof ja&&!oh.graduatedSkip(ah,oh)||oh instanceof Dr&&!oh.graduatedSkip(ah,oh))&&(rh=(ah-a.graduatedMin)*We/a.graduatedRange,rh>We&&(rh=We),Uu<=rh&&rh<=rf)){for(var qc=gt[Tc][Zu],Dd=Ye[Tc][Zu];Tc<Ye.length;){for(;rh>eg&&Zu<Ye[Tc].length-1;)Zu++,qc=gt[Tc][Zu],Dd=Ye[Tc][Zu],eg+=Dd;if(rh<=eg)break;Tc++,Zu=0,qc=gt[Tc][Zu],Dd=Ye[Tc][Zu],eg+=Dd}var _u=Ae[Tc],Dc=_u[2*Zu],Uv=_u[2*Zu+1],hd=(rh-(eg-Dd))/Dd,Zg=new Qe(Dc+(_u[2*Zu+2]-Dc)*hd+Ce/2-ye.bounds.x,Uv+(_u[2*Zu+3]-Uv)*hd+Ce/2-ye.bounds.y);Zg.scale(re.scale,re.scale);e:{var wc=qc,kf=gt[Tc];if(!(.5005>hd&&.4995<hd)){var Bc=wc;if(.5>hd?0<Zu?Bc=kf[Zu-1]:yt.$(_u[0],_u[_u.length-2])&&yt.$(_u[1],_u[_u.length-1])&&(Bc=kf[kf.length-1]):.5<hd&&(Zu+1<kf.length?Bc=kf[Zu+1]:yt.$(_u[0],_u[_u.length-2])&&yt.$(_u[1],_u[_u.length-1])&&(Bc=kf[0])),wc!==Bc){var ng=Math.abs(wc-Bc);if(180<ng&&(wc<Bc?wc+=360:Bc+=360,ng=Math.abs(wc-Bc)),5e-4>hd||.9995<hd){qc=(wc+Bc)/2%360;break e}if(10>ng){var _g=1-Math.abs(.5-hd);qc=(wc*_g+Bc*(1-_g))%360;break e}}}qc=wc}if(oh instanceof ja){var hc="";oh.graduatedFunction!==null?(hc=oh.graduatedFunction(ah,oh),hc=hc!=null?hc.toString():""):hc=(+ah.toFixed(2)).toString(),hc!==""&&xc.push({$l:Zg,angle:qc,text:hc})}else xc.push({$l:Zg,angle:qc})}ah=$p+Qc*Mf}}}a.graduatedMarks.push(xc)}Zi(gt);var Al=a.graduatedMarks;if(Al!==null)for(var em=E.length,Mu=0;Mu<em;Mu++){var Ks=E[Mu],ku=Al[Mu];if(Ks.visible&&Ks!==re&&ku.length!==0){if(Ks instanceof Dr){var cd=a,Bd=b,Ff=Ks.alignmentFocus;Ff.Mc()&&(Ff=_l);var Gy=Ks.angle;Ks.Kb=0,Ks.measure(1/0,1/0,0,0),Ks.Kb=Gy;var Zv=Ks.measuredBounds,Yg=Zv.width,Af=Zv.height,ig=Xt.allocAt(0,0,Yg,Af),Yu=Qe.alloc();Yu.xi(ig,Ff),Xt.free(ig);for(var dd=-Yu.x,Pc=-Yu.y,jh=new Xt,lf=ku.length,Xg=0;Xg<lf;Xg++)for(var uf=ku[Xg],_v=uf.$l.x,Jg=uf.$l.y,Ts=uf.angle,cc=0;4>cc;cc++){switch(cc){case 0:Yu.h(dd,Pc);break;case 1:Yu.h(dd+Yg,Pc);break;case 2:Yu.h(dd,Pc+Af);break;case 3:Yu.h(dd+Yg,Pc+Af)}Yu.rotate(Ts+Ks.angle),Yu.offset(_v,Jg),Xg===0&&cc===0?jh.h(Yu.x,Yu.y,0,0):jh.Ye(Yu),Yu.offset(-_v,-Jg),Yu.rotate(-Ts-Ks.angle)}Qe.free(Yu),cd.graduatedBounds!==null&&cd.graduatedBounds.push(jh),es(Bd,jh.x,jh.y,jh.width,jh.height)}else if(Ks instanceof ja){var Qh=a,Yv=b;Qh.temporaryTextBlock===null&&(Qh.temporaryTextBlock=new ja);var sh=Qh.temporaryTextBlock;yS(sh,Ks);var Od=Ks.alignmentFocus;Od.Mc()&&(Od=_l);for(var qh=Ks.segmentOrientation,Qg=Ks.segmentOffset,hf=new Xt,tm=0,qg=0,Oc=0,Nf=0,cf=0,$g=ku.length,Rd=0;Rd<$g;Rd++){var $c=ku[Rd];tm=$c.$l.x,qg=$c.$l.y,Oc=$c.angle,cf=Nf=Ks.angle,qh!==Pu&&(cf=qh===Ep||qh===tv?Oc+Ks.angle:Oc,Nf=Tn.computeAngle(qh,cf)),sh.Kb=Nf,sh.text=$c.text||"",sh.measure(1/0,1/0,0,0);var Id=sh.measuredBounds,fd=sh.naturalBounds,jd=fd.width,Tf=fd.height,Cc=kr.alloc();Cc.reset(),Cc.translate(-Id.x,-Id.y),Cc.scale(sh.scale,sh.scale),Cc.rotate(cf,jd/2,Tf/2),qh!==bp&&qh!==Mp||Cc.rotate(90,jd/2,Tf/2),qh!==Lp&&qh!==kp||Cc.rotate(-90,jd/2,Tf/2),qh===nv&&(45<Oc&&135>Oc||225<Oc&&315>Oc)&&Cc.rotate(-Oc,jd/2,Tf/2);var rg=Xt.allocAt(0,0,jd,Tf),zd=Qe.alloc();zd.xi(rg,Od),Cc.Ga(zd);var og=-zd.x,Ky=-zd.y,gd=Qe.alloc();gd.assign(Qg),isNaN(gd.x)&&(gd.x=jd/2+3),isNaN(gd.y)&&(gd.y=-(Tf/2+3)),gd.rotate(Oc),tm+=gd.x+og,qg+=gd.y+Ky;var Df=new Xt(tm,qg,Id.width,Id.height),nm=new Xt(Id.x,Id.y,Id.width,Id.height),Wy=new Xt(fd.x,fd.y,fd.width,fd.height);$c.Sz=Nf,$c.lineCount=sh.lineCount,$c.lines=[sh.Cb,sh.Ih,sh.df,sh.Le,sh.Qc,sh.Qb,sh.ze],$c.actualBounds=Df,$c.measuredBounds=nm,$c.naturalBounds=Wy,Rd===0?hf.assign(Df):hf.ed(Df),Qe.free(gd),Qe.free(zd),Xt.free(rg),kr.free(Cc)}Qh.graduatedBounds!==null&&Qh.graduatedBounds.push(hf),es(Yv,hf.x,hf.y,hf.width,hf.height)}Ys(Ks,!1)}}},fp.prototype.arrange=function(a,y,x){if(a.graduatedBounds!==null){var E=a.Pb(),b=a.graduatedMarks;if(b!==null){var z=a.graduatedBounds,ee=0,re=z[ee];ee++,E!==null&&E.arrange(re.x-x.x,re.y-x.y,re.width,re.height);for(var oe=y.length,se=0;se<oe;se++){var ue=y[se];re=b[se],ue.visible&&ue!==E&&re.length!==0&&(re=z[ee],ee++,ue.arrange(re.x-x.x,re.y-x.y,re.width,re.height))}a.graduatedBounds=null}}},fp.prototype.gc=function(a,y,x){var E=x.$i;x.$i=!0;var b=a.naturalBounds,z=b.width,ee=b.height;b=y instanceof th,y.save(),y.beginPath(),y.rect(-1,-1,z+1,ee+1),y.clip(),y.Se(),z=a.Pb(),z.gc(y,x),ee=a.Df()*x.scale,0>=ee&&(ee=1);for(var re=z.actualBounds,oe=a.O.s,se=a.graduatedMarks,ue=oe.length,fe=0;fe<ue;fe++){var ve=oe[fe],ye=se[fe],Ce=ye.length;if(ve.visible&&ve!==z&&ye.length!==0){if(ve instanceof Dr){if(!(2>a.graduatedTickUnit*ve.interval*z.geometry.flattenedTotalLength/a.graduatedRange*ee&&ve.graduatedSkip===null)){var Ae=ve.measuredBounds,Ye=ve.strokeWidth*ve.scale,We=ve.alignmentFocus;We.Mc()&&(We=_l);for(var tt=0;tt<Ce;tt++){var rt=ye[tt].$l,at=ye[tt].angle,gt=We,At=ve.Ab;At.reset(),At.translate(rt.x+re.x,rt.y+re.y),At.rotate(at+ve.angle,0,0),At.translate(-Ae.width*gt.x+gt.offsetX+Ye/2,-Ae.height*gt.y+gt.offsetY+Ye/2),At.scale(ve.scale,ve.scale),Uh(ve,!1),ve.wh.set(ve.Ab),ve.Kk=ve.scale,Nh(ve,!1),ve.gc(y,x),b&&(a.svg.appendChild(ve.svg),ve.svg=null),ve.Ab.reset()}}}else if(ve instanceof ja)for(a.temporaryTextBlock===null&&(a.temporaryTextBlock=new ja),Ae=a.temporaryTextBlock,yS(Ae,ve),Ye=0;Ye<Ce;Ye++)We=ye[Ye],We.actualBounds&&We.measuredBounds&&We.naturalBounds&&(Ae.ec=We.text||"",Ae.Kb=We.Sz||0,Ae.Gc=We.lineCount||0,tt=We.lines,tt!==void 0&&(Ae.Cb=tt[0],Ae.Ih=tt[1],Ae.df=tt[2],Ae.Le=tt[3],Ae.Qc=tt[4],Ae.Qb=tt[5],Ae.ze=tt[6]),We.naturalBounds&&(Ae.dc=We.naturalBounds),We.actualBounds&&(tt=We.actualBounds,Ae.arrange(tt.x,tt.y,tt.width,tt.height)),tt=We.actualBounds,Ae.arrange(tt.x,tt.y,tt.width,tt.height),rt=We.measuredBounds,We=We.naturalBounds,at=Ae.Ab,at.reset(),at.translate(tt.x+re.x,tt.y+re.y),at.translate(-rt.x,-rt.y),Ae.no(at,We.x,We.y,We.width,We.height),Uh(Ae,!1),Ae.wh.set(Ae.Ab),Ae.Kk=Ae.scale,Nh(Ae,!1),Ae.Ng=ve.part,Ae.Me=ve.panel,Ae.gc(y,x),Ae.Me=null,Ae.Ng=null,b&&(a.svg.appendChild(Ae.svg),Ae.svg=null))}}x.$i=E,y.restore(),y.Vc(!0)};function Ln(a,y){if(mt.call(this),this.na=null,a===void 0)this.na=Ln.Position;else if(typeof a=="string"){var x=rc.I(a);x!==null&&(this.na=x)}else a instanceof qs?this.na=a:a&&(this.na=Ln.Position,y=a);this.na===null&&Dt("Panel type not specified or PanelLayout not loaded: "+a),this.l=this.l|4194304|(this.na===Ln.Grid?1048576:0),this.O=new An,this.yb=Tl,this.Tm=vs,this.Uf=Cr,this.$g=null,this.$e="",this.jg=new Xt(NaN,NaN,NaN,NaN),this.T=this.F=null,this.xo=xi,this.jn=ms,this.kn=bs,this.ub=this.ra=null,this.zn=NaN,this.ge=this.Hh=null,y&&Object.assign(this,y)}Ct(Ln,mt),Ln.prototype.cloneProtected=function(a){mt.prototype.cloneProtected.call(this,a),a.na=this.na,a.yb=this.yb.J(),a.Tm=this.Tm.J(),a.Uf=this.Uf,a.$e=this.$e,a.jg.assign(this.jg),this.T!==null&&(a.T=this.T.copy(a)),a.xo=this.xo,a.jn=this.jn.J(),a.kn=this.kn.J(),this.ra!==null&&(a.ra=this.ra.copy()),a.ub=this.ub,a.zn=this.zn,a.Hh=this.Hh},Ln.prototype.Af=function(a){mt.prototype.Af.call(this,a),a.O=this.O;for(var y=a.O.s,x=y.length,E=0;E<x;E++)y[E].Me=a;a.$g=null},Ln.prototype.copy=function(){var a=mt.prototype.copy.call(this);if(a!==null){for(var y=this.O.s,x=y.length,E=0;E<x;E++){var b=y[E].copy();b.wi(a),b.Ng=null;var z=a.O,ee=z.count;if(z.Gb(ee,b),z=a.part,z!==null){z.Rh=null,b.portId!==null&&z instanceof qn&&(z.Te=!0);var re=a.diagram;re!==null&&re.undoManager.isUndoingRedoing||z.cb(ts,"elements",a,null,b,null,ee)}}return a}return null},we=Ln.prototype,we.toString=function(){return"Panel("+this.type.name+")#"+qa(this)},we.Pn=function(a){mt.prototype.Pn.call(this,a);for(var y=this.O.s,x=y.length,E=0;E<x;E++)y[E].Pn(a)},we.hh=function(a,y){if(this.na===Ln.Grid)a.yc(),this.na.gc(this,a,y);else if(this.na===Ln.Graduated)a.yc(),this.na.gc(this,a,y);else{if(this.na===Ln.Table)if(a.yc(),a instanceof th){var x=a.yd;a.yd=fm(a,"gojs-ts"),g0(this,a),a.nh.pop(),a.yd=x}else g0(this,a);(x=this.isClipping&&this.na===Ln.Spot)&&a.save();for(var E=this.Pb(),b=this.O.s,z=b.length,ee=0;ee<z;ee++){var re=b[ee];x&&re===E&&(a.clipInsteadOfFill=!0),re.gc(a,y),x&&re===E&&(a.clipInsteadOfFill=!1)}x&&(a.restore(),a.Vc(!0))}};function g0(a,y){y.lineCap="butt";var x=0<a.rowCount?a.rowDefs:null,E=0<a.columnCount?a.colDefs:null;x!==null&&Mm(a,y,!0,x,!0),E!==null&&Mm(a,y,!1,E,!0),x!==null&&rS(a,y,!0,x),E!==null&&rS(a,y,!1,E),x!==null&&Mm(a,y,!0,x,!1),E!==null&&Mm(a,y,!1,E,!1)}function rS(a,y,x,E){for(var b=E.length,z=a.actualBounds,ee=a.naturalBounds,re=!0,oe=0;oe<b;oe++){var se=E[oe];if(se!==void 0&&se.actual!==0)if(re)re=!1;else{if(x){if(se.position>ee.height)continue}else if(se.position>ee.width)continue;var ue=se.separatorStrokeWidth;isNaN(ue)&&(ue=x?a.defaultRowSeparatorStrokeWidth:a.defaultColumnSeparatorStrokeWidth);var fe=se.separatorStroke;if(fe===null&&(fe=x?a.defaultRowSeparatorStroke:a.defaultColumnSeparatorStroke),ue!==0&&fe!==null){ks(a,y,fe,!1,!1,ee,z),fe=!1;var ve=se.separatorDashArray;ve===null&&(ve=x?a.defaultRowSeparatorDashArray:a.defaultColumnSeparatorDashArray),ve!==null&&(fe=!0,y.js(ve,0)),y.beginPath(),ve=se.position+ue,x?ve>ee.height&&(ue-=ve-ee.height):ve>ee.width&&(ue-=ve-ee.width),se=se.position+ue/2,y.lineWidth=ue,ue=a.yb,x?(se+=ue.top,ve=ee.width-ue.right,y.moveTo(ue.left,se),y.lineTo(ve,se)):(se+=ue.left,ve=ee.height-ue.bottom,y.moveTo(se,ue.top),y.lineTo(se,ve)),y.stroke(),y.Se(),fe&&y.fs()}}}}function Mm(a,y,x,E,b){for(var z=E.length,ee=a.actualBounds,re=a.naturalBounds,oe=oS(a,!0),se=oS(a,!1),ue=0;ue<z;ue++){var fe=E[ue];if(fe!==void 0&&fe.background!==null&&fe.coversSeparators!==b&&fe.actual!==0){var ve=x?ee.height:ee.width;if(!(fe.position>ve)){var ye=fe.Wc(),Ce=fe.separatorStrokeWidth;isNaN(Ce)&&(Ce=x?a.defaultRowSeparatorStrokeWidth:a.defaultColumnSeparatorStrokeWidth);var Ae=fe.separatorStroke;Ae===null&&(Ae=x?a.defaultRowSeparatorStroke:a.defaultColumnSeparatorStroke),(Ae===null||fe.index===(x?oe:se))&&(Ce=0),ye-=Ce,Ce=fe.position+Ce,ye+=fe.actual,Ce+ye>ve&&(ye=ve-Ce),0>=ye||(ve=a.yb,ks(a,y,fe.background,!0,!1,re,ee),x?y.fillRect(ve.left,Ce+ve.top,ee.width-(ve.left+ve.right),ye):y.fillRect(Ce+ve.left,ve.top,ye,ee.height-(ve.top+ve.bottom)))}}}}function oS(a,y){for(var x=y?a.rowCount:a.columnCount,E=0;E<x;E++){var b=y?a.rowDefs[E]:a.colDefs[E];if(b!==void 0)return b.index}return 0}function p0(a){return a==="LineV"||a==="BarV"}we.lv=function(){for(var a=this.O.s,y=a.length,x=0;x<y;x++)a[x].lv();this.Uc=!0},we.kk=function(a,y,x){if(!mt.prototype.kk.call(this,a,y,x))return!1;if(this.type===Ln.Table)x=this.svg.getElementsByClassName("gojs-ts"),x=x.length!==0?x[0]:null,x!==null&&(x.innerHTML=""),a.yd=x,g0(this,a),a.yd=null;else if(this.na===Ln.Grid||this.na===Ln.Graduated)return this.svg.innerHTML="",this.svg.remove(),!1;x=this.O.s;for(var E=x.length,b=0;b<E;b++)x[b].gc(a,y);return!0},we.nk=function(){return!0},we.$o=function(a,y,x,E){if(!this.isClipping)if(this.Dd()&&a.bk!==null){a=a.bk,y=this.O.s;for(var b=0,z=0,ee=0;ee<y.length;ee++)if(y[ee].Ed()){var re=y[ee].actualBounds;b=ee===0?re.x:Math.min(re.x,b),z=ee===0?re.y:Math.min(re.y,z)}E.setAttributeNS(null,"clip-path","path('M "+(a.x-x.x-b)+","+(a.y-x.y-z)+" l "+a.width+" 0 l 0 "+a.height+" l -"+a.width+" 0 z')")}else mt.prototype.$o.call(this,a,y,x,E)},we.Sj=function(a,y,x,E,b){var z=this.se(),ee=this.transform,re=1/(ee.m11*ee.m22-ee.m12*ee.m21),oe=ee.m22*re,se=-ee.m12*re,ue=-ee.m21*re,fe=ee.m11*re,ve=re*(ee.m21*ee.dy-ee.m22*ee.dx),ye=re*(ee.m12*ee.dx-ee.m11*ee.dy);if(this.areaBackground!==null)return ee=this.actualBounds,yt.Ff(ee.left,ee.top,ee.right,ee.bottom,a,y,x,E,b);if(this.background!==null)return z=a*oe+y*ue+ve,re=a*se+y*fe+ye,a=x*oe+E*ue+ve,oe=x*se+E*fe+ye,b.h(0,0),x=this.naturalBounds,z=yt.Ff(0,0,x.width,x.height,z,re,a,oe,b),b.transform(ee),z;z||(oe=1,ue=se=0,fe=1,ye=ve=0),re=a*oe+y*ue+ve,a=a*se+y*fe+ye,oe=x*oe+E*ue+ve,x=x*se+E*fe+ye,b.h(oe,x),E=(oe-re)*(oe-re)+(x-a)*(x-a),se=!1,fe=this.O.s,ye=fe.length,ue=Qe.alloc(),ve=null,y=1/0;var Ce=null,Ae=this.isClipping&&this.na===Ln.Spot;Ae&&(Ce=Qe.alloc(),ve=this.Pb(),(se=ve.Sj(re,a,oe,x,Ce))&&(y=(re-Ce.x)*(re-Ce.x)+(a-Ce.y)*(a-Ce.y)));for(var Ye=0;Ye<ye;Ye++){var We=fe[Ye];We.visible&&We!==ve&&We.Sj(re,a,oe,x,ue)&&(se=!0,We=(re-ue.x)*(re-ue.x)+(a-ue.y)*(a-ue.y),We<E&&(E=We,b.set(ue)))}return Ae&&(y>E&&b.set(Ce),Qe.free(Ce)),Qe.free(ue),z&&b.transform(ee),se},we.Gj=function(){for(var a=this.O.s,y=a.length,x=0;x<y;x++)a[x].Gj();mt.prototype.Gj.call(this)},we.v=function(a){if(!ph(this)){mt.prototype.v.call(this,a),a=null,(this.na===Ln.Auto||this.na===Ln.Link)&&(a=this.Pb());for(var y=this.O.s,x=y.length,E=0;E<x;E++){var b=y[E];if((b===a||b.isPanelMain)&&b.v(!0),!b.desiredSize.w()){var z=Ou(b,!1);(b instanceof wu||b instanceof Ln||b instanceof ja||z!==mn)&&b.v(!0)}}}},we.Uj=function(){if(!ph(this)){Ys(this,!0),Hc(this,!0);for(var a=this.O.s,y=a.length,x=0;x<y;x++)a[x].Uj()}},we.Uk=function(){if(!(this.l&2048)){Uh(this,!0),Nh(this,!0);for(var a=this.O.s,y=a.length,x=0;x<y;x++)a[x].Wu()}},we.Wu=function(){Nh(this,!0);for(var a=this.O.s,y=a.length,x=0;x<y;x++)a[x].Wu()},we.Wl=function(a,y,x,E){var b=this.jg;b.h(0,0,0,0);var z=this.desiredSize,ee=this.minSize;x===void 0&&(x=ee.width,E=ee.height),x=Math.max(x,ee.width),E=Math.max(E,ee.height);var re=this.maxSize;isNaN(z.width)||(a=Math.min(z.width,re.width)),isNaN(z.height)||(y=Math.min(z.height,re.height)),a=Math.max(x,a),y=Math.max(E,y);var oe=this.yb;a=Math.max(a-oe.left-oe.right,0),y=Math.max(y-oe.top-oe.bottom,0);var se=this.O.s;se.length!==0&&this.na.measure(this,a,y,se,b,x,E),a=b.width+oe.left+oe.right,oe=b.height+oe.top+oe.bottom,isFinite(z.width)&&(a=z.width),isFinite(z.height)&&(oe=z.height),a=Math.min(re.width,a),oe=Math.min(re.height,oe),a=Math.max(ee.width,a),oe=Math.max(ee.height,oe),a=Math.max(x,a),oe=Math.max(E,oe),Ll(b,a,oe),Ll(this.naturalBounds,a,oe),this.Ge(0,0,a,oe)},we.Pb=function(){if(this.$g===null){var a=this.O.s,y=a.length;if(y===0)return null;for(var x=0;x<y;x++){var E=a[x];if(E.isPanelMain===!0)return this.$g=E}this.$g=a[0]}return this.$g};function ad(a){return a.part!==null?a.part.locationObject:null}we.eh=function(a,y,x,E){var b=this.O.s;if(this.actualBounds.h(a,y,x,E),b.length!==0){if(!this.desiredSize.w()){a=Ou(this,!0);var z=this.measuredBounds;y=z.width,z=z.height;var ee=this.Kg,re=ee.left+ee.right;switch(ee=ee.top+ee.bottom,y===x&&z===E&&(a=mn),a){case mn:(y>x||z>E)&&(this.v(),this.measure(y>x?x:y,z>E?E:z,0,0));break;case Cn:this.v(!0),this.measure(x+re,E+ee,0,0);break;case Mi:this.v(!0),this.measure(x+re,z+ee,0,0);break;case Yi:this.v(!0),this.measure(y+re,E+ee,0,0)}}this.na.arrange(this,b,this.jg)}},we.gh=function(a){var y=this.naturalBounds,x=ad(this);if(Ds(0,0,y.width,y.height,a.x,a.y)){y=this.O.s;for(var E=y.length,b=Qe.allocAt(0,0);E--;){var z=y[E];if((z.visible||z===x)&&(Ua(b.set(a),z.transform),z.ca(b)))return Qe.free(b),!0}return Qe.free(b),!(this.Ma===null&&this.areaBackground===null)}return!1},we.ks=function(a){if(this.bindingId===a)return this;for(var y=this.O.s,x=y.length,E=0;E<x;E++){var b=y[E].ks(a);if(b!==null)return b}return null},we.qm=function(a,y){if(y(this,a),a instanceof Ln){a=a.O.s;for(var x=a.length,E=0;E<x;E++)this.qm(a[E],y)}};function Sf(a,y){aS(a,a,y)}function aS(a,y,x){x(y),y=y.O.s;for(var E=y.length,b=0;b<E;b++){var z=y[b];z instanceof Ln&&aS(a,z,x)}}function vx(a,y){sS(a,a,y)}function sS(a,y,x){if(x(y),y instanceof Ln){y=y.O.s;for(var E=y.length,b=0;b<E;b++)sS(a,y[b],x)}}we.Nl=function(a){return lS(this,this,a)};function lS(a,y,x){if(x(y))return y;if(y instanceof Ln){y=y.O.s;for(var E=y.length,b=0;b<E;b++){var z=lS(a,y[b],x);if(z!==null)return z}}return null}we.fb=function(a){if(this.name===a)return this;var y=this.O.s,x=y.length;this.Hh===null&&this.itemTemplateMap===null||(x=gp(this));for(var E=0;E<x;E++){var b=y[E];if(b instanceof Ln){var z=b.fb(a);if(z!==null)return z}if(b.name===a)return b}return null};function uS(a){a=a.O.s;for(var y=a.length,x=0,E=0;E<y;E++){var b=a[E];b instanceof Ln?x=Math.max(x,uS(b)):b instanceof Dr&&(x=Math.max(x,b.ig/2*b.strokeMiterLimit*b.Df()))}return x}we.se=function(){return!(this.type===Ln.TableRow||this.type===Ln.TableColumn)};function wd(a){return a.type===Ln.TableRow||a.type===Ln.TableColumn}we.ic=function(a,y,x){if(this.pickable===!1||(y===void 0&&(y=null),x===void 0&&(x=null),Su(this)))return null;var E=this.naturalBounds,b=1/this.Df(),z=this.se(),ee=z?a:Ua(Qe.allocAt(a.x,a.y),this.transform),re=this.diagram,oe=10,se=5;if(re!==null&&(oe=re.Ql("extraTouchArea"),se=oe/2),Ds(-(se*b),-(se*b),E.width+oe*b,E.height+oe*b,ee.x,ee.y)){if(!this.isAtomic){b=this.O.s;var ue=b.length;if(re=Qe.alloc(),se=(oe=this.isClipping&&this.na===Ln.Spot)?this.Pb():null,oe&&(se.se()?Ua(re.set(a),se.transform):re.set(a),!se.ca(re)))return Qe.free(re),z||Qe.free(ee),null;for(var fe=ad(this);ue--;){var ve=b[ue];if((ve.visible||ve===fe)&&(ve.se()?Ua(re.set(a),ve.transform):re.set(a),!oe||ve!==se)){var ye=null;if(ve instanceof Ln?ye=ve.ic(re,y,x):ve.pickable===!0&&ve.ca(re)&&(ye=ve),ye!==null&&(y!==null&&(ye=y(ye)),ye!==null&&(x===null||x(ye))))return Qe.free(re),z||Qe.free(ee),ye}}Qe.free(re)}return this.background===null&&this.areaBackground===null?(z||Qe.free(ee),null):(a=Ds(0,0,E.width,E.height,ee.x,ee.y)?this:null,z||Qe.free(ee),a)}return z||Qe.free(ee),null},we.ji=function(a,y,x,E){if(this.pickable===!1)return!1;y===void 0&&(y=null),x===void 0&&(x=null);var b=this.naturalBounds,z=this.se(),ee=z?a:Ua(Qe.allocAt(a.x,a.y),this.transform);if(b=Ds(0,0,b.width,b.height,ee.x,ee.y),wd(this)||b){if(!this.isAtomic){for(var re=this.O.s,oe=re.length,se=Qe.alloc(),ue=ad(this);oe--;){var fe=re[oe];if(fe.visible||fe===ue){fe.se()?Ua(se.set(a),fe.transform):se.set(a);var ve=fe;fe=fe instanceof Ln?fe:null,(fe!==null?fe.ji(se,y,x,E):ve.ca(se))&&ve.pickable!==!1&&(y!==null&&(ve=y(ve)),ve===null||x!==null&&!x(ve)||E.add(ve))}}Qe.free(se)}return z||Qe.free(ee),b&&(this.background!==null||this.areaBackground!==null)}return z||Qe.free(ee),!1},we.Cf=function(a,y,x,E,b,z){if(this.pickable===!1)return!1;y===void 0&&(y=null),x===void 0&&(x=null);var ee=z;if(z===void 0&&(ee=kr.alloc(),ee.reset()),ee.multiply(this.transform),this.fh(a,ee))return m0(this,y,x,b),z===void 0&&kr.free(ee),!0;if(this.Yc(a,ee)){if(!this.isAtomic)for(var re=ad(this),oe=this.O.s,se=oe.length;se--;){var ue=oe[se];if(ue.visible||ue===re){var fe=ue.actualBounds,ve=this.naturalBounds;fe.x>ve.width||fe.y>ve.height||0>fe.x+fe.width||0>fe.y+fe.height||(fe=ue,ue=ue instanceof Ln?ue:null,ve=kr.alloc(),ve.set(ee),(ue!==null?ue.Cf(a,y,x,E,b,ve):fl(fe,a,E,ve))&&(y!==null&&(fe=y(fe)),fe===null||x!==null&&!x(fe)||b.add(fe)),kr.free(ve))}}return z===void 0&&kr.free(ee),E}return z===void 0&&kr.free(ee),!1};function m0(a,y,x,E){for(var b=a.O.s,z=b.length;z--;){var ee=b[z];if(ee.visible){var re=ee.actualBounds,oe=a.naturalBounds;re.x>oe.width||re.y>oe.height||0>re.x+re.width||0>re.y+re.height||(ee instanceof Ln&&m0(ee,y,x,E),y!==null&&(ee=y(ee)),ee===null||x!==null&&!x(ee)||E.add(ee))}}}we.og=function(a,y,x,E,b,z){if(this.pickable===!1)return!1;x===void 0&&(x=null),E===void 0&&(E=null);var ee=this.naturalBounds,re=this.se(),oe=re?a:Ua(Qe.allocAt(a.x,a.y),this.transform),se=re?y:Ua(Qe.allocAt(y.x,y.y),this.transform),ue=oe.Bf(se),fe=0<oe.x&&oe.x<ee.width&&0<oe.y&&oe.y<ee.height||ps(oe.x,oe.y,0,0,0,ee.height)<=ue||ps(oe.x,oe.y,0,ee.height,ee.width,ee.height)<=ue||ps(oe.x,oe.y,ee.width,ee.height,ee.width,0)<=ue||ps(oe.x,oe.y,ee.width,0,0,0)<=ue;if(ee=oe.zd(0,0)<=ue&&oe.zd(0,ee.height)<=ue&&oe.zd(ee.width,0)<=ue&&oe.zd(ee.width,ee.height)<=ue,re||(Qe.free(oe),Qe.free(se)),fe){if(!this.isAtomic){oe=Qe.alloc(),se=Qe.alloc(),ue=ad(this);for(var ve=this.O.s,ye=ve.length;ye--;){var Ce=ve[ye];if(Ce.visible||Ce===ue){var Ae=Ce.actualBounds,Ye=this.naturalBounds;(!re||!(Ae.x>Ye.width||Ae.y>Ye.height||0>Ae.x+Ae.width||0>Ae.y+Ae.height))&&(Ce.se()?(Ae=Ce.transform,Ua(oe.set(a),Ae),Ua(se.set(y),Ae)):(oe.set(a),se.set(y)),Ae=Ce,Ce=Ce instanceof Ln?Ce:null,(Ce!==null?Ce.og(oe,se,x,E,b,z):Ae.tx(oe,se,b))&&(x!==null&&(Ae=x(Ae)),Ae===null||E!==null&&!E(Ae)||z.add(Ae)))}}Qe.free(oe),Qe.free(se)}return b?fe:ee}return!1};function v0(a){var y=null;return a instanceof Dr&&(y=a.spot1,y===vs&&(y=null),a=a.geometry,a!==null&&y===null&&(y=a.spot1)),y===null&&(y=Cs),y}function y0(a){var y=null;return a instanceof Dr&&(y=a.spot2,y===vs&&(y=null),a=a.geometry,a!==null&&y===null&&(y=a.spot2)),y===null&&(y=Hl),y}we.add=function(a){for(var y=[],x=0;x<arguments.length;++x)y[x]=arguments[x];for(x=0;x<y.length;x++)this.Gb(this.O.count,y[x]);return this},we.M=function(a){return this.O.M(a)},we.Gb=function(a,y){y instanceof Ii&&Dt("Cannot add a Part to a Panel: "+y+"; use a Panel instead"),(this===y||this.rg(y))&&(this===y&&Dt("Cannot make a Panel contain itself: "+this.toString()),Dt("Cannot make a Panel indirectly contain itself: "+this.toString()+" already contains "+y.toString()));var x=y.panel;if(x!==null&&x!==this&&Dt("Cannot add a GraphObject that already belongs to another Panel to this Panel: "+y.toString()+", already contained by "+x.toString()+", cannot be shared by this Panel: "+this.toString()),this.na!==Ln.Grid||y instanceof Dr||Dt("Can only add Shapes to a Grid Panel, not: "+y),this.na!==Ln.Graduated||y instanceof Dr||y instanceof ja||Dt("Can only add Shapes or TextBlocks to a Graduated Panel, not: "+y),y.wi(this),y.Ng=null,this.itemArray!==null){var E=y.data;E!==null&&typeof E=="object"&&(this.ge===null&&(this.ge=new Li),this.ge.add(E,y))}var b=this.O;if(E=-1,x===this){for(var z=-1,ee=this.O.s,re=ee.length,oe=0;oe<re;oe++)if(ee[oe]===y){z=oe;break}if(z!==-1){if(z===a||z+1>=b.count&&a>=b.count)return;b.mb(z),E=z}else Dt("element "+y.toString()+" has panel "+x.toString()+" but is not contained by it.")}(0>a||a>b.count)&&(a=b.count),b.Gb(a,y),(a===0||y.isPanelMain)&&(this.$g=null),ph(this)||this.v(),y.v(!1),y.portId!==null?this.Te=!0:y instanceof Ln&&y.Te===!0&&(this.Te=!0),this.graduatedIntervals=null,this.If()||Fm(this,y,!1),x=this.part,x!==null&&(x.Rh=null,x.ag=NaN,this.Te&&x instanceof qn&&(x.Te=!0),x.Te&&x instanceof qn&&(x.wc=null),b=this.diagram,b!==null&&b.undoManager.isUndoingRedoing||(E!==-1&&x.cb(ss,"elements",this,y,null,E,null),x.cb(ts,"elements",this,null,y,null,a)))};function S0(a,y){a.l=y?a.l|16777216:a.l&-16777217}we.remove=function(a){for(var y=this.O.s,x=y.length,E=-1,b=0;b<x;b++)if(y[b]===a){E=b;break}E!==-1&&this.pc(E,!0)},we.mb=function(a){0<=a&&this.pc(a,!0)},we.pc=function(a,y){var x=this.O,E=x.M(a);if(E.Ng=null,E.wi(null),this.ge!==null){var b=E.data;typeof b=="object"&&this.ge.remove(b)}x.mb(a),Ys(this,!1),this.v(),this.$g===E&&(this.$g=null),this.graduatedIntervals=null;var z=this.part;z!==null&&(z.Rh=null,z.ag=NaN,z.Wb(),z instanceof qn&&(E instanceof Ln?E.qm(E,function(ee,re){K0(z,re,y)}):K0(z,E,y)),x=this.diagram,x!==null&&x.undoManager.isUndoingRedoing||z.cb(ss,"elements",this,E,null,a,null))},we.Fb=function(a){0>a&&gr(a,">= 0",Ln,"getRowDefinition:idx"),a=Math.round(a);var y=this.rowDefs;if(y[a]===void 0){var x=new Xs;x.wi(this),x.isRow=!0,x.index=a,y[a]=x,this.cb(ts,"rowdefs",this,null,x,null,a)}return y[a]},we.oA=function(a){if(0>a&&gr(a,">= 0",Ln,"removeRowDefinition:idx"),this.rowCount!==0){a=Math.round(a);var y=this.rowDefs,x=y[a];if(x){y[a]=void 0;for(var E=y.length-1;0<=E&&y[E--]===void 0;)y.length--;this.cb(ss,"rowdefs",this,x,null,a,null),this.v()}}};function hS(a,y,x){var E=a.rowDefs;if(!(0>y)){if(E[y]=x instanceof Xs?x:void 0,!x)for(y=E.length-1;0<=y&&E[y--]===void 0;)E.length--;a.v()}}we.Eb=function(a){0>a&&gr(a,">= 0",Ln,"getColumnDefinition:idx"),a=Math.round(a);var y=this.colDefs;if(y[a]===void 0){var x=new Xs;x.wi(this),x.isRow=!1,x.index=a,y[a]=x,this.cb(ts,"coldefs",this,null,x,null,a)}return y[a]},we.jA=function(a){if(0>a&&gr(a,">= 0",Ln,"removeColumnDefinition:idx"),this.columnCount!==0){a=Math.round(a);var y=this.colDefs,x=y[a];if(x){y[a]=void 0;for(var E=y.length-1;0<=E&&y[E--]===void 0;)y.length--;this.cb(ss,"coldefs",this,x,null,a,null),this.v()}}};function cS(a,y,x){var E=a.colDefs;if(!(0>y)){if(E[y]=x instanceof Xs?x:void 0,!x)for(y=E.length-1;0<=y&&E[y--]===void 0;)E.length--;a.v()}}we.Gy=function(a){var y=null;return a.isRow?y=this.Fb(a.index):a.isRow||(y=this.Eb(a.index)),y&&Am(y,a),this},we.Hy=function(a,y){return(a=this.Fb(a))&&Am(a,new Xs(y)),this},we.By=function(a,y){return(a=this.Eb(a))&&Am(a,new Xs(y)),this},we.nz=function(a){if(0>a||this.type!==Ln.Table||this.rowCount===0)return-1;for(var y=0,x=this.rowDefs,E=x.length,b=this.topIndex;b<E;b++){var z=x[b];if(z!==void 0&&(y+=z.total,a<y))break}return b},we.fz=function(a){if(0>a||this.type!==Ln.Table||this.columnCount===0)return-1;for(var y=0,x=this.colDefs,E=x.length,b=this.leftIndex;b<E;b++){var z=x[b];if(z!==void 0&&(y+=z.total,a<y))break}return b},we.Fz=function(a,y){if(y===void 0&&(y=new Qe(NaN,NaN)),this.type!==Ln.Graduated)return y.h(NaN,NaN),y;a=Math.min(Math.max(a,this.graduatedMin),this.graduatedMax);var x=this.Pb();return x.geometry.Pu((a-this.graduatedMin)/this.graduatedRange,y),x.transform.Ga(y)},we.Gz=function(a){if(this.type!==Ln.Graduated)return NaN;var y=this.Pb();return y.transform.Cd(a),y.geometry.xx(a)*this.graduatedRange+this.graduatedMin};function dS(a){return a=a.allBindings,a!==null&&a._isFrozen}function _h(a){var y=a.allBindings;if(y===null)a.data!==null&&Dt("Template cannot have .data be non-null: "+a),a.allBindings=y=new An;else if(y._isFrozen)return;var x=new An;S0(a,!1),a.qm(a,function(se,ue){ue.th();var fe=ue.localBindings;if(fe!==null)for(zf(ue,!1),fe=fe.iterator;fe.next();){var ve=fe.value;ve.mode===Rp&&zf(ue,!0);var ye=ve.sourceName;ye!==null&&(ye==="/"&&S0(se,!0),ye=L1(ve,se,ue),ye!==null&&(x.add(ye),ye.srcBindings===null&&(ye.srcBindings=new An),ye.srcBindings.add(ve))),y.add(ve)}if(ue instanceof Ln&&ue.type===Ln.Table){if(0<ue.rowCount){for(se=ue.rowDefs,fe=se.length,ve=0;ve<fe;ve++)if(ye=se[ve],ye!==void 0&&ye.be!==null)for(var Ce=ye.be.iterator;Ce.next();){var Ae=Ce.value;Ae.xd=ye,Ae.to=2,Ae.wl=ye.index,y.add(Ae)}}if(0<ue.columnCount){for(ue=ue.colDefs,se=ue.length,fe=0;fe<se;fe++)if(ve=ue[fe],ve!==void 0&&ve.be!==null)for(ye=ve.be.iterator;ye.next();)Ce=ye.value,Ce.xd=ve,Ce.to=1,Ce.wl=ve.index,y.add(Ce)}}});for(var E=x.iterator;E.next();){var b=E.value;if(b.srcBindings!==null){zf(b,!0);for(var z=b.srcBindings.iterator;z.next();){var ee=z.value;b.localBindings===null&&(b.localBindings=new An),b.localBindings.add(ee)}}b.srcBindings=null}for(E=y.iterator;E.next();)if(b=E.value,z=b.xd,z!==null){b.xd=null;var re=b.targetProperty,oe=re.indexOf(".");0<oe&&z instanceof Ln&&(ee=re.substring(0,oe),re=re.substr(oe+1),oe=z.fb(ee),oe!==null?(z=oe,b.targetProperty=re):eo('Warning: unable to find GraphObject named "'+ee+'" for Binding: '+b.toString())),z instanceof Xs?(ee=qa(z.panel),b.Ai=ee===void 0?-1:ee,z.panel.bindingId=b.Ai):z instanceof mt?(ee=qa(z),b.Ai=ee===void 0?-1:ee,z.bindingId=b.Ai):Dt("Unknown type of binding target: "+z)}y.freeze(),a instanceof Ii&&a.Zc()&&a.Va()}we.Uy=function(a){a===void 0&&(a=!1);var y=this.copy();return vx(y,function(x){x instanceof Ln&&(x.allBindings=null,x.ub=null);var E=x.localBindings;E!==null&&(x.localBindings=null,E.each(function(b){x.bind(b.copy())})),E=x.animationTriggers,E!==null&&(x.animationTriggers=null,E.each(function(b){x.Jv(b.value.copy())}))}),a&&_h(y),y},we.La=function(a){var y=this.allBindings;if(y!==null)for(a===void 0&&(a=""),y=y.iterator;y.next();){var x=y.value,E=x.sourceProperty;if((a===""||E===""||E===a)&&(E=x.targetProperty,x.converter!==null||E!=="")){E=this.data;var b=x.sourceName;if(b!==null){if(b==="")E=this;else if(b==="/")E=this;else if(b===".")E=this;else if(b==="..")E=this;else if(E=this.fb(b),E===null)continue}else if(x.isToModel)if(E=this.diagram,E!==null)E=E.model.modelData;else continue;var z=this,ee=x.Ai;if(ee!==-1){if(z=this.ks(ee),z===null)continue}else x.xd!==null&&(z=x.xd);if(b==="/"?E=z.part:b==="."?E=z:b===".."&&(E=z.panel),b=x.to,b!==0){if(!(z instanceof Ln))continue;b===1?z=z.Eb(x.wl):b===2&&(z=z.Fb(x.wl))}z!==void 0&&x.Mv(z,E)}}},we.sx=function(a){return a==null||this.ge===null?null:this.ge.I(a)};function yx(a,y){a=a.O.s;for(var x=a.length,E=y.length,b=0,z=null;b<x&&(z=a[b],!(z instanceof Ln&&z.data!==null));)b++,z=a[b];if(x-b!==E)return!0;if(z===null)return 0<E;for(var ee=0;b<x&&ee<E;){if(z=a[b],!(z instanceof Ln)||z.data!==y[ee])return!0;b++,ee++}return!1}function gp(a){if(a.type===Ln.Spot||a.type===Ln.Auto)return Math.min(a.O.length,1);if(a.type===Ln.Link){a=a.O;for(var y=a.length,x=0;x<y;x++){var E=a.M(x);if(!(E instanceof Dr&&E.isPanelMain))break}return x}return a.type===Ln.Table&&0<a.O.length&&(a=a.O.M(0),a.isPanelMain&&a instanceof Ln&&wd(a))?1:0}we.mv=function(){for(var a=gp(this);this.O.length>a;)this.pc(this.O.length-1,!1);fS(this,this.itemArray)};function fS(a,y){var x=gp(a);if(y===null||y.length===0)for(;a.O.length>x;)a.pc(a.O.length-1,!1);else if(a.O.length<=x){x=y.length;for(var E=0;E<x;E++)km(a,y[E],E,!0)}else{E=x;for(var b=0;b<y.length;b++,E++){var z=y[b],ee=E<a.O.length?a.O.M(E):null;if(ee instanceof Ln){if(ee.data!==z){var re=w0(a,ee.data),oe=w0(a,z),se=oe!==re;se||(re=P0(a,re),se=P0(a,oe)!==re),se?(a.pc(E,!1),km(a,z,b,!1)):ee.data=z}}else km(a,z,b,!1)}for(;E<a.O.length;)a.pc(E,!1);a.$g=null,x0(a,x,0),ph(a)||a.v(),a.graduatedIntervals=null,a.If()||Fm(a,a,!1),y=a.part,y!==null&&(y.Rh=null,y.ag=NaN,a.Te&&y instanceof qn&&(y.Te=!0),y.Te&&y instanceof qn&&(y.wc=null))}}function km(a,y,x,E){if(!(y==null||0>x)){var b=w0(a,y);if(b=P0(a,b),b!==null){if(_h(b),b=b.copy(),b.l&16777216){var z=a.ih();z!==null&&S0(z,!0)}typeof y=="object"&&(a.ge===null&&(a.ge=new Li),a.ge.add(y,b)),z=x+gp(a),a.Gb(z,b),E&&(b.ub=y,x0(a,z,x),b.ub=null),b.data=y}}}function x0(a,y,x){for(a=a.O;y<a.length;){var E=a.M(y);if(E instanceof Ln){var b=y,z=x;E.type===Ln.TableRow?E.row=b:E.type===Ln.TableColumn&&(E.column=b),E.itemIndex=z}y++,x++}}function w0(a,y){if(y===null)return"";if(a=a.itemCategoryProperty,typeof a=="function")a=a(y);else if(typeof a=="string"&&typeof y=="object"){if(a==="")return"";a=Is(y,a)}else return"";if(a===void 0)return"";if(typeof a=="string")return a;Dt("Panel.getCategoryForItemData found a non-string category for "+y+": "+a)}function P0(a,y){var x=a.itemTemplateMap,E=null;return x!==null&&(E=x.I(y)),E===null&&(x!==null&&(E=x.I("")),E===null&&(gS||(gS=!0,eo('No item template Panel found for category "'+y+'" on '+a),eo(" Using default item template."),a=new Ln,y=new ja,y.bind(new Hs("text","",Co)),a.add(y),pS=a),E=pS)),E}function Fm(a,y,x){var E=y.enabledChanged;if(E!==null&&E(y,x),y instanceof Ln){y=y.O.s,E=y.length;for(var b=0;b<E;b++){var z=y[b];x&&z instanceof Ln&&!z.isEnabled||Fm(a,z,x)}}}function Ac(a,y){y.name=a,rc.add(a,y)}Yt.Object.defineProperties(Ln.prototype,{type:{get:function(){return this.na},set:function(a){var y=this.na;y!==a&&(this.na=a,this.isAtomic=this.na===Ln.Grid,this.v(),this.g("type",y,a))}},elements:{get:function(){return this.O.iterator}},naturalBounds:{get:function(){return this.dc}},padding:{get:function(){return this.yb},set:function(a){typeof a=="number"?(0>a&&gr(a,">= 0",Ln,"padding"),a=new vr(a)):(0>a.left&&gr(a.left,">= 0",Ln,"padding:value.left"),0>a.right&&gr(a.right,">= 0",Ln,"padding:value.right"),0>a.top&&gr(a.top,">= 0",Ln,"padding:value.top"),0>a.bottom&&gr(a.bottom,">= 0",Ln,"padding:value.bottom"));var y=this.yb;y.D(a)||(this.yb=a=a.J(),this.v(),this.g("padding",y,a))}},defaultAlignment:{get:function(){return this.Tm},set:function(a){var y=this.Tm;y.D(a)||(this.Tm=a=a.J(),this.v(),this.g("defaultAlignment",y,a))}},defaultStretch:{get:function(){return this.Uf},set:function(a){var y=this.Uf;y!==a&&(this.Uf=a,this.v(),this.g("defaultStretch",y,a))}},defaultSeparatorPadding:{get:function(){return this.T!==null?this.T.Qp:Tl},set:function(a){typeof a=="number"&&(a=new vr(a));var y=this.defaultSeparatorPadding;y.D(a)||(a=a.J(),this.T===null&&(this.T=new Bh),this.T.Qp=a,this.v(),this.g("defaultSeparatorPadding",y,a))}},defaultRowSeparatorStroke:{get:function(){return this.T!==null?this.T.ia:null},set:function(a){var y=this.defaultRowSeparatorStroke;y!==a&&(a===null||typeof a=="string"||a instanceof ia)&&(a instanceof ia&&a.freeze(),this.T===null&&(this.T=new Bh),this.T.ia=a,this.N(),this.g("defaultRowSeparatorStroke",y,a))}},defaultRowSeparatorStrokeWidth:{get:function(){return this.T!==null?this.T.Ha:1},set:function(a){var y=this.defaultRowSeparatorStrokeWidth;y!==a&&isFinite(a)&&0<=a&&(this.T===null&&(this.T=new Bh),this.T.Ha=a,this.v(),this.g("defaultRowSeparatorStrokeWidth",y,a))}},defaultRowSeparatorDashArray:{get:function(){return this.T!==null?this.T.V:null},set:function(a){var y=this.defaultRowSeparatorDashArray;if(y!==a){if(a!==null){for(var x=a.length,E=0,b=0;b<x;b++){var z=a[b];typeof z=="number"&&0<=z&&isFinite(z)||Dt("defaultRowSeparatorDashArray value "+z+" at index "+b+" must be a positive number or zero."),E+=z}if(E===0){if(y===null)return;a=null}}this.T===null&&(this.T=new Bh),this.T.V=a,this.N(),this.g("defaultRowSeparatorDashArray",y,a)}}},defaultColumnSeparatorStroke:{get:function(){return this.T!==null?this.T.u:null},set:function(a){var y=this.defaultColumnSeparatorStroke;y!==a&&(a===null||typeof a=="string"||a instanceof ia)&&(a instanceof ia&&a.freeze(),this.T===null&&(this.T=new Bh),this.T.u=a,this.N(),this.g("defaultColumnSeparatorStroke",y,a))}},defaultColumnSeparatorStrokeWidth:{get:function(){return this.T!==null?this.T.F:1},set:function(a){var y=this.defaultColumnSeparatorStrokeWidth;y!==a&&isFinite(a)&&0<=a&&(this.T===null&&(this.T=new Bh),this.T.F=a,this.v(),this.g("defaultColumnSeparatorStrokeWidth",y,a))}},defaultColumnSeparatorDashArray:{get:function(){return this.T!==null?this.T.o:null},set:function(a){var y=this.defaultColumnSeparatorDashArray;if(y!==a){if(a!==null){for(var x=a.length,E=0,b=0;b<x;b++){var z=a[b];typeof z=="number"&&0<=z&&isFinite(z)||Dt("defaultColumnSeparatorDashArray value "+z+" at index "+b+" must be a positive number or zero."),E+=z}if(E===0){if(y===null)return;a=null}}this.T===null&&(this.T=new Bh),this.T.o=a,this.N(),this.g("defaultColumnSeparatorDashArray",y,a)}}},inRowsCols:{get:function(){return this.T!==null?this.T.nb:null},set:function(a){this.T===null&&(this.T=new Bh),this.T.nb=a}},viewboxStretch:{get:function(){return this.xo},set:function(a){var y=this.xo;y!==a&&(this.xo=a,this.v(),this.g("viewboxStretch",y,a))}},gridCellSize:{get:function(){return this.jn},set:function(a){var y=this.jn;if(!y.D(a)){a.w()&&a.width!==0&&a.height!==0||Dt("Invalid Panel.gridCellSize: "+a),this.jn=a.J();var x=this.diagram;x!==null&&this===x.grid&&zs(x),this.N(),this.g("gridCellSize",y,a)}}},gridOrigin:{get:function(){return this.kn},set:function(a){var y=this.kn;if(!y.D(a)){a.w()||Dt("Invalid Panel.gridOrigin: "+a),this.kn=a.J();var x=this.diagram;x!==null&&this===x.grid&&zs(x),this.N(),this.g("gridOrigin",y,a)}}},graduatedMin:{get:function(){return this.ra!==null?this.ra.lq:0},set:function(a){var y=this.graduatedMin;y!==a&&(this.ra===null&&(this.ra=new sd),this.ra.lq=a,this.v(),this.g("graduatedMin",y,a),Rl(this)&&(a=this.part,a!==null&&_a(this,a,"graduatedRange")))}},graduatedMax:{get:function(){return this.ra!==null?this.ra.F:100},set:function(a){var y=this.graduatedMax;y!==a&&(this.ra===null&&(this.ra=new sd),this.ra.F=a,this.v(),this.g("graduatedMax",y,a),Rl(this)&&(a=this.part,a!==null&&_a(this,a,"graduatedRange")))}},graduatedRange:{get:function(){return this.graduatedMax-this.graduatedMin}},graduatedTickUnit:{get:function(){return this.ra!==null?this.ra.ia:10},set:function(a){var y=this.graduatedTickUnit;y!==a&&0<a&&(this.ra===null&&(this.ra=new sd),this.ra.ia=a,this.v(),this.g("graduatedTickUnit",y,a))}},graduatedTickBase:{get:function(){return this.ra!==null?this.ra.V:0},set:function(a){var y=this.graduatedTickBase;y!==a&&(this.ra===null&&(this.ra=new sd),this.ra.V=a,this.v(),this.g("graduatedTickBase",y,a))}},graduatedMarks:{get:function(){return this.ra!==null?this.ra.u:null},set:function(a){this.ra!==null?this.ra.u=a:a!==null&&(this.ra=new sd,this.ra.u=a)}},graduatedBounds:{get:function(){return this.ra!==null?this.ra.j:null},set:function(a){this.ra!==null?this.ra.j=a:a!==null&&(this.ra=new sd,this.ra.j=a)}},graduatedIntervals:{get:function(){return this.ra!==null?this.ra.o:null},set:function(a){this.ra!==null?this.ra.o=a:a!==null&&(this.ra=new sd,this.ra.o=a)}},temporaryTextBlock:{get:function(){return this.ra!==null?this.ra.Zh:null},set:function(a){this.ra!==null?this.ra.Zh=a:a!==null&&(this.ra=new sd,this.ra.Zh=a)}},panelLayoutState:{get:function(){return this.F},set:function(a){this.F=a}},Te:{get:function(){return(this.l&8388608)!==0},set:function(a){(this.l&8388608)!==0!==a&&(this.l^=8388608)}},rowDefs:{get:function(){return this.T===null&&(this.T=new Bh),this.T.Pc}},rowCount:{get:function(){return this.T===null?0:this.rowDefs.length}},colDefs:{get:function(){return this.T===null&&(this.T=new Bh),this.T.Oc}},columnCount:{get:function(){return this.T===null?0:this.colDefs.length}},rowSizing:{get:function(){return this.T!==null?this.T.ob:Tm},set:function(a){var y=this.rowSizing;y!==a&&(this.T===null&&(this.T=new Bh),this.T.ob=a,this.v(),this.g("rowSizing",y,a))}},columnSizing:{get:function(){return this.T!==null?this.T.j:Tm},set:function(a){var y=this.columnSizing;y!==a&&(this.T===null&&(this.T=new Bh),this.T.j=a,this.v(),this.g("columnSizing",y,a))}},topIndex:{get:function(){return this.T!==null?this.T.Hb:0},set:function(a){var y=this.topIndex;y!==a&&((!isFinite(a)||0>a)&&Dt("Panel.topIndex must be greater than zero and a real number, not: "+a),this.T===null&&(this.T=new Bh),this.T.Hb=a,this.v(),this.g("topIndex",y,a))}},leftIndex:{get:function(){return this.T!==null?this.T.hb:0},set:function(a){var y=this.leftIndex;y!==a&&((!isFinite(a)||0>a)&&Dt("Panel.leftIndex must be greater than zero and a real number, not: "+a),this.T===null&&(this.T=new Bh),this.T.hb=a,this.v(),this.g("leftIndex",y,a))}},data:{get:function(){return this.ub},set:function(a){var y=this.ub;if(y!==a){var x=this instanceof Ii&&!(this instanceof Fo);_h(this),this.ub=a;var E=this.diagram;E!==null&&(x?(x=E.partManager,this instanceof Tn?(y!==null&&x.bf.remove(y),a!==null&&x.bf.add(a,this)):this instanceof Ii&&(y!==null&&x.cf.remove(y),a!==null&&x.cf.add(a,this))):(x=this.panel,x!==null&&x.ge!==null&&(y!==null&&x.ge.remove(y),a!==null&&x.ge.add(a,this)))),this.g("data",y,a),E!==null&&E.undoManager.isUndoingRedoing||a!==null&&this.La()}}},itemIndex:{get:function(){return this.zn},set:function(a){var y=this.zn;y!==a&&(this.zn=a,this.g("itemIndex",y,a))}},allBindings:{get:function(){return this.A!==null?this.A.nb:null},set:function(a){this.localBindings!==a&&(this.A===null&&(this.A=new Hf),this.A.nb=a)}},itemArray:{get:function(){return this.Hh},set:function(a){var y=this.Hh;if(y!==a||a!==null&&yx(this,a)){var x=this.diagram;y!==a&&(x!==null&&y!==null&&ly(x.partManager,this,x),this.Hh=a,x!==null&&a!==null&&sy(x.partManager,this)),this.g("itemArray",y,a),x!==null&&x.undoManager.isUndoingRedoing||fS(this,a)}}},itemTemplate:{get:function(){return this.itemTemplateMap===null?null:this.itemTemplateMap.I("")},set:function(a){if(this.itemTemplateMap===null){if(a===null)return;this.itemTemplateMap=new Li}var y=this.itemTemplateMap.I("");y!==a&&((a instanceof Ii||a.isPanelMain)&&Dt("Panel.itemTemplate must not be a Part or be Panel.isPanelMain: "+a),this.itemTemplateMap.add("",a),this.g("itemTemplate",y,a),a=this.diagram,a!==null&&a.undoManager.isUndoingRedoing||this.mv())}},itemTemplateMap:{get:function(){return this.A!==null?this.A.Pc:null},set:function(a){var y=this.itemTemplateMap;if(y!==a){for(var x=a.iterator;x.next(););Hr(this),this.A.Pc=a,this.g("itemTemplateMap",y,a),a=this.diagram,a!==null&&a.undoManager.isUndoingRedoing||this.mv()}}},itemCategoryProperty:{get:function(){return this.A!==null?this.A.Oc:"category"},set:function(a){var y=this.itemCategoryProperty;y!==a&&(Hr(this),this.A.Oc=a,this.g("itemCategoryProperty",y,a))}},isAtomic:{get:function(){return(this.l&1048576)!==0},set:function(a){var y=(this.l&1048576)!==0;y!==a&&(this.l^=1048576,this.g("isAtomic",y,a))}},isClipping:{get:function(){return(this.l&2097152)!==0},set:function(a){var y=(this.l&2097152)!==0;y!==a&&(this.l^=2097152,this instanceof xr&&(this.tb=null),this.v(),this.g("isClipping",y,a))}},isOpposite:{get:function(){return(this.l&33554432)!==0},set:function(a){var y=(this.l&33554432)!==0;y!==a&&(this.l^=33554432,this.v(),this.g("isOpposite",y,a))}},isEnabled:{get:function(){return(this.l&4194304)!==0},set:function(a){var y=(this.l&4194304)!==0;if(y!==a){var x=this.panel===null||this.panel.If();this.l^=4194304,this.g("isEnabled",y,a),y=this.diagram,y!==null&&y.undoManager.isUndoingRedoing||x&&Fm(this,this,a)}}},alignmentFocusName:{get:function(){return this.$e},set:function(a){var y=this.$e;y!==a&&(this.$e=a,this.v(),this.g("alignmentFocusName",y,a))}}}),Yt.Object.defineProperties(Ln,{Position:{get:function(){return rc.I("Position")}},Horizontal:{get:function(){return rc.I("Horizontal")}},Vertical:{get:function(){return rc.I("Vertical")}},Spot:{get:function(){return rc.I("Spot")}},Auto:{get:function(){return rc.I("Auto")}},Table:{get:function(){return rc.I("Table")}},Viewbox:{get:function(){return rc.I("Viewbox")}},TableRow:{get:function(){return rc.I("TableRow")}},TableColumn:{get:function(){return rc.I("TableColumn")}},Link:{get:function(){return rc.I("Link")}},Grid:{get:function(){return rc.I("Grid")}},Graduated:{get:function(){return rc.I("Graduated")}}}),Ln.prototype.rebuildItemElements=Ln.prototype.mv,Ln.prototype.findItemPanelForData=Ln.prototype.sx,Ln.prototype.updateTargetBindings=Ln.prototype.La,Ln.prototype.copyTemplate=Ln.prototype.Uy,Ln.prototype.graduatedValueForPoint=Ln.prototype.Gz,Ln.prototype.graduatedPointForValue=Ln.prototype.Fz,Ln.prototype.findColumnForLocalX=Ln.prototype.fz,Ln.prototype.findRowForLocalY=Ln.prototype.nz,Ln.prototype.addColumnDefinition=Ln.prototype.By,Ln.prototype.addRowDefinition=Ln.prototype.Hy,Ln.prototype.addRowColumnDefinition=Ln.prototype.Gy,Ln.prototype.removeColumnDefinition=Ln.prototype.jA,Ln.prototype.getColumnDefinition=Ln.prototype.Eb,Ln.prototype.removeRowDefinition=Ln.prototype.oA,Ln.prototype.getRowDefinition=Ln.prototype.Fb,Ln.prototype.removeAt=Ln.prototype.mb,Ln.prototype.remove=Ln.prototype.remove,Ln.prototype.insertAt=Ln.prototype.Gb,Ln.prototype.elt=Ln.prototype.M,Ln.prototype.add=Ln.prototype.add,Ln.prototype.findObject=Ln.prototype.fb,Ln.prototype.findInVisualTree=Ln.prototype.Nl,Ln.prototype.walkVisualTreeFrom=Ln.prototype.qm,Ln.prototype.findMainElement=Ln.prototype.Pb;var gS=!1,pS=null,rc=new Li;Ln.className="Panel",Ln.definePanelLayout=Ac,Ac("Position",new mm),Ac("Vertical",new ym),Ac("Auto",new xm),Ac("Link",new Lm);function sd(){this.lq=0,this.F=100,this.ia=10,this.V=0,this.Zh=this.o=this.j=this.u=null}sd.prototype.copy=function(){var a=new sd;return a.lq=this.lq,a.F=this.F,a.ia=this.ia,a.V=this.V,a.u=this.u,a.j=this.j,a.o=this.o,a.Zh=this.Zh,a},sd.className="GradPanelSettings";function Bh(){this.Pc=[],this.Oc=[],this.j=this.ob=Tm,this.hb=this.Hb=0,this.Qp=Tl,this.Ha=1,this.V=this.ia=null,this.F=1,this.nb=this.o=this.u=null}Bh.prototype.copy=function(a){for(var y=new Bh,x=this.Pc,E=x.length,b=y.Pc,z=0;z<E;z++)if(x[z]!==void 0){var ee=x[z].copy();ee.wi(a),b[z]=ee}for(x=this.Oc,E=x.length,b=y.Oc,z=0;z<E;z++)x[z]!==void 0&&(ee=x[z].copy(),ee.wi(a),b[z]=ee);return y.ob=this.ob,y.j=this.j,y.Hb=this.Hb,y.hb=this.hb,y.Qp=this.Qp.J(),y.Ha=this.Ha,y.ia=this.ia,y.V=this.V,y.F=this.F,y.u=this.u,y.o=this.o,y.nb=this.nb,y},Bh.className="TablePanelSettings";function Xs(a){jo(this),this.Me=null,this.uq=!0,this.Za=0,this.Hc=NaN,this.jj=0,this.hj=1/0,this.Jb=vs,this.pa=this.oc=this.oa=0,this.be=null,this.oo=C0,this.hg=Cr,this.lo=this.dg=null,this.mo=NaN,this.Ma=this.tj=null,this.Pm=!1,a&&(Object.assign(this,a),a.column!==void 0?(this.isRow=!1,this.index=a.column):a.row!==void 0&&(this.isRow=!0,this.index=a.row))}Xs.prototype.copy=function(){var a=new Xs;return a.uq=this.uq,a.Za=this.Za,a.Hc=this.Hc,a.jj=this.jj,a.hj=this.hj,a.Jb=this.Jb,a.oa=this.oa,a.oc=this.oc,a.pa=this.pa,a.hg=this.hg,a.oo=this.oo,this.dg===null?a.dg=null:a.dg=this.dg.J(),a.lo=this.lo,a.mo=this.mo,a.tj=null,this.tj!==null&&(a.separatorDashArray=Lo(this.separatorDashArray)),a.Ma=this.Ma,a.Pm=this.Pm,a.be=this.be,a};function Am(a,y){y.isRow?a.height=y.height:a.width=y.width,a.minimum=y.minimum,a.maximum=y.maximum,a.alignment=y.alignment,a.stretch=y.stretch,a.sizing=y.sizing,a.dg=y.separatorPadding===null?null:y.separatorPadding.J(),a.separatorStroke=y.separatorStroke,a.separatorStrokeWidth=y.separatorStrokeWidth,a.tj=null,y.separatorDashArray&&(a.tj=Lo(y.separatorDashArray)),a.background=y.background,a.coversSeparators=y.coversSeparators,a.be=y.be}we=Xs.prototype,we.qb=function(a){a.classType===Xs&&(this.sizing=a)},we.toString=function(){return"RowColumnDefinition "+(this.isRow?"(Row ":"(Column ")+this.index+") #"+qa(this)},we.wi=function(a){this.Me=a},we.Io=function(a){var y=0,x=this.Me;if(this.index!==a&&(a=this.separatorStroke,a===null&&x!==null&&(a=this.isRow?x.defaultRowSeparatorStroke:x.defaultColumnSeparatorStroke),a!==null&&(y=this.separatorStrokeWidth,isNaN(y)&&(x!==null?y=this.isRow?x.defaultRowSeparatorStrokeWidth:x.defaultColumnSeparatorStrokeWidth:y=0))),a=this.dg,a===null)if(x!==null)a=x.defaultSeparatorPadding;else return y;return y+(this.isRow?a.top:a.left)},we.Wc=function(){var a=0,y=this.Me,x=0,E=this.isRow;if(y!==null&&y.type===Ln.Table)for(var b=E?y.rowDefs.length:y.colDefs.length,z=0;z<b;z++){var ee=E?y.rowDefs[z]:y.colDefs[z];if(ee!==void 0&&ee.oa!==0){x=ee.index;break}}if(this.index!==x&&(x=this.separatorStroke,x===null&&y!==null&&(x=E?y.defaultRowSeparatorStroke:y.defaultColumnSeparatorStroke),x!==null&&(a=this.separatorStrokeWidth,isNaN(a)&&(y!==null?a=E?y.defaultRowSeparatorStrokeWidth:y.defaultColumnSeparatorStrokeWidth:a=0))),E=this.dg,E===null)if(y!==null)E=y.defaultSeparatorPadding;else return a;return a+(this.isRow?E.top+E.bottom:E.left+E.right)},we.Ob=function(a,y,x){var E=this.Me;if(E!==null&&(E.cb(ga,a,this,y,x,void 0,void 0),this.be!==null&&(y=E.diagram,y!==null&&!y.skipsModelSourceBindings&&(E=E.ih(),E!==null&&(y=E.data,y!==null)))))for(x=this.be.iterator;x.next();)x.value.sp(this,y,a,E)};function Nm(a){if(a.sizing===C0){var y=a.Me;return a.isRow?y.rowSizing:y.columnSizing}return a.sizing}we.bind=function(a,y,x,E){var b=null;return typeof a=="string"?b=new Hs(a,y,x,E):b=a,b.xd=this,a=this.panel,a!==null&&(y=a.ih(),y!==null&&dS(y)&&Dt("Cannot add a Binding to a RowColumnDefinition that is already frozen: "+b+" on "+a)),this.be===null&&(this.be=new An),this.be.add(b),this},Yt.Object.defineProperties(Xs.prototype,{panel:{get:function(){return this.Me}},isRow:{get:function(){return this.uq},set:function(a){this.uq=a}},index:{get:function(){return this.Za},set:function(a){this.Za=a}},height:{get:function(){return this.Hc},set:function(a){var y=this.Hc;y!==a&&(0>a&&gr(a,">= 0",Xs,"height"),this.Hc=a,this.actual=this.oa,this.panel!==null&&this.panel.v(),this.Ob("height",y,a))}},width:{get:function(){return this.Hc},set:function(a){var y=this.Hc;y!==a&&(0>a&&gr(a,">= 0",Xs,"width"),this.Hc=a,this.actual=this.oa,this.panel!==null&&this.panel.v(),this.Ob("width",y,a))}},minimum:{get:function(){return this.jj},set:function(a){var y=this.jj;y!==a&&((0>a||!isFinite(a))&&gr(a,">= 0",Xs,"minimum"),this.jj=a,this.actual=this.oa,this.panel!==null&&this.panel.v(),this.Ob("minimum",y,a))}},maximum:{get:function(){return this.hj},set:function(a){var y=this.hj;y!==a&&(0>a&&gr(a,">= 0",Xs,"maximum"),this.hj=a,this.actual=this.oa,this.panel!==null&&this.panel.v(),this.Ob("maximum",y,a))}},alignment:{get:function(){return this.Jb},set:function(a){var y=this.Jb;y.D(a)||(this.Jb=a.J(),this.panel!==null&&this.panel.v(),this.Ob("alignment",y,a))}},stretch:{get:function(){return this.hg},set:function(a){var y=this.hg;y!==a&&(this.hg=a,this.panel!==null&&this.panel.v(),this.Ob("stretch",y,a))}},separatorPadding:{get:function(){return this.dg},set:function(a){typeof a=="number"&&(a=new vr(a));var y=this.dg;a!==null&&y!==null&&y.D(a)||(a!==null&&(a=a.J()),this.dg=a,this.panel!==null&&this.panel.v(),this.Ob("separatorPadding",y,a))}},separatorStroke:{get:function(){return this.lo},set:function(a){var y=this.lo;y!==a&&(a!==null&&Kf(a,"RowColumnDefinition.separatorStroke"),a instanceof ia&&a.freeze(),this.lo=a,this.panel!==null&&this.panel.v(),this.Ob("separatorStroke",y,a))}},separatorStrokeWidth:{get:function(){return this.mo},set:function(a){var y=this.mo;y!==a&&(this.mo=a,this.panel!==null&&this.panel.v(),this.Ob("separatorStrokeWidth",y,a))}},separatorDashArray:{get:function(){return this.tj},set:function(a){var y=this.tj;if(y!==a){if(a!==null){for(var x=a.length,E=0,b=0;b<x;b++){var z=a[b];typeof z=="number"&&0<=z&&isFinite(z)||Dt("separatorDashArray value "+z+" at index "+b+" must be a positive number or zero."),E+=z}if(E===0){if(y===null)return;a=null}}this.tj=a,this.panel!==null&&this.panel.N(),this.Ob("separatorDashArray",y,a)}}},background:{get:function(){return this.Ma},set:function(a){var y=this.Ma;y!==a&&(a!==null&&Kf(a,"RowColumnDefinition.background"),a instanceof ia&&a.freeze(),this.Ma=a,this.panel!==null&&this.panel.N(),this.Ob("background",y,a))}},coversSeparators:{get:function(){return this.Pm},set:function(a){var y=this.Pm;y!==a&&(this.Pm=a,this.panel!==null&&this.panel.N(),this.Ob("coversSeparators",y,a))}},sizing:{get:function(){return this.oo},set:function(a){var y=this.oo;y!==a&&(this.oo=a,this.panel!==null&&this.panel.v(),this.Ob("sizing",y,a))}},actual:{get:function(){return this.oa},set:function(a){this.oa=isNaN(this.Hc)?Math.max(Math.min(this.hj,a),this.jj):Math.max(Math.min(this.hj,this.Hc),this.jj)}},measured:{get:function(){return this.oc},set:function(a){this.oc=a}},total:{get:function(){return this.oa+this.Wc()}},position:{get:function(){return this.pa},set:function(a){this.pa=a}}}),Xs.prototype.computeEffectiveSpacing=Xs.prototype.Wc,Xs.prototype.computeEffectiveSpacingTop=Xs.prototype.Io;var C0=new Vt(Xs,"Default",0),pp=new Vt(Xs,"None",1),Tm=new Vt(Xs,"ProportionalExtra",2);Xs.className="RowColumnDefinition",Xs.Default=C0,Xs.None=pp,Xs.ProportionalExtra=Tm;function Dr(a,y){mt.call(this),this.Rd=this.ua=null,this.an="None",this.xc=this.Ui="black",this.ig=1,this.Na=this.Yg=null,this.Vn=this.Un=NaN,this.fa=null,typeof a=="string"?this.figure=a:a&&Object.assign(this,a),y&&Object.assign(this,y)}Ct(Dr,mt),Dr.prototype.cloneProtected=function(a){mt.prototype.cloneProtected.call(this,a),a.ua=this.ua,a.Rd=this.Rd,a.an=this.an,a.Ui=this.Ui,a.xc=this.xc,a.ig=this.ig,this.Yg!==null&&(a.Yg=Lo(this.Yg)),this.Na!==null&&(a.Na=this.Na.nc?this.Na:this.Na.copy()),a.Un=this.Un,a.Vn=this.Vn,this.fa!==null&&(a.fa=this.fa.copy())};function xf(a){a.Na===null?a.Na=new L0:a.Na.nc&&(a.Na=a.Na.copy())}we=Dr.prototype,we.th=function(){mt.prototype.th.call(this),this.Na!==null&&(this.Na.nc=!0)},we.qb=function(a){a===mn||a===xi||a===ao||a===Cr?this.geometryStretch=a:mt.prototype.qb.call(this,a)},we.toString=function(){return"Shape("+(this.figure!=="None"?this.figure:this.toArrow!=="None"?this.toArrow:this.fromArrow)+")#"+qa(this)};function Pg(a,y,x,E){var b=x.length;if(!(4>b)){var z=E.measuredBounds,ee=Math.max(1,z.width);z=z.height;for(var re=x[0],oe=x[1],se,ue,fe,ve,ye,Ce,Ae=0,Ye=qi(),We=2;We<b;We+=2)se=x[We],ue=x[We+1],fe=se-re,re=ue-oe,fe===0&&(fe=.001),ve=re/fe,ye=Math.atan2(re,fe),Ce=Math.sqrt(fe*fe+re*re),Ye.push([fe,ye,ve,Ce]),Ae+=Ce,re=se,oe=ue;re=x[0],oe=x[1],fe=E.measuredBounds.width,E instanceof Dr&&(fe-=E.strokeWidth),1>fe&&(fe=1),b=x=fe,se=ee/2,ue=se!==0,We=0,Ce=Ye[We],fe=Ce[0],ye=Ce[1],ve=Ce[2],Ce=Ce[3];for(var tt=0;.1<=Ae;){if(tt===0&&(ue?(b=x,b-=se,Ae-=se,ue=!1):b=x,b===0&&(b=1)),b>Ae){Zi(Ye);return}b>Ce?(tt=b-Ce,b=Ce):tt=0;var rt=Math.sqrt(b*b/(1+ve*ve));if(0>fe&&(rt=-rt),re+=rt,oe+=ve*rt,a.translate(re,oe),a.rotate(ye),a.translate(-(ee/2),-(z/2)),tt===0&&E.hh(a,y),a.translate(ee/2,z/2),a.rotate(-ye),a.translate(-re,-oe),Ae-=b,Ce-=b,tt!==0){if(We++,We===Ye.length){Zi(Ye);return}Ce=Ye[We],fe=Ce[0],ye=Ce[1],ve=Ce[2],Ce=Ce[3],b=tt}}Zi(Ye)}}we.hh=function(a,y){var x=this.xc,E=this.Ui;if(x!==null||E!==null){var b=this.ua;if(b!==null){a.yc();var z=this.actualBounds,ee=this.naturalBounds;E!==null&&ks(this,a,E,!0,!1,ee,z);var re=this.part,oe=this.ig;if(x===null||oe!==0||re===null||!this.isPanelMain&&re.Pb()!==this||(oe=re.type===Ln.Link&&re instanceof Fo&&re.category==="Selection"&&re.adornedObject instanceof Dr&&re.adornedPart.Pb()===re.adornedObject?re.adornedObject.strokeWidth:0),oe===0&&(x=null),x!==null&&oe!==0&&(ks(this,a,x,!1,!1,ee,z),a.lineWidth=oe,a.lineJoin=this.strokeJoin,a.lineCap=this.strokeCap,a.miterLimit=this.strokeMiterLimit),z=!1,re&&y.Gf("drawShadows")&&(z=re.isShadowed),a.Il===!1&&(z=!1),re=!0,x===null||E!==null&&E!=="transparent"||(re=!1),ee=!1,oe=this.strokeDashArray,oe!==null&&(ee=!0,a.js(oe,this.strokeDashOffset)),b.type===Bn.j)a.beginPath(),a.moveTo(b.startX,b.startY),a.lineTo(b.endX,b.endY),x!==null&&a.jk(),a.Se();else if(b.type===Bn.u){var se=b.startX;oe=b.startY;var ue=b.endX,fe=b.endY;b=Math.min(se,ue);var ve=Math.min(oe,fe);se=Math.abs(ue-se),oe=Math.abs(fe-oe),a.beginPath(),a.rect(b,ve,se,oe),E!==null&&a.ng(E),x!==null&&(re&&z&&Gc(a),a.jk(),re&&z&&id(a)),a.Se()}else if(b.type===Bn.F)se=b.startX,oe=b.startY,ue=b.endX,fe=b.endY,b=Math.abs(ue-se)/2,ve=Math.abs(fe-oe)/2,se=Math.min(se,ue)+b,oe=Math.min(oe,fe)+ve,a.beginPath(),a.moveTo(se,oe-ve),a.bezierCurveTo(se+yt.wg*b,oe-ve,se+b,oe-yt.wg*ve,se+b,oe),a.bezierCurveTo(se+b,oe+yt.wg*ve,se+yt.wg*b,oe+ve,se,oe+ve),a.bezierCurveTo(se-yt.wg*b,oe+ve,se-b,oe+yt.wg*ve,se-b,oe),a.bezierCurveTo(se-b,oe-yt.wg*ve,se-yt.wg*b,oe-ve,se,oe-ve),a.closePath(),E!==null&&a.ng(E),x!==null&&(re&&z&&Gc(a),a.jk(),re&&z&&id(a)),a.Se();else if(b.type===Bn.o)for(b=b.figures,oe=b.length,ve=0;ve<oe;ve++){se=b.s[ve],a.beginPath(),a.moveTo(se.startX,se.startY),ue=se.segments.s,fe=ue.length;for(var ye=null,Ce=0;Ce<fe;Ce++){var Ae=ue[Ce];switch(Ae.type){case xs:a.moveTo(Ae.endX,Ae.endY);break;case fi:a.lineTo(Ae.endX,Ae.endY);break;case po:a.bezierCurveTo(Ae.point1X,Ae.point1Y,Ae.point2X,Ae.point2Y,Ae.endX,Ae.endY);break;case Vo:a.quadraticCurveTo(Ae.point1X,Ae.point1Y,Ae.endX,Ae.endY);break;case qo:if(Ae.radiusX===Ae.radiusY){var Ye=Math.PI/180;a.arc(Ae.point1X,Ae.point1Y,Ae.radiusX,Ae.startAngle*Ye,(Ae.startAngle+Ae.sweepAngle)*Ye,0>Ae.sweepAngle,ye!==null?ye.endX:se.startX,ye!==null?ye.endY:se.startY)}else if(ye=Bl(Ae,se),Ye=ye.length,Ye===0)a.lineTo(Ae.centerX,Ae.centerY);else for(var We=0;We<Ye;We++){var tt=ye[We];We===0&&a.lineTo(tt[0],tt[1]),a.bezierCurveTo(tt[2],tt[3],tt[4],tt[5],tt[6],tt[7])}break;case Ja:if(We=Ye=0,ye!==null&&ye.type===qo){if(ye=Bl(ye,se),tt=ye.length,tt===0){a.lineTo(Ae.endX,Ae.endY);break}ye=ye[tt-1]||null,ye!==null&&(Ye=ye[6],We=ye[7])}else Ye=ye!==null?ye.endX:se.startX,We=ye!==null?ye.endY:se.startY;if(ye=Pl(Ae,se,Ye,We),Ye=ye.length,Ye===0){a.lineTo(Ae.endX,Ae.endY);break}for(We=0;We<Ye;We++)tt=ye[We],a.bezierCurveTo(tt[2],tt[3],tt[4],tt[5],tt[6],tt[7]);break;default:Dt("Segment not of valid type: "+Ae.type)}Ae.isClosed&&a.closePath(),ye=Ae}ue=se.isFilled,z?se.isShadowed?(ue===!0&&E!=="transparent"&&E!==null&&a.ng(E,se.isEvenOdd),x!==null&&(ue&&re&&Gc(a),a.jk(),ue&&re&&id(a))):(Gc(a),ue&&E!=="transparent"&&E!==null&&a.ng(E,se.isEvenOdd),x!==null&&a.jk(),id(a)):(ue&&E!==null&&a.ng(E,se.isEvenOdd),x!==null&&a.jk()),a.Se(ve)}if(ee&&a.fs(),this.pathPattern!==null){if(x=this.pathPattern,x.measure(1/0,1/0),E=x.measuredBounds,x.arrange(0,0,E.width,E.height),z=this.geometry,a.save(),a.beginPath(),E=qi(),z.type===Bn.j)E.push(z.startX),E.push(z.startY),E.push(z.endX),E.push(z.endY),Pg(a,y,E,x);else if(z.type===Bn.o)for(z=z.figures.iterator;z.next();){for(re=z.value,E.length=0,E.push(re.startX),E.push(re.startY),ee=re.startX,b=re.startY,oe=ee,ve=b,se=re.segments.s,ue=se.length,fe=0;fe<ue;fe++){switch(Ce=se[fe],Ce.type){case xs:Pg(a,y,E,x),E.length=0,E.push(Ce.endX),E.push(Ce.endY),ee=Ce.endX,b=Ce.endY,oe=ee,ve=b;break;case fi:E.push(Ce.endX),E.push(Ce.endY),ee=Ce.endX,b=Ce.endY;break;case po:yt.Qe(ee,b,Ce.point1X,Ce.point1Y,Ce.point2X,Ce.point2Y,Ce.endX,Ce.endY,.5,E),ee=Ce.endX,b=Ce.endY;break;case Vo:yt.ep(ee,b,Ce.point1X,Ce.point1Y,Ce.endX,Ce.endY,.5,E),ee=Ce.endX,b=Ce.endY;break;case qo:if(Ae=Bl(Ce,re),ye=Ae.length,ye===0){E.push(Ce.centerX),E.push(Ce.centerY),ee=Ce.centerX,b=Ce.centerY;break}for(Ye=0;Ye<ye;Ye++)We=Ae[Ye],yt.Qe(ee,b,We[2],We[3],We[4],We[5],We[6],We[7],.5,E),ee=We[6],b=We[7];break;case Ja:if(Ae=Pl(Ce,re,ee,b),ye=Ae.length,ye===0){E.push(Ce.endX),E.push(Ce.endY),ee=Ce.endX,b=Ce.endY;break}for(Ye=0;Ye<ye;Ye++)We=Ae[Ye],yt.Qe(ee,b,We[2],We[3],We[4],We[5],We[6],We[7],.5,E),ee=We[6],b=We[7];break;default:Dt("Segment not of valid type: "+Ce.type)}Ce.isClosed&&(E.push(oe),E.push(ve),Pg(a,y,E,x))}Pg(a,y,E,x)}else if(z.type===Bn.u)E.push(z.startX),E.push(z.startY),E.push(z.endX),E.push(z.startY),E.push(z.endX),E.push(z.endY),E.push(z.startX),E.push(z.endY),E.push(z.startX),E.push(z.startY),Pg(a,y,E,x);else if(z.type===Bn.F){if(b=new Ns,b.startX=z.endX,b.startY=(z.startY+z.endY)/2,ee=new to(qo),ee.startAngle=0,ee.sweepAngle=360,ee.centerX=(z.startX+z.endX)/2,ee.centerY=(z.startY+z.endY)/2,ee.radiusX=Math.abs(z.startX-z.endX)/2,ee.radiusY=Math.abs(z.startY-z.endY)/2,b.add(ee),z=Bl(ee,b),re=z.length,re===0)E.push(ee.centerX),E.push(ee.centerY);else for(ee=b.startX,b=b.startY,oe=0;oe<re;oe++)ve=z[oe],yt.Qe(ee,b,ve[2],ve[3],ve[4],ve[5],ve[6],ve[7],.5,E),ee=ve[6],b=ve[7];Pg(a,y,E,x)}Zi(E),a.restore(),a.Vc(!1)}}}},we.kk=function(a,y,x){return!mt.prototype.kk.call(this,a,y,x)||this.xc===null&&this.Ui===null||this.ua===null||this.pathPattern!==null||this.geometry.figures.length!==this.svg.getElementsByTagName("path").length?!1:(a.Hl=this.svg,this.hh(a,y),a.Hl=null,!0)},we.nk=function(a){return this.geometry!==null&&1<this.geometry.figures.length||this.pathPattern!==null?!0:mt.prototype.nk.call(this,a)},we.Dv=function(a,y){if(a.nodeName!=="g")a.setAttributeNS(null,"filter",y);else{a=a.getElementsByTagName("path");for(var x=0;x<a.length;x++)a[x].setAttributeNS(null,"filter",y)}},we.ga=function(a,y){if(y===void 0&&(y=new Qe),a instanceof Bi){a.Mc()&&Dt("getDocumentPoint Spot must be a real, specific Spot, not: "+a.toString());var x=this.naturalBounds,E=this.strokeWidth;y.h(a.x*(x.width+E)-E/2+x.x+a.offsetX,a.y*(x.height+E)-E/2+x.y+a.offsetY)}else y.set(a);return this.oe.Ga(y),y},we.mi=function(a){a===void 0&&(a=new Xt);var y=this.naturalBounds,x=this.oe;y=Xt.allocAt(y.x,y.y,y.width,y.height);var E=this.strokeWidth;return y.Bc(E/2,E/2),E=Qe.allocAt(y.x,y.y).transform(x),a.h(E.x,E.y,0,0),E.h(y.right,y.y).transform(x),es(a,E.x,E.y,0,0),E.h(y.right,y.bottom).transform(x),es(a,E.x,E.y,0,0),E.h(y.x,y.bottom).transform(x),es(a,E.x,E.y,0,0),Xt.free(y),Qe.free(E),a},we.gh=function(a,y){var x=this.geometry;if(x===null||this.fill===null&&this.stroke===null)return!1;var E=x.bounds,b=this.strokeWidth/2;x.type!==Bn.j||y||(b+=2);var z=Xt.alloc();if(z.assign(E),z.Bc(b+2,b+2),!z.ca(a))return Xt.free(z),!1;if(E=b+1e-4,x.type===Bn.j)return this.stroke===null||(E=(x.endX-x.startX)*(a.x-x.startX)+(x.endY-x.startY)*(a.y-x.startY),0>(x.startX-x.endX)*(a.x-x.endX)+(x.startY-x.endY)*(a.y-x.endY)||0>E)?!1:(Xt.free(z),yt.Yb(x.startX,x.startY,x.endX,x.endY,b,a.x,a.y));if(x.type===Bn.u){y=x.startX;var ee=x.startY,re=x.endX;if(x=x.endY,z.x=Math.min(y,re),z.y=Math.min(ee,x),z.width=Math.abs(re-y),z.height=Math.abs(x-ee),this.fill===null){if(z.Bc(-E,-E),z.ca(a))return Xt.free(z),!1;z.Bc(E,E)}return this.stroke!==null&&z.Bc(b,b),a=z.ca(a),Xt.free(z),a}if(x.type===Bn.F){ee=x.startX,b=x.startY,re=x.endX;var oe=x.endY;if(x=Math.min(ee,re),y=Math.min(b,oe),ee=Math.abs(re-ee)/2,b=Math.abs(oe-b)/2,x=a.x-(x+ee),y=a.y-(y+b),this.fill===null){if(ee-=E,b-=E,0>=ee||0>=b||1>=x*x/(ee*ee)+y*y/(b*b))return Xt.free(z),!1;ee+=E,b+=E}return this.stroke!==null&&(ee+=E,b+=E),Xt.free(z),0>=ee||0>=b?!1:1>=x*x/(ee*ee)+y*y/(b*b)}if(x.type===Bn.o)return Xt.free(z),this.fill===null?Tu(x,a.x,a.y,b):$u(x,a,b,1<this.strokeWidth,y);Dt("Unknown Geometry type: "+x.type)},we.Wl=function(a,y,x,E){var b=this.desiredSize,z=this.ig;if(a=Math.max(a,0),y=Math.max(y,0),this.Rd!==null)var ee=this.geometry.bounds;else{var re=this.figure,oe=b0[re];if(oe===void 0){var se=yt.Ze[re];typeof se=="string"&&(se=yt.Ze[se]),typeof se=="function"?(oe=se(null,100,100),b0[re]=oe):Dt("Unsupported Figure: "+re)}ee=oe.bounds}re=ee.width,oe=ee.height,se=ee.width;var ue=ee.height;switch(Ou(this,!0)){case mn:E=x=0;break;case Cn:se=Math.max(a-z,0),ue=Math.max(y-z,0);break;case Mi:se=Math.max(a-z,0),E=0;break;case Yi:x=0,ue=Math.max(y-z,0)}isFinite(b.width)&&(se=b.width),isFinite(b.height)&&(ue=b.height);var fe=this.maxSize,ve=this.minSize;switch(x=Math.max(x-z,ve.width),E=Math.max(E-z,ve.height),se=Math.min(fe.width,se),ue=Math.min(fe.height,ue),se=isFinite(se)?Math.max(x,se):Math.max(re,x),ue=isFinite(ue)?Math.max(E,ue):Math.max(oe,E),x=E0(this),x){case mn:break;case Cn:re=se,oe=ue;break;case xi:x=Math.min(se/re,ue/oe),isFinite(x)||(x=1),re*=x,oe*=x;break;default:Dt(x+" is not a valid geometryStretch.")}this.Rd!==null?(re===0&&(re=.001),oe===0&&(oe=.001),x=this.Rd!==null?this.Rd:this.ua,ee=x.bounds,E=re/ee.width,ee=oe/ee.height,isFinite(E)||(E=1),isFinite(ee)||(ee=1),this.ua=E===1&&ee===1?x:x.copy().scale(E,ee)):this.ua!==null&&yt.$(this.ua.Sk,a-z)&&yt.$(this.ua.Rk,y-z)||(this.ua=Dr.makeGeometry(this,re,oe)),ee=this.ua.bounds,a===1/0||y===1/0?this.Ge(ee.x-z/2,ee.y-z/2,a===0&&re===0?0:ee.width+z,y===0&&oe===0?0:ee.height+z):this.Ge(-(z/2),-(z/2),se+z,ue+z),b.w()?(se=b.width,ue=b.height,se=Math.min(fe.width,se),ue=Math.min(fe.height,ue),se=Math.max(ve.width,se),ue=Math.max(ve.height,ue),this.dc.h(0,0,se,ue)):this.dc.assign(ee)};function E0(a){var y=a.geometryStretch;return a.Rd!==null?y===Cr?Cn:y:y===Cr?b0[a.figure].defaultStretch:y}we.eh=function(a,y,x,E){uu(this,a,y,x,E)},we.rs=function(a,y,x){return this.Sj(a.x,a.y,y.x,y.y,x)},we.Sj=function(a,y,x,E,b){var z=this.transform,ee=1/(z.m11*z.m22-z.m12*z.m21),re=z.m22*ee,oe=-z.m12*ee,se=-z.m21*ee,ue=z.m11*ee,fe=ee*(z.m21*z.dy-z.m22*z.dx),ve=ee*(z.m12*z.dx-z.m11*z.dy);z=a*re+y*se+fe,ee=a*oe+y*ue+ve,re=x*re+E*se+fe,oe=x*oe+E*ue+ve,fe=this.ig/2,se=this.ua,se===null&&(this.measure(1/0,1/0),se=this.ua);var ye=se.bounds;if(ue=!1,se.type===Bn.j)if(1.5>=this.strokeWidth)ue=yt.Ve(se.startX,se.startY,se.endX,se.endY,z,ee,re,oe,b);else{if(se.startX===se.endX?(E=fe,ue=0):(y=(se.endY-se.startY)/(se.endX-se.startX),ue=fe/Math.sqrt(1+y*y),E=ue*y),y=qi(),a=new Qe,yt.Ve(se.startX+E,se.startY+ue,se.endX+E,se.endY+ue,z,ee,re,oe,a)&&y.push(a),a=new Qe,yt.Ve(se.startX-E,se.startY-ue,se.endX-E,se.endY-ue,z,ee,re,oe,a)&&y.push(a),a=new Qe,yt.Ve(se.startX+E,se.startY+ue,se.startX-E,se.startY-ue,z,ee,re,oe,a)&&y.push(a),a=new Qe,yt.Ve(se.endX+E,se.endY+ue,se.endX-E,se.endY-ue,z,ee,re,oe,a)&&y.push(a),re=y.length,re===0)return Zi(y),!1;for(ue=!0,oe=1/0,E=0;E<re;E++)a=y[E],x=(a.x-z)*(a.x-z)+(a.y-ee)*(a.y-ee),x<oe&&(oe=x,b.x=a.x,b.y=a.y);Zi(y)}else if(se.type===Bn.u)ue=yt.Ff(ye.x-fe,ye.y-fe,ye.x+ye.width+fe,ye.y+ye.height+fe,z,ee,re,oe,b);else if(se.type===Bn.F){y=Xt.allocAt(ye.x,ye.y,ye.width,ye.height).Bc(fe,fe);e:if(y.width===0)ue=yt.Ve(y.x,y.y,y.x,y.y+y.height,z,ee,re,oe,b);else if(y.height===0)ue=yt.Ve(y.x,y.y,y.x+y.width,y.y,z,ee,re,oe,b);else{if(a=y.width/2,se=y.height/2,E=y.x+a,ue=y.y+se,x=9999,z!==re&&(x=(ee-oe)/(z-re)),9999>Math.abs(x)){if(oe=ee-ue-x*(z-E),0>a*a*x*x+se*se-oe*oe){b.x=NaN,b.y=NaN,ue=!1;break e}fe=Math.sqrt(a*a*x*x+se*se-oe*oe),re=(-(a*a*x*oe)+a*se*fe)/(se*se+a*a*x*x)+E,a=(-(a*a*x*oe)-a*se*fe)/(se*se+a*a*x*x)+E,se=x*(re-E)+oe+ue,oe=x*(a-E)+oe+ue,Math.abs((z-re)*(z-re))+Math.abs((ee-se)*(ee-se))<Math.abs((z-a)*(z-a))+Math.abs((ee-oe)*(ee-oe))?(b.x=re,b.y=se):(b.x=a,b.y=oe)}else{if(re=se*se,oe=z-E,re-=re/(a*a)*oe*oe,0>re){b.x=NaN,b.y=NaN,ue=!1;break e}oe=Math.sqrt(re),re=ue+oe,oe=ue-oe,Math.abs(re-ee)<Math.abs(oe-ee)?(b.x=z,b.y=re):(b.x=z,b.y=oe)}ue=!0}Xt.free(y)}else if(se.type===Bn.o){ve=Qe.alloc();var Ce=re-z,Ae=oe-ee,Ye=Ce*Ce+Ae*Ae,We=z,tt=ee;if(0<Ye&&ye.contains(We,tt)&&(ve.x=We,ve.y=tt,this.ca(ve)))for(Ce!==0&&.5>Math.abs(Ce)?(Ae*=.5/Ce,Ce=.5):Ae!==0&&.5>Math.abs(Ae)&&(Ce*=.5/Ae,Ae=.5),We-=Ce,tt-=Ae;ye.contains(We,tt);)We-=Ce,tt-=Ae;for(b.x=re,b.y=oe,Ae=0;Ae<se.figures.count;Ae++){var rt=se.figures.s[Ae],at=rt.isFilled?We:z,gt=rt.isFilled?tt:ee,At=rt.segments;ye=rt.startX,Ce=rt.startY;for(var Zn=ye,mi=Ce,si=0;si<At.count;si++){var Nn=At.s[si],pn=Nn.type,yr=Nn.endX,sr=Nn.endY,Io=!1;switch(pn){case xs:Zn=yr,mi=sr;break;case fi:Io=Bm(ye,Ce,yr,sr,at,gt,re,oe,ve);break;case po:Io=yt.Eo(ye,Ce,Nn.point1X,Nn.point1Y,Nn.point2X,Nn.point2Y,yr,sr,at,gt,re,oe,.6,ve);break;case Vo:Io=yt.Eo(ye,Ce,ye+2/3*(Nn.point1X-ye),Ce+2/3*(Nn.point1Y-Ce),yr+2/3*(Nn.point1X-yr),sr+2/3*(Nn.point1Y-sr),yr,sr,at,gt,re,oe,.6,ve);break;case qo:case Ja:pn=Nn.type===qo?Bl(Nn,rt):Pl(Nn,rt,ye,Ce);var Oa=pn.length;if(Oa===0){Io=Bm(ye,Ce,Nn.type===qo?Nn.centerX:Nn.endX,Nn.type===qo?Nn.centerY:Nn.endY,at,gt,re,oe,ve);break}for(sr=null,yr=0;yr<Oa;yr++){if(sr=pn[yr],yr===0&&Bm(ye,Ce,sr[0],sr[1],at,gt,re,oe,ve)){var gl=Dm(at,gt,ve,Ye,b);gl<Ye&&(Ye=gl,ue=!0)}yt.Eo(sr[0],sr[1],sr[2],sr[3],sr[4],sr[5],sr[6],sr[7],at,gt,re,oe,.6,ve)&&(gl=Dm(at,gt,ve,Ye,b),gl<Ye&&(Ye=gl,ue=!0))}yr=sr[6],sr=sr[7];break;default:Dt("Unknown Segment type: "+pn)}ye=yr,Ce=sr,Io&&(Io=Dm(at,gt,ve,Ye,b),Io<Ye&&(Ye=Io,ue=!0)),Nn.isClosed&&(yr=Zn,sr=mi,Bm(ye,Ce,yr,sr,at,gt,re,oe,ve)&&(Nn=Dm(at,gt,ve,Ye,b),Nn<Ye&&(Ye=Nn,ue=!0)))}}z=x-a,ee=E-y,re=Math.sqrt(z*z+ee*ee),re!==0&&(z/=re,ee/=re),b.x-=z*fe,b.y-=ee*fe,Qe.free(ve)}else Dt("Unknown Geometry type: "+se.type);return ue?(this.transform.Ga(b),!0):!1};function Dm(a,y,x,E,b){return a=x.x-a,y=x.y-y,y=a*a+y*y,y<E?(b.x=x.x,b.y=x.y,y):E}function Bm(a,y,x,E,b,z,ee,re,oe){if(yt.$(a,x)&&yt.$(y,E)||yt.$(b,ee)&&yt.$(z,re))return!1;var se=!1,ue=(b-ee)*(y-E)-(z-re)*(a-x);return ue===0?!1:(oe.x=((b*re-z*ee)*(a-x)-(b-ee)*(a*E-y*x))/ue,oe.y=((b*re-z*ee)*(y-E)-(z-re)*(a*E-y*x))/ue,(a>x?a-x:x-a)<(y>E?y-E:E-y)?(a=y<E?y:E,y=y<E?E:y,(oe.y>a||yt.$(oe.y,a))&&(oe.y<y||yt.$(oe.y,y))&&(se=!0)):(y=a<x?a:x,a=a<x?x:a,(oe.x>y||yt.$(oe.x,y))&&(oe.x<a||yt.$(oe.x,a))&&(se=!0)),se)}we.fh=function(a,y){if(y===void 0)return a.Re(this.actualBounds);var x=this.ua;x===null&&(this.measure(1/0,1/0),x=this.ua),x=x.bounds;var E=this.strokeWidth/2,b=!1,z=Qe.alloc();return z.h(x.x-E,x.y-E),a.ca(y.Ga(z))&&(z.h(x.x-E,x.bottom+E),a.ca(y.Ga(z))&&(z.h(x.right+E,x.bottom+E),a.ca(y.Ga(z))&&(z.h(x.right+E,x.y-E),a.ca(y.Ga(z))&&(b=!0)))),Qe.free(z),b},we.Yc=function(a,y){if(this.fh(a,y)||y===void 0&&(y=this.transform,a.Re(this.actualBounds)))return!0;var x=kr.alloc();x.set(y),x.Vj();var E=a.left,b=a.right,z=a.top;a=a.bottom;var ee=Qe.alloc();if(ee.h(E,z),x.Ga(ee),this.gh(ee,!0)||(ee.h(b,z),x.Ga(ee),this.gh(ee,!0))||(ee.h(E,a),x.Ga(ee),this.gh(ee,!0))||(ee.h(b,a),x.Ga(ee),this.gh(ee,!0)))return Qe.free(ee),!0;var re=Qe.alloc(),oe=Qe.alloc();return x.set(y),x.bv(this.transform),x.Vj(),re.x=b,re.y=z,re.transform(x),ee.x=E,ee.y=z,ee.transform(x),y=!1,wf(this,ee,re,oe)?y=!0:(ee.x=b,ee.y=a,ee.transform(x),wf(this,ee,re,oe)?y=!0:(re.x=E,re.y=a,re.transform(x),wf(this,ee,re,oe)?y=!0:(ee.x=E,ee.y=z,ee.transform(x),wf(this,ee,re,oe)&&(y=!0)))),Qe.free(ee),kr.free(x),Qe.free(re),Qe.free(oe),y};function wf(a,y,x,E){if(!a.rs(y,x,E))return!1;a=y.x,y=y.y;var b=x.x,z=x.y;return x=E.x,E=E.y,a===b?(y<z?(a=y,y=z):a=z,E>=a&&E<=y):(a<b?(E=a,a=b):E=b,x>=E&&x<=a)}we.tx=function(a,y,x){function E(Ye,We){for(var tt=Ye.length,rt=0;rt<tt;rt+=2)if(We.zd(Ye[rt],Ye[rt+1])>b)return!0;return!1}if(x&&this.fill!==null&&this.gh(a,!0))return!0;var b=a.Bf(y),z=b;if(1.5<this.strokeWidth&&(b=this.strokeWidth/2+Math.sqrt(b),b*=b),y=this.ua,y===null&&(this.measure(1/0,1/0),y=this.ua,y===null))return!1;if(!x){var ee=y.bounds,re=ee.x,oe=ee.y,se=ee.x+ee.width;if(ee=ee.y+ee.height,Or(a.x,a.y,re,oe)<=b&&Or(a.x,a.y,se,oe)<=b&&Or(a.x,a.y,re,ee)<=b&&Or(a.x,a.y,se,ee)<=b)return!0}if(re=y.startX,oe=y.startY,se=y.endX,ee=y.endY,y.type===Bn.j){if(x=(re-se)*(a.x-se)+(oe-ee)*(a.y-ee),ps(a.x,a.y,re,oe,se,ee)<=(0<=(se-re)*(a.x-re)+(ee-oe)*(a.y-oe)&&0<=x?b:z))return!0}else{if(y.type===Bn.u)return y=!1,x&&(y=ps(a.x,a.y,re,oe,re,ee)<=b||ps(a.x,a.y,re,oe,se,oe)<=b||ps(a.x,a.y,se,oe,se,ee)<=b||ps(a.x,a.y,re,ee,se,ee)<=b),y;if(y.type===Bn.F){y=a.x-(re+se)/2,z=a.y-(oe+ee)/2;var ue=Math.abs(se-re)/2,fe=Math.abs(ee-oe)/2;if(ue===0||fe===0)return ps(a.x,a.y,re,oe,se,ee)<=b;if(x){if(a=yt.$y(ue,fe,y,z),a*a<=b)return!0}else return!(Or(y,z,-ue,0)>=b||Or(y,z,0,-fe)>=b||Or(y,z,0,fe)>=b||Or(y,z,ue,0)>=b)}else if(y.type===Bn.o){if(se=y.bounds,z=se.x,re=se.y,oe=se.x+se.width,se=se.y+se.height,a.x>oe&&a.x<z&&a.y>se&&a.y<re&&ps(a.x,a.y,z,re,z,se)>b&&ps(a.x,a.y,z,re,oe,re)>b&&ps(a.x,a.y,oe,se,z,se)>b&&ps(a.x,a.y,oe,se,oe,re)>b)return!1;if(z=Math.sqrt(b),x){if(this.fill===null?Tu(y,a.x,a.y,z):$u(y,a,z,!0,!1))return!0}else{for(x=y.figures,y=0;y<x.count;y++){if(z=x.s[y],ee=z.startX,ue=z.startY,a.zd(ee,ue)>b)return!1;for(re=z.segments.s,oe=re.length,se=0;se<oe;se++)switch(fe=re[se],fe.type){case xs:case fi:if(ee=fe.endX,ue=fe.endY,a.zd(ee,ue)>b)return!1;break;case po:var ve=qi();if(yt.Qe(ee,ue,fe.point1X,fe.point1Y,fe.point2X,fe.point2Y,fe.endX,fe.endY,.8,ve),ee=E(ve,a),Zi(ve),ee||(ee=fe.endX,ue=fe.endY,a.zd(ee,ue)>b))return!1;break;case Vo:if(ve=qi(),yt.ep(ee,ue,fe.point1X,fe.point1Y,fe.endX,fe.endY,.8,ve),ee=E(ve,a),Zi(ve),ee||(ee=fe.endX,ue=fe.endY,a.zd(ee,ue)>b))return!1;break;case qo:case Ja:ve=fe.type===qo?Bl(fe,z):Pl(fe,z,ee,ue);var ye=ve.length;if(ye===0){if(ee=fe.type===qo?fe.centerX:fe.endX,ue=fe.type===qo?fe.centerY:fe.endY,a.zd(ee,ue)>b)return!1;break}fe=null;for(var Ce=qi(),Ae=0;Ae<ye;Ae++)if(fe=ve[Ae],Ce.length=0,yt.Qe(fe[0],fe[1],fe[2],fe[3],fe[4],fe[5],fe[6],fe[7],.8,Ce),E(Ce,a))return Zi(Ce),!1;Zi(Ce),fe!==null&&(ee=fe[6],ue=fe[7]);break;default:Dt("Unknown Segment type: "+fe.type)}}return!0}}}return!1},we.qc=function(){this.ua=null},we.kq=function(){return this.ig};function mS(a){var y=a.diagram;y!==null&&y.undoManager.isUndoingRedoing||(a.segmentOrientation=Ep,a.toArrow!=="None"?(a.segmentIndex=-1,a.alignmentFocus=Rs):a.fromArrow!=="None"&&(a.segmentIndex=0,a.alignmentFocus=new Bi(1-Rs.x,Rs.y)))}Dr.makeGeometry=function(a,y,x){if(a.toArrow!=="None")var E=Wc[a.toArrow];else a.fromArrow!=="None"?E=Wc[a.fromArrow]:(E=yt.Ze[a.figure],typeof E=="string"&&(E=yt.Ze[E]),E===void 0&&Dt("Unknown Shape.figure: "+a.figure),E=E(a,y,x),E.Sk=y,E.Rk=x);if(E===null){var b=yt.Ze.Rectangle;typeof b=="function"&&(E=b(a,y,x))}return E};function vS(a){var y=Wc[a];if(y===void 0){var x=a.toLowerCase();if(x==="none")return"None";if(y=Wc[x],y===void 0){var E=null,b;for(b in yt.um)if(b.toLowerCase()===x){E=b;break}if(E!==null)return a=Bn.parse(yt.um[E],!1),Wc[E]=a,x!==E&&(Wc[x]=E),E}}return typeof y=="string"?y:y instanceof Bn?a:null}Yt.Object.defineProperties(Dr.prototype,{geometry:{get:function(){return this.ua!==null?this.ua:this.Rd},set:function(a){var y=this.ua,x=this.Rd;if(y!==a){a!==null?this.Rd=this.ua=a.freeze():this.Rd=this.ua=null;var E=this.part;E!==null&&(E.ag=NaN),this.v(),this.g("geometry",y||x,a),Rl(this)&&(a=this.part,a!==null&&_a(this,a,"geometryString"))}}},geometryString:{get:function(){return this.geometry===null?"":this.geometry.toString()},set:function(a){a=Bn.parse(a);var y=a.normalize();this.geometry=a,this.position=a=Qe.allocAt(-y.x,-y.y),Qe.free(a)}},isGeometryPositioned:{get:function(){return(this.l&1048576)!==0},set:function(a){var y=(this.l&1048576)!==0;y!==a&&(this.l^=1048576,this.v(),this.g("isGeometryPositioned",y,a))}},fill:{get:function(){return this.Ui},set:function(a){var y=this.Ui;y!==a&&(a!==null&&Kf(a,"Shape.fill"),a instanceof ia&&a.freeze(),this.Ui=a,this.N(),this.g("fill",y,a))}},stroke:{get:function(){return this.xc},set:function(a){var y=this.xc;y!==a&&(a!==null&&Kf(a,"Shape.stroke"),a instanceof ia&&a.freeze(),this.xc=a,this.N(),this.g("stroke",y,a))}},strokeWidth:{get:function(){return this.ig},set:function(a){var y=this.ig;if(y!==a)if(0<=a){this.ig=a,this.v();var x=this.part;x!==null&&(x.ag=NaN),this.g("strokeWidth",y,a)}else gr(a,"value >= 0",Dr,"strokeWidth:value")}},strokeCap:{get:function(){return this.Na!==null?this.Na.Hr:"butt"},set:function(a){var y=this.strokeCap;y!==a&&(typeof a!="string"||a!=="butt"&&a!=="round"&&a!=="square"?gr(a,'"butt", "round", or "square"',Dr,"strokeCap"):(xf(this),this.Na.Hr=a,this.N(),this.g("strokeCap",y,a)))}},strokeJoin:{get:function(){return this.Na!==null?this.Na.Ir:"miter"},set:function(a){var y=this.strokeJoin;y!==a&&(typeof a!="string"||a!=="miter"&&a!=="bevel"&&a!=="round"?gr(a,'"miter", "bevel", or "round"',Dr,"strokeJoin"):(xf(this),this.Na.Ir=a,this.N(),this.g("strokeJoin",y,a)))}},strokeMiterLimit:{get:function(){return this.Na!==null?this.Na.Jr:10},set:function(a){var y=this.strokeMiterLimit;if(y!==a&&1<=a){xf(this),this.Na.Jr=a,this.N();var x=this.part;x!==null&&(x.ag=NaN),this.g("strokeMiterLimit",y,a)}}},strokeDashArray:{get:function(){return this.Yg},set:function(a){var y=this.Yg;if(y!==a){if(a!==null){for(var x=a.length,E=0,b=0;b<x;b++){var z=a[b];0<=z&&isFinite(z)||Dt("strokeDashArray:value "+z+" at index "+b+" must be a positive number or zero."),E+=z}if(E===0){if(y===null)return;a=null}}this.Yg=a,this.N(),this.g("strokeDashArray",y,a)}}},strokeDashOffset:{get:function(){return this.Na!==null?this.Na.uj:0},set:function(a){var y=this.strokeDashOffset;y!==a&&0<=a&&(xf(this),this.Na.uj=a,this.N(),this.g("strokeDashOffset",y,a))}},figure:{get:function(){return this.an},set:function(a){var y=this.an;if(y!==a){var x=yt.Ze[a];typeof x=="function"?x=a:(x=yt.Ze[a.toLowerCase()])||Dt("Unknown Shape.figure: "+a),y!==x&&(a=this.part,a!==null&&(a.ag=NaN),this.an=x,this.Rd=null,this.qc(),this.v(),this.g("figure",y,x))}}},toArrow:{get:function(){return this.Ua!==null?this.Ua.V:"None"},set:function(a){var y=this.toArrow;if(a===!0?a="Standard":a===!1&&(a=""),y!==a){var x=vS(a);x===null?Dt("Unknown Shape.toArrow: "+a):y!==x&&(this.Ua===null&&(this.Ua=new Wd),this.Ua.V=x,this.Rd=null,this.qc(),this.v(),mS(this),this.g("toArrow",y,x))}}},fromArrow:{get:function(){return this.Ua!==null?this.Ua.j:"None"},set:function(a){var y=this.fromArrow;if(a===!0?a="Standard":a===!1&&(a=""),y!==a){var x=vS(a);x===null?Dt("Unknown Shape.fromArrow: "+a):y!==x&&(this.Ua===null&&(this.Ua=new Wd),this.Ua.j=x,this.Rd=null,this.qc(),this.v(),mS(this),this.g("fromArrow",y,x))}}},spot1:{get:function(){return this.Na!==null?this.Na.fg:vs},set:function(a){var y=this.spot1;y.D(a)||(a=a.J(),xf(this),this.Na.fg=a,this.v(),this.g("spot1",y,a))}},spot2:{get:function(){return this.Na!==null?this.Na.gg:vs},set:function(a){var y=this.spot2;y.D(a)||(a=a.J(),xf(this),this.Na.gg=a,this.v(),this.g("spot2",y,a))}},parameter1:{get:function(){return this.Un},set:function(a){var y=this.Un;y!==a&&(this.Un=a,this.qc(),this.v(),this.g("parameter1",y,a))}},parameter2:{get:function(){return this.Vn},set:function(a){var y=this.Vn;y!==a&&(this.Vn=a,this.qc(),this.v(),this.g("parameter2",y,a))}},naturalBounds:{get:function(){return this.dc}},pathPattern:{get:function(){return this.Na!==null?this.Na.br:null},set:function(a){var y=this.pathPattern;y!==a&&(xf(this),this.Na.br=a,this.N(),this.g("pathPattern",y,a))}},geometryStretch:{get:function(){return this.Na!==null?this.Na.jq:Cr},set:function(a){var y=this.geometryStretch;y!==a&&(xf(this),this.Na.jq=a,this.v(),this.g("geometryStretch",y,a))}},interval:{get:function(){return this.fa!==null?this.fa.Tk:1},set:function(a){var y=this.interval;if(a=Math.round(a),y!==a&&a!==0&&isFinite(a)){this.fa===null&&(this.fa=new Vc),this.fa.Tk=a;var x=this.diagram;x!==null&&this.panel===x.grid&&zs(x),this.v(),x=this.panel,x!==null&&(x.graduatedIntervals=null),this.g("interval",y,a)}}},graduatedStart:{get:function(){return this.fa!==null?this.fa.u:0},set:function(a){var y=this.graduatedStart;y!==a&&(0>a?a=0:1<a&&(a=1),this.fa===null&&(this.fa=new Vc),this.fa.u=a,this.v(),this.g("graduatedStart",y,a))}},graduatedEnd:{get:function(){return this.fa!==null?this.fa.j:1},set:function(a){var y=this.graduatedEnd;y!==a&&(0>a?a=0:1<a&&(a=1),this.fa===null&&(this.fa=new Vc),this.fa.j=a,this.v(),this.g("graduatedEnd",y,a))}},graduatedSkip:{get:function(){return this.fa!==null?this.fa.o:null},set:function(a){var y=this.graduatedSkip;y!==a&&(this.fa===null&&(this.fa=new Vc),this.fa.o=a,this.v(),this.g("graduatedSkip",y,a))}}}),Dr.prototype.intersectsRect=Dr.prototype.Yc,Dr.prototype.containedInRect=Dr.prototype.fh,Dr.prototype.getNearestIntersectionPoint=Dr.prototype.rs,Dr.prototype.getDocumentBounds=Dr.prototype.mi,Dr.prototype.getDocumentPoint=Dr.prototype.ga;var Wc=new Er,b0=new Er;Dr.className="Shape",Dr.getFigureGenerators=function(){var a=new Li,y;for(y in yt.Ze)y!==y.toLowerCase()&&a.add(y,yt.Ze[y]);return a.freeze(),a},Dr.defineFigureGenerator=function(a,y){var x=a.toLowerCase(),E=yt.Ze;E[a]=y,E[x]=a},Dr.getArrowheadGeometries=function(){var a=new Li;for(E in yt.um)if(Wc[E]===void 0){var y=Bn.parse(yt.um[E],!1);Wc[E]=y,y=E.toLowerCase(),y!==E&&(Wc[y]=E)}for(var x in Wc)if(x!==x.toLowerCase()){var E=Wc[x];E instanceof Bn&&a.add(x,E)}return a.freeze(),a},Dr.defineArrowheadGeometry=function(a,y){var x=null;typeof y=="string"?x=Bn.parse(y,!1):x=y,y=a.toLowerCase(),y!=="none"&&a!==y||Dt("Shape.defineArrowheadGeometry name must not be empty or None or all-lower-case: "+a);var E=Wc;E[a]=x,E[y]=a};function L0(){this.nc=!1,this.Hr="butt",this.Ir="miter",this.Jr=10,this.uj=0,this.br=null,this.jq=Cr,this.gg=this.fg=vs}L0.prototype.copy=function(){var a=new L0;return a.Hr=this.Hr,a.Ir=this.Ir,a.Jr=this.Jr,a.uj=this.uj,a.br=this.br,a.jq=this.jq,a.fg=this.fg.J(),a.gg=this.gg.J(),a};function ja(a,y){return mt.call(this),zm||(Ru=Es?new Zh(null).context:null,zm=!0),this.l|=2097152,this.ec="",this.xc="black",this.Ae="13px sans-serif",this.Lq=this.Cb=this.Gc=0,this.da=this.fa=this.Gm=null,this.Ih=0,this.df=null,this.Le=0,this.ze=this.Qb=this.Qc=null,typeof a=="string"?this.text=a:a&&Object.assign(this,a),y&&Object.assign(this,y),this}Ct(ja,mt),ja.prototype.cloneProtected=function(a){mt.prototype.cloneProtected.call(this,a),a.ec=this.ec,a.xc=this.xc,a.Ae=this.Ae,a.Gc=this.Gc,a.Cb=this.Cb,a.Lq=this.Lq,a.Gm=this.Gm,this.fa!==null&&(a.fa=this.fa.copy()),this.da!==null&&(a.da=this.da.nc?this.da:this.da.copy()),a.Ih=this.Ih,a.df=this.df,a.Le=this.Le,a.Qc=this.Qc,a.Qb=this.Qb,a.ze=this.ze};function Nc(a){a.da===null?a.da=new D0:a.da.nc&&(a.da=a.da.copy())}we=ja.prototype,we.th=function(){mt.prototype.th.call(this),this.da!==null&&(this.da.nc=!0)};function yS(a,y){a.l=y.l|6144,a.pb=y.opacity,a.Ma=y.background,a.areaBackground=y.areaBackground,a.jd=y.desiredSize.J(),a.minSize=y.minSize.J(),a.maxSize=y.maxSize.J(),y.Lb!==null?a.Lb=y.Lb.copy():a.Lb=null,a.Ca=y.scale,a.Kb=y.angle,a.stretch=y.stretch,a.Kg=y.margin.J(),a.Jb=y.alignment.J(),a.sk=y.alignmentFocus.J(),a.segmentFraction=y.segmentFraction,a.segmentOffset=y.segmentOffset.J(),a.segmentOrientation=y.segmentOrientation,y.tb!==null&&(a.tb=y.tb.copy()),a.shadowVisible=y.shadowVisible,a.ec=y.ec,a.xc=y.xc,a.Ae=y.Ae,a.fa!==null&&(a.fa=y.fa.copy()),y.da!==null&&(a.da=y.da.nc?y.da:y.da.copy()),a.Ih=y.Ih}we.qb=function(a){a.classType===ja?this.wrap=a:mt.prototype.qb.call(this,a)},we.toString=function(){return 22<this.ec.length?'TextBlock("'+this.ec.substring(0,20)+'"...)':'TextBlock("'+this.ec+'")'},we.v=function(){mt.prototype.v.call(this)},we.hh=function(a,y){if(this.xc!==null&&this.ec.length!==0&&this.Ae!==null){var x=this.naturalBounds,E=this.actualBounds,b=x.width,z=x.height,ee=vp(this),re=a.textAlign=this.textAlign,oe=y.tn;re==="start"?re=oe?"right":"left":re==="end"&&(re=oe?"left":"right"),oe=this.isUnderline;var se=this.isStrikethrough;ks(this,a,this.xc,!0,!1,x,E),(oe||se)&&ks(this,a,this.xc,!1,!1,x,E),E=0,x=!1;var ue=this.oe,fe=ue.dx-(ee*ue.m21+ue.dx);ue=ue.dy-(ee*ue.m22+ue.dy);var ve=y.scale;switch(8>(fe*fe+ue*ue)*ve*ve&&(x=!0),y.ib!==a&&(x=!1),y.ib instanceof th&&(x=!1),y.Gf("textGreeking")===!1&&(x=!1),y=this.spacingAbove,fe=this.spacingBelow,this.flip){case wo:a.translate(b,0),a.scale(-1,1);break;case Gr:a.translate(0,z),a.scale(1,-1);break;case ua:a.translate(b,z),a.scale(-1,-1)}if(a.yc(),ue=this.Gc,ve=(y+ee+fe)*ue,z>ve&&(E=this.verticalAlignment,E=E.y*z-E.y*ve+E.offsetY),ue===1&&this.ze!==null)fe=this.Cb,fe>b&&(fe=b),this.Oj(this.ze,a,0,E+y,b,ee,fe,x,re,oe,se);else if(this.Qc!==null&&this.Qb!==null)for(ve=0;ve<ue;ve++){var ye=this.Qc[ve];ye>b&&(ye=b),E+=y,this.Oj(this.Qb[ve],a,0,E,b,ee,ye,x,re,oe,se),E+=ee+fe}switch(this.flip){case wo:a.scale(-1,1),a.translate(-b,0);break;case Gr:a.scale(1,-1),a.translate(0,-z);break;case ua:a.scale(-1,-1),a.translate(-b,-z)}}},we.Oj=function(a,y,x,E,b,z,ee,re,oe,se,ue){var fe=0;if(re)oe==="left"?fe=0:oe==="right"?fe=b-ee:oe==="center"&&(fe=(b-ee)/2),y.fillRect(x+fe,E+.25*z,ee,1);else{if(oe==="left"?fe=0:oe==="right"?fe=b:oe==="center"&&(fe=b/2),b=Om!==null?Om(this,z):.75*z,y.fillText(a,x+fe,E+b),a=z/20|0,a===0&&(a=1),oe==="right"?fe-=ee:oe==="center"&&(fe-=ee/2),se){re=Rm!==null?Rm(this,z):.8*z,oe=x+fe,se=E+re,b=x+fe+ee,re=E+re;var ve=a;y.beginPath(),y.lineWidth=ve,y.moveTo(oe,se),y.lineTo(b,re),y.stroke(),y.Se(),y instanceof th&&y.ad.classList.add("gojs-td")}ue&&(ue=E+z-z/2.2|0,a%2!==0&&(ue+=.5),E=x+fe,z=ue,x=x+fe+ee,ee=ue,fe=a,y.beginPath(),y.lineWidth=fe,y.moveTo(E,z),y.lineTo(x,ee),y.stroke(),y.Se(),y instanceof th&&y.ad.classList.add("gojs-td"))}},we.kk=function(a,y,x){if(!mt.prototype.kk.call(this,a,y,x))return!1;if(ks(this,a,this.xc,!0,!1,this.naturalBounds,this.actualBounds),x){if(this.svg.getElementsByTagName("text").length===0)return!0;for(y=this.svg.getElementsByClassName("gojs-td"),x=0;x<y.length;x++)Qy(a,y[x],!1)}else y=this.svg,y.innerHTML=this.text,Qy(a,y,!0);return!0},we.nk=function(a){return 1<this.lineCount||this.isUnderline||this.isStrikethrough?!0:mt.prototype.nk.call(this,a)},we.Dv=function(a,y){if(a.nodeName!=="g")a.setAttributeNS(null,"filter",y);else{a=a.getElementsByTagName("text");for(var x=0;x<a.length;x++)a[x].setAttributeNS(null,"filter",y)}},we.Wl=function(a,y,x,E){var b=this.Gc;this.Ih=a,this.l&=-16777217;var z=this.Ae;Ru!==null&&bS!==z&&(bS=Ru.font=z),this.Cb=this.Le=0,this.ze=this.Qb=this.Qc=this.df=null;var ee;if(isNaN(this.desiredSize.width)){if(z=this.ec.replace(/\r\n/g,`
`).replace(/\r/g,`
`),z.length===0)z=8;else if(this.isMultiline){for(var re=ee=0,oe=!1;!oe;){var se=z.indexOf(`
`,re);se===-1&&(se=z.length,oe=!0),re=z.substr(re,se-re),this.formatting===yp&&(re=re.trim()),ee=Math.max(ee,oc(re)),re=se+1}z=ee}else ee=z.indexOf(`
`,0),0<=ee&&(z=z.substr(0,ee)),z=oc(z);z=Math.min(z,a/this.scale)}else z=this.desiredSize.width;if(this.panel!==null&&(z=Math.min(z,this.panel.maxSize.width)),ee=xS(this,z),isNaN(this.desiredSize.height)?ee=Math.min(ee,y/this.scale):ee=this.desiredSize.height,oe=ee,this.Cb!==0&&this.Qc!==null&&this.Qb!==null&&this.overflow===Im&&(y=this.Ae,y=this.overflow===Im?SS(y):0,se=this.spacingAbove+this.spacingBelow,se=Math.max(0,vp(this)+se),oe=Math.min(this.maxLines-1,Math.max(Math.floor(oe/se+.01)-1,0)),!(oe+1>=this.Qb.length))){for(this.l|=16777216,se=this.Qb[oe],y=Math.max(1,a-y);oc(se)>y&&1<se.length;)se=se.substr(0,se.length-1);se+=Sp,y=oc(se),this.Qb[oe]=se,this.Qb=this.Qb.slice(0,oe+1),this.Qc[oe]=y,this.Qc=this.Qc.slice(0,oe+1),this.Le=this.Qb.length,this.Cb=Math.max(this.Cb,y),this.Gc=this.Le,this.Gc===1&&(this.ze=this.Qb[0])}(this.wrap===wS||isNaN(this.desiredSize.width))&&(z=isNaN(a)?this.Cb:Math.min(a,this.Cb)),z=Math.max(x,z),ee=Math.max(E,ee),Ll(this.dc,z,ee),this.Ge(0,0,z,ee),this.svg!==null&&b!==this.Gc&&(this.Uc=!0)},we.eh=function(a,y,x,E){uu(this,a,y,x,E)};function mp(a,y,x){a.ze===null?(a.ze=y,a.Cb=x):((a.Qb===null||a.Qc===null)&&(a.Qb=[],a.Qc=[],a.Qb.push(a.ze),a.Qc.push(a.Cb)),a.Qb.push(y),a.Qc.push(x),a.Qb.length>a.maxLines&&(a.l|=16777216))}function M0(a,y,x,E){var b=a.formatting===yp;b&&(y=y.trim());var z=0,ee=a.Ae,re=a.spacingAbove+a.spacingBelow;re=Math.max(0,vp(a)+re);var oe=a.overflow===Im?SS(ee):0;if(a.Gc>=a.maxLines)E!==null&&E.h(0,re);else if(ee=y,a.wrap===k0){a.Le=1;var se=oc(y);if(oe===0||se<=x)a.Cb=Math.max(a.Cb,se),mp(a,y,a.Cb),E!==null&&E.h(se,re);else{for(z=Cg(a,ee),ee=ee.substr(z.length),y=Cg(a,ee),se=oc(z+y);0<y.length&&se<=x;)z+=y,ee=ee.substr(y.length),y=Cg(a,ee),se=z+y,b&&(se=se.trim()),se=oc(se);for(b&&(y=y.trim()),z+=y,x=Math.max(1,x-oe);oc(z)>x&&1<z.length;)z=z.substr(0,z.length-1);a.l|=16777216,z+=Sp;var ue=oc(z);a.Cb=ue,mp(a,z,ue),E!==null&&E.h(ue,re)}}else{for(oe=0,ee.length===0&&(oe=1,mp(a,ee,0));0<ee.length;){for(y=Cg(a,ee),ee=ee.substr(y.length);oc(y)>x;){var fe=1;for(se=oc(y.substr(0,fe)),ue=0;se<=x;)fe++,ue=se,se=oc(y.substr(0,fe));if(fe===1){var ve=se;z=Math.max(z,se)}else ve=ue,z=Math.max(z,ue);if(fe--,1>fe&&(fe=1),mp(a,y.substr(0,fe),ve),oe++,y=y.substr(fe),a.Gc+oe>a.maxLines)break}for(ue=Cg(a,ee),se=oc(y+ue);0<ue.length&&se<=x;)y+=ue,ee=ee.substr(ue.length),ue=Cg(a,ee),se=y+ue,b&&(se=se.trim()),se=oc(se);if(b&&(y=y.trim()),y!==""&&(y[y.length-1]==="\xAD"&&(y=y.substring(0,y.length-1)+"\u2010"),ue.length===0?(fe=se,z=Math.max(z,se)):(fe=ue=oc(y),z=Math.max(z,ue)),mp(a,y,fe),oe++,a.Gc+oe>a.maxLines))break}a.Le=Math.min(a.maxLines,oe),a.Cb=Math.max(a.Cb,z),E!==null&&E.h(a.Cb,re*a.Le)}}function Cg(a,y){if(a.wrap===PS)return y.substr(0,1);for(var x=y.length,E=0,b=Sx;E<x&&!b.test(y.charAt(E));)E++;for(a.formatting===CS&&(x=Math.min(x,E+1));E<x&&b.test(y.charAt(E));)E++;return E>=y.length?y:y.substr(0,E)}function oc(a){return Ru===null?8*a.length:Ru.measureText(a).width}function vp(a){if(a.df!==null)return a.df;var y=a.Ae;if(Ru===null){var x=16;return a.df=x}return N0[y]!==void 0&&5e3>ES?x=N0[y]:(x=1.3*Ru.measureText("M").width,N0[y]=x,ES++),a.df=x}function SS(a){if(Ru===null)return 6;if(jm[a]!==void 0&&5e3>T0)var y=jm[a];else y=Ru.measureText(Sp).width,jm[a]=y,T0++;return y}function xS(a,y){var x=a.ec.replace(/\r\n/g,`
`).replace(/\r/g,`
`),E=a.spacingAbove+a.spacingBelow;if(E=Math.max(0,vp(a)+E),x.length===0)return a.Cb=0,a.Gc=1,E;if(!a.isMultiline){var b=x.indexOf(`
`,0);0<=b&&(x=x.substr(0,b))}b=0;for(var z=a.Gc=0,ee,re=!1;!re;){if(ee=x.indexOf(`
`,z),ee===-1&&(ee=x.length,re=!0),z<=ee){if(z=x.substr(z,ee-z),a.wrap!==k0){a.Le=0;var oe=fn.alloc();M0(a,z,y,oe),b+=oe.height,fn.free(oe),a.Gc+=a.Le}else M0(a,z,y,null),b+=E,a.Gc++;a.Gc===a.maxLines&&(re=!0)}z=ee+1}return a.Lq=b}Yt.Object.defineProperties(ja.prototype,{font:{get:function(){return this.Ae},set:function(a){var y=this.Ae;y!==a&&(this.Ae=a,this.df=null,this.v(),this.g("font",y,a))}},text:{get:function(){return this.ec},set:function(a){var y=this.ec;a!=null?a=a.toString():a="",y!==a&&(this.ec=a,this.v(),this.g("text",y,a),this.Uc=!0)}},textAlign:{get:function(){return this.da!==null?this.da.Or:"start"},set:function(a){var y=this.textAlign;y===a||a!=="start"&&a!=="end"&&a!=="left"&&a!=="right"&&a!=="center"||(Nc(this),this.da.Or=a,this.N(),this.g("textAlign",y,a))}},flip:{get:function(){return this.da!==null?this.da.Xf:mn},set:function(a){var y=this.flip;y!==a&&(Nc(this),this.da.Xf=a,this.N(),this.g("flip",y,a))}},verticalAlignment:{get:function(){return this.da!==null?this.da.Yr:Gh},set:function(a){var y=this.verticalAlignment;y.D(a)||(a=a.J(),Nc(this),this.da.Yr=a,yu(this),this.g("verticalAlignment",y,a))}},naturalBounds:{get:function(){if(!this.dc.w()){var a=fn.alloc();M0(this,this.ec,999999,a);var y=a.width;fn.free(a),a=xS(this,y);var x=this.desiredSize;isNaN(x.width)||(y=x.width),isNaN(x.height)||(a=x.height),Ll(this.dc,y,a)}return this.dc}},isMultiline:{get:function(){return(this.l&2097152)!==0},set:function(a){var y=(this.l&2097152)!==0;y!==a&&(this.l^=2097152,this.v(),this.g("isMultiline",y,a))}},isUnderline:{get:function(){return(this.l&4194304)!==0},set:function(a){var y=(this.l&4194304)!==0;y!==a&&(this.l^=4194304,this.Uc=!0,this.N(),this.g("isUnderline",y,a))}},isStrikethrough:{get:function(){return(this.l&8388608)!==0},set:function(a){var y=(this.l&8388608)!==0;y!==a&&(this.l^=8388608,this.Uc=!0,this.N(),this.g("isStrikethrough",y,a))}},wrap:{get:function(){return this.da!==null?this.da.$r:F0},set:function(a){var y=this.wrap;y!==a&&(Nc(this),this.da.$r=a,this.v(),this.g("wrap",y,a))}},overflow:{get:function(){return this.da!==null?this.da.$q:A0},set:function(a){var y=this.overflow;y!==a&&(Nc(this),this.da.$q=a,this.v(),this.g("overflow",y,a))}},isOverflowed:{get:function(){return(this.l&16777216)!==0}},stroke:{get:function(){return this.xc},set:function(a){var y=this.xc;y!==a&&(a!==null&&Kf(a,"TextBlock.stroke"),a instanceof ia&&a.freeze(),this.xc=a,this.N(),this.g("stroke",y,a))}},lineCount:{get:function(){return this.Gc}},lineHeight:{get:function(){return vp(this)}},editable:{get:function(){return(this.l&1048576)!==0},set:function(a){var y=(this.l&1048576)!==0;y!==a&&(this.l^=1048576,this.g("editable",y,a))}},textEditor:{get:function(){return this.da!==null?this.da.Qr:null},set:function(a){var y=this.textEditor;y!==a&&(Nc(this),this.da.Qr=a,this.g("textEditor",y,a))}},errorFunction:{get:function(){return this.da!==null?this.da.Hd:null},set:function(a){var y=this.errorFunction;y!==a&&(Nc(this),this.da.Hd=a,this.g("errorFunction",y,a))}},interval:{get:function(){return this.fa!==null?this.fa.Tk:1},set:function(a){var y=this.interval;if(a=Math.round(a),y!==a&&a!==0&&isFinite(a)){this.fa===null&&(this.fa=new Vc),this.fa.Tk=a,this.v();var x=this.panel;x!==null&&(x.graduatedIntervals=null),this.g("interval",y,a)}}},graduatedStart:{get:function(){return this.fa!==null?this.fa.u:0},set:function(a){var y=this.graduatedStart;y!==a&&(0>a?a=0:1<a&&(a=1),this.fa===null&&(this.fa=new Vc),this.fa.u=a,this.v(),this.g("graduatedStart",y,a))}},graduatedEnd:{get:function(){return this.fa!==null?this.fa.j:1},set:function(a){var y=this.graduatedEnd;y!==a&&(0>a?a=0:1<a&&(a=1),this.fa===null&&(this.fa=new Vc),this.fa.j=a,this.v(),this.g("graduatedEnd",y,a))}},graduatedFunction:{get:function(){return this.fa!==null?this.fa.F:null},set:function(a){var y=this.graduatedFunction;y!==a&&(this.fa===null&&(this.fa=new Vc),this.fa.F=a,this.v(),this.g("graduatedFunction",y,a))}},graduatedSkip:{get:function(){return this.fa!==null?this.fa.o:null},set:function(a){var y=this.graduatedSkip;y!==a&&(this.fa===null&&(this.fa=new Vc),this.fa.o=a,this.v(),this.g("graduatedSkip",y,a))}},textValidation:{get:function(){return this.da!==null?this.da.vj:null},set:function(a){var y=this.textValidation;y!==a&&(Nc(this),this.da.vj=a,this.g("textValidation",y,a))}},textEdited:{get:function(){return this.da!==null?this.da.Pr:null},set:function(a){var y=this.textEdited;y!==a&&(Nc(this),this.da.Pr=a,this.g("textEdited",y,a))}},spacingAbove:{get:function(){return this.da!==null?this.da.Dr:0},set:function(a){var y=this.spacingAbove;y!==a&&(Nc(this),this.da.Dr=a,this.v(),this.g("spacingAbove",y,a))}},spacingBelow:{get:function(){return this.da!==null?this.da.Er:0},set:function(a){var y=this.spacingBelow;y!==a&&(Nc(this),this.da.Er=a,this.v(),this.g("spacingBelow",y,a))}},formatting:{get:function(){return this.da!==null?this.da.gq:yp},set:function(a){var y=this.formatting;y!==a&&(Nc(this),this.da.gq=a,this.v(),this.g("formatting",y,a))}},maxLines:{get:function(){return this.da!==null?this.da.Jq:1/0},set:function(a){var y=this.maxLines;y!==a&&(a=Math.floor(a),0>=a&&gr(a,"> 0",ja,"maxLines"),Nc(this),this.da.Jq=a,this.v(),this.g("maxLines",y,a))}},metrics:{get:function(){return{arrSize:this.Qc!==null?this.Qc:[this.Cb],arrText:this.Qb!==null?this.Qb:[this.ze],maxLineWidth:this.Cb,fontHeight:this.df}}},choices:{get:function(){return this.Gm},set:function(a){var y=this.Gm;y!==a&&(this.Gm=a,this.g("choices",y,a))}}});var Om=null,Rm=null,k0=new Vt(ja,"None",0),wS=new Vt(ja,"WrapFit",1),F0=new Vt(ja,"WrapDesiredSize",2),PS=new Vt(ja,"WrapBreakAll",3),A0=new Vt(ja,"OverflowClip",0),Im=new Vt(ja,"OverflowEllipsis",1),yp=new Vt(ja,"FormatTrim",0),CS=new Vt(ja,"FormatNone",0),Sx=/[ \u200b\u00ad]/,N0=new Er,ES=0,jm=new Er,T0=0,Sp="...",bS="",Ru=null,zm=!1;ja.className="TextBlock";function D0(){this.nc=!1,this.Hd=null,this.Xf=mn,this.gq=yp,this.Jq=1/0,this.$q=A0,this.Er=this.Dr=0,this.Or="start",this.vj=this.Qr=this.Pr=null,this.Yr=Gh,this.$r=F0}D0.prototype.copy=function(){var a=new D0;return a.Hd=this.Hd,a.Xf=this.Xf,a.gq=this.gq,a.Jq=this.Jq,a.$q=this.$q,a.Dr=this.Dr,a.Er=this.Er,a.Or=this.Or,a.Pr=this.Pr,a.Qr=this.Qr,a.vj=this.vj,a.Yr=this.Yr,a.$r=this.$r,a},ja.getEllipsis=function(){return Sp},ja.setEllipsis=function(a){Sp=a,jm=new Er,T0=0},ja.getBaseline=function(){return Om},ja.setBaseline=function(a){Om=a},ja.getUnderline=function(){return Rm},ja.setUnderline=function(a){Rm=a},ja.isValidFont=function(a){if(zm||(Ru=Es?new Zh(null).context:null,zm=!0),Ru===null)return!0;var y=Ru.font;if(a===y||a==="10px sans-serif")return!0;Ru.font="10px sans-serif",Ru.font=a;var x=Ru.font;if(x!=="10px sans-serif")return Ru.font=y,!0;Ru.font="19px serif";var E=Ru.font;return Ru.font=a,x=Ru.font,Ru.font=y,x!==E},ja.FormatNone=CS,ja.FormatTrim=yp,ja.None=k0,ja.OverflowClip=A0,ja.OverflowEllipsis=Im,ja.WrapBreakAll=PS,ja.WrapDesiredSize=F0,ja.WrapFit=wS;function Vc(){this.Tk=1,this.u=0,this.j=1,this.o=this.F=null}Vc.prototype.copy=function(){var a=new Vc;return a.Tk=this.Tk,a.u=this.u,a.j=this.j,a.F=this.F,a.o=this.o,a},Vc.className="GradElementSettings";function Iu(a,y){mt.call(this),this.Eg=null,this.qo="",this.Xg=Ma,this.Nk=Cn,this.Zg=this.Hd=null,this.Mk=ko,this.Xf=mn,this.vl=null,this.qn=!1,this.en=!0,this.al=!1,this.bt=this.rl=null,typeof a=="string"?this.source=a:a&&Object.assign(this,a),y&&Object.assign(this,y)}var Eg;Ct(Iu,mt),Iu.prototype.cloneProtected=function(a){mt.prototype.cloneProtected.call(this,a),a.qo=this.qo,a.element=this.Eg,a.Xg=this.Xg.J(),a.Nk=this.Nk,a.Xf=this.Xf,a.Hd=this.Hd,a.Zg=this.Zg,a.Mk=this.Mk.J(),a.en=this.en,a.rl=this.rl},Iu.prototype.qb=function(a){a===mn||a===xi||a===ao?this.imageStretch=a:mt.prototype.qb.call(this,a)},Iu.prototype.toString=function(){return"Picture("+this.source+")#"+qa(this)};function bg(a){a===void 0&&(a=""),a!==""?Eg[a]&&(delete Eg[a],Hm--):(Eg=new Er,Hm=0)}function LS(a,y){y.qy||(y.Fq=function(x){y.sq=!0,y.ln=!1;var E=y.Bg.copy();if(E!=null){for(E=E.iterator;E.next();){var b=E.value;b.N();var z=y.getAttribute("src")||"",ee=b.Og.I(z);if(ee!==null)for(var re=ee.length,oe=0;oe<re;oe++)z=ee[oe],b.Xn.add(z),z.Uc=!0,b.$b(),y.hn&&(y.eu===void 0&&(y.eu=x),z.Zg!==null&&z.Zg(z,x))}y.Bg.clear()}a.desiredSize.w()||(Ys(a,!1),a.v())},y.Yp=function(x){y.ln=x;var E=y.Bg.copy();if(E!=null){for(E=E.iterator;E.next();){var b=E.value,z=y.getAttribute("src")||"",ee=b.Og.I(z);if(ee!==null){b=ee.length,z=qi();for(var re=0;re<b;re++)z.push(ee[re]);if(y.hn)for(re=0;re<b;re++)ee=z[re],ee.Hd!==null&&ee.Hd(ee,x);Zi(z)}}y.Bg.clear()}},y.addEventListener("load",y.Fq),y.addEventListener("error",y.Yp),y.qy=!0)}Iu.prototype.hA=function(){if(this.source!==""){bg(this.source);var a=this.source;this.source="",this.source=a}},Iu.prototype.redraw=function(){this.N(),this.Uc=!0},Iu.prototype.hh=function(a,y){var x=this.Eg;if(x!==null){var E=x.getAttribute("src");if(!(x instanceof HTMLImageElement&&(E===null||E==="")||x.ln instanceof Event&&a instanceof yf)){var b=a instanceof th;E=this.naturalBounds;var z=0,ee=0,re=this.qn,oe=re?+x.width:x.naturalWidth;if(re=re?+x.height:x.naturalHeight,oe===void 0&&x.videoWidth&&(oe=x.videoWidth),re===void 0&&x.videoHeight&&(re=x.videoHeight),oe=oe||E.width,re=re||E.height,oe!==0&&re!==0){var se=oe,ue=re;this.sourceRect.w()&&(z=this.Xg.x,ee=this.Xg.y,oe=this.Xg.width,re=this.Xg.height);var fe=oe,ve=re,ye=this.Nk,Ce=this.Mk;switch(ye){case mn:if(this.sourceRect.w())break;fe>=E.width&&(z=z+Ce.offsetX+(fe*Ce.x-E.width*Ce.x)),ve>=E.height&&(ee=ee+Ce.offsetY+(ve*Ce.y-E.height*Ce.y)),oe=Math.min(E.width,fe),re=Math.min(E.height,ve);break;case Cn:fe=E.width,ve=E.height;break;case xi:case ao:ye===xi?(ye=Math.min(E.height/ve,E.width/fe),fe*=ye,ve*=ye):ye===ao&&(ye=Math.max(E.height/ve,E.width/fe),fe*=ye,ve*=ye,fe>=E.width&&(z=(z+Ce.offsetX+(fe*Ce.x-E.width*Ce.x)/fe)*oe),ve>=E.height&&(ee=(ee+Ce.offsetY+(ve*Ce.y-E.height*Ce.y)/ve)*re),oe*=1/(fe/E.width),re*=1/(ve/E.height),fe=E.width,ve=E.height)}ye=this.Df()*y.scale;var Ae=fe*ye*ve*ye,Ye=oe*re/Ae,We=x.__goCache;ye=null;var tt=xx;if(!b){if(x.sq&&We!==void 0&&4<Ae&&Ye>tt*tt)for(We.gi===null&&(kS(We,4,se,ue,x),kS(We,16,se,ue,x)),b=We.gi,se=b.length,ue=0;ue<se&&b[ue].ratio*b[ue].ratio<Ye;ue++)ye=b[ue];if(!y.Xm){if(this.vl===null)if(this.Eg===null)this.vl=!1;else{b=new Zh(null).context;try{b.drawImage(this.Eg,0,0)}catch(rt){this.en=!1}try{b.getImageData(0,0,1,1).data[3]&&(this.vl=!1),this.vl=!1}catch(rt){this.vl=!0}}if(this.vl)return}}switch(b=fe<E.width?Ce.offsetX+(E.width*Ce.x-fe*Ce.x):0,Ce=ve<E.height?Ce.offsetY+(E.height*Ce.y-ve*Ce.y):0,this.flip){case wo:a.translate(Math.min(E.width,fe),0),a.scale(-1,1);break;case Gr:a.translate(0,Math.min(E.height,ve)),a.scale(1,-1);break;case ua:a.translate(Math.min(E.width,fe),Math.min(E.height,ve)),a.scale(-1,-1)}if(a.yc(),y.Gf("pictureRatioOptimization")&&!y.$i&&We!==void 0&&ye!==null&&ye.ratio!==1){a.save(),y=ye.ratio;try{a.drawImage(ye.source,z/y,ee/y,Math.min(ye.source.width,oe/y),Math.min(ye.source.height,re/y),b,Ce,Math.min(E.width,fe),Math.min(E.height,ve)),a instanceof th&&(this.bt=[z/y,ee/y,Math.min(ye.source.width,oe/y),Math.min(ye.source.height,re/y),b,Ce,Math.min(E.width,fe),Math.min(E.height,ve)])}catch(rt){this.en=!1}a.restore()}else try{a.drawImage(x,z,ee,oe,re,b,Ce,Math.min(E.width,fe),Math.min(E.height,ve)),a instanceof th&&(this.bt=[z,ee,oe,re,b,Ce,Math.min(E.width,fe),Math.min(E.height,ve)])}catch(rt){this.en=!1}switch(this.flip){case wo:a.scale(-1,1),a.translate(-Math.min(E.width,fe),0);break;case Gr:a.scale(1,-1),a.translate(0,-Math.min(E.height,ve));break;case ua:a.scale(-1,-1),a.translate(-Math.min(E.width,fe),-Math.min(E.height,ve))}}}}},Iu.prototype.Wl=function(a,y,x,E){var b=this.desiredSize,z=Ou(this,!0),ee=this.Eg,re=this.qn,oe=0,se=0;(re||!this.al&&ee&&ee.complete)&&(this.al=!0),ee===null?(isFinite(b.width)||(a=0),isFinite(b.height)||(y=0)):(oe=re?+ee.width:ee.naturalWidth,se=re?+ee.height:ee.naturalHeight),isFinite(b.width)||z===Cn||z===Mi?(isFinite(a)||(this.sourceRect.w()?a=this.sourceRect.width:ee!==null&&(a=oe)),x=0):ee!==null&&this.al!==!1&&(a=this.sourceRect.w()?this.sourceRect.width:oe),isFinite(b.height)||z===Cn||z===Yi?(isFinite(y)||(this.sourceRect.w()?y=this.sourceRect.height:ee!==null&&(y=se)),E=0):ee!==null&&this.al!==!1&&(y=this.sourceRect.w()?this.sourceRect.height:se),isFinite(b.width)&&(a=b.width),isFinite(b.height)&&(y=b.height),b=this.maxSize,z=this.minSize,x=Math.max(x||0,z.width),E=Math.max(E||0,z.height),a=Math.min(b.width,a),y=Math.min(b.height,y),a=Math.max(x,a),y=Math.max(E,y),ee===null||ee.complete||(isFinite(a)||(a=0),isFinite(y)||(y=0)),Ll(this.dc,a,y),this.Ge(0,0,a,y)},Iu.prototype.eh=function(a,y,x,E){uu(this,a,y,x,E)},Yt.Object.defineProperties(Iu.prototype,{element:{get:function(){return this.Eg},set:function(a){var y=this.Eg;if(this.Uc=!0,y!==a){this.qn=a instanceof HTMLCanvasElement;var x=a instanceof HTMLImageElement;a===null||x||a instanceof HTMLVideoElement||this.qn||Dt("Picture.element must be an instance of Image, Canvas, or Video, not: "+a);var E=this.diagram;E!==null&&Mc(E,this),this.Eg=a,a!==null&&x&&a.Bg===void 0&&(a.Bg=new Pn),E!==null&&x&&Vl(E,this),a!==null&&(this.qn||a.complete===!0?(a.hn&&(a.ln instanceof Event&&this.Hd!==null?this.Hd(this,a.ln):a.sq===!0&&!a.ln&&this.Zg!==null&&a.eu&&this.Zg(this,a.eu)),a.sq=!0,this.desiredSize.w()||(Ys(this,!1),this.v())):x&&LS(this,a)),this.g("element",y,a),this.N()}}},source:{get:function(){return this.qo},set:function(a){var y=this.qo;if(y!==a){this.Uc=!0,this.qo=a;var x=Eg;if(Es){var E=null;if(x[a]!==void 0)E=x[a];else if(a!==""){30<Hm&&(bg(),x=Eg),E=Rn("img"),E.hn=!0,LS(this,E);var b=this.rl;b!==null&&(E.crossOrigin=b(this)),E.src=a,x[a]=E,Hm++}this.element=E,E!==null&&E.__goCache===void 0&&(E.__goCache=new MS),this.v(),this.N()}this.g("source",y,a)}}},sourceCrossOrigin:{get:function(){return this.rl},set:function(a){if(this.rl!==a&&(this.rl=a,this.element!==null)){var y=this.element.getAttribute("src");a===null&&typeof y=="string"?this.element.crossOrigin=null:a!==null&&(this.element.crossOrigin=a(this)),this.element.src=y}}},sourceRect:{get:function(){return this.Xg},set:function(a){var y=this.Xg;y.D(a)||(this.Xg=a=a.J(),this.N(),this.g("sourceRect",y,a))}},imageStretch:{get:function(){return this.Nk},set:function(a){var y=this.Nk;y!==a&&(this.Nk=a,this.N(),this.g("imageStretch",y,a))}},flip:{get:function(){return this.Xf},set:function(a){var y=this.Xf;y!==a&&(this.Xf=a,this.N(),this.g("flip",y,a))}},imageAlignment:{get:function(){return this.Mk},set:function(a){var y=this.Mk;y.D(a)||(this.Mk=a=a.J(),this.N(),this.g("imageAlignment",y,a))}},errorFunction:{get:function(){return this.Hd},set:function(a){var y=this.Hd;y!==a&&(this.Hd=a,this.g("errorFunction",y,a))}},successFunction:{get:function(){return this.Zg},set:function(a){var y=this.Zg;y!==a&&(this.Zg=a,this.g("successFunction",y,a))}},naturalBounds:{get:function(){return this.dc}}}),Iu.prototype.redraw=Iu.prototype.redraw,Iu.prototype.reloadSource=Iu.prototype.hA;var Hm=0,xx=4;Iu.className="Picture",Eg=new Er,Iu.clearCache=bg;function MS(){this.gi=null}function kS(a,y,x,E,b){a.gi===null&&(a.gi=[]);var z=new Zh(null),ee=z.context,re=1/y;z.width=x/y,z.height=E/y,z.width!==0&&z.height!==0&&(y=new FS(z.Oa,y),x=1,0<a.gi.length&&(x=a.gi[a.gi.length-1],b=x.source,x=x.ratio),ee.setTransform(re*x,0,0,re*x,0,0),ee.yc(),ee.drawImage(b,0,0),a.gi.push(y))}MS.className="PictureCacheArray";function FS(a,y){this.source=a,this.ratio=y}FS.className="PictureCacheInstance";function Lg(){this.os=new Bn,this.mc=null}Lg.prototype.reset=function(a){a!==null?(a.ka(),this.os=a,a.figures.clear()):this.os=new Bn,this.mc=null};function Mg(a,y,x,E,b,z){a.mc=new Ns,a.mc.startX=y,a.mc.startY=x,a.mc.isFilled=E,a.mc.isEvenOdd=z||!1,a.os.figures.add(a.mc),b!==void 0&&(a.mc.isShadowed=b)}function wx(a){var y=a.mc.segments.length;0<y&&a.mc.segments.M(y-1).close()}Lg.prototype.moveTo=function(a,y,x){x===void 0&&(x=!1);var E=new to(xs);E.endX=a,E.endY=y,x&&E.close(),this.mc.segments.add(E)},Lg.prototype.lineTo=function(a,y,x){x===void 0&&(x=!1);var E=new to(fi);E.endX=a,E.endY=y,x&&E.close(),this.mc.segments.add(E)};function Pd(a,y,x,E,b,z,ee){var re;re===void 0&&(re=!1);var oe=new to(po);oe.point1X=y,oe.point1Y=x,oe.point2X=E,oe.point2Y=b,oe.endX=z,oe.endY=ee,re&&oe.close(),a.mc.segments.add(oe)}function Gm(a,y,x,E,b){var z;z===void 0&&(z=!1);var ee=new to(Vo);ee.point1X=y,ee.point1Y=x,ee.endX=E,ee.endY=b,z&&ee.close(),a.mc.segments.add(ee)}Lg.prototype.arcTo=function(a,y,x,E,b,z,ee){z===void 0&&(z=0),ee===void 0&&(ee=!1);var re=new to(qo);re.startAngle=a,re.sweepAngle=y,re.centerX=x,re.centerY=E,re.radiusX=b,re.radiusY=z!==0?z:b,ee&&re.close(),this.mc.segments.add(re)};function Px(a,y,x,E,b,z,ee,re){var oe;oe===void 0&&(oe=!1),y=new to(Ja,ee,re,y,x,E,b,z),oe&&y.close(),a.mc.segments.add(y)}function AS(a){var y=Km;return y!==null?(Km=null,y.reset(a),y):(y=new Lg,y.reset(a),y)}var Km=null;Lg.className="StreamGeometryContext";function eu(a,y){var x=a.toLowerCase(),E=yt.Ze;E[a]=y,E[x]=a}eu("Rectangle",function(a,y,x){a="r"+y+","+x;var E=yt.Mf[a];return E!==void 0||(E=new Bn(Bn.u),E.endX=y,E.endY=x,yt.Nf<yt.vm&&(yt.Mf[a]=E,yt.Nf++)),E}),eu("Square",function(a,y,x){a="s"+y+","+x;var E=yt.Mf[a];return E!==void 0||(E=new Bn(Bn.u),E.endX=y,E.endY=x,E.defaultStretch=xi,yt.Nf<yt.vm&&(yt.Mf[a]=E,yt.Nf++)),E}),eu("RoundedRectangle",function(a,y,x){a=a?a.parameter1:NaN,(isNaN(a)||0>a)&&(a=5),a=Math.min(a,y/3),a=Math.min(a,x/3);var E="rr"+y+","+x+","+a,b=yt.Mf[E];if(b!==void 0)return b;var z=a*yt.wg;return b=new Bn().add(new Ns(a,0,!0).add(new to(fi,y-a,0)).add(new to(po,y,a,y-z,0,y,z)).add(new to(fi,y,x-a)).add(new to(po,y-a,x,y,x-z,y-z,x)).add(new to(fi,a,x)).add(new to(po,0,x-a,z,x,0,x-z)).add(new to(fi,0,a)).add(new to(po,a,0,0,z,z,0).close())),1<z&&(b.spot1=new Bi(0,0,z,z),b.spot2=new Bi(1,1,-z,-z)),yt.Nf<yt.vm&&(yt.Mf[E]=b,yt.Nf++),b}),eu("Border","RoundedRectangle"),eu("Ellipse",function(a,y,x){a="e"+y+","+x;var E=yt.Mf[a];return E!==void 0||(E=new Bn(Bn.F),E.endX=y,E.endY=x,E.spot1=hh,E.spot2=al,yt.Nf<yt.vm&&(yt.Mf[a]=E,yt.Nf++)),E}),eu("Circle",function(a,y,x){a="c"+y+","+x;var E=yt.Mf[a];return E!==void 0||(E=new Bn(Bn.F),E.endX=y,E.endY=x,E.spot1=hh,E.spot2=al,E.defaultStretch=xi,yt.Nf<yt.vm&&(yt.Mf[a]=E,yt.Nf++)),E}),eu("TriangleRight",function(a,y,x){return new Bn().add(new Ns(0,0).add(new to(fi,y,.5*x)).add(new to(fi,0,x).close())).pm(0,.25,.5,.75)}),eu("TriangleDown",function(a,y,x){return new Bn().add(new Ns(0,0).add(new to(fi,y,0)).add(new to(fi,.5*y,x).close())).pm(.25,0,.75,.5)}),eu("TriangleLeft",function(a,y,x){return new Bn().add(new Ns(y,x).add(new to(fi,0,.5*x)).add(new to(fi,y,0).close())).pm(.5,.25,1,.75)}),eu("TriangleUp",function(a,y,x){return new Bn().add(new Ns(y,x).add(new to(fi,0,x)).add(new to(fi,.5*y,0).close())).pm(.25,.5,.75,1)}),eu("Triangle","TriangleUp"),eu("Diamond",function(a,y,x){return new Bn().add(new Ns(.5*y,0).add(new to(fi,0,.5*x)).add(new to(fi,.5*y,x)).add(new to(fi,y,.5*x).close())).pm(.25,.25,.75,.75)}),eu("LineH",function(a,y,x){return a=new Bn(Bn.j),a.startX=0,a.startY=x/2,a.endX=y,a.endY=x/2,a}),eu("LineV",function(a,y,x){return a=new Bn(Bn.j),a.startX=y/2,a.startY=0,a.endX=y/2,a.endY=x,a}),eu("None","Rectangle"),eu("BarH","Rectangle"),eu("BarV","Rectangle"),eu("MinusLine","LineH"),eu("PlusLine",function(a,y,x){return new Bn().add(new Ns(0,x/2,!1).add(new to(fi,y,x/2)).add(new to(xs,y/2,0)).add(new to(fi,y/2,x)))}),eu("XLine",function(a,y,x){return new Bn().add(new Ns(0,x,!1).add(new to(fi,y,0)).add(new to(xs,0,0)).add(new to(fi,y,x)))}),eu("LineRight",function(a,y,x){return new Bn().add(new Ns(.25*y,0,!1).add(new to(fi,.75*y,.5*x)).add(new to(fi,.25*y,x)))}),eu("LineDown",function(a,y,x){return new Bn().add(new Ns(0,.25*x,!1).add(new to(fi,.5*y,.75*x)).add(new to(fi,y,.25*x)))}),eu("LineLeft",function(a,y,x){return new Bn().add(new Ns(.75*y,0,!1).add(new to(fi,.25*y,.5*x)).add(new to(fi,.75*y,x)))}),eu("LineUp",function(a,y,x){return new Bn().add(new Ns(0,.75*x,!1).add(new to(fi,.5*y,.25*x)).add(new to(fi,y,.75*x)))}),yt.um={"":"",Standard:"F1 m 0,0 l 8,4 -8,4 2,-4 z",Backward:"F1 m 8,0 l -2,4 2,4 -8,-4 z",Triangle:"F1 m 0,0 l 8,4.62 -8,4.62 z",BackwardTriangle:"F1 m 8,4 l 0,4 -8,-4 8,-4 0,4 z",Boomerang:"F1 m 0,0 l 8,4 -8,4 4,-4 -4,-4 z",BackwardBoomerang:"F1 m 8,0 l -8,4 8,4 -4,-4 4,-4 z",SidewaysV:"m 0,0 l 8,4 -8,4 0,-1 6,-3 -6,-3 0,-1 z",BackwardV:"m 8,0 l -8,4 8,4 0,-1 -6,-3 6,-3 0,-1 z",OpenTriangle:"m 0,0 l 8,4 -8,4",BackwardOpenTriangle:"m 8,0 l -8,4 8,4",OpenTriangleLine:"m 0,0 l 8,4 -8,4 m 8.5,0 l 0,-8",BackwardOpenTriangleLine:"m 8,0 l -8,4 8,4 m -8.5,0 l 0,-8",OpenTriangleTop:"m 0,0 l 8,4 m 0,4",BackwardOpenTriangleTop:"m 8,0 l -8,4 m 0,4",OpenTriangleBottom:"m 0,8 l 8,-4",BackwardOpenTriangleBottom:"m 0,4 l 8,4",HalfTriangleTop:"F1 m 0,0 l 0,4 8,0 z m 0,8",BackwardHalfTriangleTop:"F1 m 8,0 l 0,4 -8,0 z m 0,8",HalfTriangleBottom:"F1 m 0,4 l 0,4 8,-4 z",BackwardHalfTriangleBottom:"F1 m 8,4 l 0,4 -8,-4 z",ForwardSemiCircle:"m 4,0 b 270 180 0 4 4",BackwardSemiCircle:"m 4,8 b 90 180 0 -4 4",Feather:"m 0,0 l 3,4 -3,4",BackwardFeather:"m 3,0 l -3,4 3,4",DoubleFeathers:"m 0,0 l 3,4 -3,4 m 3,-8 l 3,4 -3,4",BackwardDoubleFeathers:"m 3,0 l -3,4 3,4 m 3,-8 l -3,4 3,4",TripleFeathers:"m 0,0 l 3,4 -3,4 m 3,-8 l 3,4 -3,4 m 3,-8 l 3,4 -3,4",BackwardTripleFeathers:"m 3,0 l -3,4 3,4 m 3,-8 l -3,4 3,4 m 3,-8 l -3,4 3,4",ForwardSlash:"m 0,8 l 5,-8",BackSlash:"m 0,0 l 5,8",DoubleForwardSlash:"m 0,8 l 4,-8 m -2,8 l 4,-8",DoubleBackSlash:"m 0,0 l 4,8 m -2,-8 l 4,8",TripleForwardSlash:"m 0,8 l 4,-8 m -2,8 l 4,-8 m -2,8 l 4,-8",TripleBackSlash:"m 0,0 l 4,8 m -2,-8 l 4,8 m -2,-8 l 4,8",Fork:"m 0,4 l 8,0 m -8,0 l 8,-4 m -8,4 l 8,4",BackwardFork:"m 8,4 l -8,0 m 8,0 l -8,-4 m 8,4 l -8,4",LineFork:"m 0,0 l 0,8 m 0,-4 l 8,0 m -8,0 l 8,-4 m -8,4 l 8,4",BackwardLineFork:"m 8,4 l -8,0 m 8,0 l -8,-4 m 8,4 l -8,4 m 8,-8 l 0,8",CircleFork:"F1 m 6,4 b 0 360 -3 0 3 z m 0,0 l 6,0 m -6,0 l 6,-4 m -6,4 l 6,4",BackwardCircleFork:"F1 m 0,4 l 6,0 m -6,-4 l 6,4 m -6,4 l 6,-4 m 6,0 b 0 360 -3 0 3",CircleLineFork:"F1 m 6,4 b 0 360 -3 0 3 z m 1,-4 l 0,8 m 0,-4 l 6,0 m -6,0 l 6,-4 m -6,4 l 6,4",BackwardCircleLineFork:"F1 m 0,4 l 6,0 m -6,-4 l 6,4 m -6,4 l 6,-4 m 0,-4 l 0,8 m 7,-4 b 0 360 -3 0 3",Circle:"F1 m 8,4 b 0 360 -4 0 4 z",Block:"F1 m 0,0 l 0,8 8,0 0,-8 z",StretchedDiamond:"F1 m 0,3 l 5,-3 5,3 -5,3 -5,-3 z",Diamond:"F1 m 0,4 l 4,-4 4,4 -4,4 -4,-4 z",Chevron:"F1 m 0,0 l 5,0 3,4 -3,4 -5,0 3,-4 -3,-4 z",StretchedChevron:"F1 m 0,0 l 8,0 3,4 -3,4 -8,0 3,-4 -3,-4 z",NormalArrow:"F1 m 0,2 l 4,0 0,-2 4,4 -4,4 0,-2 -4,0 z",X:"m 0,0 l 8,8 m 0,-8 l -8,8",TailedNormalArrow:"F1 m 0,0 l 2,0 1,2 3,0 0,-2 2,4 -2,4 0,-2 -3,0 -1,2 -2,0 1,-4 -1,-4 z",DoubleTriangle:"F1 m 0,0 l 4,4 -4,4 0,-8 z m 4,0 l 4,4 -4,4 0,-8 z",BigEndArrow:"F1 m 0,0 l 5,2 0,-2 3,4 -3,4 0,-2 -5,2 0,-8 z",ConcaveTailArrow:"F1 m 0,2 h 4 v -2 l 4,4 -4,4 v -2 h -4 l 2,-2 -2,-2 z",RoundedTriangle:"F1 m 0,1 a 1,1 0 0 1 1,-1 l 7,3 a 0.5,1 0 0 1 0,2 l -7,3 a 1,1 0 0 1 -1,-1 l 0,-6 z",SimpleArrow:"F1 m 1,2 l -1,-2 2,0 1,2 -1,2 -2,0 1,-2 5,0 0,-2 2,2 -2,2 0,-2 z",AccelerationArrow:"F1 m 0,0 l 0,8 0.2,0 0,-8 -0.2,0 z m 2,0 l 0,8 1,0 0,-8 -1,0 z m 3,0 l 2,0 2,4 -2,4 -2,0 0,-8 z",BoxArrow:"F1 m 0,0 l 4,0 0,2 2,0 0,-2 2,4 -2,4 0,-2 -2,0 0,2 -4,0 0,-8 z",TriangleLine:"F1 m 8,4 l -8,-4 0,8 8,-4 z m 0.5,4 l 0,-8",CircleEndedArrow:"F1 m 10,4 l -2,-3 0,2 -2,0 0,2 2,0 0,2 2,-3 z m -4,0 b 0 360 -3 0 3 z",DynamicWidthArrow:"F1 m 0,3 l 2,0 2,-1 2,-2 2,4 -2,4 -2,-2 -2,-1 -2,0 0,-2 z",EquilibriumArrow:"m 0,3 l 8,0 -3,-3 m 3,5 l -8,0 3,3",FastForward:"F1 m 0,0 l 3.5,4 0,-4 3.5,4 0,-4 1,0 0,8 -1,0 0,-4 -3.5,4 0,-4 -3.5,4 0,-8 z",Kite:"F1 m 0,4 l 2,-4 6,4 -6,4 -2,-4 z",HalfArrowTop:"F1 m 0,0 l 4,4 4,0 -8,-4 z m 0,8",HalfArrowBottom:"F1 m 0,8 l 4,-4 4,0 -8,4 z",OpposingDirectionDoubleArrow:"F1 m 0,4 l 2,-4 0,2 4,0 0,-2 2,4 -2,4 0,-2 -4,0 0,2 -2,-4 z",PartialDoubleTriangle:"F1 m 0,0 4,3 0,-3 4,4 -4,4 0,-3 -4,3 0,-8 z",LineCircle:"F1 m 0,0 l 0,8 m 7 -4 b 0 360 -3 0 3 z",DoubleLineCircle:"F1 m 0,0 l 0,8 m 2,-8 l 0,8 m 7 -4 b 0 360 -3 0 3 z",TripleLineCircle:"F1 m 0,0 l 0,8 m 2,-8 l 0,8 m 2,-8 l 0,8 m 7 -4 b 0 360 -3 0 3 z",CircleLine:"F1 m 6 4 b 0 360 -3 0 3 z m 1,-4 l 0,8",DiamondCircle:"F1 m 8,4 l -4,4 -4,-4 4,-4 4,4 m 8,0 b 0 360 -4 0 4 z",PlusCircle:"F1 m 8,4 b 0 360 -4 0 4 l -8 0 z m -4 -4 l 0 8",OpenRightTriangleTop:"m 8,0 l 0,4 -8,0 m 0,4",OpenRightTriangleBottom:"m 8,8 l 0,-4 -8,0",Line:"m 0,0 l 0,8",DoubleLine:"m 0,0 l 0,8 m 2,0 l 0,-8",TripleLine:"m 0,0 l 0,8 m 2,0 l 0,-8 m 2,0 l 0,8",PentagonArrow:"F1 m 8,4 l -4,-4 -4,0 0,8 4,0 4,-4 z"};function B0(){this.nc=!1,this.tr=this.Kp=this.zq=null,this.vr="",this.fr=this.oq=this.ur=null,this.hr="",this.gr=el,this.ir=null,this.jr="",this.lr=vs,this.Gq="",this.Hq=Cs,this.Pq=Ul,this.Kq=Zl,this.Up=null,this.Cq=127,this.zr=rl,this.yr="gray",this.Vg=4}B0.prototype.copy=function(){var a=new B0;return a.zq=this.zq,a.Kp=this.Kp,a.tr=this.tr,a.vr=this.vr,a.ur=this.ur,a.oq=this.oq,a.fr=this.fr,a.hr=this.hr,a.gr=this.gr.J(),a.ir=this.ir,a.jr=this.jr,a.lr=this.lr.J(),a.Gq=this.Gq,a.Hq=this.Hq.J(),a.Pq=this.Pq.J(),a.Kq=this.Kq.J(),a.Up=this.Up,a.Cq=this.Cq,a.zr=this.zr.J(),a.yr=this.yr,a.Vg=this.Vg,a};function Ii(a,y){a===void 0||a instanceof qs||typeof a=="string"?Ln.call(this,a):(Ln.call(this),a&&(y=a)),this.G=2408959,this.Tf="",this.P=null,this.Jg="",this.Qf=this.Ug=null,this.ec="",this.Ah=this.Ig=null,this.ke=new Qe(NaN,NaN).freeze(),this.nf=null,this.Ao=NaN,this.vw=-1,this.py=new Xt,this.Rh=null,this.ag=NaN,y&&Object.assign(this,y)}Ct(Ii,Ln),Ii.prototype.cloneProtected=function(a){Ln.prototype.cloneProtected.call(this,a),a.G=this.G&-4097|49152,a.Tf=this.Tf,this.P!==null&&(a.P=this.P.nc?this.P:this.P.copy()),a.Jg=this.Jg,a.Qf=null,a.ec=this.ec,a.ke.assign(this.ke),a.Ao=this.Ao},we=Ii.prototype,we.Af=function(a){Ln.prototype.Af.call(this,a),a.oh(),a.Ug=null,a.nf=null,a.Rh=null},we.toString=function(){var a=cr(this.constructor)+"#"+qa(this);return this.data!==null&&(a+="("+Co(this.data)+")"),a};function ju(a){a.P===null?a.P=new B0:a.P.nc&&(a.P=a.P.copy())}we.th=function(){Ln.prototype.th.call(this),this.P!==null&&(this.P.nc=!0)},we.gk=function(a,y,x,E,b,z,ee){var re=this.diagram;re!==null&&(a===ts&&y==="elements"?b instanceof Ln?Sf(b,function(oe){sy(re.partManager,oe),su(re,oe)}):Vl(re,b):a===ss&&y==="elements"&&(b instanceof Ln?Sf(b,function(oe){ly(re.partManager,oe,re)}):Mc(re,b)),re.cb(a,y,x,E,b,z,ee))},we.La=function(a){if(Ln.prototype.La.call(this,a),this.data!==null){for(var y=this.O.s,x=y.length,E=0;E<x;E++){var b=y[E];b instanceof Ln&&Sf(b,function(z){z.data!==null&&z.La()})}for(y=this.adornments;y.next();)y.value.La(a)}},Ii.prototype.updateRelationshipsFromData=function(){var a;this.data!==null&&((a=this.diagram)===null||a===void 0||a.partManager.updateRelationshipsFromData(this))},Ii.prototype.Pj=function(a){var y=this.Qf;return y===null?null:y.I(a)},Ii.prototype.bh=function(a,y){if(y!==null){var x=null,E=this.Qf;if(E!==null&&(x=E.I(a)),x!==y){if(x!==null){var b=x.diagram;b!==null&&b.remove(x)}E===null&&(this.Qf=E=new Li),y.Tf!==a&&(y.category=a),E.add(a,y),a=this.diagram,a!==null&&(a.add(y),a=y.adornedObject,a!==null&&(a=a.ih(),a!==null&&(y.data=a.data)))}}},Ii.prototype.Jf=function(a){var y=this.Qf;if(y!==null){var x=y.I(a);if(x!==null){var E=x.diagram;E!==null&&E.remove(x)}y.remove(a),y.count===0&&(this.Qf=null)}},Ii.prototype.Ej=function(){var a=this.Qf;if(a!==null){var y=qi();for(a=a.iterator;a.next();)y.push(a.key);a=y.length;for(var x=0;x<a;x++)this.Jf(y[x]);Zi(y)}},Ii.prototype.updateAdornments=function(){var a=this.diagram;if(a!==null){for(var y=this.adornments;y.next();){var x=y.value;x.v(),x.placeholder&&x.placeholder.v()}e:{if(this.isSelected&&this.selectionAdorned&&(y=this.selectionObject,y!==null&&this.actualBounds.w()&&this.isVisible()&&y.Ed()&&y.actualBounds.w())){if(x=this.Pj("Selection"),x===null){if(x=this.selectionAdornmentTemplate,x===null&&(x=this.ph()?a.linkSelectionAdornmentTemplate:this instanceof xr?a.groupSelectionAdornmentTemplate:a.nodeSelectionAdornmentTemplate),!(x instanceof Fo))break e;_h(x),x=x.copy(),x!==null&&(this.ph()&&this.selectionObject===this.path&&(x.type=Ln.Link),x.adornedObject=y)}if(x!==null){x.type===Ln.Link&&x.v(),this.bh("Selection",x);break e}}this.Jf("Selection")}for(Cx(this,a),y=this.adornments;y.next();)y.value.La()}},Ii.prototype.Wb=function(){var a=this.diagram;a!==null&&(a.vd=!0,!(this.G&16384)&&(this.G|=16384))};function O0(a){a.G&16384&&(a.updateAdornments(),a.G&=-16385)}function Cx(a,y){y.toolManager.mouseDownTools.each(function(x){x.isEnabled&&x.updateAdornments(a)}),y.toolManager.updateAdornments(a)}function Wm(a){if(Vd(a)===!1){I0(a,!0),a.Uk();var y=a.diagram;y!==null&&(y.De.add(a),y.$b())}}function NS(a){if(a.G|=2097152,Vd(a)!==!1){var y=a.position,x=a.location;x.w()&&y.w()||BS(a,y,x),x=a.Ib;var E=Xt.alloc().assign(x);x.ka(),x.x=y.x,x.y=y.y,x.freeze(),a.Xl(E,x),Xt.free(E),I0(a,!1)}}Ii.prototype.Ge=function(a,y,x,E){var b=this.uc;b.h(a,y,x,E),this.Lb===null&&(this.Lb=new kr);var z=this.Lb;z.reset(),this.no(z,a,y,x,E),this.Lb=z,z.ws()||z.pp(b)},Ii.prototype.no=function(a,y,x,E,b){if(this.Ca!==1&&a.scale(this.Ca),this.Kb!==0){var z=ko;this.locationSpot.sb()&&(z=this.locationSpot);var ee=Qe.alloc();if(this.locationObject!==this)for(y=this.locationObject,x=y.naturalBounds,ee.yi(x.x,x.y,x.width,x.height,z),y.Lb!==null&&y.Lb.Ga(ee),ee.offset(-y.measuredBounds.x,-y.measuredBounds.y),z=y.panel;z!==null&&z!==this;)z.Lb!==null&&z.Lb.Ga(ee),ee.offset(-z.measuredBounds.x,-z.measuredBounds.y),z=z.panel;else ee.yi(y,x,E,b,z);a.rotate(this.Kb,ee.x,ee.y),Qe.free(ee)}},Ii.prototype.move=function(a,y){y===!0?this.location=a:this.position=a},Ii.prototype.moveTo=function(a,y,x){a=Qe.allocAt(a,y),this.move(a,x),Qe.free(a)},Ii.prototype.isVisible=function(){if(!this.visible)return!1;var a=this.layer;if(a!==null){if(!a.visible)return!1;if(a=a.diagram,a!==null&&a.animationManager.fv(this))return!0}return a=this.containingGroup,!!(a===null||a.isSubGraphExpanded&&a.isVisible())},Ii.prototype.Zb=function(a){var y=this.diagram;a?(this.C(4),this.Wb(),y!==null&&y.De.add(this)):(this.C(8),this.Ej()),this.oh(),y!==null&&(y.Ya(),y.N())},Ii.prototype.fb=function(a){if(this.name===a)return this;var y=this.Rh;if(y===null&&(this.Rh=y=new Li),y.I(a)!==null)return y.I(a);var x=Ln.prototype.fb.call(this,a);return x!==null?(y.set(a,x),x):(y.set(a,null),null)};function Cd(a,y,x,E){E===void 0&&(E=new Qe),x=x.Mc()?ko:x;var b=y.naturalBounds;if(E.h(b.width*x.x+x.offsetX,b.height*x.y+x.offsetY),y===null||y===a)return E;for(y.transform.Ga(E),y=y.panel;y!==null&&y!==a;)y.transform.Ga(E),y=y.panel;return a.Lb!==null&&a.Lb.Ga(E),E.offset(-a.uc.x,-a.uc.y),E}Ii.prototype.mi=function(a){return a===void 0&&(a=new Xt),a.assign(this.actualBounds)},Ii.prototype.Va=function(){this.measure(1/0,1/0),this.arrange()};function TS(a){var y=Qe.alloc(),x=a.locationObject,E=x.naturalBounds,b=x instanceof Dr?x.strokeWidth:0;if(y.yi(0,0,E.width+b,E.height+b,a.locationSpot),x!==a)for(y.offset(-b/2,-b/2),x.transform.Ga(y),x=x.panel;x!==null&&x!==a;)x.transform.Ga(y),x=x.panel;return a.Lb!==null&&a.Lb.Ga(y),y.offset(-a.uc.x,-a.uc.y),y}function Pf(a,y){var x=a.py;isNaN(a.ag)&&(a.ag=uS(a));var E=a.ag,b=2*E;if(!a.isShadowed)return x.h(y.x-1-E,y.y-1-E,y.width+2+b,y.height+2+b),x;E=y.x,b=y.y;var z=y.width;y=y.height;var ee=a.shadowBlur;return a=a.shadowOffset,z+=ee,y+=ee,E-=ee/2,b-=ee/2,0<a.x?z+=a.x:(E+=a.x,z-=a.x),0<a.y?y+=a.y:(b+=a.y,y-=a.y),x.h(E-1,b-1,z+2,y+2),x}Ii.prototype.arrange=function(){if(Su(this)===!1)NS(this);else{Hc(this,!1);var a=this.Ib,y=Xt.alloc();y.assign(a);var x=Ud(this);this.eh(0,0,this.uc.width,this.uc.height);var E=this.position;BS(this,E,this.location),a.ka(),a.x=E.x,a.y=E.y,a.freeze(),this.Xl(y,a),y.D(a)?this.Fd(x):!this.Zc()||yt.B(y.width,a.width)&&yt.B(y.height,a.height)||0<=this.vw&&this.C(16),Xt.free(y),I0(this,!1)}},we=Ii.prototype,we.Xl=function(a,y){var x=this.diagram;if(x!==null){var E=!1;if(x.Zi===!1&&a.w()){var b=Xt.alloc();b.assign(x.documentBounds),b.Fv(x.padding),a.x>b.x&&a.y>b.y&&a.right<b.right&&a.bottom<b.bottom&&y.x>b.x&&y.y>b.y&&y.right<b.right&&y.bottom<b.bottom&&(E=!0),Xt.free(b)}!(this.G&65536)&&a.D(y)||IS(this,E,x),x.N(),!a.w()&&!y.w()||As(a,y)||(this instanceof qn&&!x.undoManager.isUndoingRedoing&&this.Bd(),this.oh())}},we.zv=function(a,y,x){if(this.ph()||!a.w())return!1;var E=this.diagram;return E!==null&&DS(this,E,a,y,x),this.pa=a,this.G&=-2097153,!this.ke.w()||E!==null&&!E.animationManager.isTicking&&E.undoManager.isUndoingRedoing||(E=this.ke,this.ke=new Qe(E.x+(a.x-y),E.y+(a.y-x)),this.g("location",E,this.ke.copy())),Vd(this)===!1&&Su(this)===!1&&(Wm(this),NS(this)),!0};function DS(a,y,x,E,b){y===null||a instanceof Fo||(y=y.animationManager,y.zb&&ur(y,a,new Qe(E,b),x))}we.mm=function(a,y,x){var E=this.ke,b=this.pa;if(x){if(E.x===a&&E.y===y)return;Vd(this)||Su(this)?b.h(NaN,NaN):b.h(b.x+a-E.x,b.y+y-E.y),E.h(a,y)}else{if(b.x===a&&b.y===y)return;E.h(E.x+a-b.x,E.y+y-b.y),b.h(a,y)}Wm(this)},we.Av=function(){this.G&=-2097153,Wm(this)};function BS(a,y,x){var E=TS(a),b=a.diagram,z=x.w(),ee=y.w();z&&ee?a.G&2097152?OS(a,y,x,b,E):RS(a,y,x,b,E):z?OS(a,y,x,b,E):ee&&RS(a,y,x,b,E),a.G|=2097152,Qe.free(E),a.Uk()}function OS(a,y,x,E,b){var z=y.x,ee=y.y;y.h(x.x-b.x,x.y-b.y),E!==null&&(x=E.animationManager,(E=x.defaultAnimation.isAnimating)||!x.zb||a instanceof Fo||ur(x,a,new Qe(z,ee),y),E||y.x===z&&y.y===ee||a.g("position",new Qe(z,ee),y.copy()))}function RS(a,y,x,E,b){var z=x.copy();x.h(y.x+b.x,y.y+b.y),x.D(z)||E===null||a.g("location",z,x.copy())}function IS(a,y,x){j0(a,!1),a instanceof qn&&md(x,a),a.layer.isTemporary||y||x.Ya(),y=a.Ib;var E=x.viewportBounds;E.w()?Ud(a)?(Xu(y,E)||a.Fd(!1),a.updateAdornments()):a.isVisible()&&y.Yc(E)?(a.Fd(!0),a.updateAdornments()):a.Wb():x.vd=!0}we.si=function(){return!0},we.Zc=function(){return!0},we.ph=function(){return!1},we.Dd=function(){return!0};function R0(a,y,x,E){y.constructor===a.constructor||HS||(HS=!0,eo('Should not change the class of the Part when changing category from "'+x+'" to "'+E+'"'),eo(" Old class: "+cr(a.constructor)+", new class: "+cr(y.constructor)+", part: "+a.toString())),a.Ej();var b=a.data;x=a.layerName;var z=a.isSelected,ee=a.isHighlighted,re=!0,oe=!0,se=!1;a instanceof qn&&(re=a.isTreeLeaf,oe=a.isTreeExpanded,se=a.wasTreeExpanded),y.Af(a),y.cloneProtected(a),a.Tf=E,a.svg!==null&&(a.svg.remove(),a.svg=null,a.Uc=!0),a.v(),a.N(),y=a.diagram,E=!0,y!==null&&(E=y.skipsUndoManager,y.skipsUndoManager=!0),a.ub=b,a.G=z?a.G|4096:a.G&-4097,a.G=ee?a.G|524288:a.G&-524289,a instanceof qn&&(a.U=re?a.U|4:a.U&-5,a.U=oe?a.U|1:a.U&-2,a.U=se?a.U|2:a.U&-3),b!==null&&a.La(),b=a.layerName,b!==x&&(a.Jg=x,a.layerName=b),y!==null&&(y.skipsUndoManager=E),a.Zc()&&a.C(64)}Ii.prototype.canCopy=function(){if(!this.copyable)return!1;var a=this.layer;return a===null?!0:a.allowCopy?(a=a.diagram,a===null?!0:!!a.allowCopy):!1},Ii.prototype.canDelete=function(){if(!this.deletable)return!1;var a=this.layer;return a===null?!0:a.allowDelete?(a=a.diagram,a===null?!0:!!a.allowDelete):!1},Ii.prototype.canEdit=function(){if(!this.textEditable)return!1;var a=this.layer;return a===null?!0:a.allowTextEdit?(a=a.diagram,a===null?!0:!!a.allowTextEdit):!1},Ii.prototype.canGroup=function(){if(!this.groupable)return!1;var a=this.layer;return a===null?!0:a.allowGroup?(a=a.diagram,a===null?!0:!!a.allowGroup):!1},Ii.prototype.canMove=function(){if(!this.movable)return!1;var a=this.layer;return a===null?!0:a.allowMove?(a=a.diagram,a===null?!0:!!a.allowMove):!1},Ii.prototype.canReshape=function(){if(!this.reshapable)return!1;var a=this.layer;return a===null?!0:a.allowReshape?(a=a.diagram,a===null?!0:!!a.allowReshape):!1},Ii.prototype.canResize=function(){if(!this.resizable)return!1;var a=this.layer;return a===null?!0:a.allowResize?(a=a.diagram,a===null?!0:!!a.allowResize):!1},Ii.prototype.canRotate=function(){if(!this.rotatable)return!1;var a=this.layer;return a===null?!0:a.allowRotate?(a=a.diagram,a===null?!0:!!a.allowRotate):!1},Ii.prototype.canSelect=function(){if(!this.selectable)return!1;var a=this.layer;return a===null?!0:a.allowSelect?(a=a.diagram,a===null?!0:!!a.allowSelect):!1};function Vd(a){return(a.G&32768)!==0}function I0(a,y){a.G=y?a.G|32768:a.G&-32769}function j0(a,y){a.G=y?a.G|65536:a.G&-65537}function Ud(a){return(a.G&131072)!==0}we=Ii.prototype,we.Fd=function(a){this.G=a?this.G|131072:this.G&-131073};function Vm(a,y){a.G=y?a.G|1048576:a.G&-1048577}we.oh=function(){var a=this.containingGroup;a!==null&&(a.v(),a.placeholder!==null&&a.placeholder.v(),a.Bd())},we.N=function(){var a=this.diagram;a!==null&&!Su(this)&&!Vd(this)&&this.isVisible()&&this.Ib.w()&&a.N(Pf(this,this.Ib))},we.v=function(){Ln.prototype.v.call(this);var a=this.diagram;a!==null&&(a.De.add(this),this instanceof qn&&this.labeledLink!==null&&yu(this.labeledLink),a.$b(!0))},we.Vo=function(a){a||(a=this.Ah,a!==null&&V0(a,this))},we.Wo=function(a){a||(a=this.Ah,a!==null&&U0(a,this))},we.Lj=function(){var a=this.data;if(a!==null){var y=this.diagram;y!==null&&(y=y.model,y!==null&&y.cm(a))}},we.oz=function(){return z0(this,this)};function z0(a,y){var x=y.containingGroup;return x!==null?1+z0(a,x):y instanceof qn&&(y=y.labeledLink,y!==null)?z0(a,y):0}we.sz=function(){return jS(this,this)};function jS(a,y){var x=y.containingGroup;return x!==null||y instanceof qn&&(x=y.labeledLink,x!==null)?jS(a,x):y}we.Td=function(a){return a instanceof xr?H0(this,this,a):!1};function H0(a,y,x){if(y===x||x===null)return!1;var E=y.containingGroup;return E===null||E!==x&&!H0(a,E,x)?y instanceof qn&&(y=y.labeledLink,y!==null)?H0(a,y,x):!1:!0}we.px=function(a){if(a===null)return null;if(this===a)return this.containingGroup;for(var y=this;y!==null;){if(y instanceof xr&&Vm(y,!0),y instanceof qn){var x=y.labeledLink;x!==null&&(y=x)}y=y.containingGroup}for(x=null,y=a;y!==null;){if(y.G&1048576){x=y;break}y instanceof qn&&(a=y.labeledLink,a!==null&&(y=a)),y=y.containingGroup}for(y=this;y!==null;)y instanceof xr&&Vm(y,!1),y instanceof qn&&(a=y.labeledLink,a!==null&&(y=a)),y=y.containingGroup;return x},Ii.prototype.canLayout=function(){if(!this.isLayoutPositioned||!this.isVisible())return!1;var a=this.layer;return!(a!==null&&a.isTemporary||this instanceof qn&&this.isLinkLabel)},Ii.prototype.C=function(a){if(a===void 0&&(a=16777215),this.isLayoutPositioned&&a&this.layoutConditions){var y=this.layer;y!==null&&y.isTemporary||this instanceof qn&&this.isLinkLabel?y=!1:(y=this.diagram,y=!(y!==null&&y.undoManager.isUndoingRedoing))}else y=!1;if(y)if(y=this.Ah,y!==null){var x=y.layout;x!==null?x.C():y.C(a)}else a=this.diagram,a!==null&&(a=a.layout,a!==null&&a.C())};function zS(a){return a.isVisible()?(a=a.layer,!(a!==null&&a.isTemporary)):!1}function Zd(a,y,x,E,b,z){if(z===void 0&&(z=null),!(a.contains(y)||z!==null&&!z(y)||y instanceof Fo)){if(a.add(y),y instanceof qn){if(x&&y instanceof xr)for(var ee=y.memberParts;ee.next();)Zd(a,ee.value,x,E,b,z);if(b!==!1)for(ee=y.linksConnected;ee.next();){var re=ee.value;if(!a.contains(re)){var oe=re.fromNode,se=re.toNode;oe=oe===null||a.contains(oe),se=se===null||a.contains(se),(b?oe&&se:oe||se)&&Zd(a,re,x,E,b,z)}}if(1<E)for(y=y.Ou();y.next();)Zd(a,y.value,x,E-1,b,z)}else if(y instanceof Tn)for(y=y.labelNodes;y.next();)Zd(a,y.value,x,E,b,z)}}Yt.Object.defineProperties(Ii.prototype,{key:{get:function(){var a=this.diagram;if(a!==null)return a.model.wa(this.data)}},adornments:{get:function(){return this.Qf===null?ea:this.Qf.iteratorValues}},layer:{get:function(){return this.Ig}},diagram:{get:function(){var a=this.Ig;return a==null?null:a.diagram}},layerName:{get:function(){return this.Jg},set:function(a){var y=this.Jg;if(y!==a){var x=this.diagram;if((x===null||x.Qj(a)!==null&&!x.partManager.addsToTemporaryLayer)&&(this.Jg=a,x!==null&&x.Ya(),this.g("layerName",y,a),y=this.layer,y!==null&&y.name!==a&&(x=y.diagram,x!==null&&(a=x.Qj(a),a!==null&&a!==y)))){var E=y.pc(-1,this,!0);if(0<=E&&x.cb(ss,"parts",y,this,null,E,!0),E=a.oi(99999999,this,!0),y.visible!==a.visible&&this.Zb(a.visible),0<=E&&x.cb(ts,"parts",a,null,this,!0,E),E=this.layerChanged,E!==null){var b=x.aa;x.aa=!0,E(this,y,a),x.aa=b}}}}},layerChanged:{get:function(){return this.P!==null?this.P.zq:null},set:function(a){var y=this.layerChanged;y!==a&&(ju(this),this.P.zq=a,this.g("layerChanged",y,a))}},zOrder:{get:function(){return this.Ao},set:function(a){var y=this.Ao;if(y!==a){this.Ao=a;var x=this.layer;x!==null&&Ha(x,-1,this),this.g("zOrder",y,a),a=this.diagram,a!==null&&a.N()}}},locationObject:{get:function(){if(this.nf===null){var a=this.locationObjectName;a!==""?(a=this.fb(a),a!==null?this.nf=a:this.nf=this):this instanceof Fo?this.type!==Ln.Link&&this.placeholder!==null?this.nf=this.placeholder:this.nf=this:this.nf=this}return this.nf.visible?this.nf:this}},minLocation:{get:function(){return this.P!==null?this.P.Pq:Ul},set:function(a){var y=this.minLocation;y.D(a)||(a=a.J(),ju(this),this.P.Pq=a,this.g("minLocation",y,a))}},maxLocation:{get:function(){return this.P!==null?this.P.Kq:Zl},set:function(a){var y=this.maxLocation;y.D(a)||(a=a.J(),ju(this),this.P.Kq=a,this.g("maxLocation",y,a))}},locationObjectName:{get:function(){return this.P!==null?this.P.Gq:""},set:function(a){var y=this.locationObjectName;y!==a&&(ju(this),this.P.Gq=a,this.nf=null,this.v(),this.g("locationObjectName",y,a))}},locationSpot:{get:function(){return this.P!==null?this.P.Hq:Cs},set:function(a){var y=this.locationSpot;y.D(a)||(a=a.J(),ju(this),this.P.Hq=a,this.v(),this.g("locationSpot",y,a))}},location:{get:function(){return this.ke},set:function(a){var y=a.x,x=a.y,E=this.ke;if(!(E.x===y||isNaN(E.x)&&isNaN(y))||!(E.y===x||isNaN(E.y)&&isNaN(x))){if(a=a.copy(),y=a,this.ph())y=!1;else{if(this.ke=y,this.G|=2097152,Su(this)===!1&&(Wm(this),x=this.pa,x.w())){var b=this.diagram;if(b===null||b.animationManager.isTicking||!b.undoManager.isUndoingRedoing){var z=x.copy();x.h(x.x+(y.x-E.x),x.y+(y.y-E.y)),DS(this,b,x,z.x,z.y),this.g("position",z,x.copy())}}y=!0}y&&this.g("location",E,a.copy())}}},category:{get:function(){return this.Tf},set:function(a){var y=this.Tf;if(y!==a){this.svg!==null&&(this.svg.remove(),this.Uc=!0);var x=this.diagram,E=this.data,b=null;if(x!==null&&E!==null&&!(this instanceof Fo)){var z=x.model.undoManager;z.isEnabled&&!z.isUndoingRedoing&&(b=this.clone(),b.O.addAll(this.O))}this.Tf=a,this.g("category",y,a),x===null||E===null||this instanceof Fo?this instanceof Fo&&(b=this.adornedPart,b!==null&&(a=b.Qf,a!==null&&a.remove(y),b.bh(this.category,this))):(z=x.model,z.undoManager.isUndoingRedoing||(this.ph()?(x.partManager.setLinkCategoryForData(E,a),x=x.partManager.findLinkTemplateForCategory(a),x!==null&&(_h(x),x=x.copy(),x!==null&&R0(this,x,y,a))):(z!==null&&z.jm(E,a),x=c1(x.partManager,E,a),x!==null&&(_h(x),x=x.copy(),x===null||x instanceof Tn||(E=this.location.copy(),R0(this,x,y,a),this.location.w()||(this.location=E)))),b!==null&&(y=this.clone(),y.O.addAll(this.O),this.g("self",b,y))))}}},self:{get:function(){return this},set:function(a){R0(this,a,this.category,a.category)}},copyable:{get:function(){return(this.G&1)!==0},set:function(a){var y=(this.G&1)!==0;y!==a&&(this.G^=1,this.g("copyable",y,a))}},deletable:{get:function(){return(this.G&2)!==0},set:function(a){var y=(this.G&2)!==0;y!==a&&(this.G^=2,this.g("deletable",y,a))}},textEditable:{get:function(){return(this.G&4)!==0},set:function(a){var y=(this.G&4)!==0;y!==a&&(this.G^=4,this.g("textEditable",y,a),this.Wb())}},groupable:{get:function(){return(this.G&8)!==0},set:function(a){var y=(this.G&8)!==0;y!==a&&(this.G^=8,this.g("groupable",y,a))}},movable:{get:function(){return(this.G&16)!==0},set:function(a){var y=(this.G&16)!==0;y!==a&&(this.G^=16,this.g("movable",y,a))}},selectionAdorned:{get:function(){return(this.G&32)!==0},set:function(a){var y=(this.G&32)!==0;y!==a&&(this.G^=32,this.g("selectionAdorned",y,a),this.Wb())}},isInDocumentBounds:{get:function(){return(this.G&64)!==0},set:function(a){var y=(this.G&64)!==0;if(y!==a){this.G^=64;var x=this.diagram;x!==null&&x.Ya(),this.g("isInDocumentBounds",y,a)}}},isLayoutPositioned:{get:function(){return(this.G&128)!==0},set:function(a){var y=(this.G&128)!==0;y!==a&&(this.G^=128,this.g("isLayoutPositioned",y,a),this.C(a?4:8))}},selectable:{get:function(){return(this.G&256)!==0},set:function(a){var y=(this.G&256)!==0;y!==a&&(this.G^=256,this.g("selectable",y,a),this.Wb())}},reshapable:{get:function(){return(this.G&512)!==0},set:function(a){var y=(this.G&512)!==0;y!==a&&(this.G^=512,this.g("reshapable",y,a),this.Wb())}},resizable:{get:function(){return(this.G&1024)!==0},set:function(a){var y=(this.G&1024)!==0;y!==a&&(this.G^=1024,this.g("resizable",y,a),this.Wb())}},rotatable:{get:function(){return(this.G&2048)!==0},set:function(a){var y=(this.G&2048)!==0;y!==a&&(this.G^=2048,this.g("rotatable",y,a),this.Wb())}},isSelected:{get:function(){return(this.G&4096)!==0},set:function(a){var y=(this.G&4096)!==0;if(y!==a){var x=this.diagram;if(!a||this.canSelect()&&!(x!==null&&x.selection.count>=x.maxSelectionCount)){this.G^=4096;var E=!1;if(x!==null){E=x.skipsUndoManager,x.skipsUndoManager=!0;var b=x.selection;b.ka(),a?b.add(this):b.remove(this),b.freeze()}this.g("isSelected",y,a),this.Wb(),a=this.selectionChanged,a!==null&&a(this),x!==null&&(x.$b(),x.skipsUndoManager=E)}}}},isHighlighted:{get:function(){return(this.G&524288)!==0},set:function(a){var y=(this.G&524288)!==0;if(y!==a){this.G^=524288;var x=this.diagram;x!==null&&(x=x.highlighteds,x.ka(),a?x.add(this):x.remove(this),x.freeze()),this.g("isHighlighted",y,a),this.N(),a=this.highlightedChanged,a!==null&&a(this)}}},isShadowed:{get:function(){return(this.G&8192)!==0},set:function(a){var y=(this.G&8192)!==0;y!==a&&(this.G^=8192,this.Uc=!0,this.g("isShadowed",y,a),this.N())}},isAnimated:{get:function(){return(this.G&262144)!==0},set:function(a){var y=(this.G&262144)!==0;y!==a&&(this.G^=262144,this.g("isAnimated",y,a))}},highlightedChanged:{get:function(){return this.P!==null?this.P.oq:null},set:function(a){var y=this.highlightedChanged;y!==a&&(ju(this),this.P.oq=a,this.g("highlightedChanged",y,a))}},selectionObjectName:{get:function(){return this.P!==null?this.P.vr:""},set:function(a){var y=this.selectionObjectName;y!==a&&(ju(this),this.P.vr=a,this.Ug=null,this.g("selectionObjectName",y,a))}},selectionAdornmentTemplate:{get:function(){return this.P!==null?this.P.tr:null},set:function(a){var y=this.selectionAdornmentTemplate;y!==a&&(ju(this),this.P.tr=a,this.g("selectionAdornmentTemplate",y,a))}},selectionObject:{get:function(){if(this.Ug===null){var a=this.selectionObjectName;a!==null&&a!==""?(a=this.fb(a),a!==null?this.Ug=a:this.Ug=this):this instanceof Tn?(a=this.path,a!==null?this.Ug=a:this.Ug=this):this.Ug=this}return this.Ug}},selectionChanged:{get:function(){return this.P!==null?this.P.ur:null},set:function(a){var y=this.selectionChanged;y!==a&&(ju(this),this.P.ur=a,this.g("selectionChanged",y,a))}},resizeAdornmentTemplate:{get:function(){return this.P!==null?this.P.fr:null},set:function(a){var y=this.resizeAdornmentTemplate;y!==a&&(ju(this),this.P.fr=a,this.g("resizeAdornmentTemplate",y,a))}},resizeObjectName:{get:function(){return this.P!==null?this.P.hr:""},set:function(a){var y=this.resizeObjectName;y!==a&&(ju(this),this.P.hr=a,this.g("resizeObjectName",y,a))}},resizeObject:{get:function(){var a=this.resizeObjectName;return a!==""&&(a=this.fb(a),a!==null)?a:this}},resizeCellSize:{get:function(){return this.P!==null?this.P.gr:el},set:function(a){var y=this.resizeCellSize;y.D(a)||(a=a.J(),ju(this),this.P.gr=a,this.g("resizeCellSize",y,a))}},rotateAdornmentTemplate:{get:function(){return this.P!==null?this.P.ir:null},set:function(a){var y=this.rotateAdornmentTemplate;y!==a&&(ju(this),this.P.ir=a,this.g("rotateAdornmentTemplate",y,a))}},rotateObjectName:{get:function(){return this.P!==null?this.P.jr:""},set:function(a){var y=this.rotateObjectName;y!==a&&(ju(this),this.P.jr=a,this.g("rotateObjectName",y,a))}},rotateObject:{get:function(){var a=this.rotateObjectName;return a!==""&&(a=this.fb(a),a!==null)?a:this}},rotationSpot:{get:function(){return this.P!==null?this.P.lr:vs},set:function(a){var y=this.rotationSpot;y.D(a)||(a=a.J(),ju(this),this.P.lr=a,this.g("rotationSpot",y,a))}},text:{get:function(){return this.ec},set:function(a){var y=this.ec;y!==a&&(this.ec=a,this.g("text",y,a))}},containingGroup:{get:function(){return this.Ah},set:function(a){if(this.Zc()){var y=this.Ah;if(y!==a){a===null||this!==a&&!a.Td(this)||(this===a&&Dt("Cannot make a Group a member of itself: "+this.toString()),Dt("Cannot make a Group indirectly contain itself: "+this.toString()+" already contains "+a.toString())),this.C(2);var x=this.diagram;if(y!==null?U0(y,this):this instanceof xr&&x!==null&&x.ai.remove(this),this.Ah=a,a!==null?V0(a,this):this instanceof xr&&x!==null&&x.ai.add(this),this.C(1),x!==null&&x.aa){var E=this.data,b=x.model;if(E!==null&&b.Xj()){var z=b.wa(a!==null?a.data:null);b.mp(E,z)}}if(E=this.containingGroupChanged,E!==null&&(b=!0,x!==null&&(b=x.aa,x.aa=!0),E(this,y,a),x!==null&&(x.aa=b)),this instanceof xr){for(x=new Pn,Zd(x,this,!0,0,!0),x=x.iterator;x.next();)if(E=x.value,E instanceof qn)for(E=E.linksConnected;E.next();)kg(E.value)}if(this instanceof qn){for(x=this.linksConnected;x.next();)kg(x.value);x=this.labeledLink,x!==null&&kg(x)}this.g("containingGroup",y,a),a!==null&&(y=a.layer,y!==null&&Ha(y,-1,a))}}else Dt("cannot set the Part.containingGroup of a Link or Adornment")}},containingGroupChanged:{get:function(){return this.P!==null?this.P.Kp:null},set:function(a){var y=this.containingGroupChanged;y!==a&&(ju(this),this.P.Kp=a,this.g("containingGroupChanged",y,a))}},isTopLevel:{get:function(){return!(this.containingGroup!==null||this instanceof qn&&this.labeledLink!==null)}},layoutConditions:{get:function(){return this.P!==null?this.P.Cq:127},set:function(a){var y=this.layoutConditions;y!==a&&(ju(this),this.P.Cq=a,this.g("layoutConditions",y,a))}},dragComputation:{get:function(){return this.P!==null?this.P.Up:null},set:function(a){var y=this.dragComputation;y!==a&&(ju(this),this.P.Up=a,this.g("dragComputation",y,a))}},shadowOffset:{get:function(){return this.P!==null?this.P.zr:rl},set:function(a){var y=this.shadowOffset;y.D(a)||(a=a.J(),ju(this),this.P.zr=a,this.N(),this.g("shadowOffset",y,a))}},shadowColor:{get:function(){return this.P!==null?this.P.yr:"gray"},set:function(a){var y=this.shadowColor;y!==a&&(ju(this),this.P.yr=a,this.N(),this.g("shadowColor",y,a))}},shadowBlur:{get:function(){return this.P!==null?this.P.Vg:4},set:function(a){var y=this.shadowBlur;y!==a&&(ju(this),this.P.Vg=a,this.N(),this.g("shadowBlur",y,a))}}}),Ii.prototype.invalidateLayout=Ii.prototype.C,Ii.prototype.findCommonContainingGroup=Ii.prototype.px,Ii.prototype.isMemberOf=Ii.prototype.Td,Ii.prototype.findTopLevelPart=Ii.prototype.sz,Ii.prototype.findSubGraphLevel=Ii.prototype.oz,Ii.prototype.ensureBounds=Ii.prototype.Va,Ii.prototype.getDocumentBounds=Ii.prototype.mi,Ii.prototype.findObject=Ii.prototype.fb,Ii.prototype.moveTo=Ii.prototype.moveTo,Ii.prototype.invalidateAdornments=Ii.prototype.Wb,Ii.prototype.clearAdornments=Ii.prototype.Ej,Ii.prototype.removeAdornment=Ii.prototype.Jf,Ii.prototype.addAdornment=Ii.prototype.bh,Ii.prototype.findAdornment=Ii.prototype.Pj,Ii.prototype.updateTargetBindings=Ii.prototype.La;var HS=!1;Ii.className="Part",Ii.LayoutNone=0,Ii.LayoutAdded=1,Ii.LayoutRemoved=2,Ii.LayoutShown=4,Ii.LayoutHidden=8,Ii.LayoutNodeSized=16,Ii.LayoutGroupLayout=32,Ii.LayoutNodeReplaced=64,Ii.LayoutStandard=127,Ii.LayoutAll=16777215;function Fo(a,y){a===void 0||a instanceof qs||typeof a=="string"?Ii.call(this,a):(Ii.call(this),a&&(y=a)),this.G&=-257,this.Jg="Adornment",this.ue=null,this.Aw=0,this.Uw=!1,this.j=this.$a=null,y&&Object.assign(this,y)}Ct(Fo,Ii),Fo.prototype.toString=function(){var a=this.adornedPart;return"Adornment("+this.category+")"+(a!==null?a.toString():"")},Fo.prototype.updateRelationshipsFromData=function(){},Fo.prototype.Ul=function(a){var y=this.adornedObject,x=y==null?void 0:y.part;if(x instanceof Tn&&y instanceof Dr){y=x.path,x.Ul(a),a=y.geometry,x=this.O.s,y=x.length;for(var E=0;E<y;E++){var b=x[E];b.isPanelMain&&b instanceof Dr&&(b.ua=a)}}},Fo.prototype.si=function(){var a=this.ue;return a===null?!0:(a=a.part,a===null||!Su(a))},Fo.prototype.Zc=function(){return!1},Fo.prototype.gk=function(a,y,x,E,b,z,ee){if(a===ts&&y==="elements"){if(b instanceof wu)this.$a===null&&(this.$a=b);else if(b instanceof Ln){var re=b.Nl(function(oe){return oe instanceof wu});re instanceof wu&&this.$a===null&&(this.$a=re)}}else a===ss&&y==="elements"&&this.$a!==null&&(E===this.$a?this.$a=null:E instanceof Ln&&this.$a.rg(E)&&(this.$a=null));Ii.prototype.gk.call(this,a,y,x,E,b,z,ee)},Fo.prototype.updateAdornments=function(){},Fo.prototype.Lj=function(){},Yt.Object.defineProperties(Fo.prototype,{placeholder:{get:function(){return this.$a}},adornedObject:{get:function(){return this.ue},set:function(a){var y=this.adornedPart,x=null;a!==null&&(x=a.part),y===null||a!==null&&y===x||y.Jf(this.category),this.ue=a,x!==null&&x.bh(this.category,this)}},adornedPart:{get:function(){var a=this.ue;return a!==null?a.part:null}},containingGroup:{get:function(){return null}}}),Fo.className="Adornment";function G0(){this.nc=!1,this.Vr=this.gj=this.Eq=this.Dq=null,this.yp=wh,this.er=_m,this.Kr=this.ij=this.Nq=this.Mq=null}G0.prototype.copy=function(){var a=new G0;return a.Dq=this.Dq,a.Eq=this.Eq,a.gj=this.gj,a.Vr=this.Vr,a.yp=this.yp.J(),a.er=this.er,a.Mq=this.Mq,a.Nq=this.Nq,a.ij=this.ij,a.Kr=this.Kr,a};function qn(a,y){a===void 0||a instanceof qs||typeof a=="string"?Ii.call(this,a):(Ii.call(this),a&&(y=a)),this.U=13,this.Ba=null,this.jb=new An,this.wc=this.af=this.Yk=null,this.ci=!1,y&&Object.assign(this,y)}Ct(qn,Ii),qn.prototype.cloneProtected=function(a){Ii.prototype.cloneProtected.call(this,a),a.U=this.U,this.Ba!==null&&(a.Ba=this.Ba.nc?this.Ba:this.Ba.copy())},we=qn.prototype,we.Af=function(a){Ii.prototype.Af.call(this,a),a.Bd(),a.af=this.af,a.wc=null};function Ed(a){a.Ba===null?a.Ba=new G0:a.Ba.nc&&(a.Ba=a.Ba.copy())}we.th=function(){Ii.prototype.th.call(this),this.Ba!==null&&(this.Ba.nc=!0)};function GS(a,y){y!==null&&(a.af===null&&(a.af=new Pn),a.af.add(y))}function KS(a,y,x,E){if(y===null||a.af===null)return null;for(var b=a.af.iterator;b.next();){var z=b.value;if(z.Ds===a&&z.cv===y&&z.Ox===x&&z.Px===E||z.Ds===y&&z.cv===a&&z.Ox===E&&z.Px===x)return z}return null}we.Lz=function(a,y,x){y==null&&(y=""),x==null&&(x=""),a=KS(this,a,y,x),a!==null&&a.Sl()},we.gk=function(a,y,x,E,b,z,ee){a===ts&&y==="elements"?this.wc=null:a===ss&&y==="elements"&&(this.wc=null),Ii.prototype.gk.call(this,a,y,x,E,b,z,ee)},we.Bd=function(a){for(var y=this.linksConnected;y.next();){var x=y.value;a!==void 0&&a.contains(x)||(nh(x.fromPort),nh(x.toPort),x.bb())}};function WS(a,y){for(a=a.linksConnected;a.next();){var x=a.value;(x.fromPort===y||x.toPort===y)&&(nh(x.fromPort),nh(x.toPort),x.bb())}}function nh(a){if(a!==null){var y=a.Zn;y!==null&&y.Sl(),a=a.part,y=a.containingGroup,y===null||a.isVisible()||nh(y.port)}}we.si=function(){return!0},qn.prototype.getAvoidableRect=function(a){return a.set(this.actualBounds),a.Co(this.avoidableMargin),a},qn.prototype.findVisibleNode=function(){for(var a=this;a!==null&&!a.isVisible();)a=a.containingGroup;return a},qn.prototype.isVisible=function(){if(!Ii.prototype.isVisible.call(this))return!1;var a=!0,y=yd,x=this.diagram;if(x!==null&&(a=x.isTreePathToChildren,y=x.treeCollapsePolicy),y===yd){if(a=this.pg(),a!==null&&!a.isTreeExpanded)return!1}else if(y===_s){if(a=a?this.Oo():this.Po(),0<a.count&&a.all(function(E){return!E.isTreeExpanded}))return!1}else if(y===fg&&(a=a?this.Oo():this.Po(),0<a.count&&a.any(function(E){return!E.isTreeExpanded})))return!1;return a=this.labeledLink,a!==null?a.isVisible():!0},qn.prototype.Zb=function(a){Ii.prototype.Zb.call(this,a);for(var y=this.linksConnected;y.next();){var x=y.value;if(a&&this.containingGroup!==null){var E=x.To(this);E===null||E.Td(this.containingGroup)||x.bb()}x.Zb(a)}},qn.prototype.qx=function(){var a=new Pn,y=new Pn;return VS(this,this,a,y),y.iterator};function VS(a,y,x,E){if(y!==null&&!x.has(y)){x.add(y);var b=!0,z=a.diagram;z!==null&&(b=z.isTreePathToChildren),y.linksConnected.each(function(ee){ee.isTreeLink?(b?ee.fromNode===y:ee.toNode===y)&&VS(a,b?ee.toNode:ee.fromNode,x,E):E.add(ee)})}}qn.prototype.findLinksConnected=function(a){if(a===void 0&&(a=null),a===null)return this.jb.iterator;var y=new Oo(this.jb),x=this;return y.predicate=function(E){return E.fromNode===x&&E.fromPortId===a||E.toNode===x&&E.toPortId===a},y},we=qn.prototype,we.Mo=function(a){a===void 0&&(a=null);var y=new Oo(this.jb),x=this;return y.predicate=function(E){return E.fromNode!==x?!1:a===null?!0:E.fromPortId===a},y},we.Sd=function(a){a===void 0&&(a=null);var y=new Oo(this.jb),x=this;return y.predicate=function(E){return E.toNode!==x?!1:a===null?!0:E.toPortId===a},y},we.Mu=function(a){a===void 0&&(a=null);for(var y=null,x=null,E=this.jb.iterator;E.next();){var b=E.value;b.fromNode===this?(a===null||b.fromPortId===a)&&(b=b.toNode,y!==null?y.add(b):x!==null&&x!==b?(y=new Pn,y.add(x),y.add(b)):x=b):b.toNode!==this||a!==null&&b.toPortId!==a||(b=b.fromNode,y!==null?y.add(b):x!==null&&x!==b?(y=new Pn,y.add(x),y.add(b)):x=b)}return y!==null?y.iterator:x!==null?new fo(x):ea},we.Po=function(a){a===void 0&&(a=null);for(var y=null,x=null,E=this.jb.iterator;E.next();){var b=E.value;b.fromNode!==this||a!==null&&b.fromPortId!==a||(b=b.toNode,y!==null?y.add(b):x!==null&&x!==b?(y=new Pn,y.add(x),y.add(b)):x=b)}return y!==null?y.iterator:x!==null?new fo(x):ea},we.Oo=function(a){a===void 0&&(a=null);for(var y=null,x=null,E=this.jb.iterator;E.next();){var b=E.value;b.toNode!==this||a!==null&&b.toPortId!==a||(b=b.fromNode,y!==null?y.add(b):x!==null&&x!==b?(y=new Pn,y.add(x),y.add(b)):x=b)}return y!==null?y.iterator:x!==null?new fo(x):ea},we.jz=function(a,y,x){y===void 0&&(y=null),x===void 0&&(x=null);var E=new Oo(this.jb),b=this;return E.predicate=function(z){return!((z.fromNode!==b||z.toNode!==a||y!==null&&z.fromPortId!==y||x!==null&&z.toPortId!==x)&&(z.fromNode!==a||z.toNode!==b||x!==null&&z.fromPortId!==x||y!==null&&z.toPortId!==y))},E},we.kz=function(a,y,x){y===void 0&&(y=null),x===void 0&&(x=null);var E=new Oo(this.jb),b=this;return E.predicate=function(z){return!(z.fromNode!==b||z.toNode!==a||y!==null&&z.fromPortId!==y||x!==null&&z.toPortId!==x)},E};function Um(a,y,x){nh(x);var E=a.jb.contains(y);if(E||a.jb.add(y),!E||y.fromNode===y.toNode){var b=a.linkConnected;if(b!==null){var z=!0,ee=a.diagram;ee!==null&&(z=ee.aa,ee.aa=!0),b(a,y,x),ee!==null&&(ee.aa=z)}}!E&&y.isTreeLink&&(x=y.fromNode,y=y.toNode,x!==null&&y!==null&&x!==y&&(E=!0,a=a.diagram,a!==null&&(E=a.isTreePathToChildren),b=E?y:x,z=E?x:y,b.ci||(b.ci=z),!z.isTreeLeaf||a!==null&&a.undoManager.isUndoingRedoing||(E?x===z&&(z.isTreeLeaf=!1):y===z&&(z.isTreeLeaf=!1))))}function Zm(a,y,x){nh(x);var E=a.jb.remove(y),b=null;if(E||y.toNode===y.fromNode){var z=a.linkDisconnected;if(b=a.diagram,z!==null){var ee=!0;b!==null&&(ee=b.aa,b.aa=!0),z(a,y,x),b!==null&&(b.aa=ee)}}E&&y.isTreeLink&&(x=!0,b!==null&&(x=b.isTreePathToChildren),a=x?y.toNode:y.fromNode,y=x?y.fromNode:y.toNode,a!==null&&(a.ci=!1),y===null||y.isTreeLeaf||(y.jb.count===0?(y.ci=null,b!==null&&b.undoManager.isUndoingRedoing||(y.isTreeLeaf=!0)):xp(y)))}function xp(a){if(a.ci=!1,a.jb.count!==0){var y=!0,x=a.diagram;if(x===null||!x.undoManager.isUndoingRedoing){for(x!==null&&(y=x.isTreePathToChildren),x=a.jb.iterator;x.next();){var E=x.value;if(E.isTreeLink){if(y){if(E.fromNode===a){a.isTreeLeaf=!1;return}}else if(E.toNode===a){a.isTreeLeaf=!1;return}}}a.isTreeLeaf=!0}}}qn.prototype.updateRelationshipsFromData=function(){var a=this.diagram;a!==null&&a.partManager.updateRelationshipsFromData(this)},we=qn.prototype,we.Vo=function(a){Ii.prototype.Vo.call(this,a),a||(xp(this),a=this.Yk,a!==null&&$S(a,this))},we.Wo=function(a){Ii.prototype.Wo.call(this,a),a||(a=this.Yk,a!==null&&a.wd!==null&&(a.wd.remove(this),a.v()))},we.Lj=function(){if(0<this.jb.count){var a=this.diagram;if(a!==null)for(var y=a.commandHandler!==null?a.commandHandler.deletesConnectedLinks:!0,x=this.jb.copy().iterator;x.next();){var E=x.value;y?a.remove(E):(E.fromNode===this&&(E.fromNode=null),E.toNode===this&&(E.toNode=null))}}this.labeledLink=null,Ii.prototype.Lj.call(this)},we.ns=function(a){if(this.wc===null){if(a===""&&this.Te===!1)return this;US(this)}var y=this.wc.I(a);return y!==null||a!==""&&(y=this.wc.I(""),y!==null)?y:this};function US(a){a.wc===null?a.wc=new Li:a.wc.clear(),a.qm(a,function(y,x){ZS(y,x)}),a.wc.count===0&&a.wc.add("",a)}function ZS(a,y){var x=y.portId;x!==null&&a.wc!==null&&a.wc.add(x,y)}function K0(a,y,x){var E=y.portId;if(E!==null&&(a.wc!==null&&a.wc.remove(E),y=a.diagram,y!==null&&x)){for(x=null,a=a.findLinksConnected(E);a.next();)E=a.value,x===null&&(x=qi()),x.push(E);if(x!==null){for(a=0;a<x.length;a++)y.remove(x[a]);Zi(x)}}}we.Nz=function(a){if(a===null||a===this)return!1;var y=!0,x=this.diagram;if(x!==null&&(y=x.isTreePathToChildren),x=this,y)for(;x!==a;){y=null;for(var E=x.jb.iterator;E.next();){var b=E.value;if(b.isTreeLink&&(y=b.fromNode,y!==x&&y!==this))break}if(y===this||y===null||y===x)return!1;x=y}else for(;x!==a;){for(y=null,E=x.jb.iterator;E.next()&&(b=E.value,!b.isTreeLink||(y=b.toNode,y===x||y===this)););if(y===this||y===null||y===x)return!1;x=y}return!0},we.xz=function(){var a=!0,y=this.diagram;if(y!==null&&(a=y.isTreePathToChildren),y=this,a)for(;;){a=null;for(var x=y.jb.iterator;x.next();){var E=x.value;if(E.isTreeLink&&(a=E.fromNode,a!==y&&a!==this))break}if(a===this)return this;if(a===null||a===y)return y;y=a}else for(;;){for(a=null,x=y.jb.iterator;x.next()&&(E=x.value,!E.isTreeLink||(a=E.toNode,a===y||a===this)););if(a===this)return this;if(a===null||a===y)return y;y=a}},we.gz=function(a){if(a===null)return null;if(this===a)return this;for(var y=this;y!==null;)Vm(y,!0),y=y.pg();var x=null;for(y=a;y!==null;){if(y.G&1048576){x=y;break}y=y.pg()}for(y=this;y!==null;)Vm(y,!1),y=y.pg();return x},we.kh=function(){var a=!0,y=this.diagram;if(y!==null&&(a=y.isTreePathToChildren),y=this.jb.iterator,a){for(;y.next();)if(a=y.value,a.isTreeLink&&a.fromNode!==this)return a}else for(;y.next();)if(a=y.value,a.isTreeLink&&a.toNode!==this)return a;return null},we.pg=function(){var a=this.ci;if(a===null)return null;if(a instanceof qn)return a;a=this.diagram,a=a!==null?a.isTreePathToChildren:!0;for(var y=this.jb.iterator;y.next();){var x=y.value;if(x.isTreeLink&&(x=a?x.fromNode:x.toNode,x!==this))return this.ci=x}return this.ci=null},we.vz=function(){function a(x,E){E.add(x);var b=x.kh();b!==null&&(E.add(b),x=x.pg(),x!==null&&a(x,E))}var y=new Pn;return a(this,y),y},we.uz=function(){return _S(this,this)};function _S(a,y){return y=y.pg(),y===null?0:1+_S(a,y)}we.Qo=function(){var a=!0,y=this.diagram;y!==null&&(a=y.isTreePathToChildren),y=new Oo(this.jb);var x=this;return y.predicate=a?function(E){return!!(E.isTreeLink&&E.fromNode===x)}:function(E){return!!(E.isTreeLink&&E.toNode===x)},y},we.Ou=function(){var a=!0,y=this.diagram;y!==null&&(a=y.isTreePathToChildren);var x=y=null,E=this.jb.iterator;if(a)for(;E.next();)a=E.value,a.isTreeLink&&a.fromNode===this&&(a=a.toNode,y!==null?y.add(a):x!==null&&x!==a?(y=new An,y.add(x),y.add(a)):x=a);else for(;E.next();)a=E.value,a.isTreeLink&&a.toNode===this&&(a=a.fromNode,y!==null?y.add(a):x!==null&&x!==a?(y=new An,y.add(x),y.add(a)):x=a);return y!==null?y.iterator:x!==null?new fo(x):ea},we.wz=function(a){a===void 0&&(a=1/0);var y=new Pn;return Zd(y,this,!1,a,!0),y},qn.prototype.collapseTree=function(a){a===void 0&&(a=1),1>a&&(a=1);var y=this.diagram;if(y!==null&&!y.Ue){y.Ue=!0;var x=new Pn;x.add(this),YS(this,x,y.isTreePathToChildren,a,y,this,y.treeCollapsePolicy===yd),y.Ue=!1}};function YS(a,y,x,E,b,z,ee){if(1<E)for(var re=x?a.Mo():a.Sd();re.next();){var oe=re.value;oe.isTreeLink&&(oe=oe.To(a),oe===null||oe===a||y.contains(oe)||(y.add(oe),YS(oe,y,x,E-1,b,z,ee)))}else XS(a,y,x,b,z,ee)}function XS(a,y,x,E,b,z){for(var ee=b===a?!0:a.isTreeExpanded,re=x?a.Mo():a.Sd(),oe={};re.next();){var se=re.value;if(se.isTreeLink&&(se=se.To(a),se!==null&&se!==a)){var ue=y.contains(se);if(ue||y.add(se),ee){var fe=x?se.Oo():se.Po();oe.uv=a,fe.all(function(ve){return function(ye){return ye===ve.uv||!ye.isTreeExpanded}}(oe))&&E.Aj(se,b),se.oh(),se.Zb(!1)}se.isTreeExpanded&&(se.wasTreeExpanded=se.isTreeExpanded,ue||XS(se,y,x,E,b,z))}oe={uv:oe.uv}}a.isTreeExpanded=!1}qn.prototype.expandTree=function(a){a===void 0&&(a=2),2>a&&(a=2);var y=this.diagram;if(y!==null&&!y.Ue){y.Ue=!0;var x=new Pn;x.add(this),JS(this,x,y.isTreePathToChildren,a,y,this,y.treeCollapsePolicy===yd),y.Ue=!1}};function JS(a,y,x,E,b,z,ee){for(var re=z===a?!1:a.isTreeExpanded,oe=x?a.Mo():a.Sd(),se={};oe.next();){var ue=oe.value;if(ue.isTreeLink&&(re||ue.fd||ue.bb(),ue=ue.To(a),ue!==null&&ue!==a&&!y.contains(ue))){if(y.add(ue),!re){ue.Zb(!0),ue.oh();var fe=x?ue.Oo():ue.Po();se.vv=a,fe.all(function(ve){return function(ye){return ye===ve.vv||!ye.isTreeExpanded}}(se))&&b.Cj(ue,z)}(2<E||ue.wasTreeExpanded)&&(ue.wasTreeExpanded=!1,JS(ue,y,x,E-1,b,z,ee))}se={vv:se.vv}}a.isTreeExpanded=!0}Yt.Object.defineProperties(qn.prototype,{portSpreading:{get:function(){return this.Ba!==null?this.Ba.er:_m},set:function(a){var y=this.portSpreading;y!==a&&(Ed(this),this.Ba.er=a,this.g("portSpreading",y,a),a=this.diagram,a!==null&&a.undoManager.isUndoingRedoing||this.Bd())}},avoidable:{get:function(){return(this.U&8)!==0},set:function(a){var y=(this.U&8)!==0;if(y!==a){this.U^=8;var x=this.diagram;x!==null&&md(x,this),this.g("avoidable",y,a)}}},avoidableMargin:{get:function(){return this.Ba!==null?this.Ba.yp:wh},set:function(a){typeof a=="number"&&(a=new vr(a));var y=this.avoidableMargin;if(!y.D(a)){a=a.J(),Ed(this),this.Ba.yp=a;var x=this.diagram;x!==null&&md(x,this),this.g("avoidableMargin",y,a)}}},linksConnected:{get:function(){return this.jb.iterator}},linkConnected:{get:function(){return this.Ba!==null?this.Ba.Dq:null},set:function(a){var y=this.linkConnected;y!==a&&(Ed(this),this.Ba.Dq=a,this.g("linkConnected",y,a))}},linkDisconnected:{get:function(){return this.Ba!==null?this.Ba.Eq:null},set:function(a){var y=this.linkDisconnected;y!==a&&(Ed(this),this.Ba.Eq=a,this.g("linkDisconnected",y,a))}},linkValidation:{get:function(){return this.Ba!==null?this.Ba.gj:null},set:function(a){var y=this.linkValidation;y!==a&&(Ed(this),this.Ba.gj=a,this.g("linkValidation",y,a))}},isLinkLabel:{get:function(){return this.Yk!==null}},labeledLink:{get:function(){return this.Yk},set:function(a){var y=this.Yk;if(y!==a){var x=this.diagram,E=this.data;if(y!==null){if(y.wd!==null&&(y.wd.remove(this),y.v()),x!==null&&E!==null&&!x.undoManager.isUndoingRedoing){var b=y.data,z=x.model;if(b!==null&&z.ri()){var ee=z.wa(E);ee!==void 0&&z.Qx(b,ee)}}this.containingGroup=null}this.Yk=a,a!==null&&($S(a,this),x===null||E===null||x.undoManager.isUndoingRedoing||(b=a.data,x=x.model,b!==null&&x.ri()&&(E=x.wa(E),E!==void 0&&x.Bu(b,E))),this.containingGroup=a.containingGroup),yu(this),this.g("labeledLink",y,a)}}},port:{get:function(){return this.ns("")}},ports:{get:function(){return this.wc===null&&US(this),this.wc.iteratorValues}},isTreeExpanded:{get:function(){return(this.U&1)!==0},set:function(a){var y=(this.U&1)!==0;if(y!==a){this.U^=1;var x=this.diagram;if(this.g("isTreeExpanded",y,a),y=this.treeExpandedChanged,y!==null){var E=!0;x!==null&&(E=x.aa,x.aa=!0),y(this),x!==null&&(x.aa=E)}x!==null&&x.undoManager.isUndoingRedoing?this.Zb(a):a?this.expandTree():this.collapseTree()}}},wasTreeExpanded:{get:function(){return(this.U&2)!==0},set:function(a){var y=(this.U&2)!==0;y!==a&&(this.U^=2,this.g("wasTreeExpanded",y,a))}},treeExpandedChanged:{get:function(){return this.Ba!==null?this.Ba.Vr:null},set:function(a){var y=this.treeExpandedChanged;y!==a&&(Ed(this),this.Ba.Vr=a,this.g("treeExpandedChanged",y,a))}},isTreeLeaf:{get:function(){return(this.U&4)!==0},set:function(a){var y=(this.U&4)!==0;y!==a&&(this.U^=4,this.g("isTreeLeaf",y,a))}}}),qn.prototype.expandTree=qn.prototype.expandTree,qn.prototype.collapseTree=qn.prototype.collapseTree,qn.prototype.findTreeParts=qn.prototype.wz,qn.prototype.findTreeChildrenNodes=qn.prototype.Ou,qn.prototype.findTreeChildrenLinks=qn.prototype.Qo,qn.prototype.findTreeLevel=qn.prototype.uz,qn.prototype.findTreeParentChain=qn.prototype.vz,qn.prototype.findTreeParentNode=qn.prototype.pg,qn.prototype.findTreeParentLink=qn.prototype.kh,qn.prototype.findCommonTreeParent=qn.prototype.gz,qn.prototype.findTreeRoot=qn.prototype.xz,qn.prototype.isInTreeOf=qn.prototype.Nz,qn.prototype.findPort=qn.prototype.ns,qn.prototype.findLinksTo=qn.prototype.kz,qn.prototype.findLinksBetween=qn.prototype.jz,qn.prototype.findNodesInto=qn.prototype.Oo,qn.prototype.findNodesOutOf=qn.prototype.Po,qn.prototype.findNodesConnected=qn.prototype.Mu,qn.prototype.findLinksInto=qn.prototype.Sd,qn.prototype.findLinksOutOf=qn.prototype.Mo,qn.prototype.findExternalTreeLinksConnected=qn.prototype.qx,qn.prototype.invalidateConnectedLinks=qn.prototype.Bd,qn.prototype.invalidateLinkBundle=qn.prototype.Lz;var Ex=new Vt(qn,"SpreadingNone",10),_m=new Vt(qn,"SpreadingEvenly",11),W0=new Vt(qn,"SpreadingPacked",12);qn.className="Node",qn.SpreadingNone=Ex,qn.SpreadingEvenly=_m,qn.SpreadingPacked=W0;function xr(a,y){a===void 0||a instanceof qs||typeof a=="string"?qn.call(this,a):(qn.call(this),a&&(y=a)),this.U|=4608,this.Gn=new Pn,this.$a=null,this.Sc=new as,this.Sc.group=this,this.gl=new Pn,this.tb=this.$p=null,y&&Object.assign(this,y)}Ct(xr,qn),xr.prototype.cloneProtected=function(a){qn.prototype.cloneProtected.call(this,a),this.U=this.U&-32769;var y=a.Nl(function(x){return x instanceof wu});y instanceof wu?a.$a=y:a.$a=null,this.Sc!==null?(a.Sc=this.Sc.copy(),a.Sc.group=a):(a.Sc!==null&&(a.Sc.group=null),a.Sc=null),this.tb!==null&&(a.tb=this.tb.copy())},we=xr.prototype,we.Af=function(a){qn.prototype.Af.call(this,a);var y=a.Rj();for(a=a.memberParts;a.next();){var x=a.value;if(x.v(),x.C(8),x.Ej(),x instanceof qn)x.Bd(y);else if(x instanceof Tn)for(x=x.labelNodes;x.next();)x.value.Bd(y)}},we.gk=function(a,y,x,E,b,z,ee){if(a===ts&&y==="elements"){if(b instanceof wu)this.$a===null?this.$a=b:this.$a!==b&&Dt("Cannot insert a second Placeholder into the visual tree of a Group.");else if(b instanceof Ln){var re=b.Nl(function(oe){return oe instanceof wu});re instanceof wu&&(this.$a===null?this.$a=re:this.$a!==re&&Dt("Cannot insert a second Placeholder into the visual tree of a Group."))}}else a===ss&&y==="elements"&&this.$a!==null&&(E===this.$a?this.$a=null:E instanceof Ln&&this.$a.rg(E)&&(this.$a=null));qn.prototype.gk.call(this,a,y,x,E,b,z,ee)},we.Xl=function(a,y){qn.prototype.Xl.call(this,a,y),this.isClipping&&this.type!==Ln.Spot&&this.isSubGraphExpanded&&(a=this.resizeObject,a instanceof Ln&&(a=a.Pb()),this.tb===null&&(this.tb=new Xt),a.mi(this.tb),a instanceof Dr&&this.tb.Bc(-a.strokeWidth,-a.strokeWidth))},we.eh=function(a,y,x,E){this.nf=this.$a,qn.prototype.eh.call(this,a,y,x,E)},we.Va=function(){var a=this;a.isSubGraphExpanded&&this.memberParts.each(function(y){!a.computesBoundsIncludingLinks&&y instanceof Tn||y.Va()}),qn.prototype.Va.call(this)},we.si=function(){if(!qn.prototype.si.call(this))return!1;for(var a=this.memberParts;a.next();){var y=a.value;if(y instanceof qn){if(y.isVisible()&&Su(y))return!1}else if(y instanceof Tn&&y.isVisible()&&Su(y)&&y.fromNode!==this&&y.toNode!==this)return!1}return!0};function V0(a,y){if(a.Gn.add(y)){y instanceof xr&&a.gl.add(y);var x=a.memberAdded;if(x!==null){var E=!0,b=a.diagram;b!==null&&(E=b.aa,b.aa=!0),x(a,y),b!==null&&(b.aa=E)}a.isVisible()&&a.isSubGraphExpanded||y.Zb(!1)}y instanceof Tn&&!a.computesBoundsIncludingLinks||(y=a.$a,y===null&&(y=a),y.v())}function U0(a,y){if(a.Gn.remove(y)){y instanceof xr&&a.gl.remove(y);var x=a.memberRemoved;if(x!==null){var E=!0,b=a.diagram;b!==null&&(E=b.aa,b.aa=!0),x(a,y),b!==null&&(b.aa=E)}a.isVisible()&&a.isSubGraphExpanded||y.Zb(!0)}y instanceof Tn&&!a.computesBoundsIncludingLinks||(y=a.$a,y===null&&(y=a),y.v())}we.Lj=function(){if(0<this.Gn.count){var a=this.diagram;if(a!==null)for(var y=this.Gn.copy().iterator;y.next();)a.remove(y.value)}qn.prototype.Lj.call(this)},xr.prototype.canAddMembers=function(a){var y=this.diagram;if(y===null)return!1;for(y=y.commandHandler,a=_t(a).iterator;a.next();)if(!y.isValidMember(this,a.value))return!1;return!0},xr.prototype.addMembers=function(a,y){var x=this.diagram;if(x===null)return!1;x=x.commandHandler;var E=!0;for(a=_t(a).iterator;a.next();){var b=a.value;!y||x.isValidMember(this,b)?b.containingGroup=this:E=!1}return E},xr.prototype.canUngroup=function(){if(!this.ungroupable)return!1;var a=this.layer;return a===null||!a.allowUngroup?!1:(a=a.diagram,!!(a===null||a.allowUngroup))},we=xr.prototype,we.Bd=function(a){var y=(this.U&65536)!==0;if(qn.prototype.Bd.call(this,a),!y)for(!(this.U&65536)&&(this.U=this.U^65536),y=this.Lu();y.next();){var x=y.value;if(a===void 0||!a.contains(x)){var E=x.fromNode;E!==null&&E!==this&&E.Td(this)&&!E.isVisible()?(nh(x.fromPort),nh(x.toPort),x.bb()):(E=x.toNode,E!==null&&E!==this&&E.Td(this)&&!E.isVisible()&&(nh(x.fromPort),nh(x.toPort),x.bb()))}}},we.Lu=function(){var a=this.diagram!==null&&this.diagram.Pw;if(a&&this.$p!==null)return this.$p.iterator;var y=this.Rj();y.add(this);for(var x=new Pn,E=y.iterator;E.next();){var b=E.value;if(b instanceof qn)for(b=b.linksConnected;b.next();){var z=b.value;y.contains(z)||x.add(z)}}return a&&(this.$p=x),x.iterator},we.iz=function(){var a=this.Rj();a.add(this);for(var y=new Pn,x=a.iterator;x.next();){var E=x.value;if(E instanceof qn)for(E=E.linksConnected;E.next();){var b=E.value,z=b.fromNode;z===null||a.contains(z)&&z!==this||y.add(z),b=b.toNode,b===null||a.contains(b)&&b!==this||y.add(b)}}return y.iterator},we.hz=function(){function a(x,E){x!==null&&(E.add(x),a(x.containingGroup,E))}var y=new Pn;return a(this,y),y},we.Rj=function(){var a=new Pn;return Zd(a,this,!0,0,!0),a.remove(this),a},we.Zb=function(a){qn.prototype.Zb.call(this,a);for(var y=this.memberParts;y.next();)y.value.Zb(a)},xr.prototype.collapseSubGraph=function(){var a=this.diagram;if(a!==null&&!a.Ue){a.Ue=!0;var y=this.Rj();QS(this,y,a,this),a.Ue=!1}};function QS(a,y,x,E){for(var b=a.memberParts;b.next();){var z=b.value;if(z.Zb(!1),z instanceof xr&&z.isSubGraphExpanded&&(z.wasSubGraphExpanded=z.isSubGraphExpanded,QS(z,y,x,E)),z instanceof qn)z.Bd(y),x.Aj(z,E);else if(z instanceof Tn)for(z=z.labelNodes;z.next();)z.value.Bd(y)}a.isSubGraphExpanded=!1}xr.prototype.expandSubGraph=function(){var a=this.diagram;if(a!==null&&!a.Ue){a.Ue=!0;var y=this.Rj();qS(this,y,a,this),a.Ue=!1}};function qS(a,y,x,E){for(var b=a.memberParts;b.next();){var z=b.value;if(z.Zb(!0),z instanceof xr&&z.wasSubGraphExpanded&&(z.wasSubGraphExpanded=!1,qS(z,y,x,E)),z instanceof qn)z.Bd(y),x.Cj(z,E);else if(z instanceof Tn)for(z=z.labelNodes;z.next();)z.value.Bd(y)}a.isSubGraphExpanded=!0}xr.prototype.move=function(a,y){y===void 0&&(y=!1);var x=y?this.location:this.position,E=x.x;x=x.y;var b=a.x,z=a.y;if(!(E===b||isNaN(E)&&isNaN(b))||!(x===z||isNaN(x)&&isNaN(z))){for(E=b-(isNaN(E)?0:E),x=z-(isNaN(x)?0:x),z=Qe.alloc(),qn.prototype.move.call(this,a,y),a=new Pn,y=this.Rj().iterator;y.next();)b=y.value,b instanceof Tn&&(b.suspendsRouting&&a.add(b),b.fd||b.fromNode!==this&&b.toNode!==this)&&(b.suspendsRouting=!0);for(y.reset();y.next();)if(b=y.value,!(b.ph()||b instanceof qn&&b.isLinkLabel)){var ee=b.position,re=b.location;ee.w()?(z.x=ee.x+E,z.y=ee.y+x,b.position=z):re.w()&&(z.x=re.x+E,z.y=re.y+x,b.location=z)}for(y.reset();y.next();)b=y.value,b instanceof Tn&&(b.suspendsRouting=a.contains(b),b.fd||b.fromNode!==this&&b.toNode!==this)&&(ee=b.position,z.x=ee.x+E,z.y=ee.y+x,z.w()?b.move(z):b.bb(),_0(b)&&b.bb());Qe.free(z)}},Yt.Object.defineProperties(xr.prototype,{placeholder:{get:function(){return this.$a}},computesBoundsAfterDrag:{get:function(){return(this.U&2048)!==0},set:function(a){var y=(this.U&2048)!==0;y!==a&&(this.U^=2048,this.g("computesBoundsAfterDrag",y,a))}},computesBoundsIncludingLinks:{get:function(){return(this.U&4096)!==0},set:function(a){var y=(this.U&4096)!==0;y!==a&&(this.U^=4096,this.g("computesBoundsIncludingLinks",y,a))}},computesBoundsIncludingLocation:{get:function(){return(this.U&8192)!==0},set:function(a){var y=(this.U&8192)!==0;y!==a&&(this.U^=8192,this.g("computesBoundsIncludingLocation",y,a))}},handlesDragDropForMembers:{get:function(){return(this.U&16384)!==0},set:function(a){var y=(this.U&16384)!==0;y!==a&&(this.U^=16384,this.g("handlesDragDropForMembers",y,a))}},memberParts:{get:function(){return this.Gn.iterator}},layout:{get:function(){return this.Sc},set:function(a){var y=this.Sc;if(y!==a){a!==null&&a.diagram!==null&&a.diagram.layout===a&&Dt("A layout cannot be both the Diagram.layout and a Group.layout: "+a),y!==null&&(y.diagram=null,y.group=null),this.Sc=a;var x=this.diagram;a!==null&&(a.diagram=x,a.group=this),x!==null&&(x.xh=!0),this.g("layout",y,a),x!==null&&x.$b()}}},memberAdded:{get:function(){return this.Ba!==null?this.Ba.Mq:null},set:function(a){var y=this.memberAdded;y!==a&&(Ed(this),this.Ba.Mq=a,this.g("memberAdded",y,a))}},memberRemoved:{get:function(){return this.Ba!==null?this.Ba.Nq:null},set:function(a){var y=this.memberRemoved;y!==a&&(Ed(this),this.Ba.Nq=a,this.g("memberRemoved",y,a))}},memberValidation:{get:function(){return this.Ba!==null?this.Ba.ij:null},set:function(a){var y=this.memberValidation;y!==a&&(Ed(this),this.Ba.ij=a,this.g("memberValidation",y,a))}},ungroupable:{get:function(){return(this.U&256)!==0},set:function(a){var y=(this.U&256)!==0;y!==a&&(this.U^=256,this.g("ungroupable",y,a))}},isSubGraphExpanded:{get:function(){return(this.U&512)!==0},set:function(a){var y=(this.U&512)!==0;if(y!==a){this.U^=512;var x=this.diagram;if(this.g("isSubGraphExpanded",y,a),y=this.subGraphExpandedChanged,y!==null){var E=!0;x!==null&&(E=x.aa,x.aa=!0),y(this),x!==null&&(x.aa=E)}x!==null&&x.undoManager.isUndoingRedoing?(this.$a!==null&&this.$a.v(),this.memberParts.each(function(b){b.updateAdornments()})):a?this.expandSubGraph():this.collapseSubGraph()}}},wasSubGraphExpanded:{get:function(){return(this.U&1024)!==0},set:function(a){var y=(this.U&1024)!==0;y!==a&&(this.U^=1024,this.g("wasSubGraphExpanded",y,a))}},subGraphExpandedChanged:{get:function(){return this.Ba!==null?this.Ba.Kr:null},set:function(a){var y=this.subGraphExpandedChanged;y!==a&&(Ed(this),this.Ba.Kr=a,this.g("subGraphExpandedChanged",y,a))}},rh:{get:function(){return(this.U&32768)!==0},set:function(a){(this.U&32768)!==0!==a&&(this.U^=32768)}}}),xr.prototype.expandSubGraph=xr.prototype.expandSubGraph,xr.prototype.collapseSubGraph=xr.prototype.collapseSubGraph,xr.prototype.findSubGraphParts=xr.prototype.Rj,xr.prototype.findContainingGroupChain=xr.prototype.hz,xr.prototype.findExternalNodesConnected=xr.prototype.iz,xr.prototype.findExternalLinksConnected=xr.prototype.Lu,xr.prototype.ensureBounds=xr.prototype.Va,xr.className="Group";function wu(a){mt.call(this),this.yb=Tl,this.ko=new Xt(NaN,NaN,NaN,NaN),a&&Object.assign(this,a)}Ct(wu,mt),wu.prototype.cloneProtected=function(a){mt.prototype.cloneProtected.call(this,a),a.yb=this.yb.J(),a.ko=this.ko.copy()},wu.prototype.gh=function(a){if(this.background===null&&this.areaBackground===null)return!1;var y=this.naturalBounds;return Ds(0,0,y.width,y.height,a.x,a.y)},wu.prototype.Wl=function(){var a=this.part;if(a!==null&&(a instanceof xr||a instanceof Fo)||Dt("Placeholder is not inside a Group or Adornment."),a instanceof xr){var y=this.computeBorder(this.ko),x=this.minSize,E=this.dc;for(Ll(E,(isFinite(x.width)?Math.max(x.width,y.width):y.width)||0,(isFinite(x.height)?Math.max(x.height,y.height):y.height)||0),this.Ge(0,0,E.width,E.height),E=a.memberParts,x=!1;E.next();)if(E.value.isVisible()){x=!0;break}E=a.diagram,!x||E===null||E.animationManager.Xu(a)||isNaN(y.x)||isNaN(y.y)||(x=Qe.alloc(),x.xi(y,a.locationSpot),x.D(a.location)||(a.location=x),Qe.free(x))}else{y=this.dc,x=this.yb,E=x.left+x.right;var b=x.top+x.bottom,z=a.adornedObject;a.angle=z.li();var ee=0;z instanceof Dr&&(ee=z.strokeWidth);var re=z.Df(),oe=z.naturalBounds,se=(oe.width+ee)*re;ee=(oe.height+ee)*re,a.type!==Ln.Link&&(re=z.ga(a.category==="Selection"?Cs:a.locationSpot,Qe.alloc()),a.location=re,Qe.free(re)),isNaN(se)||isNaN(ee)?(a=z.ga(Cs,Qe.alloc()),se=Xt.allocAt(a.x,a.y,0,0),se.Ye(z.ga(Hl,a)),se.Ye(z.ga(lh,a)),se.Ye(z.ga(iu,a)),Ll(y,se.width+E||0,se.height+b||0),this.Ge(-x.left,-x.top,y.width,y.height),Qe.free(a),Xt.free(se)):(Ll(y,se+E||0,ee+b||0),this.Ge(-x.left,-x.top,y.width,y.height))}},wu.prototype.eh=function(a,y,x,E){this.actualBounds.h(a,y,x,E)},wu.prototype.computeBorder=function(a){var y=this.part,x=y.diagram,E=x===null||!x.animationManager.isAnimating;if(x!==null&&y instanceof xr&&!y.layer.isTemporary&&y.computesBoundsAfterDrag&&this.ko.w()){var b=x.toolManager.findTool("Dragging");if(b===x.currentTool&&(x=b.computeBorder(y,this.ko,a),x!==null))return x}x=Xt.alloc(),b=this.computeMemberBounds(x);var z=this.yb;return y instanceof xr&&!y.isSubGraphExpanded?a.h(b.x-z.left,b.y-z.top,0,0):a.h(b.x-z.left,b.y-z.top,Math.max(b.width+z.left+z.right,0),Math.max(b.height+z.top+z.bottom,0)),Xt.free(x),E&&y instanceof xr&&y.computesBoundsIncludingLocation&&y.location.w()&&a.Ye(y.location),a},wu.prototype.computeMemberBounds=function(a){if(!(this.part instanceof xr))return a.h(0,0,0,0),a;for(var y=this.part,x=1/0,E=1/0,b=-1/0,z=-1/0,ee=y.memberParts;ee.next();){var re=ee.value;if(re.isVisible()){if(re instanceof Tn&&(!y.computesBoundsIncludingLinks||ph(re)||re.fromNode===y||re.toNode===y))continue;re=re.actualBounds,re.left<x&&(x=re.left),re.top<E&&(E=re.top),re.right>b&&(b=re.right),re.bottom>z&&(z=re.bottom)}}return isFinite(x)&&isFinite(E)?a.h(x,E,b-x,z-E):(y=y.location,a.h(y.x,y.y,0,0)),a},Yt.Object.defineProperties(wu.prototype,{padding:{get:function(){return this.yb},set:function(a){typeof a=="number"&&(a=new vr(a));var y=this.yb;y.D(a)||(this.yb=a=a.J(),this.g("padding",y,a),this.v())}}}),wu.className="Placeholder";function Tn(a){Ii.call(this,Ln.Link),this.Qa=8,this.ef=null,this.ff="",this.uf=this.gn=null,this.vf="",this.uo=null,this.qk=Pu,this.Om=0,this.Qm=Pu,this.Rm=NaN,this.qj=J0,this.po=.5,this.wd=null,this.Nb=new An().freeze(),this.Tg=this.Mg=null,this.ml=new Xt,this.ua=new Bn,this.u=this.o=this.Sf=this.Wf=null,this.su=new Qe,this.cq=this.Mw=this.Lw=null,this.vt=NaN,this.ba=null,this.j=[],a&&Object.assign(this,a)}Ct(Tn,Ii),Tn.prototype.cloneProtected=function(a){Ii.prototype.cloneProtected.call(this,a),a.Qa=this.Qa&-113,a.ff=this.ff,a.gn=this.gn,a.vf=this.vf,a.uo=this.uo,a.qk=this.qk,a.Om=this.Om,a.Qm=this.Qm,a.Rm=this.Rm,a.qj=this.qj,a.po=this.po,this.ba!==null&&(a.ba=this.ba.copy())},we=Tn.prototype,we.Af=function(a){Ii.prototype.Af.call(this,a),this.ff=a.ff,this.vf=a.vf,a.Mg=null,a.bb(),a.Sf=this.Sf;var y=a.fromPort;y!==null&&nh(y),a=a.toPort,a!==null&&nh(a)},we.qb=function(a){a.classType===Tn?(a.value&2)===2?this.routing=a:a===vh||a===Ld||a===Ag?this.curve=a:a===Cp||a===$m||a===ev?this.adjusting=a:a!==J0&&a!==Pu&&Dt("Unknown Link enum value for a Link property: "+a):Ii.prototype.qb.call(this,a)},we.Xc=function(){this.ba===null&&(this.ba=new up)},we.si=function(){var a=this.fromNode;if(a!==null){var y=a.findVisibleNode();if(y!==null&&(a=y),Su(a)||Vd(a))return!1}return a=this.toNode,!(a!==null&&(y=a.findVisibleNode(),y!==null&&(a=y),Su(a)||Vd(a)))},we.zv=function(){return!1},we.Av=function(){},we.Zc=function(){return!1},Tn.prototype.computeAngle=function(a,y,x){return Tn.computeAngle(y,x)},Tn.computeAngle=function(a,y){switch(a){default:case Pu:a=0;break;case Ep:a=y;break;case bp:a=y+90;break;case Lp:a=y-90;break;case Q0:a=y+180;break;case tv:a=yt.bp(y),90<a&&270>a&&(a-=180);break;case Mp:a=yt.bp(y+90),90<a&&270>a&&(a-=180);break;case kp:a=yt.bp(y-90),90<a&&270>a&&(a-=180);break;case nv:if(a=yt.bp(y),45<a&&135>a||225<a&&315>a)return 0;90<a&&270>a&&(a-=180)}return yt.bp(a)};function kg(a){var y=a.fromNode,x=a.toNode,E=null;if(y!==null?E=x!==null?y.px(x):y.containingGroup:x!==null?E=x.containingGroup:E=null,y=E,x=a.Ah,x!==y){x!==null&&U0(x,a),a.Ah=y,y!==null&&V0(y,a);var b=a.containingGroupChanged;if(b!==null){var z=!0,ee=a.diagram;ee!==null&&(z=ee.aa,ee.aa=!0),b(a,x,y),ee!==null&&(ee.aa=z)}!a.fd||a.Lw!==x&&a.Mw!==x||a.bb()}if(a.isLabeledLink)for(a=a.labelNodes;a.next();)a.value.containingGroup=E}we=Tn.prototype,we.oh=function(){var a=this.containingGroup;a!==null&&this.fromNode!==a&&this.toNode!==a&&a.computesBoundsIncludingLinks&&Ii.prototype.oh.call(this)},we.To=function(a){var y=this.fromNode;return a===y?this.toNode:y},we.Cz=function(a){var y=this.fromPort;return a===y?this.toPort:y};function $S(a,y){a.wd===null&&(a.wd=new Pn),a.wd.add(y),a.v()}we.Vo=function(a){if(Ii.prototype.Vo.call(this,a),Cf(this)&&this.Xo(this.actualBounds),!a){a=this.ef;var y=null;a!==null&&(y=this.fromPort,Um(a,this,y));var x=this.uf;if(x!==null){var E=this.toPort;x===a&&E===y||Um(x,this,E)}wp(this)}},we.Wo=function(a){if(Ii.prototype.Wo.call(this,a),Cf(this)&&this.Xo(this.actualBounds),!a){a=this.ef;var y=null;a!==null&&(y=this.fromPort,Zm(a,this,y));var x=this.uf;if(x!==null){var E=this.toPort;x===a&&E===y||Zm(x,this,E)}Pp(this)}},we.Lj=function(){if(this.fd=!0,this.wd!==null){var a=this.diagram;if(a!==null)for(var y=this.wd.copy().iterator;y.next();)a.remove(y.value)}this.data!==null&&(a=this.diagram,a!==null&&a.partManager.removeDataForLink(this))},Tn.prototype.updateRelationshipsFromData=function(){if(this.data!==null){var a=this.diagram;a!==null&&a.partManager.updateRelationshipsFromData(this)}},Tn.prototype.move=function(a,y){var x=y?this.location:this.position,E=x.x;isNaN(E)&&(E=0);var b=x.y;for(isNaN(b)&&(b=0),E=a.x-E,b=a.y-b,y===!0?Ii.prototype.move.call(this,a,!1):(a=Qe.allocAt(x.x+E,x.y+b),Ii.prototype.move.call(this,a,!1),Qe.free(a)),bd(this,E,b),a=this.labelNodes;a.next();)y=a.value,x=y.position,y.moveTo(x.x+E,x.y+b)},Tn.prototype.canRelinkFrom=function(){if(!this.relinkableFrom)return!1;var a=this.layer;return a===null?!0:a.allowRelink?(a=a.diagram,!!(a===null||a.allowRelink)):!1},Tn.prototype.canRelinkTo=function(){if(!this.relinkableTo)return!1;var a=this.layer;return a===null?!0:a.allowRelink?(a=a.diagram,!!(a===null||a.allowRelink)):!1},Tn.prototype.computeMidPoint=function(a){var y=this.pointsCount;if(y===0)return a.assign(tu),a;if(y===1)return a.assign(this.i(0)),a;if(y===2){var x=this.i(0),E=this.i(1);return a.h((x.x+E.x)/2,(x.y+E.y)/2),a}if(this.isOrthogonal&&(15<=this.computeCorner()||this.computeCurve()===vh))return this.ua.Pu(.5,a),a.add(this.i(0)),x=this.ua.figures.first(),a.offset(-x.startX,-x.startY),a;if(this.computeCurve()===vh){if(y===3){x=this.i(0),E=this.i(1);var b=this.i(2);return yt.ax(x.x,x.y,E.x,E.y,E.x,E.y,b.x,b.y,a),a}if(E=(y-1)/3|0,x=3*(E/2|0),E%2===1){E=this.i(x),b=this.i(x+1);var z=this.i(x+2);x=this.i(x+3),yt.ax(E.x,E.y,b.x,b.y,z.x,z.y,x.x,x.y,a)}else a.assign(this.i(x));return a}var ee=this.flattenedLengths;for(x=this.flattenedTotalLength,b=z=E=0;E<x/2&&z<y&&(b=ee[z],!(E+b>x/2));)E+=b,z++;return y=this.i(z),z=this.i(z+1),1>Math.abs(y.x-z.x)?y.y>z.y?a.h(y.x,y.y-(x/2-E)):a.h(y.x,y.y+(x/2-E)):1>Math.abs(y.y-z.y)?y.x>z.x?a.h(y.x-(x/2-E),y.y):a.h(y.x+(x/2-E),y.y):(x=(x/2-E)/b,a.h(y.x+x*(z.x-y.x),y.y+x*(z.y-y.y))),a},Tn.prototype.computeMidAngle=function(){var a=this.pointsCount;if(2>a)return NaN;if(a===2)return this.i(0).ab(this.i(1));if(this.isOrthogonal&&(15<=this.computeCorner()||this.computeCurve()===vh))return this.ua.wx(.5);if(this.computeCurve()===vh&&4<=a){var y=(a-1)/3|0,x=3*(y/2|0);if(y%2===1){x=Math.floor(x),a=this.i(x),y=this.i(x+1);var E=this.i(x+2);return x=this.i(x+3),yt.My(a.x,a.y,y.x,y.y,E.x,E.y,x.x,x.y)}if(0<x&&x+1<a)return this.i(x-1).ab(this.i(x+1))}y=this.flattenedLengths,E=this.flattenedTotalLength;var b=0;x=0;for(var z;b<E/2&&x<a&&(z=y[x],!(b+z>E/2));)b+=z,x++;if(y=this.i(x),E=this.i(x+1),1>Math.abs(y.x-E.x)&&1>Math.abs(y.y-E.y)){if(0<x&&x+2<a)return this.i(x-1).ab(this.i(x+2))}else{if(1>Math.abs(y.x-E.x))return y.y>E.y?270:90;if(1>Math.abs(y.y-E.y))return y.x>E.x?180:0}return y.ab(E)},we=Tn.prototype,we.i=function(a){return this.Nb.s[a]},we.dd=function(a,y){this.Nb.cd(a,y)},we.L=function(a,y,x){this.Nb.cd(a,new Qe(y,x))},we.Kz=function(a,y){this.Nb.Gb(a,y)},we.m=function(a,y,x){this.Nb.Gb(a,new Qe(y,x))},we.ne=function(a){this.Nb.add(a)},we.yf=function(a,y){this.Nb.add(new Qe(a,y))},we.pv=function(a){this.Nb.mb(a)},we.Fj=function(){this.Nb.clear()};function bd(a,y,x){if(y!==0||x!==0)if(a.pointsCount===0)a.defaultFromPoint&&a.defaultFromPoint.offset(y,x),a.defaultToPoint&&a.defaultToPoint.offset(y,x);else{for(var E=a.fd,b=new An,z=a.Nb.iterator;z.next();){var ee=z.value;b.add(new Qe(ee.x+y,ee.y+x).freeze())}b.freeze(),z=a.Nb,a.Nb=b,ee=a.diagram,isNaN(y)||isNaN(x)||ee!==null&&ee.animationManager.zb?a.v():(a.ke.h(a.ke.x+y,a.ke.y+x),a.pa.h(a.pa.x+y,a.pa.y+x),yu(a)),E?Ym(a):(a.defaultFromPoint&&(a.defaultFromPoint=a.i(0)),a.defaultToPoint&&(a.defaultToPoint=a.i(a.pointsCount-1))),ee!==null&&ee.animationManager.zb&&rr(ee.animationManager,a,b),a.g("points",z,b)}}we.uh=function(){this.Mg===null&&(this.Mg=this.Nb,this.Nb=this.Nb.copy())},we.zf=function(){if(this.Mg!==null){for(var a=this.Mg,y=this.Nb,x=1/0,E=1/0,b=a.s,z=b.length,ee=0;ee<z;ee++){var re=b[ee];x=Math.min(re.x,x),E=Math.min(re.y,E)}re=ee=1/0;for(var oe=y.s,se=oe.length,ue=0;ue<se;ue++){var fe=oe[ue];ee=Math.min(fe.x,ee),re=Math.min(fe.y,re),fe.freeze()}if(y.freeze(),se===z){for(z=0;z<se;z++)if(ue=b[z],fe=oe[z],ue.x-x!==fe.x-ee||ue.y-E!==fe.y-re){this.qc();break}}else this.qc();this.Mg=null,x=this.diagram,x!==null&&x.animationManager.zb&&rr(x.animationManager,this,y),Ym(this),this.g("points",a,y)}},we.rv=function(){this.Mg!==null&&(this.Nb=this.Mg,this.Mg=null)};function Ym(a){a.Nb.count===0?a.fd=!1:(a.fd=!0,a.cq=null,a.vt=NaN,a.defaultFromPoint=a.i(0),a.defaultToPoint=a.i(a.pointsCount-1),qm(a,!1))}we.bb=function(){if(!this.suspendsRouting){var a=this.diagram;if(a){if(a.As.contains(this)||a.undoManager.isUndoingRedoing||(a=a.animationManager,a.isTicking&&!a.isAnimating))return;this.Tg===null||a.isTicking||(this.Tg=null)}a=this.path,a!==null&&(this.fd=!1,this.v(),a.v())}},we.vg=function(){if(!this.fd&&!this.computingPoints){var a=!0;try{this.computingPoints=!0,this.uh(),a=this.computePoints()}catch(y){this.computingPoints=!1,this.rv()}finally{this.computingPoints=!1,a?this.zf():this.rv()}}},Tn.prototype.computePoints=function(){if(this.diagram===null)return!1;var a=this.fromNode,y=null;if(a===null?(Uf||(Uf=new qn,Uf.desiredSize=jr,Uf.Va()),this.defaultFromPoint&&(Uf.location=this.defaultFromPoint,Uf.Va(),y=a=Uf)):y=this.fromPort,y!==null&&!a.isVisible()){var x=a.findVisibleNode();x!==null&&x!==a?(a=x,y=x.port):a=x}if(this.Lw=a,a===null||!a.location.w())return!1;for(;!(y===null||y.actualBounds.w()&&y.Ed());)y=y.panel;if(y===null)return!1;var E=this.toNode,b=null;if(E===null?(Zf||(Zf=new qn,Zf.desiredSize=jr,Zf.Va()),this.defaultToPoint&&(Zf.location=this.defaultToPoint,Zf.Va(),b=E=Zf)):b=this.toPort,b===null||E.isVisible()||(x=E.findVisibleNode(),x!==null&&x!==E?(E=x,b=x.port):E=x),this.Mw=E,E===null||!E.location.w())return!1;for(;!(b===null||b.actualBounds.w()&&b.Ed());)b=b.panel;if(b===null)return!1;var z=this.pointsCount,ee=this.computeSpot(!0,y);x=this.computeSpot(!1,b);var re=Fg(ee),oe=Fg(x),se=y===b&&y!==null,ue=this.isOrthogonal,fe=this.curve===vh;this.Wf=se&&!ue?fe=!0:!1;var ve=this.computeAdjusting()===Pu||se;if(!ue&&!se&&re&&oe){if(re=!1,!ve&&3<=z&&(ve=this.getLinkPoint(a,y,ee,!0,!1,E,b),oe=this.getLinkPoint(E,b,x,!1,!1,a,y),re=this.adjustPoints(0,ve,z-1,oe))&&(ve=this.getLinkPoint(a,y,ee,!0,!1,E,b),oe=this.getLinkPoint(E,b,x,!1,!1,a,y),this.adjustPoints(0,ve,z-1,oe)),!re)if(this.Fj(),fe){z=this.getLinkPoint(a,y,ee,!0,!1,E,b),ve=this.getLinkPoint(E,b,x,!1,!1,a,y),re=ve.x-z.x,oe=ve.y-z.y,se=this.computeCurviness(),fe=ue=0;var ye=z.x+re/3,Ce=z.y+oe/3,Ae=ye,Ye=Ce;yt.B(oe,0)?Ye=0<re?Ye-se:Ye+se:(ue=-re/oe,fe=Math.sqrt(se*se/(ue*ue+1)),0>se&&(fe=-fe),Ae=(0>oe?-1:1)*fe+ye,Ye=ue*(Ae-ye)+Ce),ye=z.x+2*re/3,Ce=z.y+2*oe/3;var We=ye,tt=Ce;yt.B(oe,0)?tt=0<re?tt-se:tt+se:(We=(0>oe?-1:1)*fe+ye,tt=ue*(We-ye)+Ce),this.Fj(),this.ne(z),this.yf(Ae,Ye),this.yf(We,tt),this.ne(ve),this.dd(0,this.getLinkPoint(a,y,ee,!0,!1,E,b)),this.dd(3,this.getLinkPoint(E,b,x,!1,!1,a,y))}else z=E,ve=b,E=this.getLinkPoint(a,y,ee,!0,!1,z,ve),b=this.getLinkPoint(z,ve,x,!1,!1,a,y),this.hasCurviness()?(ve=b.x-E.x,x=b.y-E.y,ee=this.computeCurviness(),a=E.x+ve/2,y=E.y+x/2,z=a,re=y,yt.B(x,0)?re=0<ve?re-ee:re+ee:(ve=-ve/x,z=Math.sqrt(ee*ee/(ve*ve+1)),0>ee&&(z=-z),z=(0>x?-1:1)*z+a,re=ve*(z-a)+y),this.ne(E),this.yf(z,re),this.ne(b)):(this.ne(E),this.ne(b),re=Xt.alloc(),y.mi(re),oe=re.ca(b),ve.mi(re),se=re.ca(E),(oe||se)&&(ee=y.ga(Jm(ee),new Qe),this.dd(0,this.getLinkPointFromPoint(a,y,ee,b,!0,ee)),x=ve.ga(Jm(x),new Qe),this.dd(1,this.getLinkPointFromPoint(z,ve,x,E,!1,x))),Xt.free(re))}else{fe=this.isAvoiding,ve&&(ue&&fe||se)&&this.Fj();var rt=se?this.computeCurviness():0;fe=this.getLinkPoint(a,y,ee,!0,ue,E,b),ye=Ae=Ce=0,(ue||!re||se)&&(Ye=this.computeEndSegmentLength(a,y,ee,!0),ye=this.getLinkDirection(a,y,fe,ee,!0,ue,E,b),se&&(re||ee.D(x)||!ue&&ee.x+x.x===1&&ee.y+x.y===1)&&(ye-=ue?90:30,0>rt&&(ye-=180)),0>ye?ye+=360:360<=ye&&(ye-=360),se&&(Ye+=Math.abs(rt)*(ue?1:2)),ye===0?Ce=Ye:ye===90?Ae=Ye:ye===180?Ce=-Ye:ye===270?Ae=-Ye:(Ce=Ye*Math.cos(ye*Math.PI/180),Ae=Ye*Math.sin(ye*Math.PI/180)),ee.Mc()&&se&&(Ye=y.ga(ko,Qe.alloc()),We=Qe.allocAt(Ye.x+1e3*Ce,Ye.y+1e3*Ae),this.getLinkPointFromPoint(a,y,Ye,We,!0,fe),Qe.free(Ye),Qe.free(We))),Ye=this.getLinkPoint(E,b,x,!1,ue,a,y);var at=tt=We=0;if(ue||!oe||se){var gt=this.computeEndSegmentLength(E,b,x,!1);at=this.getLinkDirection(E,b,Ye,x,!1,ue,a,y),se&&(oe||ee.D(x)||!ue&&ee.x+x.x===1&&ee.y+x.y===1)&&(at+=ue?0:30,0>rt&&(at+=180)),0>at?at+=360:360<=at&&(at-=360),se&&(gt+=Math.abs(rt)*(ue?1:2)),at===0?We=gt:at===90?tt=gt:at===180?We=-gt:at===270?tt=-gt:(We=gt*Math.cos(at*Math.PI/180),tt=gt*Math.sin(at*Math.PI/180)),x.Mc()&&se&&(x=b.ga(ko,Qe.alloc()),ee=Qe.allocAt(x.x+1e3*We,x.y+1e3*tt),this.getLinkPointFromPoint(E,b,x,ee,!1,Ye),Qe.free(x),Qe.free(ee))}x=fe,(ue||!re||se)&&(x=new Qe(fe.x+Ce,fe.y+Ae)),ee=Ye,(ue||!oe||se)&&(ee=new Qe(Ye.x+We,Ye.y+tt)),!ve&&!ue&&re&&3<z&&this.adjustPoints(0,fe,z-2,ee)?this.dd(z-1,Ye):!ve&&!ue&&oe&&3<z&&this.adjustPoints(1,x,z-1,Ye)?this.dd(0,fe):!ve&&(ue?6<=z:4<z)&&this.adjustPoints(1,x,z-2,ee)?(this.dd(0,fe),this.dd(z-1,Ye)):(this.Fj(),this.ne(fe),(ue||!re||se)&&this.ne(x),ue&&this.addOrthoPoints(x,ye,ee,at,a,E),(ue||!oe||se)&&this.ne(ee),this.ne(Ye))}return!0};function Z0(a,y){return Math.abs(y.x-a.x)>Math.abs(y.y-a.y)?(y.x>=a.x?y.x=a.x+9e9:y.x=a.x-9e9,y.y=a.y):(y.y>=a.y?y.y=a.y+9e9:y.y=a.y-9e9,y.x=a.x),y}Tn.prototype.getLinkPointFromPoint=function(a,y,x,E,b,z){if(z===void 0&&(z=new Qe),a===null||y===null)return z.assign(x),z;if(a.isVisible()||(b=a.findVisibleNode(),b!==null&&b!==a&&(y=b.port)),a=null,b=y.panel,b===null||b.se()||(b=b.panel),b===null){b=E.x,E=E.y;var ee=x.x;x=x.y}else{a=b.oe,b=1/(a.m11*a.m22-a.m12*a.m21),ee=a.m22*b;var re=-a.m12*b,oe=-a.m21*b,se=a.m11*b,ue=b*(a.m21*a.dy-a.m22*a.dx),fe=b*(a.m12*a.dx-a.m11*a.dy);b=E.x*ee+E.y*oe+ue,E=E.x*re+E.y*se+fe,ee=x.x*ee+x.y*oe+ue,x=x.x*re+x.y*se+fe}return y.Sj(b,E,ee,x,z),a!==null&&z.transform(a),z};function Xm(a,y){var x=y.Zn;return x===null&&(x=new _f,x.port=y,x.node=y.part,y.Zn=x),s1(x,a)}Tn.prototype.getLinkPoint=function(a,y,x,E,b,z,ee,re){if(re===void 0&&(re=new Qe),x.sb()&&!Fg(x))return y.ga(x,re),re;if(x.$c()){var oe=Xm(this,y);if(oe!==null){if(re.assign(oe.Zo),b&&this.routing===t1){var se=Xm(this,ee);if(se!==null&&oe.Gl<se.Gl){oe=Qe.alloc(),se=Qe.alloc();var ue=new Xt(y.ga(Cs,oe),y.ga(Hl,se)),fe=this.computeSpot(!E,ee);a=this.getLinkPoint(z,ee,fe,!E,b,a,y,se),(x.Hf(ec)||x.Hf(Dl))&&a.y>=ue.y&&a.y<=ue.y+ue.height?re.y=a.y:(x.Hf(Eh)||x.Hf(ru))&&a.x>=ue.x&&a.x<=ue.x+ue.width&&(re.x=a.x),Qe.free(oe),Qe.free(se)}}return re}}return x=y.ga(Jm(x),Qe.alloc()),this.pointsCount>(b?6:2)?(ee=E?this.i(1):this.i(this.pointsCount-2),b&&(ee=Z0(x,ee.copy()))):(oe=this.computeSpot(!E,ee),z=Qe.alloc(),ee=ee.ga(Jm(oe),z),b&&(ee=Z0(x,ee)),Qe.free(z)),this.getLinkPointFromPoint(a,y,x,ee,E,re),Qe.free(x),re},Tn.prototype.getLinkDirection=function(a,y,x,E,b,z,ee,re){e:if(E.sb())var oe=E.x>E.y?E.x>1-E.y?0:E.x<1-E.y?270:315:E.x<E.y?E.x>1-E.y?90:E.x<1-E.y?180:135:.5>E.x?225:.5<E.x?45:0;else{if(E.$c()&&(oe=Xm(this,y),oe!==null))switch(oe.Nc){case 1:oe=270;break e;case 2:oe=180;break e;default:case 4:oe=0;break e;case 8:oe=90;break e}oe=y.ga(ko,Qe.alloc()),this.pointsCount>(z?6:2)?(re=b?this.i(1):this.i(this.pointsCount-2),re=z?Z0(oe,re.copy()):x):(x=Qe.alloc(),re=re.ga(ko,x),Qe.free(x)),x=Math.abs(re.x-oe.x)>Math.abs(re.y-oe.y)?re.x>=oe.x?0:180:re.y>=oe.y?90:270,Qe.free(oe),oe=x}return E.Mc()&&ee.Td(a)&&(oe+=180,360<=oe&&(oe-=360)),Fg(E)||(a=y.li(),a===0)||(45<=a&&135>a?oe+=90:135<=a&&225>a?oe+=180:225<=a&&315>a&&(oe+=270),360<=oe&&(oe-=360)),oe},Tn.prototype.computeEndSegmentLength=function(a,y,x,E){return y!==null&&x.$c()&&(a=Xm(this,y),a!==null)?a.Ju:(a=E?this.fromEndSegmentLength:this.toEndSegmentLength,y!==null&&isNaN(a)&&(a=E?y.fromEndSegmentLength:y.toEndSegmentLength),isNaN(a)&&(a=10),a)},Tn.prototype.computeSpot=function(a,y){return y===void 0&&(y=null),a?(a=y||this.fromPort,a===null?a=ko:(y=this.fromSpot,y.Xb()&&(y=a.fromSpot),a=y===vs?Ms:y)):(a=y||this.toPort,a===null?a=ko:(y=this.toSpot,y.Xb()&&(y=a.toSpot),a=y===vs?Ms:y)),a};function Fg(a){return a===Ms||a.x===.5&&a.y===.5}function Jm(a){return a.x===.5&&a.y===.5?a:ko}Tn.prototype.computeOtherPoint=function(a,y){return this.computeAdjusting()!==Pu&&4<this.pointsCount?this.computeMidPoint(new Qe):(a=y.Zn,a=a!==null?s1(a,this):null,a!==null?a.Zo:y.ga(ko))},Tn.prototype.computeShortLength=function(a){if(a){if(a=this.fromShortLength,isNaN(a)){var y=this.fromPort;y!==null&&(a=y.fromShortLength)}return isNaN(a)?0:a}return a=this.toShortLength,isNaN(a)&&(y=this.toPort,y!==null&&(a=y.toShortLength)),isNaN(a)?0:a},Tn.prototype.Cf=function(a,y,x,E,b,z){if(this.pickable===!1)return!1;y===void 0&&(y=null),x===void 0&&(x=null);var ee=z;if(z===void 0&&(ee=kr.alloc(),ee.reset()),ee.multiply(this.transform),this.fh(a,ee))return m0(this,y,x,b),z===void 0&&kr.free(ee),!0;if(this.Yc(a,ee)){var re=!1;if(!this.isAtomic)for(var oe=this.O.s,se=oe.length;se--;){var ue=oe[se];if(ue.visible||ue===this.locationObject){var fe=ue.actualBounds,ve=this.naturalBounds;if(!(fe.x>ve.width||fe.y>ve.height||0>fe.x+fe.width||0>fe.y+fe.height)){if(fe=kr.alloc(),fe.set(ee),ue instanceof Ln)re=ue.Cf(a,y,x,E,b,fe);else if(this.path===ue){if(ue instanceof Dr)if(re=a,ve=E,ue.pickable===!1)re=!1;else if(fe.multiply(ue.transform),ve)e:{var ye=re,Ce=fe;if(ue.fh(ye,Ce))re=!0;else{if(Ce===void 0&&(Ce=ue.transform,ye.Re(ue.actualBounds))){re=!0;break e}re=ye.left,ve=ye.right;var Ae=ye.top;ye=ye.bottom;var Ye=Qe.alloc(),We=Qe.alloc(),tt=Qe.alloc(),rt=kr.alloc();rt.set(Ce),rt.bv(ue.transform),rt.Vj(),We.x=ve,We.y=Ae,We.transform(rt),Ye.x=re,Ye.y=Ae,Ye.transform(rt),Ce=!1,wf(ue,Ye,We,tt)?Ce=!0:(Ye.x=ve,Ye.y=ye,Ye.transform(rt),wf(ue,Ye,We,tt)?Ce=!0:(We.x=re,We.y=ye,We.transform(rt),wf(ue,Ye,We,tt)?Ce=!0:(Ye.x=re,Ye.y=Ae,Ye.transform(rt),wf(ue,Ye,We,tt)&&(Ce=!0)))),kr.free(rt),Qe.free(Ye),Qe.free(We),Qe.free(tt),re=Ce}}else re=ue.fh(re,fe)}else re=fl(ue,a,E,fe);re&&(ve=ue,y!==null&&(ve=y(ue)),ve&&(x===null||x(ve))&&b.add(ve)),kr.free(fe)}}}return z===void 0&&kr.free(ee),re||this.background!==null||this.areaBackground!==null}return z===void 0&&kr.free(ee),!1},Tn.prototype.computeCurve=function(){if(this.Wf===null){var a=this.fromPort,y=this.isOrthogonal;this.Wf=a!==null&&a===this.toPort&&!y}return this.Wf?vh:this.curve},Tn.prototype.computeCorner=function(){if(this.curve===vh)return 0;var a=this.corner;return(isNaN(a)||0>a)&&(a=10),a},Tn.prototype.findMidLabel=function(){for(var a=this.path,y=this.O.s,x=y.length,E=0;E<x;E++){var b=y[E];if(b!==a&&!b.isPanelMain&&(b.segmentIndex===-1/0||isNaN(b.segmentIndex)))return b}for(a=this.labelNodes;a.next();)if(y=a.value,y.segmentIndex===-1/0||isNaN(y.segmentIndex))return y;return null},Tn.prototype.computeSpacing=function(){if(!this.isVisible())return 0;var a=i1;a=Math.max(a,this.computeThickness());var y=this.fromPort,x=this.toPort;if(y!==null&&x!==null){var E=this.findMidLabel();if(E!==null){var b=E.naturalBounds,z=E.margin,ee=isNaN(b.width)?30:b.width*E.scale+z.left+z.right;b=isNaN(b.height)?14:b.height*E.scale+z.top+z.bottom,E=E.segmentOrientation,E===Ep||E===tv||E===Q0?a=Math.max(a,b):E===Lp||E===kp||E===bp||E===Mp?a=Math.max(a,ee):(y=y.ga(ko).ab(x.ga(ko))/180*Math.PI,a=Math.max(a,Math.abs(Math.sin(y)*ee)+Math.abs(Math.cos(y)*b)+1)),this.curve===vh&&(a*=1.333)}}return a},Tn.prototype.arrangeBundledLinks=function(a,y){if(y)for(y=0;y<a.length;y++){var x=a[y];x.computeAdjusting()===Pu&&x.bb()}},Tn.prototype.computeCurviness=function(){var a=this.curviness;if(isNaN(a)){a=n1;var y=this.Sf;if(y!==null){for(var x=qi(),E=0,b=y.links,z=0;z<b.length;z++){var ee=b[z].computeSpacing();x.push(ee),E+=ee}for(E=-E/2,z=0;z<b.length;z++){if(b[z]===this){a=E+x[z]/2;break}E+=x[z]}y.Ds===this.fromNode&&(a=-a),Zi(x)}}return a},Tn.prototype.computeThickness=function(){if(!this.isVisible())return 0;var a=this.path;return a!==null?Math.max(a.strokeWidth,1):1},Tn.prototype.hasCurviness=function(){return!isNaN(this.curviness)||this.Sf!==null},Tn.prototype.adjustPoints=function(a,y,x,E){var b=this.computeAdjusting();if(this.isOrthogonal){if(b===$m)return!1;b===ev&&(b=Cp)}switch(b){case $m:var z=this.i(a),ee=this.i(x);if(!z.Xa(y)||!ee.Xa(E)){b=z.x,z=z.y;var re=ee.x-b,oe=ee.y-z,se=Math.sqrt(re*re+oe*oe);if(!yt.$(se,0)){if(yt.$(re,0))var ue=0>oe?-Math.PI/2:Math.PI/2;else ue=Math.atan(oe/Math.abs(re)),0>re&&(ue=Math.PI-ue);ee=y.x;var fe=y.y;re=E.x-ee;var ve=E.y-fe;for(oe=Math.sqrt(re*re+ve*ve),yt.$(re,0)?ve=0>ve?-Math.PI/2:Math.PI/2:(ve=Math.atan(ve/Math.abs(re)),0>re&&(ve=Math.PI-ve)),se=oe/se,ue=ve-ue,this.dd(a,y),a+=1;a<x;a++)y=this.i(a),re=y.x-b,oe=y.y-z,y=Math.sqrt(re*re+oe*oe),yt.$(y,0)||(yt.$(re,0)?oe=0>oe?-Math.PI/2:Math.PI/2:(oe=Math.atan(oe/Math.abs(re)),0>re&&(oe=Math.PI-oe)),re=oe+ue,y*=se,this.L(a,ee+y*Math.cos(re),fe+y*Math.sin(re)));this.dd(x,E)}}return!0;case ev:if(z=this.i(a),fe=this.i(x),!z.Xa(y)||!fe.Xa(E)){b=z.x,z=z.y,ee=fe.x,fe=fe.y,se=(ee-b)*(ee-b)+(fe-z)*(fe-z),re=y.x,ue=y.y,oe=E.x,ve=E.y;var ye=1;if(oe-re!==0){var Ce=(ve-ue)/(oe-re);ye=Math.sqrt(1+1/(Ce*Ce))}else Ce=9e9;for(this.dd(a,y),a+=1;a<x;a++){y=this.i(a);var Ae=y.x,Ye=y.y,We=.5;se!==0&&(We=((b-Ae)*(b-ee)+(z-Ye)*(z-fe))/se);var tt=b+We*(ee-b),rt=z+We*(fe-z);y=Math.sqrt((Ae-tt)*(Ae-tt)+(Ye-rt)*(Ye-rt)),Ye<Ce*(Ae-tt)+rt&&(y=-y),0<Ce&&(y=-y),Ae=re+We*(oe-re),We=ue+We*(ve-ue),Ce!==0?(y=Ae+y/ye,this.L(a,y,We-(y-Ae)/Ce)):this.L(a,Ae,We+y)}this.dd(x,E)}return!0;case Cp:e:{if(this.isOrthogonal&&(b=this.i(a),z=this.i(a+1),ee=this.i(a+2),re=z.x,ue=z.y,fe=re,se=ue,yt.B(b.y,z.y)?yt.B(z.x,ee.x)?ue=y.y:yt.B(z.y,ee.y)&&(re=y.x):yt.B(b.x,z.x)&&(yt.B(z.y,ee.y)?re=y.x:yt.B(z.x,ee.x)&&(ue=y.y)),this.L(a+1,re,ue),b=this.i(x),z=this.i(x-1),ee=this.i(x-2),re=z.x,ue=z.y,oe=re,ve=ue,yt.B(b.y,z.y)?yt.B(z.x,ee.x)?ue=E.y:yt.B(z.y,ee.y)&&(re=E.x):yt.B(b.x,z.x)&&(yt.B(z.y,ee.y)?re=E.x:yt.B(z.x,ee.x)&&(ue=E.y)),this.L(x-1,re,ue),_0(this))){this.L(a+1,fe,se),this.L(x-1,oe,ve),x=!1;break e}this.dd(a,y),this.dd(x,E),x=!0}return x;default:return!1}},Tn.prototype.addOrthoPoints=function(a,y,x,E,b,z){0>y?y+=360:360<=y&&(y-=360),0>E?E+=360:360<=E&&(E-=360);var ee=E;y=315<=y||45>y?0:45<=y&&135>y?90:135<=y&&225>y?180:270,E=315<=E||45>E?0:45<=E&&135>E?90:135<=E&&225>E?180:270;var re=b.actualBounds.copy(),oe=z.actualBounds.copy();if(re.w()&&oe.w()){re.Bc(Fp,Fp),oe.Bc(Fp,Fp),re.Ye(a),oe.Ye(x);var se=Qe.alloc(),ue=Qe.alloc();y===0?x.x>a.x||E===270&&x.y<a.y&&oe.right>a.x||E===90&&x.y>a.y&&oe.right>a.x?(se.h(x.x,a.y),ue.h(x.x,(a.y+x.y)/2),E===180?(se.x=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1),ue.x=se.x,ue.y=x.y):E===270&&x.y<a.y||E===90&&x.y>a.y?(se.x=a.x<oe.left?this.computeMidOrthoPosition(a.x,a.y,oe.left,x.y,!1):a.x<oe.right&&(E===270&&a.y<oe.top||E===90&&a.y>oe.bottom)?this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1):oe.right,ue.x=se.x,ue.y=x.y):E===0&&a.x<oe.left&&a.y>oe.top&&a.y<oe.bottom&&(se.x=a.x,se.y=a.y<x.y?Math.min(x.y,oe.top):Math.max(x.y,oe.bottom),ue.y=se.y)):(se.h(a.x,x.y),ue.h((a.x+x.x)/2,x.y),(E===180||E===90&&x.y<re.top||E===270&&x.y>re.bottom)&&(E===180&&(oe.ca(a)||re.ca(x))?se.y=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0):x.y<a.y&&(E===180||E===90)?se.y=this.computeMidOrthoPosition(a.x,re.top,x.x,Math.max(x.y,oe.bottom),!0):x.y>a.y&&(E===180||E===270)&&(se.y=this.computeMidOrthoPosition(a.x,re.bottom,x.x,Math.min(x.y,oe.top),!0)),ue.x=x.x,ue.y=se.y),se.y>re.top&&se.y<re.bottom&&(x.x>=re.left&&x.x<=a.x||a.x<=oe.right&&a.x>=x.x?(E===90||E===270)&&(se.h(Math.max((a.x+x.x)/2,a.x),a.y),ue.h(se.x,x.y)):(se.y=E===270||(E===0||E===180)&&x.y<a.y?Math.min(x.y,E===0?re.top:Math.min(re.top,oe.top)):Math.max(x.y,E===0?re.bottom:Math.max(re.bottom,oe.bottom)),ue.x=x.x,ue.y=se.y))):y===180?x.x<a.x||E===270&&x.y<a.y&&oe.left<a.x||E===90&&x.y>a.y&&oe.left<a.x?(se.h(x.x,a.y),ue.h(x.x,(a.y+x.y)/2),E===0?(se.x=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1),ue.x=se.x,ue.y=x.y):E===270&&x.y<a.y||E===90&&x.y>a.y?(se.x=a.x>oe.right?this.computeMidOrthoPosition(a.x,a.y,oe.right,x.y,!1):a.x>oe.left&&(E===270&&a.y<oe.top||E===90&&a.y>oe.bottom)?this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1):oe.left,ue.x=se.x,ue.y=x.y):E===180&&a.x>oe.right&&a.y>oe.top&&a.y<oe.bottom&&(se.x=a.x,se.y=a.y<x.y?Math.min(x.y,oe.top):Math.max(x.y,oe.bottom),ue.y=se.y)):(se.h(a.x,x.y),ue.h((a.x+x.x)/2,x.y),(E===0||E===90&&x.y<re.top||E===270&&x.y>re.bottom)&&(E===0&&(oe.ca(a)||re.ca(x))?se.y=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0):x.y<a.y&&(E===0||E===90)?se.y=this.computeMidOrthoPosition(a.x,re.top,x.x,Math.max(x.y,oe.bottom),!0):x.y>a.y&&(E===0||E===270)&&(se.y=this.computeMidOrthoPosition(a.x,re.bottom,x.x,Math.min(x.y,oe.top),!0)),ue.x=x.x,ue.y=se.y),se.y>re.top&&se.y<re.bottom&&(x.x<=re.right&&x.x>=a.x||a.x>=oe.left&&a.x<=x.x?(E===90||E===270)&&(se.h(Math.min((a.x+x.x)/2,a.x),a.y),ue.h(se.x,x.y)):(se.y=E===270||(E===0||E===180)&&x.y<a.y?Math.min(x.y,E===180?re.top:Math.min(re.top,oe.top)):Math.max(x.y,E===180?re.bottom:Math.max(re.bottom,oe.bottom)),ue.x=x.x,ue.y=se.y))):y===90?x.y>a.y||E===180&&x.x<a.x&&oe.bottom>a.y||E===0&&x.x>a.x&&oe.bottom>a.y?(se.h(a.x,x.y),ue.h((a.x+x.x)/2,x.y),E===270?(se.y=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0),ue.x=x.x,ue.y=se.y):E===180&&x.x<a.x||E===0&&x.x>a.x?(se.y=a.y<oe.top?this.computeMidOrthoPosition(a.x,a.y,x.x,oe.top,!0):a.y<oe.bottom&&(E===180&&a.x<oe.left||E===0&&a.x>oe.right)?this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0):oe.bottom,ue.x=x.x,ue.y=se.y):E===90&&a.y<oe.top&&a.x>oe.left&&a.x<oe.right&&(se.x=a.x<x.x?Math.min(x.x,oe.left):Math.max(x.x,oe.right),se.y=a.y,ue.x=se.x)):(se.h(x.x,a.y),ue.h(x.x,(a.y+x.y)/2),(E===270||E===0&&x.x<re.left||E===180&&x.x>re.right)&&(E===270&&(oe.ca(a)||re.ca(x))?se.x=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1):x.x<a.x&&(E===270||E===0)?se.x=this.computeMidOrthoPosition(re.left,a.y,Math.max(x.x,oe.right),x.y,!1):x.x>a.x&&(E===270||E===180)&&(se.x=this.computeMidOrthoPosition(re.right,a.y,Math.min(x.x,oe.left),x.y,!1)),ue.x=se.x,ue.y=x.y),se.x>re.left&&se.x<re.right&&(x.y>=re.top&&x.y<=a.y||a.y<=oe.bottom&&a.y>=x.y?(E===0||E===180)&&(se.h(a.x,Math.max((a.y+x.y)/2,a.y)),ue.h(x.x,se.y)):(se.x=E===180||(E===90||E===270)&&x.x<a.x?Math.min(x.x,E===90?re.left:Math.min(re.left,oe.left)):Math.max(x.x,E===90?re.right:Math.max(re.right,oe.right)),ue.x=se.x,ue.y=x.y))):x.y<a.y||E===180&&x.x<a.x&&oe.top<a.y||E===0&&x.x>a.x&&oe.top<a.y?(se.h(a.x,x.y),ue.h((a.x+x.x)/2,x.y),E===90?(se.y=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0),ue.x=x.x,ue.y=se.y):E===180&&x.x<a.x||E===0&&x.x>=a.x?(se.y=a.y>oe.bottom?this.computeMidOrthoPosition(a.x,a.y,x.x,oe.bottom,!0):a.y>oe.top&&(E===180&&a.x<oe.left||E===0&&a.x>oe.right)?this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0):oe.top,ue.x=x.x,ue.y=se.y):E===270&&a.y>oe.bottom&&a.x>oe.left&&a.x<oe.right&&(se.x=a.x<x.x?Math.min(x.x,oe.left):Math.max(x.x,oe.right),se.y=a.y,ue.x=se.x)):(se.h(x.x,a.y),ue.h(x.x,(a.y+x.y)/2),(E===90||E===0&&x.x<re.left||E===180&&x.x>re.right)&&(E===90&&(oe.ca(a)||re.ca(x))?se.x=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1):x.x<a.x&&(E===90||E===0)?se.x=this.computeMidOrthoPosition(re.left,a.y,Math.max(x.x,oe.right),x.y,!1):x.x>a.x&&(E===90||E===180)&&(se.x=this.computeMidOrthoPosition(re.right,a.y,Math.min(x.x,oe.left),x.y,!1)),ue.x=se.x,ue.y=x.y),se.x>re.left&&se.x<re.right&&(x.y<=re.bottom&&x.y>=a.y||a.y>=oe.top&&a.y<=x.y?(E===0||E===180)&&(se.h(a.x,Math.min((a.y+x.y)/2,a.y)),ue.h(x.x,se.y)):(se.x=E===180||(E===90||E===270)&&x.x<a.x?Math.min(x.x,E===270?re.left:Math.min(re.left,oe.left)):Math.max(x.x,E===270?re.right:Math.max(re.right,oe.right)),ue.x=se.x,ue.y=x.y)));var fe=x;if(this.isAvoiding){var ve=this.diagram;if(ve===null||b===z||this.layer.isTemporary||!ug(ve)||re.ca(fe)&&!z.Td(b)||oe.ca(a)&&!b.Td(z))y=!1;else{var ye=hg(ve,!0,this.containingGroup,null);if(this.segmentIndex!==17&&ye.Yj(Math.min(a.x,se.x),Math.min(a.y,se.y),Math.abs(a.x-se.x),Math.abs(a.y-se.y))&&ye.Yj(Math.min(se.x,ue.x),Math.min(se.y,ue.y),Math.abs(se.x-ue.x),Math.abs(se.y-ue.y))&&ye.Yj(Math.min(ue.x,fe.x),Math.min(ue.y,fe.y),Math.abs(ue.x-fe.x),Math.abs(ue.y-fe.y)))y=!1;else{b=a,z=fe;var Ce=x=null;if(ve.isVirtualized){ve=ye.bounds.copy(),ve.Bc(-ye.Ho,-ye.Go);var Ae=Qe.alloc();Ng(ye,a.x,a.y)||(yt.Ff(ve.x,ve.y,ve.x+ve.width,ve.y+ve.height,a.x,a.y,se.x,se.y,Ae)?(x=a=Ae.copy(),y=Ae.ab(se)):yt.Ff(ve.x,ve.y,ve.x+ve.width,ve.y+ve.height,se.x,se.y,ue.x,ue.y,Ae)?(x=a=Ae.copy(),y=Ae.ab(ue)):yt.Ff(ve.x,ve.y,ve.x+ve.width,ve.y+ve.height,ue.x,ue.y,fe.x,fe.y,Ae)&&(x=a=Ae.copy(),y=Ae.ab(fe))),Ng(ye,fe.x,fe.y)||(yt.Ff(ve.x,ve.y,ve.x+ve.width,ve.y+ve.height,fe.x,fe.y,ue.x,ue.y,Ae)?(Ce=fe=Ae.copy(),E=ue.ab(Ae)):yt.Ff(ve.x,ve.y,ve.x+ve.width,ve.y+ve.height,ue.x,ue.y,se.x,se.y,Ae)?(Ce=fe=Ae.copy(),E=se.ab(Ae)):yt.Ff(ve.x,ve.y,ve.x+ve.width,ve.y+ve.height,se.x,se.y,a.x,a.y,Ae)&&(Ce=fe=Ae.copy(),E=a.ab(Ae))),Qe.free(Ae)}re=re.copy().ed(oe),re.Bc(ye.Ho*ye.Os,ye.Go*ye.Os),o1(ye,a,y,fe,E,re,!0),oe=Uc(ye,fe.x,fe.y),!ye.abort&&oe>=Tg&&(r1(ye),re.Bc(ye.Ho*ye.Hx,ye.Go*ye.Ix),o1(ye,a,y,fe,E,re,!1),oe=Uc(ye,fe.x,fe.y)),!ye.abort&&oe<Tg&&Uc(ye,fe.x,fe.y)!==Md?(Y0(this,ye,fe.x,fe.y,E,!0,ee),re=this.i(2),4>this.pointsCount?(y===0||y===180?(re.x=a.x,re.y=fe.y):(re.x=fe.x,re.y=a.y),this.L(2,re.x,re.y),this.m(3,re.x,re.y)):(ee=this.i(3),y===0||y===180?yt.B(re.x,ee.x)?(re=y===0?Math.max(re.x,a.x):Math.min(re.x,a.x),this.L(2,re,a.y),this.L(3,re,ee.y)):yt.B(re.y,ee.y)?(Math.abs(a.y-re.y)<=ye.Go/2&&(this.L(2,re.x,a.y),this.L(3,ee.x,a.y)),this.m(2,re.x,a.y)):this.L(2,a.x,re.y):(y===90||y===270)&&(yt.B(re.y,ee.y)?(re=y===90?Math.max(re.y,a.y):Math.min(re.y,a.y),this.L(2,a.x,re),this.L(3,ee.x,re)):yt.B(re.x,ee.x)?(Math.abs(a.x-re.x)<=ye.Ho/2&&(this.L(2,a.x,re.y),this.L(3,a.x,ee.y)),this.m(2,a.x,re.y)):this.L(2,re.x,a.y))),x!==null&&(a=this.i(1),ee=this.i(2),a.x!==ee.x&&a.y!==ee.y?y===0||y===180?this.m(2,a.x,ee.y):this.m(2,ee.x,a.y):y===0||y===180?this.m(2,b.x,x.y):this.m(2,x.x,b.y)),Ce!==null&&(E===0||E===180?this.yf(z.x,Ce.y):this.yf(Ce.x,z.y)),y=!0):y=!1}}}else y=!1;y||(this.ne(se.copy()),this.ne(ue.copy())),Qe.free(se),Qe.free(ue)}},Tn.prototype.computeMidOrthoPosition=function(a,y,x,E,b){var z=0;return!this.hasCurviness()||this.computeSpot(!0,this.fromPort).$c()||this.computeSpot(!1,this.toPort).$c()||(z=this.computeCurviness()),b?(y+E)/2+z:(a+x)/2+z};function _0(a){if(a.diagram===null||!a.isAvoiding||!ug(a.diagram))return!1;var y=a.points.s,x=y.length;if(4>x)return!1;a=hg(a.diagram,!0,a.containingGroup,null);for(var E=1;E<x-2;E++){var b=y[E],z=y[E+1];if(!a.Yj(Math.min(b.x,z.x),Math.min(b.y,z.y),Math.abs(b.x-z.x),Math.abs(b.y-z.y)))return!0}return!1}function Y0(a,y,x,E,b,z,ee){var re=y.Ho,oe=y.Go,se=Uc(y,x,E),ue=x,fe=E;for(b===0?ue+=re:b===90?fe+=oe:b===180?ue-=re:fe-=oe,b!==ee&&se>Ef&&Uc(y,ue,fe)!==se-1&&(Uc(y,x-re,E)===se-1?(b=180,ue=x-re,fe=E):Uc(y,x+re,E)===se-1?(b=0,ue=x+re,fe=E):Uc(y,x,E-oe)===se-1?(b=270,ue=x,fe=E-oe):Uc(y,x,E+oe)===se-1&&(b=90,ue=x,fe=E+oe));se>Ef&&Uc(y,ue,fe)===se-1;)x=ue,E=fe,b===0?ue+=re:b===90?fe+=oe:b===180?ue-=re:fe-=oe,--se;z?se>Ef&&(b===180||b===0?x=Math.floor(x/re)*re+re/2:(b===90||b===270)&&(E=Math.floor(E/oe)*oe+oe/2)):(x=Math.floor(x/re)*re+re/2,E=Math.floor(E/oe)*oe+oe/2),se>Ef&&(z=b,ee=x,ue=E,b===0?(z=90,ue+=oe):b===90?(z=180,ee-=re):b===180?(z=270,ue-=oe):b===270&&(z=0,ee+=re),Uc(y,ee,ue)===se-1?Y0(a,y,ee,ue,z,!1,z):(ee=x,ue=E,b===0?(z=270,ue-=oe):b===90?(z=0,ee+=re):b===180?(z=90,ue+=oe):b===270&&(z=180,ee-=re),Uc(y,ee,ue)===se-1&&Y0(a,y,ee,ue,z,!1,z))),a.yf(x,E)}Tn.prototype.ez=function(a){var y=a.x;a=a.y;for(var x=this.i(0),E=this.i(1),b=ps(y,a,x.x,x.y,E.x,E.y),z=0,ee=1;ee<this.pointsCount-1;ee++){x=this.i(ee+1);var re=ps(y,a,E.x,E.y,x.x,x.y);E=x,re<b&&(z=ee,b=re)}return z},Tn.prototype.qc=function(){this.lk=!1,this.v()},Tn.prototype.Ul=function(a){if(!(!a&&(this.fd===!1||(a=this.Pb(),this.lk&&(a===null||a.geometry!==null))))&&(2>this.pointsCount?this.lk=!0:this.ua=this.makeGeometry(),a=this.path,a!==null)){a.ua=this.ua;for(var y=this.O.s,x=y.length,E=0;E<x;E++){var b=y[E];b!==a&&b.isPanelMain&&b instanceof Dr&&(b.ua=this.ua)}}},Tn.prototype.makeGeometry=function(){var a=this.ua,y=this.pointsCount,x=!1,E=this.diagram;E!==null&&Cf(this)&&E.Eh.contains(this)&&(this.ml.width!==0||this.ml.height!==0)&&(E.animationManager.isAnimating||E.currentTool!==E.toolManager)&&(x=!0);var b=this.i(0).copy(),z=b.copy();E=this.Nb.s;var ee=this.computeCurve();if(ee===vh&&3<=y&&!yt.$(this.smoothness,0))if(y===3){var re=this.i(1);E=Math.min(b.x,re.x);var oe=Math.min(b.y,re.y);re=this.i(2),E=Math.min(E,re.x),oe=Math.min(oe,re.y)}else{if(this.isOrthogonal)for(oe=0;oe<y;oe++)re=E[oe],z.x=Math.min(re.x,z.x),z.y=Math.min(re.y,z.y);else for(E=3;E<y;E+=3)E+3>=y&&(E=y-1),oe=this.i(E),z.x=Math.min(oe.x,z.x),z.y=Math.min(oe.y,z.y);E=z.x,oe=z.y}else{for(oe=0;oe<y;oe++)re=E[oe],z.x=Math.min(re.x,z.x),z.y=Math.min(re.y,z.y);E=z.x,oe=z.y}if(E-=this.su.x,oe-=this.su.y,b.x-=E,b.y-=oe,y!==2||Cf(this)){if(a.type=Bn.o,re=AS(a),this.computeShortLength(!0)!==0&&(b=Wf(this,b,!0,z)),Mg(re,b.x,b.y,!1),ee===vh&&3<=y&&!yt.$(this.smoothness,0))if(y===3)x=this.i(1),y=x.x-E,x=x.y-oe,b=this.i(2).copy(),b.x-=E,b.y-=oe,this.computeShortLength(!1)!==0&&(b=Wf(this,b,!1,z)),Pd(re,y,x,y,x,b.x,b.y);else if(this.isOrthogonal){y=Qe.allocAt(E,oe),x=Qe.alloc(),x.assign(this.i(1)),z=Qe.allocAt(E,oe),b=Qe.allocAt(E,oe),ee=this.i(0);for(var se,ue=this.smoothness/3,fe=1;fe<this.pointsCount-1;fe++){se=this.i(fe);var ve=ee,ye=se,Ce=this.i(X0(this,se,fe,!1));if((!yt.$(ve.x,ye.x)||!yt.$(ye.x,Ce.x))&&(!yt.$(ve.y,ye.y)||!yt.$(ye.y,Ce.y))){var Ae=ue;isNaN(Ae)&&(Ae=this.smoothness/3);var Ye=ve.x;ve=ve.y;var We=ye.x;ye=ye.y;var tt=Ce.x;Ce=Ce.y;var rt=Ae*Qm(Ye,ve,We,ye);Ae*=Qm(We,ye,tt,Ce),yt.$(ve,ye)&&yt.$(We,tt)&&(We>Ye?Ce>ye?(z.x=We-rt,z.y=ye-rt,b.x=We+Ae,b.y=ye+Ae):(z.x=We-rt,z.y=ye+rt,b.x=We+Ae,b.y=ye-Ae):Ce>ye?(z.x=We+rt,z.y=ye-rt,b.x=We-Ae,b.y=ye+Ae):(z.x=We+rt,z.y=ye+rt,b.x=We-Ae,b.y=ye-Ae)),yt.$(Ye,We)&&yt.$(ye,Ce)&&(ye>ve?(tt>We?(z.x=We-rt,z.y=ye-rt,b.x=We+Ae):(z.x=We+rt,z.y=ye-rt,b.x=We-Ae),b.y=ye+Ae):(tt>We?(z.x=We-rt,z.y=ye+rt,b.x=We+Ae):(z.x=We+rt,z.y=ye+rt,b.x=We-Ae),b.y=ye-Ae)),(yt.$(Ye,We)&&yt.$(We,tt)||yt.$(ve,ye)&&yt.$(ye,Ce))&&(Ye=.5*(Ye+tt),ve=.5*(ve+Ce),z.x=Ye,z.y=ve,b.x=Ye,b.y=ve),(fe===1||fe===2&&yt.$(ee.x,this.i(0).x)&&yt.$(ee.y,this.i(0).y))&&(x.x=.5*(ee.x+se.x),x.y=.5*(ee.y+se.y)),Pd(re,x.x-E,x.y-oe,z.x-E,z.y-oe,se.x-E,se.y-oe),y.set(z),x.set(b),ee=se}}se=ee.x,ee=ee.y,ue=this.i(this.pointsCount-1),this.computeShortLength(!1)!==0&&(ue=Wf(this,ue.copy(),!1,bs)),se=.5*(se+ue.x),ee=.5*(ee+ue.y),Pd(re,b.x-E,b.y-oe,se-E,ee-oe,ue.x-E,ue.y-oe),Qe.free(y),Qe.free(x),Qe.free(z),Qe.free(b)}else for(x=3;x<y;x+=3)z=this.i(x-2),x+3>=y&&(x=y-1),b=this.i(x-1),ee=this.i(x),x===y-1&&this.computeShortLength(!1)!==0&&(ee=Wf(this,ee.copy(),!1,bs)),Pd(re,z.x-E,z.y-oe,b.x-E,b.y-oe,ee.x-E,ee.y-oe);else{for(z=Qe.alloc(),z.assign(this.i(0)),b=Qe.alloc(),b.assign(z),ee=this.computeCorner(),fe=1,se=0;fe<y;){if(fe=X0(this,z,fe,1<fe),ue=this.i(fe),fe>=y-1){if(!z.D(ue))this.computeShortLength(!1)!==0&&(ue=Wf(this,ue.copy(),!1,bs)),Vf(this,re,-E,-oe,z,ue,x);else if(se===0)for(fe=1;fe<y;)b.assign(z),ue=this.i(fe++),Vf(this,re,-E,-oe,z,ue,x),z.assign(ue);break}if(se=X0(this,ue,fe+1,fe<y-3),fe=-E,Ye=-oe,ve=ue,We=this.i(se),Ae=x,yt.B(z.y,ve.y)&&yt.B(ve.x,We.x))if(Ce=Math.min(ee,Math.abs(ve.x-b.x)/2),Ce=rt=Math.min(Ce,Math.abs(We.y-ve.y)/2),yt.B(Ce,0))Vf(this,re,fe,Ye,z,ve,Ae),z.assign(ve);else{var at=ve.x,gt=ve.y;ye=at,tt=gt,ve.x>z.x?at=ve.x-Ce:at=ve.x+Ce,We.y>ve.y?tt=ve.y+rt:tt=ve.y-rt,We=Qe.allocAt(at,gt),Vf(this,re,fe,Ye,z,We,Ae),Qe.free(We),Gm(re,ve.x+fe,ve.y+Ye,ye+fe,tt+Ye),z.h(ye,tt)}else yt.B(z.x,ve.x)&&yt.B(ve.y,We.y)?(Ce=Math.min(ee,Math.abs(ve.y-b.y)/2),Ce=rt=Math.min(Ce,Math.abs(We.x-ve.x)/2),yt.B(rt,0)?(Vf(this,re,fe,Ye,z,ve,Ae),z.assign(ve)):(at=ve.x,gt=ve.y,ye=at,tt=gt,ve.y>z.y?gt=ve.y-Ce:gt=ve.y+Ce,We.x>ve.x?ye=ve.x+rt:ye=ve.x-rt,We=Qe.allocAt(at,gt),Vf(this,re,fe,Ye,z,We,Ae),Qe.free(We),Gm(re,ve.x+fe,ve.y+Ye,ye+fe,tt+Ye),z.h(ye,tt))):(Vf(this,re,fe,Ye,z,ve,Ae),z.assign(ve));b.assign(ue),fe=se}Qe.free(z)}Km=re}else re=this.i(1).copy(),re.x-=E,re.y-=oe,this.computeShortLength(!0)!==0&&(b=Wf(this,b,!0,z)),this.computeShortLength(!1)!==0&&(re=Wf(this,re,!1,z)),a.type=Bn.j,a.startX=b.x,a.startY=b.y,a.endX=re.x,a.endY=re.y;return this.lk=!0,a};function Qm(a,y,x,E){return a=x-a,isNaN(a)||a===1/0||a===-1/0?NaN:(0>a&&(a=-a),y=E-y,isNaN(y)||y===1/0||y===-1/0?NaN:(0>y&&(y=-y),yt.$(a,0)?y:yt.$(y,0)?a:Math.sqrt(a*a+y*y)))}function Wf(a,y,x,E){var b=a.pointsCount;if(2>b)return y;if(x){var z=a.i(1);if(x=z.x-E.x,z=z.y-E.y,E=Qm(y.x,y.y,x,z),E===0)return y;b=b===2?.5*E:E,a=a.computeShortLength(!0),a>b&&(a=b),b=a*(z-y.y)/E,y.x+=a*(x-y.x)/E,y.y+=b}else{if(z=a.i(b-2),x=z.x-E.x,z=z.y-E.y,E=Qm(y.x,y.y,x,z),E===0)return y;b=b===2?.5*E:E,a=a.computeShortLength(!1),a>b&&(a=b),b=a*(y.y-z)/E,y.x-=a*(y.x-x)/E,y.y-=b}return y}function X0(a,y,x,E){for(var b=a.pointsCount,z=y;yt.$(y.x,z.x)&&yt.$(y.y,z.y);){if(x>=b)return b-1;z=a.i(x++)}if(!yt.$(y.x,z.x)&&!yt.$(y.y,z.y))return x-1;for(var ee=z;yt.$(y.x,z.x)&&yt.$(z.x,ee.x)&&(!E||(y.y>=z.y?z.y>=ee.y:z.y<=ee.y))||yt.$(y.y,z.y)&&yt.$(z.y,ee.y)&&(!E||(y.x>=z.x?z.x>=ee.x:z.x<=ee.x));){if(x>=b)return b-1;ee=a.i(x++)}return x-2}Tn.prototype.computeJumpLength=function(){return 10};function Vf(a,y,x,E,b,z,ee){if(!ee&&Cf(a)){ee=a.computeJumpLength();var re=ee/2,oe=[],se=0;if(a.isVisible()&&(se=bx(a,b,z,oe)),0<se){if(yt.B(b.y,z.y))if(b.x<z.x)for(var ue=0;ue<se;){var fe=Math.max(b.x,Math.min(oe[ue++]-re,z.x-ee));y.lineTo(fe+x,z.y+E);for(var ve=fe+x,ye=Math.min(fe+ee,z.x);ue<se&&(fe=oe[ue],fe<ye+ee);)ue++,ye=Math.min(fe+re,z.x);fe=z.y-ee+E,ye+=x;var Ce=z.y+E;a.curve===Ld?Mg(y,ye,Ce,!1):Pd(y,ve,fe,ye,fe,ye,Ce)}else for(--se;0<=se;){for(ue=Math.min(b.x,Math.max(oe[se--]+re,z.x+ee)),y.lineTo(ue+x,z.y+E),ve=ue+x,fe=Math.max(ue-ee,z.x);0<=se&&(ue=oe[se],ue>fe-ee);)se--,fe=Math.max(ue-re,z.x);ue=z.y-ee+E,fe+=x,ye=z.y+E,a.curve===Ld?Mg(y,fe,ye,!1):Pd(y,ve,ue,fe,ue,fe,ye)}else if(yt.B(b.x,z.x))if(b.y<z.y)for(ue=0;ue<se;){for(fe=Math.max(b.y,Math.min(oe[ue++]-re,z.y-ee)),y.lineTo(z.x+x,fe+E),ve=fe+E,fe=Math.min(fe+ee,z.y);ue<se&&(ye=oe[ue],ye<fe+ee);)ue++,fe=Math.min(ye+re,z.y);ye=z.x-ee+x,Ce=z.x+x,fe+=E,a.curve===Ld?Mg(y,Ce,fe,!1):Pd(y,ye,ve,ye,fe,Ce,fe)}else for(--se;0<=se;){for(ue=Math.min(b.y,Math.max(oe[se--]+re,z.y+ee)),y.lineTo(z.x+x,ue+E),ve=ue+E,ue=Math.max(ue-ee,z.y);0<=se&&(fe=oe[se],fe>ue-ee);)se--,ue=Math.max(fe-re,z.y);fe=z.x-ee+x,ye=z.x+x,ue+=E,a.curve===Ld?Mg(y,ye,ue,!1):Pd(y,fe,ve,fe,ue,ye,ue)}}}y.lineTo(z.x+x,z.y+E)}function bx(a,y,x,E){var b=a.diagram;if(b===null||y.D(x))return 0;for(b=b.layers;b.next();){var z=b.value;if(z!==null&&z.visible){z=z.Pa.s;for(var ee=z.length,re=0;re<ee;re++){var oe=z[re];if(oe instanceof Tn){if(oe===a)return 0<E.length&&E.sort(function(ue,fe){return ue-fe}),E.length;if(oe.isVisible()&&Cf(oe)){var se=oe.routeBounds;se.w()&&a.routeBounds.Yc(se)&&!a.usesSamePort(oe)&&(se=oe.path,se!==null&&se.Ed()&&Lx(y,x,E,oe))}}}}}return 0<E.length&&E.sort(function(ue,fe){return ue-fe}),E.length}function Lx(a,y,x,E){for(var b=yt.B(a.y,y.y),z=E.pointsCount,ee=E.i(0),re=Qe.alloc(),oe=1;oe<z;oe++){var se=E.i(oe);if(oe<z-1){var ue=E.i(oe+1);if(ee.y===se.y&&se.y===ue.y){if(se.x>ee.x&&ue.x>=se.x||se.x<ee.x&&ue.x<=se.x)continue}else if(ee.x===se.x&&se.x===ue.x&&(se.y>ee.y&&ue.y>=se.y||se.y<ee.y&&ue.y<=se.y))continue}e:{ue=a.x;var fe=a.y,ve=y.x,ye=y.y,Ce=ee.x;ee=ee.y;var Ae=se.x,Ye=se.y;if(yt.B(ue,ve)){if(!yt.B(fe,ye)&&yt.B(ee,Ye)&&Math.min(fe,ye)<ee&&Math.max(fe,ye)>ee&&Math.min(Ce,Ae)<ue&&Math.max(Ce,Ae)>ue&&!yt.B(Ce,Ae)){re.x=ue,re.y=ee,ue=!0;break e}}else if(yt.B(fe,ye)&&yt.B(Ce,Ae)&&Math.min(ue,ve)<Ce&&Math.max(ue,ve)>Ce&&Math.min(ee,Ye)<fe&&Math.max(ee,Ye)>fe&&!yt.B(ee,Ye)){re.x=Ce,re.y=fe,ue=!0;break e}re.x=0,re.y=0,ue=!1}ue&&(b?x.push(re.x):x.push(re.y)),ee=se}Qe.free(re)}function Cf(a){return a=a.curve,a===Ag||a===Ld}function qm(a,y){(y||Cf(a))&&(y=a.diagram,y===null||y.animationManager.isTicking||y.Eh.contains(a)||a.ml.width===0&&a.ml.height===0||y.Eh.add(a,a.ml.copy()))}Tn.prototype.Xo=function(a){var y=this.layer;if(y!==null&&y.visible&&!y.isTemporary){var x=y.diagram;if(x!==null&&!x.animationManager.isTicking){var E=!1;for(x=x.layers;x.next();){var b=x.value;if(b.visible){if(b===y){E=!0;var z=!1;b=b.Pa.s;for(var ee=b.length,re=0;re<ee;re++){var oe=b[re];oe instanceof Tn&&(oe===this?z=!0:z&&e1(this,oe,a))}}else if(E)for(z=b.Pa.s,b=z.length,ee=0;ee<b;ee++)re=z[ee],re instanceof Tn&&e1(this,re,a)}}}}};function e1(a,y,x){if(y!==null&&y.lk&&y.fd&&Cf(y)){var E=y.routeBounds;E.w()&&(a.routeBounds.Yc(E)||x.Yc(E))&&(a.usesSamePort(y)||y.qc())}}Tn.prototype.usesSamePort=function(a){var y=this.pointsCount,x=a.pointsCount;if(0<y&&0<x){var E=this.i(0),b=a.i(0);if(E.Xa(b)||(y=this.i(y-1),a=a.i(x-1),y.Xa(a)||E.Xa(a)||y.Xa(b)))return!0}else if(this.fromNode===a.fromNode||this.toNode===a.toNode||this.fromNode===a.toNode||this.toNode===a.fromNode)return!0;return!1},Tn.prototype.isVisible=function(){if(!Ii.prototype.isVisible.call(this))return!1;var a=this.containingGroup,y=!0,x=this.diagram;if(x!==null&&(y=x.isTreePathToChildren),x=this.fromNode,x!==null){if(this.isTreeLink&&y&&!x.isTreeExpanded)return!1;if(x===a)return!0;for(var E=x;E!==null;){if(E.labeledLink===this)return!0;E=E.containingGroup}if(x=x.findVisibleNode(),x===null||x===a)return!1}if(x=this.toNode,x!==null){if(this.isTreeLink&&!y&&!x.isTreeExpanded)return!1;if(x===a)return!0;for(y=x;y!==null;){if(y.labeledLink===this)return!0;y=y.containingGroup}if(y=x.findVisibleNode(),y===null||y===a)return!1}return!0},Tn.prototype.Zb=function(a){if(Ii.prototype.Zb.call(this,a),a&&qm(this,!1),this.Sf!==null&&this.Sf.Sl(),this.wd!==null)for(var y=this.wd.iterator;y.next();)y.value.Zb(a)},Tn.prototype.computeAdjusting=function(){return this.isAvoiding&&this.diagram!==null&&this.diagram.animationManager.defaultAnimation.isAnimating?Cp:this.qk};function wp(a){var y=a.ef;if(y!==null){var x=a.uf;if(x!==null&&isNaN(a.curviness)){for(var E=a.ff,b=a.vf,z=a=null,ee=y.jb.s,re=ee.length,oe=0;oe<re;oe++){var se=ee[oe];(se.ef===y&&se.ff===E&&se.uf===x&&se.vf===b||se.ef===x&&se.ff===b&&se.uf===y&&se.vf===E)&&(z===null?z=se:(a===null&&(a=[],a.push(z)),a.push(se)))}if(a!==null){for(z=KS(y,x,E,b),z===null&&(z=new iv(y,E,x,b),GS(y,z),GS(x,z)),z.links=a,y=0;y<a.length;y++)a[y].Sf=z;z.Sl()}}}}function Pp(a){var y=a.Sf;y!==null&&isNaN(a.curviness)&&(a.Sf=null,a=y.links.indexOf(a),0<=a&&($o(y.links,a),y.Sl()))}Tn.prototype.ph=function(){return!0},Yt.Object.defineProperties(Tn.prototype,{fromNode:{get:function(){return this.ef},set:function(a){var y=this.ef;if(y!==a){var x=this.fromPort;y!==null&&(this.uf!==y&&Zm(y,this,x),Pp(this),this.C(2)),this.ef=a,a!==null&&this.Zb(a.isVisible()),this.Wf=null,this.bb();var E=this.diagram;E!==null&&E.aa&&E.partManager.setFromNodeForLink(this,a,y);var b=this.fromPort,z=this.fromPortChanged;if(z!==null){var ee=!0;E!==null&&(ee=E.aa,E.aa=!0),z(this,x,b),E!==null&&(E.aa=ee)}a!==null&&(this.uf!==a&&Um(a,this,b),wp(this),this.C(1)),this.g("fromNode",y,a),kg(this)}}},fromPortId:{get:function(){return this.ff},set:function(a){var y=this.ff;if(y!==a){var x=this.fromPort;x!==null&&nh(x),Pp(this),this.ff=a;var E=this.fromPort;E!==null&&nh(E);var b=this.diagram;if(b!==null){var z=this.data,ee=b.model;z!==null&&ee.ri()&&ee.xv(z,a)}x!==E&&(this.Wf=null,this.bb(),z=this.fromPortChanged,z!==null&&(ee=!0,b!==null&&(ee=b.aa,b.aa=!0),z(this,x,E),b!==null&&(b.aa=ee))),wp(this),this.g("fromPortId",y,a)}}},fromPort:{get:function(){var a=this.ef;return a===null?null:a.ns(this.ff)}},fromPortChanged:{get:function(){return this.gn},set:function(a){var y=this.gn;y!==a&&(this.gn=a,this.g("fromPortChanged",y,a))}},toNode:{get:function(){return this.uf},set:function(a){var y=this.uf;if(y!==a){var x=this.toPort;y!==null&&(this.ef!==y&&Zm(y,this,x),Pp(this),this.C(2)),this.uf=a,a!==null&&this.Zb(a.isVisible()),this.Wf=null,this.bb();var E=this.diagram;E!==null&&E.aa&&E.partManager.setToNodeForLink(this,a,y);var b=this.toPort,z=this.toPortChanged;if(z!==null){var ee=!0;E!==null&&(ee=E.aa,E.aa=!0),z(this,x,b),E!==null&&(E.aa=ee)}a!==null&&(this.ef!==a&&Um(a,this,b),wp(this),this.C(1)),this.g("toNode",y,a),kg(this)}}},toPortId:{get:function(){return this.vf},set:function(a){var y=this.vf;if(y!==a){var x=this.toPort;x!==null&&nh(x),Pp(this),this.vf=a;var E=this.toPort;E!==null&&nh(E);var b=this.diagram;if(b!==null){var z=this.data,ee=b.model;z!==null&&ee.ri()&&ee.Cv(z,a)}x!==E&&(this.Wf=null,this.bb(),z=this.toPortChanged,z!==null&&(ee=!0,b!==null&&(ee=b.aa,b.aa=!0),z(this,x,E),b!==null&&(b.aa=ee))),wp(this),this.g("toPortId",y,a)}}},toPort:{get:function(){var a=this.uf;return a===null?null:a.ns(this.vf)}},toPortChanged:{get:function(){return this.uo},set:function(a){var y=this.uo;y!==a&&(this.uo=a,this.g("toPortChanged",y,a))}},fromSpot:{get:function(){return this.ba!==null?this.ba.Xi:vs},set:function(a){var y=this.fromSpot;y.D(a)||(a=a.J(),this.Xc(),this.ba.Xi=a,this.g("fromSpot",y,a),(y.$c()||a.$c())&&this.fromNode!==null&&nh(this.fromPort),this.bb())}},fromEndSegmentLength:{get:function(){return this.ba!==null?this.ba.Vi:NaN},set:function(a){var y=this.fromEndSegmentLength;y!==a&&(0>a&&gr(a,">= 0",Tn,"fromEndSegmentLength"),this.Xc(),this.ba.Vi=a,this.g("fromEndSegmentLength",y,a),this.bb())}},fromShortLength:{get:function(){return this.ba!==null?this.ba.Wi:NaN},set:function(a){var y=this.fromShortLength;y!==a&&(this.Xc(),this.ba.Wi=a,this.qc(),this.g("fromShortLength",y,a))}},toSpot:{get:function(){return this.ba!==null?this.ba.yj:vs},set:function(a){var y=this.toSpot;y.D(a)||(a=a.J(),this.Xc(),this.ba.yj=a,this.g("toSpot",y,a),(y.$c()||a.$c())&&this.toNode!==null&&nh(this.toPort),this.bb())}},toEndSegmentLength:{get:function(){return this.ba!==null?this.ba.wj:NaN},set:function(a){var y=this.toEndSegmentLength;y!==a&&(0>a&&gr(a,">= 0",Tn,"toEndSegmentLength"),this.Xc(),this.ba.wj=a,this.g("toEndSegmentLength",y,a),this.bb())}},toShortLength:{get:function(){return this.ba!==null?this.ba.xj:NaN},set:function(a){var y=this.toShortLength;y!==a&&(this.Xc(),this.ba.xj=a,this.qc(),this.g("toShortLength",y,a))}},isLabeledLink:{get:function(){return this.wd===null?!1:0<this.wd.count}},labelNodes:{get:function(){return this.wd===null?ea:this.wd.iterator}},relinkableFrom:{get:function(){return(this.Qa&1)!==0},set:function(a){var y=(this.Qa&1)!==0;y!==a&&(this.Qa^=1,this.g("relinkableFrom",y,a),this.Wb())}},relinkableTo:{get:function(){return(this.Qa&2)!==0},set:function(a){var y=(this.Qa&2)!==0;y!==a&&(this.Qa^=2,this.g("relinkableTo",y,a),this.Wb())}},resegmentable:{get:function(){return(this.Qa&4)!==0},set:function(a){var y=(this.Qa&4)!==0;y!==a&&(this.Qa^=4,this.g("resegmentable",y,a),this.Wb())}},isTreeLink:{get:function(){return(this.Qa&8)!==0},set:function(a){var y=(this.Qa&8)!==0;y!==a&&(this.Qa^=8,this.g("isTreeLink",y,a),this.fromNode!==null&&xp(this.fromNode),this.toNode!==null&&xp(this.toNode))}},path:{get:function(){var a=this.Pb();return a instanceof Dr?a:null}},routeBounds:{get:function(){this.vg();var a=this.ml,y=1/0,x=1/0,E=this.pointsCount;if(E===0)a.h(NaN,NaN,0,0);else{if(E===1)E=this.i(0),y=Math.min(E.x,y),x=Math.min(E.y,x),a.h(E.x,E.y,0,0);else if(E===2){E=this.i(0);var b=this.i(1);y=Math.min(E.x,b.x),x=Math.min(E.y,b.y),a.h(E.x,E.y,0,0),a.Ye(b)}else if(this.computeCurve()===vh&&3<=E&&!this.isOrthogonal)if(b=this.i(0),y=b.x,x=b.y,a.h(y,x,0,0),E===3){E=this.i(1),y=Math.min(E.x,y),x=Math.min(E.y,x);var z=this.i(2);y=Math.min(z.x,y),x=Math.min(z.y,x),yt.Dl(b.x,b.y,E.x,E.y,E.x,E.y,z.x,z.y,.5,a)}else for(z=3;z<E;z+=3){var ee=this.i(z-2);z+3>=E&&(z=E-1);var re=this.i(z-1),oe=this.i(z);yt.Dl(b.x,b.y,ee.x,ee.y,re.x,re.y,oe.x,oe.y,.5,a),y=Math.min(oe.x,y),x=Math.min(oe.y,x),b=oe}else for(b=this.i(0),z=this.i(1),y=Math.min(b.x,z.x),x=Math.min(b.y,z.y),a.h(b.x,b.y,0,0),a.Ye(z),b=2;b<E;b++)z=this.i(b),y=Math.min(z.x,y),x=Math.min(z.y,x),a.Ye(z);this.su.h(y-a.x,x-a.y)}return a}},midPoint:{get:function(){return this.vg(),this.computeMidPoint(new Qe)}},midAngle:{get:function(){return this.vg(),this.computeMidAngle()}},flattenedLengths:{get:function(){if(this.cq===null){this.fd||Ym(this);for(var a=this.cq=[],y=this.pointsCount,x=0;x<y-1;x++){var E=this.i(x),b=this.i(x+1);yt.$(E.x,b.x)?(E=b.y-E.y,0>E&&(E=-E)):yt.$(E.y,b.y)?(E=b.x-E.x,0>E&&(E=-E)):E=Math.sqrt(E.Bf(b)),a.push(E)}}return this.cq}},flattenedTotalLength:{get:function(){var a=this.vt;if(isNaN(a)){for(var y=this.flattenedLengths,x=y.length,E=a=0;E<x;E++)a+=y[E];this.vt=a}return a}},points:{get:function(){return this.Nb},set:function(a){var y=this.Nb;if(y!==a){var x=null;if(Array.isArray(a)){var E=a.length%2===0;if(E){for(var b=0;b<a.length;b++)if(typeof a[b]!="number"||isNaN(a[b])){E=!1;break}}if(E)for(x=new An,E=0;E<a.length/2;E++)b=new Qe(a[2*E],a[2*E+1]).freeze(),x.add(b);else{for(E=!0,b=0;b<a.length;b++){var z=a[b];if(!kn(z)||typeof z.x!="number"||isNaN(z.x)||typeof z.y!="number"||isNaN(z.y)){E=!1;break}}if(E)for(x=new An,E=0;E<a.length;E++)b=a[E],x.add(new Qe(b.x,b.y).freeze())}}else if(a instanceof An)for(x=a.copy(),a=x.iterator;a.next();)a.value.freeze();else Dt("Link.points value is not an instance of List or Array: "+a);x.freeze(),this.Nb=x,this.qc(),Ym(this),a=this.diagram,a!==null&&(a.pi||a.undoManager.isUndoingRedoing||a.As.add(this),a.animationManager.zb&&rr(a.animationManager,this,x)),this.g("points",y,x)}}},pointsCount:{get:function(){return this.Nb.count}},fd:{get:function(){return(this.Qa&16)!==0},set:function(a){(this.Qa&16)!==0!==a&&(this.Qa^=16)}},suspendsRouting:{get:function(){return(this.Qa&32)!==0},set:function(a){(this.Qa&32)!==0!==a&&(this.Qa^=32)}},computingPoints:{get:function(){return(this.Qa&64)!==0},set:function(a){(this.Qa&64)!==0!==a&&(this.Qa^=64)}},defaultFromPoint:{get:function(){return this.o},set:function(a){this.o=a.copy()}},defaultToPoint:{get:function(){return this.u},set:function(a){this.u=a.copy()}},isOrthogonal:{get:function(){return(this.qj.value&2)===2}},isAvoiding:{get:function(){return(this.qj.value&4)===4}},lk:{get:function(){return(this.Qa&128)!==0},set:function(a){(this.Qa&128)!==0!==a&&(this.Qa^=128)}},geometry:{get:function(){if(!this.lk){if(this.vg(),2>this.pointsCount)return this.lk=!0,this.ua;this.ua=this.makeGeometry()}return this.ua}},firstPickIndex:{get:function(){return 2>=this.pointsCount?0:this.isOrthogonal||!Fg(this.computeSpot(!0))?1:0}},lastPickIndex:{get:function(){var a=this.pointsCount;return a===0?0:2>=a?a-1:this.isOrthogonal||!Fg(this.computeSpot(!1))?a-2:a-1}},adjusting:{get:function(){return this.qk},set:function(a){var y=this.qk;y!==a&&(this.qk=a,this.g("adjusting",y,a))}},corner:{get:function(){return this.Om},set:function(a){var y=this.Om;y!==a&&(this.Om=a,this.qc(),this.g("corner",y,a))}},curve:{get:function(){return this.Qm},set:function(a){var y=this.Qm;y!==a&&(this.Qm=a,this.bb(),this.qc(),qm(this,y===Ld||y===Ag||a===Ld||a===Ag),this.g("curve",y,a))}},curviness:{get:function(){return this.Rm},set:function(a){var y=this.Rm;y!==a&&(this.Rm=a,this.bb(),this.qc(),this.g("curviness",y,a))}},routing:{get:function(){return this.qj},set:function(a){var y=this.qj;y!==a&&(this.qj=a,this.Wf=null,this.bb(),qm(this,(y.value&2)===2||(a.value&2)===2),this.g("routing",y,a))}},smoothness:{get:function(){return this.po},set:function(a){var y=this.po;y!==a&&(this.po=a,this.qc(),this.g("smoothness",y,a))}},key:{get:function(){var a=this.diagram;if(a!==null&&a.model.ri())return a.model.Ac(this.data)}}}),Tn.prototype.invalidateOtherJumpOvers=Tn.prototype.Xo,Tn.prototype.findClosestSegment=Tn.prototype.ez,Tn.prototype.updateRoute=Tn.prototype.vg,Tn.prototype.invalidateRoute=Tn.prototype.bb,Tn.prototype.rollbackRoute=Tn.prototype.rv,Tn.prototype.commitRoute=Tn.prototype.zf,Tn.prototype.startRoute=Tn.prototype.uh,Tn.prototype.clearPoints=Tn.prototype.Fj,Tn.prototype.removePoint=Tn.prototype.pv,Tn.prototype.addPointAt=Tn.prototype.yf,Tn.prototype.addPoint=Tn.prototype.ne,Tn.prototype.insertPointAt=Tn.prototype.m,Tn.prototype.insertPoint=Tn.prototype.Kz,Tn.prototype.setPointAt=Tn.prototype.L,Tn.prototype.setPoint=Tn.prototype.dd,Tn.prototype.getPoint=Tn.prototype.i,Tn.prototype.getOtherPort=Tn.prototype.Cz,Tn.prototype.getOtherNode=Tn.prototype.To;var Uf=null,Zf=null,J0=new Vt(Tn,"Normal",1),Mx=new Vt(Tn,"Orthogonal",2),kx=new Vt(Tn,"AvoidsNodes",6),t1=new Vt(Tn,"AvoidsNodesStraight",7),Pu=new Vt(Tn,"None",0),vh=new Vt(Tn,"Bezier",9),Ld=new Vt(Tn,"JumpGap",10),Ag=new Vt(Tn,"JumpOver",11),Cp=new Vt(Tn,"End",17),$m=new Vt(Tn,"Scale",18),ev=new Vt(Tn,"Stretch",19),Ep=new Vt(Tn,"OrientAlong",21),bp=new Vt(Tn,"OrientPlus90",22),Lp=new Vt(Tn,"OrientMinus90",23),Q0=new Vt(Tn,"OrientOpposite",24),tv=new Vt(Tn,"OrientUpright",25),Mp=new Vt(Tn,"OrientPlus90Upright",26),kp=new Vt(Tn,"OrientMinus90Upright",27),nv=new Vt(Tn,"OrientUpright45",28),n1=16,i1=14,Fp=8;Tn.className="Link",Tn.Normal=J0,Tn.Orthogonal=Mx,Tn.AvoidsNodes=kx,Tn.AvoidsNodesStraight=t1,Tn.None=Pu,Tn.Bezier=vh,Tn.JumpGap=Ld,Tn.JumpOver=Ag,Tn.End=Cp,Tn.Scale=$m,Tn.Stretch=ev,Tn.OrientAlong=Ep,Tn.OrientPlus90=bp,Tn.OrientMinus90=Lp,Tn.OrientOpposite=Q0,Tn.OrientUpright=tv,Tn.OrientPlus90Upright=Mp,Tn.OrientMinus90Upright=kp,Tn.OrientUpright45=nv,Tn.EndSegmentStep=8,Tn.CurvinessStart=n1,Tn.SpacingMin=i1,Tn.OrthoShortCut=Fp;function iv(a,y,x,E){jo(this),this.Fe=this.qq=!1,this.Ds=a,this.Ox=y,this.cv=x,this.Px=E,this.links=[]}iv.prototype.Sl=function(){if(!this.qq){var a=this.links;0<a.length&&(a=a[0].diagram,a!==null&&(a.ow.add(this),this.Fe=a.undoManager.isUndoingRedoing))}this.qq=!0},iv.prototype.Nv=function(){if(this.qq){this.qq=!1;var a=this.links;if(0<a.length){var y=a[0],x=y.diagram;x=x===null||x.pi&&!this.Fe,this.Fe=!1,y.arrangeBundledLinks(a,x),a.length===1&&(y.Sf=null,a.length=0)}a.length===0&&(a=this.Ds,this!==null&&a.af!==null&&a.af.remove(this),a=this.cv,this!==null&&a.af!==null&&a.af.remove(this))}},iv.className="LinkBundle";function Ap(a){jo(this),this.Yx=this.group=null,this.vs=!0,this.abort=!1,this.Od=this.Nd=1,this.Fn=this.En=-1,this.rc=a.width,this.sc=a.height,this.ac=null,this.ei=this.di=0,this.Os=11,this.Ix=this.Hx=22}Ap.prototype.initialize=function(a){if(!(0>=a.width||0>=a.height)){var y=a.y,x=a.x+a.width,E=a.y+a.height;if(this.Nd=Math.floor((a.x-this.rc)/this.rc)*this.rc,this.Od=Math.floor((y-this.sc)/this.sc)*this.sc,this.En=Math.ceil((x+2*this.rc)/this.rc)*this.rc,this.Fn=Math.ceil((E+2*this.sc)/this.sc)*this.sc,a=1+(Math.ceil((this.En-this.Nd)/this.rc)|0),y=1+(Math.ceil((this.Fn-this.Od)/this.sc)|0),this.ac===null||this.di<a-1||this.ei<y-1){for(x=[],E=0;E<=a;E++)x[E]=new Uint32Array(y);this.ac=x,this.di=a-1,this.ei=y-1}if(a=q0,this.ac!==null)for(y=0;y<=this.di;y++)if(x=this.ac[y],x.fill)x.fill(a);else for(E=0;E<=this.ei;E++)x[E]=a}};function Ng(a,y,x){return a.Nd<=y&&y<=a.En&&a.Od<=x&&x<=a.Fn}function Uc(a,y,x){return Ng(a,y,x)?(y-=a.Nd,y/=a.rc,x-=a.Od,x/=a.sc,a.ac[y|0][x|0]):q0}function r1(a){if(a.ac!==null)for(var y=0;y<=a.di;y++)for(var x=a.ac[y],E=0;E<=a.ei;E++)x[E]>=Ef&&(x[E]=q0)}Ap.prototype.Yj=function(a,y,x,E){if(a>this.En||a+x<this.Nd||y>this.Fn||y+E<this.Od)return!0;a=(a-this.Nd)/this.rc|0,y=(y-this.Od)/this.sc|0,x=Math.max(0,x)/this.rc+1|0;var b=Math.max(0,E)/this.sc+1|0;if(0>a&&(x+=a,a=0),0>y&&(b+=y,y=0),0>x||0>b)return!0;for(E=Math.min(a+x-1,this.di)|0,x=Math.min(y+b-1,this.ei)|0;a<=E;a++){b=this.ac[a];for(var z=y;z<=x;z++)if(b[z]===Md)return!1}return!0};function Zc(a,y,x,E,b,z,ee,re,oe){if(!(y<z||y>ee||x<re||x>oe)){var se=y|0,ue=x|0,fe=a.ac[se][ue];if(fe>=Ef&&fe<Tg)for(b?ue+=E:se+=E,fe+=1;z<=se&&se<=ee&&re<=ue&&ue<=oe&&!(fe>=a.ac[se][ue]);)a.ac[se][ue]=fe,fe+=1,b?ue+=E:se+=E;if(se=b?ue:se,b)if(0<E)for(x+=E;x<se;x+=E)Zc(a,y,x,1,!b,z,ee,re,oe),Zc(a,y,x,-1,!b,z,ee,re,oe);else for(x+=E;x>se;x+=E)Zc(a,y,x,1,!b,z,ee,re,oe),Zc(a,y,x,-1,!b,z,ee,re,oe);else if(0<E)for(y+=E;y<se;y+=E)Zc(a,y,x,1,!b,z,ee,re,oe),Zc(a,y,x,-1,!b,z,ee,re,oe);else for(y+=E;y>se;y+=E)Zc(a,y,x,1,!b,z,ee,re,oe),Zc(a,y,x,-1,!b,z,ee,re,oe)}}function rv(a,y,x,E,b,z,ee,re,oe){y|=0,x|=0;var se=Md,ue=Ef;for(a.ac[y][x]=ue;se===Md&&y>z&&y<ee&&x>re&&x<oe;)ue+=1,a.ac[y][x]=ue,b?x+=E:y+=E,se=a.ac[y][x]}function ov(a,y,x,E,b,z,ee,re,oe){y|=0,x|=0;var se=Md,ue=Tg;for(a.ac[y][x]=ue;se===Md&&y>z&&y<ee&&x>re&&x<oe;)a.ac[y][x]=ue,b?x+=E:y+=E,se=a.ac[y][x]}function o1(a,y,x,E,b,z,ee){if(a.ac!==null){a.abort=!1;var re=y.x,oe=y.y;if(Ng(a,re,oe)){re-=a.Nd,re/=a.rc,oe-=a.Od,oe/=a.sc;var se=E.x,ue=E.y;if(Ng(a,se,ue))if(se-=a.Nd,se/=a.rc,ue-=a.Od,ue/=a.sc,1>=Math.abs(re-se)&&1>=Math.abs(oe-ue))a.abort=!0;else{var fe=z.x;E=z.y,y=z.x+z.width;var ve=z.y+z.height;fe-=a.Nd,fe/=a.rc,E-=a.Od,E/=a.sc,y-=a.Nd,y/=a.rc,ve-=a.Od,ve/=a.sc,z=Math.max(0,Math.min(a.di,fe|0)),y=Math.min(a.di,Math.max(0,y|0)),fe=Math.max(0,Math.min(a.ei,E|0)),ve=Math.min(a.ei,Math.max(0,ve|0)),E=a.ac,re|=0,oe|=0,se|=0,ue|=0;var ye=x===0||x===90?1:-1;if(x=x===90||x===270,E[re][oe]===Md?(rv(a,re,oe,ye,x,z,y,fe,ve),rv(a,re,oe,1,!x,z,y,fe,ve),rv(a,re,oe,-1,!x,z,y,fe,ve)):rv(a,re,oe,ye,x,re,oe,re,oe),E[se][ue]===Md?(ov(a,se,ue,b===0||b===90?1:-1,b===90||b===270,z,y,fe,ve),ov(a,se,ue,1,!(b===90||b===270),z,y,fe,ve),ov(a,se,ue,-1,!(b===90||b===270),z,y,fe,ve)):ov(a,se,ue,ye,x,se,ue,se,ue),x=qi(),ee&&a1(a,se,ue,b,re,oe,x))for((x[0]!==se||x[1]!==ue)&&(x.unshift(ue),x.unshift(se)),(x[x.length-2]!==re||x[x.length-1]!==oe)&&(x.push(re),x.push(oe)),a=Ef,b=x[x.length-2],ee=x[x.length-1],E[b][ee]=a++,z=x.length-4;0<=z;z-=2)for(b=x[z+2],ee=x[z+3],y=x[z],se=x[z+1];y>b?b++:y<b?b--:se>ee?ee++:se<ee&&ee--,E[b][ee]=a++,b!==y||ee!==se;);else Zc(a,re,oe,1,!1,z,y,fe,ve),Zc(a,re,oe,-1,!1,z,y,fe,ve),Zc(a,re,oe,1,!0,z,y,fe,ve),Zc(a,re,oe,-1,!0,z,y,fe,ve);Zi(x)}}}}function a1(a,y,x,E,b,z,ee){for(var re=a.ac,oe=y,se=x;;){if(oe===b&&se===z)return!0;var ue=oe,fe=se;if(E===0)if(ue<b)ue++;else break;else if(E===90)if(fe<z)fe++;else break;else if(E===180)if(ue>b)ue--;else break;else if(fe>z)fe--;else break;var ve=re[ue][fe];if(ve===0||ve===$0)break;oe=ue,se=fe}for(;;){if(ue=E,fe=oe,ve=se,E===0?ve<z?(ue=90,ve++):ve>z&&(ue=270,ve--):E===90?fe<b?(ue=0,fe++):fe>b&&(ue=180,fe--):E===180?ve<z?(ue=90,ve++):ve>z&&(ue=270,ve--):fe<b?(ue=0,fe++):fe>b&&(ue=180,fe--),fe=re[fe][ve],ue!==E&&fe!==0&&fe!==$0){if(ee.push(oe),ee.push(se),a1(a,oe,se,ue,b,z,ee))return!0;ee.pop(),ee.pop()}if(re[oe][se]=$0,E===0){if(oe===y)return!1;oe--}else if(E===90){if(se===x)return!1;se--}else if(E===180){if(oe===y)return!1;oe++}else{if(se===x)return!1;se++}}}Yt.Object.defineProperties(Ap.prototype,{bounds:{get:function(){return new Xt(this.Nd,this.Od,this.En-this.Nd,this.Fn-this.Od)}},Ho:{get:function(){return this.rc},set:function(a){0<a&&a!==this.rc&&(this.rc=a,this.initialize(this.bounds))}},Go:{get:function(){return this.sc},set:function(a){0<a&&a!==this.sc&&(this.sc=a,this.initialize(this.bounds))}}});var Md=0,Ef=1,Tg=999999,q0=Tg+1,$0=Tg+2;Ap.className="PositionArray";function _f(){jo(this),this.port=this.node=null,this.pe=[],this.ap=!1}_f.prototype.toString=function(){for(var a=this.pe,y=this.node.toString()+" "+a.length.toString()+":",x=0;x<a.length;x++){var E=a[x];E!==null&&(y+=`
`+E.toString())}return y};function Fx(a,y,x,E){switch(y=y.offsetY,y){case 8:return 90;case 2:return 180;case 1:return 270;case 4:return 0}switch(y){case 9:return 180<x?270:90;case 6:return 90<x&&270>=x?180:0}switch(a=180*Math.atan2(a.height,a.width)/Math.PI,y){case 3:return x>a&&x<=180+a?180:270;case 5:return x>180-a&&x<=360-a?270:0;case 12:return x>a&&x<=180+a?90:0;case 10:return x>180-a&&x<=360-a?180:90;case 7:return 90<x&&x<=180+a?180:x>180+a&&x<=360-a?270:0;case 13:return 180<x&&x<=360-a?270:x>a&&180>=x?90:0;case 14:return x>a&&x<=180-a?90:x>180-a&&270>=x?180:0;case 11:return x>180-a&&x<=180+a?180:x>180+a?270:90}return E&&y!==15&&(x-=15,0>x&&(x+=360)),x>a&&x<180-a?90:x>=180-a&&x<=180+a?180:x>180+a&&x<360-a?270:0}_f.prototype.Sl=function(){this.pe.length=0};function s1(a,y){var x=a.pe;if(x.length===0){e:if(!a.ap){x=a.ap,a.ap=!0;var E=null,b=a.node,z=b instanceof xr?b:null;if(z===null||z.isSubGraphExpanded)var ee=b.isTreeExpanded?b.findLinksConnected(a.port.portId):b.qx();else{if(!z.actualBounds.w()){a.ap=x;break e}E=z,ee=E.Lu()}z=a.pe.length=0;var re=a.port.ga(Cs,Qe.alloc()),oe=a.port.ga(Hl,Qe.alloc());for(b=Xt.allocAt(re.x,re.y,0,0),b.Ye(oe),Qe.free(re),Qe.free(oe),re=Qe.allocAt(b.x+b.width/2,b.y+b.height/2),oe=a.port.li(),ee=ee.iterator;ee.next();){var se=ee.value;if(se.isVisible()&&se.fromPort!==se.toPort){var ue=se.fromPort===a.port||se.fromNode!==null&&se.fromNode.Td(E),fe=se.computeSpot(ue,a.port);if(fe.$c()&&(ue=ue?se.toPort:se.fromPort,ue!==null)){var ve=ue.part;if(ve!==null){var ye=ve.findVisibleNode();ye!==null&&ye!==ve&&(ve=ye,ue=ve.port),ue=se.computeOtherPoint(ve,ue),ve=re.ab(ue),ve-=oe,0>ve?ve+=360:360<=ve&&(ve-=360),fe=Fx(b,fe,ve,se.isOrthogonal),fe===0?(fe=4,180<ve&&(ve-=360)):fe===90?(fe=8,270<ve&&(ve-=360)):fe===180?fe=2:(fe=1,90>ve&&(ve+=360)),ye=a.pe[z],ye===void 0?(ye=new ey(se,ve,fe),a.pe[z]=ye):(ye.link=se,ye.angle=ve,ye.Nc=fe),ye.hv.set(ue),z++}}}}for(Qe.free(re),a.pe.sort(_f.prototype.j),oe=a.pe.length,E=-1,z=re=0;z<oe;z++)ee=a.pe[z],ee!==void 0&&(ee.Nc!==E&&(E=ee.Nc,re=0),ee.Uo=re,re++);for(E=-1,re=0,z=oe-1;0<=z;z--)oe=a.pe[z],oe!==void 0&&(oe.Nc!==E&&(E=oe.Nc,re=oe.Uo+1),oe.Gl=re);if(z=a.pe,fe=a.port,E=a.node.portSpreading,re=Qe.alloc(),oe=Qe.alloc(),ee=Qe.alloc(),se=Qe.alloc(),fe.ga(Cs,re),fe.ga(lh,oe),fe.ga(Hl,ee),fe.ga(iu,se),ye=ve=ue=fe=0,E===W0)for(var Ce=0;Ce<z.length;Ce++){var Ae=z[Ce];if(Ae!==null){var Ye=Ae.link.computeThickness();switch(Ae.Nc){case 8:ve+=Ye;break;case 2:ye+=Ye;break;case 1:fe+=Ye;break;default:case 4:ue+=Ye}}}var We=Ce=0,tt=1,rt=Ae=0;for(Ye=0;Ye<z.length;Ye++){var at=z[Ye];if(at!==null){if(Ce!==at.Nc){switch(Ce=at.Nc,Ce){case 8:var gt=ee;We=se;break;case 2:gt=se,We=re;break;case 1:gt=re,We=oe;break;default:case 4:gt=oe,We=ee}switch(Ae=We.x-gt.x,rt=We.y-gt.y,Ce){case 8:ve>Math.abs(Ae)?(tt=Math.abs(Ae)/ve,ve=Math.abs(Ae)):tt=1;break;case 2:ye>Math.abs(rt)?(tt=Math.abs(rt)/ye,ye=Math.abs(rt)):tt=1;break;case 1:fe>Math.abs(Ae)?(tt=Math.abs(Ae)/fe,fe=Math.abs(Ae)):tt=1;break;default:case 4:ue>Math.abs(rt)?(tt=Math.abs(rt)/ue,ue=Math.abs(rt)):tt=1}We=0}var At=at.Zo;if(E===W0){switch(at=at.link.computeThickness(),at*=tt,At.set(gt),Ce){case 8:At.x=gt.x+Ae/2+ve/2-We-at/2;break;case 2:At.y=gt.y+rt/2+ye/2-We-at/2;break;case 1:At.x=gt.x+Ae/2-fe/2+We+at/2;break;default:case 4:At.y=gt.y+rt/2-ue/2+We+at/2}We+=at}else{var Zn=.5;E===_m&&(Zn=(at.Uo+1)/(at.Gl+1)),At.x=gt.x+Ae*Zn,At.y=gt.y+rt*Zn}}}for(Qe.free(re),Qe.free(oe),Qe.free(ee),Qe.free(se),gt=a.pe,z=0;z<gt.length;z++)E=gt[z],E!==null&&(E.Ju=a.computeEndSegmentLength(E));a.ap=x,Xt.free(b)}x=a.pe}for(a=0;a<x.length;a++)if(b=x[a],b!==null&&b.link===y)return b;return null}_f.prototype.j=function(a,y){return a===y?0:a===null?-1:y===null?1:a.Nc<y.Nc?-1:a.Nc>y.Nc?1:a.angle<y.angle?-1:a.angle>y.angle?1:0},_f.prototype.computeEndSegmentLength=function(a){var y=a.link,x=y.computeEndSegmentLength(this.node,this.port,Ms,y.fromPort===this.port),E=a.Uo;if(0>E)return x;var b=a.Gl;if(1>=b||!y.isOrthogonal)return x;y=a.hv;var z=a.Zo;return(a.Nc===2||a.Nc===8)&&(E=b-1-E),((a=a.Nc===2||a.Nc===4)?y.y<z.y:y.x<z.x)?x+8*E:(a?y.y===z.y:y.x===z.x)?x:x+8*(b-1-E)},_f.className="Knot";function ey(a,y,x){this.link=a,this.angle=y,this.Nc=x,this.hv=new Qe,this.Gl=this.Uo=0,this.Zo=new Qe,this.Ju=0}ey.prototype.toString=function(){return this.link.toString()+" "+this.angle.toString()+" "+this.Nc.toString()+":"+this.Uo.toString()+"/"+this.Gl.toString()+" "+this.Zo.toString()+" "+this.Ju.toString()+" "+this.hv.toString()},ey.className="LinkInfo";function as(a){jo(this),this.o=this.H=null,this.Gh=this.sn=!0,this.yn=!1,this.Am=new Qe(0,0).freeze(),this.vn=!0,this.Em=this.un=null,this.xn=!1,this.j=null,a&&Object.assign(this,a)}as.prototype.cloneProtected=function(a){a.sn=this.sn,a.Gh=this.Gh,a.yn=this.yn,a.Am.assign(this.Am),a.vn=this.vn,a.un=this.un,a.Em=this.Em,a.xn=!0},as.prototype.copy=function(){var a=new this.constructor;return this.cloneProtected(a),a},as.prototype.qb=function(){},as.prototype.toString=function(){var a=cr(this.constructor);return a+="(",this.group!==null&&(a+=" in "+this.group),this.diagram!==null&&(a+=" for "+this.diagram),a+")"},as.prototype.C=function(){if(this.isValidLayout){var a=this.diagram;if(a!==null&&!a.undoManager.isUndoingRedoing){var y=a.animationManager;!y.isTicking&&(y.defaultAnimation.isAnimating&&y.Cc(),this.isOngoing&&a.pi||this.isInitial&&!a.pi)&&(this.isValidLayout=!1,a.$b())}}},as.prototype.createNetwork=function(){return new za(this)},as.prototype.makeNetwork=function(a){var y=this.createNetwork();return a instanceof bt?(y.lg(a.nodes,!0),y.lg(a.links,!0)):a instanceof xr?y.lg(a.memberParts):y.lg(a.iterator),y},as.prototype.updateParts=function(){this.isValidLayout=!0;var a=this.diagram;if(a===null&&this.network!==null)for(var y=this.network.vertexes.iterator;y.next();){var x=y.value.node;if(x!==null&&(a=x.diagram,a!==null))break}try{a!==null&&a.Ea("Layout"),this.commitLayout()}finally{a!==null&&a.eb("Layout")}},as.prototype.commitLayout=function(){if(this.network!==null){for(var a=this.network.vertexes.iterator;a.next();)a.value.commit();if(this.isRouting)for(a=this.network.edges.iterator;a.next();)a.value.commit()}},as.prototype.doLayout=function(a){var y=new Pn;a instanceof bt?(_d(this,y,a.nodes,!0,this.rh,!0,!1,!0),_d(this,y,a.parts,!0,this.rh,!0,!1,!0)):a instanceof xr?_d(this,y,a.memberParts,!1,this.rh,!0,!1,!0):y.addAll(a.iterator),0<y.count&&(a=this.diagram,a!==null&&a.Ea("Layout"),this.doMinimalNoNetworkLayout(y),a!==null&&a.eb("Layout")),this.isValidLayout=!0},as.prototype.doMinimalNoNetworkLayout=function(a){var y=Math.ceil(Math.sqrt(a.count));this.arrangementOrigin=this.initialOrigin(this.arrangementOrigin);var x=this.arrangementOrigin.x,E=x,b=this.arrangementOrigin.y,z=0,ee=0;for(a=a.iterator;a.next();){var re=a.value;Np(re);var oe=re.measuredBounds,se=oe.width;oe=oe.height,re.moveTo(E,b),re instanceof xr&&(re.rh=!1),E+=Math.max(se,50)+20,ee=Math.max(ee,Math.max(oe,50)),z>=y-1?(z=0,E=x,b+=ee+20,ee=0):z++}},as.prototype.doMinimalNetworkLayout=function(){var a=Math.ceil(Math.sqrt(this.network.vertexes.count));this.arrangementOrigin=this.initialOrigin(this.arrangementOrigin);for(var y=this.arrangementOrigin.x,x=y,E=this.arrangementOrigin.y,b=0,z=0,ee=this.network.vertexes.iterator;ee.next();){var re=ee.value.node;if(!(re===null||re instanceof Tn)&&(Np(re),this.rh(re))){var oe=re.measuredBounds,se=oe.width;oe=oe.height,re.moveTo(x,E),re instanceof xr&&(re.rh=!1),x+=Math.max(se,50)+20,z=Math.max(z,Math.max(oe,50)),b>=a-1?(b=0,x=y,E+=z+20,z=0):b++}}},as.prototype.rh=function(a){return!!(!a.location.w()||a instanceof xr&&a.rh)};function _d(a,y,x,E,b,z,ee,re){for(x=x.iterator;x.next();){var oe=x.value;E&&!oe.isTopLevel||b!==null&&!b(oe)||!oe.canLayout()||(z&&oe instanceof qn?oe.isLinkLabel||(oe instanceof xr&&oe.layout===null?_d(a,y,oe.memberParts,!1,b,z,ee,re):(Np(oe),y.add(oe))):ee&&oe instanceof Tn?y.add(oe):!re||!oe.Zc()||oe instanceof qn||(Np(oe),y.add(oe)))}}function Np(a){var y=a.actualBounds;(y.width===0||y.height===0||isNaN(y.width)||isNaN(y.height))&&a.Va()}as.prototype.ni=function(a,y){var x=this.boundsComputation;return x!==null?(y||(y=new Xt),x(a,this,y)):y?(y.set(a.actualBounds),y):a.actualBounds},as.prototype.ex=function(a){var y=new Pn;return a instanceof bt?(_d(this,y,a.nodes,!0,null,!0,!0,!0),_d(this,y,a.links,!0,null,!0,!0,!0),_d(this,y,a.parts,!0,null,!0,!0,!0)):a instanceof xr?_d(this,y,a.memberParts,!1,null,!0,!0,!0):_d(this,y,a.iterator,!1,null,!0,!0,!0),y},as.prototype.initialOrigin=function(a){var y=this.group;if(y!==null){var x=y.position.copy();return(isNaN(x.x)||isNaN(x.y))&&x.set(a),y=y.placeholder,y!==null&&(x=y.ga(Cs),(isNaN(x.x)||isNaN(x.y))&&x.set(a),a=y.padding,x.x+=a.left,x.y+=a.top),x}return a},Yt.Object.defineProperties(as.prototype,{diagram:{get:function(){return this.H},set:function(a){this.H=a}},group:{get:function(){return this.o},set:function(a){this.o!==a&&(this.o=a,a!==null&&(this.H=a.diagram))}},isOngoing:{get:function(){return this.sn},set:function(a){this.sn!==a&&(this.sn=a)}},isInitial:{get:function(){return this.Gh},set:function(a){this.Gh=a,a||(this.xn=!0)}},isViewportSized:{get:function(){return this.yn},set:function(a){this.yn!==a&&(this.yn=a)&&this.C()}},isRouting:{get:function(){return this.vn},set:function(a){this.vn!==a&&(this.vn=a)}},isRealtime:{get:function(){return this.un},set:function(a){this.un!==a&&(this.un=a)}},isValidLayout:{get:function(){return this.xn},set:function(a){this.xn!==a&&(this.xn=a,a||(a=this.diagram,a!==null&&(a.xh=!0)))}},network:{get:function(){return this.j},set:function(a){this.j!==a&&(this.j=a,a!==null&&(a.layout=this))}},boundsComputation:{get:function(){return this.Em},set:function(a){this.Em!==a&&(this.Em=a,this.C())}},arrangementOrigin:{get:function(){return this.Am},set:function(a){this.Am.D(a)||(this.Am.assign(a),this.C())}}}),as.prototype.collectParts=as.prototype.ex,as.prototype.getLayoutBounds=as.prototype.ni,as.prototype.invalidateLayout=as.prototype.C,as.className="Layout";function za(a){jo(this),this.Sc=a,this.wf=new Pn,this.ye=new Pn,this.Es=new Li,this.zs=new Li}za.prototype.clear=function(){if(this.wf)for(var a=this.wf.iterator;a.next();)a.value.clear();if(this.ye)for(a=this.ye.iterator;a.next();)a.value.clear();this.wf=new Pn,this.ye=new Pn,this.Es=new Li,this.zs=new Li},za.prototype.toString=function(a){a===void 0&&(a=0);var y="LayoutNetwork"+(this.layout!==null?"("+this.layout.toString()+")":"");if(0>=a)return y;if(y+=" vertexes: "+this.wf.count+" edges: "+this.ye.count,1<a){for(var x=this.wf.iterator;x.next();)y+=`
`+x.value.toString(a-1);for(x=this.ye.iterator;x.next();)y+=`
`+x.value.toString(a-1)}return y},za.prototype.createVertex=function(){return new $s(this)},za.prototype.createEdge=function(){return new ih(this)},za.prototype.lg=function(a,y,x){if(a!==null){for(y===void 0&&(y=!1),x===void 0&&(x=null),x===null&&(x=function(ee){if(ee instanceof qn)return!ee.isLinkLabel;if(ee instanceof Tn){var re=ee.fromNode;return re===null||re.isLinkLabel?!1:(ee=ee.toNode,!(ee===null||ee.isLinkLabel))}return!1}),a=a.iterator;a.next();){var E=a.value;if(E instanceof qn&&(!y||E.isTopLevel)&&E.canLayout()&&x(E)){if(E instanceof xr&&E.layout===null)this.lg(E.memberParts,!1);else if(this.ki(E)===null){var b=this.createVertex();b.node=E,this.dh(b)}}}for(a.reset();a.next();)if(E=a.value,E instanceof Tn&&(!y||E.isTopLevel)&&E.canLayout()&&x(E)&&this.Lo(E)===null){var z=E.fromNode;b=E.toNode,z!==null&&b!==null&&z!==b&&(z=this.findGroupVertex(z),b=this.findGroupVertex(b),z!==null&&b!==null&&this.Zj(z,b,E))}}},za.prototype.findGroupVertex=function(a){if(a===null)return null;var y=a.findVisibleNode();if(y===null)return null;if(a=this.ki(y),a!==null)return a;for(y=y.containingGroup;y!==null;){if(a=this.ki(y),a!==null)return a;y=y.containingGroup}return null},we=za.prototype,we.dh=function(a){if(a!==null){this.wf.add(a);var y=a.node;y!==null&&this.Es.add(y,a),a.network=this}},we.Bl=function(a){if(a===null)return null;var y=this.ki(a);return y===null&&(y=this.createVertex(),y.node=a,this.dh(y)),y},we.Iu=function(a){if(a!==null&&l1(this,a)){for(var y=a.tg,x=y.count-1;0<=x;x--){var E=y.M(x);this.Mj(E)}for(y=a.mg,a=y.count-1;0<=a;a--)x=y.M(a),this.Mj(x)}};function l1(a,y){if(y===null)return!1;var x=a.wf.remove(y);return x&&(y=y.node,y!==null&&a.Es.remove(y)),x}we.Zy=function(a){a!==null&&(a=this.ki(a),a!==null&&this.Iu(a))},we.ki=function(a){return a===null?null:this.Es.I(a)},we.Bo=function(a){if(a!==null){ty(this,a);var y=a.toVertex;y!==null&&y.Cl(a),y=a.fromVertex,y!==null&&y.zl(a)}};function ty(a,y){if(y!==null){a.ye.add(y);var x=y.link;x!==null&&a.Lo(x)===null&&a.zs.add(x,y),y.network=a}}we.Dy=function(a){if(a===null)return null;var y=a.fromNode,x=a.toNode,E=this.Lo(a);return E===null?(E=this.createEdge(),E.link=a,y!==null&&(E.fromVertex=this.Bl(y)),x!==null&&(E.toVertex=this.Bl(x)),this.Bo(E)):(y!==null?E.fromVertex=this.Bl(y):E.fromVertex=null,x!==null?E.toVertex=this.Bl(x):E.toVertex=null),E},we.Mj=function(a){if(a!==null){var y=a.toVertex;y!==null&&y.Kl(a),y=a.fromVertex,y!==null&&y.Jl(a),ny(this,a)}};function ny(a,y){y!==null&&a.ye.remove(y)&&(y=y.link,y!==null&&a.zs.remove(y))}we.Yy=function(a){a!==null&&(a=this.Lo(a),a!==null&&this.Mj(a))},we.Lo=function(a){return a===null?null:this.zs.I(a)},we.Zj=function(a,y,x){if(a===null||y===null)return null;if(a.network===this&&y.network===this){var E=this.createEdge();return E.link=x,E.fromVertex=a,E.toVertex=y,this.Bo(E),E}return null},we.gm=function(a){if(a!==null){var y=a.fromVertex,x=a.toVertex;y!==null&&x!==null&&(y.Jl(a),x.Kl(a),a.gm(),y.Cl(a),x.zl(a))}},we.Ko=function(){for(var a=qi(),y=this.ye.iterator;y.next();){var x=y.value;x.fromVertex===x.toVertex&&a.push(x)}for(y=a.length,x=0;x<y;x++)this.Mj(a[x]);Zi(a)},za.prototype.deleteArtificialVertexes=function(){for(var a=qi(),y=this.wf.iterator;y.next();){var x=y.value;x.node===null&&x.data===null&&a.push(x)}for(x=a.length,y=0;y<x;y++)this.Iu(a[y]);for(y=qi(),x=this.ye.iterator;x.next();){var E=x.value;E.link===null&&E.data===null&&y.push(E)}for(x=y.length,E=0;E<x;E++)this.Mj(y[E]);Zi(a),Zi(y)};function Ax(a){for(var y=qi(),x=a.ye.iterator;x.next();){var E=x.value;E.fromVertex!==null&&E.toVertex!==null||y.push(E)}for(x=y.length,E=0;E<x;E++)a.Mj(y[E]);Zi(y)}za.prototype.Zx=function(a){a===void 0&&(a=!0),a&&(this.deleteArtificialVertexes(),Ax(this),this.Ko()),a=new An;for(var y=!0;y;){y=!1;for(var x=this.wf.iterator;x.next();){var E=x.value;if(0<E.tg.count||0<E.mg.count){y=this.layout.createNetwork(),a.add(y),iy(this,y,E),y=!0;break}}}return a.sort(function(b,z){return b===null||z===null||b===z?0:z.vertexes.count-b.vertexes.count}),a};function iy(a,y,x){if(x!==null&&x.network!==y){l1(a,x),y.dh(x);for(var E=x.sourceEdges;E.next();){var b=E.value;b.network!==y&&(ny(a,b),ty(y,b),iy(a,y,b.fromVertex))}for(E=x.destinationEdges;E.next();)x=E.value,x.network!==y&&(ny(a,x),ty(y,x),iy(a,y,x.toVertex))}}za.prototype.dz=function(){for(var a=new Pn,y=this.wf.iterator;y.next();)a.add(y.value.node);for(y=this.ye.iterator;y.next();)a.add(y.value.link);return a},Yt.Object.defineProperties(za.prototype,{layout:{get:function(){return this.Sc},set:function(a){a!==null&&(this.Sc=a)}},vertexes:{get:function(){return this.wf}},edges:{get:function(){return this.ye}}}),za.prototype.findAllParts=za.prototype.dz,za.prototype.splitIntoSubNetworks=za.prototype.Zx,za.prototype.deleteSelfEdges=za.prototype.Ko,za.prototype.reverseEdge=za.prototype.gm,za.prototype.linkVertexes=za.prototype.Zj,za.prototype.findEdge=za.prototype.Lo,za.prototype.deleteLink=za.prototype.Yy,za.prototype.deleteEdge=za.prototype.Mj,za.prototype.addLink=za.prototype.Dy,za.prototype.addEdge=za.prototype.Bo,za.prototype.findVertex=za.prototype.ki,za.prototype.deleteNode=za.prototype.Zy,za.prototype.deleteVertex=za.prototype.Iu,za.prototype.addNode=za.prototype.Bl,za.prototype.addVertex=za.prototype.dh,za.prototype.addParts=za.prototype.lg,za.className="LayoutNetwork";function $s(a){jo(this),this.ob=a,this.j=new Xt(0,0,10,10).freeze(),this.o=new Qe(5,5).freeze(),this.Sh=this.ub=null,this.tg=new An,this.mg=new An}$s.prototype.clear=function(){this.Sh=this.ub=null,this.tg=new An,this.mg=new An},$s.prototype.toString=function(a){a===void 0&&(a=0);var y="LayoutVertex#"+qa(this);if(0<a&&(y+=this.node!==null?"("+this.node.toString()+")":"",1<a)){a="";for(var x=!0,E=this.tg.iterator;E.next();){var b=E.value;x?x=!1:a+=",",a+=b.toString(0)}for(b="",x=!0,E=this.mg.iterator;E.next();){var z=E.value;x?x=!1:b+=",",b+=z.toString(0)}y+=" sources: "+a+" destinations: "+b}return y},$s.prototype.commit=function(){var a=this.ub;if(a!==null){var y=this.bounds,x=a.bounds;kn(x)?(x.x=y.x,x.y=y.y,x.width=y.width,x.height=y.height):a.bounds=y.copy()}else if(a=this.node,a!==null){if(y=this.bounds,!(a instanceof xr)){x=Xt.alloc(),a.Va();var E=this.network.layout.ni(a,x),b=a.locationObject.ga(ko);if(E.w()&&b.w()){a.moveTo(y.x+this.focusX-(b.x-E.x),y.y+this.focusY-(b.y-E.y)),Xt.free(x);return}Xt.free(x)}a.moveTo(y.x,y.y)}},$s.prototype.Cl=function(a){a!==null&&(this.tg.contains(a)||this.tg.add(a))},$s.prototype.Kl=function(a){a!==null&&this.tg.remove(a)},$s.prototype.zl=function(a){a!==null&&(this.mg.contains(a)||this.mg.add(a))},$s.prototype.Jl=function(a){a!==null&&this.mg.remove(a)};function ry(a,y){return a=a.Sh,y=y.Sh,a?y?(a=a.text,y=y.text,a<y?-1:a>y?1:0):1:y!==null?-1:0}Yt.Object.defineProperties($s.prototype,{sourceEdgesArrayAccess:{get:function(){return this.tg._dataArray}},destinationEdgesArrayAccess:{get:function(){return this.mg._dataArray}},data:{get:function(){return this.ub},set:function(a){if(this.ub=a,a!==null&&a.bounds){var y=a.bounds;a=y.x;var x=y.y,E=y.width;y=y.height,this.o.h(E/2,y/2),this.j.h(a,x,E,y)}}},node:{get:function(){return this.Sh},set:function(a){if(this.Sh!==a){this.Sh=a,a.Va();var y=this.network.layout,x=Xt.alloc(),E=y.ni(a,x);y=E.x;var b=E.y,z=E.width;if(E=E.height,isNaN(y)&&(y=0),isNaN(b)&&(b=0),this.j.h(y,b,z,E),Xt.free(x),!(a instanceof xr)&&(a=a.locationObject.ga(ko),a.w())){this.o.h(a.x-y,a.y-b);return}this.o.h(z/2,E/2)}}},bounds:{get:function(){return this.j},set:function(a){this.j.D(a)||this.j.assign(a)}},focus:{get:function(){return this.o},set:function(a){this.o.D(a)||this.o.assign(a)}},centerX:{get:function(){return this.j.x+this.o.x},set:function(a){var y=this.j;y.x+this.o.x!==a&&(y.ka(),y.x=a-this.o.x,y.freeze())}},centerY:{get:function(){return this.j.y+this.o.y},set:function(a){var y=this.j;y.y+this.o.y!==a&&(y.ka(),y.y=a-this.o.y,y.freeze())}},focusX:{get:function(){return this.o.x},set:function(a){var y=this.o;y.x!==a&&(y.ka(),y.x=a,y.freeze())}},focusY:{get:function(){return this.o.y},set:function(a){var y=this.o;y.y!==a&&(y.ka(),y.y=a,y.freeze())}},x:{get:function(){return this.j.x},set:function(a){var y=this.j;y.x!==a&&(y.ka(),y.x=a,y.freeze())}},y:{get:function(){return this.j.y},set:function(a){var y=this.j;y.y!==a&&(y.ka(),y.y=a,y.freeze())}},width:{get:function(){return this.j.width},set:function(a){var y=this.j;y.width!==a&&(y.ka(),y.width=a,y.freeze())}},height:{get:function(){return this.j.height},set:function(a){var y=this.j;y.height!==a&&(y.ka(),y.height=a,y.freeze())}},network:{get:function(){return this.ob},set:function(a){this.ob=a}},sourceVertexes:{get:function(){for(var a=new Pn,y=this.sourceEdges;y.next();)a.add(y.value.fromVertex);return a.iterator}},destinationVertexes:{get:function(){for(var a=new Pn,y=this.destinationEdges;y.next();)a.add(y.value.toVertex);return a.iterator}},vertexes:{get:function(){for(var a=new Pn,y=this.sourceEdges;y.next();)a.add(y.value.fromVertex);for(y=this.destinationEdges;y.next();)a.add(y.value.toVertex);return a.iterator}},sourceEdges:{get:function(){return this.tg.iterator}},destinationEdges:{get:function(){return this.mg.iterator}},edges:{get:function(){for(var a=new An,y=this.sourceEdges;y.next();)a.add(y.value);for(y=this.destinationEdges;y.next();)a.add(y.value);return a.iterator}},edgesCount:{get:function(){return this.tg.count+this.mg.count}}}),$s.prototype.deleteDestinationEdge=$s.prototype.Jl,$s.prototype.addDestinationEdge=$s.prototype.zl,$s.prototype.deleteSourceEdge=$s.prototype.Kl,$s.prototype.addSourceEdge=$s.prototype.Cl,$s.className="LayoutVertex",$s.standardComparer=ry,$s.smartComparer=function(a,y){if(a!==null){if(y!==null){a=a.Sh;var x=y.Sh;if(a!==null){if(x!==null){for(y=a.text.toLocaleLowerCase().split(/([+-]?[.]?\d+(?:\.\d*)?(?:e[+-]?\d+)?)/),a=x.text.toLocaleLowerCase().split(/([+-]?[.]?\d+(?:\.\d*)?(?:e[+-]?\d+)?)/),x=0;x<y.length;x++)if(a[x]!==""&&a[x]!==void 0){var E=parseFloat(y[x]),b=parseFloat(a[x]);if(isNaN(E))if(isNaN(b)){if(y[x].localeCompare(a[x])!==0)return y[x].localeCompare(a[x])}else return 1;else{if(isNaN(b))return-1;if(E-b!==0)return E-b}}else if(y[x]!=="")return 1;return a[x]!==""&&a[x]!==void 0?-1:0}return 1}return x!==null?-1:0}return 1}return y!==null?-1:0};function ih(a){jo(this),this.nb=a,this.qd=this.kd=this.$k=this.ub=null}ih.prototype.clear=function(){this.qd=this.kd=this.$k=this.ub=null},ih.prototype.toString=function(a){a===void 0&&(a=0);var y="LayoutEdge#"+qa(this);return 0<a&&(y+=this.$k!==null?"("+this.$k.toString()+")":"",1<a&&(y+=" "+(this.kd?this.kd.toString():"null")+" --> "+(this.qd?this.qd.toString():"null"))),y},ih.prototype.gm=function(){var a=this.kd;this.kd=this.qd,this.qd=a},ih.prototype.commit=function(){},ih.prototype.Ax=function(a){return this.qd===a?this.kd:this.kd===a?this.qd:null},Yt.Object.defineProperties(ih.prototype,{network:{get:function(){return this.nb},set:function(a){this.nb=a}},data:{get:function(){return this.ub},set:function(a){this.ub!==a&&(this.ub=a)}},link:{get:function(){return this.$k},set:function(a){this.$k!==a&&(this.$k=a)}},fromVertex:{get:function(){return this.kd},set:function(a){this.kd!==a&&(this.kd=a)}},toVertex:{get:function(){return this.qd},set:function(a){this.qd!==a&&(this.qd=a)}}}),ih.prototype.getOtherVertex=ih.prototype.Ax,ih.className="LayoutEdge";function Fl(a){as.call(this),this.isViewportSized=!0,this.yo=this.zo=NaN,this.yg=new fn(NaN,NaN).freeze(),this.tf=new fn(10,10).freeze(),this.Jb=Tp,this.Rb=sv,this.nd=Dp,this.hd=u1,a&&Object.assign(this,a)}Ct(Fl,as),Fl.prototype.cloneProtected=function(a){as.prototype.cloneProtected.call(this,a),a.zo=this.zo,a.yo=this.yo,a.yg.assign(this.yg),a.tf.assign(this.tf),a.Jb=this.Jb,a.Rb=this.Rb,a.nd=this.nd,a.hd=this.hd},Fl.prototype.qb=function(a){a.classType===Fl?a===Dp||a===uv||a===oy||a===lv?this.sorting=a:a===sv||a===pc?this.arrangement=a:a===Tp||a===av?this.alignment=a:Dt("Unknown enum value: "+a):as.prototype.qb.call(this,a)},Fl.prototype.doLayout=function(a){this.arrangementOrigin=this.initialOrigin(this.arrangementOrigin);var y=this.ex(a);a=this.diagram;for(var x=y.copy().iterator;x.next();){var E=x.value;if(!E.ph()||E.fromNode===null&&E.toNode===null){if(E.Va(),E instanceof xr)for(E=E.memberParts;E.next();)y.remove(E.value)}else y.remove(E)}var b=y.Fa();if(b.length!==0){switch(this.sorting){case lv:b.reverse();break;case Dp:b.sort(this.comparer);break;case uv:b.sort(this.comparer),b.reverse()}var z=this.wrappingColumn;isNaN(z)&&(z=0);var ee=this.wrappingWidth;switch(isNaN(ee)&&a!==null?(y=a.padding,ee=Math.max(a.viewportBounds.width-y.left-y.right,0)):ee=Math.max(this.wrappingWidth,0),0>=z&&0>=ee&&(z=1),y=this.spacing.width,isFinite(y)||(y=0),x=this.spacing.height,isFinite(x)||(x=0),a!==null&&a.Ea("Layout"),E=[],this.alignment){case av:var re=y,oe=x,se=Xt.alloc(),ue=Math.max(this.cellSize.width,1);if(!isFinite(ue))for(var fe=ue=0;fe<b.length;fe++){var ve=this.ni(b[fe],se);ue=Math.max(ue,ve.width)}if(ue=Math.max(ue+re,1),fe=Math.max(this.cellSize.height,1),!isFinite(fe))for(ve=fe=0;ve<b.length;ve++){var ye=this.ni(b[ve],se);fe=Math.max(fe,ye.height)}fe=Math.max(fe+oe,1),ve=this.arrangement;for(var Ce=ye=this.arrangementOrigin.x,Ae=this.arrangementOrigin.y,Ye=0,We=0,tt=0;tt<b.length;tt++){var rt=b[tt],at=this.ni(rt,se),gt=Math.ceil((at.width+re)/ue)*ue,At=Math.ceil((at.height+oe)/fe)*fe;switch(ve){case pc:var Zn=Math.abs(Ce-at.width);break;default:Zn=Ce+at.width}switch((0<z&&Ye>z-1||0<ee&&0<Ye&&Zn-ye>ee)&&(E.push(new Xt(0,Ae,ee+re,We)),Ye=0,Ce=ye,Ae+=We,We=0),We=Math.max(We,At),ve){case pc:at=-at.width;break;default:at=0}switch(rt.moveTo(Ce+at,Ae),ve){case pc:Ce-=gt;break;default:Ce+=gt}Ye++}E.push(new Xt(0,Ae,ee+re,We)),Xt.free(se);break;case Tp:for(oe=ee,ue=z,fe=y,ve=x,ee=Xt.alloc(),ye=Math.max(this.cellSize.width,1),z=Ae=se=0,re=Qe.alloc(),Ce=0;Ce<b.length;Ce++)We=b[Ce],Ye=this.ni(We,ee),We=Cd(We,We.locationObject,We.locationSpot,re),se=Math.max(se,We.x),Ae=Math.max(Ae,Ye.width-We.x),z=Math.max(z,We.y);switch(Ce=this.arrangement,Ce){case pc:se+=fe;break;default:Ae+=fe}ye=isFinite(ye)?Math.max(ye+fe,1):Math.max(se+Ae,1);var mi=We=this.arrangementOrigin.x;for(tt=this.arrangementOrigin.y,Ae=0,oe>=se&&(oe-=se),se=rt=0,gt=Math.max(this.cellSize.height,1),at=z=0,At=!0,Ye=Qe.alloc(),Zn=0;Zn<b.length;Zn++){var si=b[Zn],Nn=this.ni(si,ee),pn=Cd(si,si.locationObject,si.locationSpot,re);if(0<Ae)switch(Ce){case pc:mi=(mi-We-(Nn.width-pn.x))/ye,mi=yt.$(Math.round(mi),mi)?Math.round(mi):Math.floor(mi),mi=mi*ye+We;break;default:mi=(mi-We+pn.x)/ye,mi=yt.$(Math.round(mi),mi)?Math.round(mi):Math.ceil(mi),mi=mi*ye+We}else switch(Ce){case pc:rt=mi+pn.x+Nn.width;break;default:rt=mi-pn.x}switch(Ce){case pc:var yr=-(mi+pn.x)+rt;break;default:yr=mi+Nn.width-pn.x-rt}if(0<ue&&Ae>ue-1||0<oe&&0<Ae&&yr>oe){for(E.push(new Xt(0,At?tt-z:tt,oe+fe,at+z+ve)),mi=0;mi<Ae&&Zn!==Ae;mi++){yr=b[Zn-Ae+mi];var sr=Cd(yr,yr.locationObject,yr.locationSpot,Ye);yr.moveTo(yr.position.x,yr.position.y+z-sr.y)}at+=ve,tt=At?tt+at:tt+(at+z),Ae=at=z=0,mi=We,At=!1}switch(mi===We&&(se=Ce===pc?Math.max(se,Nn.width-pn.x):Math.min(se,-pn.x)),z=Math.max(z,pn.y),at=Math.max(at,Nn.height-pn.y),isFinite(gt)&&(at=Math.max(at,Math.max(Nn.height,gt)-pn.y)),At?si.moveTo(mi-pn.x,tt-pn.y):si.moveTo(mi-pn.x,tt),Ce){case pc:mi-=pn.x+fe;break;default:mi+=Nn.width-pn.x+fe}Ae++}if(E.push(new Xt(0,tt,oe+fe,(At?at:at+z)+ve)),b.length!==Ae)for(oe=0;oe<Ae;oe++)ue=b[b.length-Ae+oe],fe=Cd(ue,ue.locationObject,ue.locationSpot,re),ue.moveTo(ue.position.x,ue.position.y+z-fe.y);if(Qe.free(re),Qe.free(Ye),Ce===pc)for(b=0;b<E.length;b++)z=E[b],z.width+=se,z.x-=se;else for(b=0;b<E.length;b++)z=E[b],z.x>se&&(z.width+=z.x-se,z.x=se);Xt.free(ee)}for(re=z=ee=b=0;re<E.length;re++)oe=E[re],b=Math.min(b,oe.x),ee=Math.min(ee,oe.y),z=Math.max(z,oe.x+oe.width);this.arrangement===pc?this.commitLayers(E,new Qe(b+y/2-(z+b),ee-x/2)):this.commitLayers(E,new Qe(b-y/2,ee-x/2)),a!==null&&a.eb("Layout"),this.isValidLayout=!0}},Fl.prototype.commitLayers=function(){};function u1(a,y){return a=a.text,y=y.text,a<y?-1:a>y?1:0}Yt.Object.defineProperties(Fl.prototype,{wrappingWidth:{get:function(){return this.zo},set:function(a){this.zo!==a&&(0<a||isNaN(a))&&(this.zo=a,this.isViewportSized=isNaN(a),this.C())}},wrappingColumn:{get:function(){return this.yo},set:function(a){this.yo!==a&&(0<a||isNaN(a))&&(this.yo=a,this.C())}},cellSize:{get:function(){return this.yg},set:function(a){this.yg.D(a)||(this.yg.assign(a),this.C())}},spacing:{get:function(){return this.tf},set:function(a){this.tf.D(a)||(this.tf.assign(a),this.C())}},alignment:{get:function(){return this.Jb},set:function(a){this.Jb===a||a!==Tp&&a!==av||(this.Jb=a,this.C())}},arrangement:{get:function(){return this.Rb},set:function(a){this.Rb===a||a!==sv&&a!==pc||(this.Rb=a,this.C())}},sorting:{get:function(){return this.nd},set:function(a){this.nd===a||a!==oy&&a!==lv&&a!==Dp&&a!==uv||(this.nd=a,this.C())}},comparer:{get:function(){return this.hd},set:function(a){this.hd!==a&&(this.hd=a,this.C())}}});var av=new Vt(Fl,"Position",0),Tp=new Vt(Fl,"Location",1),sv=new Vt(Fl,"LeftToRight",2),pc=new Vt(Fl,"RightToLeft",3),oy=new Vt(Fl,"Forward",4),lv=new Vt(Fl,"Reverse",5),Dp=new Vt(Fl,"Ascending",6),uv=new Vt(Fl,"Descending",7);Fl.className="GridLayout",Fl.standardComparer=u1,Fl.smartComparer=function(a,y){if(a!==null){if(y!==null){a=a.text.toLocaleLowerCase().split(/([+-]?[.]?\d+(?:\.\d*)?(?:e[+-]?\d+)?)/),y=y.text.toLocaleLowerCase().split(/([+-]?[.]?\d+(?:\.\d*)?(?:e[+-]?\d+)?)/);for(var x=0;x<a.length;x++)if(y[x]!==""&&y[x]!==void 0){var E=parseFloat(a[x]),b=parseFloat(y[x]);if(isNaN(E))if(isNaN(b)){if(a[x].localeCompare(y[x])!==0)return a[x].localeCompare(y[x])}else return 1;else{if(isNaN(b))return-1;if(E-b!==0)return E-b}}else if(a[x]!=="")return 1;return y[x]!==""&&y[x]!==void 0?-1:0}return 1}return y!==null?-1:0},Fl.Position=av,Fl.Location=Tp,Fl.LeftToRight=sv,Fl.RightToLeft=pc,Fl.Forward=oy,Fl.Reverse=lv,Fl.Ascending=Dp,Fl.Descending=uv;function oa(){this.On=new Pn,this.Dn=new Pn,this.Pa=new Pn,this.cf=new Li,this.bf=new Li,this.aj=new Li,this.H=null,this.tp=!1}we=oa.prototype,we.clear=function(){this.On.clear(),this.Dn.clear(),this.Pa.clear(),this.cf.clear(),this.bf.clear(),this.aj.clear()},we.Xe=function(a){this.H=a},we.oi=function(a){if(a instanceof qn){if(this.On.add(a),a instanceof xr){var y=a.containingGroup;y===null?this.H.ai.add(a):y.gl.add(a),y=a.layout,y!==null&&(y.diagram=this.H)}}else a instanceof Tn?this.Dn.add(a):a instanceof Fo||this.Pa.add(a);y=a.data,y===null||a instanceof Fo||(a instanceof Tn?this.bf.add(y,a):this.cf.add(y,a))},we.pc=function(a){if(a.Ej(),a instanceof qn){if(this.On.remove(a),a instanceof xr){var y=a.containingGroup;y===null?this.H.ai.remove(a):y.gl.remove(a),y=a.layout,y!==null&&(y.diagram=null)}}else a instanceof Tn?this.Dn.remove(a):a instanceof Fo||this.Pa.remove(a);y=a.data,y===null||a instanceof Fo||(a instanceof Tn?this.bf.remove(y):this.cf.remove(y))},we.Wd=function(){var a=this.H;if(a!==null){for(var y=a.nodeTemplateMap.iterator;y.next();){var x=y.value,E=y.key;(!x.Zc()||x instanceof xr)&&Dt('Invalid node template in Diagram.nodeTemplateMap: template for "'+E+'" must be a Node or a simple Part, not a Group or Link: '+x)}for(y=a.groupTemplateMap.iterator;y.next();)x=y.value,E=y.key,x instanceof xr||Dt('Invalid group template in Diagram.groupTemplateMap: template for "'+E+'" must be a Group, not a normal Node or Link: '+x);for(y=a.linkTemplateMap.iterator;y.next();)x=y.value,E=y.key,x instanceof Tn||Dt('Invalid link template in Diagram.linkTemplateMap: template for "'+E+'" must be a Link, not a normal Node or simple Part: '+x);for(y=qi(),x=a.selection.iterator;x.next();)(E=x.value.data)&&y.push(E);for(x=qi(),a=a.highlighteds.iterator;a.next();)(E=a.value.data)&&x.push(E);for(a=qi(),E=this.nodes.iterator;E.next();){var b=E.value;b.data!==null&&(a.push(b.data),a.push(b.location))}for(E=this.links.iterator;E.next();)b=E.value,b.data!==null&&(a.push(b.data),a.push(b.location));for(E=this.parts.iterator;E.next();)b=E.value,b.data!==null&&(a.push(b.data),a.push(b.location));for(this.removeAllModeledParts(),this.addAllModeledParts(),E=0;E<y.length;E++)b=this.Lc(y[E]),b!==null&&(b.isSelected=!0);for(E=0;E<x.length;E++)b=this.Lc(x[E]),b!==null&&(b.isHighlighted=!0);for(E=0;E<a.length;E+=2)b=this.Lc(a[E]),b!==null&&(b.location=a[E+1]);Zi(y),Zi(x),Zi(a)}},oa.prototype.addAllModeledParts=function(){this.addModeledParts(this.diagram.model.nodeDataArray)},oa.prototype.addModeledParts=function(a,y){var x=this,E=this.diagram.model;a.forEach(function(b){E.lb(b)&&h1(x,b,!1)}),a.forEach(function(b){E.lb(b)&&x.resolveReferencesForData(b)}),y!==!1&&td(this.diagram,!1)};function h1(a,y,x){if(y!=null&&!a.diagram.undoManager.isUndoingRedoing&&!a.cf.contains(y)){x===void 0&&(x=!0);e:{if(y!=null&&!a.H.undoManager.isUndoingRedoing&&!a.cf.contains(y)){var E=a.Ro(y),b=c1(a,y,E);if(b!==null&&(_h(b),b=b.copy(),b!==null)){var z=a.diagram.skipsModelSourceBindings;a.diagram.skipsModelSourceBindings=!0,b.Tf=E,b.ub=y,a.tp&&(b.Jg="Tool"),a.diagram.add(b),b.ub=null,b.data=y,a.diagram.skipsModelSourceBindings=z,E=b;break e}}E=null}E!==null&&x&&a.resolveReferencesForData(y)}}oa.prototype.insertLink=function(){return null},oa.prototype.resolveReferencesForData=function(){},oa.prototype.Ro=function(a){return this.H.model.Ro(a)};function c1(a,y,x){a=a.H;var E=a.model;return E.Xj()&&E.Yu(y)?(y=a.groupTemplateMap.I(x),y===null&&(y=a.groupTemplateMap.I(""),y===null&&(g1||(g1=!0,eo('No Group template found for category "'+x+'"'),eo(" Using default group template")),y=a.ly))):(y=a.nodeTemplateMap.I(x),y===null&&(y=a.nodeTemplateMap.I(""),y===null&&(f1||(f1=!0,eo('No Node template found for category "'+x+'"'),eo(" Using default node template")),y=a.ny))),y}oa.prototype.getLinkCategoryForData=function(){return""},oa.prototype.setLinkCategoryForData=function(){},oa.prototype.setFromNodeForLink=function(){},oa.prototype.setToNodeForLink=function(){},oa.prototype.findLinkTemplateForCategory=function(a){var y=this.H,x=y.linkTemplateMap.I(a);return x===null&&(x=y.linkTemplateMap.I(""),x===null&&(p1||(p1=!0,eo('No Link template found for category "'+a+'"'),eo(" Using default link template")),x=y.my)),x},oa.prototype.removeAllModeledParts=function(){this.Gs(this.diagram.model.nodeDataArray)},oa.prototype.Gs=function(a){var y=this;a.forEach(function(x){y.ip(x)})},oa.prototype.ip=function(a){a=this.Lc(a),a!==null&&(ed(this.diagram,a,!1),this.unresolveReferencesForPart(a))},oa.prototype.unresolveReferencesForPart=function(){},oa.prototype.removeDataForLink=function(){},oa.prototype.findPartForKey=function(a){return a==null?null:(a=this.H.model.hc(a),a!==null?this.cf.I(a):null)},oa.prototype.Vb=function(a){return a==null||(a=this.H.model.hc(a),a===null)?null:(a=this.cf.I(a),a instanceof qn?a:null)},oa.prototype.findLinkForKey=function(){return null},we=oa.prototype,we.Lc=function(a){if(a===null)return null;var y=this.cf.I(a);return y!==null?y:y=this.bf.I(a)},we.ii=function(a){return a===null?null:(a=this.cf.I(a),a instanceof qn?a:null)},we.Kc=function(a){return a===null?null:this.bf.I(a)},we.ms=function(a){for(var y=0;y<arguments.length;++y);y=new Pn;for(var x=this.On.iterator;x.next();){var E=x.value,b=E.data;if(b!==null)for(var z=0;z<arguments.length;z++){var ee=arguments[z];if(kn(ee)&&ay(this,b,ee)){y.add(E);break}}}return y.iterator},we.ls=function(a){for(var y=0;y<arguments.length;++y);y=new Pn;for(var x=this.Dn.iterator;x.next();){var E=x.value,b=E.data;if(b!==null)for(var z=0;z<arguments.length;z++){var ee=arguments[z];if(kn(ee)&&ay(this,b,ee)){y.add(E);break}}}return y.iterator};function ay(a,y,x){for(var E in x){var b=y[E],z=x[E];if(Xi(z)){if(!Xi(b)||b.length<z.length)return!1;for(var ee=0;ee<b.length;ee++){var re=z[ee];if(re!==void 0&&!d1(a,b[ee],re))return!1}}else if(!d1(a,b,z))return!1}return!0}function d1(a,y,x){if(typeof x=="function"){if(!x(y))return!1}else if(x instanceof RegExp){if(!y||!x.test(y.toString()))return!1}else if(kn(y)&&kn(x)){if(!ay(a,y,x))return!1}else if(y!==x)return!1;return!0}oa.prototype.doModelChanged=function(a){if(this.H){var y=this.H;if(a.model===y.model){var x=a.change;if(y.doModelChanged(a),y.aa){y.aa=!1;try{var E=a.modelChange;if(E!=="")if(x===ga){if(E==="nodeCategory"){var b=this.Lc(a.object),z=a.newValue;b!==null&&typeof z=="string"&&(b.category=z)}else E==="nodeDataArray"&&(this.Gs(a.oldValue),this.addModeledParts(a.newValue));y.isModified=!0}else if(x===ts){var ee=a.newValue;E==="nodeDataArray"&&kn(ee)&&h1(this,ee),y.isModified=!0}else if(x===ss){var re=a.oldValue;E==="nodeDataArray"&&kn(re)&&this.ip(re),y.isModified=!0}else x===sl&&(E==="SourceChanged"?a.object!==null?this.updateDataBindings(a.object,a.propertyName):(this.rp(),this.updateAllTargetBindings()):E==="ModelDisplaced"&&this.Wd());else if(x===ga){var oe=a.propertyName,se=a.object;se===y.model?(oe==="nodeKeyProperty"||oe==="nodeCategoryProperty")&&(y.undoManager.isUndoingRedoing||this.Wd()):this.updateDataBindings(se,oe),y.isModified=!0}else if(x===ts||x===ss){var ue=a.change===ts,fe=ue?a.newParam:a.oldParam,ve=ue?a.newValue:a.oldValue,ye=this.aj.I(a.object);if(Array.isArray(ye))for(a=0;a<ye.length;a++){var Ce=ye[a];if(ue)km(Ce,ve,fe,!0);else if(!(0>fe)){var Ae=fe+gp(Ce);Ce.pc(Ae,!0),x0(Ce,Ae,fe)}}y.isModified=!0}}finally{y.aa=!0}}}}},oa.prototype.updateAllTargetBindings=function(a){a===void 0&&(a="");for(var y=this.parts.iterator;y.next();)y.value.La(a);for(y=this.nodes.iterator;y.next();)y.value.La(a);for(y=this.links.iterator;y.next();)y.value.La(a)},oa.prototype.rp=function(){for(var a=this.H.model,y=new Pn,x=a.nodeDataArray,E=0;E<x.length;E++)y.add(x[E]);var b=[];for(this.nodes.each(function(ee){ee.data===null||y.contains(ee.data)||b.push(ee.data)}),this.parts.each(function(ee){ee.data===null||y.contains(ee.data)||b.push(ee.data)}),b.forEach(function(ee){E1(a,ee,!1)}),E=0;E<x.length;E++){var z=x[E];this.Lc(z)===null&&C1(a,z,!1)}for(this.refreshDataBoundLinks(),x=this.parts.iterator;x.next();)x.value.updateRelationshipsFromData();for(x=this.nodes.iterator;x.next();)x.value.updateRelationshipsFromData();for(x=this.links.iterator;x.next();)x.value.updateRelationshipsFromData()},oa.prototype.refreshDataBoundLinks=function(){},oa.prototype.updateRelationshipsFromData=function(){},oa.prototype.updateDataBindings=function(a,y){if(typeof y=="string"){var x=this.Lc(a);if(x!==null)x.La(y);else{x=null;for(var E=this.aj.iterator;E.next();){for(var b=E.value,z=0;z<b.length;z++){var ee=b[z].sx(a);ee!==null&&(x===null&&(x=qi()),x.push(ee))}if(x!==null)break}if(x!==null){for(E=0;E<x.length;E++)x[E].La(y);Zi(x)}}a===this.diagram.model.modelData&&this.updateAllTargetBindings(y)}};function sy(a,y){var x=y.Hh;if(Xi(x)){var E=a.aj.I(x);if(E===null)E=[],E.push(y),a.aj.add(x,E);else{for(a=0;a<E.length;a++)if(E[a]===y)return;E.push(y)}}}function ly(a,y,x){Sf(y,function(ee){ee=ee.O.s;for(var re=ee.length,oe=0;oe<re;oe++)Mc(x,ee[oe])});var E=y.Hh;if(Xi(E)){var b=a.aj.I(E);if(b!==null){for(var z=0;z<b.length;z++)if(b[z]===y){b.splice(z,1),b.length===0&&a.aj.remove(E);break}}}}oa.prototype.Kj=function(a,y,x){x===void 0&&(x=!1);var E=new Li;if(Xi(a))for(var b=0;b<a.length;b++)hv(this,a[b],y,E,x);else for(a=a.iterator;a.next();)hv(this,a.value,y,E,x);if(y!==null){x=y.model,a=y.toolManager.findTool("Dragging"),a=a!==null?a.dragOptions.dragsLink:y.Wm.dragsLink,b=new Pn;for(var z=new Li,ee=E.iterator;ee.next();){var re=ee.value;if(re instanceof Tn)a||re.fromNode!==null&&re.toNode!==null||b.add(re);else if(re instanceof qn&&re.data!==null&&x.Tl()){var oe=re;re=ee.key;var se=re.pg();se!==null&&(se=E.I(se),se!==null?(x.qe(oe.data,x.wa(se.data)),oe=y.Kc(oe.data),re=re.kh(),re!==null&&oe!==null&&z.add(re,oe)):x.qe(oe.data,void 0))}}if(0<b.count&&y.Is(b,!1),0<z.count)for(x=z.iterator;x.next();)E.add(x.key,x.value)}if(y!==null&&this.H!==null&&(y=y.model,x=y.afterCopyFunction,x!==null)){var ue=new Li;E.each(function(fe){fe.key.data!==null&&ue.add(fe.key.data,fe.value.data)}),x(ue,y,this.H.model)}for(y=E.iterator;y.next();)y.value.La();return E};function hv(a,y,x,E,b){if(y===null||b&&!y.canCopy())return null;if(E.contains(y))return E.I(y);var z=a.copyPartData(y,x);if(!(z instanceof Ii))return null;if(z.isSelected=!1,z.isHighlighted=!1,E.add(y,z),y instanceof qn){for(var ee=y.linksConnected;ee.next();){var re=ee.value;if(re.fromNode===y){var oe=E.I(re);oe!==null&&(oe.fromNode=z)}re.toNode===y&&(re=E.I(re),re!==null&&(re.toNode=z))}if(y instanceof xr&&z instanceof xr)for(y=y.memberParts;y.next();)ee=hv(a,y.value,x,E,b),ee instanceof Tn||ee===null||(ee.containingGroup=z)}else if(y instanceof Tn&&z instanceof Tn)for(ee=y.fromNode,ee!==null&&(ee=E.I(ee),ee!==null&&(z.fromNode=ee)),ee=y.toNode,ee!==null&&(ee=E.I(ee),ee!==null&&(z.toNode=ee)),y=y.labelNodes;y.next();)ee=hv(a,y.value,x,E,b),ee!==null&&ee instanceof qn&&(ee.labeledLink=z);return z}oa.prototype.copyPartData=function(a,y){var x=null,E=a.data;if(E!==null&&y!==null){var b=y.model;a instanceof Tn||(E=b.copyNodeData(E),kn(E)&&(b.xf(E),x=y.Lc(E)))}else _h(a),x=a.copy(),x!==null&&(b=this.H,y!==null?y.add(x):E!==null&&b!==null&&b.commandHandler!==null&&b.commandHandler.copiesClipboardData&&(y=b.model,b=null,x instanceof Tn||(b=y.copyNodeData(E)),kn(b)&&(x.data=b)));return x},Yt.Object.defineProperties(oa.prototype,{nodes:{get:function(){return this.On}},links:{get:function(){return this.Dn}},parts:{get:function(){return this.Pa}},diagram:{get:function(){return this.H}},addsToTemporaryLayer:{get:function(){return this.tp},set:function(a){this.tp=a}}}),oa.prototype.updateAllRelationshipsFromData=oa.prototype.rp,oa.prototype.findLinksByExample=oa.prototype.ls,oa.prototype.findNodesByExample=oa.prototype.ms,oa.prototype.findLinkForData=oa.prototype.Kc,oa.prototype.findNodeForData=oa.prototype.ii,oa.prototype.findPartForData=oa.prototype.Lc,oa.prototype.findNodeForKey=oa.prototype.Vb,oa.prototype.removeModeledPart=oa.prototype.ip,oa.prototype.removeModeledParts=oa.prototype.Gs,oa.prototype.rebuildParts=oa.prototype.Wd;var f1=!1,g1=!1,p1=!1;oa.className="PartManager";function xl(a){oa.apply(this,arguments)}Ct(xl,oa),xl.prototype.addAllModeledParts=function(){var a=this.diagram.model;this.addModeledParts(a.nodeDataArray),m1(this,a.linkDataArray)},xl.prototype.addModeledParts=function(a){for(oa.prototype.addModeledParts.call(this,a,!1),a=this.links.iterator;a.next();)kg(a.value);td(this.diagram,!1)};function m1(a,y){y.forEach(function(x){v1(a,x)}),td(a.diagram,!1)}function v1(a,y){if(y!=null&&!a.diagram.undoManager.isUndoingRedoing&&!a.bf.contains(y)){var x=a.getLinkCategoryForData(y),E=a.findLinkTemplateForCategory(x);if(E!==null){_h(E);var b=E.copy();if(b!==null){E=a.diagram.skipsModelSourceBindings,a.diagram.skipsModelSourceBindings=!0,b.Tf=x,b.ub=y,x=a.diagram.model;var z=gv(x,y,!0);z!==""&&(b.fromPortId=z),z=yh(x,y,!0),z!==void 0&&(z=a.Vb(z),z instanceof qn&&(b.fromNode=z)),z=gv(x,y,!1),z!==""&&(b.toPortId=z),z=yh(x,y,!1),z!==void 0&&(z=a.Vb(z),z instanceof qn&&(b.toNode=z)),x=x.Ef(y),Array.isArray(x)&&x.forEach(function(ee){ee=a.Vb(ee),ee!==null&&(ee.labeledLink=b)}),a.tp&&(b.Jg="Tool"),a.diagram.add(b),b.ub=null,b.data=y,a.diagram.skipsModelSourceBindings=E}}}}xl.prototype.removeAllModeledParts=function(){var a=this.diagram.model;y1(this,a.linkDataArray),this.Gs(a.nodeDataArray)};function y1(a,y){y.forEach(function(x){a.ip(x)})}xl.prototype.getLinkCategoryForData=function(a){return this.diagram.model.ps(a)},xl.prototype.setLinkCategoryForData=function(a,y){return this.diagram.model.lp(a,y)},xl.prototype.setFromNodeForLink=function(a,y){var x=this.diagram.model;x.wv(a.data,x.wa(y!==null?y.data:null))},xl.prototype.setToNodeForLink=function(a,y){var x=this.diagram.model;x.Bv(a.data,x.wa(y!==null?y.data:null))},xl.prototype.removeDataForLink=function(a){this.diagram.model.bm(a.data)},xl.prototype.findPartForKey=function(a){var y=oa.prototype.findPartForKey.call(this,a);return y===null&&(a=this.diagram.model.jh(a),a!==null)?this.bf.I(a):y},xl.prototype.findLinkForKey=function(a){return a==null?null:(a=this.diagram.model.jh(a),a!==null?this.bf.I(a):null)},xl.prototype.doModelChanged=function(a){var y=this;if(oa.prototype.doModelChanged.call(this,a),this.diagram){var x=this.diagram;if(a.model===x.model){var E=a.change;if(x.aa){x.aa=!1;try{var b=a.modelChange;if(b!==""){if(E===ga){if(b==="linkFromKey"){var z=this.Kc(a.object);if(z!==null){var ee=this.Vb(a.newValue);z.fromNode=ee}}else if(b==="linkToKey"){var re=this.Kc(a.object);if(re!==null){var oe=this.Vb(a.newValue);re.toNode=oe}}else if(b==="linkFromPortId"){var se=this.Kc(a.object);if(se!==null){var ue=a.newValue;typeof ue=="string"&&(se.fromPortId=ue)}}else if(b==="linkToPortId"){var fe=this.Kc(a.object);if(fe!==null){var ve=a.newValue;typeof ve=="string"&&(fe.toPortId=ve)}}else if(b==="nodeGroupKey"){var ye=this.Lc(a.object);if(ye!==null){var Ce=a.newValue;if(Ce!==void 0){var Ae=this.Vb(Ce);Ae instanceof xr?ye.containingGroup=Ae:ye.containingGroup=null}else ye.containingGroup=null}}else if(b==="linkLabelKeys"){var Ye=this.Kc(a.object);if(Ye!==null){var We=a.oldValue,tt=a.newValue;Array.isArray(We)&&We.forEach(function(pn){0<=tt.indexOf(pn)||(pn=y.Vb(pn),pn!==null&&(pn.labeledLink=null))}),Array.isArray(tt)&&tt.forEach(function(pn){pn=y.Vb(pn),pn!==null&&(pn.labeledLink=Ye)})}}else if(b==="linkCategory"){var rt=this.Kc(a.object),at=a.newValue;rt!==null&&typeof at=="string"&&(rt.category=at)}else b==="linkDataArray"&&(y1(this,a.oldValue),m1(this,a.newValue));x.isModified=!0}else if(E===ts){var gt=a.newValue;if(b==="linkDataArray"&&typeof gt=="object"&&gt!==null)v1(this,gt);else if(b==="linkLabelKeys"&&Xd(gt)){var At=this.Kc(a.object),Zn=this.Vb(gt);At!==null&&Zn!==null&&(Zn.labeledLink=At)}x.isModified=!0}else if(E===ss){var mi=a.oldValue;if(b==="linkDataArray"&&typeof mi=="object"&&mi!==null)this.ip(mi);else if(b==="linkLabelKeys"&&Xd(mi)){var si=this.Vb(mi);si!==null&&(si.labeledLink=null)}x.isModified=!0}}else if(E===ga){var Nn=a.propertyName;a.object!==x.model||Nn!=="linkFromKeyProperty"&&Nn!=="linkToKeyProperty"&&Nn!=="linkFromPortIdProperty"&&Nn!=="linkToPortIdProperty"&&Nn!=="linkLabelKeysProperty"&&Nn!=="nodeIsGroupProperty"&&Nn!=="nodeGroupKeyProperty"&&Nn!=="linkCategoryProperty"||x.undoManager.isUndoingRedoing||this.Wd(),x.isModified=!0}}finally{x.aa=!0}}}}},xl.prototype.refreshDataBoundLinks=function(){var a=this,y=this.diagram.model,x=new Pn,E=y.linkDataArray;E.forEach(function(z){x.add(z)});var b=[];this.links.each(function(z){z.data===null||x.contains(z.data)||b.push(z.data)}),b.forEach(function(z){A1(y,z,!1)}),E.forEach(function(z){a.Kc(z)===null&&F1(y,z,!1)})},xl.prototype.updateRelationshipsFromData=function(a){var y=a.data;if(y!==null){var x=a.diagram;if(x!==null){var E=x.model;if(a instanceof Tn){var b=yh(E,y,!0);if(b=x.Vb(b),a.fromNode=b,b=yh(E,y,!1),b=x.Vb(b),a.toNode=b,y=E.Ef(y),0<y.length||0<a.labelNodes.count){if(y.length===1&&a.labelNodes.count===1){b=y[0];var z=a.labelNodes.first();if(E.wa(z.data)===b)return}b=new Pn().addAll(y);var ee=new Pn;a.labelNodes.each(function(re){re.data!==null&&(re=E.wa(re.data),re!==void 0&&ee.add(re))}),y=ee.copy(),y.hp(b),b=b.copy(),b.hp(ee),(0<y.count||0<b.count)&&(y.each(function(re){re=x.Vb(re),re!==null&&re.labeledLink===a&&(re.labeledLink=null)}),b.each(function(re){re=x.Vb(re),re!==null&&re.labeledLink!==a&&(re.labeledLink=a)}))}}else!(a instanceof Fo)&&(y=E.lh(y),y=x.findPartForKey(y),y===null||y instanceof xr)&&(a.containingGroup=y)}}},xl.prototype.resolveReferencesForData=function(a){var y=this.diagram.model,x=y.wa(a);if(x!==void 0){var E=Bp(y,x),b=this.Lc(a);if(E!==null&&b!==null){E=E.iterator;for(var z={};E.next();){var ee=E.value;y.lb(ee)?b instanceof xr&&y.lh(ee)===x&&(ee=this.Lc(ee),ee!==null&&(ee.containingGroup=b)):(z.link=this.Kc(ee),z.link!==null&&b instanceof qn&&(yh(y,ee,!0)===x&&(z.link.fromNode=b),yh(y,ee,!1)===x&&(z.link.toNode=b),ee=y.Ef(ee),Array.isArray(ee)&&ee.some(function(re){return function(oe){return oe===x?(b.labeledLink=re.link,!0):!1}}(z)))),z={link:z.link}}vc(y,x)}a=y.lh(a),a!==void 0&&(a=this.Vb(a),a instanceof xr&&(b.containingGroup=a))}},xl.prototype.unresolveReferencesForPart=function(a){var y=this.diagram.model;if(a instanceof qn){var x=y.wa(a.data);if(x!==void 0){for(var E=a.linksConnected;E.next();)mc(y,x,E.value.data);if(a.isLinkLabel&&(E=a.labeledLink,E!==null&&mc(y,x,E.data)),a instanceof xr)for(a=a.memberParts;a.next();)E=a.value.data,y.lb(E)&&mc(y,x,E)}}},xl.prototype.copyPartData=function(a,y){var x=oa.prototype.copyPartData.call(this,a,y);if(a instanceof Tn)if(a=a.data,a!==null&&y!==null){var E=y.model;a=E.Jo(a),typeof a=="object"&&a!==null&&(E.fi(a),x=y.Kc(a))}else x!==null&&(y=this.diagram,a!==null&&y!==null&&y.commandHandler!==null&&y.commandHandler.copiesClipboardData&&(y=y.model.Jo(a),typeof y=="object"&&y!==null&&(x.data=y)));return x},xl.prototype.insertLink=function(a,y,x,E){var b=this.diagram,z=b.model,ee=b.toolManager.findTool("Linking"),re="";if(a!==null&&(y===null&&(y=a),re=y.portId,re===null&&(re="")),y="",x!==null&&(E===null&&(E=x),y=E.portId,y===null&&(y="")),E=ee.archetypeLinkData,E instanceof Tn){if(_h(E),z=E.copy(),z!==null)return z.fromNode=a,z.fromPortId=re,z.toNode=x,z.toPortId=y,b.add(z),a=ee.archetypeLabelNodeData,a instanceof qn&&(_h(a),a=a.copy(),a!==null&&(a.labeledLink=z,b.add(a))),z}else if(E!==null&&(E=z.Jo(E),typeof E=="object"&&E!==null))return a!==null&&Bg(z,E,z.wa(a.data),!0),Og(z,E,re,!0),x!==null&&Bg(z,E,z.wa(x.data),!1),Og(z,E,y,!1),z.fi(E),a=ee.archetypeLabelNodeData,a===null||a instanceof qn||(a=z.copyNodeData(a),typeof a=="object"&&a!==null&&(z.xf(a),a=z.wa(a),a!==void 0&&z.Bu(E,a))),b.Kc(E);return null},xl.prototype.findLinkForKey=xl.prototype.findLinkForKey,xl.prototype.findPartForKey=xl.prototype.findPartForKey,xl.prototype.removeAllModeledParts=xl.prototype.removeAllModeledParts,xl.prototype.addModeledParts=xl.prototype.addModeledParts,xl.prototype.addAllModeledParts=xl.prototype.addAllModeledParts,xl.className="GraphLinksPartManager";function Oh(){oa.apply(this,arguments),this.Sg=null}Ct(Oh,oa);function cv(a,y,x){if(y!==null&&x!==null&&x.kh()===null){var E=a.diagram.toolManager.findTool("Linking"),b=y,z=x;if(a.diagram.isTreePathToChildren||(b=x,z=y),(E===null||!No(E,b,z,null,!0))&&(y=a.getLinkCategoryForData(x.data),E=a.findLinkTemplateForCategory(y),E!==null&&(_h(E),E=E.copy(),E!==null))){var ee=a.diagram.skipsModelSourceBindings;a.diagram.skipsModelSourceBindings=!0,E.Tf=y,E.ub=x.data,E.fromNode=b,E.toNode=z,a.diagram.add(E),E.ub=null,E.data=x.data,a.diagram.skipsModelSourceBindings=ee}}}Oh.prototype.getLinkCategoryForData=function(a){return this.diagram.model.ss(a)},Oh.prototype.setLinkCategoryForData=function(a,y){this.diagram.model.Ms(a,y)},Oh.prototype.setFromNodeForLink=function(a,y,x){var E=this.diagram.model;if(x===void 0&&(x=null),y=y!==null?y.data:null,this.diagram.isTreePathToChildren)E.qe(a.data,E.wa(y));else{var b=this.Sg;this.Sg=a,x!==null&&E.qe(x.data,void 0),E.qe(y,E.wa(a.toNode!==null?a.toNode.data:null)),this.Sg=b}},Oh.prototype.setToNodeForLink=function(a,y,x){var E=this.diagram.model;if(x===void 0&&(x=null),y=y!==null?y.data:null,this.diagram.isTreePathToChildren){var b=this.Sg;this.Sg=a,x!==null&&E.qe(x.data,void 0),E.qe(y,E.wa(a.fromNode!==null?a.fromNode.data:null)),this.Sg=b}else E.qe(a.data,E.wa(y))},Oh.prototype.removeDataForLink=function(a){this.diagram.model.qe(a.data,void 0)},Oh.prototype.findLinkForKey=function(a){return a==null?null:(a=this.diagram.model.hc(a),a!==null?this.bf.I(a):null)},Oh.prototype.doModelChanged=function(a){if(oa.prototype.doModelChanged.call(this,a),this.diagram){var y=this.diagram;if(a.model===y.model){var x=a.change;if(y.aa){y.aa=!1;try{var E=a.modelChange;if(E!==""){if(x===ga){if(E==="nodeParentKey"){var b=a.object,z=this.Vb(a.newValue),ee=this.ii(b);if(this.Sg!==null)z!==null&&(this.Sg.data=b,this.Sg.category=this.getLinkCategoryForData(b));else if(ee!==null){var re=ee.kh();re!==null?z===null?y.remove(re):y.isTreePathToChildren?re.fromNode=z:re.toNode=z:cv(this,z,ee)}}else if(E==="parentLinkCategory"){var oe=this.ii(a.object),se=a.newValue;if(oe!==null&&typeof se=="string"){var ue=oe.kh();ue!==null&&(ue.category=se)}}y.isModified=!0}}else if(x===ga){var fe=a.propertyName;a.object===y.model&&fe==="nodeParentKeyProperty"&&(y.undoManager.isUndoingRedoing||this.Wd()),y.isModified=!0}}finally{y.aa=!0}}}}},Oh.prototype.updateRelationshipsFromData=function(a){var y=a.data;if(y!==null){var x=a.diagram;if(x!==null){var E=x.model;a instanceof qn&&(y=E.mh(y),y=x.Vb(y),E=a.pg(),y!==E&&(E=a.kh(),y!==null?E!==null?x.isTreePathToChildren?E.fromNode=y:E.toNode=y:cv(this,y,a):E!==null&&ed(x,E,!1)))}}},Oh.prototype.updateDataBindings=function(a,y){oa.prototype.updateDataBindings.call(this,a,y),typeof y=="string"&&this.Lc(a)!==null&&(a=this.Kc(a),a!==null&&a.La(y))},Oh.prototype.resolveReferencesForData=function(a){var y=this.diagram.model,x=y.wa(a);if(x!==void 0){var E=Bp(y,x),b=this.Lc(a);if(E!==null&&b!==null){for(E=E.iterator;E.next();){var z=E.value;y.lb(z)&&b instanceof qn&&y.mh(z)===x&&cv(this,b,this.ii(z))}vc(y,x)}a=y.mh(a),a!==void 0&&b instanceof qn&&(a=this.Vb(a),cv(this,a,b))}},Oh.prototype.unresolveReferencesForPart=function(a){var y=this.diagram.model;if(a instanceof qn){var x=y.wa(a.data),E=this.Kc(a.data);if(E!==null){E.isSelected=!1,E.isHighlighted=!1;var b=E.layer;if(b!==null){var z=b.pc(-1,E,!1);0<=z&&this.diagram.cb(ss,"parts",b,E,null,z,null),z=E.layerChanged,z!==null&&z(E,b,null)}}for(E=this.diagram.isTreePathToChildren,a=a.linksConnected;a.next();)b=a.value,b=(E?b.toNode:b.fromNode).data,y.lb(b)&&mc(y,x,b)}},Oh.prototype.insertLink=function(a,y,x){y=this.diagram.model;var E=a,b=x;return this.diagram.isTreePathToChildren||(E=x,b=a),E!==null&&b!==null?(y.qe(b.data,y.wa(E.data)),b.kh()):null},Oh.prototype.findLinkForKey=Oh.prototype.findLinkForKey,Oh.className="TreePartManager";function Ci(a,y){this.kl=new Pn,this.il=new Pn,this.Wv=`,
"insertedNodeKeys": `,this.jy=`,
"modifiedNodeData": `,this.Yv=`,
"removedNodeKeys": `,this.vh=null,jo(this),this.Sm=this.xa="",this.Gg=!1,this.j={},this.Tc=[],this.kb=new Li,this.Th="key",this.Bk=this.bl=null,this.Jm=this.Km=!1,this.Mm=!0,this.xm=null,this.lj="category",this.Vf=new Li,this.Lt=new An,this.Wg=!1,this.o=null,this.undoManager=new Ta,a!==void 0&&(Xi(a)?this.nodeDataArray=a:y=a),y&&(Object.assign(this,y),a=y.Changed)&&(delete this.Changed,this.Pe(a))}Ci.prototype.cloneProtected=function(a){a.xa=this.xa,a.Sm=this.Sm,a.Gg=this.Gg,a.Th=this.Th,a.bl=this.bl,a.Bk=this.Bk,a.Km=this.Km,a.Jm=this.Jm,a.Mm=this.Mm,a.xm=this.xm,a.lj=this.lj},Ci.prototype.copy=function(){var a=new this.constructor;return this.cloneProtected(a),a},Ci.prototype.clear=function(){this.Tc=[],this.kb.clear(),this.Vf.clear(),this.undoManager.clear()},Ci.prototype.toString=function(a){if(a===void 0&&(a=0),1<a)return this.np();var y=(this.name!==""?this.name:"")+" Model";if(0<a){y+=`
node data:`,a=this.nodeDataArray;for(var x=a.length,E=0;E<x;E++){var b=a[E];y+=" "+this.wa(b)+":"+Co(b)}}return y},Ci.prototype.xA=function(a){a.change!==sl&&Dt("Model.toIncrementalData argument is not a Transaction ChangedEvent:"+a.toString());var y=a.object;return a.isTransactionFinished&&y instanceof ws?(x1(this,y),a=this.Qv(y,a.propertyName==="FinishedUndo"),this.vh=null,a):null},Ci.prototype.Qv=function(a,y){var x=this,E=!1,b=new Pn,z=new Pn,ee=new Pn,re=this.vh;a.changes.each(function(fe){fe.model===x&&(fe.modelChange==="nodeDataArray"?fe.change===ts?b.add(fe.newValue):fe.change===ss&&ee.add(fe.oldValue):x.lb(fe.object)?z.add(fe.object):fe.change!==ga||x.modelData!==fe.object&&fe.propertyName!=="modelData"?fe.object!==null&&(re&&re.contains(fe.object)?re.get(fe.object).each(function(ve){x.lb(ve)&&z.add(ve)}):fe.object instanceof Ci||x.ri()&&x.Jc(fe.object)||w1(x,fe.object).each(function(ve){z.add(ve)})):E=!0)});var oe=this.il;oe.clear(),b.each(function(fe){oe.add(x.wa(fe)),y||z.add(fe)});var se=this.kl;se.clear(),ee.each(function(fe){se.add(x.wa(fe)),y&&z.add(fe)}),a=x.cloneDeep(z.Fa());var ue=null;return E&&(ue===null&&(ue={}),ue.modelData=this.cloneDeep(this.modelData)),0<oe.count&&(ue===null&&(ue={}),y?ue.removedNodeKeys=oe.Fa():ue.insertedNodeKeys=oe.Fa()),0<a.length&&(ue===null&&(ue={}),ue.modifiedNodeData=a),0<se.count&&(ue===null&&(ue={}),y?ue.insertedNodeKeys=se.Fa():ue.removedNodeKeys=se.Fa()),se.clear(),oe.clear(),ue},Ci.prototype.cloneDeep=function(a){return Dg(this,a,!0)};function Dg(a,y,x,E,b,z){function ee(fe,ve){re?(fe.__gohashid===void 0&&z.push(fe),E.set(fe,ve)):(fe=bl++,E.set(fe,ve),b.set(fe,y))}if(!kn(y))return y;z||(z=[]);var re=Object.isExtensible(y);if(E||(E=new Li),re){var oe=E.get(y);if(oe)return oe}else for(b||(b=new Li),oe=b.iterator;oe.next();){var se=oe.key;if(oe.value===y&&(se=E.get(se)))return se}if(Array.isArray(y)){oe=[],ee(y,oe);for(var ue=0;ue<y.length;ue++)oe.push(Dg(a,y[ue],!1,E,b,z))}else if(y instanceof Qe||y instanceof fn||y instanceof Xt||y instanceof vr||y instanceof Bi)oe=y.copy(),ee(y,oe);else{if(y instanceof ia||y instanceof Bn||y instanceof Vt)return y;if(y instanceof An)oe=new An().addAll(Dg(a,y.Fa(),!1,E,b,z)),ee(y,oe);else if(y instanceof Pn)oe=new Pn().addAll(Dg(a,y.Fa(),!1,E,b,z)),ee(y,oe);else if(y instanceof Li)oe=new Li().addAll(Dg(a,y.Fa(),!1,E,b,z)),ee(y,oe);else if(y instanceof Date)oe=new Date(y.getTime()),ee(y,oe);else if(y instanceof RegExp)oe=new RegExp(y),ee(y,oe),oe.lastIndex=y.lastIndex;else if(typeof y.copy=="function")oe=y.copy(),ee(y,oe);else for(ue in oe={},ee(y,oe),y)ue!=="__gohashid"&&(oe[ue]=Dg(a,y[ue],!1,E,b,z))}return x&&z.forEach(function(fe){delete fe.__gohashid}),oe}we=Ci.prototype,we.quote=function(a){return JSON.stringify(a).replace(/[\u007F-\uFFFF]/g,function(y){return"\\u"+("0000"+y.charCodeAt(0).toString(16)).substr(-4)})},we.rm=function(){var a="";return this.name!==""&&(a+=`,
"name": `+this.quote(this.name)),this.dataFormat!==""&&(a+=`,
"dataFormat": `+this.quote(this.dataFormat)),this.isReadOnly&&(a+=`,
"isReadOnly": `+this.isReadOnly),this.nodeKeyProperty!=="key"&&typeof this.nodeKeyProperty=="string"&&(a+=`,
"nodeKeyProperty": `+this.quote(this.nodeKeyProperty)),this.copiesArrays&&(a+=`,
"copiesArrays": true`),this.copiesArrayObjects&&(a+=`,
"copiesArrayObjects": true`),this.copiesKey||(a+=`,
"copiesKey": false`),this.nodeCategoryProperty!=="category"&&typeof this.nodeCategoryProperty=="string"&&(a+=`,
"nodeCategoryProperty": `+this.quote(this.nodeCategoryProperty)),a},we.gp=function(a){a.name&&(this.name=a.name),a.dataFormat&&(this.dataFormat=a.dataFormat),a.isReadOnly&&(this.isReadOnly=!0),a.nodeKeyProperty&&(this.nodeKeyProperty=a.nodeKeyProperty),a.copiesArrays&&(this.copiesArrays=!0),a.copiesArrayObjects&&(this.copiesArrayObjects=!0),a.copiesKey===!1&&(this.copiesKey=!1),a.nodeCategoryProperty&&(this.nodeCategoryProperty=a.nodeCategoryProperty)};function S1(a,y){y=y.modelData,kn(y)&&(a.dm(y),a.modelData=y)}we.Rv=function(){var a=this.modelData,y=!1,x;for(x in a)if(!P1(x,a[x])){y=!0;break}return a="",y&&(a=`,
"modelData": `+uy(this,this.modelData)),a+`,
"nodeDataArray": `+Yd(this,this.nodeDataArray,!0)},we.kv=function(a){S1(this,a),a=a.nodeDataArray,Xi(a)&&(this.dm(a),this.nodeDataArray=a)};function x1(a,y){function x(b,z){if((z=z.part)&&(z=z.data,b!==z)){var ee=E.get(b);ee===null?(ee=new Pn,ee.add(z),E.add(b,ee)):ee.add(z)}}var E=a.vh;E===null&&(E=new Li,y.changes.each(function(b){if(b.diagram!==null){var z=b.change;z===ga?(b=b.object.panel)&&(z=b.data)&&x(z,b):(z===ts||z===ss)&&(b=b.object,(z=b.itemArray)&&x(z,b))}}),a.vh=E)}function w1(a,y){for(var x=new Pn,E=0;E<a.nodeDataArray.length;E++){var b=a.nodeDataArray[E];dv(a,y,b,b,x)}return x}function dv(a,y,x,E,b){if(Array.isArray(x))for(var z=0;z<x.length;z++){var ee=x[z];if(ee===y)return b.add(E),!0;if(dv(a,y,ee,E,b))return!0}else if(kn(x)&&Object.getPrototypeOf(x)===Object.prototype)for(z in x){if(ee=x[z],ee===y)return b.add(E),!0;if(dv(a,y,ee,E,b))return!0}return!1}we.Pv=function(a,y){var x=this,E=!1,b=new Pn,z=new Pn,ee=new Pn,re=this.vh;a.changes.each(function(ue){ue.model===x&&(ue.modelChange==="nodeDataArray"?ue.change===ts?b.add(ue.newValue):ue.change===ss&&ee.add(ue.oldValue):x.lb(ue.object)?z.add(ue.object):ue.change!==ga||x.modelData!==ue.object&&ue.propertyName!=="modelData"?ue.object!==null&&(re&&re.contains(ue.object)?re.get(ue.object).each(function(fe){x.lb(fe)&&z.add(fe)}):ue.object instanceof Ci||x.ri()&&x.Jc(ue.object)||w1(x,ue.object).each(function(fe){z.add(fe)})):E=!0)});var oe=this.il;oe.clear(),b.each(function(ue){oe.add(x.wa(ue)),y||z.add(ue)});var se=this.kl;return se.clear(),ee.each(function(ue){se.add(x.wa(ue)),y&&z.add(ue)}),a="",E&&(a+=`,
"modelData": `+uy(this,this.modelData)),0<oe.count&&(a+=(y?this.Yv:this.Wv)+Yd(this,oe.Fa(),!0)),0<z.count&&(a+=this.jy+Yd(this,z.Fa(),!0)),0<se.count&&(a+=(y?this.Wv:this.Yv)+Yd(this,se.Fa(),!0)),se.clear(),oe.clear(),a},we.fp=function(a){(a.name!==void 0&&a.name!==this.name||a.dataFormat!==void 0&&a.dataFormat!==this.dataFormat||a.isReadOnly!==void 0&&a.isReadOnly!==this.isReadOnly||a.nodeKeyProperty!==void 0&&a.nodeKeyProperty!==this.nodeKeyProperty||a.copiesArrays!==void 0&&a.copiesArrays!==this.copiesArrays||a.copiesArrayObjects!==void 0&&a.copiesArrayObjects!==this.copiesArrayObjects||a.copiesKey!==void 0&&a.copiesKey!==this.copiesKey||a.nodeCategoryProperty!==void 0&&a.nodeCategoryProperty!==this.nodeCategoryProperty)&&Dt("applyIncrementalJson cannot change Model properties"),S1(this,a);var y=a.insertedNodeKeys,x=a.modifiedNodeData,E=new Li;if(Array.isArray(x))for(var b=0;b<x.length;b++){var z=x[b],ee=this.wa(z);ee!=null&&E.set(ee,z)}if(Array.isArray(y))for(b=y.length,z=0;z<b;z++){ee=y[z];var re=this.hc(ee);re===null&&(re=(re=E.get(ee))?re:this.copyNodeData({}),this.km(re,ee),this.xf(re))}if(Array.isArray(x)){for(y=x.length,E=0;E<y;E++)if(b=x[E],z=this.wa(b),z=this.hc(z),z!==null){for(var oe in b)oe==="__gohashid"||oe===this.nodeKeyProperty||this.Wj()&&oe===this.nodeIsGroupProperty||this.setDataProperty(z,oe,b[oe]);this.lm(b,z)}}if(a=a.removedNodeKeys,Array.isArray(a))for(x=a.length,oe=0;oe<x;oe++)y=this.hc(a[oe]),y!==null&&this.cm(y)},we.$x=function(a,y){a.change!==sl&&Dt("Model.toIncrementalJson argument is not a Transaction ChangedEvent:"+a.toString());var x=a.object;return a.isTransactionFinished&&x instanceof ws?(y===void 0&&(y=Op(this,this)),x1(this,x),a=this.Pv(x,a.propertyName==="FinishedUndo"),this.vh=null,y==="2"?'{ "incremental": 2'+a+"}":'{ "class": '+this.quote(y)+', "incremental": 1'+this.rm()+a+"}"):'{ "incremental": 0 }'},we.yA=function(a,y){return this.$x(a,y)},we.np=function(a){return a===void 0&&(a=Op(this,this)),'{ "class": '+this.quote(a)+this.rm()+this.Rv()+"}"},we.toJSON=function(a){return this.np(a)},we.Zw=function(a){var y=null;if(typeof a=="string")try{y=Kt.JSON.parse(a)}catch(E){}else typeof a=="object"?y=a:Dt("Unable to modify a Model from: "+a);var x=y.incremental;typeof x!="number"&&Dt("Unable to apply non-incremental changes to Model: "+a),x!==0&&(this.Ea("applyIncrementalJson"),this.fp(y),this.eb("applyIncrementalJson"))},we.Ky=function(a){return this.Zw(a)},Ci.constructGraphLinksModel=function(){return new Ci},we=Ci.prototype,we.dm=function(a){if(Xi(a))for(var y=a.length,x=0;x<y;x++){var E=a[x];if(kn(E)){var b=x;E=this.dm(E),Array.isArray(a)?a[b]=E:Dt("Cannot replace an object in an HTMLCollection or NodeList at "+b)}}else if(kn(a)){for(y in a)if(x=a[y],kn(x)&&(x=this.dm(x),a[y]=x,y==="points"&&Array.isArray(x))){for(b=x.length%2===0,E=0;E<x.length;E++)if(typeof x[E]!="number"){b=!1;break}if(b){for(b=new An,E=0;E<x.length/2;E++)b.add(new Qe(x[2*E],x[2*E+1]));b.freeze(),a[y]=b}}return Nx(a)}return a},we.sm=function(a){return a===void 0?"undefined":a===null?"null":a===!0?"true":a===!1?"false":typeof a=="string"?this.quote(a):typeof a=="number"?a===1/0?"9e9999":a===-1/0?"-9e9999":isNaN(a)?'{"class":"NaN"}':a.toString():a instanceof Date?'{"class":"Date", "value":"'+a.toJSON()+'"}':a instanceof Number?this.sm(a.valueOf()):Xi(a)?Yd(this,a):kn(a)?uy(this,a):typeof a=="function"?"null":a.toString()};function Yd(a,y,x){x===void 0&&(x=!1);var E=y.length;if(0>=E)return"[]";var b=new Ko;b.add("["),x&&1<E&&b.add(`
`);for(var z=0;z<E;z++){var ee=y[z];ee!==void 0&&(0<z&&(b.add(","),x&&b.add(`
`)),b.add(a.sm(ee)))}return x&&1<E&&b.add(`
`),b.add("]"),b.toString()}function P1(a,y){return y===void 0||a==="__gohashid"||a[0]==="_"||typeof y=="function"}function Cu(a){return isNaN(a)?"NaN":a===1/0?"9e9999":a===-1/0?"-9e9999":a}function uy(a,y){var x=y;if(x instanceof Qe)y={class:"go.Point",x:Cu(x.x),y:Cu(x.y)};else if(x instanceof fn)y={class:"go.Size",width:Cu(x.width),height:Cu(x.height)};else if(x instanceof Xt)y={class:"go.Rect",x:Cu(x.x),y:Cu(x.y),width:Cu(x.width),height:Cu(x.height)};else if(x instanceof vr)y={class:"go.Margin",top:Cu(x.top),right:Cu(x.right),bottom:Cu(x.bottom),left:Cu(x.left)};else if(x instanceof Bi)x.sb()?y={class:"go.Spot",x:Cu(x.x),y:Cu(x.y),offsetX:Cu(x.offsetX),offsetY:Cu(x.offsetY)}:y={class:"go.Spot",enum:x.toString()};else if(x instanceof ia){if(y={class:"go.Brush",type:x.type.name},x.type===xd?y.color=x.color:(x.type===od||x.type===Dh)&&(y.start=x.start,y.end=x.end,x.type===Dh&&(x.startRadius!==0&&(y.startRadius=Cu(x.startRadius)),isNaN(x.endRadius)||(y.endRadius=Cu(x.endRadius)))),x.colorStops!==null){var E={};for(x=x.colorStops.iterator;x.next();)E[x.key]=x.value;y.colorStops=E}}else x instanceof Bn?(y={class:"go.Geometry",type:x.type.name},x.startX!==0&&(y.startX=Cu(x.startX)),x.startY!==0&&(y.startY=Cu(x.startY)),x.endX!==0&&(y.endX=Cu(x.endX)),x.endY!==0&&(y.endY=Cu(x.endY)),x.spot1.D(Cs)||(y.spot1=x.spot1),x.spot2.D(Hl)||(y.spot2=x.spot2),x.type===Bn.o&&(y.path=Bn.ia(x))):x instanceof Vt&&(y={class:"go.EnumValue",classType:Op(a,x.classType),name:x.name});E="{",x=!0;for(var b in y){var z=Is(y,b);if(!P1(b,z))if(x?x=!1:E+=",",E+=a.quote(b)+":",b==="points"&&z instanceof An){var ee="[";for(z=z.iterator;z.next();){var re=z.value;1<ee.length&&(ee+=","),ee+=a.sm(re.x),ee+=",",ee+=a.sm(re.y)}ee+="]",E+=ee}else E+=a.sm(z)}return E+"}"}function Eu(a){return typeof a=="number"?a:a==="NaN"?NaN:a==="9e9999"?1/0:a==="-9e9999"?-1/0:parseFloat(a)}function Nx(a){if(typeof a!="object")return a;var y=a.class||"";if(y==="NaN")return NaN;if(y==="Date")return new Date(a.value);if(y.indexOf("go.")!==0)return a;y=y.substr(3);var x=a;if(y==="Point")x=new Qe(Eu(a.x),Eu(a.y));else if(y==="Size")x=new fn(Eu(a.width),Eu(a.height));else if(y==="Rect")x=new Xt(Eu(a.x),Eu(a.y),Eu(a.width),Eu(a.height));else if(y==="Margin")x=new vr(Eu(a.top),Eu(a.right),Eu(a.bottom),Eu(a.left));else if(y==="Spot")typeof a.enum=="string"?x=os(a.enum):x=new Bi(Eu(a.x),Eu(a.y),Eu(a.offsetX),Eu(a.offsetY));else if(y==="Brush"){if(x=new ia,x.type=Kr(ia,a.type),typeof a.color=="string"&&(x.color=a.color),a.start instanceof Bi&&(x.start=a.start),a.end instanceof Bi&&(x.end=a.end),typeof a.startRadius=="number"&&(x.startRadius=Eu(a.startRadius)),typeof a.endRadius=="number"&&(x.endRadius=Eu(a.endRadius)),a=a.colorStops,kn(a))for(var E in a)x.addColorStop(parseFloat(E),a[E])}else y==="Geometry"?(x=null,typeof a.path=="string"?x=Bn.parse(a.path):x=new Bn,x.type=Kr(Bn,a.type),typeof a.startX=="number"&&(x.startX=Eu(a.startX)),typeof a.startY=="number"&&(x.startY=Eu(a.startY)),typeof a.endX=="number"&&(x.endX=Eu(a.endX)),typeof a.endY=="number"&&(x.endY=Eu(a.endY)),a.spot1 instanceof Bi&&(x.spot1=a.spot1),a.spot2 instanceof Bi&&(x.spot2=a.spot2)):y==="EnumValue"&&(E=a.classType,E.indexOf("go.")===0&&(E=E.substr(3)),E=cy(E),typeof E=="function"&&(x=Kr(E,a.name)));return x}we.Pe=function(a){return this.Lt.add(a),this},we.ik=function(a){this.Lt.remove(a)},we.ds=function(a){this.skipsUndoManager||this.undoManager.Tu(a);for(var y=this.Lt,x=y.length,E=0;E<x;E++)y.M(E)(a)},we.cb=function(a,y,x,E,b,z,ee){Js(this,"",a,y,x,E,b,z,ee)},we.g=function(a,y,x,E,b){Js(this,"",ga,a,this,y,x,E,b)},we.Fs=function(a,y,x,E,b,z){Js(this,"",ga,y,a,x,E,b,z)};function Js(a,y,x,E,b,z,ee,re,oe){re===void 0&&(re=null),oe===void 0&&(oe=null);var se=new ka;se.model=a,se.change=x,se.modelChange=y,se.propertyName=E,se.object=b,se.oldValue=z,se.oldParam=re,se.newValue=ee,se.newParam=oe,a.ds(se)}Ci.prototype.changeState=function(a,y){if(a!==null&&a.model===this)if(a.change===ga){var x=a.object,E=a.propertyName,b=a.I(y);E===this.nodeKeyProperty&&this.lb(x)&&(y=a.I(!y),y!==void 0&&this.kb.remove(y),b!==void 0&&this.kb.add(b,x)),rs(x,E,b)}else a.change===ts?(x=a.newParam,a.modelChange==="nodeDataArray"?(a=a.newValue,kn(a)&&typeof x=="number"&&(E=this.wa(a),y?(this.Tc[x]===a&&$o(this.Tc,x),E!==void 0&&this.kb.remove(E)):(this.Tc[x]!==a&&La(this.Tc,x,a),E!==void 0&&this.kb.add(E,a)))):a.modelChange===""?((E=a.object)&&!Xi(E)&&a.propertyName&&(E=Is(a.object,a.propertyName)),Xi(E)&&typeof x=="number"&&(a=a.newValue,y?$o(E,x):La(E,x,a))):Dt("unknown ChangedEvent.Insert modelChange: "+a.toString())):a.change===ss?(x=a.oldParam,a.modelChange==="nodeDataArray"?(a=a.oldValue,kn(a)&&typeof x=="number"&&(E=this.wa(a),y?(this.Tc[x]!==a&&La(this.Tc,x,a),E!==void 0&&this.kb.add(E,a)):(this.Tc[x]===a&&$o(this.Tc,x),E!==void 0&&this.kb.remove(E)))):a.modelChange===""?((E=a.object)&&!Xi(E)&&a.propertyName&&(E=Is(a.object,a.propertyName)),Xi(E)&&typeof x=="number"&&(a=a.oldValue,y?La(E,x,a):$o(E,x))):Dt("unknown ChangedEvent.Remove modelChange: "+a.toString())):a.change!==sl&&Dt("unknown ChangedEvent: "+a.toString())},Ci.prototype.Ea=function(a){return this.undoManager.Ea(a)},Ci.prototype.eb=function(a){return this.undoManager.eb(a)},Ci.prototype.Kf=function(){return this.undoManager.Kf()},Ci.prototype.commit=function(a,y){y===void 0&&(y="");var x=this.skipsUndoManager;y===null&&(this.skipsUndoManager=!0,y=""),this.undoManager.Ea(y);var E=!1;try{a(this),E=!0}finally{E?this.undoManager.eb(y):this.undoManager.Kf(),this.skipsUndoManager=x}},we=Ci.prototype,we.La=function(a,y){y===void 0&&(y=""),Js(this,"SourceChanged",sl,y,a,null,null)},we.wa=function(a){if(a!==null){var y=this.Th;if(y!==""&&(y=Is(a,y),y!==void 0)){if(Xd(y))return y;Dt("Key value for node data "+a+" is not a number or a string: "+y)}}},we.km=function(a,y){if(a!==null){var x=this.Th;if(x!=="")if(this.lb(a)){var E=Is(a,x);E!==y&&this.hc(y)===null&&(rs(a,x,y),E!==void 0&&this.kb.remove(E),this.kb.add(y,a),Js(this,"nodeKey",ga,x,a,E,y),typeof x=="string"&&this.La(a,x),this.jp(E,y))}else rs(a,x,y)}};function Xd(a){return typeof a=="number"||typeof a=="string"}we.lb=function(a){var y=this.wa(a);return y===void 0?!1:this.kb.I(y)===a},we.hc=function(a){return a===null&&Dt("Model.findNodeDataForKey:key must not be null"),a!==void 0&&Xd(a)?this.kb.I(a):null},we.$u=function(a){if(a!==null){var y=this.Th;if(y!==""){var x=this.wa(a);if(x===void 0||this.kb.contains(x)){var E=this.bl;if(E!==null&&(x=E(this,a),x!=null&&!this.kb.contains(x))){rs(a,y,x);return}if(typeof x=="string"){for(E=2;this.kb.contains(x+E);)E++;rs(a,y,x+E)}else if(x===void 0||typeof x=="number"){for(x=-this.kb.count-1;this.kb.contains(x);)x--;rs(a,y,x)}}}}},we.xf=function(a){a!==null&&(Ws(a),this.lb(a)||C1(this,a,!0))};function C1(a,y,x){var E=a.wa(y);(E===void 0||a.kb.I(E)!==y)&&(a.$u(y),E=a.wa(y),E===void 0&&Dt("Model.makeNodeDataKeyUnique failed on "+y+". Data not added to Model."),a.kb.add(E,y),E=null,x&&(E=a.Tc.length,La(a.Tc,E,y)),Js(a,"nodeDataArray",ts,"nodeDataArray",a,null,y,null,E),a.fm(y),a.em(y))}we.Fy=function(a){if(Xi(a))for(var y=a.length,x=0;x<y;x++)this.xf(a[x]);else for(a=a.iterator;a.next();)this.xf(a.value)},we.cm=function(a){a!==null&&E1(this,a,!0)};function E1(a,y,x){var E=a.wa(y);if(E!==void 0&&a.kb.remove(E),E=null,x){e:if(x=a.Tc,Array.isArray(x))E=x.indexOf(y);else{E=x.length;for(var b=0;b<E;b++)if(x[b]===y){E=b;break e}E=-1}if(0>E)return;$o(a.Tc,E)}Js(a,"nodeDataArray",ss,"nodeDataArray",a,y,null,E,null),a.qp(y)}we.nA=function(a){if(Xi(a))for(var y=a.length,x=0;x<y;x++)this.cm(a[x]);else for(a=a.iterator;a.next();)this.cm(a.value)},we.$z=function(a){if(a!==this.nodeDataArray&&Xi(a)){var y=this.kl;y.clear(),y.addAll(this.kb.iteratorKeys);var x=this.il;x.clear();for(var E=a.length,b=0;b<E;b++){var z=a[b],ee=this.wa(z);if(ee!==void 0){x.add(ee);var re=this.hc(ee);re!==z&&(re!==null?(this.Do(re,z),this.lm(z,re)):(z=this.cloneDeep(z),this.km(z,ee),this.xf(z)))}else ee=this.cloneDeep(z),this.xf(ee),x.add(this.wa(ee))}for(a=y.iterator;a.next();)E=a.value,x.contains(E)||(E=this.hc(E))&&this.cm(E);y.clear(),x.clear()}},we.jp=function(a,y){y!==void 0&&(a=Bp(this,a),a instanceof Pn&&this.Vf.add(y,a))},we.Lv=function(){},we.fm=function(){},we.em=function(){},we.qp=function(){};function mc(a,y,x){if(y!==void 0){var E=a.Vf.I(y);E===null&&(E=new Pn,a.Vf.add(y,E)),E.add(x)}}function vc(a,y,x){if(y!==void 0){var E=a.Vf.I(y);E instanceof Pn&&(x==null?a.Vf.remove(y):(E.remove(x),E.count===0&&a.Vf.remove(y)))}}function Bp(a,y){return y===void 0?null:(a=a.Vf.I(y),a instanceof Pn?a:null)}we.Qy=function(a){a===void 0?this.Vf.clear():this.Vf.remove(a)},Ci.prototype.copyNodeData=function(a){if(a===null)return null;var y=this.Bk;return a=y!==null?y(a,this):fv(this,a,!0),kn(a)&&jo(a),a};function fv(a,y,x){if(a.copiesArrays&&Array.isArray(y)){var E=[];for(x=0;x<y.length;x++){var b=fv(a,y[x],a.copiesArrayObjects);E.push(b)}return jo(E),E}if(x&&kn(y)){x=(x=y.constructor)?new x:{},b=a.copiesKey||typeof a.nodeKeyProperty!="string"?null:a.nodeKeyProperty;for(E in y)if(E==="__gohashid")x.__gohashid=void 0;else if(E===b)x[b]=void 0;else{var z=Is(y,E),ee=Op(a,z);ee==="GraphObject"||ee==="Diagram"||ee==="Layer"||ee==="RowColumnDefinition"||ee==="AnimationManager"||ee==="Tool"||ee==="CommandHandler"||ee==="Layout"||ee==="InputEvent"||ee==="DiagramEvent"||z instanceof Ci||z instanceof Ta||z instanceof ws||z instanceof ka||(z=fv(a,z,!1)),rs(x,E,z)}return jo(x),x}return y instanceof Qe||y instanceof fn||y instanceof Xt||y instanceof Bi||y instanceof vr?y.copy():y}Ci.prototype.setDataProperty=function(a,y,x){if(this.lb(a)){if(y===this.nodeKeyProperty){this.km(a,x);return}if(y===this.nodeCategoryProperty){this.jm(a,x);return}}else!b1&&a instanceof mt&&(b1=!0,eo('Model.setDataProperty is modifying a GraphObject, "'+a.toString()+'"'),eo(" Is that really your intent?"));var E=Is(a,y);E!==x&&(rs(a,y,x),this.Fs(a,y,E,x))},we=Ci.prototype,we.set=function(a,y,x){this.setDataProperty(a,y,x)},we.Do=function(a,y){if(y){var x=this.lb(a),E;for(E in y)E==="__gohashid"||x&&E===this.nodeKeyProperty||this.setDataProperty(a,E,y[E])}},we.Ay=function(a,y){this.ts(a,-1,y)},we.ts=function(a,y,x){0>y&&(y=a.length),La(a,y,x),Js(this,"",ts,"",a,null,x,null,y)},we.ov=function(a,y){y===void 0&&(y=-1),a===this.Tc&&Dt("Model.removeArrayItem should not be called on the Model.nodeDataArray"),y===-1&&(y=a.length-1);var x=a[y];$o(a,y),Js(this,"",ss,"",a,x,null,y,null)},we.Ro=function(a){if(a===null)return"";var y=this.lj;if(y===""||(y=Is(a,y),y===void 0))return"";if(typeof y=="string")return y;Dt("getCategoryForNodeData found a non-string category for "+a+": "+y)},we.jm=function(a,y){if(a!==null){var x=this.lj;if(x!=="")if(this.lb(a)){var E=Is(a,x);E===void 0&&(E=""),E!==y&&(rs(a,x,y),Js(this,"nodeCategory",ga,x,a,E,y))}else rs(a,x,y)}},we.lm=function(a,y){this.jm(y,this.Ro(a))},we.Tl=function(){return!1},we.Wj=function(){return!1},we.ri=function(){return!1},we.xs=function(){return!1},we.Xj=function(){return!1};function hy(){return new Ci}function Op(a,y){if(typeof y=="function"){if(y.className)return y.className;if(y.name)return y.name}else if(typeof y=="object"&&y!==null&&y.constructor)return Op(a,y.constructor);return typeof y}function cy(a){return ac[a]?ac[a]:Kt.go!==void 0&&Kt.go[a]?Kt.go[a]:null}function Is(a,y){if(!a||!y)return null;try{if(typeof y=="function")var x=y(a);else typeof a.getAttribute=="function"?(x=a.getAttribute(y),x===null&&(x=void 0)):x=a[y]}catch(E){}return x}function rs(a,y,x){if(a&&y)try{typeof y=="function"?y(a,x):typeof a.setAttribute=="function"?a.setAttribute(y,x):a[y]=x}catch(E){}}Yt.Object.defineProperties(Ci.prototype,{name:{get:function(){return this.xa},set:function(a){var y=this.xa;y!==a&&(this.xa=a,this.g("name",y,a))}},dataFormat:{get:function(){return this.Sm},set:function(a){var y=this.Sm;y!==a&&(this.Sm=a,this.g("dataFormat",y,a))}},isReadOnly:{get:function(){return this.Gg},set:function(a){var y=this.Gg;y!==a&&(this.Gg=a,this.g("isReadOnly",y,a))}},modelData:{get:function(){return this.j},set:function(a){var y=this.j;y!==a&&(this.j=a,this.g("modelData",y,a),this.La(a))}},undoManager:{get:function(){return this.o},set:function(a){var y=this.o;y!==a&&(y!==null&&y.Rx(this),this.o=a,a!==null&&a.Xw(this))}},skipsUndoManager:{get:function(){return this.Wg},set:function(a){this.Wg=a}},nodeKeyProperty:{get:function(){return this.Th},set:function(a){var y=this.Th;y!==a&&(a===""&&Dt("Model.nodeKeyProperty may not be the empty string"),0<this.kb.count&&Dt("Cannot set Model.nodeKeyProperty when there is existing node data"),this.Th=a,this.g("nodeKeyProperty",y,a))}},makeUniqueKeyFunction:{get:function(){return this.bl},set:function(a){var y=this.bl;y!==a&&(this.bl=a,this.g("makeUniqueKeyFunction",y,a))}},nodeDataArray:{get:function(){return this.Tc},set:function(a){var y=this.Tc;if(y!==a){this.kb.clear(),this.Lv();for(var x=a.length,E=0;E<x;E++){var b=a[E];kn(b)||Dt("Model.nodeDataArray must only contain Objects, not: "+b),Ws(b)}for(this.Tc=a,E=new An,b=0;b<x;b++){var z=a[b],ee=this.wa(z);ee===void 0||this.kb.I(ee)!==null?E.add(z):this.kb.add(ee,z)}for(E=E.iterator;E.next();)b=E.value,this.$u(b),z=this.wa(b),z!==void 0&&this.kb.add(z,b);for(Js(this,"nodeDataArray",ga,"nodeDataArray",this,y,a),y=0;y<x;y++)E=a[y],this.fm(E),this.em(E);Array.isArray(a)||(this.isReadOnly=!0)}}},copyNodeDataFunction:{get:function(){return this.Bk},set:function(a){var y=this.Bk;y!==a&&(this.Bk=a,this.g("copyNodeDataFunction",y,a))}},copiesArrays:{get:function(){return this.Km},set:function(a){var y=this.Km;y!==a&&(this.Km=a,this.g("copiesArrays",y,a))}},copiesArrayObjects:{get:function(){return this.Jm},set:function(a){var y=this.Jm;y!==a&&(this.Jm=a,this.g("copiesArrayObjects",y,a))}},copiesKey:{get:function(){return this.Mm},set:function(a){var y=this.Mm;y!==a&&(this.Mm=a,this.g("copiesKey",y,a))}},afterCopyFunction:{get:function(){return this.xm},set:function(a){var y=this.xm;y!==a&&(this.xm=a,this.g("afterCopyFunction",y,a))}},nodeCategoryProperty:{get:function(){return this.lj},set:function(a){var y=this.lj;y!==a&&(this.lj=a,this.g("nodeCategoryProperty",y,a))}},type:{get:function(){return"Model"}}}),Ci.prototype.setCategoryForNodeData=Ci.prototype.jm,Ci.prototype.getCategoryForNodeData=Ci.prototype.Ro,Ci.prototype.removeArrayItem=Ci.prototype.ov,Ci.prototype.insertArrayItem=Ci.prototype.ts,Ci.prototype.addArrayItem=Ci.prototype.Ay,Ci.prototype.assignAllDataProperties=Ci.prototype.Do,Ci.prototype.set=Ci.prototype.set,Ci.prototype.clearUnresolvedReferences=Ci.prototype.Qy,Ci.prototype.mergeNodeDataArray=Ci.prototype.$z,Ci.prototype.removeNodeDataCollection=Ci.prototype.nA,Ci.prototype.removeNodeData=Ci.prototype.cm,Ci.prototype.addNodeDataCollection=Ci.prototype.Fy,Ci.prototype.addNodeData=Ci.prototype.xf,Ci.prototype.makeNodeDataKeyUnique=Ci.prototype.$u,Ci.prototype.findNodeDataForKey=Ci.prototype.hc,Ci.prototype.containsNodeData=Ci.prototype.lb,Ci.prototype.setKeyForNodeData=Ci.prototype.km,Ci.prototype.getKeyForNodeData=Ci.prototype.wa,Ci.prototype.updateTargetBindings=Ci.prototype.La,Ci.prototype.commit=Ci.prototype.commit,Ci.prototype.rollbackTransaction=Ci.prototype.Kf,Ci.prototype.commitTransaction=Ci.prototype.eb,Ci.prototype.startTransaction=Ci.prototype.Ea,Ci.prototype.raiseDataChanged=Ci.prototype.Fs,Ci.prototype.raiseChanged=Ci.prototype.g,Ci.prototype.raiseChangedEvent=Ci.prototype.cb,Ci.prototype.removeChangedListener=Ci.prototype.ik,Ci.prototype.addChangedListener=Ci.prototype.Pe,Ci.prototype.writeJsonValue=Ci.prototype.sm,Ci.prototype.replaceJsonObjects=Ci.prototype.dm,Ci.prototype.applyIncrementalJSON=Ci.prototype.Ky,Ci.prototype.applyIncrementalJson=Ci.prototype.Zw,Ci.prototype.toJSON=Ci.prototype.toJSON,Ci.prototype.toJson=Ci.prototype.np,Ci.prototype.toIncrementalJSON=Ci.prototype.yA,Ci.prototype.toIncrementalJson=Ci.prototype.$x,Ci.prototype.toIncrementalData=Ci.prototype.xA,Ci.prototype.clear=Ci.prototype.clear;var b1=!1,ac={};Ci.className="Model",Ci.fromJSON=Ci.fromJson=function(a,y){y===void 0&&(y=null);var x=null;if(typeof a=="string")try{x=Kt.JSON.parse(a)}catch(z){}else typeof a=="object"?x=a:Dt("Unable to construct a Model from: "+a);if(y===null){a=null;var E=x.class;if(typeof E=="string")try{var b=null;E.indexOf("go.")===0?(E=E.substr(3),b=cy(E)):(b=cy(E),b===null&&(b=Kt[E])),typeof b=="function"&&(a=new b)}catch(z){}a===null||a instanceof Ci?y=a:Dt("Unable to construct a Model of declared class: "+x.class)}return y===null&&(y=Ci.constructGraphLinksModel()),y.gp(x),y.kv(x),y},Ci.safePropertyValue=Is,Ci.safePropertySet=rs,ac.Brush=ia,ac.ChangedEvent=ka,ac.Geometry=Bn,ac.Margin=vr,ac.Panel=Ln,ac.Point=Qe,ac.Rect=Xt,ac.Size=fn,ac.Spot=Bi,ac.Transaction=ws,ac.UndoManager=Ta;function Hs(a,y,x,E){jo(this),this._isFrozen=!1,a===void 0&&(a=""),y===void 0&&(y=a),x===void 0&&(x=null),this.j=-1,this.xd=null,this.xl=a,this.wl=this.to=0,this.Cr=null,this.wn=!1,this.sl=y,this.Im=x,E===void 0?(this.el=M1,this.wk=null):(this.el=Rp,this.wk=E),this.st=new Pn}Hs.prototype.copy=function(){var a=new Hs;return a.xl=this.xl,a.to=this.to,a.wl=this.wl,a.Cr=this.Cr,a.wn=this.wn,a.sl=this.sl,a.Im=this.Im,a.el=this.el,a.wk=this.wk,a},we=Hs.prototype,we.qb=function(a){a.classType===Hs&&(this.mode=a)},we.toString=function(){return"Binding("+this.targetProperty+":"+this.sourceProperty+(this.Ai!==-1?" "+this.Ai:"")+" "+this.mode.name+")"},we.freeze=function(){return this._isFrozen=!0,this},we.ka=function(){return this._isFrozen=!1,this},we.Kx=function(a){return a===void 0&&(a=null),this.mode=Rp,this.backConverter=a,this},we.cp=function(a){return a===void 0&&(a=""),this.sourceName=a,this.isToModel=!1,this},we.dA=function(){return this.sourceName=null,this.isToModel=!0,this};function L1(a,y,x){return a=a.sourceName,a===null||a===""?y:a==="/"?x.part:a==="."?x:a===".."?x.panel:y.fb(a)}we.Mv=function(a,y,x){var E=this.sl;if(x===void 0||E===""||E===x){x=this.xl;var b=this.Im;if(b===null&&x==="")eo("Binding error: target property is the empty string: "+this.toString());else{var z=y;if(E!==""&&(z=Is(y,E)),z!==void 0)if(b===null)x!==""&&rs(a,x,z);else try{if(x!==""){var ee=b(z,a);rs(a,x,ee)}else b(z,a)}catch(re){}}}},we.sp=function(a,y,x,E){if(this.el===Rp){var b=this.xl;if(x===void 0||b===x){x=this.sl;var z=this.wk,ee=a;if(b!==""&&(ee=Is(a,b)),ee!==void 0&&!this.st.contains(a))try{this.st.add(a);var re=E!==null?E.diagram:null,oe=re!==null?re.model:null;if(z===null){if(x!=="")oe!==null?oe.setDataProperty(y,x,ee):rs(y,x,ee);else if(oe!==null&&E!==null&&0<=E.itemIndex&&E.panel!==null&&Array.isArray(E.panel.itemArray)){var se=E.itemIndex,ue=E.panel.itemArray;oe.ov(ue,se),oe.ts(ue,se,ee)}}else try{if(x!==""){var fe=z(ee,y,oe);oe!==null?oe.setDataProperty(y,x,fe):rs(y,x,fe)}else{var ve=z(ee,y,oe);if(ve!==void 0&&oe!==null&&E!==null&&0<=E.itemIndex&&E.panel!==null&&Array.isArray(E.panel.itemArray)){var ye=E.itemIndex,Ce=E.panel.itemArray;oe.ov(Ce,ye),oe.ts(Ce,ye,ve)}}}catch(Ae){}}finally{this.st.remove(a)}}}},Yt.Object.defineProperties(Hs.prototype,{Ai:{get:function(){return this.j},set:function(a){this._isFrozen&&wi(this),this.j=a}},targetProperty:{get:function(){return this.xl},set:function(a){this._isFrozen&&wi(this),this.xl=a}},sourceName:{get:function(){return this.Cr},set:function(a){this._isFrozen&&wi(this),this.Cr=a,a!==null&&(this.wn=!1)}},isToModel:{get:function(){return this.wn},set:function(a){this._isFrozen&&wi(this),this.wn=a}},sourceProperty:{get:function(){return this.sl},set:function(a){this._isFrozen&&wi(this),this.sl=a}},converter:{get:function(){return this.Im},set:function(a){this._isFrozen&&wi(this),this.Im=a}},backConverter:{get:function(){return this.wk},set:function(a){this._isFrozen&&wi(this),this.wk=a}},mode:{get:function(){return this.el},set:function(a){this._isFrozen&&wi(this),this.el=a}}}),Hs.prototype.updateSource=Hs.prototype.sp,Hs.prototype.updateTarget=Hs.prototype.Mv,Hs.prototype.ofModel=Hs.prototype.dA,Hs.prototype.ofObject=Hs.prototype.cp,Hs.prototype.makeTwoWay=Hs.prototype.Kx;var Tx="Binding",M1=new Vt(Hs,"OneWay",1),Rp=new Vt(Hs,"TwoWay",2);Hs.className="Binding",Hs.parseEnum=function(a,y){return function(x){return x=Kr(a,x),x===null?y:x}},Hs.toString=Co,Hs.OneWay=M1,Hs.TwoWay=Rp;function vo(a,y,x){Ci.call(this),this.Vv=`,
"insertedLinkKeys": `,this.iy=`,
"modifiedLinkData": `,this.Xv=`,
"removedLinkKeys": `,this.md=[],this.$f=new Pn,this.wb=new Li,this.Jh="",this.Ri=this.Ak=this.cl=null,this.lf="from",this.mf="to",this.fj=this.ej="",this.dj="category",this.je="",this.jl="isGroup",this.Je="group",this.Lm=!1,y!==void 0&&(this.linkDataArray=y),a!==void 0&&(Xi(a)?this.nodeDataArray=a:x=a),x&&(Object.assign(this,x),a=x.Changed)&&(delete this.Changed,this.Pe(a))}Ct(vo,Ci),vo.constructGraphLinksModel=Ci.constructGraphLinksModel,vo.prototype.cloneProtected=function(a){Ci.prototype.cloneProtected.call(this,a),a.Jh=this.Jh,a.cl=this.cl,a.Ak=this.Ak,a.lf=this.lf,a.mf=this.mf,a.ej=this.ej,a.fj=this.fj,a.dj=this.dj,a.je=this.je,a.jl=this.jl,a.Je=this.Je,a.Lm=this.Lm},we=vo.prototype,we.clear=function(){Ci.prototype.clear.call(this),this.md=[],this.wb.clear(),this.$f.clear()},we.toString=function(a){if(a===void 0&&(a=0),2<=a)return this.np();var y=(this.name!==""?this.name:"")+" GraphLinksModel";if(0<a){y+=`
node data:`,a=this.nodeDataArray;var x=a.length,E;for(E=0;E<x;E++){var b=a[E];y+=" "+this.wa(b)+":"+Co(b)}for(y+=`
link data:`,a=this.linkDataArray,x=a.length,E=0;E<x;E++)b=a[E],y+=" "+yh(this,b,!0)+"-->"+yh(this,b,!1)}return y},we.Qv=function(a,y){this.linkKeyProperty===""&&Dt("GraphLinksModel.linkKeyProperty must not be an empty string for .toIncrementalData() to succeed.");var x=Ci.prototype.Qv.call(this,a,y),E=this,b=new Pn,z=new Pn,ee=new Pn,re=this.vh;a.changes.each(function(ue){ue.model===E&&(ue.modelChange==="linkDataArray"?ue.change===ts?b.add(ue.newValue):ue.change===ss&&ee.add(ue.oldValue):E.Jc(ue.object)?z.add(ue.object):ue.object!==null&&(ue.object!==null&&re&&re.contains(ue.object)?re.get(ue.object).each(function(fe){E.Jc(fe)&&z.add(fe)}):ue.object instanceof Ci||E.lb(ue.object)||k1(E,ue.object).each(function(fe){z.add(fe)})))});var oe=this.il;oe.clear(),b.each(function(ue){oe.add(E.Ac(ue)),y||z.add(ue)});var se=this.kl;return se.clear(),ee.each(function(ue){se.add(E.Ac(ue)),y&&z.add(ue)}),a=E.cloneDeep(z.Fa()),0<oe.count&&(x===null&&(x={}),y?x.removedLinkKeys=oe.Fa():x.insertedLinkKeys=oe.Fa()),0<a.length&&(x===null&&(x={}),x.modifiedLinkData=a),0<se.count&&(x===null&&(x={}),y?x.insertedLinkKeys=se.Fa():x.removedLinkKeys=se.Fa()),se.clear(),oe.clear(),x},we.rm=function(){var a=Ci.prototype.rm.call(this),y="";return this.linkCategoryProperty!=="category"&&typeof this.linkCategoryProperty=="string"&&(y+=`,
"linkCategoryProperty": `+this.quote(this.linkCategoryProperty)),this.linkKeyProperty!==""&&typeof this.linkKeyProperty=="string"&&(y+=`,
"linkKeyProperty": `+this.quote(this.linkKeyProperty)),this.linkFromKeyProperty!=="from"&&typeof this.linkFromKeyProperty=="string"&&(y+=`,
"linkFromKeyProperty": `+this.quote(this.linkFromKeyProperty)),this.linkToKeyProperty!=="to"&&typeof this.linkToKeyProperty=="string"&&(y+=`,
"linkToKeyProperty": `+this.quote(this.linkToKeyProperty)),this.linkFromPortIdProperty!==""&&typeof this.linkFromPortIdProperty=="string"&&(y+=`,
"linkFromPortIdProperty": `+this.quote(this.linkFromPortIdProperty)),this.linkToPortIdProperty!==""&&typeof this.linkToPortIdProperty=="string"&&(y+=`,
"linkToPortIdProperty": `+this.quote(this.linkToPortIdProperty)),this.linkLabelKeysProperty!==""&&typeof this.linkLabelKeysProperty=="string"&&(y+=`,
"linkLabelKeysProperty": `+this.quote(this.linkLabelKeysProperty)),this.nodeIsGroupProperty!=="isGroup"&&typeof this.nodeIsGroupProperty=="string"&&(y+=`,
"nodeIsGroupProperty": `+this.quote(this.nodeIsGroupProperty)),this.nodeGroupKeyProperty!=="group"&&typeof this.nodeGroupKeyProperty=="string"&&(y+=`,
"nodeGroupKeyProperty": `+this.quote(this.nodeGroupKeyProperty)),a+y},we.gp=function(a){Ci.prototype.gp.call(this,a),a.linkKeyProperty&&(this.linkKeyProperty=a.linkKeyProperty),a.linkFromKeyProperty&&(this.linkFromKeyProperty=a.linkFromKeyProperty),a.linkToKeyProperty&&(this.linkToKeyProperty=a.linkToKeyProperty),a.linkFromPortIdProperty&&(this.linkFromPortIdProperty=a.linkFromPortIdProperty),a.linkToPortIdProperty&&(this.linkToPortIdProperty=a.linkToPortIdProperty),a.linkCategoryProperty&&(this.linkCategoryProperty=a.linkCategoryProperty),a.linkLabelKeysProperty&&(this.linkLabelKeysProperty=a.linkLabelKeysProperty),a.nodeIsGroupProperty&&(this.nodeIsGroupProperty=a.nodeIsGroupProperty),a.nodeGroupKeyProperty&&(this.nodeGroupKeyProperty=a.nodeGroupKeyProperty)},we.Rv=function(){var a=Ci.prototype.Rv.call(this),y=`,
"linkDataArray": `+Yd(this,this.linkDataArray,!0);return a+y},we.kv=function(a){Ci.prototype.kv.call(this,a),a=a.linkDataArray,Array.isArray(a)&&(this.dm(a),this.linkDataArray=a)};function k1(a,y){for(var x=new Pn,E=0;E<a.linkDataArray.length;E++){var b=a.linkDataArray[E];dv(a,y,b,b,x)}return x}we.Pv=function(a,y){this.linkKeyProperty===""&&Dt("GraphLinksModel.linkKeyProperty must not be an empty string for .toIncrementalJson() to succeed.");var x=Ci.prototype.Pv.call(this,a,y),E=this,b=new Pn,z=new Pn,ee=new Pn,re=this.vh;a.changes.each(function(ue){ue.model===E&&(ue.modelChange==="linkDataArray"?ue.change===ts?b.add(ue.newValue):ue.change===ss&&ee.add(ue.oldValue):E.Jc(ue.object)?z.add(ue.object):ue.object!==null&&(ue.object!==null&&re&&re.contains(ue.object)?re.get(ue.object).each(function(fe){E.Jc(fe)&&z.add(fe)}):ue.object instanceof Ci||E.lb(ue.object)||k1(E,ue.object).each(function(fe){z.add(fe)})))});var oe=this.il;oe.clear(),b.each(function(ue){oe.add(E.Ac(ue)),y||z.add(ue)});var se=this.kl;return se.clear(),ee.each(function(ue){se.add(E.Ac(ue)),y&&z.add(ue)}),a=x,0<oe.count&&(a+=(y?this.Xv:this.Vv)+Yd(this,oe.Fa(),!0)),0<z.count&&(a+=this.iy+Yd(this,z.Fa(),!0)),0<se.count&&(a+=(y?this.Vv:this.Xv)+Yd(this,se.Fa(),!0)),se.clear(),oe.clear(),a},we.fp=function(a){(a.linkCategoryProperty!==void 0&&a.linkCategoryProperty!==this.linkCategoryProperty||a.linkKeyProperty!==void 0&&a.linkKeyProperty!==this.linkKeyProperty||a.linkFromKeyProperty!==void 0&&a.linkFromKeyProperty!==this.linkFromKeyProperty||a.linkToKeyProperty!==void 0&&a.linkToKeyProperty!==this.linkToKeyProperty||a.linkFromPortIdProperty!==void 0&&a.linkFromPortIdProperty!==this.linkFromPortIdProperty||a.linkToPortIdProperty!==void 0&&a.linkToPortIdProperty!==this.linkToPortIdProperty||a.linkLabelKeysProperty!==void 0&&a.linkLabelKeysProperty!==this.linkLabelKeysProperty||a.nodeIsGroupProperty!==void 0&&a.nodeIsGroupProperty!==this.nodeIsGroupProperty||a.nodeGroupKeyProperty!==void 0&&a.nodeGroupKeyProperty!==this.nodeGroupKeyProperty)&&Dt("applyIncrementalJson cannot change Model properties"),Ci.prototype.fp.call(this,a);var y=a.insertedLinkKeys;if(Array.isArray(y))for(var x=y.length,E=0;E<x;E++){var b=y[E],z=this.jh(b);z===null&&(z=this.Jo({}),this.Ks(z,b),this.fi(z))}if(y=a.modifiedLinkData,Array.isArray(y)){for(x=y.length,E=0;E<x;E++)if(b=y[E],z=this.Ac(b),z=this.jh(z),z!==null){for(var ee in b)ee!=="__gohashid"&&ee!==this.linkKeyProperty&&this.setDataProperty(z,ee,b[ee]);N1(this,b,z)}}if(a=a.removedLinkKeys,Array.isArray(a))for(ee=a.length,y=0;y<ee;y++)x=this.jh(a[y]),x!==null&&this.bm(x)},vo.prototype.changeState=function(a,y){if(a!==null&&a.model===this){if(a.change===ga){var x=a.object,E=a.propertyName;if(E===this.linkKeyProperty&&this.Jc(x)){var b=a.I(y);y=a.I(!y),y!==void 0&&this.wb.remove(y),b!==void 0&&this.wb.add(b,x),rs(x,E,b);return}}else if(a.change===ts){if(x=a.newParam,a.modelChange==="linkDataArray"){a=a.newValue,kn(a)&&typeof x=="number"&&(E=this.Ac(a),y?(this.$f.remove(a),this.md[x]===a&&this.md.splice(x,1),E!==void 0&&this.wb.remove(E)):(this.$f.add(a),this.md[x]!==a&&this.md.splice(x,0,a),E!==void 0&&this.wb.add(E,a)));return}if(a.modelChange==="linkLabelKeys"){E=this.Ef(a.object),Array.isArray(E)&&typeof x=="number"&&(y?(x=E.indexOf(a.newValue),0<=x&&E.splice(x,1)):0>E.indexOf(a.newValue)&&E.splice(x,0,a.newValue));return}}else if(a.change===ss){if(x=a.oldParam,a.modelChange==="linkDataArray"){a=a.oldValue,kn(a)&&typeof x=="number"&&(E=this.Ac(a),y?(this.$f.add(a),this.md[x]!==a&&this.md.splice(x,0,a),E!==void 0&&this.wb.add(E,a)):(this.$f.remove(a),this.md[x]===a&&this.md.splice(x,1),E!==void 0&&this.wb.remove(E)));return}if(a.modelChange==="linkLabelKeys"){E=this.Ef(a.object),Array.isArray(E)&&typeof x=="number"&&(y?0>E.indexOf(a.newValue)&&E.splice(x,0,a.newValue):(x=E.indexOf(a.newValue),0<=x&&E.splice(x,1)));return}}Ci.prototype.changeState.call(this,a,y)}},we=vo.prototype,we.Vl=function(a){if(a!==void 0){var y=this.Ri;if(y!==null){var x=this.hc(a);x===null&&(x=this.copyNodeData(y),rs(x,this.nodeKeyProperty,a),this.xf(x))}return a}},we.yx=function(a){return yh(this,a,!0)},we.wv=function(a,y){Bg(this,a,y,!0)},we.Bx=function(a){return yh(this,a,!1)},we.Bv=function(a,y){Bg(this,a,y,!1)};function yh(a,y,x){if(y!==null&&(a=x?a.lf:a.mf,a!==""&&(a=Is(y,a),a!==void 0))){if(Xd(a))return a;Dt((x?"FromKey":"ToKey")+" value for link data "+y+" is not a number or a string: "+a)}}function Bg(a,y,x,E){if(x===null&&(x=void 0),y!==null){var b=E?a.lf:a.mf;if(b!=="")if(x=a.Vl(x),a.Jc(y)){var z=Is(y,b);z!==x&&(vc(a,z,y),rs(y,b,x),a.hc(x)===null&&mc(a,x,y),Js(a,E?"linkFromKey":"linkToKey",ga,b,y,z,x),typeof b=="string"&&a.La(y,b))}else rs(y,b,x)}}we.zx=function(a){return gv(this,a,!0)},we.xv=function(a,y){Og(this,a,y,!0)},we.Cx=function(a){return gv(this,a,!1)},we.Cv=function(a,y){Og(this,a,y,!1)};function gv(a,y,x){return y===null||(a=x?a.ej:a.fj,a==="")?"":(y=Is(y,a),y===void 0?"":y)}function Og(a,y,x,E){if(y!==null){var b=E?a.ej:a.fj;if(b!=="")if(a.Jc(y)){var z=Is(y,b);z===void 0&&(z=""),z!==x&&(rs(y,b,x),Js(a,E?"linkFromPortId":"linkToPortId",ga,b,y,z,x),typeof b=="string"&&a.La(y,b))}else rs(y,b,x)}}we.Ef=function(a){if(a===null)return pv;var y=this.je;return y===""?pv:(a=Is(a,y),a===void 0?pv:a)},we.Ls=function(a,y){if(a!==null){var x=this.je;if(x!=="")if(this.Jc(a)){var E=Is(a,x);if(E===void 0&&(E=pv),E!==y){if(Array.isArray(E))for(var b=E.length,z=0;z<b;z++)vc(this,E[z],a);for(rs(a,x,y),b=y.length,z=0;z<b;z++){var ee=y[z];this.hc(ee)===null&&mc(this,ee,a)}Js(this,"linkLabelKeys",ga,x,a,E,y),typeof x=="string"&&this.La(a,x)}}else rs(a,x,y)}},we.Bu=function(a,y){if(y!=null&&a!==null){var x=this.je;if(x!==""){var E=Is(a,x);if(E===void 0)x=[],x.push(y),this.Ls(a,x);else if(Array.isArray(E)){var b=E.indexOf(y);0<=b||(b=E.length,E.push(y),this.Jc(a)&&(this.hc(y)===null&&mc(this,y,a),Js(this,"linkLabelKeys",ts,x,a,null,y,null,b)))}else Dt(x+" property is not an Array; cannot addLabelKeyForLinkData: "+a)}}},we.Qx=function(a,y){if(y!=null&&a!==null){var x=this.je;if(x!==""){var E=Is(a,x);if(Array.isArray(E)){var b=E.indexOf(y);0>b||(E.splice(b,1),this.Jc(a)&&(vc(this,y,a),Js(this,"linkLabelKeys",ss,x,a,y,null,b,null)))}else E!==void 0&&Dt(x+" property is not an Array; cannot removeLabelKeyforLinkData: "+a)}}},we.Ac=function(a){if(a!==null){var y=this.Jh;if(y!==""&&(y=Is(a,y),y!==void 0)){if(Xd(y))return y;Dt("Key value for link data "+a+" is not a number or a string: "+y)}}},we.Ks=function(a,y){if(a!==null){var x=this.Jh;if(x!=="")if(this.Jc(a)){var E=Is(a,x);E!==y&&this.jh(y)===null&&(rs(a,x,y),E!==void 0&&this.wb.remove(E),this.wb.add(y,a),Js(this,"linkKey",ga,x,a,E,y),typeof x=="string"&&this.La(a,x))}else rs(a,x,y)}},we.jh=function(a){return a===null&&Dt("GraphLinksModel.findLinkDataForKey:key must not be null"),a!==void 0&&Xd(a)?this.wb.I(a):null},we.Bs=function(a){if(a!==null){var y=this.Jh;if(y!==""){var x=this.Ac(a);if(x===void 0||this.wb.contains(x)){var E=this.cl;if(E!==null&&(x=E(this,a),x!=null&&!this.wb.contains(x))){rs(a,y,x);return}if(typeof x=="string"){for(E=2;this.wb.contains(x+E);)E++;rs(a,y,x+E)}else if(x===void 0||typeof x=="number"){for(x=-this.wb.count-1;this.wb.contains(x);)x--;rs(a,y,x)}}}}},we.Jc=function(a){return a===null?!1:this.$f.contains(a)},we.fi=function(a){a!==null&&(Ws(a),this.Jc(a)||F1(this,a,!0))};function F1(a,y,x){if(a.linkKeyProperty!==""){var E=a.Ac(y);if(E!==void 0&&a.wb.I(E)===y)return;a.Bs(y),E=a.Ac(y),E===void 0&&Dt("GraphLinksModel.makeLinkDataKeyUnique failed on "+y+". Data not added to model."),a.wb.add(E,y)}a.$f.add(y),E=null,x&&(E=a.md.length,a.md.splice(E,0,y)),Js(a,"linkDataArray",ts,"linkDataArray",a,null,y,null,E),dy(a,y)}we.Ey=function(a){if(Array.isArray(a))for(var y=a.length,x=0;x<y;x++)this.fi(a[x]);else for(a=a.iterator;a.next();)this.fi(a.value)},we.bm=function(a){a!==null&&A1(this,a,!0)};function A1(a,y,x){a.$f.remove(y);var E=a.Ac(y);if(E!==void 0&&a.wb.remove(E),E=null,x){if(E=a.md.indexOf(y),0>E)return;a.md.splice(E,1)}if(Js(a,"linkDataArray",ss,"linkDataArray",a,y,null,E,null),x=yh(a,y,!0),vc(a,x,y),x=yh(a,y,!1),vc(a,x,y),E=a.Ef(y),Array.isArray(E))for(var b=E.length,z=0;z<b;z++)x=E[z],vc(a,x,y)}we.lA=function(a){if(Array.isArray(a))for(var y=a.length,x=0;x<y;x++)this.bm(a[x]);else for(a=a.iterator;a.next();)this.bm(a.value)},we.Zz=function(a){if(this.linkKeyProperty===""&&Dt("GraphLinksModel.linkKeyProperty must not be an empty string for .mergeLinkDataArray() to succeed."),a!==this.linkDataArray&&Xi(a)){var y=this.kl;y.clear(),y.addAll(this.wb.iteratorKeys);var x=this.il;x.clear();for(var E=a.length,b=0;b<E;b++){var z=a[b],ee=this.Ac(z);if(ee!==void 0){x.add(ee);var re=this.jh(ee);re!==z&&(re!==null?(this.Do(re,z),N1(this,z,re)):(z=this.cloneDeep(z),this.Ks(z,ee),this.fi(z)))}else ee=this.cloneDeep(z),this.fi(ee),x.add(this.Ac(ee))}for(a=y.iterator;a.next();)E=a.value,x.contains(E)||(E=this.jh(E))&&this.bm(E);y.clear(),x.clear()}};function dy(a,y){var x=yh(a,y,!0);x=a.Vl(x),a.hc(x)===null&&mc(a,x,y),x=yh(a,y,!1),x=a.Vl(x),a.hc(x)===null&&mc(a,x,y);var E=a.Ef(y);if(Array.isArray(E))for(var b=E.length,z=0;z<b;z++)x=E[z],a.hc(x)===null&&mc(a,x,y)}we.Jo=function(a){if(a===null)return null;var y=this.Ak;return a=y!==null?y(a,this):fv(this,a,!0),kn(a)&&(jo(a),this.lf!==""&&rs(a,this.lf,void 0),this.mf!==""&&rs(a,this.mf,void 0),this.je!==""&&rs(a,this.je,[])),a},we.Yu=function(a){if(a===null)return!1;var y=this.jl;return y===""?!1:!!Is(a,y)},we.lh=function(a){if(a!==null){var y=this.Je;if(y!==""&&(y=Is(a,y),y!==void 0)){if(Xd(y))return y;Dt("GroupKey value for node data "+a+" is not a number or a string: "+y)}}},we.mp=function(a,y){if(y===null&&(y=void 0),a!==null){var x=this.Je;if(x!=="")if(this.lb(a)){var E=Is(a,x);E!==y&&(vc(this,E,a),rs(a,x,y),this.hc(y)===null&&mc(this,y,a),Js(this,"nodeGroupKey",ga,x,a,E,y),typeof x=="string"&&this.La(a,x))}else rs(a,x,y)}},vo.prototype.copyNodeData=function(a){return a===null?null:(a=Ci.prototype.copyNodeData.call(this,a),this.Ij||this.Je===""||Is(a,this.Je)===void 0||rs(a,this.Je,void 0),a)},vo.prototype.setDataProperty=function(a,y,x){if(this.lb(a)){if(y===this.nodeKeyProperty){this.km(a,x);return}if(y===this.nodeCategoryProperty){this.jm(a,x);return}if(y===this.nodeGroupKeyProperty){this.mp(a,x);return}}else if(this.Jc(a)){if(y===this.linkFromKeyProperty){Bg(this,a,x,!0);return}if(y===this.linkToKeyProperty){Bg(this,a,x,!1);return}if(y===this.linkFromPortIdProperty){Og(this,a,x,!0);return}if(y===this.linkToPortIdProperty){Og(this,a,x,!1);return}if(y===this.linkKeyProperty){this.Ks(a,x);return}if(y===this.linkCategoryProperty){this.lp(a,x);return}if(y===this.linkLabelKeysProperty){this.Ls(a,x);return}}var E=Is(a,y);E!==x&&(rs(a,y,x),this.Fs(a,y,E,x))},we=vo.prototype,we.Do=function(a,y){if(y){var x=this.lb(a),E=this.Jc(a),b;for(b in y)b==="__gohashid"||x&&b===this.nodeKeyProperty||x&&b===this.nodeIsGroupProperty&&Is(a,b)===y[b]||E&&b===this.linkKeyProperty||this.setDataProperty(a,b,y[b])}},we.jp=function(a,y){Ci.prototype.jp.call(this,a,y);for(var x=this.kb.iterator;x.next();)this.qv(x.value,a,y);for(x=this.$f.iterator;x.next();){var E=x.value,b=a,z=y;if(yh(this,E,!0)===b){var ee=this.lf;rs(E,ee,z),Js(this,"linkFromKey",ga,ee,E,b,z),typeof ee=="string"&&this.La(E,ee)}if(yh(this,E,!1)===b&&(ee=this.mf,rs(E,ee,z),Js(this,"linkToKey",ga,ee,E,b,z),typeof ee=="string"&&this.La(E,ee)),ee=this.Ef(E),Array.isArray(ee))for(var re=ee.length,oe=this.je,se=0;se<re;se++)ee[se]===b&&(ee[se]=z,Js(this,"linkLabelKeys",ts,oe,E,b,z,se,se))}},we.qv=function(a,y,x){if(this.lh(a)===y){var E=this.Je;rs(a,E,x),Js(this,"nodeGroupKey",ga,E,a,y,x),typeof E=="string"&&this.La(a,E)}},we.Lv=function(){Ci.prototype.Lv.call(this);for(var a=this.linkDataArray,y=a.length,x=0;x<y;x++)dy(this,a[x])},we.fm=function(a){Ci.prototype.fm.call(this,a),a=this.wa(a);var y=Bp(this,a);if(y!==null){var x=qi();for(y=y.iterator;y.next();){var E=y.value;if(this.lb(E)){if(this.lh(E)===a){var b=this.Je;Js(this,"nodeGroupKey",ga,b,E,a,a),typeof b=="string"&&this.La(E,b),x.push(E)}}else if(yh(this,E,!0)===a&&(b=this.lf,Js(this,"linkFromKey",ga,b,E,a,a),typeof b=="string"&&this.La(E,b),x.push(E)),yh(this,E,!1)===a&&(b=this.mf,Js(this,"linkToKey",ga,b,E,a,a),typeof b=="string"&&this.La(E,b),x.push(E)),b=this.Ef(E),Array.isArray(b))for(var z=b.length,ee=this.je,re=0;re<z;re++)b[re]===a&&(Js(this,"linkLabelKeys",ts,ee,E,a,a,re,re),x.push(E))}for(y=0;y<x.length;y++)vc(this,a,x[y]);Zi(x)}},we.em=function(a){Ci.prototype.em.call(this,a);var y=this.lh(a);this.hc(y)===null&&mc(this,y,a)},we.qp=function(a){Ci.prototype.qp.call(this,a);var y=this.lh(a);vc(this,y,a)},we.ps=function(a){if(a===null)return"";var y=this.dj;if(y===""||(y=Is(a,y),y===void 0))return"";if(typeof y=="string")return y;Dt("getCategoryForLinkData found a non-string category for "+a+": "+y)},vo.prototype.getLinkCategoryForData=function(a){return this.ps(a)},vo.prototype.lp=function(a,y){if(a!==null){var x=this.dj;if(x!=="")if(this.Jc(a)){var E=Is(a,x);E===void 0&&(E=""),E!==y&&(rs(a,x,y),Js(this,"linkCategory",ga,x,a,E,y),typeof x=="string"&&this.La(a,x))}else rs(a,x,y)}},vo.prototype.setLinkCategoryForData=function(a,y){this.lp(a,y)},we=vo.prototype,we.lm=function(a,y){Ci.prototype.lm.call(this,a,y),this.mp(y,this.lh(a))};function N1(a,y,x){a.lp(x,a.ps(y)),a.wv(x,a.yx(y)),a.Bv(x,a.Bx(y)),a.Ls(x,a.Ef(y)),a.xv(x,a.zx(y)),a.Cv(x,a.Cx(y))}we.Wj=function(){return!0},we.ri=function(){return!0},we.xs=function(){return!0},we.Xj=function(){return!0},Yt.Object.defineProperties(vo.prototype,{archetypeNodeData:{get:function(){return this.Ri},set:function(a){var y=this.Ri;y!==a&&(this.Ri=a,this.g("archetypeNodeData",y,a))}},linkFromKeyProperty:{get:function(){return this.lf},set:function(a){var y=this.lf;y!==a&&(this.lf=a,this.g("linkFromKeyProperty",y,a))}},linkToKeyProperty:{get:function(){return this.mf},set:function(a){var y=this.mf;y!==a&&(this.mf=a,this.g("linkToKeyProperty",y,a))}},linkFromPortIdProperty:{get:function(){return this.ej},set:function(a){var y=this.ej;y!==a&&(this.ej=a,this.g("linkFromPortIdProperty",y,a))}},linkToPortIdProperty:{get:function(){return this.fj},set:function(a){var y=this.fj;y!==a&&(this.fj=a,this.g("linkToPortIdProperty",y,a))}},linkLabelKeysProperty:{get:function(){return this.je},set:function(a){var y=this.je;y!==a&&(this.je=a,this.g("linkLabelKeysProperty",y,a))}},linkDataArray:{get:function(){return this.md},set:function(a){var y=this.md;if(y!==a){this.wb.clear();for(var x=a.length,E=0;E<x;E++){var b=a[E];kn(b)||Dt("GraphLinksModel.linkDataArray must only contain Objects, not: "+b),Ws(b)}if(this.md=a,this.linkKeyProperty!==""){for(E=new An,b=0;b<x;b++){var z=a[b],ee=this.Ac(z);ee===void 0||this.wb.I(ee)!==null?E.add(z):this.wb.add(ee,z)}for(E=E.iterator;E.next();)b=E.value,this.Bs(b),z=this.Ac(b),z!==void 0&&this.wb.add(z,b)}for(E=new Pn,b=0;b<x;b++)E.add(a[b]);for(this.$f=E,Js(this,"linkDataArray",ga,"linkDataArray",this,y,a),y=0;y<x;y++)dy(this,a[y])}}},linkKeyProperty:{get:function(){return this.Jh},set:function(a){var y=this.Jh;if(y!==a){this.Jh=a,this.wb.clear();for(var x=this.linkDataArray.length,E=0;E<x;E++){var b=this.linkDataArray[E],z=this.Ac(b);z===void 0&&(this.Bs(b),z=this.Ac(b)),z!==void 0&&this.wb.add(z,b)}this.g("linkKeyProperty",y,a)}}},makeUniqueLinkKeyFunction:{get:function(){return this.cl},set:function(a){var y=this.cl;y!==a&&(this.cl=a,this.g("makeUniqueLinkKeyFunction",y,a))}},copyLinkDataFunction:{get:function(){return this.Ak},set:function(a){var y=this.Ak;y!==a&&(this.Ak=a,this.g("copyLinkDataFunction",y,a))}},nodeIsGroupProperty:{get:function(){return this.jl},set:function(a){var y=this.jl;y!==a&&(this.jl=a,this.g("nodeIsGroupProperty",y,a))}},nodeGroupKeyProperty:{get:function(){return this.Je},set:function(a){var y=this.Je;y!==a&&(this.Je=a,this.g("nodeGroupKeyProperty",y,a))}},Ij:{get:function(){return this.Lm},set:function(a){this.Lm!==a&&(this.Lm=a)}},linkCategoryProperty:{get:function(){return this.dj},set:function(a){var y=this.dj;y!==a&&(this.dj=a,this.g("linkCategoryProperty",y,a))}},type:{get:function(){return"GraphLinksModel"}}}),vo.prototype.setCategoryForLinkData=vo.prototype.lp,vo.prototype.getCategoryForLinkData=vo.prototype.ps,vo.prototype.assignAllDataProperties=vo.prototype.Do,vo.prototype.setGroupKeyForNodeData=vo.prototype.mp,vo.prototype.getGroupKeyForNodeData=vo.prototype.lh,vo.prototype.isGroupForNodeData=vo.prototype.Yu,vo.prototype.copyLinkData=vo.prototype.Jo,vo.prototype.mergeLinkDataArray=vo.prototype.Zz,vo.prototype.removeLinkDataCollection=vo.prototype.lA,vo.prototype.removeLinkData=vo.prototype.bm,vo.prototype.addLinkDataCollection=vo.prototype.Ey,vo.prototype.addLinkData=vo.prototype.fi,vo.prototype.containsLinkData=vo.prototype.Jc,vo.prototype.makeLinkDataKeyUnique=vo.prototype.Bs,vo.prototype.findLinkDataForKey=vo.prototype.jh,vo.prototype.setKeyForLinkData=vo.prototype.Ks,vo.prototype.getKeyForLinkData=vo.prototype.Ac,vo.prototype.removeLabelKeyForLinkData=vo.prototype.Qx,vo.prototype.addLabelKeyForLinkData=vo.prototype.Bu,vo.prototype.setLabelKeysForLinkData=vo.prototype.Ls,vo.prototype.getLabelKeysForLinkData=vo.prototype.Ef,vo.prototype.setToPortIdForLinkData=vo.prototype.Cv,vo.prototype.getToPortIdForLinkData=vo.prototype.Cx,vo.prototype.setFromPortIdForLinkData=vo.prototype.xv,vo.prototype.getFromPortIdForLinkData=vo.prototype.zx,vo.prototype.setToKeyForLinkData=vo.prototype.Bv,vo.prototype.getToKeyForLinkData=vo.prototype.Bx,vo.prototype.setFromKeyForLinkData=vo.prototype.wv,vo.prototype.getFromKeyForLinkData=vo.prototype.yx,vo.prototype.clear=vo.prototype.clear;var pv=Object.freeze([]);vo.className="GraphLinksModel",ac.GraphLinksModel=vo,Ci.constructGraphLinksModel=Ci.constructGraphLinksModel=function(){return new vo},Ci.initDiagramModel=hy=function(){return new vo};function bu(a,y){Ci.call(this),this.Ke="parent",this.Nm=!1,this.nj="parentLinkCategory",a!==void 0&&(Xi(a)?this.nodeDataArray=a:y=a),y&&(Object.assign(this,y),a=y.Changed)&&(delete this.Changed,this.Pe(a))}Ct(bu,Ci),bu.constructGraphLinksModel=Ci.constructGraphLinksModel,bu.prototype.cloneProtected=function(a){Ci.prototype.cloneProtected.call(this,a),a.Ke=this.Ke,a.Nm=this.Nm,a.nj=this.nj},we=bu.prototype,we.toString=function(a){if(a===void 0&&(a=0),2<=a)return this.np();var y=(this.name!==""?this.name:"")+" TreeModel";if(0<a){y+=`
node data:`,a=this.nodeDataArray;for(var x=a.length,E=0;E<x;E++){var b=a[E];y+=" "+this.wa(b)+":"+Co(b)}}return y},we.rm=function(){var a=Ci.prototype.rm.call(this),y="";return this.nodeParentKeyProperty!=="parent"&&typeof this.nodeParentKeyProperty=="string"&&(y+=`,
"nodeParentKeyProperty": `+this.quote(this.nodeParentKeyProperty)),a+y},we.gp=function(a){Ci.prototype.gp.call(this,a),a.nodeParentKeyProperty&&(this.nodeParentKeyProperty=a.nodeParentKeyProperty)},we.fp=function(a){a.nodeParentKeyProperty!==void 0&&a.nodeParentKeyProperty!==this.nodeParentKeyProperty&&Dt("applyIncrementalJson cannot change Model properties"),Ci.prototype.fp.call(this,a)},we.Vl=function(a){return a},we.mh=function(a){if(a!==null){var y=this.Ke;if(y!==""&&(y=Is(a,y),y!==void 0)){if(Xd(y))return y;Dt("ParentKey value for node data "+a+" is not a number or a string: "+y)}}},we.qe=function(a,y){if(y===null&&(y=void 0),a!==null){var x=this.Ke;if(x!=="")if(y=this.Vl(y),this.lb(a)){var E=Is(a,x);E!==y&&(vc(this,E,a),rs(a,x,y),this.hc(y)===null&&mc(this,y,a),Js(this,"nodeParentKey",ga,x,a,E,y),typeof x=="string"&&this.La(a,x))}else rs(a,x,y)}},we.ss=function(a){if(a===null)return"";var y=this.nj;return y===""||(y=Is(a,y),y===void 0)?"":typeof y=="string"?y:(Dt("getParentLinkCategoryForNodeData found a non-string category for "+a+": "+y),"")},bu.prototype.getLinkCategoryForData=function(a){return this.ss(a)},bu.prototype.Ms=function(a,y){if(a!==null){var x=this.nj;if(x!=="")if(this.lb(a)){var E=Is(a,x);E===void 0&&(E=""),E!==y&&(rs(a,x,y),Js(this,"parentLinkCategory",ga,x,a,E,y),typeof x=="string"&&this.La(a,x))}else rs(a,x,y)}},bu.prototype.setLinkCategoryForData=function(a,y){this.Ms(a,y)},bu.prototype.copyNodeData=function(a){return a===null?null:(a=Ci.prototype.copyNodeData.call(this,a),this.Jj||this.Ke===""||Is(a,this.Ke)===void 0||rs(a,this.Ke,void 0),a)},bu.prototype.setDataProperty=function(a,y,x){if(this.lb(a)){if(y===this.nodeKeyProperty){this.km(a,x);return}if(y===this.nodeCategoryProperty){this.jm(a,x);return}if(y===this.nodeParentKeyProperty){this.qe(a,x);return}}var E=Is(a,y);E!==x&&(rs(a,y,x),this.Fs(a,y,E,x))},we=bu.prototype,we.jp=function(a,y){Ci.prototype.jp.call(this,a,y);for(var x=this.kb.iterator;x.next();)this.qv(x.value,a,y)},we.qv=function(a,y,x){if(this.mh(a)===y){var E=this.Ke;rs(a,E,x),Js(this,"nodeParentKey",ga,E,a,y,x),typeof E=="string"&&this.La(a,E)}},we.fm=function(a){Ci.prototype.fm.call(this,a),a=this.wa(a);var y=Bp(this,a);if(y!==null){var x=qi();for(y=y.iterator;y.next();){var E=y.value;if(this.lb(E)&&this.mh(E)===a){var b=this.Ke;Js(this,"nodeParentKey",ga,b,E,a,a),typeof b=="string"&&this.La(E,b),x.push(E)}}for(y=0;y<x.length;y++)vc(this,a,x[y]);Zi(x)}},we.em=function(a){Ci.prototype.em.call(this,a);var y=this.mh(a);y=this.Vl(y),this.hc(y)===null&&mc(this,y,a)},we.qp=function(a){Ci.prototype.qp.call(this,a);var y=this.mh(a);vc(this,y,a)},we.lm=function(a,y){Ci.prototype.lm.call(this,a,y),this.Ms(y,this.ss(a)),this.qe(y,this.mh(a))},we.Tl=function(){return!0},we.xs=function(){return!0},Yt.Object.defineProperties(bu.prototype,{nodeParentKeyProperty:{get:function(){return this.Ke},set:function(a){var y=this.Ke;y!==a&&(this.Ke=a,this.g("nodeParentKeyProperty",y,a))}},Jj:{get:function(){return this.Nm},set:function(a){this.Nm!==a&&(this.Nm=a)}},parentLinkCategoryProperty:{get:function(){return this.nj},set:function(a){var y=this.nj;y!==a&&(this.nj=a,this.g("parentLinkCategoryProperty",y,a))}},linkCategoryProperty:{get:function(){return this.parentLinkCategoryProperty},set:function(a){this.parentLinkCategoryProperty=a}},type:{get:function(){return"TreeModel"}}}),bu.prototype.setParentLinkCategoryForNodeData=bu.prototype.Ms,bu.prototype.getParentLinkCategoryForNodeData=bu.prototype.ss,bu.prototype.setParentKeyForNodeData=bu.prototype.qe,bu.prototype.getParentKeyForNodeData=bu.prototype.mh,bu.className="TreeModel",ac.TreeModel=bu;function fs(a){as.call(this),this.lw=this.Zm=this.lc=0,this.Wp=360,this.kw=sc,this.Ti=0,this.Zv=new Qe,this.Jp=this.me=0,this.Xr=new Hp,this.gt=this.mj=0,this.ty=600,this.eo=NaN,this.Cm=1,this.ro=0,this.ul=360,this.Rb=sc,this.K=Lu,this.nd=Ig,this.hd=ry,this.tf=6,this.Nn=Pv,a&&Object.assign(this,a)}Ct(fs,as),fs.prototype.cloneProtected=function(a){as.prototype.cloneProtected.call(this,a),a.eo=this.eo,a.Cm=this.Cm,a.ro=this.ro,a.ul=this.ul,a.Rb=this.Rb,a.K=this.K,a.nd=this.nd,a.hd=this.hd,a.tf=this.tf,a.Nn=this.Nn},fs.prototype.qb=function(a){a.classType===fs?a===xv||a===wv||a===yv||a===Sv||a===Ig?this.sorting=a:a===bf||a===Rg||a===Lu||a===Qd?this.direction=a:a===kd||a===Jd||a===sc||a===lc?this.arrangement=a:(a===Yf||a===Pv)&&(this.nodeDiameterFormula=a):as.prototype.qb.call(this,a)},fs.prototype.createNetwork=function(){return new jg(this)},fs.prototype.doLayout=function(a){if(this.network===null&&(this.network=this.makeNetwork(a)),this.arrangementOrigin=this.initialOrigin(this.arrangementOrigin),a=this.network.vertexes,1>=a.count)a.count===1&&(a=a.first(),a.centerX=0,a.centerY=0);else{var y=new An;y.addAll(a.iterator),a=new An;var x=new An,E=this.sort(y),b,z,ee=this.Jp,re=this.arrangement,oe=this.nodeDiameterFormula,se=this.radius;(!isFinite(se)||0>=se)&&(se=NaN);var ue=this.aspectRatio;(!isFinite(ue)||0>=ue)&&(ue=1);var fe=this.startAngle;isFinite(fe)||(fe=0);var ve=this.sweepAngle;if((!isFinite(ve)||360<ve||1>ve)&&(ve=360),y=this.spacing,isFinite(y)||(y=NaN),re===lc&&oe===Yf?re=sc:re===lc&&oe!==Yf&&(re=this.arrangement),(this.direction===bf||this.direction===Rg)&&this.sorting!==Ig){for(oe=0;!(oe>=E.length)&&(a.add(E.M(oe)),!(oe+1>=E.length));oe+=2)x.add(E.M(oe+1));this.direction===bf?(this.arrangement===lc&&a.reverse(),E=new An,E.addAll(a),E.addAll(x)):(this.arrangement===lc&&x.reverse(),E=new An,E.addAll(x),E.addAll(a))}oe=E.length;for(var ye=z=b=0;ye<E.length;ye++){var Ce=fe+ve*z*(this.direction===Lu?1:-1)/oe,Ae=E.M(ye).diameter;isNaN(Ae)&&(Ae=qd(E.M(ye),Ce)),360>ve&&(ye===0||ye===E.length-1)&&(Ae/=2),b+=Ae,z++}if(isNaN(se)||re===lc){if(isNaN(y)&&(y=6),re!==sc&&re!==lc){for(z=-1/0,ee=0;ee<oe;ee++)ye=E.M(ee),b=E.M(ee===oe-1?0:ee+1),isNaN(ye.diameter)&&qd(ye,0),isNaN(b.diameter)&&qd(b,0),z=Math.max(z,(ye.diameter+b.diameter)/2);ee=z+y,re===kd?se=(z+y)/(2*Math.PI/oe):se=mv(this,ee*(360<=ve?oe:oe-1),ue,fe*Math.PI/180,ve*Math.PI/180)}else se=mv(this,b+(360<=ve?oe:oe-1)*(re!==lc?y:1.6*y),ue,fe*Math.PI/180,ve*Math.PI/180);z=se*ue}else if(z=se*ue,ye=fy(this,se,z,fe*Math.PI/180,ve*Math.PI/180),isNaN(y))(re===sc||re===lc)&&(y=(ye-b)/(360<=ve?oe:oe-1));else if(re===sc||re===lc)ye=(ye-b)/(360<=ve?oe:oe-1),ye<y?(se=mv(this,b+y*(360<=ve?oe:oe-1),ue,fe*Math.PI/180,ve*Math.PI/180),z=se*ue):y=ye;else{for(ee=-1/0,b=0;b<oe;b++)Ce=E.M(b),Ae=E.M(b===oe-1?0:b+1),isNaN(Ce.diameter)&&qd(Ce,0),isNaN(Ae.diameter)&&qd(Ae,0),ee=Math.max(ee,(Ce.diameter+Ae.diameter)/2);ee+=y,b=mv(this,ee*(360<=ve?oe:oe-1),ue,fe*Math.PI/180,ve*Math.PI/180),b>se?(se=b,z=se*ue):ee=ye/(360<=ve?oe:oe-1)}if(this.kw=re,this.lc=se,this.Zm=ue,this.lw=fe,this.Wp=ve,this.Ti=y,this.me=z,this.Jp=ee,y=E,E=this.kw,re=this.lc,se=this.lw,ue=this.Wp,fe=this.Ti,ve=this.me,oe=this.Jp,this.direction!==bf&&this.direction!==Rg||E!==lc)if(this.direction===bf||this.direction===Rg){switch(ee=0,E){case Jd:ee=180*vv(this,re,ve,se,oe)/Math.PI;break;case sc:oe=y=0,ee=a.first(),ee!==null&&(y=qd(ee,Math.PI/2)),ee=x.first(),ee!==null&&(oe=qd(ee,Math.PI/2)),ee=180*vv(this,re,ve,se,fe+(y+oe)/2)/Math.PI;break;case kd:ee=ue/y.length}if(this.direction===bf){switch(E){case Jd:zp(this,a,se,Qd);break;case sc:jp(this,a,se,Qd);break;case kd:Ip(this,a,ue/2,se,Qd)}switch(E){case Jd:zp(this,x,se+ee,Lu);break;case sc:jp(this,x,se+ee,Lu);break;case kd:Ip(this,x,ue/2,se+ee,Lu)}}else{switch(E){case Jd:zp(this,x,se,Qd);break;case sc:jp(this,x,se,Qd);break;case kd:Ip(this,x,ue/2,se,Qd)}switch(E){case Jd:zp(this,a,se+ee,Lu);break;case sc:jp(this,a,se+ee,Lu);break;case kd:Ip(this,a,ue/2,se+ee,Lu)}}}else switch(E){case Jd:zp(this,y,se,this.direction);break;case sc:jp(this,y,se,this.direction);break;case kd:Ip(this,y,ue,se,this.direction);break;case lc:T1(this,y,ue,se,this.direction)}else T1(this,y,ue,se-ue/2,Lu)}this.updateParts(),this.network=null,this.isValidLayout=!0};function Ip(a,y,x,E,b){var z=a.Wp,ee=a.lc;a=a.me,E=E*Math.PI/180,x=x*Math.PI/180;for(var re=y.length,oe=0;oe<re;oe++){var se=E+(b===Lu?oe*x/(360<=z?re:re-1):-(oe*x)/re),ue=y.M(oe),fe=ee*Math.tan(se)/a;fe=Math.sqrt((ee*ee+a*a*fe*fe)/(1+fe*fe)),ue.centerX=fe*Math.cos(se),ue.centerY=fe*Math.sin(se),ue.actualAngle=180*se/Math.PI}}function jp(a,y,x,E){var b=a.lc,z=a.me,ee=a.Ti;x=x*Math.PI/180;for(var re=y.length,oe=0;oe<re;oe++){var se=y.M(oe),ue=y.M(oe===re-1?0:oe+1),fe=z*Math.sin(x);se.centerX=b*Math.cos(x),se.centerY=fe,se.actualAngle=180*x/Math.PI,isNaN(se.diameter)&&qd(se,0),isNaN(ue.diameter)&&qd(ue,0),se=vv(a,b,z,E===Lu?x:-x,(se.diameter+ue.diameter)/2+ee),x+=E===Lu?se:-se}}function zp(a,y,x,E){var b=a.lc,z=a.me,ee=a.Jp;x=x*Math.PI/180;for(var re=y.length,oe=0;oe<re;oe++){var se=y.M(oe);se.centerX=b*Math.cos(x),se.centerY=z*Math.sin(x),se.actualAngle=180*x/Math.PI,se=vv(a,b,z,E===Lu?x:-x,ee),x+=E===Lu?se:-se}}function T1(a,y,x,E,b){var z=a.Wp;if(a.mj=0,a.Xr=new Hp,360>x){for(z=E+(b===Lu?z:-z);0>z;)z+=360;z%=360,180<z&&(z-=360),z*=Math.PI/180,a.gt=z,B1(a,y,x,E,b)}else D1(a,y,x,E,b);a.Xr.commit(y)}function D1(a,y,x,E,b){var z=a.lc,ee=a.Ti,re=a.Zm,oe=z*Math.cos(E*Math.PI/180),se=a.me*Math.sin(E*Math.PI/180),ue=y.Fa();if(ue.length===3)ue[0].centerX=z,ue[0].centerY=0,ue[1].centerX=ue[0].centerX-ue[0].width/2-ue[1].width/2-ee,ue[1].y=ue[0].y,ue[2].centerX=(ue[0].centerX+ue[1].centerX)/2,ue[2].y=ue[0].y-ue[2].height-ee;else if(ue.length===4)ue[0].centerX=z,ue[0].centerY=0,ue[2].centerX=-ue[0].centerX,ue[2].centerY=ue[0].centerY,ue[1].centerX=0,ue[1].y=Math.min(ue[0].y,ue[2].y)-ue[1].height-ee,ue[3].centerX=0,ue[3].y=Math.max(ue[0].y+ue[0].height+ee,ue[2].y+ue[2].height+ee);else{z=Qe.alloc();for(var fe=0;fe<ue.length&&(ue[fe].centerX=oe,ue[fe].centerY=se,!(fe>=ue.length-1));fe++)O1(a,oe,se,ue,fe,b,z)||R1(a,oe,se,ue,fe,b,z),oe=z.x,se=z.y;if(Qe.free(z),a.mj++,!(23<a.mj)){oe=ue[0].centerX,se=ue[0].centerY,z=ue[ue.length-1].centerX,fe=ue[ue.length-1].centerY;var ve=Math.abs(oe-z)-((ue[0].width+ue[ue.length-1].width)/2+ee),ye=Math.abs(se-fe)-((ue[0].height+ue[ue.length-1].height)/2+ee);ee=0,1>Math.abs(ye)?Math.abs(oe-z)<(ue[0].width+ue[ue.length-1].width)/2&&(ee=0):ee=0<ye?ye:1>Math.abs(ve)?0:ve,oe=Math.abs(z)>Math.abs(fe)?0<z!=se>fe:0<fe!=oe<z,(oe=b===Lu?oe:!oe)&&(ee=-Math.abs(ee),ee=Math.min(ee,-ue[ue.length-1].width),ee=Math.min(ee,-ue[ue.length-1].height)),a.Xr.compare(ee,ue),1<Math.abs(ee)&&(a.lc=8>a.mj?a.lc-ee/(2*Math.PI):5>ue.length&&10<ee?a.lc/2:a.lc-(0<ee?1.7:-2.3),a.me=a.lc*re,D1(a,y,x,E,b))}}}function B1(a,y,x,E,b){for(var z=a.lc,ee=a.me,re=a.Zm,oe=z*Math.cos(E*Math.PI/180),se=ee*Math.sin(E*Math.PI/180),ue=Qe.alloc(),fe=y.Fa(),ve=0;ve<fe.length&&(fe[ve].centerX=oe,fe[ve].centerY=se,!(ve>=fe.length-1));ve++)O1(a,oe,se,fe,ve,b,ue)||R1(a,oe,se,fe,ve,b,ue),oe=ue.x,se=ue.y;if(Qe.free(ue),a.mj++,!(23<a.mj)){if(oe=Math.atan2(se,oe),oe=b===Lu?a.gt-oe:oe-a.gt,oe=Math.abs(oe)<Math.abs(oe-2*Math.PI)?oe:oe-2*Math.PI,z=oe*(z+ee)/2,ee=a.Xr,Math.abs(z)<Math.abs(ee.Pl))for(ee.Pl=z,ee.mk=[],ee.tm=[],oe=0;oe<fe.length;oe++)ee.mk[oe]=fe[oe].bounds.x,ee.tm[oe]=fe[oe].bounds.y;1<Math.abs(z)&&(a.lc=8>a.mj?a.lc-z/(2*Math.PI):a.lc-(0<z?1.7:-2.3),a.me=a.lc*re,B1(a,y,x,E,b))}}function O1(a,y,x,E,b,z,ee){var re=a.lc,oe=a.me,se=0;a=(E[b].width+E[b+1].width)/2+a.Ti;var ue=!1;if(0<=x!=(z===Lu)){if(z=y+a,z>re){if(z=y-a,z<-re)return ee.x=z,ee.y=se,!1;ue=!0}}else if(z=y-a,z<-re){if(z=y+a,z>re)return ee.x=z,ee.y=se,!1;ue=!0}return se=Math.sqrt(1-Math.min(1,z*z/(re*re)))*oe,0>x!==ue&&(se=-se),Math.abs(x-se)>(E[b].height+E[b+1].height)/2?(ee.x=z,ee.y=se,!1):(ee.x=z,ee.y=se,!0)}function R1(a,y,x,E,b,z,ee){var re=a.lc,oe=a.me,se=0;if(a=(E[b].height+E[b+1].height)/2+a.Ti,E=!1,0<=y!=(z===Lu)){if(z=x-a,z<-oe){if(z=x+a,z>oe){ee.x=se,ee.y=z;return}E=!0}}else if(z=x+a,z>oe){if(z=x-a,z<-oe){ee.x=se,ee.y=z;return}E=!0}se=Math.sqrt(1-Math.min(1,z*z/(oe*oe)))*re,0>y!==E&&(se=-se),ee.x=se,ee.y=z}fs.prototype.commitLayout=function(){this.commitNodes(),this.isRouting&&this.commitLinks()},fs.prototype.commitNodes=function(){var a=this.group!==null&&this.group.placeholder!==null&&this.group.isSubGraphExpanded,y=a?this.group.location.copy():null,x=this.actualCenter;a?x=new Qe(0,0):(x.x=this.arrangementOrigin.x+this.lc,x.y=this.arrangementOrigin.y+this.me);for(var E=this.network.vertexes.iterator;E.next();){var b=E.value;b.x+=x.x,b.y+=x.y,b.commit()}a&&(this.group.Va(),a=this.group.position.copy(),x=this.group.location.copy(),y=y.re(x.re(a)),this.group.move(y),this.Zv=y.re(a))},fs.prototype.commitLinks=function(){for(var a=this.network.edges.iterator;a.next();)a.value.commit()};function fy(a,y,x,E,b){var z=a.ty;if(.001>Math.abs(a.Zm-1))return E!==void 0&&b!==void 0?b*y:2*Math.PI*y;a=y>x?Math.sqrt(y*y-x*x)/y:Math.sqrt(x*x-y*y)/x;for(var ee=0,re=E!==void 0&&b!==void 0?b/(z+1):Math.PI/(2*(z+1)),oe=0,se=0;se<=z;se++){E!==void 0&&b!==void 0?oe=E+se*b/z:oe=se*Math.PI/(2*z);var ue=Math.sin(oe);ee+=Math.sqrt(1-a*a*ue*ue)*re}return E!==void 0&&b!==void 0?(y>x?y:x)*ee:4*(y>x?y:x)*ee}function mv(a,y,x,E,b){return y/(E!==void 0&&b!==void 0?fy(a,1,x,E,b):fy(a,1,x))}function vv(a,y,x,E,b){if(.001>Math.abs(a.Zm-1))return b/y;var z=y>x?Math.sqrt(y*y-x*x)/y:Math.sqrt(x*x-y*y)/x,ee=0;a=2*Math.PI/(700*a.network.vertexes.count),y>x&&(E+=Math.PI/2);for(var re=0;;re++){var oe=Math.sin(E+re*a);if(ee+=(y>x?y:x)*Math.sqrt(1-z*z*oe*oe)*a,ee>=b)return re*a}}fs.prototype.sort=function(a){switch(this.sorting){case yv:break;case Sv:a.reverse();break;case xv:a.sort(this.comparer);break;case wv:a.sort(this.comparer),a.reverse();break;case Ig:return this.ak(Dx(a));default:Dt("Invalid sorting type.")}return a};function Dx(a){for(var y=[],x=0;x<a.length;x++)y.push(0);x=new An;for(var E=0;E<a.length;E++){var b=-1,z=-1;if(E===0)for(var ee=0;ee<a.length;ee++){var re=a.M(ee).edgesCount;re>b&&(b=re,z=ee)}else for(ee=0;ee<a.length;ee++)re=y[ee],re>b&&(b=re,z=ee);for(x.add(a.M(z)),y[z]=-1,z=a.M(z),ee=z.sourceEdges;ee.next();)b=a.indexOf(ee.value.fromVertex),0>b||0<=y[b]&&y[b]++;for(z=z.destinationEdges;z.next();)b=a.indexOf(z.value.toVertex),0>b||0<=y[b]&&y[b]++}return x}fs.prototype.ak=function(a){for(var y=[],x=0;x<a.length;x++){var E=a.M(x);y[x]=[];for(var b,z=E.destinationEdges;z.next();)b=a.indexOf(z.value.toVertex),b!==x&&0>y[x].indexOf(b)&&y[x].push(b);for(E=E.sourceEdges;E.next();)b=a.indexOf(E.value.fromVertex),b!==x&&0>y[x].indexOf(b)&&y[x].push(b)}for(z=[],x=0;x<y.length;x++)z[x]=0;x=[];var ee=[],re=[];E=[],b=new An;for(var oe=0,se=0;se<y.length;se++){var ue=y[se].length;if(ue===1)E.push(se);else if(ue===0)b.add(a.M(se));else{if(oe===0)x.push(se);else{for(var fe=ue=1/0,ve=-1,ye=[],Ce=0;Ce<x.length;Ce++)0>y[x[Ce]].indexOf(x[Ce===x.length-1?0:Ce+1])&&ye.push(Ce===x.length-1?0:Ce+1);if(ye.length===0)for(Ce=0;Ce<x.length;Ce++)ye.push(Ce);for(Ce=0;Ce<ye.length;Ce++){for(var Ae=ye[Ce],Ye=y[se],We=0,tt=0;tt<ee.length;tt++){var rt=z[ee[tt]],at=z[re[tt]];if(rt<at){var gt=rt;rt=at}else gt=at;if(gt<Ae&&Ae<=rt)for(at=0;at<Ye.length;at++){var At=Ye[at];0>x.indexOf(At)||gt<z[At]&&z[At]<rt||gt===z[At]||rt===z[At]||We++}else for(at=0;at<Ye.length;at++)At=Ye[at],0>x.indexOf(At)||gt<z[At]&&z[At]<rt&&gt!==z[At]&&rt!==z[At]&&We++}for(Ye=We,tt=We=0;tt<y[se].length;tt++)gt=x.indexOf(y[se][tt]),0<=gt&&(gt=Math.abs(Ae-(gt>=Ae?gt+1:gt)),We+=gt<x.length+1-gt?gt:x.length+1-gt);for(tt=0;tt<ee.length;tt++)gt=z[ee[tt]],rt=z[re[tt]],gt>=Ae&&gt++,rt>=Ae&&rt++,gt>rt&&(at=rt,rt=gt,gt=at),rt-gt<(x.length+2)/2==(gt<Ae&&Ae<=rt)&&We++;(Ye<ue||Ye===ue&&We<fe)&&(ue=Ye,fe=We,ve=Ae)}for(x.splice(ve,0,se),ue=0;ue<x.length;ue++)z[x[ue]]=ue;for(ue=0;ue<y[se].length;ue++)fe=y[se][ue],0<=x.indexOf(fe)&&(ee.push(se),re.push(fe))}oe++}}for(ee=x.length;;){for(z=!0,re=0;re<E.length;re++)if(oe=E[re],se=y[oe][0],ue=x.indexOf(se),0<=ue){for(ve=fe=0;ve<y[se].length;ve++)ye=x.indexOf(y[se][ve]),0>ye||ye===ue||(Ce=ye>ue?ye-ue:ue-ye,fe+=ye<ue!=Ce>ee-Ce?1:-1);x.splice(0>fe?ue:ue+1,0,oe),E.splice(re,1),re--}else z=!1;if(z)break;x.push(E[0]),E.splice(0,1)}for(y=0;y<x.length;y++)b.add(a.M(x[y]));return b},Yt.Object.defineProperties(fs.prototype,{radius:{get:function(){return this.eo},set:function(a){this.eo!==a&&(0<a||isNaN(a))&&(this.eo=a,this.C())}},aspectRatio:{get:function(){return this.Cm},set:function(a){this.Cm!==a&&0<a&&(this.Cm=a,this.C())}},startAngle:{get:function(){return this.ro},set:function(a){this.ro!==a&&(this.ro=a,this.C())}},sweepAngle:{get:function(){return this.ul},set:function(a){this.ul!==a&&(0<a&&360>=a?this.ul=a:this.ul=360,this.C())}},arrangement:{get:function(){return this.Rb},set:function(a){this.Rb===a||a!==lc&&a!==sc&&a!==Jd&&a!==kd||(this.Rb=a,this.C())}},direction:{get:function(){return this.K},set:function(a){this.K===a||a!==Lu&&a!==Qd&&a!==bf&&a!==Rg||(this.K=a,this.C())}},sorting:{get:function(){return this.nd},set:function(a){this.nd===a||a!==yv&&a!==Sv&&a!==xv&&!wv&&a!==Ig||(this.nd=a,this.C())}},comparer:{get:function(){return this.hd},set:function(a){this.hd!==a&&(this.hd=a,this.C())}},spacing:{get:function(){return this.tf},set:function(a){this.tf!==a&&(this.tf=a,this.C())}},nodeDiameterFormula:{get:function(){return this.Nn},set:function(a){this.Nn===a||a!==Pv&&a!==Yf||(this.Nn=a,this.C())}},actualXRadius:{get:function(){return this.lc}},actualYRadius:{get:function(){return this.me}},actualSpacing:{get:function(){return this.Ti}},actualCenter:{get:function(){return this.Zv}}});var sc=new Vt(fs,"ConstantSpacing",0),Jd=new Vt(fs,"ConstantDistance",1),kd=new Vt(fs,"ConstantAngle",2),lc=new Vt(fs,"Packed",3),Lu=new Vt(fs,"Clockwise",4),Qd=new Vt(fs,"Counterclockwise",5),bf=new Vt(fs,"BidirectionalLeft",6),Rg=new Vt(fs,"BidirectionalRight",7),yv=new Vt(fs,"Forwards",8),Sv=new Vt(fs,"Reverse",9),xv=new Vt(fs,"Ascending",10),wv=new Vt(fs,"Descending",11),Ig=new Vt(fs,"Optimized",12),Pv=new Vt(fs,"Pythagorean",13),Yf=new Vt(fs,"Circular",14);fs.className="CircularLayout",fs.ConstantSpacing=sc,fs.ConstantDistance=Jd,fs.ConstantAngle=kd,fs.Packed=lc,fs.Clockwise=Lu,fs.Counterclockwise=Qd,fs.BidirectionalLeft=bf,fs.BidirectionalRight=Rg,fs.Forwards=yv,fs.Reverse=Sv,fs.Ascending=xv,fs.Descending=wv,fs.Optimized=Ig,fs.Pythagorean=Pv,fs.Circular=Yf;function Hp(){this.Pl=-1/0,this.tm=this.mk=null}Hp.prototype.compare=function(a,y){if(0<a&&0>this.Pl||Math.abs(a)<Math.abs(this.Pl)&&!(0>a&&0<this.Pl))for(this.Pl=a,this.mk=[],this.tm=[],a=0;a<y.length;a++)this.mk[a]=y[a].bounds.x,this.tm[a]=y[a].bounds.y},Hp.prototype.commit=function(a){if(this.mk!==null&&this.tm!==null)for(var y=0;y<this.mk.length;y++){var x=a.M(y);x.x=this.mk[y],x.y=this.tm[y]}},Hp.className="VertexArrangement";function jg(a){za.call(this,a)}Ct(jg,za),jg.prototype.createVertex=function(){return new Gp(this)},jg.prototype.createEdge=function(){return new Cv(this)},jg.className="CircularNetwork";function Gp(a){$s.call(this,a),this.u=this.Si=NaN}Ct(Gp,$s);function qd(a,y){var x=a.network;if(x===null)return NaN;if(x=x.layout,x===null)return NaN;if(x.arrangement===lc)if(x.nodeDiameterFormula===Yf)a.Si=Math.max(a.width,a.height);else{if(x=Math.abs(Math.sin(y)),y=Math.abs(Math.cos(y)),x===0)return a.width;if(y===0)return a.height;a.Si=Math.min(a.height/x,a.width/y)}else a.Si=x.nodeDiameterFormula===Yf?Math.max(a.width,a.height):Math.sqrt(a.width*a.width+a.height*a.height);return a.Si}Yt.Object.defineProperties(Gp.prototype,{diameter:{get:function(){return this.Si},set:function(a){this.Si!==a&&(this.Si=a)}},actualAngle:{get:function(){return this.u},set:function(a){this.u!==a&&(this.u=a)}}}),Gp.className="CircularVertex";function Cv(a){ih.call(this,a)}Ct(Cv,ih),Cv.className="CircularEdge";function jl(a){as.call(this),this.ah=null,this.An=0,this.$d=new fn(100,100).freeze(),this.Bm=!1,this.sf=!0,this.td=!1,this.dl=100,this.$m=1,this.Zf=1e3,this.In=10,this.fo=Math,this.Hk=.05,this.Gk=50,this.Ek=150,this.Fk=0,this.Vm=10,this.Um=5,a&&Object.assign(this,a)}Ct(jl,as),jl.prototype.cloneProtected=function(a){as.prototype.cloneProtected.call(this,a),a.$d.assign(this.$d),a.Bm=this.Bm,a.sf=this.sf,a.td=this.td,a.dl=this.dl,a.$m=this.$m,a.Zf=this.Zf,a.In=this.In,a.fo=this.fo,a.Hk=this.Hk,a.Gk=this.Gk,a.Ek=this.Ek,a.Fk=this.Fk,a.Vm=this.Vm,a.Um=this.Um},jl.prototype.createNetwork=function(){return new Xf(this)},jl.prototype.doLayout=function(a){if(this.network===null&&(this.network=this.makeNetwork(a)),a=this.maxIterations,0<this.network.vertexes.count){this.network.Ko();for(var y=this.network.vertexes.iterator;y.next();){var x=y.value;x.charge=this.electricalCharge(x),x.mass=this.gravitationalMass(x)}for(y=this.network.edges.iterator;y.next();)x=y.value,x.stiffness=this.springStiffness(x),x.length=this.springLength(x);if(this.Cu(),this.An=0,this.needsClusterLayout()){y=this.network,x=y.Zx();for(var E=x.iterator;E.next();){this.network=E.value;for(var b=this.network.vertexes.iterator;b.next();){var z=b.value;z.Vd=z.vertexes.count,z.sh=1,z.Hj=null,z.We=null}I1(this,0,a)}this.network=y;var ee=E=x.iterator;E=this.arrangementSpacing;var re=ee.count,oe=!0;z=b=0;for(var se=qi(),ue=0;ue<re+y.vertexes.count+2;ue++)se[ue]=null;re=0,ee.reset();for(var fe=Xt.alloc();ee.next();)if(ue=ee.value,this.computeBounds(ue,fe),oe)oe=!1,b=fe.x+fe.width/2,z=fe.y+fe.height/2,se[0]=new Qe(fe.x+fe.width+E.width,fe.y),se[1]=new Qe(fe.x,fe.y+fe.height+E.height),re=2;else{var ve=j1(se,re,b,z,fe.width,fe.height,E),ye=se[ve],Ce=new Qe(ye.x+fe.width+E.width,ye.y),Ae=new Qe(ye.x,ye.y+fe.height+E.height);for(ve+1<re&&se.splice(ve+1,0,null),se[ve]=Ce,se[ve+1]=Ae,re++,ve=ye.x-fe.x,ye=ye.y-fe.y,ue=ue.vertexes.iterator;ue.next();)Ce=ue.value,Ce.centerX+=ve,Ce.centerY+=ye}for(Xt.free(fe),ue=y.vertexes.iterator;ue.next();)ee=ue.value,ve=ee.bounds,2>re?(b=ve.x+ve.width/2,z=ve.y+ve.height/2,se[0]=new Qe(ve.x+ve.width+E.width,ve.y),se[1]=new Qe(ve.x,ve.y+ve.height+E.height),re=2):(oe=j1(se,re,b,z,ve.width,ve.height,E),fe=se[oe],ye=new Qe(fe.x+ve.width+E.width,fe.y),ve=new Qe(fe.x,fe.y+ve.height+E.height),oe+1<re&&se.splice(oe+1,0,null),se[oe]=ye,se[oe+1]=ve,re++,ee.centerX=fe.x+ee.width/2,ee.centerY=fe.y+ee.height/2);for(Zi(se),E=x.iterator;E.next();){for(x=E.value,b=x.vertexes.iterator;b.next();)y.dh(b.value);for(x=x.edges.iterator;x.next();)y.Bo(x.value)}}H1(this,a),this.updateParts()}this.dl=a,this.network=null,this.isValidLayout=!0},jl.prototype.needsClusterLayout=function(){if(3>this.network.vertexes.count)return!1;for(var a=0,y=0,x=this.network.vertexes.first().bounds,E=this.network.vertexes.iterator;E.next();){if(E.value.bounds.Yc(x)&&(a++,2<a))return!0;if(10<y)break;y++}return!1},jl.prototype.computeBounds=function(a,y){var x=!0;for(a=a.vertexes.iterator;a.next();){var E=a.value;x?(x=!1,y.set(E.bounds)):y.ed(E.bounds)}return y};function I1(a,y,x){if(Bx(a,y)){var E=a.Zf;a.Zf*=1+1/(y+1);var b=Ox(a,y),z=Math.max(0,Math.max(Math.min(a.network.vertexes.count,x*(y+1)/11),10));for(a.maxIterations+=z,I1(a,y+1,x),H1(a,z),Rx(a,b),y=b.vertexes.Fa(),y.sort(function(ee,re){return ee===null||re===null||ee===re?0:re.Vd-ee.Vd}),x=0;x<y.length;x++)Ix(a,y[x]);a.Zf=E}}function Bx(a,y){if(10<y||3>a.network.vertexes.count)return!1;for(a.ah=a.network.vertexes.Fa(),a=a.ah,a.sort(function(x,E){return x===null||E===null||x===E?0:E.Vd-x.Vd}),y=a.length-1;0<=y&&1>=a[y].Vd;)y--;return 1<a.length-y}function Ox(a,y){for(var x=a.network,E=new Xf(a),b=0;b<a.ah.length;b++){var z=a.ah[b];if(1<z.Vd){E.dh(z);var ee=new G1;ee.Rs=z.Vd,ee.Ss=z.width,ee.Qs=z.height,ee.Sv=z.focus.x,ee.Tv=z.focus.y,z.We===null&&(z.We=new An),z.We.add(ee),z.sv=z.We.count-1}else break}for(z=x.edges.iterator;z.next();){var re=z.value;b=re.fromVertex,ee=re.toVertex,b.network===E&&ee.network===E?E.Bo(re):b.network===E?(re=b.Hj,re===null&&(re=new An,b.Hj=re),re.add(ee),b.Vd--,b.sh+=ee.sh):ee.network===E&&(re=ee.Hj,re===null&&(re=new An,ee.Hj=re),re.add(b),ee.Vd--,ee.sh+=b.sh)}for(b=E.edges.iterator;b.next();)z=b.value,z.length*=Math.max(1,yt.sqrt((z.fromVertex.sh+z.toVertex.sh)/(4*y+1)));for(y=E.vertexes.iterator;y.next();){b=y.value;var oe=b.Hj;if(oe!==null&&0<oe.count&&(ee=b.We.M(b.We.count-1).Rs-b.Vd,!(0>=ee))){for(var se=re=0,ue=oe.count-ee;ue<oe.count;ue++){var fe=oe.M(ue),ve=null;for(z=fe.edges.iterator;z.next();){var ye=z.value;if(ye.Ax(fe)===b){ve=ye;break}}ve!==null&&(se+=ve.length,re+=fe.width*fe.height)}z=b.centerX,oe=b.centerY,ue=b.width,fe=b.height,ve=b.focus,ye=ue*fe,1>ye&&(ye=1),re=yt.sqrt((re+ye+se*se*4/(ee*ee))/ye),ee=(re-1)*ue/2,re=(re-1)*fe/2,b.bounds=new Xt(z-ve.x-ee,oe-ve.y-re,ue+2*ee,fe+2*re),b.focus=new Qe(ve.x+ee,ve.y+re)}}return a.network=E,x}function Rx(a,y){for(var x=a.network.vertexes.iterator;x.next();){var E=x.value;if(E.network=y,E.We!==null){var b=E.We.M(E.sv);E.Vd=b.Rs;var z=b.Sv,ee=b.Tv;E.bounds=new Xt(E.centerX-z,E.centerY-ee,b.Ss,b.Qs),E.focus=new Qe(z,ee),E.sv--}}for(x=a.network.edges.iterator;x.next();)x.value.network=y;a.network=y}function Ix(a,y){var x=y.Hj;if(x!==null&&x.count!==0){var E=y.centerX,b=y.centerY,z=y.width,ee=y.height;y.We!==null&&0<y.We.count&&(ee=y.We.M(0),z=ee.Ss,ee=ee.Qs),z=yt.sqrt(z*z+ee*ee)/2;for(var re=!1,oe=ee=0,se=0,ue=y.vertexes.iterator;ue.next();){var fe=ue.value;1>=fe.Vd?oe++:(re=!0,se++,ee+=Math.atan2(y.centerY-fe.centerY,y.centerX-fe.centerX))}if(oe!==0){for(0<se&&(ee/=se),se=y=0,y=re?2*Math.PI/(oe+1):2*Math.PI/oe,oe%2===0&&(se=y/2),1<x.count&&x.sort(function(ye,Ce){return ye===null||Ce===null||ye===Ce?0:Ce.width*Ce.height-ye.width*ye.height}),re=oe%2===0?0:1,x=x.iterator;x.next();)if(oe=x.value,!(1<oe.Vd||a.isFixed(oe))){for(ue=null,fe=oe.edges.iterator;fe.next();){ue=fe.value;break}fe=oe.width;var ve=oe.height;fe=yt.sqrt(fe*fe+ve*ve)/2,ue=z+ue.length+fe,fe=ee+(y*(re/2>>1)+se)*(re%2===0?1:-1),oe.centerX=E+ue*Math.cos(fe),oe.centerY=b+ue*Math.sin(fe),re++}}}}function j1(a,y,x,E,b,z,ee){var re=9e19,oe=-1,se=0;e:for(;se<y;se++){var ue=a[se],fe=ue.x-x,ve=ue.y-E;if(fe=fe*fe+ve*ve,fe<re){for(ve=se-1;0<=ve;ve--)if(a[ve].y>ue.y&&a[ve].x-ue.x<b+ee.width)continue e;for(ve=se+1;ve<y;ve++)if(a[ve].x>ue.x&&a[ve].y-ue.y<z+ee.height)continue e;oe=se,re=fe}}return oe}jl.prototype.Cu=function(){if(this.comments)for(var a=this.network.vertexes.iterator;a.next();)this.addComments(a.value)},jl.prototype.addComments=function(a){var y=a.node;if(y!==null)for(y=y.Mu();y.next();){var x=y.value;if(x.category==="Comment"&&x.isVisible()){var E=this.network.ki(x);E===null&&(E=this.network.Bl(x)),E.charge=this.defaultCommentElectricalCharge,x=null;for(var b=E.destinationEdges;b.next();){var z=b.value;if(z.toVertex===a){x=z;break}}if(x===null){for(b=E.sourceEdges;b.next();)if(z=b.value,z.fromVertex===a){x=z;break}}x===null&&(x=this.network.Zj(a,E,null)),x.length=this.defaultCommentSpringLength}}};function z1(a,y){var x=a.bounds,E=x.x;a=x.y;var b=x.width;x=x.height;var z=y.bounds,ee=z.x;y=z.y;var re=z.width;return z=z.height,E+b<ee?a>y+z?(x=E+b-ee,a=a-y-z,yt.sqrt(x*x+a*a)):a+x<y?(E=E+b-ee,a=a+x-y,yt.sqrt(E*E+a*a)):ee-(E+b):E>ee+re?a>y+z?(x=E-ee-re,a=a-y-z,yt.sqrt(x*x+a*a)):a+x<y?(E=E-ee-re,a=a+x-y,yt.sqrt(E*E+a*a)):E-(ee+re):a>y+z?a-(y+z):a+x<y?y-(a+x):.1}function H1(a,y){for(a.ah=null,y=a.An+y;a.An<y&&(a.An++,jx(a)););a.ah=null}function jx(a){a.ah===null&&(a.ah=a.network.vertexes.Fa());var y=a.ah;if(0>=y.length)return!1;var x=y[0];x.forceX=0,x.forceY=0;for(var E=x.centerX,b=E,z=x=x.centerY,ee=1;ee<y.length;ee++){var re=y[ee];re.forceX=0,re.forceY=0;var oe=re.centerX;re=re.centerY,E=Math.min(E,oe),b=Math.max(b,oe),x=Math.min(x,re),z=Math.max(z,re)}(b=b-E>z-x)?y.sort(function(Ae,Ye){return Ae===null||Ye===null||Ae===Ye?0:Ae.centerX-Ye.centerX}):y.sort(function(Ae,Ye){return Ae===null||Ye===null||Ae===Ye?0:Ae.centerY-Ye.centerY}),x=a.Zf;var se=E=re=0;for(z=0;z<y.length;z++){ee=y[z],E=ee.bounds,re=ee.focus,oe=E.x+re.x;var ue=E.y+re.y;E=ee.charge*a.electricalFieldX(oe,ue),se=ee.charge*a.electricalFieldY(oe,ue),E+=ee.mass*a.gravitationalFieldX(oe,ue),se+=ee.mass*a.gravitationalFieldY(oe,ue),ee.forceX+=E,ee.forceY+=se;for(var fe=z+1;fe<y.length;fe++){var ve=y[fe];if(ve!==ee){E=ve.bounds,re=ve.focus,se=E.x+re.x;var ye=E.y+re.y;if(oe-se>x||se-oe>x){if(b)break}else if(ue-ye>x||ye-ue>x){if(!b)break}else{var Ce=z1(ee,ve);1>Ce?(E=a.randomNumberGenerator,E===null&&(a.randomNumberGenerator=E=new Ev),Ce=E.random(),re=E.random(),oe>se?(E=Math.abs(ve.bounds.right-ee.bounds.x),E=(1+E)*Ce):oe<se?(E=Math.abs(ve.bounds.x-ee.bounds.right),E=-(1+E)*Ce):(E=Math.max(ve.width,ee.width),E=(1+E)*Ce-E/2),ue>ye?(se=Math.abs(ve.bounds.bottom-ee.bounds.y),se=(1+se)*re):oe<se?(se=Math.abs(ve.bounds.y-ee.bounds.bottom),se=-(1+se)*re):(se=Math.max(ve.height,ee.height),se=(1+se)*re-se/2)):(re=-(ee.charge*ve.charge)/(Ce*Ce),E=(se-oe)/Ce*re,se=(ye-ue)/Ce*re),ee.forceX+=E,ee.forceY+=se,ve.forceX-=E,ve.forceY-=se}}}}for(b=a.network.edges.iterator;b.next();)re=b.value,x=re.fromVertex,z=re.toVertex,ee=x.bounds,oe=x.focus,E=ee.x+oe.x,ee=ee.y+oe.y,ue=z.bounds,fe=z.focus,oe=ue.x+fe.x,ue=ue.y+fe.y,fe=z1(x,z),1>fe?(fe=a.randomNumberGenerator,fe===null&&(a.randomNumberGenerator=fe=new Ev),re=fe.random(),fe=fe.random(),E=(E>oe?1:-1)*(1+(z.width>x.width?z.width:x.width))*re,se=(ee>ue?1:-1)*(1+(z.height>x.height?z.height:x.height))*fe):(re=re.stiffness*(fe-re.length),E=(oe-E)/fe*re,se=(ue-ee)/fe*re),x.forceX+=E,x.forceY+=se,z.forceX-=E,z.forceY-=se;for(b=E=0;b<y.length;b++)x=y[b],a.isFixed(x)?a.moveFixedVertex(x):E=Math.max(E,a.moveVertex(x)||0);return E>a.epsilonDistance*a.epsilonDistance}jl.prototype.moveVertex=function(a){var y=a.forceX,x=a.forceY,E=this.moveLimit;return y<-E?y=-E:y>E&&(y=E),x<-E?x=-E:x>E&&(x=E),a.centerX+=y,a.centerY+=x,y*y+x*x},jl.prototype.moveFixedVertex=function(){},jl.prototype.commitLayout=function(){this.yv(),this.commitNodes(),this.isRouting&&this.commitLinks()},jl.prototype.yv=function(){if(this.setsPortSpots)for(var a=this.network.edges.iterator;a.next();){var y=a.value.link;y!==null&&(y.fromSpot=vs,y.toSpot=vs)}},jl.prototype.commitNodes=function(){var a=0,y=0;if(this.arrangesToOrigin){var x=Xt.alloc();this.computeBounds(this.network,x),y=this.arrangementOrigin,a=y.x-x.x,y=y.y-x.y,Xt.free(x)}x=Xt.alloc();for(var E=this.network.vertexes.iterator;E.next();){var b=E.value;(a!==0||y!==0)&&(x.assign(b.bounds),x.x+=a,x.y+=y,b.bounds=x),b.commit()}Xt.free(x)},jl.prototype.commitLinks=function(){for(var a=this.network.edges.iterator;a.next();)a.value.commit()},jl.prototype.springStiffness=function(a){return a=a.stiffness,isNaN(a)?this.Hk:a},jl.prototype.springLength=function(a){return a=a.length,isNaN(a)?this.Gk:a},jl.prototype.electricalCharge=function(a){return a=a.charge,isNaN(a)?this.Ek:a},jl.prototype.electricalFieldX=function(){return 0},jl.prototype.electricalFieldY=function(){return 0},jl.prototype.gravitationalMass=function(a){return a=a.mass,isNaN(a)?this.Fk:a},jl.prototype.gravitationalFieldX=function(){return 0},jl.prototype.gravitationalFieldY=function(){return 0},jl.prototype.isFixed=function(a){return a.isFixed},Yt.Object.defineProperties(jl.prototype,{currentIteration:{get:function(){return this.An}},arrangementSpacing:{get:function(){return this.$d},set:function(a){this.$d.D(a)||(this.$d.assign(a),this.C())}},arrangesToOrigin:{get:function(){return this.Bm},set:function(a){this.Bm!==a&&(this.Bm=a,this.C())}},setsPortSpots:{get:function(){return this.sf},set:function(a){this.sf!==a&&(this.sf=a,this.C())}},comments:{get:function(){return this.td},set:function(a){this.td!==a&&(this.td=a,this.C())}},maxIterations:{get:function(){return this.dl},set:function(a){this.dl!==a&&0<=a&&(this.dl=a,this.C())}},epsilonDistance:{get:function(){return this.$m},set:function(a){this.$m!==a&&0<a&&(this.$m=a,this.C())}},infinityDistance:{get:function(){return this.Zf},set:function(a){this.Zf!==a&&1<a&&(this.Zf=a,this.C())}},moveLimit:{get:function(){return this.In},set:function(a){this.In!==a&&1<a&&(this.In=a,this.C())}},randomNumberGenerator:{get:function(){return this.fo},set:function(a){this.fo!==a&&(a!==null&&typeof a.random!="function"&&Dt('ForceDirectedLayout.randomNumberGenerator must have a "random()" function on it: '+a),this.fo=a)}},defaultSpringStiffness:{get:function(){return this.Hk},set:function(a){this.Hk!==a&&(this.Hk=a,this.C())}},defaultSpringLength:{get:function(){return this.Gk},set:function(a){this.Gk!==a&&(this.Gk=a,this.C())}},defaultElectricalCharge:{get:function(){return this.Ek},set:function(a){this.Ek!==a&&(this.Ek=a,this.C())}},defaultGravitationalMass:{get:function(){return this.Fk},set:function(a){this.Fk!==a&&(this.Fk=a,this.C())}},defaultCommentSpringLength:{get:function(){return this.Vm},set:function(a){this.Vm!==a&&(this.Vm=a,this.C())}},defaultCommentElectricalCharge:{get:function(){return this.Um},set:function(a){this.Um!==a&&(this.Um=a,this.C())}}}),jl.className="ForceDirectedLayout";function G1(){this.Tv=this.Sv=this.Qs=this.Ss=this.Rs=0}G1.className="ForceDirectedSubnet";function Xf(a){za.call(this,a)}Ct(Xf,za),Xf.prototype.createVertex=function(){return new Kp(this)},Xf.prototype.createEdge=function(){return new Wp(this)},Xf.className="ForceDirectedNetwork";function Kp(a){$s.call(this,a),this.ia=!1,this.Ha=this.u=NaN,this.sh=this.Vd=this.V=this.F=0,this.We=this.Hj=null,this.sv=0}Ct(Kp,$s),Yt.Object.defineProperties(Kp.prototype,{isFixed:{get:function(){return this.ia},set:function(a){this.ia!==a&&(this.ia=a)}},charge:{get:function(){return this.u},set:function(a){this.u!==a&&(this.u=a)}},mass:{get:function(){return this.Ha},set:function(a){this.Ha!==a&&(this.Ha=a)}},forceX:{get:function(){return this.F},set:function(a){this.F!==a&&(this.F=a)}},forceY:{get:function(){return this.V},set:function(a){this.V!==a&&(this.V=a)}}}),Kp.className="ForceDirectedVertex";function Wp(a){ih.call(this,a),this.j=this.o=NaN}Ct(Wp,ih),Yt.Object.defineProperties(Wp.prototype,{stiffness:{get:function(){return this.o},set:function(a){this.o!==a&&(this.o=a)}},length:{get:function(){return this.j},set:function(a){this.j!==a&&(this.j=a)}}}),Wp.className="ForceDirectedEdge";function Ev(){var a=0;a===void 0&&(a=42),this.seed=a,this.ay=48271,this.ey=2147483647,this.Q=44488.07041494893,this.gy=3399,this.by=1/2147483647,this.random()}Ev.prototype.random=function(){var a=this.seed%this.Q*this.ay-this.seed/this.Q*this.gy;return 0<a?this.seed=a:this.seed=a+this.ey,this.seed*this.by},Ev.className="RandomNumberGenerator";function aa(a){as.call(this),this.kc=this.ie=25,this.K=0,this.Dk=Fv,this.Zk=Av,this.Qk=Nv,this.bj=4,this.rk=Tv,this.bg=15,this.sf=!0,this.Cn=4,this.Ra=this.Iq=this.Ia=-1,this.Md=this.Hn=0,this.Ta=this.Kd=this.Ld=this.he=this.tc=null,this.Kn=0,this.Jn=this.kj=null,this.le=0,this.fl=null,this.Rf=new Qe,this.He=[],this.He.length=100,this.xw=this.ve=0,a&&Object.assign(this,a)}Ct(aa,as),aa.prototype.cloneProtected=function(a){as.prototype.cloneProtected.call(this,a),a.ie=this.ie,a.kc=this.kc,a.K=this.K,a.Dk=this.Dk,a.Zk=this.Zk,a.Qk=this.Qk,a.bj=this.bj,a.rk=this.rk,a.bg=this.bg,a.sf=this.sf,a.Cn=this.Cn,a.ve=this.ve},aa.prototype.qb=function(a){a.classType===aa?a.name.indexOf("Aggressive")===0?this.aggressiveOption=a:a.name.indexOf("Cycle")===0?this.cycleRemoveOption=a:a.name.indexOf("Init")===0?this.initializeOption=a:a.name.indexOf("Layer")===0?this.layeringOption=a:Dt("Unknown enum value: "+a):as.prototype.qb.call(this,a)},aa.prototype.createNetwork=function(){return new Hg(this)},aa.prototype.doLayout=function(a){for(this.network===null&&(this.network=this.makeNetwork(a)),this.arrangementOrigin=this.initialOrigin(this.arrangementOrigin),this.Iq=-1,this.Md=this.Hn=0,this.fl=this.Jn=this.kj=null,a=0;a<this.He.length;a++)this.He[a]=null;if(0<this.network.vertexes.count){for(this.network.Ko(),this.cycleRemoveOption!==Up&&this.removeCycles(),a=this.network.vertexes.iterator;a.next();)a.value.layer=-1;for(this.Ia=-1,this.assignLayers(),a.reset();a.next();)this.Ia=Math.max(this.Ia,a.value.layer);this.cycleRemoveOption===Up&&this.removeCycles(),a=this.network;for(var y=[],x=a.edges.iterator;x.next();){var E=x.value;E.valid=!1,y.push(E)}for(x=0;x<y.length;x++){E=y[x];var b=E.fromVertex,z=E.toVertex;if(!(E.valid||(b.node===null&&b.data===null||z.node===null&&z.data===null)&&b.layer===z.layer)){var ee=0,re=0,oe=0,se=0;if(E.link!==null){if(re=E.link,re===null)continue;var ue=b.node;if(ee=z.node,ue===null||ee===null)continue;var fe=re.fromNode;oe=re.toNode;for(var ve=re.fromPort;ve!==null&&!ve.Ed();)ve=ve.panel;for(re=re.toPort;re!==null&&!re.Ed();)re=re.panel;if(E.rev){se=fe;var ye=ve;fe=oe,ve=re,oe=se,re=ye}var Ce=b.focus;se=z.focus;var Ae=E.rev?z.bounds:b.bounds;ye=Qe.alloc(),ue!==fe?Ae.w()&&fe.isVisible()?fe.actualBounds.w()?(Cd(fe,ve,ko,ye),ye.x+=fe.actualBounds.x-Ae.x,ye.y+=fe.actualBounds.y-Ae.y):(Cd(fe,ve,ko,ye),ye.w()||ye.assign(Ce)):ye.assign(Ce):Ae.w()?(Cd(fe,ve,ko,ye),ye.w()||ye.assign(Ce)):ye.assign(Ce),fe=E.rev?b.bounds:z.bounds,ue=Qe.alloc(),ee!==oe?fe.w()&&oe.isVisible()?oe.actualBounds.w()?(Cd(oe,re,ko,ue),ue.x+=oe.actualBounds.x-fe.x,ue.y+=oe.actualBounds.y-fe.y):(Cd(oe,re,ko,ue),ue.w()||ue.assign(se)):ue.assign(se):fe.w()?(Cd(oe,re,ko,ue),ue.w()||ue.assign(se)):ue.assign(se),this.K===90||this.K===270?(ee=Math.round((ye.x-Ce.x)/this.kc),oe=ye.x,re=Math.round((ue.x-se.x)/this.kc),se=ue.x):(ee=Math.round((ye.y-Ce.y)/this.kc),oe=ye.y,re=Math.round((ue.y-se.y)/this.kc),se=ue.y),Qe.free(ye),Qe.free(ue),E.portFromColOffset=ee,E.portFromPos=oe,E.portToColOffset=re,E.portToPos=se}else E.portFromColOffset=0,E.portFromPos=0,E.portToColOffset=0,E.portToPos=0;if(ye=b.layer,ue=z.layer,fe=0,Ae=E.link,Ae!==null){var Ye=Ae.fromPort,We=Ae.toPort;if(Ye!==null&&We!==null){var tt=Ae.fromNode;if(ve=Ae.toNode,tt!==null&&ve!==null){var rt=kv(this,!0),at=kv(this,!1),gt=this.setsPortSpots?rt:Ae.computeSpot(!0,Ye);Ce=this.setsPortSpots?at:Ae.computeSpot(!1,We);var At=Ae.isOrthogonal;gt.$c()&&gt.Hf(at)&&Ce.$c()&&Ce.Hf(rt)?fe=0:(rt=Ae.getLinkPoint(tt,Ye,gt,!0,At,ve,We,Qe.alloc()),at=Ae.getLinkDirection(tt,Ye,rt,gt,!0,At,ve,We),Qe.free(rt),gt.ys()||at!==J1(this,E,!0)?this.setsPortSpots&&tt!==null&&tt.ports.count===1&&E.rev&&(fe+=1):fe+=1,gt=Ae.getLinkPoint(ve,We,Ce,!1,At,tt,Ye,Qe.alloc()),Ae=Ae.getLinkDirection(ve,We,gt,Ce,!1,At,tt,Ye),Qe.free(gt),Ce.ys()||Ae!==J1(this,E,!1)?this.setsPortSpots&&ve!==null&&ve.ports.count===1&&E.rev&&(fe+=2):fe+=2)}}}if(ve=fe,fe=ve===1||ve===3,(ve=ve===2||ve===3)&&(Ce=a.createVertex(),Ce.node=null,Ce.Dj=1,Ce.layer=ye,Ce.near=b,a.dh(Ce),b=a.Zj(b,Ce,E.link),b.valid=!1,b.rev=E.rev,b.portFromColOffset=ee,b.portToColOffset=0,b.portFromPos=oe,b.portToPos=0,b=Ce),Ae=1,fe&&Ae--,ye-ue>Ae&&0<ye){for(E.valid=!1,Ce=a.createVertex(),Ce.node=null,Ce.Dj=2,Ce.layer=ye-1,a.dh(Ce),b=a.Zj(b,Ce,E.link),b.valid=!0,b.rev=E.rev,b.portFromColOffset=ve?0:ee,b.portToColOffset=0,b.portFromPos=ve?0:oe,b.portToPos=0,b=Ce,ye--;ye-ue>Ae&&0<ye;)Ce=a.createVertex(),Ce.node=null,Ce.Dj=3,Ce.layer=ye-1,a.dh(Ce),b=a.Zj(b,Ce,E.link),b.valid=!0,b.rev=E.rev,b.portFromColOffset=0,b.portToColOffset=0,b.portFromPos=0,b.portToPos=0,b=Ce,ye--;b=a.Zj(Ce,z,E.link),b.valid=!fe,fe&&(Ce.near=z),b.rev=E.rev,b.portFromColOffset=0,b.portToColOffset=re,b.portFromPos=0,b.portToPos=se}else E.valid=!0}}for(a=this.tc=[],y=0;y<=this.Ia;y++)a[y]=0;for(y=this.network.vertexes.iterator;y.next();)y.value.index=-1;for(this.initializeIndices(),this.Iq=-1,x=this.Md=this.Hn=0;x<=this.Ia;x++)a[x]>a[this.Md]&&(this.Iq=a[x]-1,this.Md=x),a[x]<a[this.Hn]&&(this.Hn=x);for(this.fl=[],x=0;x<a.length;x++)this.fl[x]=[];for(y.reset();y.next();)a=y.value,this.fl[a.layer][a.index]=a;for(this.Ra=-1,a=0;a<=this.Ia;a++){for(y=$d(this,a),x=0,E=this.tc[a],z=0;z<E;z++)b=y[z],x+=this.nodeMinColumnSpace(b,!0),b.column=x,x+=1,x+=this.nodeMinColumnSpace(b,!1);this.Ra=Math.max(this.Ra,x-1),ef(this,a,y)}this.reduceCrossings(),this.straightenAndPack(),this.updateParts()}this.network=null,this.isValidLayout=!0},aa.prototype.linkMinLength=function(){return 1};function gy(a){var y=a.fromVertex.node||a.fromVertex.data;return a=a.toVertex.node||a.toVertex.data,y===null&&a===null?8:y===null||a===null?4:1}aa.prototype.nodeMinLayerSpace=function(a,y){return a.node===null&&a.data===null?0:this.K===90||this.K===270?y?a.focus.y+10:a.bounds.height-a.focus.y+10:y?a.focus.x+10:a.bounds.width-a.focus.x+10},aa.prototype.nodeMinColumnSpace=function(a,y){if(a.node===null&&a.data===null)return 0;var x=y?a.ev:a.dv;return x!==null?x:(x=this.K,x===90||x===270?y?a.ev=a.focus.x/this.kc+1|0:a.dv=(a.bounds.width-a.focus.x)/this.kc+1|0:y?a.ev=a.focus.y/this.kc+1|0:a.dv=(a.bounds.height-a.focus.y)/this.kc+1|0)};function zu(a){a.kj===null&&(a.kj=[]);for(var y=0,x=a.network.vertexes.iterator;x.next();){var E=x.value;a.kj[y]=E.layer,y++,a.kj[y]=E.column,y++,a.kj[y]=E.index,y++}return a.kj}function Rh(a,y){var x=0;for(a=a.network.vertexes.iterator;a.next();){var E=a.value;E.layer=y[x],x++,E.column=y[x],x++,E.index=y[x],x++}}function K1(a,y,x){var E=$d(a,y),b=a.tc[y];(a.Jn===null||a.Jn.length<b*b)&&(a.Jn=[]);for(var z=a.Jn,ee=0;ee<b;ee++){var re=0,oe=E[ee],se=oe.near;if(se!==null&&se.layer===oe.layer)if(oe=se.index,oe>ee)for(var ue=ee+1;ue<oe;ue++){var fe=E[ue];fe.near===se&&fe.Dj===se.Dj||re++}else for(ue=ee-1;ue>oe;ue--)fe=E[ue],fe.near===se&&fe.Dj===se.Dj||re++;var ve;if(0<=x)for(oe=E[ee].sourceEdgesArrayAccess,se=0;se<oe.length;se++){var ye=oe[se];if(ye.valid&&ye.fromVertex.layer!==y)for(fe=ye.fromVertex.index,ue=ye.portToPos,ye=ye.portFromPos,ve=se+1;ve<oe.length;ve++){var Ce=oe[ve];if(Ce.valid&&Ce.fromVertex.layer!==y){var Ae=Ce.fromVertex.index,Ye=Ce.portToPos;Ce=Ce.portFromPos,ue<Ye&&(fe>Ae||fe===Ae&&ye>Ce)&&re++,Ye<ue&&(Ae>fe||Ae===fe&&Ce>ye)&&re++}}}if(0>=x){for(oe=E[ee].destinationEdgesArrayAccess,se=0;se<oe.length;se++)if(ye=oe[se],ye.valid&&ye.toVertex.layer!==y)for(fe=ye.toVertex.index,ue=ye.portToPos,ye=ye.portFromPos,ve=se+1;ve<oe.length;ve++)Ce=oe[ve],Ce.valid&&Ce.toVertex.layer!==y&&(Ae=Ce.toVertex.index,Ye=Ce.portToPos,Ce=Ce.portFromPos,ye<Ce&&(fe>Ae||fe===Ae&&ue>Ye)&&re++,Ce<ye&&(Ae>fe||Ae===fe&&Ye>ue)&&re++)}for(z[ee*b+ee]=re,oe=ee+1;oe<b;oe++){var We=0,tt=0;if(0<=x){re=E[ee].sourceEdgesArrayAccess;var rt=E[oe].sourceEdgesArrayAccess;for(se=0;se<re.length;se++)if(ye=re[se],ye.valid&&ye.fromVertex.layer!==y)for(fe=ye.fromVertex.index,ye=ye.portFromPos,ve=0;ve<rt.length;ve++)Ce=rt[ve],Ce.valid&&Ce.fromVertex.layer!==y&&(Ae=Ce.fromVertex.index,Ce=Ce.portFromPos,(fe<Ae||fe===Ae&&ye<Ce)&&tt++,(Ae<fe||Ae===fe&&Ce<ye)&&We++)}if(0>=x){for(re=E[ee].destinationEdgesArrayAccess,rt=E[oe].destinationEdgesArrayAccess,se=0;se<re.length;se++)if(ye=re[se],ye.valid&&ye.toVertex.layer!==y)for(fe=ye.toVertex.index,ue=ye.portToPos,ve=0;ve<rt.length;ve++)Ce=rt[ve],Ce.valid&&Ce.toVertex.layer!==y&&(Ae=Ce.toVertex.index,Ye=Ce.portToPos,(fe<Ae||fe===Ae&&ue<Ye)&&tt++,(Ae<fe||Ae===fe&&Ye<ue)&&We++)}z[ee*b+oe]=We,z[oe*b+ee]=tt}}return ef(a,y,E),z}aa.prototype.countCrossings=function(){for(var a=0,y=0;y<=this.Ia;y++)for(var x=K1(this,y,1),E=this.tc[y],b=0;b<E;b++)for(var z=b;z<E;z++)a+=x[b*E+z];return a};function bv(a){for(var y=0,x=0;x<=a.Ia;x++){for(var E=a,b=x,z=$d(E,b),ee=E.tc[b],re=0,oe=0;oe<ee;oe++){var se=z[oe].destinationEdgesArrayAccess;if(se!==null)for(var ue=0;ue<se.length;ue++){var fe=se[ue];if(fe.valid&&fe.toVertex.layer!==b){var ve=fe.fromVertex.column+fe.portFromColOffset,ye=fe.toVertex.column+fe.portToColOffset;re+=(Math.abs(ve-ye)+1)*gy(fe)}}}ef(E,b,z),y+=re}return y}aa.prototype.normalize=function(){var a=1/0;this.Ra=-1;for(var y=this.network.vertexes.iterator;y.next();){var x=y.value;a=Math.min(a,x.column-this.nodeMinColumnSpace(x,!0)),this.Ra=Math.max(this.Ra,x.column+this.nodeMinColumnSpace(x,!1))}for(y.reset();y.next();)y.value.column-=a;this.Ra-=a};function py(a,y,x){for(var E=$d(a,y),b=a.tc[y],z=[],ee=0;ee<b;ee++){var re=E[ee],oe=null;0>=x&&(oe=re.sourceEdgesArrayAccess);var se=null;0<=x&&(se=re.destinationEdgesArrayAccess);var ue=0,fe=0,ve=re.near;if(ve!==null&&ve.layer===re.layer&&(ue+=ve.column-1,fe++),oe!==null)for(ve=0;ve<oe.length;ve++){re=oe[ve];var ye=re.fromVertex;re.valid&&!re.rev&&ye.layer!==y&&(ue+=ye.column,fe++)}if(se!==null)for(oe=0;oe<se.length;oe++)re=se[oe],ve=re.toVertex,re.valid&&!re.rev&&ve.layer!==y&&(ue+=ve.column,fe++);z[ee]=fe===0?-1:ue/fe}return ef(a,y,E),z}function W1(a,y,x){for(var E=$d(a,y),b=a.tc[y],z=[],ee=0;ee<b;ee++){var re=E[ee],oe=null;0>=x&&(oe=re.sourceEdgesArrayAccess);var se=null;0<=x&&(se=re.destinationEdgesArrayAccess);var ue=0,fe=[],ve=re.near;if(ve!==null&&ve.layer===re.layer&&(fe[ue]=ve.column-1,ue++),re=void 0,oe!==null)for(ve=0;ve<oe.length;ve++){re=oe[ve];var ye=re.fromVertex;re.valid&&!re.rev&&ye.layer!==y&&(fe[ue]=ye.column+re.portFromColOffset,ue++)}if(se!==null)for(oe=0;oe<se.length;oe++)re=se[oe],ve=re.toVertex,re.valid&&!re.rev&&ve.layer!==y&&(fe[ue]=ve.column+re.portToColOffset,ue++);ue===0?z[ee]=-1:(fe.sort(function(Ce,Ae){return Ce-Ae}),se=ue>>1,z[ee]=ue&1?fe[se]:fe[se-1]+fe[se]>>1)}return ef(a,y,E),z}function Vp(a,y,x,E,b,z){if(y.component===E){if(y.component=x,b)for(var ee=y.destinationEdges;ee.next();){var re=ee.value,oe=re.toVertex,se=y.layer-oe.layer;re=a.linkMinLength(re),se===re&&Vp(a,oe,x,E,b,z)}if(z)for(ee=y.sourceEdges;ee.next();)re=ee.value,oe=re.fromVertex,se=oe.layer-y.layer,re=a.linkMinLength(re),se===re&&Vp(a,oe,x,E,b,z)}}function my(a,y,x,E,b,z){if(y.component===E){if(y.component=x,b)for(var ee=y.destinationEdges;ee.next();)my(a,ee.value.toVertex,x,E,b,z);if(z)for(y=y.sourceEdges;y.next();)my(a,y.value.fromVertex,x,E,b,z)}}aa.prototype.removeCycles=function(){for(var a=this.network.edges.iterator;a.next();)a.value.rev=!1;switch(this.Dk){default:case Sy:a=this.network;var y=0,x=a.vertexes.count-1,E=[];E.length=x+1;for(var b=a.vertexes.iterator;b.next();)b.value.valid=!0;for(;zx(a)!==null;){for(b=V1(a);b!==null;)E[x]=b,x--,b.valid=!1,b=V1(a);for(b=U1(a);b!==null;)E[y]=b,y++,b.valid=!1,b=U1(a);b=null;for(var z=0,ee=this.network.vertexes.iterator;ee.next();){var re=ee.value;if(re.valid){for(var oe=0,se=re.destinationEdges;se.next();)se.value.toVertex.valid&&oe++;se=0;for(var ue=re.sourceEdges;ue.next();)ue.value.fromVertex.valid&&se++;(b===null||z<oe-se)&&(b=re,z=oe-se)}}b!==null&&(E[y]=b,y++,b.valid=!1)}for(y=0;y<a.vertexes.count;y++)E[y].index=y;for(E=a.edges.iterator;E.next();)y=E.value,y.fromVertex.index>y.toVertex.index&&(a.gm(y),y.rev=!0);break;case Fv:for(E=this.network.vertexes.iterator;E.next();)a=E.value,a.Ll=-1,a.finish=-1;for(a=this.network.edges.iterator;a.next();)a.value.forest=!1;for(this.Kn=0,E.reset();E.next();)y=E.value,y.sourceEdges.count===0&&vy(this,y);for(E.reset();E.next();)y=E.value,y.Ll===-1&&vy(this,y);for(a.reset();a.next();)E=a.value,E.forest||(y=E.fromVertex,x=y.finish,b=E.toVertex,z=b.finish,b.Ll<y.Ll&&x<z&&(this.network.gm(E),E.rev=!0));break;case Up:for(a=this.network,y=a.vertexes.iterator,E=1/0;y.next();)E=Math.min(E,y.value.layer);if(1/0>E){if(0>E)for(y.reset();y.next();)y.value.layer-=E;for(E=[],y.reset();y.next();)x=y.value,b=E[x.layer],b===void 0?E[x.layer]=[x]:b.push(x);for(x=y=0;x<E.length;x++)if(b=E[x],!b||b.length===0)y++;else if(0<x)for(z=0;z<b.length;z++)b[z].layer-=y;for(E=a.edges.iterator;E.next();)y=E.value,y.fromVertex.layer<y.toVertex.layer&&(a.gm(y),y.rev=!0)}}};function zx(a){for(a=a.vertexes.iterator;a.next();){var y=a.value;if(y.valid)return y}return null}function V1(a){for(a=a.vertexes.iterator;a.next();){var y=a.value;if(y.valid){for(var x=!0,E=y.destinationEdges;E.next();)if(E.value.toVertex.valid){x=!1;break}if(x)return y}}return null}function U1(a){for(a=a.vertexes.iterator;a.next();){var y=a.value;if(y.valid){for(var x=!0,E=y.sourceEdges;E.next();)if(E.value.fromVertex.valid){x=!1;break}if(x)return y}}return null}function vy(a,y){y.Ll=a.Kn,a.Kn++;for(var x=y.destinationEdges;x.next();){var E=x.value,b=E.toVertex;b.Ll===-1&&(E.forest=!0,vy(a,b))}y.finish=a.Kn,a.Kn++}aa.prototype.assignLayers=function(){switch(this.Zk){case xy:Z1(this);break;case wy:for(var a,y=this.network.vertexes.iterator;y.next();)a=Y1(this,y.value),this.Ia=Math.max(a,this.Ia);for(y.reset();y.next();)a=y.value,a.layer=this.Ia-a.layer;break;default:case Av:for(Z1(this),y=this.network.vertexes.iterator;y.next();)y.value.valid=!1;for(y.reset();y.next();)a=y.value,a.sourceEdges.count===0&&X1(this,a);for(a=1/0,y.reset();y.next();)a=Math.min(a,y.value.layer);for(this.Ia=-1,y.reset();y.next();){var x=y.value;x.layer-=a,this.Ia=Math.max(this.Ia,x.layer)}}};function Z1(a){for(var y=a.network.vertexes.iterator;y.next();){var x=_1(a,y.value);a.Ia=Math.max(x,a.Ia)}}function _1(a,y){var x=0;if(y.layer===-1){for(var E=y.destinationEdges;E.next();){var b=E.value,z=b.toVertex;b=a.linkMinLength(b),x=Math.max(x,_1(a,z)+b)}y.layer=x}else x=y.layer;return x}function Y1(a,y){var x=0;if(y.layer===-1){for(var E=y.sourceEdges;E.next();){var b=E.value,z=b.fromVertex;b=a.linkMinLength(b),x=Math.max(x,Y1(a,z)+b)}y.layer=x}else x=y.layer;return x}function X1(a,y){if(!y.valid){y.valid=!0;for(var x=y.destinationEdges;x.next();)X1(a,x.value.toVertex);for(x=a.network.vertexes.iterator;x.next();)x.value.component=-1;for(var E=y.sourceEdgesArrayAccess,b=E.length,z=0;z<b;z++){var ee=E[z],re=ee.fromVertex,oe=ee.toVertex;ee=a.linkMinLength(ee),re.layer-oe.layer>ee&&Vp(a,re,0,-1,!0,!1)}for(Vp(a,y,1,-1,!0,!0);y.component!==0;){for(z=0,E=1/0,re=0,oe=null,ee=a.network.vertexes.iterator;ee.next();){var se=ee.value;if(se.component===1){var ue=0,fe=!1,ve=se.sourceEdgesArrayAccess;b=ve.length;for(var ye=0;ye<b;ye++){var Ce=ve[ye],Ae=Ce.fromVertex;ue+=1,Ae.component!==1&&(z+=1,Ae=Ae.layer-se.layer,Ce=a.linkMinLength(Ce),E=Math.min(E,Ae-Ce))}for(ve=se.destinationEdgesArrayAccess,b=ve.length,ye=0;ye<b;ye++)Ce=ve[ye].toVertex,--ue,Ce.component!==1?--z:fe=!0;(oe===null||ue<re)&&!fe&&(oe=se,re=ue)}}if(0<z){for(x.reset();x.next();)b=x.value,b.component===1&&(b.layer+=E);y.component=0}else oe.component=0}for(x=a.network.vertexes.iterator;x.next();)x.value.component=-1;for(Vp(a,y,1,-1,!0,!1);y.component!==0;){for(E=0,b=1/0,z=0,re=null,oe=a.network.vertexes.iterator;oe.next();)if(ee=oe.value,ee.component===1){for(se=0,ue=!1,ve=ee.sourceEdgesArrayAccess,fe=ve.length,ye=0;ye<fe;ye++)Ce=ve[ye].fromVertex,se+=1,Ce.component!==1?E+=1:ue=!0;for(ve=ee.destinationEdgesArrayAccess,fe=ve.length,ye=0;ye<fe;ye++)Ce=ve[ye],Ae=Ce.toVertex,--se,Ae.component!==1&&(--E,Ae=ee.layer-Ae.layer,Ce=a.linkMinLength(Ce),b=Math.min(b,Ae-Ce));(re===null||se>z)&&!ue&&(re=ee,z=se)}if(0>E){for(x.reset();x.next();)E=x.value,E.component===1&&(E.layer-=b);y.component=0}else re.component=0}}}function J1(a,y,x){return a.K===90?x&&!y.rev||!x&&y.rev?270:90:a.K===180?x&&!y.rev||!x&&y.rev?0:180:a.K===270?x&&!y.rev||!x&&y.rev?90:270:x&&!y.rev||!x&&y.rev?180:0}aa.prototype.initializeIndices=function(){switch(this.Qk){default:case Cy:for(var a=this.network.vertexes.iterator;a.next();){var y=a.value,x=y.layer;y.index=this.tc[x],this.tc[x]++}break;case Nv:for(a=this.network.vertexes.iterator,y=this.Ia;0<=y;y--)for(a.reset();a.next();)x=a.value,x.layer===y&&x.index===-1&&Q1(this,x);break;case Py:for(a=this.network.vertexes.iterator,y=0;y<=this.Ia;y++)for(a.reset();a.next();)x=a.value,x.layer===y&&x.index===-1&&q1(this,x)}};function Q1(a,y){var x=y.layer;for(y.index=a.tc[x],a.tc[x]++,y=y.destinationEdgesArrayAccess,x=!0;x;){x=!1;for(var E=0;E<y.length-1;E++){var b=y[E],z=y[E+1];b.portFromColOffset>z.portFromColOffset&&(x=!0,y[E]=z,y[E+1]=b)}}for(x=0;x<y.length;x++)E=y[x],E.valid&&(E=E.toVertex,E.index===-1&&Q1(a,E))}function q1(a,y){var x=y.layer;y.index=a.tc[x],a.tc[x]++,y=y.sourceEdgesArrayAccess;for(var E=!0;E;)for(E=!1,x=0;x<y.length-1;x++){var b=y[x],z=y[x+1];b.portToColOffset>z.portToColOffset&&(E=!0,y[x]=z,y[x+1]=b)}for(x=0;x<y.length;x++)E=y[x],E.valid&&(E=E.fromVertex,E.index===-1&&q1(a,E))}aa.prototype.reduceCrossings=function(){var a=this.countCrossings(),y=zu(this),x,E;for(x=0;x<this.bj;x++){for(E=0;E<=this.Ia;E++)Lv(this,E,1),Yh(this,E,1);var b=this.countCrossings();for(b<a&&(a=b,y=zu(this)),E=this.Ia;0<=E;E--)Lv(this,E,-1),Yh(this,E,-1);b=this.countCrossings(),b<a&&(a=b,y=zu(this))}for(Rh(this,y),x=0;x<this.bj;x++){for(E=0;E<=this.Ia;E++)Lv(this,E,0),Yh(this,E,0);for(b=this.countCrossings(),b<a&&(a=b,y=zu(this)),E=this.Ia;0<=E;E--)Lv(this,E,0),Yh(this,E,0);b=this.countCrossings(),b<a&&(a=b,y=zu(this))}Rh(this,y);var z,ee,re;switch(this.rk){case Ey:break;case by:for(re=a+1;(E=this.countCrossings())<re;)for(re=E,x=this.Ia;0<=x;x--)for(ee=0;ee<=x;ee++){for(z=!0;z;)for(z=!1,E=x;E>=ee;E--)z=Yh(this,E,-1)||z;for(b=this.countCrossings(),b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=x;E>=ee;E--)z=Yh(this,E,1)||z;for(b=this.countCrossings(),b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=ee;E<=x;E++)z=Yh(this,E,1)||z;for(b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=ee;E<=x;E++)z=Yh(this,E,-1)||z;for(b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=x;E>=ee;E--)z=Yh(this,E,0)||z;for(b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=ee;E<=x;E++)z=Yh(this,E,0)||z;b>=a?Rh(this,y):(a=b,y=zu(this))}break;default:case Tv:for(x=this.Ia,ee=0,re=a+1;(E=this.countCrossings())<re;){for(re=E,z=!0;z;)for(z=!1,E=x;E>=ee;E--)z=Yh(this,E,-1)||z;for(b=this.countCrossings(),b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=x;E>=ee;E--)z=Yh(this,E,1)||z;for(b=this.countCrossings(),b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=ee;E<=x;E++)z=Yh(this,E,1)||z;for(b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=ee;E<=x;E++)z=Yh(this,E,-1)||z;for(b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=x;E>=ee;E--)z=Yh(this,E,0)||z;for(b>=a?Rh(this,y):(a=b,y=zu(this)),z=!0;z;)for(z=!1,E=ee;E<=x;E++)z=Yh(this,E,0)||z;b>=a?Rh(this,y):(a=b,y=zu(this))}}Rh(this,y)};function Lv(a,y,x){var E=$d(a,y),b=a.tc[y],z=W1(a,y,x),ee=py(a,y,x);for(x=0;x<b;x++)ee[x]===-1&&(ee[x]=E[x].column),z[x]===-1&&(z[x]=E[x].column);for(var re=!0,oe;re;)for(re=!1,x=0;x<b-1;x++)(z[x+1]<z[x]||z[x+1]===z[x]&&ee[x+1]<ee[x])&&(re=!0,oe=z[x],z[x]=z[x+1],z[x+1]=oe,oe=ee[x],ee[x]=ee[x+1],ee[x+1]=oe,oe=E[x],E[x]=E[x+1],E[x+1]=oe);for(x=z=0;x<b;x++)oe=E[x],oe.index=x,z+=a.nodeMinColumnSpace(oe,!0),oe.column=z,z+=1,z+=a.nodeMinColumnSpace(oe,!1);ef(a,y,E)}function Yh(a,y,x){var E=$d(a,y),b=a.tc[y];x=K1(a,y,x);var z,ee=[];for(z=0;z<b;z++)ee[z]=-1;var re=[];for(z=0;z<b;z++)re[z]=-1;for(var oe=!1,se=!0;se;)for(se=!1,z=0;z<b-1;z++){var ue=x[E[z].index*b+E[z+1].index],fe=x[E[z+1].index*b+E[z].index],ve=0,ye=0,Ce=E[z].column,Ae=E[z+1].column,Ye=a.nodeMinColumnSpace(E[z],!0),We=a.nodeMinColumnSpace(E[z],!1),tt=a.nodeMinColumnSpace(E[z+1],!0),rt=a.nodeMinColumnSpace(E[z+1],!1);Ye=Ce-Ye+tt,We=Ae-We+rt;var at=E[z].sourceEdges.iterator;for(at.reset();at.next();)if(tt=at.value,rt=tt.fromVertex,tt.valid&&rt.layer===y){for(tt=0;E[tt]!==rt;)tt++;tt<z&&(ve+=2*(z-tt),ye+=2*(z+1-tt)),tt===z+1&&(ve+=1),tt>z+1&&(ve+=4*(tt-z),ye+=4*(tt-(z+1)))}for(at=E[z].destinationEdges.iterator,at.reset();at.next();)if(tt=at.value,rt=tt.toVertex,tt.valid&&rt.layer===y){for(tt=0;E[tt]!==rt;)tt++;tt===z+1&&(ye+=1)}for(at=E[z+1].sourceEdges.iterator,at.reset();at.next();)if(tt=at.value,rt=tt.fromVertex,tt.valid&&rt.layer===y){for(tt=0;E[tt]!==rt;)tt++;tt<z&&(ve+=2*(z+1-tt),ye+=2*(z-tt)),tt===z&&(ye+=1),tt>z+1&&(ve+=4*(tt-(z+1)),ye+=4*(tt-z))}for(at=E[z+1].destinationEdges.iterator,at.reset();at.next();)if(tt=at.value,rt=tt.toVertex,tt.valid&&rt.layer===y){for(tt=0;E[tt]!==rt;)tt++;tt===z&&(ve+=1)}tt=rt=0,at=ee[E[z].index];var gt=re[E[z].index],At=ee[E[z+1].index],Zn=re[E[z+1].index];at!==-1&&(rt+=Math.abs(at-Ce),tt+=Math.abs(at-We)),gt!==-1&&(rt+=Math.abs(gt-Ce),tt+=Math.abs(gt-We)),At!==-1&&(rt+=Math.abs(At-Ae),tt+=Math.abs(At-Ye)),Zn!==-1&&(rt+=Math.abs(Zn-Ae),tt+=Math.abs(Zn-Ye)),(ye<ve-.5||ye===ve&&fe<ue-.5||ye===ve&&fe===ue&&tt<rt-.5)&&(se=oe=!0,E[z].column=We,E[z+1].column=Ye,ue=E[z],E[z]=E[z+1],E[z+1]=ue)}for(z=0;z<b;z++)E[z].index=z;return ef(a,y,E),oe}aa.prototype.straightenAndPack=function(){if(this.ve===0){var a=(this.bg&1)!==0,y=(this.bg&_x)!==0;if(1e3<this.network.edges.count&&y&&(a=!1),a){var x=[];for(y=0;y<=this.Ia;y++)x[y]=0;for(var E,b=this.network.vertexes.iterator;b.next();){var z=b.value;y=z.layer,E=z.column,z=this.nodeMinColumnSpace(z,!1),x[y]=Math.max(x[y],E+z)}for(b.reset();b.next();)z=b.value,y=z.layer,E=z.column,z.column=(8*(this.Ra-x[y])>>1)+8*E;this.Ra*=8}if(this.bg&2)for(x=!0;x;){for(x=!1,y=this.Md+1;y<=this.Ia;y++)x=zg(this,y,1)||x;for(y=this.Md-1;0<=y;y--)x=zg(this,y,-1)||x;x=zg(this,this.Md,0)||x}if(this.bg&4){for(y=this.Md+1;y<=this.Ia;y++)yy(this,y,1);for(y=this.Md-1;0<=y;y--)yy(this,y,-1);yy(this,this.Md,0)}if(a&&($1(this,-1),$1(this,1)),this.bg&2)for(x=!0;x;){for(x=!1,x=zg(this,this.Md,0)||x,y=this.Md+1;y<=this.Ia;y++)x=zg(this,y,0)||x;for(y=this.Md-1;0<=y;y--)x=zg(this,y,0)||x}}else Wx(this)};function zg(a,y,x){for(var E=!1;Hx(a,y,x);)E=!0;return E}function Hx(a,y,x){var E,b=$d(a,y),z=a.tc[y],ee=py(a,y,-1);if(0<x)for(E=0;E<z;E++)ee[E]=-1;var re=py(a,y,1);if(0>x)for(E=0;E<z;E++)re[E]=-1;for(var oe=!1,se=!0;se;)for(se=!1,E=0;E<z;E++){var ue=b[E].column,fe=a.nodeMinColumnSpace(b[E],!0),ve=a.nodeMinColumnSpace(b[E],!1),ye=0;0>E-1||ue-b[E-1].column-1>fe+a.nodeMinColumnSpace(b[E-1],!1)?ye=ue-1:ye=ue,fe=E+1>=z||b[E+1].column-ue-1>ve+a.nodeMinColumnSpace(b[E+1],!0)?ue+1:ue;var Ce=ve=0,Ae=0;if(0>=x)for(var Ye=b[E].sourceEdges.iterator;Ye.next();){var We=Ye.value,tt=We.fromVertex;if(We.valid&&tt.layer!==y){var rt=gy(We),at=We.portFromColOffset;We=We.portToColOffset,tt=tt.column,ve+=(Math.abs(ue+We-(tt+at))+1)*rt,Ce+=(Math.abs(ye+We-(tt+at))+1)*rt,Ae+=(Math.abs(fe+We-(tt+at))+1)*rt}}if(0<=x)for(Ye=b[E].destinationEdges.iterator;Ye.next();)We=Ye.value,tt=We.toVertex,We.valid&&tt.layer!==y&&(rt=gy(We),at=We.portFromColOffset,We=We.portToColOffset,tt=tt.column,ve+=(Math.abs(ue+at-(tt+We))+1)*rt,Ce+=(Math.abs(ye+at-(tt+We))+1)*rt,Ae+=(Math.abs(fe+at-(tt+We))+1)*rt);We=at=rt=0,Ye=ee[b[E].index],tt=re[b[E].index],Ye!==-1&&(rt+=Math.abs(Ye-ue),at+=Math.abs(Ye-ye),We+=Math.abs(Ye-fe)),tt!==-1&&(rt+=Math.abs(tt-ue),at+=Math.abs(tt-ye),We+=Math.abs(tt-fe)),Ce<ve||Ce===ve&&at<rt?(se=oe=!0,b[E].column=ye):(Ae<ve||Ae===ve&&We<rt)&&(se=oe=!0,b[E].column=fe)}return ef(a,y,b),a.normalize(),oe}function yy(a,y,x){var E=$d(a,y),b=a.tc[y],z=W1(a,y,x),ee=[];for(x=0;x<b;x++)ee[x]=z[x];for(z=!0;z;)for(z=!1,x=0;x<b;x++){var re=E[x].column,oe=a.nodeMinColumnSpace(E[x],!0),se=a.nodeMinColumnSpace(E[x],!1),ue=0;if(ee[x]===-1)if(x===0&&x===b-1)ue=re;else if(x===0){var fe=E[x+1].column;fe-re===se+a.nodeMinColumnSpace(E[x+1],!0)?ue=re-1:ue=re}else x===b-1?(fe=E[x-1].column,ue=re-fe===oe+a.nodeMinColumnSpace(E[x-1],!1)?re+1:re):(fe=E[x-1].column,oe=fe+a.nodeMinColumnSpace(E[x-1],!1)+oe+1,fe=E[x+1].column,se=fe-a.nodeMinColumnSpace(E[x+1],!0)-se-1,ue=(oe+se)/2|0);else x===0&&x===b-1?ue=ee[x]:x===0?(fe=E[x+1].column,se=fe-a.nodeMinColumnSpace(E[x+1],!0)-se-1,ue=Math.min(ee[x],se)):x===b-1?(fe=E[x-1].column,oe=fe+a.nodeMinColumnSpace(E[x-1],!1)+oe+1,ue=Math.max(ee[x],oe)):(fe=E[x-1].column,oe=fe+a.nodeMinColumnSpace(E[x-1],!1)+oe+1,fe=E[x+1].column,se=fe-a.nodeMinColumnSpace(E[x+1],!0)-se-1,oe<ee[x]&&ee[x]<se?ue=ee[x]:oe>=ee[x]?ue=oe:se<=ee[x]&&(ue=se));ue!==re&&(z=!0,E[x].column=ue)}ef(a,y,E),a.normalize()}function Gx(a,y){for(var x=!0,E=a.network.vertexes.iterator;E.next();){var b=E.value,z=a.nodeMinColumnSpace(b,!0),ee=a.nodeMinColumnSpace(b,!1);if(b.column-z<=y&&b.column+ee>=y){x=!1;break}}if(a=!1,x)for(E.reset();E.next();)x=E.value,x.column>y&&(--x.column,a=!0);return a}function Kx(a,y){var x=y+1,E,b=[],z=[];for(E=0;E<=a.Ia;E++)b[E]=!1,z[E]=!1;for(var ee=a.network.vertexes.iterator;ee.next();){E=ee.value;var re=E.column-a.nodeMinColumnSpace(E,!0),oe=E.column+a.nodeMinColumnSpace(E,!1);re<=y&&oe>=y&&(b[E.layer]=!0),re<=x&&oe>=x&&(z[E.layer]=!0)}for(re=!0,x=!1,E=0;E<=a.Ia;E++)re=re&&!(b[E]&&z[E]);if(re)for(ee.reset();ee.next();)a=ee.value,a.column>y&&(--a.column,x=!0);return x}function $1(a,y){for(var x=0;x<=a.Ra;x++)for(;Gx(a,x););for(a.normalize(),x=0;x<a.Ra;x++)for(;Kx(a,x););a.normalize();var E;if(0<y)for(x=0;x<=a.Ra;x++){var b=zu(a),z=bv(a);for(E=z+1;z<E;){E=z,ex(a,x,1);var ee=bv(a);ee>z?Rh(a,b):ee<z&&(z=ee,b=zu(a))}}if(0>y)for(x=a.Ra;0<=x;x--)for(b=zu(a),z=bv(a),E=z+1;z<E;)E=z,ex(a,x,-1),ee=bv(a),ee>z?Rh(a,b):ee<z&&(z=ee,b=zu(a));a.normalize()}function ex(a,y,x){a.le=0;for(var E=a.network.vertexes.iterator;E.next();)E.value.component=-1;if(0<x)for(E.reset();E.next();){var b=E.value;b.column-a.nodeMinColumnSpace(b,!0)<=y&&(b.component=a.le)}if(0>x)for(E.reset();E.next();)b=E.value,b.column+a.nodeMinColumnSpace(b,!1)>=y&&(b.component=a.le);for(a.le++,E.reset();E.next();)y=E.value,y.component===-1&&(my(a,y,a.le,-1,!0,!0),a.le++);var z;for(y=[],z=0;z<a.le*a.le;z++)y[z]=!1;for(b=[],z=0;z<(a.Ia+1)*(a.Ra+1);z++)b[z]=-1;for(E.reset();E.next();){z=E.value;for(var ee=z.layer,re=Math.max(0,z.column-a.nodeMinColumnSpace(z,!0)),oe=Math.min(a.Ra,z.column+a.nodeMinColumnSpace(z,!1));re<=oe;re++)b[ee*(a.Ra+1)+re]=z.component}for(z=0;z<=a.Ia;z++){if(0<x)for(ee=0;ee<a.Ra;ee++)b[z*(a.Ra+1)+ee]!==-1&&b[z*(a.Ra+1)+ee+1]!==-1&&b[z*(a.Ra+1)+ee]!==b[z*(a.Ra+1)+ee+1]&&(y[b[z*(a.Ra+1)+ee]*a.le+b[z*(a.Ra+1)+ee+1]]=!0);if(0>x)for(ee=a.Ra;0<ee;ee--)b[z*(a.Ra+1)+ee]!==-1&&b[z*(a.Ra+1)+ee-1]!==-1&&b[z*(a.Ra+1)+ee]!==b[z*(a.Ra+1)+ee-1]&&(y[b[z*(a.Ra+1)+ee]*a.le+b[z*(a.Ra+1)+ee-1]]=!0)}for(b=[],z=0;z<a.le;z++)b[z]=!0;for(ee=[],ee.push(0);ee.length!==0;)if(oe=ee[ee.length-1],ee.pop(),b[oe])for(b[oe]=!1,z=0;z<a.le;z++)y[oe*a.le+z]&&ee.splice(0,0,z);if(0<x)for(E.reset();E.next();)a=E.value,b[a.component]&&--a.column;if(0>x)for(E.reset();E.next();)x=E.value,b[x.component]&&(x.column+=1)}function Wx(a){for(var y=qi(),x=a.fl.length,E=0;E<=x;E++)y[E]=[];for(E=a.network.vertexes.iterator;E.next();){var b=E.value;y[x-b.layer][b.index]=b}x=new Pn,Vx(y,x);var z=null,ee=null,re=null,oe=null,se=(a.ve&1)!==0,ue=(a.ve&2)!==0,fe=(a.ve&4)!==0,ve=(a.ve&8)!==0;for(se&&(a.verticalAlignment(y,x,!0),z=Mv(a,y,!0,!1)),y.reverse(),fe&&(a.verticalAlignment(y,x,!1),re=Mv(a,y,!1,!1)),E=bn(y),b=E.next();!b.done;b=E.next())b.value.reverse();ve&&(a.verticalAlignment(y,x,!1),oe=Mv(a,y,!1,!0)),y.reverse(),ue&&(a.verticalAlignment(y,x,!0),ee=Mv(a,y,!0,!0)),Zi(y),a.u(z,ee,re,oe),a.network.vertexes.each(function(ye){var Ce=qi();se&&Ce.push(z.get(ye)),ue&&Ce.push(ee.get(ye)),fe&&Ce.push(re.get(ye)),ve&&Ce.push(oe.get(ye)),Ce.sort(function(Ye,We){return Ye-We});var Ae=Ce.length;Ae=(Ce[Math.floor((Ae-1)/2)]+Ce[Math.ceil((Ae-1)/2)])/2,Zi(Ce),ye.zc=Ae})}function Vx(a,y){for(var x=a.length,E=1;E<x-1;E++)for(var b=0,z=0,ee=a[E],re=a[E+1],oe=0;z<re.length;oe++){var se=re[oe];e:{if(se.node===null){var ue=Ly(se);if(0<ue.length){ue=ue[0].node===null;break e}}ue=!1}var fe=ue;if(oe===re.length-1||fe){for(ue=ee.length-1,fe&&(ue=Ly(se)[0].index);z<=oe;){if(se=re[z],!se.bo){fe=[];for(var ve=bn(se.sourceEdgesArrayAccess),ye=ve.next();!ye.done;ye=ve.next())ye=ye.value,ye.valid&&fe.push(ye);se.bo=fe}for(se=bn(se.bo),fe=se.next();!fe.done;fe=se.next())fe=fe.value,ve=fe.fromVertex.index,(ve<b||ve>ue)&&y.add(fe);z++}b=ue}}}aa.prototype.verticalAlignment=function(a,y,x){Ux(a),a=bn(a);for(var E=a.next();!E.done;E=a.next()){var b=-1;E=bn(E.value);for(var z=E.next();!z.done;z=E.next()){z=z.value;var ee=x?Ly(z):Yx(z),re=ee.length;if(0<re){ee.sort(function(fe,ve){return fe.vi-ve.vi});var oe=(re-1)/2;for(re=Math.floor(oe),oe=Math.ceil(oe);re<=oe;re++)if(z.align===z){var se=ee[re],ue=void 0;ue=x?Dv(se,z):Dv(z,se),!y.contains(ue)&&b<se.vi&&(se.align=z,z.root=se.root,z.align=se.root,b=se.vi)}}}}};function Ux(a){for(var y=0;y<a.length;y++)for(var x=a[y],E=0;E<x.length;E++){var b=x[E];b.root=b,b.align=b,b.Tz=y,b.vi=E}}function Mv(a,y,x,E){for(var b=a.K===90||a.K===270,z=bn(y),ee=z.next();!ee.done;ee=z.next()){var re=bn(ee.value);for(ee=re.next();!ee.done;ee=re.next())ee=ee.value,ee.sd=ee,ee.shift=1/0,ee.zc=NaN,ee.qg=0}for(ee=a.K===90||a.K===270,z=bn(y),re=z.next();!re.done;re=z.next()){re=bn(re.value);for(var oe=re.next();!oe.done;oe=re.next())if(oe=oe.value,oe.root===oe){for(var se=0,ue=oe;ue.align!==oe;){var fe=ue.align,ve=ee?ue.width:ue.height,ye=ee?fe.width:fe.height;if(x){var Ce=Dv(ue,fe),Ae=Ce.portFromPos,Ye=Ce.portToPos;Ce.link!==null&&(ue.node&&ue.node!==Ce.link.fromNode&&(Ae=ee?ue.focusX:ue.focusY),fe.node&&fe.node!==Ce.link.toNode&&(Ye=ee?fe.focusX:fe.focusY))}else Ce=Dv(fe,ue),Ae=Ce.portToPos,Ye=Ce.portFromPos,Ce.link!==null&&(ue.node&&ue.node!==Ce.link.toNode&&(Ae=ee?ue.focusX:ue.focusY),fe.node&&fe.node!==Ce.link.fromNode&&(Ye=ee?fe.focusX:fe.focusY));ve=E?ue.qg+(ve-Ae)-(ye-Ye):ue.qg+Ae-Ye,fe.qg=ve,se=Math.min(se,ve),ue=ue.align}ue=oe;do ue.qg=ue.qg-se,ue=ue.align;while(ue!==oe)}}for(x=bn(y),ee=x.next();!ee.done;ee=x.next())for(z=bn(ee.value),ee=z.next();!ee.done;ee=z.next())ee=ee.value,ee.root===ee&&tx(a,ee,y);for(x=0;x<y.length;x++)if(!(0>=y[x].length)&&(ee=y[x][0],ee.sd===ee)){ee.sd.shift===1/0&&(ee.sd.shift=0),ee=x,re=0;do{for(z=y[ee][re];z.align!==z.root;)z=z.align,ee++,0<z.vi&&(re=nx(z,y),re.sd.shift=Math.min(re.sd.shift,z.sd.shift+z.zc+z.qg-(re.zc+re.qg+(b?re.width:re.height)+a.columnSpacing)));re=z.vi+1}while(ee<y.length&&re<y[ee].length&&z.sd===y[ee][re].sd)}for(a=new Li,y=bn(y),ee=y.next();!ee.done;ee=y.next())for(x=bn(ee.value),ee=x.next();!ee.done;ee=x.next())ee=ee.value,ee.zc=ee.zc+ee.sd.shift+ee.qg,z=b?ee.width:ee.height,a.add(ee,E?-ee.zc-z:ee.zc);return a}function tx(a,y,x){if(isNaN(y.zc)){y.zc=0;var E=y;do{if(0<E.vi){var b=nx(E,x),z=b.root;tx(a,z,x),y.sd===y&&(y.sd=z.sd);var ee=a.K===90||a.K===270?b.width:b.height;y.sd===z.sd&&(y.zc=Math.max(y.zc,z.zc+b.qg+ee-E.qg+a.columnSpacing))}E=E.align}while(E!==y);for(;E.align!==y;)E=E.align,E.zc=y.zc,E.sd=y.sd}}function nx(a,y){var x=a.Tz;return a=a.vi,1>a&&Dt("Could not determine previous vertex in layer"),y[x][a-1]}aa.prototype.u=function(a){for(var y=[],x=0;x<arguments.length;++x)y[x]=arguments[x];x=-1;for(var E=qi(),b=qi(),z=1/0,ee=0;4>ee;ee++)if(y[ee]){var re=Zx(this,y[ee],E,b,ee);re<z&&(x=ee,z=re)}for(z={},ee=0;4>ee;z={delta:z.delta},ee++)y[ee]&&(z.delta=ee===0||ee===2?E[x]-E[ee]:b[x]-b[ee],z.delta!==0&&y[ee].each(function(oe){return function(se){se.value+=oe.delta}}(z)));Zi(E),Zi(b)};function Zx(a,y,x,E,b){if(!y||y.count===0)return x[b]=0,E[b]=0,1/0;var z=1/0,ee=-1/0;return y.each(function(re){var oe=re.key;re=re.value,oe=a.K===90||a.K===270?oe.width:oe.height,re<z&&(z=re),re+oe>ee&&(ee=re+oe)}),x[b]=z,E[b]=ee,ee-z}aa.prototype.commitLayout=function(){if(this.setsPortSpots)for(var a=kv(this,!0),y=kv(this,!1),x=this.network.edges.iterator;x.next();){var E=x.value.link;E!==null&&(E.fromSpot=a,E.toSpot=y)}this.commitNodes(),this.Gu(),this.isRouting&&this.commitLinks()};function kv(a,y){return a.K===270?y?Ml:Us:a.K===90?y?Us:Ml:a.K===180?y?ol:Rs:y?Rs:ol}aa.prototype.commitNodes=function(){this.he=[],this.Ld=[],this.Kd=[],this.Ta=[];for(var a=0;a<=this.Ia;a++)this.he[a]=0,this.Ld[a]=0,this.Kd[a]=0,this.Ta[a]=0;for(a=this.network.vertexes.iterator;a.next();){var y=a.value,x=y.layer;this.he[x]=Math.max(this.he[x],this.nodeMinLayerSpace(y,!0)),this.Ld[x]=Math.max(this.Ld[x],this.nodeMinLayerSpace(y,!1))}y=0,x=this.ie;for(var E=0;E<=this.Ia;E++){var b=x;0>=this.he[E]+this.Ld[E]&&(b=0),0<E&&(y+=b/2),this.K===90||this.K===0?(y+=this.Ld[E],this.Kd[E]=y,y+=this.he[E]):(y+=this.he[E],this.Kd[E]=y,y+=this.Ld[E]),E<this.Ia&&(y+=b/2),this.Ta[E]=y}for(x=y,y=this.arrangementOrigin,E=0;E<=this.Ia;E++)this.K===270?this.Kd[E]=y.y+this.Kd[E]:this.K===90?(this.Kd[E]=y.y+x-this.Kd[E],this.Ta[E]=x-this.Ta[E]):this.K===180?this.Kd[E]=y.x+this.Kd[E]:(this.Kd[E]=y.x+x-this.Kd[E],this.Ta[E]=x-this.Ta[E]);x=this.ve!==0,a.reset(),E=this.K===270||this.K===90;for(var z=1/0,ee=b=1/0,re=-1/0;a.next();){var oe=a.value,se=oe.layer,ue=oe.column|0;E?(ee=y.x+this.kc*ue,se=this.Kd[se]):(ee=this.Kd[se],se=y.y+this.kc*ue),oe.centerX=ee,oe.centerY=se,x&&isFinite(oe.zc)&&(E?oe.node?oe.x=y.x+oe.zc:oe.centerX=y.x+oe.zc:oe.node?oe.y=y.y+oe.zc:oe.centerY=y.y+oe.zc),z=Math.min(oe.x,z),b=Math.min(oe.y,b),E?(ee=z,re=Math.max(re,oe.bounds.right)):(ee=b,re=Math.max(re,oe.bounds.bottom))}for(this.xw=re-ee,z=y.x-z,y=y.y-b,this.Rf=new Qe(x&&E?0:z,x&&!E?0:y),a.reset();a.next();)x=a.value,x.x+=z,x.y+=y,x.commit()},aa.prototype.Gu=function(){for(var a=0,y=this.ie,x=0;x<=this.Ia;x++)a+=this.he[x],a+=this.Ld[x];a+=this.Ia*y,y=[],x=this.ve!==0?this.xw:this.kc*this.Ra;for(var E=this.maxLayer;0<=E;E--)this.K===270?E===0?y.push(new Xt(0,0,x,Math.abs(this.Ta[0]))):y.push(new Xt(0,this.Ta[E-1],x,Math.abs(this.Ta[E-1]-this.Ta[E]))):this.K===90?E===0?y.push(new Xt(0,this.Ta[0],x,Math.abs(this.Ta[0]-a))):y.push(new Xt(0,this.Ta[E],x,Math.abs(this.Ta[E-1]-this.Ta[E]))):this.K===180?E===0?y.push(new Xt(0,0,Math.abs(this.Ta[0]),x)):y.push(new Xt(this.Ta[E-1],0,Math.abs(this.Ta[E-1]-this.Ta[E]),x)):E===0?y.push(new Xt(this.Ta[0],0,Math.abs(this.Ta[0]-a),x)):y.push(new Xt(this.Ta[E],0,Math.abs(this.Ta[E-1]-this.Ta[E]),x));this.commitLayers(y,this.Rf)},aa.prototype.commitLayers=function(){},aa.prototype.commitLinks=function(){for(var a=this.network.edges.iterator,y;a.next();)y=a.value.link,y!==null&&(y.uh(),y.Fj(),y.zf());for(a.reset();a.next();)y=a.value.link,y!==null&&y.vg();for(a.reset();a.next();){var x=a.value;if(y=x.link,y!==null){y.uh();var E=y,b=E.fromNode,z=E.toNode,ee=E.fromPort,re=E.toPort;if(b!==null){var oe=b.findVisibleNode();oe!==null&&oe!==b&&(b=oe,ee=oe.port)}z!==null&&(oe=z.findVisibleNode(),oe!==null&&oe!==z&&(z=oe,re=oe.port));var se=y.computeSpot(!0,ee);oe=y.computeSpot(!1,re);var ue=x.fromVertex,fe=x.toVertex;if(x.valid)y.curve===vh&&y.pointsCount===4&&(ue.column===fe.column&&this.alignOption===0?(x=y.getLinkPoint(b,ee,se,!0,!1,z,re),re=y.getLinkPoint(z,re,oe,!1,!1,b,ee),x.w()||x.set(b.actualBounds.center),re.w()||re.set(z.actualBounds.center),y.Fj(),y.yf(x.x,x.y),y.yf((2*x.x+re.x)/3,(2*x.y+re.y)/3),y.yf((x.x+2*re.x)/3,(x.y+2*re.y)/3),y.yf(re.x,re.y)):(x=E=!1,ee!==null&&se===Ms&&(E=!0),re!==null&&oe===Ms&&(x=!0),(E||x)&&(oe=null,E&&(oe=y.getLinkPointFromPoint(b,ee,ee.ga(ko),y.i(3),!0),oe.w()||oe.set(b.actualBounds.center),y.L(0,oe.x,oe.y)),b=null,x&&(b=y.getLinkPointFromPoint(z,re,re.ga(ko),y.i(0),!1),b.w()||b.set(z.actualBounds.center),y.L(3,b.x,b.y)),oe&&(z=y.i(2),y.L(1,(2*oe.x+z.x)/3,(2*oe.y+z.y)/3)),b&&(z=y.i(1),y.L(2,(2*b.x+z.x)/3,(2*b.y+z.y)/3))))),y.zf();else if(ue.layer===fe.layer)y.zf();else{var ve=!1,ye=!1,Ce=this.ie,Ae=y.firstPickIndex+1;if(y.isOrthogonal){ye=!0;var Ye=y.pointsCount;4<Ye&&y.points.removeRange(2,Ye-3)}else if(y.curve===vh)ve=!0,Ye=y.pointsCount,4<Ye&&y.points.removeRange(2,Ye-3),Ye===4&&(Ae=2);else{Ye=y.pointsCount;var We=se===Ms,tt=oe===Ms;2<Ye&&We&&tt?y.points.removeRange(1,Ye-2):3<Ye&&We&&!tt?y.points.removeRange(1,Ye-3):3<Ye&&!We&&tt?y.points.removeRange(2,Ye-2):4<Ye&&!We&&!tt&&y.points.removeRange(2,Ye-3)}if(x.rev){for(;fe!==null&&ue!==fe;){var rt=Ye=null;for(We=fe.sourceEdges.iterator;We.next()&&(tt=We.value,tt.link!==x.link||(Ye=tt.fromVertex,rt=tt.toVertex,Ye.node!==null)););if(Ye===null)break;if(Ye!==ue){We=y.i(Ae-1).x,tt=y.i(Ae-1).y;var at=Ye.centerX,gt=Ye.centerY;if(ye)this.K===180||this.K===0?Ae===y.firstPickIndex+1?(y.m(Ae++,We,tt),y.m(Ae++,We,gt)):(rt!==null?rt.centerY:tt)!==gt&&(rt=this.Ta[Ye.layer-1]+this.Rf.x,y.m(Ae++,rt,tt),y.m(Ae++,rt,gt)):Ae===y.firstPickIndex+1?(y.m(Ae++,We,tt),y.m(Ae++,at,tt)):(rt!==null?rt.centerX:We)!==at&&(rt=this.Ta[Ye.layer-1]+this.Rf.y,y.m(Ae++,We,rt),y.m(Ae++,at,rt));else if(Ae===y.firstPickIndex+1){rt=Math.max(10,this.he[fe.layer]);var At=Math.max(10,this.Ld[fe.layer]);if(ve)this.K===180?at<=fe.bounds.x?(fe=fe.bounds.x,y.m(Ae++,fe-rt,gt),y.m(Ae++,fe,gt),y.m(Ae++,fe+At,gt)):(y.m(Ae++,at-rt,gt),y.m(Ae++,at,gt),y.m(Ae++,at+At,gt)):this.K===90?gt>=fe.bounds.bottom?(fe=fe.bounds.y+fe.bounds.height,y.m(Ae++,at,fe+At),y.m(Ae++,at,fe),y.m(Ae++,at,fe-rt)):(y.m(Ae++,at,gt+At),y.m(Ae++,at,gt),y.m(Ae++,at,gt-rt)):this.K===270?gt<=fe.bounds.y?(fe=fe.bounds.y,y.m(Ae++,at,fe-rt),y.m(Ae++,at,fe),y.m(Ae++,at,fe+At)):(y.m(Ae++,at,gt-rt),y.m(Ae++,at,gt),y.m(Ae++,at,gt+At)):this.K===0&&(at>=fe.bounds.right?(fe=fe.bounds.x+fe.bounds.width,y.m(Ae++,fe+At,gt),y.m(Ae++,fe,gt),y.m(Ae++,fe-rt,gt)):(y.m(Ae++,at+At,gt),y.m(Ae++,at,gt),y.m(Ae++,at-rt,gt)));else{y.m(Ae++,We,tt);var Zn=0;this.K===180||this.K===0?((this.K===180?at>=fe.bounds.right:at<=fe.bounds.x)&&(Zn=(this.K===0?-rt:At)/2),y.m(Ae++,We+Zn,gt)):((this.K===270?gt>=fe.bounds.bottom:gt<=fe.bounds.y)&&(Zn=(this.K===90?-rt:At)/2),y.m(Ae++,at,tt+Zn)),y.m(Ae++,at,gt)}}else rt=Math.max(10,this.he[Ye.layer]),At=Math.max(10,this.Ld[Ye.layer]),ve?this.K===180?(y.m(Ae++,at-rt-Ce,gt),y.m(Ae++,Math.min(at-rt+Ce/2,at),gt),y.m(Ae++,at,gt),y.m(Ae++,at,gt),y.m(Ae++,Math.max(at+At-Ce/2,at),gt),y.m(Ae++,at+At+Ce,gt)):this.K===90?(y.m(Ae++,at,gt+At+Ce),y.m(Ae++,at,Math.max(gt+At-Ce/2,gt)),y.m(Ae++,at,gt),y.m(Ae++,at,gt),y.m(Ae++,at,Math.min(gt-rt+Ce/2,gt)),y.m(Ae++,at,gt-rt-Ce)):this.K===270?(y.m(Ae++,at,gt-rt-Ce),y.m(Ae++,at,Math.min(gt-rt+Ce/2,gt)),y.m(Ae++,at,gt),y.m(Ae++,at,gt),y.m(Ae++,at,Math.max(gt+At-Ce/2,gt)),y.m(Ae++,at,gt+At+Ce)):(y.m(Ae++,at+At+Ce,gt),y.m(Ae++,Math.max(at+At-Ce/2,at),gt),y.m(Ae++,at,gt),y.m(Ae++,at,gt),y.m(Ae++,Math.min(at-rt+Ce/2,at),gt),y.m(Ae++,at-rt-Ce,gt)):y.m(Ae++,at,gt)}fe=Ye}(re===null||se!==Ms||ye)&&(We=y.i(Ae-1).x,tt=y.i(Ae-1).y,at=y.i(Ae).x,gt=y.i(Ae).y,ye?(Ce=this.Ld[ue.layer],this.K===180||this.K===0?(ye=tt,ye>=ue.bounds.y&&ye<=ue.bounds.bottom&&(this.K===180?at>=ue.bounds.x:at<=ue.bounds.right)&&(fe=ue.centerX+(this.K===180?-Ce:Ce),ye<ue.bounds.y+ue.bounds.height/2?ye=ue.bounds.y-this.kc/2:ye=ue.bounds.bottom+this.kc/2,y.m(Ae++,fe,tt),y.m(Ae++,fe,ye)),y.m(Ae++,at,ye)):(ye=We,ye>=ue.bounds.x&&ye<=ue.bounds.right&&(this.K===270?gt>=ue.bounds.y:gt<=ue.bounds.bottom)&&(fe=ue.centerY+(this.K===270?-Ce:Ce),ye<ue.bounds.x+ue.bounds.width/2?ye=ue.bounds.x-this.kc/2:ye=ue.bounds.right+this.kc/2,y.m(Ae++,We,fe),y.m(Ae++,ye,fe)),y.m(Ae++,ye,gt)),y.m(Ae++,at,gt)):ve?(rt=Math.max(10,this.he[ue.layer]),At=Math.max(10,this.Ld[ue.layer]),this.K===180&&at>=ue.bounds.x?(fe=ue.bounds.x+ue.bounds.width,y.L(Ae-2,fe,tt),y.L(Ae-1,fe+At,tt)):this.K===90&&gt<=ue.bounds.bottom?(fe=ue.bounds.y,y.L(Ae-2,We,fe),y.L(Ae-1,We,fe-rt)):this.K===270&&gt>=ue.bounds.y?(fe=ue.bounds.y+ue.bounds.height,y.L(Ae-2,We,fe),y.L(Ae-1,We,fe+At)):this.K===0&&at<=ue.bounds.right&&(fe=ue.bounds.x,y.L(Ae-2,fe,tt),y.L(Ae-1,fe-rt,tt))):(rt=Math.max(10,this.he[ue.layer]),At=Math.max(10,this.Ld[ue.layer]),ye=0,this.K===180||this.K===0?((this.K===180?at<=ue.bounds.x:at>=ue.bounds.right)&&(ye=(this.K===0?At:-rt)/2),y.m(Ae++,at+ye,tt)):((this.K===270?gt<=ue.bounds.y:gt>=ue.bounds.bottom)&&(ye=(this.K===90?At:-rt)/2),y.m(Ae++,We,gt+ye)),y.m(Ae++,at,gt)))}else{for(;ue!==null&&ue!==fe;){for(rt=Ye=null,ue=ue.destinationEdges.iterator;ue.next()&&(We=ue.value,We.link!==x.link||(Ye=We.toVertex,rt=We.fromVertex,rt.node!==null&&(rt=null),Ye.node!==null)););if(Ye===null)break;Ye!==fe&&(We=y.i(Ae-1).x,tt=y.i(Ae-1).y,at=Ye.centerX,gt=Ye.centerY,ye?this.K===180||this.K===0?(rt!==null?rt.centerY:tt)!==gt&&(rt=this.Ta[Ye.layer]+this.Rf.x,Ae===y.firstPickIndex+1&&(rt=this.K===0?Math.max(rt,We):Math.min(rt,We)),y.m(Ae++,rt,tt),y.m(Ae++,rt,gt)):(rt!==null?rt.centerX:We)!==at&&(rt=this.Ta[Ye.layer]+this.Rf.y,Ae===y.firstPickIndex+1&&(rt=this.K===90?Math.max(rt,tt):Math.min(rt,tt)),y.m(Ae++,We,rt),y.m(Ae++,at,rt)):(rt=Math.max(10,this.he[Ye.layer]),At=Math.max(10,this.Ld[Ye.layer]),ve?this.K===180?(y.m(Ae++,at+At+Ce,gt),y.m(Ae++,Math.max(at+At-Ce/2,at),gt),y.m(Ae++,at,gt),y.m(Ae++,at,gt),y.m(Ae++,Math.min(at-rt+Ce/2,at),gt),y.m(Ae++,at-rt-Ce,gt)):this.K===90?(y.m(Ae++,at,gt-rt-Ce),y.m(Ae++,at,Math.min(gt-rt+Ce/2,gt)),y.m(Ae++,at,gt),y.m(Ae++,at,gt),y.m(Ae++,at,Math.max(gt+At-Ce/2,gt)),y.m(Ae++,at,gt+At+Ce)):this.K===270?(y.m(Ae++,at,gt+At+Ce),y.m(Ae++,at,Math.max(gt+At-Ce/2,gt)),y.m(Ae++,at,gt),y.m(Ae++,at,gt),y.m(Ae++,at,Math.min(gt-rt+Ce/2,gt)),y.m(Ae++,at,gt-rt-Ce)):(y.m(Ae++,at-rt-Ce,gt),y.m(Ae++,Math.min(at-rt+Ce/2,at),gt),y.m(Ae++,at,gt),y.m(Ae++,at,gt),y.m(Ae++,Math.max(at+At-Ce/2,at),gt),y.m(Ae++,at+At+Ce,gt)):this.K===180?(y.m(Ae++,at+At,gt),y.m(Ae++,at-rt,gt)):this.K===90?(y.m(Ae++,at,gt-rt),y.m(Ae++,at,gt+At)):this.K===270?(y.m(Ae++,at,gt+At),y.m(Ae++,at,gt-rt)):(y.m(Ae++,at-rt,gt),y.m(Ae++,at+At,gt)))),ue=Ye}ye&&(We=y.i(Ae-1).x,tt=y.i(Ae-1).y,at=y.i(Ae).x,gt=y.i(Ae).y,this.K===180||this.K===0?tt!==gt&&(rt=this.K===0?Math.min(Math.max((at+We)/2,this.Ta[fe.layer]+this.Rf.x),at):Math.max(Math.min((at+We)/2,this.Ta[fe.layer]+this.Rf.x),at),y.m(Ae++,rt,tt),y.m(Ae++,rt,gt)):We!==at&&(rt=this.K===90?Math.min(Math.max((gt+tt)/2,this.Ta[fe.layer]+this.Rf.y),gt):Math.max(Math.min((gt+tt)/2,this.Ta[fe.layer]+this.Rf.y),gt),y.m(Ae++,We,rt),y.m(Ae++,at,rt)))}E!==null&&ve&&4<=y.pointsCount&&(ee!==null&&(ee=se===Ms?y.getLinkPointFromPoint(b,ee,ee.ga(ko),y.i(3),!0):y.i(0),se===Ms&&(se=y.i(2),E=y.i(3),this.direction===90||this.direction===270?(y.L(1,(ee.x+se.x)/2,se.y),y.L(2,E.x,(se.y+E.y)/2)):(y.L(1,se.x,(ee.y+se.y)/2),y.L(2,(se.x+E.x)/2,E.y))),ee.w()||ee.set(b.actualBounds.center),y.L(0,ee.x,ee.y)),re!==null&&(b=oe===Ms?y.getLinkPointFromPoint(z,re,re.ga(ko),y.i(y.pointsCount-4),!1):y.i(y.pointsCount-1),oe===Ms&&(re=y.i(y.pointsCount-3),oe=y.i(y.pointsCount-4),this.direction===90||this.direction===270?(y.L(y.pointsCount-2,(b.x+re.x)/2,re.y),y.L(y.pointsCount-2,oe.x,(re.y+oe.y)/2)):(y.L(y.pointsCount-2,re.x,(b.y+re.y)/2),y.L(y.pointsCount-3,(re.x+oe.x)/2,oe.y))),b.w()||b.set(z.actualBounds.center),y.L(y.pointsCount-1,b.x,b.y))),y.zf(),x.commit()}}}this.avoidOrthogonalOverlaps()},aa.prototype.avoidOrthogonalOverlaps=function(){if(!(0>=this.linkSpacing)){for(var a=new An,y=this.network.edges.iterator;y.next();){var x=y.value.link;x!==null&&x.isOrthogonal&&!a.contains(x)&&a.add(x)}if(0<a.count)if(this.K===90||this.K===270){for(y=0,x=[],a=a.iterator;a.next();){var E=a.value;if(E!==null&&E.isOrthogonal)for(var b=2;b<E.pointsCount-3;b++){var z=E.i(b),ee=E.i(b+1);if(this.B(z.y,ee.y)&&!this.B(z.x,ee.x)){var re=new tf;re.layer=Math.floor(z.y/2);var oe=E.i(0),se=E.i(E.pointsCount-1);if(re.first=oe.x*oe.x+oe.y,re.jc=se.x*se.x+se.y,re.rd=Math.min(z.x,ee.x),re.Ic=Math.max(z.x,ee.x),re.index=b,re.link=E,b+2<E.pointsCount){oe=E.i(b-1),se=E.i(b+2);var ue=0;oe.y<z.y?ue=se.y<z.y?3:z.x<ee.x?2:1:oe.y>z.y&&(ue=se.y>z.y?0:ee.x<z.x?2:1),re.j=ue}x.push(re)}}}if(1<x.length)for(x.sort(this.Vx),a=0;a<x.length;){for(z=x[a].layer,E=a+1;E<x.length&&x[E].layer===z;)E++;if(1<E-a)for(z=a;z<E;){for(ee=x[z].Ic,b=a+1;b<E&&x[b].rd<ee;)ee=Math.max(ee,x[b].Ic),b++;if(ee=b-z,1<ee){for(this.zi(x,this.Js,z,z+ee),ue=1,re=x[z].jc,oe=z;oe<b;oe++)se=x[oe],se.jc!==re&&(ue++,re=se.jc);this.zi(x,this.Ux,z,z+ee);var fe=1;for(re=x[z].first,oe=z;oe<b;oe++)se=x[oe],se.first!==re&&(fe++,re=se.first);for(oe=!0,se=fe,ue<fe?(oe=!1,se=ue,re=x[z].jc,this.zi(x,this.Js,z,z+ee)):re=x[z].first,ue=0,fe=z;fe<b;fe++){var ve=x[fe];(oe?ve.first:ve.jc)!==re&&(ue++,re=oe?ve.first:ve.jc);var ye=ve.link;z=ye.i(ve.index),ee=ye.i(ve.index+1);var Ce=this.linkSpacing*(ue-(se-1)/2);y++,ye.uh(),ye.L(ve.index,z.x,z.y+Ce),ye.L(ve.index+1,ee.x,ee.y+Ce),ye.zf()}}z=b}a=E}}else{for(y=0,x=[],a=a.iterator;a.next();)if(E=a.value,E!==null&&E.isOrthogonal)for(b=2;b<E.pointsCount-3;b++)z=E.i(b),ee=E.i(b+1),this.B(z.x,ee.x)&&!this.B(z.y,ee.y)&&(re=new tf,re.layer=Math.floor(z.x/2),oe=E.i(0),se=E.i(E.pointsCount-1),re.first=oe.x+oe.y*oe.y,re.jc=se.x+se.y*se.y,re.rd=Math.min(z.y,ee.y),re.Ic=Math.max(z.y,ee.y),re.index=b,re.link=E,b+2<E.pointsCount&&(oe=E.i(b-1),se=E.i(b+2),ue=0,oe.x<z.x?ue=se.x<z.x?3:z.y<ee.y?2:1:oe.x>z.x&&(ue=se.x>z.x?0:ee.y<z.y?2:1),re.j=ue),x.push(re));if(1<x.length)for(x.sort(this.Vx),a=0;a<x.length;){for(z=x[a].layer,E=a+1;E<x.length&&x[E].layer===z;)E++;if(1<E-a)for(z=a;z<E;){for(ee=x[z].Ic,b=a+1;b<E&&x[b].rd<ee;)ee=Math.max(ee,x[b].Ic),b++;if(ee=b-z,1<ee){for(this.zi(x,this.Js,z,z+ee),ue=1,re=x[z].jc,oe=z;oe<b;oe++)se=x[oe],se.jc!==re&&(ue++,re=se.jc);for(this.zi(x,this.Ux,z,z+ee),fe=1,re=x[z].first,oe=z;oe<b;oe++)se=x[oe],se.first!==re&&(fe++,re=se.first);for(oe=!0,se=fe,ue<fe?(oe=!1,se=ue,re=x[z].jc,this.zi(x,this.Js,z,z+ee)):re=x[z].first,ue=0,fe=z;fe<b;fe++)ve=x[fe],(oe?ve.first:ve.jc)!==re&&(ue++,re=oe?ve.first:ve.jc),ye=ve.link,z=ye.i(ve.index),ee=ye.i(ve.index+1),Ce=this.linkSpacing*(ue-(se-1)/2),y++,ye.uh(),ye.L(ve.index,z.x+Ce,z.y),ye.L(ve.index+1,ee.x+Ce,ee.y),ye.zf()}z=b}a=E}}}},we=aa.prototype,we.Vx=function(a,y){return a instanceof tf&&y instanceof tf&&a!==y?a.layer<y.layer?-1:a.layer>y.layer?1:a.rd<y.rd?-1:a.rd>y.rd?1:a.Ic<y.Ic?-1:a.Ic>y.Ic?1:0:0},we.Ux=function(a,y){return a instanceof tf&&y instanceof tf&&a!==y?a.first<y.first?-1:a.first>y.first||a.j<y.j?1:a.j>y.j||a.rd<y.rd?-1:a.rd>y.rd?1:a.Ic<y.Ic?-1:a.Ic>y.Ic?1:0:0},we.Js=function(a,y){return a instanceof tf&&y instanceof tf&&a!==y?a.jc<y.jc?-1:a.jc>y.jc||a.j<y.j?1:a.j>y.j||a.rd<y.rd?-1:a.rd>y.rd?1:a.Ic<y.Ic?-1:a.Ic>y.Ic?1:0:0},we.B=function(a,y){return a-=y,-1<a&&1>a},we.zi=function(a,y,x,E){var b=a.length,z=E-x;if(!(1>=z))if((0>x||x>=b-1)&&Dt("not in range 0 <= from < length: "+x),z===2)E=a[x],b=a[x+1],0<y(E,b)&&(a[x]=b,a[x+1]=E);else if(x===0)if(E>=b)a.sort(y);else for(x=a.slice(0,E),x.sort(y),y=0;y<E;y++)a[y]=x[y];else if(E>=b)for(E=a.slice(x),E.sort(y),y=x;y<b;y++)a[y]=E[y-x];else for(b=a.slice(x,E),b.sort(y),y=x;y<E;y++)a[y]=b[y-x]};function $d(a,y){var x=a.tc[y];if(x>=a.He.length){for(var E=[],b=0;b<a.He.length;b++)E[b]=a.He[b];a.He=E}for(a.He[x]===void 0||a.He[x]===null?E=[]:(E=a.He[x],a.He[x]=null),a=a.fl[y],y=0;y<a.length;y++)x=a[y],E[x.index]=x;return E}function ef(a,y,x){a.He[a.tc[y]]=x}Yt.Object.defineProperties(aa.prototype,{layerSpacing:{get:function(){return this.ie},set:function(a){this.ie!==a&&0<=a&&(this.ie=a,this.C())}},columnSpacing:{get:function(){return this.kc},set:function(a){this.kc!==a&&0<a&&(this.kc=a,this.C())}},direction:{get:function(){return this.K},set:function(a){this.K!==a&&(a===0||a===90||a===180||a===270?(this.K=a,this.C()):Dt("LayeredDigraphLayout.direction must be 0, 90, 180, or 270"))}},cycleRemoveOption:{get:function(){return this.Dk},set:function(a){this.Dk===a||a!==Sy&&a!==Fv&&a!==Up||(this.Dk=a,this.C())}},layeringOption:{get:function(){return this.Zk},set:function(a){this.Zk===a||a!==Av&&a!==xy&&a!==wy||(this.Zk=a,this.C())}},initializeOption:{get:function(){return this.Qk},set:function(a){this.Qk===a||a!==Nv&&a!==Py&&a!==Cy||(this.Qk=a,this.C())}},iterations:{get:function(){return this.bj},set:function(a){this.bj!==a&&0<=a&&(this.bj=a,this.C())}},aggressiveOption:{get:function(){return this.rk},set:function(a){this.rk===a||a!==Ey&&a!==Tv&&a!==by||(this.rk=a,this.C())}},packOption:{get:function(){return this.bg},set:function(a){this.bg!==a&&0<=a&&8>a&&(this.bg=a,this.C())}},alignOption:{get:function(){return this.ve},set:function(a){this.ve!==a&&0<=a&&16>a&&(this.ve=a,this.C())}},setsPortSpots:{get:function(){return this.sf},set:function(a){this.sf!==a&&(this.sf=a,this.C())}},linkSpacing:{get:function(){return this.Cn},set:function(a){this.Cn!==a&&0<=a&&(this.Cn=a,this.C())}},maxLayer:{get:function(){return this.Ia}},maxIndex:{get:function(){return this.Iq}},maxColumn:{get:function(){return this.Ra}},minIndexLayer:{get:function(){return this.Hn}},maxIndexLayer:{get:function(){return this.Md}}});var Fv=new Vt(aa,"CycleDepthFirst",0),Sy=new Vt(aa,"CycleGreedy",1),Up=new Vt(aa,"CycleFromLayers",2),Av=new Vt(aa,"LayerOptimalLinkLength",0),xy=new Vt(aa,"LayerLongestPathSink",1),wy=new Vt(aa,"LayerLongestPathSource",2),Nv=new Vt(aa,"InitDepthFirstOut",0),Py=new Vt(aa,"InitDepthFirstIn",1),Cy=new Vt(aa,"InitNaive",2),Ey=new Vt(aa,"AggressiveNone",0),Tv=new Vt(aa,"AggressiveLess",1),by=new Vt(aa,"AggressiveMore",2),_x=8;aa.className="LayeredDigraphLayout",aa.CycleDepthFirst=Fv,aa.CycleGreedy=Sy,aa.CycleFromLayers=Up,aa.LayerOptimalLinkLength=Av,aa.LayerLongestPathSink=xy,aa.LayerLongestPathSource=wy,aa.InitDepthFirstOut=Nv,aa.InitDepthFirstIn=Py,aa.InitNaive=Cy,aa.AggressiveNone=Ey,aa.AggressiveLess=Tv,aa.AggressiveMore=by,aa.PackNone=0,aa.PackExpand=1,aa.PackStraighten=2,aa.PackMedian=4,aa.PackAll=15,aa.AlignNone=0,aa.AlignUpperLeft=1,aa.AlignUpperRight=2,aa.AlignLowerLeft=4,aa.AlignLowerRight=8,aa.AlignAll=15;function tf(){this.index=this.Ic=this.rd=this.jc=this.first=this.layer=0,this.link=null,this.j=0}tf.className="SegInfo";function Hg(a){za.call(this,a)}Ct(Hg,za),Hg.prototype.createVertex=function(){return new Ih(this)},Hg.prototype.createEdge=function(){return new Zp(this)},Hg.className="LayeredDigraphNetwork";function Ih(a){$s.call(this,a),this.$n=this.bo=this.ao=this.co=null,this.Za=this.Ag=this.Ig=-1,this.u=NaN,this.F=null,this.valid=!1,this.finish=this.Ll=NaN,this.Dj=0,this.dv=this.ev=null}Ct(Ih,$s);function ix(a,y){return a.index-y.index}function Dv(a,y){if(!a.$n){for(var x=[],E=bn(a.destinationEdgesArrayAccess),b=E.next();!b.done;b=E.next())b=b.value,b.valid&&x.push(b);a.$n=x}for(a=bn(a.$n),x=a.next();!x.done;x=a.next())if(x=x.value,x.toVertex===y)return x;Dt("Unable to find destination edge to given vertex")}function Ly(a){if(!a.co){for(var y=[],x=bn(a.sourceEdgesArrayAccess),E=x.next();!E.done;E=x.next())E=E.value,E.valid&&y.push(E.fromVertex);y.sort(ix),a.co=y}return a.co}function Yx(a){if(!a.ao){for(var y=[],x=bn(a.destinationEdgesArrayAccess),E=x.next();!E.done;E=x.next())E=E.value,E.valid&&y.push(E.toVertex);y.sort(ix),a.ao=y}return a.ao}Ih.prototype.Cl=function(a){$s.prototype.Cl.call(this,a),this.bo=this.co=null},Ih.prototype.Kl=function(a){$s.prototype.Kl.call(this,a),this.bo=this.co=null},Ih.prototype.zl=function(a){$s.prototype.zl.call(this,a),this.$n=this.ao=null},Ih.prototype.Jl=function(a){$s.prototype.Jl.call(this,a),this.$n=this.ao=null},Yt.Object.defineProperties(Ih.prototype,{layer:{get:function(){return this.Ig},set:function(a){this.Ig!==a&&(this.Ig=a)}},column:{get:function(){return this.Ag},set:function(a){this.Ag!==a&&(this.Ag=a)}},index:{get:function(){return this.Za},set:function(a){this.Za!==a&&(this.Za=a)}},component:{get:function(){return this.u},set:function(a){this.u!==a&&(this.u=a)}},near:{get:function(){return this.F},set:function(a){this.F!==a&&(this.F=a)}}}),Ih.prototype.deleteDestinationEdge=Ih.prototype.Jl,Ih.prototype.addDestinationEdge=Ih.prototype.zl,Ih.prototype.deleteSourceEdge=Ih.prototype.Kl,Ih.prototype.addSourceEdge=Ih.prototype.Cl,Ih.className="LayeredDigraphVertex";function Zp(a){ih.call(this,a),this.j=this.ia=this.Ha=!1,this.V=this.u=NaN,this.F=this.o=0}Ct(Zp,ih),Yt.Object.defineProperties(Zp.prototype,{fromVertex:{get:function(){return this.kd},set:function(a){this.kd!==a&&(this.kd=a)}},toVertex:{get:function(){return this.qd},set:function(a){this.qd!==a&&(this.qd=a)}},valid:{get:function(){return this.Ha},set:function(a){this.Ha!==a&&(this.Ha=a)}},rev:{get:function(){return this.ia},set:function(a){this.ia!==a&&(this.ia=a)}},forest:{get:function(){return this.j},set:function(a){this.j!==a&&(this.j=a)}},portFromPos:{get:function(){return this.u},set:function(a){this.u!==a&&(this.u=a)}},portToPos:{get:function(){return this.V},set:function(a){this.V!==a&&(this.V=a)}},portFromColOffset:{get:function(){return this.o},set:function(a){this.o!==a&&(this.o=a)}},portToColOffset:{get:function(){return this.F},set:function(a){this.F!==a&&(this.F=a)}}}),Zp.className="LayeredDigraphEdge";function Qr(a){as.call(this),this.Ub=new Pn,this.Wn=Iv,this.ud=_c,this.vo=zv,this.Bq=Iy,this.$v=[],this.td=!0,this.Rb=Hv,this.$d=new fn(10,10).freeze();var y=new $f(this);this.W=new Xh(y),this.Y=new Xh(y),this.ru=[],a&&Object.assign(this,a)}Ct(Qr,as),Qr.prototype.cloneProtected=function(a){as.prototype.cloneProtected.call(this,a),a.Wn=this.Wn,a.vo=this.vo,a.Bq=this.Bq,a.td=this.td,a.Rb=this.Rb,a.$d.assign(this.$d),a.W.copyInheritedPropertiesFrom(this.W),a.Y.copyInheritedPropertiesFrom(this.Y)},Qr.prototype.qb=function(a){a.classType===Qr?a.name.indexOf("Alignment")===0?this.alignment=a:a.name.indexOf("Arrangement")===0?this.arrangement=a:a.name.indexOf("Compaction")===0?this.compaction=a:a.name.indexOf("Path")===0?this.path=a:a.name.indexOf("Sorting")===0?this.sorting=a:a.name.indexOf("Style")===0?this.treeStyle=a:Dt("Unknown enum value: "+a):as.prototype.qb.call(this,a)},Qr.prototype.createNetwork=function(){return new $f(this)},Qr.prototype.makeNetwork=function(a){function y(E){if(E instanceof qn)return!E.isLinkLabel&&E.category!=="Comment";if(E instanceof Tn){var b=E.fromNode;return b===null||b.isLinkLabel||b.category==="Comment"?!1:(E=E.toNode,!(E===null||E.isLinkLabel||E.category==="Comment"))}return!1}var x=this.createNetwork();return a instanceof bt?(x.lg(a.nodes,!0,y),x.lg(a.links,!0,y)):a instanceof xr?x.lg(a.memberParts,!1,y):x.lg(a.iterator,!1,y),x},Qr.prototype.doLayout=function(a){this.network===null&&(this.network=this.makeNetwork(a)),this.arrangement!==Gv&&(this.arrangementOrigin=this.initialOrigin(this.arrangementOrigin));var y=this.diagram;if(y===null&&a instanceof bt&&(y=a),this.path===Iv&&y!==null?this.ud=y.isTreePathToChildren?_c:Qf:this.ud=this.path===Iv?_c:this.path,0<this.network.vertexes.count){for(this.network.Ko(),a=this.network.vertexes.iterator;a.next();)y=a.value,y.initialized=!1,y.level=0,y.parent=null,y.children=[];if(0<this.Ub.count){for(a=new Pn,y=this.Ub.iterator;y.next();){var x=y.value;x instanceof qn?(x=this.network.ki(x),x!==null&&a.add(x)):x instanceof Xh&&a.add(x)}this.Ub=a}for(this.Ub.count===0&&this.findRoots(),a=this.Ub.copy().iterator;a.next();)y=a.value,y.initialized||(y.initialized=!0,My(this,y));for(y=this.network.vertexes,a=null;a=Xx(y),0<a.count;)y=rx(this,a),y!==null&&this.Ub.add(y),y.initialized=!0,My(this,y),y=a;for(a=this.Ub.iterator;a.next();)y=a.value,y instanceof Xh&&ax(this,y);for(a=this.Ub.iterator;a.next();)y=a.value,y instanceof Xh&&sx(this,y);for(a=this.Ub.iterator;a.next();)y=a.value,y instanceof Xh&&lx(this,y);if(this.Cu(),this.layerStyle===Kv){for(a=[],y=this.network.vertexes.iterator;y.next();){x=y.value;var E=x.parent;E===null&&(E=x),E=E.angle===0||E.angle===180;var b=a[x.level];b===void 0&&(b=0),a[x.level]=Math.max(b,E?x.width:x.height)}for(y=0;y<a.length;y++)a[y]===void 0&&(a[y]=0);for(this.$v=a,y=this.network.vertexes.iterator;y.next();)x=y.value,E=x.parent,E===null&&(E=x),E.angle===0||E.angle===180?(E.angle===180&&(x.focusX+=a[x.level]-x.width),x.width=a[x.level]):(E.angle===270&&(x.focusY+=a[x.level]-x.height),x.height=a[x.level])}else if(this.layerStyle===jy)for(a=this.network.vertexes.iterator;a.next();){for(y=a.value,x=y.angle===0||y.angle===180,E=-1,b=0;b<y.children.length;b++){var z=y.children[b];E=Math.max(E,x?z.width:z.height)}if(0<=E)for(b=0;b<y.children.length;b++)z=y.children[b],x?(y.angle===180&&(z.focusX+=E-z.width),z.width=E):(y.angle===270&&(z.focusY+=E-z.height),z.height=E)}for(a=this.Ub.iterator;a.next();)y=a.value,y instanceof Xh&&this.layoutTree(y);this.arrangeTrees(),this.updateParts()}this.network=null,this.Ub=new Pn,this.isValidLayout=!0};function Xx(a){var y=new Pn;for(a=a.iterator;a.next();){var x=a.value;x.initialized||y.add(x)}return y}Qr.prototype.findRoots=function(){for(var a=this.network.vertexes,y=a.iterator;y.next();){var x=y.value;switch(this.ud){case _c:x.sourceEdges.count===0&&this.Ub.add(x);break;case Qf:x.destinationEdges.count===0&&this.Ub.add(x);break;default:Dt("Unhandled path value "+this.ud.toString())}}this.Ub.count===0&&(a=rx(this,a),a!==null&&this.Ub.add(a))};function rx(a,y){var x=999999,E=null;for(y=y.iterator;y.next();){var b=y.value;switch(a.ud){case _c:b.sourceEdges.count<x&&(x=b.sourceEdges.count,E=b);break;case Qf:b.destinationEdges.count<x&&(x=b.destinationEdges.count,E=b);break;default:Dt("Unhandled path value "+a.ud.toString())}}return E}function My(a,y){if(y!==null){switch(a.ud){case _c:if(0<y.destinationEdges.count){for(var x=new An,E=y.destinationVertexes;E.next();){var b=E.value;ox(a,y,b)&&x.add(b)}0<x.count&&(y.children=x.Fa())}break;case Qf:if(0<y.sourceEdges.count){for(x=new An,E=y.sourceVertexes;E.next();)b=E.value,ox(a,y,b)&&x.add(b);0<x.count&&(y.children=x.Fa())}break;default:Dt("Unhandled path value"+a.ud.toString())}for(x=y.children,E=x.length,b=0;b<E;b++){var z=x[b];z.initialized=!0,z.level=y.level+1,z.parent=y,a.Ub.remove(z)}for(y=0;y<E;y++)My(a,x[y])}}function ox(a,y,x){if(x.initialized){if(y===null)var E=!1;else{for(E=y.parent;E!==null&&E!==x;)E=E.parent;E=E===x}if(E||x.level>y.level)return!1;a.removeChild(x.parent,x)}return!0}Qr.prototype.removeChild=function(a,y){if(a!==null&&y!==null){for(var x=a.children,E=0,b=0;b<x.length;b++)x[b]===y&&E++;if(0<E){E=Array(x.length-E);for(var z=b=0;z<x.length;z++)x[z]!==y&&(E[b++]=x[z]);a.children=E}}};function ax(a,y){if(y!==null){a.initializeTreeVertexValues(y),y.alignment===Jc&&a.sortTreeVertexChildren(y);for(var x=0,E=y.childrenCount,b=0,z=y.children,ee=z.length,re=0;re<ee;re++){var oe=z[re];ax(a,oe),x+=oe.descendantCount+1,E=Math.max(E,oe.maxChildrenCount),b=Math.max(b,oe.maxGenerationCount)}y.descendantCount=x,y.maxChildrenCount=E,y.maxGenerationCount=0<E?b+1:0}}function Jx(a,y){switch(a.vo){default:case zv:return y.parent!==null?y.parent:a.W;case Oy:return y.parent===null?a.W:y.parent.parent===null?a.Y:y.parent;case By:return y.parent!==null?y.parent.parent!==null?y.parent.parent:a.Y:a.W;case Dy:var x=!0;if(y.childrenCount===0)x=!1;else for(var E=y.children,b=E.length,z=0;z<b;z++)if(0<E[z].childrenCount){x=!1;break}return x&&y.parent!==null?a.Y:y.parent!==null?y.parent:a.W}}Qr.prototype.initializeTreeVertexValues=function(a){if(a.copyInheritedPropertiesFrom(Jx(this,a)),a.parent!==null&&a.parent.alignment===Jc){for(var y=a.angle,x=a.parent.children,E=0;E<x.length&&a!==x[E];)E++;E%2===0?E!==x.length-1&&(y=y===90?180:y===180?270:y===270?180:270):y=y===90?0:y===180?90:y===270?0:90,a.angle=y}a.initialized=!0};function sx(a,y){if(y!==null){a.assignTreeVertexValues(y),y=y.children;for(var x=y.length,E=0;E<x;E++)sx(a,y[E])}}Qr.prototype.assignTreeVertexValues=function(){};function lx(a,y){if(y!==null){y.alignment!==Jc&&a.sortTreeVertexChildren(y),y=y.children;for(var x=y.length,E=0;E<x;E++)lx(a,y[E])}}Qr.prototype.sortTreeVertexChildren=function(a){switch(a.sorting){case Gg:break;case Yp:a.children.reverse();break;case Xp:a.children.sort(a.comparer);break;case Jp:a.children.sort(a.comparer),a.children.reverse();break;default:Dt("Unhandled sorting value "+a.sorting.toString())}},Qr.prototype.Cu=function(){if(this.comments)for(var a=this.network.vertexes.iterator;a.next();)this.addComments(a.value)},Qr.prototype.addComments=function(a){var y=a.angle,x=a.parent,E=0,b=!1;x!==null&&(E=x.angle,b=x.alignment,b=nf(b)),y=y===90||y===270,E=E===90||E===270,x=a.childrenCount===0;var z=0,ee=0,re=0,oe=a.commentSpacing;if(a.node!==null)for(var se=a.node.Mu();se.next();){var ue=se.value;ue.category==="Comment"&&ue.canLayout()&&(a.comments===null&&(a.comments=[]),a.comments.push(ue),ue.Va(),ue=ue.measuredBounds,y&&!x||!b&&!E&&x||b&&E&&x?(z=Math.max(z,ue.width),ee+=ue.height+Math.abs(re)):(z+=ue.width+Math.abs(re),ee=Math.max(ee,ue.height)),re=oe)}a.comments!==null&&(y&&!x||!b&&!E&&x||b&&E&&x?(z+=Math.abs(a.commentMargin),ee=Math.max(0,ee-a.height)):(ee+=Math.abs(a.commentMargin),z=Math.max(0,z-a.width)),b=Xt.allocAt(0,0,a.bounds.width+z,a.bounds.height+ee),a.bounds=b,Xt.free(b))};function nf(a){return a===Fd||a===Jc||a===Ad||a===ld}function _p(a){return a===Fd||a===Jc}function ky(a){var y=a.parent;if(y!==null){var x=y.alignment;if(nf(x)){if(_p(x)){for(y=y.children,x=0;x<y.length&&a!==y[x];)x++;return x%2===0}if(x===Ad)return!0}}return!1}Qr.prototype.layoutComments=function(a){if(a.comments!==null){var y=a.node.measuredBounds,x=a.parent,E=a.angle,b=0,z=!1;x!==null&&(b=x.angle,z=x.alignment,z=nf(z)),E=E===90||E===270,x=b===90||b===270;for(var ee=a.childrenCount===0,re=ky(a),oe=0,se=a.comments,ue=se.length,fe=Qe.alloc(),ve=0;ve<ue;ve++){var ye=se[ve],Ce=ye.measuredBounds;if(E&&!ee||!z&&!x&&ee||z&&x&&ee){if(135<b&&!z||x&&re)if(0<=a.commentMargin)for(fe.h(a.bounds.x-a.commentMargin-Ce.width,a.bounds.y+oe),ye.move(fe),ye=ye.Sd();ye.next();){var Ae=ye.value;Ae.fromSpot=ol,Ae.toSpot=Rs}else for(fe.h(a.bounds.x+2*a.focus.x-a.commentMargin,a.bounds.y+oe),ye.move(fe),ye=ye.Sd();ye.next();)Ae=ye.value,Ae.fromSpot=Rs,Ae.toSpot=ol;else if(0<=a.commentMargin)for(fe.h(a.bounds.x+2*a.focus.x+a.commentMargin,a.bounds.y+oe),ye.move(fe),ye=ye.Sd();ye.next();)Ae=ye.value,Ae.fromSpot=Rs,Ae.toSpot=ol;else for(fe.h(a.bounds.x+a.commentMargin-Ce.width,a.bounds.y+oe),ye.move(fe),ye=ye.Sd();ye.next();)Ae=ye.value,Ae.fromSpot=ol,Ae.toSpot=Rs;oe=0<=a.commentSpacing?oe+(Ce.height+a.commentSpacing):oe+(a.commentSpacing-Ce.height)}else{if(135<b&&!z||!x&&re)if(0<=a.commentMargin)for(fe.h(a.bounds.x+oe,a.bounds.y-a.commentMargin-Ce.height),ye.move(fe),ye=ye.Sd();ye.next();)Ae=ye.value,Ae.fromSpot=Ml,Ae.toSpot=Us;else for(fe.h(a.bounds.x+oe,a.bounds.y+2*a.focus.y-a.commentMargin),ye.move(fe),ye=ye.Sd();ye.next();)Ae=ye.value,Ae.fromSpot=Us,Ae.toSpot=Ml;else if(0<=a.commentMargin)for(fe.h(a.bounds.x+oe,a.bounds.y+2*a.focus.y+a.commentMargin),ye.move(fe),ye=ye.Sd();ye.next();)Ae=ye.value,Ae.fromSpot=Us,Ae.toSpot=Ml;else for(fe.h(a.bounds.x+oe,a.bounds.y+a.commentMargin-Ce.height),ye.move(fe),ye=ye.Sd();ye.next();)Ae=ye.value,Ae.fromSpot=Ml,Ae.toSpot=Us;oe=0<=a.commentSpacing?oe+(Ce.width+a.commentSpacing):oe+(a.commentSpacing-Ce.width)}}if(Qe.free(fe),y=oe-a.commentSpacing-(E?y.height:y.width),this.ud===_c)for(a=a.destinationEdges;a.next();)b=a.value.link,b===null||b.isAvoiding||(b.fromEndSegmentLength=0<y?y:NaN);else for(a=a.sourceEdges;a.next();)b=a.value.link,b===null||b.isAvoiding||(b.toEndSegmentLength=0<y?y:NaN)}},Qr.prototype.layoutTree=function(a){if(a!==null){for(var y=a.children,x=y.length,E=0;E<x;E++)this.layoutTree(y[E]);switch(a.compaction){case jv:ux(this,a);break;case Qp:if(a.alignment===Jc)ux(this,a);else if(a.childrenCount===0)E=a.parent,x=!1,y=0,E!==null&&(y=E.angle,x=E.alignment,x=nf(x)),E=ky(a),a.S.h(0,0),a.Da.h(a.width,a.height),a.parent===null||a.comments===null||(y!==180&&y!==270||x)&&!E?a.la.h(0,0):y===180&&!x||(y===90||y===270)&&E?a.la.h(a.width-2*a.focus.x,0):a.la.h(0,a.height-2*a.focus.y),a.Yo=null,a.kp=null;else{var b=uc(a);y=b===90||b===270;var z=0,ee=a.children,re=ee.length;for(x=0;x<re;x++)E=ee[x],z=Math.max(z,y?E.Da.width:E.Da.height);var oe=a.alignment;E=oe===Yc;var se=oe===Xc,ue=nf(oe),fe=Math.max(0,a.breadthLimit);x=this.computeLayerSpacing(a);var ve=a.nodeSpacing,ye=this.computeNodeIndent(a),Ce=a.rowSpacing,Ae=0;(E||se||a.hm||a.im&&a.maxGenerationCount===1)&&(Ae=Math.max(0,a.rowIndent)),E=a.width;var Ye=a.height,We=0,tt=0,rt=0,at=null,gt=null,At=0,Zn=0,mi=0,si=0,Nn=0,pn=0,yr=0,sr=0;if(ue&&!_p(oe)&&135<b&&ee.reverse(),_p(oe))if(1<re)for(var Io=0;Io<re;Io++)Io%2===0&&Io!==re-1&&(sr=Math.max(sr,y?ee[Io].Da.width:ee[Io].Da.height));else re===1&&(sr=y?ee[0].Da.width:ee[0].Da.height);if(ue){switch(oe){case Fd:tt=135>b?hx(this,a,ee,sr,We,tt):cx(this,a,ee,sr,We,tt),sr=tt.x,We=tt.width,tt=tt.height;break;case Ad:for(at=0;at<re;at++)gt=ee[at],fe=gt.Da,rt=pn===0?0:Ce,y?(gt.S.h(z-fe.width,si+rt),We=Math.max(We,fe.width),tt=Math.max(tt,si+rt+fe.height),si+=rt+fe.height):(gt.S.h(mi+rt,z-fe.height),We=Math.max(We,mi+rt+fe.width),tt=Math.max(tt,fe.height),mi+=rt+fe.width),pn++;break;case ld:for(at=0;at<re;at++)gt=ee[at],z=gt.Da,fe=pn===0?0:Ce,y?(gt.S.h(ve/2+a.focus.x,si+fe),We=Math.max(We,z.width),tt=Math.max(tt,si+fe+z.height),si+=fe+z.height):(gt.S.h(mi+fe,ve/2+a.focus.y),We=Math.max(We,mi+fe+z.width),tt=Math.max(tt,z.height),mi+=fe+z.width),pn++}at=Vu(this,2),gt=Vu(this,2),y?(at[0].h(0,0),at[1].h(0,tt),gt[0].h(We,0)):(at[0].h(0,0),at[1].h(We,0),gt[0].h(0,tt)),gt[1].h(We,tt)}else for(Io=0;Io<re;Io++){var Oa=ee[Io],gl=Oa.Da;if(y){0<fe&&0<pn&&mi+ve+gl.width>fe&&(mi<z&&Lf(a,oe,z-mi,0,yr,Io-1),Nn++,pn=0,yr=Io,rt=tt,mi=0,si=135<b?-tt-Ce:tt+Ce),Ov(this,Oa,0,si);var wl=0;if(pn===0)at=Oa.Yo,gt=Oa.kp,At=gl.width,Zn=gl.height,(at===null||gt===null||b!==uc(Oa))&&(at=Vu(this,2),gt=Vu(this,2),at[0].h(0,0),at[1].h(0,Zn),gt[0].h(At,0),gt[1].h(At,Zn));else{var hu=qi();Zn=dx(this,a,Oa,at,gt,At,Zn,hu),wl=Zn.x,at=hu[0],gt=hu[1],At=Zn.width,Zn=Zn.height,Zi(hu),mi<gl.width&&0>wl&&(Jf(a,-wl,0,yr,Io-1),Rv(at,-wl,0),Rv(gt,-wl,0),wl=0)}Oa.S.h(wl,si),We=Math.max(We,At),tt=Math.max(tt,rt+(Nn===0?0:Ce)+gl.height),mi=At}else 0<fe&&0<pn&&si+ve+gl.height>fe&&(si<z&&Lf(a,oe,0,z-si,yr,Io-1),Nn++,pn=0,yr=Io,rt=We,si=0,mi=135<b?-We-Ce:We+Ce),Ov(this,Oa,mi,0),wl=0,pn===0?(at=Oa.Yo,gt=Oa.kp,At=gl.width,Zn=gl.height,(at===null||gt===null||b!==uc(Oa))&&(at=Vu(this,2),gt=Vu(this,2),at[0].h(0,0),at[1].h(At,0),gt[0].h(0,Zn),gt[1].h(At,Zn))):(hu=qi(),Zn=dx(this,a,Oa,at,gt,At,Zn,hu),wl=Zn.x,at=hu[0],gt=hu[1],At=Zn.width,Zn=Zn.height,Zi(hu),si<gl.height&&0>wl&&(Jf(a,0,-wl,yr,Io-1),Rv(at,0,-wl),Rv(gt,0,-wl),wl=0)),Oa.S.h(mi,wl),tt=Math.max(tt,Zn),We=Math.max(We,rt+(Nn===0?0:Ce)+gl.width),si=Zn;pn++}switch(0<Nn&&(y?(tt+=Math.max(0,x),mi<We&&Lf(a,oe,We-mi,0,yr,re-1),0<Ae&&(se||Jf(a,Ae,0,0,re-1),We+=Ae)):(We+=Math.max(0,x),si<tt&&Lf(a,oe,0,tt-si,yr,re-1),0<Ae&&(se||Jf(a,0,Ae,0,re-1),tt+=Ae))),Ae=se=0,oe){case Kg:y?se+=We/2-a.focus.x-ye/2:Ae+=tt/2-a.focus.y-ye/2;break;case qf:0<Nn?y?se+=We/2-a.focus.x-ye/2:Ae+=tt/2-a.focus.y-ye/2:y?(sr=ee[0].S.x+ee[0].la.x,se+=sr+(ee[re-1].S.x+ee[re-1].la.x+2*ee[re-1].focus.x-sr)/2-a.focus.x-ye/2):(sr=ee[0].S.y+ee[0].la.y,Ae+=sr+(ee[re-1].S.y+ee[re-1].la.y+2*ee[re-1].focus.y-sr)/2-a.focus.y-ye/2);break;case Yc:y?(se-=ye,We+=ye):(Ae-=ye,tt+=ye);break;case Xc:y?(se+=We-a.width+ye,We+=ye):(Ae+=tt-a.height+ye,tt+=ye);break;case Fd:y?1<re?se+=sr+ve/2-a.focus.x:se+=ee[0].focus.x-a.focus.x+ee[0].la.x:1<re?Ae+=sr+ve/2-a.focus.y:Ae+=ee[0].focus.y-a.focus.y+ee[0].la.y;break;case Ad:y?se+=We+ve/2-a.focus.x:Ae+=tt+ve/2-a.focus.y;break;case ld:break;default:tt=this.customAlignment(a,se,Ae,We,tt),se=tt[0],Ae=tt[1],We=tt[2],tt=tt[3]}for(ye=0;ye<re;ye++)sr=ee[ye],y?sr.S.h(sr.S.x+sr.la.x-se,sr.S.y+(135<b?(ue?-tt:-sr.Da.height)+sr.la.y-x:Ye+x+sr.la.y)):sr.S.h(sr.S.x+(135<b?(ue?-We:-sr.Da.width)+sr.la.x-x:E+x+sr.la.x),sr.S.y+sr.la.y-Ae);if(re=ee=0,ue?y?(We=Fy(a,We,se),0>se&&(se=0),135<b&&(Ae+=tt+x),tt+=Ye+x,oe===ld&&(ee+=ve/2+a.focus.x),re+=Ye+x):(135<b&&(se+=We+x),We+=E+x,tt=Ay(a,tt,Ae),0>Ae&&(Ae=0),oe===ld&&(re+=ve/2+a.focus.y),ee+=E+x):y?(a.comments===null?E>We&&(We=Ny(oe,E-We,0),ee=We.x,re=We.y,We=E,se=0):We=Fy(a,We,se),0>se&&(ee-=se,se=0),135<b&&(Ae+=tt+x),tt=Math.max(Math.max(tt,Ye),tt+Ye+x),re+=Ye+x):(135<b&&(se+=We+x),We=Math.max(Math.max(We,E),We+E+x),a.comments===null?Ye>tt&&(tt=Ny(oe,0,Ye-tt),ee=tt.x,re=tt.y,tt=Ye,Ae=0):tt=Ay(a,tt,Ae),0>Ae&&(re-=Ae,Ae=0),ee+=E+x),0<Nn)b=Vu(this,4),Nn=Vu(this,4),y?(b[2].h(0,Ye+x),b[3].h(b[2].x,tt),Nn[2].h(We,b[2].y),Nn[3].h(Nn[2].x,b[3].y)):(b[2].h(E+x,0),b[3].h(We,b[2].y),Nn[2].h(b[2].x,tt),Nn[3].h(b[3].x,Nn[2].y));else{for(b=Vu(this,at.length+2),Nn=Vu(this,gt.length+2),oe=0;oe<at.length;oe++)ue=at[oe],b[oe+2].h(ue.x+ee,ue.y+re);for(oe=0;oe<gt.length;oe++)ue=gt[oe],Nn[oe+2].h(ue.x+ee,ue.y+re)}y?(b[0].h(se,0),b[1].h(b[0].x,Ye),b[2].y<b[1].y&&(b[2].x>b[0].x?b[2].assign(b[1]):b[1].assign(b[2])),b[3].y<b[2].y&&(b[3].x>b[0].x?b[3].assign(b[2]):b[2].assign(b[3])),Nn[0].h(se+E,0),Nn[1].h(Nn[0].x,Ye),Nn[2].y<Nn[1].y&&(Nn[2].x<Nn[0].x?Nn[2].assign(Nn[1]):Nn[1].assign(Nn[2])),Nn[3].y<Nn[2].y&&(Nn[3].x<Nn[0].x?Nn[3].assign(Nn[2]):Nn[2].assign(Nn[3])),b[2].y-=x/2,Nn[2].y-=x/2):(b[0].h(0,Ae),b[1].h(E,b[0].y),b[2].x<b[1].x&&(b[2].y>b[0].y?b[2].assign(b[1]):b[1].assign(b[2])),b[3].x<b[2].x&&(b[3].y>b[0].y?b[3].assign(b[2]):b[2].assign(b[3])),Nn[0].h(0,Ae+Ye),Nn[1].h(E,Nn[0].y),Nn[2].x<Nn[1].x&&(Nn[2].y<Nn[0].y?Nn[2].assign(Nn[1]):Nn[1].assign(Nn[2])),Nn[3].x<Nn[2].x&&(Nn[3].y<Nn[0].y?Nn[3].assign(Nn[2]):Nn[2].assign(Nn[3])),b[2].x-=x/2,Nn[2].x-=x/2),yc(this,at),yc(this,gt),a.Yo=b,a.kp=Nn,a.la.h(se,Ae),a.Da.h(We,tt)}break;default:Dt("Unhandled compaction value "+a.compaction.toString())}}};function ux(a,y){if(y.childrenCount===0){var x=!1,E=0;y.parent!==null&&(E=y.parent.angle,x=y.parent.alignment,x=nf(x));var b=ky(y);y.S.h(0,0),y.Da.h(y.width,y.height),y.parent===null||y.comments===null||(E!==180&&E!==270||x)&&!b?y.la.h(0,0):E===180&&!x||(E===90||E===270)&&b?y.la.h(y.width-2*y.focus.x,0):y.la.h(0,y.height-2*y.focus.y)}else{E=uc(y),x=E===90||E===270;var z=0;b=y.children;for(var ee=b.length,re=0;re<ee;re++){var oe=b[re];z=Math.max(z,x?oe.Da.width:oe.Da.height)}var se=y.alignment,ue=se===Yc,fe=se===Xc;re=nf(se);var ve=Math.max(0,y.breadthLimit);oe=a.computeLayerSpacing(y);var ye=y.nodeSpacing,Ce=a.computeNodeIndent(y),Ae=ue||fe?0:Ce/2,Ye=y.rowSpacing,We=0;(ue||fe||y.hm||y.im&&y.maxGenerationCount===1)&&(We=Math.max(0,y.rowIndent)),ue=y.width;var tt=y.height,rt=0,at=0,gt=0,At=0,Zn=0,mi=0,si=0,Nn=0,pn=0,yr=0;if(re&&!_p(se)&&135<E&&b.reverse(),_p(se))if(1<ee)for(var sr=0;sr<ee;sr++){var Io=b[sr],Oa=Io.Da;sr%2===0&&sr!==ee-1?pn=Math.max(pn,(x?Oa.width:Oa.height)+a.computeBusNodeSpacing(Io)-ye):sr%2!==0&&(yr=Math.max(yr,(x?Oa.width:Oa.height)+a.computeBusNodeSpacing(Io)-ye))}else ee===1&&(pn=x?b[0].Da.width:b[0].Da.height);if(re)switch(se){case Fd:case Jc:at=135>E?hx(a,y,b,pn,rt,at):cx(a,y,b,pn,rt,at),pn=at.x,rt=at.width,at=at.height;break;case Ad:for(ve=0;ve<ee;ve++)Ae=b[ve],gt=Ae.Da,yr=si===0?0:Ye,x?(Ae.S.h(z-gt.width,Zn+yr),rt=Math.max(rt,gt.width),at=Math.max(at,Zn+yr+gt.height),Zn+=yr+gt.height):(Ae.S.h(At+yr,z-gt.height),rt=Math.max(rt,At+yr+gt.width),at=Math.max(at,gt.height),At+=yr+gt.width),si++;break;case ld:for(z=0;z<ee;z++)ve=b[z],Ae=ve.Da,gt=si===0?0:Ye,x?(ve.S.h(ye/2+y.focus.x,Zn+gt),rt=Math.max(rt,Ae.width),at=Math.max(at,Zn+gt+Ae.height),Zn+=gt+Ae.height):(ve.S.h(At+gt,ye/2+y.focus.y),rt=Math.max(rt,At+gt+Ae.width),at=Math.max(at,Ae.height),At+=gt+Ae.width),si++}else for(yr=0;yr<ee;yr++)sr=b[yr],Io=sr.Da,x?(0<ve&&0<si&&At+ye+Io.width>ve&&(At<z&&Lf(y,se,z-At,0,Nn,yr-1),mi++,si=0,Nn=yr,gt=at,At=0,Zn=135<E?-at-Ye:at+Ye),Oa=si===0?Ae:ye,Ov(a,sr,0,Zn),sr.S.h(At+Oa,Zn),rt=Math.max(rt,At+Oa+Io.width),at=Math.max(at,gt+(mi===0?0:Ye)+Io.height),At+=Oa+Io.width):(0<ve&&0<si&&Zn+ye+Io.height>ve&&(Zn<z&&Lf(y,se,0,z-Zn,Nn,yr-1),mi++,si=0,Nn=yr,gt=rt,Zn=0,At=135<E?-rt-Ye:rt+Ye),Oa=si===0?Ae:ye,Ov(a,sr,At,0),sr.S.h(At,Zn+Oa),at=Math.max(at,Zn+Oa+Io.height),rt=Math.max(rt,gt+(mi===0?0:Ye)+Io.width),Zn+=Oa+Io.height),si++;switch(0<mi&&(x?(at+=Math.max(0,oe),At<rt&&Lf(y,se,rt-At,0,Nn,ee-1),0<We&&(fe||Jf(y,We,0,0,ee-1),rt+=We)):(rt+=Math.max(0,oe),Zn<at&&Lf(y,se,0,at-Zn,Nn,ee-1),0<We&&(fe||Jf(y,0,We,0,ee-1),at+=We))),We=fe=0,se){case Kg:x?fe+=rt/2-y.focus.x-Ce/2:We+=at/2-y.focus.y-Ce/2;break;case qf:0<mi?x?fe+=rt/2-y.focus.x-Ce/2:We+=at/2-y.focus.y-Ce/2:x?(a=b[0].S.x+b[0].la.x,fe+=a+(b[ee-1].S.x+b[ee-1].la.x+2*b[ee-1].focus.x-a)/2-y.focus.x-Ce/2):(a=b[0].S.y+b[0].la.y,We+=a+(b[ee-1].S.y+b[ee-1].la.y+2*b[ee-1].focus.y-a)/2-y.focus.y-Ce/2);break;case Yc:x?(fe-=Ce,rt+=Ce):(We-=Ce,at+=Ce);break;case Xc:x?(fe+=rt-y.width+Ce,rt+=Ce):(We+=at-y.height+Ce,at+=Ce);break;case Fd:case Jc:x?1<ee?fe+=pn+ye/2-y.focus.x:fe+=b[0].focus.x-y.focus.x+b[0].la.x:1<ee?We+=pn+ye/2-y.focus.y:We+=b[0].focus.y-y.focus.y+b[0].la.y;break;case Ad:x?fe+=rt+ye/2-y.focus.x:We+=at+ye/2-y.focus.y;break;case ld:break;default:a=a.customAlignment(y,fe,We,rt,at),fe=a[0],We=a[1],rt=a[2],at=a[3]}for(a=0;a<ee;a++)Ce=b[a],x?Ce.S.h(Ce.S.x+Ce.la.x-fe,Ce.S.y+(135<E?(re?-at:-Ce.Da.height)+Ce.la.y-oe:tt+oe+Ce.la.y)):Ce.S.h(Ce.S.x+(135<E?(re?-rt:-Ce.Da.width)+Ce.la.x-oe:ue+oe+Ce.la.x),Ce.S.y+Ce.la.y-We);x?(rt=Fy(y,rt,fe),0>fe&&(fe=0),135<E&&(We+=at+oe),at=Math.max(Math.max(at,tt),at+tt+oe)):(135<E&&(fe+=rt+oe),rt=Math.max(Math.max(rt,ue),rt+ue+oe),at=Ay(y,at,We),0>We&&(We=0)),y.la.h(fe,We),y.Da.h(rt,at)}}Qr.prototype.customAlignment=function(a,y,x,E,b){return[y,x,E,b]};function hx(a,y,x,E,b,z){var ee=x.length;if(ee===0)return new Xt(E,0,b,z);if(ee===1)return y=x[0],b=y.Da.width,z=y.Da.height,new Xt(E,0,b,z);for(var re=y.nodeSpacing,oe=y.rowSpacing,se=uc(y)===90,ue=0,fe=0,ve=0,ye=0;ye<ee;ye++)if(!(ye%2!==0||1<ee&&ye===ee-1)){var Ce=x[ye],Ae=Ce.Da,Ye=ue===0?0:oe;if(se){var We=a.computeBusNodeSpacing(Ce)-re;Ce.S.h(E-(Ae.width+We),ve+Ye),b=Math.max(b,Ae.width+We),z=Math.max(z,ve+Ye+Ae.height),ve+=Ye+Ae.height}else We=a.computeBusNodeSpacing(Ce)-re,Ce.S.h(fe+Ye,E-(Ae.height+We)),z=Math.max(z,Ae.height+We),b=Math.max(b,fe+Ye+Ae.width),fe+=Ye+Ae.width;ue++}for(ue=0,Ce=fe,ye=ve,se?(fe=E+re,ve=0):(fe=0,ve=E+re),Ae=0;Ae<ee;Ae++)if(Ae%2!==0){Ye=x[Ae],We=Ye.Da;var tt=ue===0?0:oe;if(se){var rt=a.computeBusNodeSpacing(Ye)-re;Ye.S.h(fe+rt,ve+tt),b=Math.max(b,fe+We.width+rt),z=Math.max(z,ve+tt+We.height),ve+=tt+We.height}else rt=a.computeBusNodeSpacing(Ye)-re,Ye.S.h(fe+tt,ve+rt),b=Math.max(b,fe+tt+We.width),z=Math.max(z,ve+We.height+rt),fe+=tt+We.width;ue++}return 1<ee&&ee%2===1&&(x=x[ee-1],ee=x.Da,a=a.computeBusLastRowSpacing(x,se?Math.max(Math.abs(ye),Math.abs(ve)):Math.max(Math.abs(Ce),Math.abs(fe))),se?(x.S.h(E+re/2-x.focus.x-x.la.x,z+a),se=E+re/2-x.focus.x-x.la.x,b=Math.max(b,se+ee.width),0>se&&(b-=se),z=Math.max(z,Math.max(ye,ve)+a+ee.height),0>x.S.x&&(E=Bv(y,x.S.x,!1,E,re))):(x.S.h(b+a,E+re/2-x.focus.y-x.la.y),b=Math.max(b,Math.max(Ce,fe)+a+ee.width),ve=E+re/2-x.focus.y-x.la.y,z=Math.max(z,ve+ee.height),0>ve&&(z-=ve),0>x.S.y&&(E=Bv(y,x.S.y,!0,E,re)))),new Xt(E,0,b,z)}function cx(a,y,x,E,b,z){var ee=x.length;if(ee===0)return new Xt(E,0,b,z);if(ee===1)return x=x[0],b=x.Da.width,z=x.Da.height,new Xt(E,0,b,z);for(var re=y.nodeSpacing,oe=y.rowSpacing,se=uc(y)===270,ue=0,fe=0,ve=0,ye=0;ye<ee;ye++)if(!(ye%2!==0||1<ee&&ye===ee-1)){var Ce=x[ye],Ae=Ce.Da,Ye=ue===0?0:oe;if(se){var We=a.computeBusNodeSpacing(Ce)-re;ve-=Ye+Ae.height,Ce.S.h(E-(Ae.width+We),ve),b=Math.max(b,Ae.width+We),z=Math.max(z,Math.abs(ve))}else We=a.computeBusNodeSpacing(Ce)-re,fe-=Ye+Ae.width,Ce.S.h(fe,E-(Ae.height+We)),z=Math.max(z,Ae.height+We),b=Math.max(b,Math.abs(fe));ue++}for(ue=0,Ce=fe,ye=ve,se?(fe=E+re,ve=0):(fe=0,ve=E+re),Ae=0;Ae<ee;Ae++)if(Ae%2!==0){Ye=x[Ae],We=Ye.Da;var tt=ue===0?0:oe;if(se){var rt=a.computeBusNodeSpacing(Ye)-re;ve-=tt+We.height,Ye.S.h(fe+rt,ve),b=Math.max(b,fe+We.width+rt),z=Math.max(z,Math.abs(ve))}else rt=a.computeBusNodeSpacing(Ye)-re,fe-=tt+We.width,Ye.S.h(fe,ve+rt),z=Math.max(z,ve+We.height+rt),b=Math.max(b,Math.abs(fe));ue++}for(1<ee&&ee%2===1&&(oe=x[ee-1],ue=oe.Da,a=a.computeBusLastRowSpacing(oe,se?Math.max(Math.abs(ye),Math.abs(ve)):Math.max(Math.abs(Ce),Math.abs(fe))),se?(oe.S.h(E+re/2-oe.focus.x-oe.la.x,-z-ue.height-a),fe=E+re/2-oe.focus.x-oe.la.x,b=Math.max(b,fe+ue.width),0>fe&&(b-=fe),z=Math.max(z,Math.abs(Math.min(ye,ve))+a+ue.height),0>oe.S.x&&(E=Bv(y,oe.S.x,!1,E,re))):(oe.S.h(-b-ue.width-a,E+re/2-oe.focus.y-oe.la.y),b=Math.max(b,Math.abs(Math.min(Ce,fe))+a+ue.width),ve=E+re/2-oe.focus.y-oe.la.y,z=Math.max(z,ve+ue.height),0>ve&&(z-=ve),0>oe.S.y&&(E=Bv(y,oe.S.y,!0,E,re)))),y=0;y<ee;y++)re=x[y],se?re.S.h(re.S.x,re.S.y+z):re.S.h(re.S.x+b,re.S.y);return new Xt(E,0,b,z)}Qr.prototype.computeBusNodeSpacing=function(a){return a.parent===null?0:a.parent.nodeSpacing},Qr.prototype.computeBusLastRowSpacing=function(a){return a.parent===null?0:a.parent.rowSpacing};function Bv(a,y,x,E,b){a=a.children;for(var z=a.length,ee=0;ee<z;ee++)x?a[ee].S.h(a[ee].S.x,a[ee].S.y-y):a[ee].S.h(a[ee].S.x-y,a[ee].S.y);return y=a[z-1],Math.max(E,x?y.la.y+y.focus.y-b/2:y.la.x+y.focus.x-b/2)}function Fy(a,y,x){switch(a.alignment){case qf:case Kg:return x+a.width>y&&(y=x+a.width),0>x&&(y-=x),y;case Yc:return a.width>y?a.width:y;case Xc:return 2*a.focus.x>y?a.width:y+a.width-2*a.focus.x;case Fd:case Jc:return Math.max(a.width,Math.max(y,x+a.width)-Math.min(0,x));case Ad:return a.width-a.focus.x+a.nodeSpacing/2+y;case ld:return Math.max(a.width,a.focus.x+a.nodeSpacing/2+y);default:return y}}function Ay(a,y,x){switch(a.alignment){case qf:case Kg:return x+a.height>y&&(y=x+a.height),0>x&&(y-=x),y;case Yc:return a.height>y?a.height:y;case Xc:return 2*a.focus.y>y?a.height:y+a.height-2*a.focus.y;case Fd:case Jc:return Math.max(a.height,Math.max(y,x+a.height)-Math.min(0,x));case Ad:return a.height-a.focus.y+a.nodeSpacing/2+y;case ld:return Math.max(a.height,a.focus.y+a.nodeSpacing/2+y);default:return y}}function Ny(a,y,x){switch(a){case Kg:y/=2,x/=2;break;case qf:y/=2,x/=2;break;case Yc:x=y=0;break;case Xc:break;default:Dt("Unhandled alignment value "+a.toString())}return new Qe(y,x)}function Lf(a,y,x,E,b,z){y=Ny(y,x,E),Jf(a,y.x,y.y,b,z)}function Jf(a,y,x,E,b){if(y!==0||x!==0)for(a=a.children;E<=b;E++){var z=a[E].S;z.x+=y,z.y+=x}}function Ov(a,y,x,E){var b=y.parent;switch(a.ud){case _c:for(a=y.sourceEdges;a.next();)y=a.value,y.fromVertex===b&&y.relativePoint.h(x,E);break;case Qf:for(a=y.destinationEdges;a.next();)y=a.value,y.toVertex===b&&y.relativePoint.h(x,E);break;default:Dt("Unhandled path value "+a.ud.toString())}}function Rv(a,y,x){for(var E=0;E<a.length;E++){var b=a[E];b.x+=y,b.y+=x}}function dx(a,y,x,E,b,z,ee,re){var oe=uc(y),se=oe===90||oe===270,ue=y.nodeSpacing;y=E;var fe=b;E=z;var ve=ee,ye=x.Yo,Ce=x.kp;ee=x.Da;var Ae=se?Math.max(ve,ee.height):Math.max(E,ee.width);if((ye===null||oe!==uc(x))&&(ye=Vu(a,2),Ce=Vu(a,2),se?(ye[0].h(0,0),ye[1].h(0,ee.height),Ce[0].h(ee.width,0),Ce[1].h(Ce[0].x,ye[1].y)):(ye[0].h(0,0),ye[1].h(ee.width,0),Ce[0].h(0,ee.height),Ce[1].h(ye[1].x,Ce[0].y))),se){if(ve=9999999,!(fe===null||2>fe.length||ye===null||2>ye.length))for(b=x=0;x<fe.length&&b<ye.length;){z=fe[x];var Ye=ye[b];oe=Ye.x,se=Ye.y,oe+=E;var We=z;x+1<fe.length&&(We=fe[x+1]);var tt=Ye;Ye=tt.x,tt=tt.y,b+1<ye.length&&(tt=ye[b+1],Ye=tt.x,tt=tt.y,Ye+=E);var rt=ve;z.y===se?rt=oe-z.x:z.y>se&&z.y<tt?rt=oe+(z.y-se)/(tt-se)*(Ye-oe)-z.x:se>z.y&&se<We.y&&(rt=oe-(z.x+(se-z.y)/(We.y-z.y)*(We.x-z.x))),rt<ve&&(ve=rt),We.y<=z.y?x++:tt<=se?b++:(We.y<=tt&&x++,tt<=We.y&&b++)}if(ve=E-ve,ve+=ue,x=ye,b=ve,y===null||2>y.length||x===null||2>x.length)E=null;else{for(ue=Vu(a,y.length+x.length),E=z=oe=0;z<x.length&&x[z].y<y[0].y;)se=x[z++],ue[E++].h(se.x+b,se.y);for(;oe<y.length;)se=y[oe++],ue[E++].h(se.x,se.y);for(oe=y[y.length-1].y;z<x.length&&x[z].y<=oe;)z++;for(;z<x.length&&x[z].y>oe;)se=x[z++],ue[E++].h(se.x+b,se.y);for(x=Vu(a,E),oe=0;oe<E;oe++)x[oe].assign(ue[oe]);yc(a,ue),E=x}if(z=Ce,oe=ve,fe===null||2>fe.length||z===null||2>z.length)b=null;else{for(ue=Vu(a,fe.length+z.length),b=se=x=0;x<fe.length&&fe[x].y<z[0].y;)We=fe[x++],ue[b++].h(We.x,We.y);for(;se<z.length;)We=z[se++],ue[b++].h(We.x+oe,We.y);for(z=z[z.length-1].y;x<fe.length&&fe[x].y<=z;)x++;for(;x<fe.length&&fe[x].y>z;)oe=fe[x++],ue[b++].h(oe.x,oe.y);for(z=Vu(a,b),x=0;x<b;x++)z[x].assign(ue[x]);yc(a,ue),b=z}return z=Math.max(0,ve)+ee.width,ee=Ae,yc(a,y),yc(a,ye),yc(a,fe),yc(a,Ce),re[0]=E,re[1]=b,new Xt(ve,0,z,ee)}if(E=9999999,!(fe===null||2>fe.length||ye===null||2>ye.length))for(b=x=0;x<fe.length&&b<ye.length;)z=fe[x],Ye=ye[b],oe=Ye.x,se=Ye.y,se+=ve,We=z,x+1<fe.length&&(We=fe[x+1]),tt=Ye,Ye=tt.x,tt=tt.y,b+1<ye.length&&(tt=ye[b+1],Ye=tt.x,tt=tt.y,tt+=ve),rt=E,z.x===oe?rt=se-z.y:z.x>oe&&z.x<Ye?rt=se+(z.x-oe)/(Ye-oe)*(tt-se)-z.y:oe>z.x&&oe<We.x&&(rt=se-(z.y+(oe-z.x)/(We.x-z.x)*(We.y-z.y))),rt<E&&(E=rt),We.x<=z.x?x++:Ye<=oe?b++:(We.x<=Ye&&x++,Ye<=We.x&&b++);if(ve-=E,ve+=ue,x=ye,b=ve,y===null||2>y.length||x===null||2>x.length)E=null;else{for(ue=Vu(a,y.length+x.length),E=z=oe=0;z<x.length&&x[z].x<y[0].x;)se=x[z++],ue[E++].h(se.x,se.y+b);for(;oe<y.length;)se=y[oe++],ue[E++].h(se.x,se.y);for(oe=y[y.length-1].x;z<x.length&&x[z].x<=oe;)z++;for(;z<x.length&&x[z].x>oe;)se=x[z++],ue[E++].h(se.x,se.y+b);for(x=Vu(a,E),oe=0;oe<E;oe++)x[oe].assign(ue[oe]);yc(a,ue),E=x}if(z=Ce,oe=ve,fe===null||2>fe.length||z===null||2>z.length)b=null;else{for(ue=Vu(a,fe.length+z.length),b=se=x=0;x<fe.length&&fe[x].x<z[0].x;)We=fe[x++],ue[b++].h(We.x,We.y);for(;se<z.length;)We=z[se++],ue[b++].h(We.x,We.y+oe);for(z=z[z.length-1].x;x<fe.length&&fe[x].x<=z;)x++;for(;x<fe.length&&fe[x].x>z;)oe=fe[x++],ue[b++].h(oe.x,oe.y);for(z=Vu(a,b),x=0;x<b;x++)z[x].assign(ue[x]);yc(a,ue),b=z}return z=Ae,ee=Math.max(0,ve)+ee.height,yc(a,y),yc(a,ye),yc(a,fe),yc(a,Ce),re[0]=E,re[1]=b,new Xt(ve,0,z,ee)}function Vu(a,y){if(a=a.ru[y],a!==void 0&&(a=a.pop(),a!==void 0))return a;a=[];for(var x=0;x<y;x++)a[x]=new Qe;return a}function yc(a,y){var x=y.length,E=a.ru[x];E===void 0&&(E=[],a.ru[x]=E),E.push(y)}Qr.prototype.arrangeTrees=function(){if(this.Rb===Gv)for(var a=this.Ub.iterator;a.next();){var y=a.value;if(y instanceof Xh){var x=y.node;if(x!==null){var E=x.position;x=E.x,E=E.y,isFinite(x)||(x=0),isFinite(E)||(E=0),Ty(this,y,x,E)}}}else{for(a=[],y=this.Ub.iterator;y.next();)x=y.value,x instanceof Xh&&a.push(x);switch(this.sorting){case Gg:break;case Yp:a.reverse();break;case Xp:a.sort(this.comparer);break;case Jp:a.sort(this.comparer),a.reverse();break;default:Dt("Unhandled sorting value "+this.sorting.toString())}for(x=this.arrangementOrigin,y=x.x,x=x.y,E=0;E<a.length;E++){var b=a[E];switch(Ty(this,b,y+b.la.x,x+b.la.y),this.Rb){case Hv:x+=b.Da.height+this.$d.height;break;case Ry:y+=b.Da.width+this.$d.width;break;default:Dt("Unhandled arrangement value "+this.Rb.toString())}}}};function Ty(a,y,x,E){if(y!==null){y.x=x,y.y=E,y=y.children;for(var b=y.length,z=0;z<b;z++){var ee=y[z];Ty(a,ee,x+ee.S.x,E+ee.S.y)}}}Qr.prototype.commitLayout=function(){this.yv(),this.commitNodes(),this.Gu(),this.isRouting&&this.commitLinks()},Qr.prototype.commitNodes=function(){for(var a=this.network.vertexes.iterator;a.next();)a.value.commit();for(a.reset();a.next();)this.layoutComments(a.value)},Qr.prototype.Gu=function(){if(this.layerStyle===Kv){for(var a=this.$v,y=[],x=null,E=this.network.vertexes.iterator;E.next();){var b=E.value;x===null?x=b.bounds.copy():x.ed(b.bounds);var z=y[b.level];z===void 0?z=this.computeLayerSpacing(b):z=Math.max(z,this.computeLayerSpacing(b)),y[b.level]=z}for(E=0;E<y.length;E++)y[E]===void 0&&(y[E]=0);if(this.angle===90||this.angle===270?(x.Bc(this.nodeSpacing/2,this.layerSpacing),E=new Qe(-this.nodeSpacing/2,-this.layerSpacing/2)):(x.Bc(this.layerSpacing,this.nodeSpacing/2),E=new Qe(-this.layerSpacing/2,-this.nodeSpacing/2)),b=[],x=this.angle===90||this.angle===270?x.width:x.height,z=0,this.angle===180||this.angle===270)for(var ee=0;ee<a.length;ee++)z+=a[ee]+y[ee];for(ee=0;ee<a.length;ee++){var re=a[ee]+y[ee];this.angle===270?(z-=re,b.push(new Xt(0,z,x,re))):this.angle===90?(b.push(new Xt(0,z,x,re)),z+=re):this.angle===180?(z-=re,b.push(new Xt(z,0,re,x))):(b.push(new Xt(z,0,re,x)),z+=re)}this.commitLayers(b,E)}},Qr.prototype.commitLayers=function(){},Qr.prototype.commitLinks=function(){for(var a=this.network.edges.iterator;a.next();)a.value.commit()},Qr.prototype.yv=function(){for(var a=this.Ub.iterator;a.next();){var y=a.value;y instanceof Xh&&fx(this,y)}};function fx(a,y){if(y!==null){a.setPortSpots(y),y=y.children;for(var x=y.length,E=0;E<x;E++)fx(a,y[E])}}Qr.prototype.setPortSpots=function(a){var y=a.alignment;if(nf(y)){var x=this.ud===_c,E=uc(a);switch(E){case 0:var b=Rs;break;case 90:b=Us;break;case 180:b=ol;break;default:b=Ml}var z=a.children,ee=z.length;switch(y){case Fd:case Jc:for(y=0;y<ee;y++){var re=z[y];if(re=(x?re.sourceEdges:re.destinationEdges).first(),re!==null&&(re=re.link,re!==null)){var oe=E===90||E===270?ol:Ml;if(ee===1||y===ee-1&&ee%2===1)switch(E){case 0:oe=ol;break;case 90:oe=Ml;break;case 180:oe=Rs;break;default:oe=Us}else y%2===0&&(oe=E===90||E===270?Rs:Us);x?(a.setsPortSpot&&(re.fromSpot=b),a.setsChildPortSpot&&(re.toSpot=oe)):(a.setsPortSpot&&(re.fromSpot=oe),a.setsChildPortSpot&&(re.toSpot=b))}}break;case Ad:for(E=E===90||E===270?Rs:Us,z=x?a.destinationEdges:a.sourceEdges;z.next();)ee=z.value.link,ee!==null&&(x?(a.setsPortSpot&&(ee.fromSpot=b),a.setsChildPortSpot&&(ee.toSpot=E)):(a.setsPortSpot&&(ee.fromSpot=E),a.setsChildPortSpot&&(ee.toSpot=b)));break;case ld:for(E=E===90||E===270?ol:Ml,z=x?a.destinationEdges:a.sourceEdges;z.next();)ee=z.value.link,ee!==null&&(x?(a.setsPortSpot&&(ee.fromSpot=b),a.setsChildPortSpot&&(ee.toSpot=E)):(a.setsPortSpot&&(ee.fromSpot=E),a.setsChildPortSpot&&(ee.toSpot=b)))}}else if(x=uc(a),this.ud===_c){for(b=a.destinationEdges;b.next();)if(E=b.value.link,E!==null){if(a.setsPortSpot)if(a.portSpot.Xb())switch(x){case 0:E.fromSpot=Rs;break;case 90:E.fromSpot=Us;break;case 180:E.fromSpot=ol;break;default:E.fromSpot=Ml}else E.fromSpot=a.portSpot;if(a.setsChildPortSpot)if(a.childPortSpot.Xb())switch(x){case 0:E.toSpot=ol;break;case 90:E.toSpot=Ml;break;case 180:E.toSpot=Rs;break;default:E.toSpot=Us}else E.toSpot=a.childPortSpot}}else for(b=a.sourceEdges;b.next();)if(E=b.value.link,E!==null){if(a.setsPortSpot)if(a.portSpot.Xb())switch(x){case 0:E.toSpot=Rs;break;case 90:E.toSpot=Us;break;case 180:E.toSpot=ol;break;default:E.toSpot=Ml}else E.toSpot=a.portSpot;if(a.setsChildPortSpot)if(a.childPortSpot.Xb())switch(x){case 0:E.fromSpot=ol;break;case 90:E.fromSpot=Ml;break;case 180:E.fromSpot=Rs;break;default:E.fromSpot=Us}else E.fromSpot=a.childPortSpot}};function uc(a){return a=a.angle,45>=a?0:135>=a?90:225>=a?180:315>=a?270:0}Qr.prototype.computeLayerSpacing=function(a){var y=uc(a);y=y===90||y===270;var x=a.layerSpacing;if(0<a.layerSpacingParentOverlap){var E=Math.min(1,a.layerSpacingParentOverlap);x-=y?a.height*E:a.width*E}return x<(y?-a.height:-a.width)&&(x=y?-a.height:-a.width),x},Qr.prototype.computeNodeIndent=function(a){var y=uc(a),x=a.nodeIndent;if(0<a.nodeIndentPastParent){var E=Math.min(1,a.nodeIndentPastParent);x+=y===90||y===270?a.width*E:a.height*E}return x=Math.max(0,x)},Yt.Object.defineProperties(Qr.prototype,{roots:{get:function(){return this.Ub},set:function(a){this.Ub!==a&&(this.Ub=a,this.C())}},path:{get:function(){return this.Wn},set:function(a){this.Wn!==a&&(this.Wn=a,this.C())}},treeStyle:{get:function(){return this.vo},set:function(a){this.Rb===a||a!==zv&&a!==By&&a!==Dy&&a!==Oy||(this.vo=a,this.C())}},layerStyle:{get:function(){return this.Bq},set:function(a){this.Rb===a||a!==Iy&&a!==jy&&a!==Kv||(this.Bq=a,this.C())}},comments:{get:function(){return this.td},set:function(a){this.td!==a&&(this.td=a,this.C())}},arrangement:{get:function(){return this.Rb},set:function(a){this.Rb===a||a!==Hv&&a!==Ry&&a!==Gv||(this.Rb=a,this.C())}},arrangementSpacing:{get:function(){return this.$d},set:function(a){this.$d.D(a)||(this.$d.assign(a),this.C())}},rootDefaults:{get:function(){return this.W},set:function(a){this.W!==a&&(this.W=a,this.C())}},alternateDefaults:{get:function(){return this.Y},set:function(a){this.Y!==a&&(this.Y=a,this.C())}},sorting:{get:function(){return this.W.sorting},set:function(a){this.W.sorting===a||a!==Gg&&a!==Yp&&a!==Xp&&!Jp||(this.W.sorting=a,this.C())}},comparer:{get:function(){return this.W.comparer},set:function(a){this.W.comparer!==a&&(this.W.comparer=a,this.C())}},angle:{get:function(){return this.W.angle},set:function(a){this.W.angle!==a&&(a===0||a===90||a===180||a===270?(this.W.angle=a,this.C()):Dt("TreeLayout.angle must be 0, 90, 180, or 270"))}},alignment:{get:function(){return this.W.alignment},set:function(a){this.W.alignment!==a&&(this.W.alignment=a,this.C())}},nodeIndent:{get:function(){return this.W.nodeIndent},set:function(a){this.W.nodeIndent!==a&&0<=a&&(this.W.nodeIndent=a,this.C())}},nodeIndentPastParent:{get:function(){return this.W.nodeIndentPastParent},set:function(a){this.W.nodeIndentPastParent!==a&&0<=a&&1>=a&&(this.W.nodeIndentPastParent=a,this.C())}},nodeSpacing:{get:function(){return this.W.nodeSpacing},set:function(a){this.W.nodeSpacing!==a&&(this.W.nodeSpacing=a,this.C())}},layerSpacing:{get:function(){return this.W.layerSpacing},set:function(a){this.W.layerSpacing!==a&&(this.W.layerSpacing=a,this.C())}},layerSpacingParentOverlap:{get:function(){return this.W.layerSpacingParentOverlap},set:function(a){this.W.layerSpacingParentOverlap!==a&&0<=a&&1>=a&&(this.W.layerSpacingParentOverlap=a,this.C())}},compaction:{get:function(){return this.W.compaction},set:function(a){this.W.compaction===a||a!==jv&&a!==Qp||(this.W.compaction=a,this.C())}},breadthLimit:{get:function(){return this.W.breadthLimit},set:function(a){this.W.breadthLimit!==a&&0<=a&&(this.W.breadthLimit=a,this.C())}},rowSpacing:{get:function(){return this.W.rowSpacing},set:function(a){this.W.rowSpacing!==a&&(this.W.rowSpacing=a,this.C())}},rowIndent:{get:function(){return this.W.rowIndent},set:function(a){this.W.rowIndent!==a&&0<=a&&(this.W.rowIndent=a,this.C())}},commentSpacing:{get:function(){return this.W.commentSpacing},set:function(a){this.W.commentSpacing!==a&&(this.W.commentSpacing=a,this.C())}},commentMargin:{get:function(){return this.W.commentMargin},set:function(a){this.W.commentMargin!==a&&(this.W.commentMargin=a,this.C())}},setsPortSpot:{get:function(){return this.W.setsPortSpot},set:function(a){this.W.setsPortSpot!==a&&(this.W.setsPortSpot=a,this.C())}},portSpot:{get:function(){return this.W.portSpot},set:function(a){this.W.portSpot.D(a)||(this.W.portSpot=a,this.C())}},setsChildPortSpot:{get:function(){return this.W.setsChildPortSpot},set:function(a){this.W.setsChildPortSpot!==a&&(this.W.setsChildPortSpot=a,this.C())}},childPortSpot:{get:function(){return this.W.childPortSpot},set:function(a){this.W.childPortSpot.D(a)||(this.W.childPortSpot=a,this.C())}},alternateSorting:{get:function(){return this.Y.sorting},set:function(a){this.Y.sorting===a||a!==Gg&&a!==Yp&&a!==Xp&&!Jp||(this.Y.sorting=a,this.C())}},alternateComparer:{get:function(){return this.Y.comparer},set:function(a){this.Y.comparer!==a&&(this.Y.comparer=a,this.C())}},alternateAngle:{get:function(){return this.Y.angle},set:function(a){this.Y.angle===a||a!==0&&a!==90&&a!==180&&a!==270||(this.Y.angle=a,this.C())}},alternateAlignment:{get:function(){return this.Y.alignment},set:function(a){this.Y.alignment!==a&&(this.Y.alignment=a,this.C())}},alternateNodeIndent:{get:function(){return this.Y.nodeIndent},set:function(a){this.Y.nodeIndent!==a&&0<=a&&(this.Y.nodeIndent=a,this.C())}},alternateNodeIndentPastParent:{get:function(){return this.Y.nodeIndentPastParent},set:function(a){this.Y.nodeIndentPastParent!==a&&0<=a&&1>=a&&(this.Y.nodeIndentPastParent=a,this.C())}},alternateNodeSpacing:{get:function(){return this.Y.nodeSpacing},set:function(a){this.Y.nodeSpacing!==a&&(this.Y.nodeSpacing=a,this.C())}},alternateLayerSpacing:{get:function(){return this.Y.layerSpacing},set:function(a){this.Y.layerSpacing!==a&&(this.Y.layerSpacing=a,this.C())}},alternateLayerSpacingParentOverlap:{get:function(){return this.Y.layerSpacingParentOverlap},set:function(a){this.Y.layerSpacingParentOverlap!==a&&0<=a&&1>=a&&(this.Y.layerSpacingParentOverlap=a,this.C())}},alternateCompaction:{get:function(){return this.Y.compaction},set:function(a){this.Y.compaction===a||a!==jv&&a!==Qp||(this.Y.compaction=a,this.C())}},alternateBreadthLimit:{get:function(){return this.Y.breadthLimit},set:function(a){this.Y.breadthLimit!==a&&0<=a&&(this.Y.breadthLimit=a,this.C())}},alternateRowSpacing:{get:function(){return this.Y.rowSpacing},set:function(a){this.Y.rowSpacing!==a&&(this.Y.rowSpacing=a,this.C())}},alternateRowIndent:{get:function(){return this.Y.rowIndent},set:function(a){this.Y.rowIndent!==a&&0<=a&&(this.Y.rowIndent=a,this.C())}},alternateCommentSpacing:{get:function(){return this.Y.commentSpacing},set:function(a){this.Y.commentSpacing!==a&&(this.Y.commentSpacing=a,this.C())}},alternateCommentMargin:{get:function(){return this.Y.commentMargin},set:function(a){this.Y.commentMargin!==a&&(this.Y.commentMargin=a,this.C())}},alternateSetsPortSpot:{get:function(){return this.Y.setsPortSpot},set:function(a){this.Y.setsPortSpot!==a&&(this.Y.setsPortSpot=a,this.C())}},alternatePortSpot:{get:function(){return this.Y.portSpot},set:function(a){this.Y.portSpot.D(a)||(this.Y.portSpot=a,this.C())}},alternateSetsChildPortSpot:{get:function(){return this.Y.setsChildPortSpot},set:function(a){this.Y.setsChildPortSpot!==a&&(this.Y.setsChildPortSpot=a,this.C())}},alternateChildPortSpot:{get:function(){return this.Y.childPortSpot},set:function(a){this.Y.childPortSpot.D(a)||(this.Y.childPortSpot=a,this.C())}}});var Iv=new Vt(Qr,"PathDefault",-1),_c=new Vt(Qr,"PathDestination",0),Qf=new Vt(Qr,"PathSource",1),Gg=new Vt(Qr,"SortingForwards",10),Yp=new Vt(Qr,"SortingReverse",11),Xp=new Vt(Qr,"SortingAscending",12),Jp=new Vt(Qr,"SortingDescending",13),Kg=new Vt(Qr,"AlignmentCenterSubtrees",20),qf=new Vt(Qr,"AlignmentCenterChildren",21),Yc=new Vt(Qr,"AlignmentStart",22),Xc=new Vt(Qr,"AlignmentEnd",23),Fd=new Vt(Qr,"AlignmentBus",24),Jc=new Vt(Qr,"AlignmentBusBranching",25),Ad=new Vt(Qr,"AlignmentTopLeftBus",26),ld=new Vt(Qr,"AlignmentBottomRightBus",27),jv=new Vt(Qr,"CompactionNone",30),Qp=new Vt(Qr,"CompactionBlock",31),zv=new Vt(Qr,"StyleLayered",40),Dy=new Vt(Qr,"StyleLastParents",41),By=new Vt(Qr,"StyleAlternating",42),Oy=new Vt(Qr,"StyleRootOnly",43),Hv=new Vt(Qr,"ArrangementVertical",50),Ry=new Vt(Qr,"ArrangementHorizontal",51),Gv=new Vt(Qr,"ArrangementFixedRoots",52),Iy=new Vt(Qr,"LayerIndividual",60),jy=new Vt(Qr,"LayerSiblings",61),Kv=new Vt(Qr,"LayerUniform",62);Qr.className="TreeLayout",Qr.PathDefault=Iv,Qr.PathDestination=_c,Qr.PathSource=Qf,Qr.SortingForwards=Gg,Qr.SortingReverse=Yp,Qr.SortingAscending=Xp,Qr.SortingDescending=Jp,Qr.AlignmentCenterSubtrees=Kg,Qr.AlignmentCenterChildren=qf,Qr.AlignmentStart=Yc,Qr.AlignmentEnd=Xc,Qr.AlignmentBus=Fd,Qr.AlignmentBusBranching=Jc,Qr.AlignmentTopLeftBus=Ad,Qr.AlignmentBottomRightBus=ld,Qr.CompactionNone=jv,Qr.CompactionBlock=Qp,Qr.StyleLayered=zv,Qr.StyleLastParents=Dy,Qr.StyleAlternating=By,Qr.StyleRootOnly=Oy,Qr.ArrangementVertical=Hv,Qr.ArrangementHorizontal=Ry,Qr.ArrangementFixedRoots=Gv,Qr.LayerIndividual=Iy,Qr.LayerSiblings=jy,Qr.LayerUniform=Kv;function $f(a){za.call(this,a)}Ct($f,za),$f.prototype.createVertex=function(){return new Xh(this)},$f.prototype.createEdge=function(){return new Wg(this)},$f.className="TreeNetwork";function Xh(a){$s.call(this,a),this.V=!1,this.hb=null,this.u=[],this.nb=this.Ha=this.F=this.ia=0,this.td=null,this.S=new Qe(0,0),this.Da=new fn(0,0),this.la=new Qe(0,0),this.im=this.hm=this.qA=!1,this.kp=this.Yo=null,this.nd=Gg,this.hd=ry,this.Kb=0,this.Jb=qf,this.Vq=this.Uq=0,this.Wq=20,this.ie=50,this.Aq=0,this.Hp=Qp,this.Ap=0,this.nr=25,this.Gp=this.mr=10,this.Fp=20,this.xr=!0,this.dr=vs,this.wr=!0,this.Dp=vs}Ct(Xh,$s),Xh.prototype.copyInheritedPropertiesFrom=function(a){a!==null&&(this.nd=a.sorting,this.hd=a.comparer,this.Kb=a.angle,this.Jb=a.alignment,this.Uq=a.nodeIndent,this.Vq=a.nodeIndentPastParent,this.Wq=a.nodeSpacing,this.ie=a.layerSpacing,this.Aq=a.layerSpacingParentOverlap,this.Hp=a.compaction,this.Ap=a.breadthLimit,this.nr=a.rowSpacing,this.mr=a.rowIndent,this.Gp=a.commentSpacing,this.Fp=a.commentMargin,this.xr=a.setsPortSpot,this.dr=a.portSpot,this.wr=a.setsChildPortSpot,this.Dp=a.childPortSpot)},Yt.Object.defineProperties(Xh.prototype,{initialized:{get:function(){return this.V},set:function(a){this.V!==a&&(this.V=a)}},parent:{get:function(){return this.hb},set:function(a){this.hb!==a&&(this.hb=a)}},children:{get:function(){return this.u},set:function(a){if(this.u!==a){if(a!==null)for(var y=a.length,x=0;x<y;x++);this.u=a}}},level:{get:function(){return this.ia},set:function(a){this.ia!==a&&(this.ia=a)}},descendantCount:{get:function(){return this.F},set:function(a){this.F!==a&&(this.F=a)}},maxChildrenCount:{get:function(){return this.Ha},set:function(a){this.Ha!==a&&(this.Ha=a)}},maxGenerationCount:{get:function(){return this.nb},set:function(a){this.nb!==a&&(this.nb=a)}},comments:{get:function(){return this.td},set:function(a){if(this.td!==a){if(a!==null)for(var y=a.length,x=0;x<y;x++);this.td=a}}},sorting:{get:function(){return this.nd},set:function(a){this.nd!==a&&(this.nd=a)}},comparer:{get:function(){return this.hd},set:function(a){this.hd!==a&&(this.hd=a)}},angle:{get:function(){return this.Kb},set:function(a){this.Kb!==a&&(this.Kb=a)}},alignment:{get:function(){return this.Jb},set:function(a){this.Jb!==a&&(this.Jb=a)}},nodeIndent:{get:function(){return this.Uq},set:function(a){this.Uq!==a&&(this.Uq=a)}},nodeIndentPastParent:{get:function(){return this.Vq},set:function(a){this.Vq!==a&&(this.Vq=a)}},nodeSpacing:{get:function(){return this.Wq},set:function(a){this.Wq!==a&&(this.Wq=a)}},layerSpacing:{get:function(){return this.ie},set:function(a){this.ie!==a&&(this.ie=a)}},layerSpacingParentOverlap:{get:function(){return this.Aq},set:function(a){this.Aq!==a&&(this.Aq=a)}},compaction:{get:function(){return this.Hp},set:function(a){this.Hp!==a&&(this.Hp=a)}},breadthLimit:{get:function(){return this.Ap},set:function(a){this.Ap!==a&&(this.Ap=a)}},rowSpacing:{get:function(){return this.nr},set:function(a){this.nr!==a&&(this.nr=a)}},rowIndent:{get:function(){return this.mr},set:function(a){this.mr!==a&&(this.mr=a)}},commentSpacing:{get:function(){return this.Gp},set:function(a){this.Gp!==a&&(this.Gp=a)}},commentMargin:{get:function(){return this.Fp},set:function(a){this.Fp!==a&&(this.Fp=a)}},setsPortSpot:{get:function(){return this.xr},set:function(a){this.xr!==a&&(this.xr=a)}},portSpot:{get:function(){return this.dr},set:function(a){this.dr.D(a)||(this.dr=a)}},setsChildPortSpot:{get:function(){return this.wr},set:function(a){this.wr!==a&&(this.wr=a)}},childPortSpot:{get:function(){return this.Dp},set:function(a){this.Dp.D(a)||(this.Dp=a)}},childrenCount:{get:function(){return this.children.length}},relativePosition:{get:function(){return this.S},set:function(a){this.S.set(a)}},subtreeSize:{get:function(){return this.Da},set:function(a){this.Da.set(a)}},subtreeOffset:{get:function(){return this.la},set:function(a){this.la.set(a)}}}),Xh.className="TreeVertex";function Wg(a){ih.call(this,a),this.$t=new Qe(0,0)}Ct(Wg,ih),Wg.prototype.commit=function(){var a=this.link;if(a!==null&&!a.isAvoiding){var y=this.network.layout,x=null,E=null;switch(y.ud){case _c:x=this.fromVertex,E=this.toVertex;break;case Qf:x=this.toVertex,E=this.fromVertex;break;default:Dt("Unhandled path value "+y.ud.toString())}if(x!==null&&E!==null){var b=this.$t;if(b.x!==0||b.y!==0||x.qA){E=x.bounds;var z=uc(x),ee=y.computeLayerSpacing(x),re=x.rowSpacing;a.vg();var oe=a.curve===vh,se=a.isOrthogonal,ue;if(a.uh(),se||oe){for(ue=2;4<a.pointsCount;)a.pv(2);var fe=a.i(1),ve=a.i(2)}else{for(ue=1;3<a.pointsCount;)a.pv(1);fe=a.i(0),ve=a.i(a.pointsCount-1)}var ye=a.i(a.pointsCount-1);z===0?(x.alignment===Xc?(z=E.bottom+b.y,b.y===0&&fe.y>ye.y+x.rowIndent&&(z=Math.min(z,Math.max(fe.y,z-y.computeNodeIndent(x))))):x.alignment===Yc?(z=E.top+b.y,b.y===0&&fe.y<ye.y-x.rowIndent&&(z=Math.max(z,Math.min(fe.y,z+y.computeNodeIndent(x))))):z=x.hm||x.im&&x.maxGenerationCount===1?E.top-x.la.y+b.y:E.y+E.height/2+b.y,oe?(a.m(ue,fe.x,z),ue++,a.m(ue,E.right+ee,z),ue++,a.m(ue,E.right+ee+(b.x-re)/3,z),ue++,a.m(ue,E.right+ee+2*(b.x-re)/3,z),ue++,a.m(ue,E.right+ee+(b.x-re),z),ue++,a.m(ue,ve.x,z)):(se&&(a.m(ue,E.right+ee/2,fe.y),ue++),a.m(ue,E.right+ee/2,z),ue++,a.m(ue,E.right+ee+b.x-(se?re/2:re),z),ue++,se&&a.m(ue,a.i(ue-1).x,ve.y))):z===90?(x.alignment===Xc?(z=E.right+b.x,b.x===0&&fe.x>ye.x+x.rowIndent&&(z=Math.min(z,Math.max(fe.x,z-y.computeNodeIndent(x))))):x.alignment===Yc?(z=E.left+b.x,b.x===0&&fe.x<ye.x-x.rowIndent&&(z=Math.max(z,Math.min(fe.x,z+y.computeNodeIndent(x))))):z=x.hm||x.im&&x.maxGenerationCount===1?E.left-x.la.x+b.x:E.x+E.width/2+b.x,oe?(a.m(ue,z,fe.y),ue++,a.m(ue,z,E.bottom+ee),ue++,a.m(ue,z,E.bottom+ee+(b.y-re)/3),ue++,a.m(ue,z,E.bottom+ee+2*(b.y-re)/3),ue++,a.m(ue,z,E.bottom+ee+(b.y-re)),ue++,a.m(ue,z,ve.y)):(se&&(a.m(ue,fe.x,E.bottom+ee/2),ue++),a.m(ue,z,E.bottom+ee/2),ue++,a.m(ue,z,E.bottom+ee+b.y-(se?re/2:re)),ue++,se&&a.m(ue,ve.x,a.i(ue-1).y))):z===180?(x.alignment===Xc?(z=E.bottom+b.y,b.y===0&&fe.y>ye.y+x.rowIndent&&(z=Math.min(z,Math.max(fe.y,z-y.computeNodeIndent(x))))):x.alignment===Yc?(z=E.top+b.y,b.y===0&&fe.y<ye.y-x.rowIndent&&(z=Math.max(z,Math.min(fe.y,z+y.computeNodeIndent(x))))):z=x.hm||x.im&&x.maxGenerationCount===1?E.top-x.la.y+b.y:E.y+E.height/2+b.y,oe?(a.m(ue,fe.x,z),ue++,a.m(ue,E.left-ee,z),ue++,a.m(ue,E.left-ee+(b.x+re)/3,z),ue++,a.m(ue,E.left-ee+2*(b.x+re)/3,z),ue++,a.m(ue,E.left-ee+(b.x+re),z),ue++,a.m(ue,ve.x,z)):(se&&(a.m(ue,E.left-ee/2,fe.y),ue++),a.m(ue,E.left-ee/2,z),ue++,a.m(ue,E.left-ee+b.x+(se?re/2:re),z),ue++,se&&a.m(ue,a.i(ue-1).x,ve.y))):z===270?(x.alignment===Xc?(z=E.right+b.x,b.x===0&&fe.x>ye.x+x.rowIndent&&(z=Math.min(z,Math.max(fe.x,z-y.computeNodeIndent(x))))):x.alignment===Yc?(z=E.left+b.x,b.x===0&&fe.x<ye.x-x.rowIndent&&(z=Math.max(z,Math.min(fe.x,z+y.computeNodeIndent(x))))):z=x.hm||x.im&&x.maxGenerationCount===1?E.left-x.la.x+b.x:E.x+E.width/2+b.x,oe?(a.m(ue,z,fe.y),ue++,a.m(ue,z,E.top-ee),ue++,a.m(ue,z,E.top-ee+(b.y+re)/3),ue++,a.m(ue,z,E.top-ee+2*(b.y+re)/3),ue++,a.m(ue,z,E.top-ee+(b.y+re)),ue++,a.m(ue,z,ve.y)):(se&&(a.m(ue,fe.x,E.top-ee/2),ue++),a.m(ue,z,E.top-ee/2),ue++,a.m(ue,z,E.top-ee+b.y+(se?re/2:re)),ue++,se&&a.m(ue,ve.x,a.i(ue-1).y))):Dt("Invalid angle "+z),a.zf()}else b=E,a=this.link,E=this.network.layout,y=uc(x),y!==uc(b)&&(ee=E.computeLayerSpacing(x),re=x.bounds,x=b.bounds,y===0&&x.left-re.right<ee+1||y===90&&x.top-re.bottom<ee+1||y===180&&re.left-x.right<ee+1||y===270&&re.top-x.bottom<ee+1||(a.vg(),x=a.curve===vh,b=a.isOrthogonal,E=nf(this.fromVertex.alignment),a.uh(),y===0?(y=re.right+ee/2,x?a.pointsCount===4&&(x=a.i(3).y,a.L(1,y-20,a.i(1).y),a.m(2,y-20,x),a.m(3,y,x),a.m(4,y+20,x),a.L(5,a.i(5).x,x)):b?E?a.L(3,a.i(2).x,a.i(4).y):a.pointsCount===6&&(a.L(2,y,a.i(2).y),a.L(3,y,a.i(3).y)):a.pointsCount===4?a.m(2,y,a.i(2).y):a.pointsCount===3?a.L(1,y,a.i(2).y):a.pointsCount===2&&a.m(1,y,a.i(1).y)):y===90?(y=re.bottom+ee/2,x?a.pointsCount===4&&(x=a.i(3).x,a.L(1,a.i(1).x,y-20),a.m(2,x,y-20),a.m(3,x,y),a.m(4,x,y+20),a.L(5,x,a.i(5).y)):b?E?a.L(3,a.i(2).x,a.i(4).y):a.pointsCount===6&&(a.L(2,a.i(2).x,y),a.L(3,a.i(3).x,y)):a.pointsCount===4?a.m(2,a.i(2).x,y):a.pointsCount===3?a.L(1,a.i(2).x,y):a.pointsCount===2&&a.m(1,a.i(1).x,y)):y===180?(y=re.left-ee/2,x?a.pointsCount===4&&(x=a.i(3).y,a.L(1,y+20,a.i(1).y),a.m(2,y+20,x),a.m(3,y,x),a.m(4,y-20,x),a.L(5,a.i(5).x,x)):b?E?a.L(3,a.i(2).x,a.i(4).y):a.pointsCount===6&&(a.L(2,y,a.i(2).y),a.L(3,y,a.i(3).y)):a.pointsCount===4?a.m(2,y,a.i(2).y):a.pointsCount===3?a.L(1,y,a.i(2).y):a.pointsCount===2&&a.m(1,y,a.i(1).y)):y===270&&(y=re.top-ee/2,x?a.pointsCount===4&&(x=a.i(3).x,a.L(1,a.i(1).x,y+20),a.m(2,x,y+20),a.m(3,x,y),a.m(4,x,y-20),a.L(5,x,a.i(5).y)):b?E?a.L(3,a.i(2).x,a.i(4).y):a.pointsCount===6&&(a.L(2,a.i(2).x,y),a.L(3,a.i(3).x,y)):a.pointsCount===4?a.m(2,a.i(2).x,y):a.pointsCount===3?a.L(1,a.i(2).x,y):a.pointsCount===2&&a.m(1,a.i(1).x,y)),a.zf()))}}},Yt.Object.defineProperties(Wg.prototype,{fromVertex:{get:function(){return this.kd},set:function(a){this.kd!==a&&(this.kd=a)}},toVertex:{get:function(){return this.qd},set:function(a){this.qd!==a&&(this.qd=a)}},relativePoint:{get:function(){return this.$t},set:function(a){this.$t.set(a)}}}),Wg.className="TreeEdge",sa.prototype.initializeStandardTools=function(){this.gb("Action",new Bt,this.mouseDownTools),this.gb("Relinking",new Te,this.mouseDownTools),this.gb("LinkReshaping",new Xe,this.mouseDownTools),this.gb("Rotating",new ct,this.mouseDownTools),this.gb("Resizing",new Ke,this.mouseDownTools),this.gb("Linking",new To,this.mouseMoveTools),this.gb("Dragging",new Br,this.mouseMoveTools),this.gb("DragSelecting",new qt,this.mouseMoveTools),this.gb("Panning",new nn,this.mouseMoveTools),this.gb("ContextMenu",new Jn,this.mouseUpTools),this.gb("TextEditing",new Wn,this.mouseUpTools),this.gb("ClickCreating",new hn,this.mouseUpTools),this.gb("ClickSelecting",new Et,this.mouseUpTools)},Ac("Horizontal",new vm),Ac("Spot",new Sm),Ac("Table",new wm),Ac("Viewbox",new Em),Ac("TableRow",new Pm),Ac("TableColumn",new Cm),Ac("Graduated",new fp),Ac("Grid",new dp),dg.add("GraphLinksModel",xl),dg.add("TreeModel",Oh);var Wv=Kt.go,zy={get licenseKey(){return bt.licenseKey},set licenseKey(a){bt.licenseKey=a},get version(){return bt.version},Group:xr,EnumValue:Vt,List:An,Set:Pn,Map:Li,Point:Qe,Size:fn,Rect:Xt,Margin:vr,Spot:Bi,Geometry:Bn,PathFigure:Ns,PathSegment:to,InputEvent:Zs,DiagramEvent:mu,ChangedEvent:ka,Model:Ci,GraphLinksModel:vo,TreeModel:bu,Binding:Hs,Transaction:ws,UndoManager:Ta,CommandHandler:_e,Tool:Ni,DraggingTool:Br,DraggingInfo:nd,DraggingOptions:ae,LinkingBaseTool:er,LinkingTool:To,RelinkingTool:Te,LinkReshapingTool:Xe,ResizingTool:Ke,RotatingTool:ct,ClickSelectingTool:Et,ActionTool:Bt,ClickCreatingTool:hn,HTMLInfo:Sn,ContextMenuTool:Jn,DragSelectingTool:qt,PanningTool:nn,TextEditingTool:Wn,ToolManager:sa,Animation:Xo,AnimationManager:lo,AnimationTrigger:Za,Layer:or,Diagram:bt,Palette:de,Overview:ge,Brush:ia,GraphObject:mt,Panel:Ln,RowColumnDefinition:Xs,Shape:Dr,TextBlock:ja,Picture:Iu,Part:Ii,Adornment:Fo,Node:qn,Link:Tn,Placeholder:wu,Layout:as,LayoutNetwork:za,LayoutVertex:$s,LayoutEdge:ih,GridLayout:Fl,PanelLayout:qs,CircularLayout:fs,CircularNetwork:jg,CircularVertex:Gp,CircularEdge:Cv,ForceDirectedLayout:jl,ForceDirectedNetwork:Xf,ForceDirectedVertex:Kp,ForceDirectedEdge:Wp,LayeredDigraphLayout:aa,LayeredDigraphNetwork:Hg,LayeredDigraphVertex:Ih,LayeredDigraphEdge:Zp,TreeLayout:Qr,TreeNetwork:$f,TreeVertex:Xh,TreeEdge:Wg};typeof Wv=="object"&&Wv.version&&eo("WARNING: a `go` object on the root object is already defined. "+("Debug"in Wv?"debug ":"")+"version: "+Wv.version+", replaced with version: "+zy.version),bt.prototype.go=zy,Kt.go=zy,typeof jn.exports=="object"&&(jn.exports=typeof De.g!="undefined"?De.g.go:self.go)}();var Ne=typeof De.g!="undefined"?De.g.go:self.go;const dt=typeof De.g!="undefined"?De.g.go:self.go,Ut=dt.Group,$t=dt.EnumValue,kt=dt.List,Ie=dt.Set,$e=dt.Map,Mt=dt.Point,Pt=dt.Size,wt=dt.Rect,Qt=dt.Margin,It=dt.Spot,sn=dt.Geometry,Re=dt.PathFigure,ne=dt.PathSegment,te=dt.InputEvent,he=dt.DiagramEvent,le=dt.ChangedEvent,pe=dt.Model,me=dt.GraphLinksModel,xe=dt.TreeModel,Ee=dt.Binding,Ge=dt.Transaction,et=dt.UndoManager,ut=dt.CommandHandler,st=dt.Tool,it=dt.DraggingTool,Nt=dt.DraggingInfo,St=dt.LinkingBaseTool,Ft=dt.LinkingTool,cn=dt.RelinkingTool,Tt=dt.LinkReshapingTool,hi=dt.ResizingTool,di=dt.RotatingTool,zn=dt.ClickSelectingTool,Dn=dt.ActionTool,nt=dt.ClickCreatingTool,ze=dt.HTMLInfo,ke=dt.ContextMenuTool,Wt=dt.DragSelectingTool,On=dt.PanningTool,Lt=dt.TextEditingTool,xn=dt.ToolManager,vn=dt.Animation,Xn=dt.AnimationManager,Ot=dt.AnimationTrigger,ft=dt.Layer,Gt=dt.Diagram,an=dt.Palette,Jt=dt.Overview,Ve=dt.Brush,be=dt.GraphObject,Pe=dt.Panel,Be=dt.RowColumnDefinition,Ze=dt.Shape,Fe=dt.TextBlock,qe=dt.TextBlockMetrics,dn=dt.Picture,ui=dt.Part,$n=dt.Adornment,rn=dt.Node,Hn=dt.Link,Zt=dt.Placeholder,_n=dt.Layout,ti=dt.LayoutNetwork,Ri=dt.LayoutVertex,oi=dt.LayoutEdge,wr=dt.GridLayout,fr=dt.PanelLayout,Ei=dt.CircularLayout,Di=dt.CircularNetwork,uo=dt.CircularVertex,vt=dt.CircularEdge,ei=dt.ForceDirectedLayout,co=dt.ForceDirectedNetwork,bo=dt.ForceDirectedVertex,Ui=dt.ForceDirectedEdge,yo=dt.LayeredDigraphLayout,ha=dt.LayeredDigraphNetwork,Ka=dt.LayeredDigraphVertex,Ra=dt.LayeredDigraphEdge,ca=dt.TreeLayout,ma=dt.TreeNetwork,Ho=dt.TreeVertex,_r=dt.TreeEdge,Fn=dt.version},15979:function(jn,li,De){"use strict";De.d(li,{hP:function(){return Jt}});var Ne=function(Ve,be){return(Ne=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Pe,Be){Pe.__proto__=Be}||function(Pe,Be){for(var Ze in Be)Object.prototype.hasOwnProperty.call(Be,Ze)&&(Pe[Ze]=Be[Ze])})(Ve,be)};function dt(Ve,be){function Pe(){this.constructor=Ve}Ne(Ve,be),Ve.prototype=be===null?Object.create(be):(Pe.prototype=be.prototype,new Pe)}function Ut(Ve,be,Pe,Be){return new(Pe||(Pe=Promise))(function(Ze,Fe){function qe($n){try{ui(Be.next($n))}catch(rn){Fe(rn)}}function dn($n){try{ui(Be.throw($n))}catch(rn){Fe(rn)}}function ui($n){var rn;$n.done?Ze($n.value):(rn=$n.value,rn instanceof Pe?rn:new Pe(function(Hn){Hn(rn)})).then(qe,dn)}ui((Be=Be.apply(Ve,be||[])).next())})}function $t(Ve,be){var Pe,Be,Ze,Fe,qe={label:0,sent:function(){if(1&Ze[0])throw Ze[1];return Ze[1]},trys:[],ops:[]};return Fe={next:dn(0),throw:dn(1),return:dn(2)},typeof Symbol=="function"&&(Fe[Symbol.iterator]=function(){return this}),Fe;function dn(ui){return function($n){return function(rn){if(Pe)throw new TypeError("Generator is already executing.");for(;qe;)try{if(Pe=1,Be&&(Ze=2&rn[0]?Be.return:rn[0]?Be.throw||((Ze=Be.return)&&Ze.call(Be),0):Be.next)&&!(Ze=Ze.call(Be,rn[1])).done)return Ze;switch(Be=0,Ze&&(rn=[2&rn[0],Ze.value]),rn[0]){case 0:case 1:Ze=rn;break;case 4:return qe.label++,{value:rn[1],done:!1};case 5:qe.label++,Be=rn[1],rn=[0];continue;case 7:rn=qe.ops.pop(),qe.trys.pop();continue;default:if(Ze=qe.trys,!((Ze=Ze.length>0&&Ze[Ze.length-1])||rn[0]!==6&&rn[0]!==2)){qe=0;continue}if(rn[0]===3&&(!Ze||rn[1]>Ze[0]&&rn[1]<Ze[3])){qe.label=rn[1];break}if(rn[0]===6&&qe.label<Ze[1]){qe.label=Ze[1],Ze=rn;break}if(Ze&&qe.label<Ze[2]){qe.label=Ze[2],qe.ops.push(rn);break}Ze[2]&&qe.ops.pop(),qe.trys.pop();continue}rn=be.call(Ve,qe)}catch(Hn){rn=[6,Hn],Be=0}finally{Pe=Ze=0}if(5&rn[0])throw rn[1];return{value:rn[0]?rn[1]:void 0,done:!0}}([ui,$n])}}}function kt(){for(var Ve=0,be=0,Pe=arguments.length;be<Pe;be++)Ve+=arguments[be].length;var Be=Array(Ve),Ze=0;for(be=0;be<Pe;be++)for(var Fe=arguments[be],qe=0,dn=Fe.length;qe<dn;qe++,Ze++)Be[Ze]=Fe[qe];return Be}var Ie=function(){function Ve(){}return Ve.createDefs=function(){return document.createElementNS("http://www.w3.org/2000/svg","defs")},Ve.setAttributes=function(be,Pe){for(var Be=0,Ze=Pe;Be<Ze.length;Be++){var Fe=Ze[Be],qe=Fe[0],dn=Fe[1];be.setAttribute(qe,dn)}},Ve.createRect=function(be,Pe,Be){var Ze=document.createElementNS("http://www.w3.org/2000/svg","rect");return Ze.setAttribute("width",be.toString()),Ze.setAttribute("height",Pe.toString()),Be&&Ve.setAttributes(Ze,Be),Ze},Ve.createLine=function(be,Pe,Be,Ze,Fe){var qe=document.createElementNS("http://www.w3.org/2000/svg","line");return qe.setAttribute("x1",be.toString()),qe.setAttribute("y1",Pe.toString()),qe.setAttribute("x2",Be.toString()),qe.setAttribute("y2",Ze.toString()),Fe&&Ve.setAttributes(qe,Fe),qe},Ve.createPolygon=function(be,Pe){var Be=document.createElementNS("http://www.w3.org/2000/svg","polygon");return Be.setAttribute("points",be),Pe&&Ve.setAttributes(Be,Pe),Be},Ve.createCircle=function(be,Pe){var Be=document.createElementNS("http://www.w3.org/2000/svg","circle");return Be.setAttribute("cx",(be/2).toString()),Be.setAttribute("cy",(be/2).toString()),Be.setAttribute("r",be.toString()),Pe&&Ve.setAttributes(Be,Pe),Be},Ve.createEllipse=function(be,Pe,Be){var Ze=document.createElementNS("http://www.w3.org/2000/svg","ellipse");return Ze.setAttribute("cx",(be/2).toString()),Ze.setAttribute("cy",(Pe/2).toString()),Ze.setAttribute("rx",(be/2).toString()),Ze.setAttribute("ry",(Pe/2).toString()),Be&&Ve.setAttributes(Ze,Be),Ze},Ve.createGroup=function(be){var Pe=document.createElementNS("http://www.w3.org/2000/svg","g");return be&&Ve.setAttributes(Pe,be),Pe},Ve.createTransform=function(){return document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGTransform()},Ve.createMarker=function(be,Pe,Be,Ze,Fe,qe,dn){var ui=document.createElementNS("http://www.w3.org/2000/svg","marker");return Ve.setAttributes(ui,[["id",be],["orient",Pe],["markerWidth",Be.toString()],["markerHeight",Ze.toString()],["refX",Fe.toString()],["refY",qe.toString()]]),ui.appendChild(dn),ui},Ve.createText=function(be){var Pe=document.createElementNS("http://www.w3.org/2000/svg","text");return Pe.setAttribute("x","0"),Pe.setAttribute("y","0"),be&&Ve.setAttributes(Pe,be),Pe},Ve.createTSpan=function(be,Pe){var Be=document.createElementNS("http://www.w3.org/2000/svg","tspan");return Be.textContent=be,Pe&&Ve.setAttributes(Be,Pe),Be},Ve.createImage=function(be){var Pe=document.createElementNS("http://www.w3.org/2000/svg","image");return be&&Ve.setAttributes(Pe,be),Pe},Ve.createPoint=function(be,Pe){var Be=document.createElementNS("http://www.w3.org/2000/svg","svg").createSVGPoint();return Be.x=be,Be.y=Pe,Be},Ve.createPath=function(be,Pe){var Be=document.createElementNS("http://www.w3.org/2000/svg","path");return Be.setAttribute("d",be),Pe&&Ve.setAttributes(Be,Pe),Be},Ve}(),$e=function(){function Ve(){}return Ve.addKey=function(be){Ve.key=be},Object.defineProperty(Ve,"isLicensed",{get:function(){return!!Ve.key&&new RegExp(/^MJS2-[A-Z][0-9]{3}-[A-Z][0-9]{3}-[0-9]{4}$/,"i").test(Ve.key)},enumerable:!1,configurable:!0}),Ve}(),Mt=function(){function Ve(){this.naturalSize=!1,this.imageType="image/png",this.markersOnly=!1}return Ve.prototype.rasterize=function(be,Pe,Be){var Ze=this;return new Promise(function(Fe){var qe=Be!==void 0?Be:document.createElement("canvas");be===null&&(Ze.markersOnly=!0,Ze.naturalSize=!1);var dn=document.createElementNS("http://www.w3.org/2000/svg","svg");dn.setAttribute("xmlns","http://www.w3.org/2000/svg"),dn.setAttribute("width",Pe.width.baseVal.valueAsString),dn.setAttribute("height",Pe.height.baseVal.valueAsString),dn.setAttribute("viewBox","0 0 "+Pe.viewBox.baseVal.width.toString()+" "+Pe.viewBox.baseVal.height.toString()),dn.innerHTML=Pe.innerHTML,Ze.naturalSize===!0?(dn.width.baseVal.value=be.naturalWidth,dn.height.baseVal.value=be.naturalHeight):Ze.width!==void 0&&Ze.height!==void 0&&(dn.width.baseVal.value=Ze.width,dn.height.baseVal.value=Ze.height),qe.width=dn.width.baseVal.value,qe.height=dn.height.baseVal.value;var ui=dn.outerHTML,$n=qe.getContext("2d");Ze.markersOnly!==!0&&$n.drawImage(be,0,0,qe.width,qe.height);var rn=window.URL,Hn=new Image(qe.width,qe.height);Hn.setAttribute("crossOrigin","anonymous");var Zt=new Blob([ui],{type:"image/svg+xml"}),_n=rn.createObjectURL(Zt);Hn.onload=function(){$n.drawImage(Hn,0,0),rn.revokeObjectURL(_n);var ti=qe.toDataURL(Ze.imageType,Ze.imageQuality);Fe(ti)},Hn.src=_n})},Ve}(),Pt=function(){},wt=function(){function Ve(be){this._classNamePrefixBase="__markerjs2_",this.classes=[],this.rules=[],this.settings=this.defaultSettings,this._classNamePrefix=this._classNamePrefixBase+"_"+be+"_"}return Object.defineProperty(Ve.prototype,"classNamePrefixBase",{get:function(){return this._classNamePrefixBase},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"classNamePrefix",{get:function(){return this._classNamePrefix},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"defaultSettings",{get:function(){return{canvasBackgroundColor:"#ffffff",toolbarBackgroundColor:"#111111",toolbarBackgroundHoverColor:"#333333",toolbarColor:"#eeeeee",toolbarHeight:40,toolboxColor:"#eeeeee",toolboxAccentColor:"#3080c3",undoButtonVisible:!0,redoButtonVisible:!1,zoomButtonVisible:!1,zoomOutButtonVisible:!1,clearButtonVisible:!1,resultButtonBlockVisible:!0,logoPosition:"left"}},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"fadeInAnimationClassName",{get:function(){return this.classNamePrefix+"fade_in"},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"fadeOutAnimationClassName",{get:function(){return this.classNamePrefix+"fade_out"},enumerable:!1,configurable:!0}),Ve.prototype.addClass=function(be){return this.styleSheet===void 0&&this.addStyleSheet(),be.name=""+this.classNamePrefix+be.localName,this.classes.push(be),this.styleSheet.sheet.insertRule("."+be.name+" {"+be.style+"}",this.styleSheet.sheet.cssRules.length),be},Ve.prototype.addRule=function(be){this.styleSheet===void 0&&this.addStyleSheet(),this.rules.push(be),this.styleSheet.sheet.insertRule(be.selector+" {"+be.style+"}",this.styleSheet.sheet.cssRules.length)},Ve.prototype.addStyleSheet=function(){var be;this.styleSheet=document.createElement("style"),((be=this.styleSheetRoot)!==null&&be!==void 0?be:document.head).appendChild(this.styleSheet),this.addRule(new Qt("."+this.classNamePrefix+" h3","font-family: sans-serif")),this.addRule(new Qt("@keyframes "+this.classNamePrefix+"_fade_in_animation_frames",`
from {
opacity: 0;
}
to {
opacity: 1;
}
`)),this.addRule(new Qt("@keyframes "+this.classNamePrefix+"_fade_out_animation_frames",`
from {
opacity: 1;
}
to {
opacity: 0;
}
`)),this.addClass(new It("fade_in",`
animation-duration: 0.3s;
animation-name: `+this.classNamePrefix+`_fade_in_animation_frames;
`)),this.addClass(new It("fade_out",`
animation-duration: 0.3s;
animation-name: `+this.classNamePrefix+`_fade_out_animation_frames;
`))},Ve.prototype.removeStyleSheet=function(){var be;this.styleSheet&&(((be=this.styleSheetRoot)!==null&&be!==void 0?be:document.head).removeChild(this.styleSheet),this.styleSheet=void 0)},Ve}(),Qt=function(Ve,be){this.selector=Ve,this.style=be},It=function(Ve,be){this.localName=Ve,this.style=be},sn=function(){function Ve(be,Pe,Be,Ze,Fe){this.buttons=[],this.markerButtons=[],this.buttonClickListeners=[],this.markerjsContainer=be,this.displayMode=Pe,this.markerItems=Be,this.uiStyleSettings=Ze,this.styles=Fe,this.addStyles(),this.adjustLayout=this.adjustLayout.bind(this),this.overflowButtonClicked=this.overflowButtonClicked.bind(this),this.setCurrentMarker=this.setCurrentMarker.bind(this)}return Ve.prototype.show=function(be){var Pe=this;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=be,this.uiContainer.className=this.toolbarStyleClass.name+" "+this.styles.fadeInAnimationClassName+" "+(this.uiStyleSettings.toolbarStyleColorsClassName?this.uiStyleSettings.toolbarStyleColorsClassName:this.toolbarStyleColorsClass.name);var Be=document.createElement("div");Be.className=this.toolbarBlockStyleClass.name,Be.style.whiteSpace="nowrap",this.uiContainer.appendChild(Be),this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M10.07 14.27a.997.997 0 011.33.48l2.3 4.99 1.8-.85-2.31-4.98c-.24-.5-.02-1.1.48-1.33l.28-.08 2.3-.45L8 5.12V15.9l1.82-1.47.25-.16m3.57 7.7a.99.99 0 01-1.33-.47l-2.18-4.74-2.51 2.02c-.17.14-.38.22-.62.22a1 1 0 01-1-1V3a1 1 0 011-1c.24 0 .47.09.64.23l.01-.01 11.49 9.64a1.001 1.001 0 01-.44 1.75l-3.16.62 2.2 4.73c.26.5.02 1.09-.48 1.32l-3.62 1.69z"/></svg>',"select"),this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M9 3v1H4v2h1v13a2 2 0 002 2h10a2 2 0 002-2V6h1V4h-5V3H9M7 6h10v13H7V6m2 2v9h2V8H9m4 0v9h2V8h-2z"/></svg>',"delete"),this.uiStyleSettings.clearButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M19.36 2.72l1.42 1.42-5.72 5.71c1.07 1.54 1.22 3.39.32 4.59L9.06 8.12c1.2-.9 3.05-.75 4.59.32l5.71-5.72M5.93 17.57c-2.01-2.01-3.24-4.41-3.58-6.65l4.88-2.09 7.44 7.44-2.09 4.88c-2.24-.34-4.64-1.57-6.65-3.58z"/></svg>',"clear"),this.uiStyleSettings.undoButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M12.5 8c-2.65 0-5.05 1-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"/></svg>',"undo"),this.uiStyleSettings.redoButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M18.4 10.6C16.55 9 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16a8.002 8.002 0 017.6-5.5c1.95 0 3.73.72 5.12 1.88L13 16h9V7l-3.6 3.6z"/></svg>',"redo"),this.uiStyleSettings.zoomButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M15.5 14l5 5-1.5 1.5-5-5v-.79l-.27-.28A6.471 6.471 0 019.5 16 6.5 6.5 0 013 9.5 6.5 6.5 0 019.5 3 6.5 6.5 0 0116 9.5c0 1.61-.59 3.09-1.57 4.23l.28.27h.79m-6 0C12 14 14 12 14 9.5S12 5 9.5 5 5 7 5 9.5 7 14 9.5 14m2.5-4h-2v2H9v-2H7V9h2V7h1v2h2v1z"/></svg>',"zoom"),this.uiStyleSettings.zoomButtonVisible&&this.uiStyleSettings.zoomOutButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M15.5 14h-.79l-.28-.27A6.471 6.471 0 0016 9.5 6.5 6.5 0 009.5 3 6.5 6.5 0 003 9.5 6.5 6.5 0 009.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 5 1.5-1.5-5-5m-6 0C7 14 5 12 5 9.5S7 5 9.5 5 14 7 14 9.5 12 14 9.5 14M7 9h5v1H7V9z"/></svg>',"zoom-out"),this.uiStyleSettings.notesButtonVisible&&this.addActionButton(Be,'<svg viewBox="0 0 24 24"><path d="M18.13 12l1.26-1.26c.44-.44 1-.68 1.61-.74V9l-6-6H5c-1.11 0-2 .89-2 2v14a2 2 0 002 2h6v-1.87l.13-.13H5V5h7v7h6.13M14 4.5l5.5 5.5H14V4.5m5.13 9.33l2.04 2.04L15.04 22H13v-2.04l6.13-6.13m3.72.36l-.98.98-2.04-2.04.98-.98c.19-.2.52-.2.72 0l1.32 1.32c.2.2.2.53 0 .72z"/></svg>',"notes"),this.markerButtonBlock=document.createElement("div"),this.markerButtonBlock.className=this.toolbarBlockStyleClass.name,this.markerButtonBlock.style.flexGrow="2",this.markerButtonBlock.style.textAlign="center",this.uiContainer.appendChild(this.markerButtonBlock),this.markerButtonOverflowBlock=document.createElement("div"),this.markerButtonOverflowBlock.className=this.toolbarOverflowBlockStyleClass.name+" "+(this.uiStyleSettings.toolbarOverflowBlockStyleColorsClassName?this.uiStyleSettings.toolbarOverflowBlockStyleColorsClassName:this.toolbarOverflowBlockStyleColorsClass.name),this.markerButtonOverflowBlock.style.display="none",this.uiContainer.appendChild(this.markerButtonOverflowBlock),this.markerItems&&(this.markerItems.forEach(function(Fe){var qe=document.createElement("div");qe.className=""+Pe.toolbarButtonStyleClass.name,qe.setAttribute("data-type-name",Fe.typeName),qe.innerHTML=Fe.icon,qe.addEventListener("click",function(){Pe.markerToolbarButtonClicked(qe,Fe)}),Pe.buttons.push(qe),Pe.markerButtons.push(qe)}),this.overflowButton=document.createElement("div"),this.overflowButton.className=this.toolbarButtonStyleClass.name+" "+(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name),this.overflowButton.innerHTML='<svg viewBox="0 0 24 24"><path d="M12 16a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2m0-6a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2m0-6a2 2 0 012 2 2 2 0 01-2 2 2 2 0 01-2-2 2 2 0 012-2z"/></svg>',this.overflowButton.addEventListener("click",this.overflowButtonClicked),this.markerButtonBlock.appendChild(this.overflowButton));var Ze=document.createElement("div");Ze.className=this.toolbarBlockStyleClass.name,Ze.style.whiteSpace="nowrap",Ze.style.display=this.uiStyleSettings.resultButtonBlockVisible!==!1?"":"none",this.uiContainer.appendChild(Ze),this.addActionButton(Ze,'<svg viewBox="0 0 24 24"><path d="M9 20.42l-6.21-6.21 2.83-2.83L9 14.77l9.88-9.89 2.83 2.83L9 20.42z"/></svg>',"render"),this.addActionButton(Ze,'<svg viewBox="0 0 24 24"><path d="M20 6.91L17.09 4 12 9.09 6.91 4 4 6.91 9.09 12 4 17.09 6.91 20 12 14.91 17.09 20 20 17.09 14.91 12 20 6.91z"/></svg>',"close"),this.markerjsContainer.appendChild(this.uiContainer),this.setSelectMode(),this.setCurrentMarker(),this.adjustLayout()},Ve.prototype.addButtonClickListener=function(be){this.buttonClickListeners.push(be)},Ve.prototype.removeButtonClickListener=function(be){this.buttonClickListeners.indexOf(be)>-1&&this.buttonClickListeners.splice(this.buttonClickListeners.indexOf(be),1)},Ve.prototype.setSelectMode=function(){this.resetButtonStyles(),this.setActiveButton(this.buttons[0])},Ve.prototype.adjustLayout=function(){if(this.markerButtons&&this.markerButtons.length>0){var be=Math.floor(this.markerButtonBlock.clientWidth/this.uiStyleSettings.toolbarHeight)-1;this.markerButtonBlock.innerHTML="",this.markerButtonOverflowBlock.innerHTML="";for(var Pe=0;Pe<this.markerButtons.length;Pe++)Pe<be||Pe===be&&this.markerButtons.length-1===be?this.markerButtonBlock.appendChild(this.markerButtons[Pe]):(Pe===be&&this.markerButtonBlock.appendChild(this.overflowButton),this.markerButtonOverflowBlock.appendChild(this.markerButtons[Pe]))}},Ve.prototype.overflowButtonClicked=function(){this.markerButtonOverflowBlock.style.display!=="none"?(this.markerButtonOverflowBlock.className=this.markerButtonOverflowBlock.className.replace(this.styles.fadeInAnimationClassName,""),this.markerButtonOverflowBlock.style.display="none"):(this.markerButtonOverflowBlock.className+=" "+this.styles.fadeInAnimationClassName,this.markerButtonOverflowBlock.style.top=this.uiContainer.offsetTop+this.overflowButton.offsetHeight+"px",this.markerButtonOverflowBlock.style.right=this.uiContainer.offsetWidth-this.overflowButton.offsetLeft-this.overflowButton.offsetWidth+2*this.uiContainer.offsetLeft+"px",this.markerButtonOverflowBlock.style.display="inline-block")},Ve.prototype.resetButtonStyles=function(){var be=this;this.buttons.forEach(function(Pe){Pe.className=Pe.className.replace(be.uiStyleSettings.toolbarButtonStyleColorsClassName?be.uiStyleSettings.toolbarButtonStyleColorsClassName:be.toolbarButtonStyleColorsClass.name,"").trim(),Pe.className=Pe.className.replace(be.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?be.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:be.toolbarActiveButtonStyleColorsClass.name,"").trim(),Pe.className+=" "+(be.uiStyleSettings.toolbarButtonStyleColorsClassName?be.uiStyleSettings.toolbarButtonStyleColorsClassName:be.toolbarButtonStyleColorsClass.name)})},Ve.prototype.addActionButton=function(be,Pe,Be){var Ze=this,Fe=document.createElement("div");switch(Fe.className=""+this.toolbarButtonStyleClass.name,Fe.innerHTML=Pe,Fe.setAttribute("data-action",Be),Fe.addEventListener("click",function(){Ze.actionToolbarButtonClicked(Fe,Be)}),Be){case"select":Fe.style.fill=this.uiStyleSettings.selectButtonColor;break;case"delete":case"clear":Fe.style.fill=this.uiStyleSettings.deleteButtonColor;break;case"undo":case"redo":Fe.style.fill=this.uiStyleSettings.selectButtonColor;break;case"render":Fe.style.fill=this.uiStyleSettings.okButtonColor;break;case"close":Fe.style.fill=this.uiStyleSettings.closeButtonColor}be.appendChild(Fe),this.buttons.push(Fe)},Ve.prototype.addStyles=function(){this.toolbarStyleClass=this.styles.addClass(new It("toolbar",`
width: 100%;
flex-shrink: 0;
display: flex;
flex-direction: row;
justify-content: space-between;
height: `+this.uiStyleSettings.toolbarHeight+`px;
box-sizing: content-box;
`+(this.displayMode==="inline"?"border-top-left-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
`+(this.displayMode==="inline"?"border-top-right-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
overflow: hidden;
`)),this.toolbarStyleColorsClass=this.styles.addClass(new It("toolbar_colors",`
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
box-shadow: 0px 3px rgba(33, 33, 33, 0.1);
`)),this.toolbarBlockStyleClass=this.styles.addClass(new It("toolbar-block",`
display: inline-block;
box-sizing: content-box;
`)),this.toolbarOverflowBlockStyleClass=this.styles.addClass(new It("toolbar-overflow-block",`
position: absolute;
top: `+this.uiStyleSettings.toolbarHeight+`px;
max-width: `+2*this.uiStyleSettings.toolbarHeight+`px;
z-index: 10;
box-sizing: content-box;
`)),this.toolbarOverflowBlockStyleColorsClass=this.styles.addClass(new It("toolbar-overflow-block_colors",`
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
`));var be=this.uiStyleSettings.toolbarHeight/4;this.toolbarButtonStyleClass=this.styles.addClass(new It("toolbar_button",`
display: inline-block;
width: `+(this.uiStyleSettings.toolbarHeight-2*be)+`px;
height: `+(this.uiStyleSettings.toolbarHeight-2*be)+`px;
padding: `+be+`px;
box-sizing: content-box;
`)),this.toolbarButtonStyleColorsClass=this.styles.addClass(new It("toolbar_button_colors",`
fill: `+this.uiStyleSettings.toolbarColor+`;
`)),this.toolbarActiveButtonStyleColorsClass=this.styles.addClass(new It("toolbar_active_button",`
fill: `+this.uiStyleSettings.toolbarColor+`;
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
`)),this.styles.addRule(new Qt("."+this.toolbarButtonStyleClass.name+" svg",`
height: `+this.uiStyleSettings.toolbarHeight/2+`px;
`)),this.styles.addRule(new Qt("."+this.toolbarButtonStyleColorsClass.name+":hover",`
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
`))},Ve.prototype.markerToolbarButtonClicked=function(be,Pe){this.setActiveButton(be),this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach(function(Be){return Be("marker",Pe)}),this.markerButtonOverflowBlock.style.display="none"},Ve.prototype.actionToolbarButtonClicked=function(be,Pe){this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach(function(Be){return Be("action",Pe)}),this.markerButtonOverflowBlock.style.display="none",this.setActiveButton(this.buttons[0])},Ve.prototype.setActiveButton=function(be){this.resetButtonStyles(),be.className=be.className.replace(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,"").trim(),be.className+=" "+(this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name)},Ve.prototype.setActiveMarkerButton=function(be){var Pe=this.markerButtons.find(function(Be){return Be.getAttribute("data-type-name")===be});Pe&&this.setActiveButton(Pe)},Ve.prototype.setCurrentMarker=function(be){var Pe=this;this.currentMarker=be,this.buttons.filter(function(Be){return/delete|notes/.test(Be.getAttribute("data-action"))}).forEach(function(Be){Pe.currentMarker===void 0?(Be.style.fillOpacity="0.4",Be.style.pointerEvents="none"):(Be.style.fillOpacity="1",Be.style.pointerEvents="all")})},Ve}(),Re=function(){function Ve(be,Pe,Be,Ze){this.panels=[],this.panelButtons=[],this.markerjsContainer=be,this.displayMode=Pe,this.uiStyleSettings=Be,this.styles=Ze,this.panelButtonClick=this.panelButtonClick.bind(this),this.addStyles()}return Ve.prototype.addStyles=function(){var be;this.toolboxStyleClass=this.styles.addClass(new It("toolbox",`
width: 100%;
flex-shrink: 0;
display: flex;
flex-direction: column;
font-family: sans-serif;
`+(this.displayMode==="popup"?"height:"+2.5*this.uiStyleSettings.toolbarHeight+"px;":"")+`
box-sizing: content-box;
`+(this.displayMode==="popup"?"background-color: "+this.uiStyleSettings.canvasBackgroundColor+";":"")+`
`+(this.displayMode==="inline"?"border-bottom-left-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
`+(this.displayMode==="inline"?"border-bottom-right-radius: "+Math.round(this.uiStyleSettings.toolbarHeight/10)+"px;":"")+`
overflow: hidden;
`)),this.toolboxStyleColorsClass=this.styles.addClass(new It("toolbox_colors",`
color: `+this.uiStyleSettings.toolboxColor+`;
`));var Pe=this.uiStyleSettings.toolbarHeight/4;this.toolboxButtonRowStyleClass=this.styles.addClass(new It("toolbox-button-row",`
display: flex;
cursor: default;
box-sizing: content-box;
`)),this.toolboxButtonRowStyleColorsClass=this.styles.addClass(new It("toolbox-button-row_colors",`
background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`;
`)),this.toolboxPanelRowStyleClass=this.styles.addClass(new It("toolbox-panel-row",`
display: flex;
`+(this.displayMode==="inline"?"position: absolute;":"")+`
`+(this.displayMode==="inline"?"bottom: "+this.uiStyleSettings.toolbarHeight+"px;":"")+`
cursor: default;
height: `+1.5*this.uiStyleSettings.toolbarHeight+`px;
`+(this.displayMode==="inline"?"width: 100%;":"")+`
box-sizing: content-box;
`)),this.toolboxPanelRowStyleColorsClass=this.styles.addClass(new It("toolbox-panel-row_colors",`
background-color: `+((be=this.uiStyleSettings.toolboxBackgroundColor)!==null&&be!==void 0?be:this.uiStyleSettings.toolbarBackgroundHoverColor)+`;
`)),this.toolboxButtonStyleClass=this.styles.addClass(new It("toolbox_button",`
display: inline-block;
width: `+(this.uiStyleSettings.toolbarHeight-2*Pe)+`px;
height: `+(this.uiStyleSettings.toolbarHeight-2*Pe)+`px;
padding: `+Pe+`px;
box-sizing: content-box;
`)),this.toolboxButtonStyleColorsClass=this.styles.addClass(new It("toolbox-button_colors",`
fill: `+this.uiStyleSettings.toolbarColor+`;
`)),this.toolboxActiveButtonStyleColorsClass=this.styles.addClass(new It("toolbox-active-button_colors",`
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`;
fill: `+this.uiStyleSettings.toolbarColor+`;
`)),this.styles.addRule(new Qt("."+this.toolboxButtonStyleColorsClass.name+":hover",`
background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`
`)),this.styles.addRule(new Qt("."+this.toolboxButtonStyleClass.name+" svg",`
height: `+this.uiStyleSettings.toolbarHeight/2+`px;
`))},Ve.prototype.show=function(be){var Pe;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=be,this.uiContainer.className=this.toolboxStyleClass.name+" "+((Pe=this.uiStyleSettings.toolboxStyleColorsClassName)!==null&&Pe!==void 0?Pe:this.toolboxStyleColorsClass.name),this.markerjsContainer.appendChild(this.uiContainer)},Ve.prototype.setPanelButtons=function(be){var Pe,Be,Ze=this;this.panels=be,this.uiContainer!==void 0&&(this.uiContainer.innerHTML="",this.panelRow=document.createElement("div"),this.panelRow.className=this.toolboxPanelRowStyleClass.name+" "+((Pe=this.uiStyleSettings.toolboxPanelRowStyleColorsClassName)!==null&&Pe!==void 0?Pe:this.toolboxPanelRowStyleColorsClass.name),this.uiContainer.appendChild(this.panelRow),this.buttonRow=document.createElement("div"),this.buttonRow.className=this.toolboxButtonRowStyleClass.name+" "+((Be=this.uiStyleSettings.toolboxButtonRowStyleColorsClassName)!==null&&Be!==void 0?Be:this.toolboxButtonRowStyleColorsClass.name)+" ",this.uiContainer.appendChild(this.buttonRow),this.panelButtons.splice(0),this.panels.forEach(function(Fe){var qe;Fe.uiStyleSettings=Ze.uiStyleSettings;var dn=document.createElement("div");dn.className=Ze.toolboxButtonStyleClass.name+" "+((qe=Ze.uiStyleSettings.toolboxButtonStyleColorsClassName)!==null&&qe!==void 0?qe:Ze.toolboxButtonStyleColorsClass.name),dn.innerHTML=Fe.icon,dn.title=Fe.title,dn.addEventListener("click",function(){Ze.panelButtonClick(Fe)}),Ze.panelButtons.push(dn),Ze.buttonRow.appendChild(dn)}),this.displayMode==="inline"?this.panelRow.style.display="none":this.panelRow.style.visibility="hidden")},Ve.prototype.panelButtonClick=function(be){var Pe=this,Be=-1;if(be!==this.activePanel){Be=this.panels.indexOf(be),this.panelRow.innerHTML="";var Ze=be.getUi();Ze.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.panelRow.appendChild(Ze),this.panelRow.style.display="flex",this.panelRow.style.visibility="visible",this.panelRow.className=this.panelRow.className.replace(this.styles.fadeOutAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeInAnimationClassName,this.activePanel=be}else this.activePanel=void 0,this.panelRow.className=this.panelRow.className.replace(this.styles.fadeInAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeOutAnimationClassName,setTimeout(function(){Pe.displayMode==="inline"?Pe.panelRow.style.display="none":Pe.panelRow.style.visibility="hidden"},200);this.panelButtons.forEach(function(Fe,qe){var dn,ui;Fe.className=Pe.toolboxButtonStyleClass.name+" "+(qe===Be?""+((dn=Pe.uiStyleSettings.toolboxActiveButtonStyleColorsClassName)!==null&&dn!==void 0?dn:Pe.toolboxActiveButtonStyleColorsClass.name):""+((ui=Pe.uiStyleSettings.toolboxButtonStyleColorsClassName)!==null&&ui!==void 0?ui:Pe.toolboxButtonStyleColorsClass.name))})},Ve}(),ne=function(Ve,be){this.title=Ve,this.icon=be},te=function(Ve){function be(Pe,Be,Ze,Fe){var qe=Ve.call(this,Pe,Fe||'<svg viewBox="0 0 24 24"><path d="M17.5 12a1.5 1.5 0 01-1.5-1.5A1.5 1.5 0 0117.5 9a1.5 1.5 0 011.5 1.5 1.5 1.5 0 01-1.5 1.5m-3-4A1.5 1.5 0 0113 6.5 1.5 1.5 0 0114.5 5 1.5 1.5 0 0116 6.5 1.5 1.5 0 0114.5 8m-5 0A1.5 1.5 0 018 6.5 1.5 1.5 0 019.5 5 1.5 1.5 0 0111 6.5 1.5 1.5 0 019.5 8m-3 4A1.5 1.5 0 015 10.5 1.5 1.5 0 016.5 9 1.5 1.5 0 018 10.5 1.5 1.5 0 016.5 12M12 3a9 9 0 00-9 9 9 9 0 009 9 1.5 1.5 0 001.5-1.5c0-.39-.15-.74-.39-1-.23-.27-.38-.62-.38-1a1.5 1.5 0 011.5-1.5H16a5 5 0 005-5c0-4.42-4.03-8-9-8z"/></svg>')||this;return qe.colors=[],qe.addTransparent=!1,qe.colorBoxes=[],qe.colors=Be,qe.currentColor=Ze,qe.setCurrentColor=qe.setCurrentColor.bind(qe),qe.getColorBox=qe.getColorBox.bind(qe),qe}return dt(be,Ve),be.prototype.getUi=function(){var Pe=this,Be=document.createElement("div");return Be.style.overflow="hidden",Be.style.whiteSpace="nowrap",this.colors.forEach(function(Ze){var Fe=Pe.getColorBox(Ze);Be.appendChild(Fe),Pe.colorBoxes.push(Fe)}),Be},be.prototype.getColorBox=function(Pe){var Be=this,Ze=this.uiStyleSettings.toolbarHeight/4,Fe=this.uiStyleSettings.toolbarHeight-Ze,qe=document.createElement("div");qe.style.display="inline-block",qe.style.boxSizing="content-box",qe.style.width=Fe-2+"px",qe.style.height=Fe-2+"px",qe.style.padding="1px",qe.style.marginRight="2px",qe.style.marginBottom="2px",qe.style.borderWidth="2px",qe.style.borderStyle="solid",qe.style.borderRadius=(Fe+2)/2+"px",qe.style.borderColor=Pe===this.currentColor?this.uiStyleSettings.toolboxAccentColor:"transparent",qe.addEventListener("click",function(){Be.setCurrentColor(Pe,qe)});var dn=document.createElement("div");return dn.style.display="inline-block",dn.style.width=Fe-2+"px",dn.style.height=Fe-2+"px",dn.style.backgroundColor=Pe,dn.style.borderRadius=Fe/2+"px",Pe==="transparent"&&(dn.style.fill=this.uiStyleSettings.toolboxAccentColor,dn.innerHTML=`<svg viewBox="0 0 24 24">
<path d="M2,5.27L3.28,4L20,20.72L18.73,22L15.65,18.92C14.5,19.3 13.28,19.5 12,19.5C7,19.5 2.73,16.39 1,12C1.69,10.24 2.79,8.69 4.19,7.46L2,5.27M12,9A3,3 0 0,1 15,12C15,12.35 14.94,12.69 14.83,13L11,9.17C11.31,9.06 11.65,9 12,9M12,4.5C17,4.5 21.27,7.61 23,12C22.18,14.08 20.79,15.88 19,17.19L17.58,15.76C18.94,14.82 20.06,13.54 20.82,12C19.17,8.64 15.76,6.5 12,6.5C10.91,6.5 9.84,6.68 8.84,7L7.3,5.47C8.74,4.85 10.33,4.5 12,4.5M3.18,12C4.83,15.36 8.24,17.5 12,17.5C12.69,17.5 13.37,17.43 14,17.29L11.72,15C10.29,14.85 9.15,13.71 9,12.28L5.6,8.87C4.61,9.72 3.78,10.78 3.18,12Z" />
</svg>`),qe.appendChild(dn),qe},be.prototype.setCurrentColor=function(Pe,Be){var Ze=this;this.currentColor=Pe,this.colorBoxes.forEach(function(Fe){Fe.style.borderColor=Fe===Be?Ze.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onColorChanged&&this.onColorChanged(Pe)},be}(ne),he=function(){function Ve(be,Pe,Be){this._state="new",this._isSelected=!1,this._container=be,this._overlayContainer=Pe,this.globalSettings=Be,this.stateChanged=this.stateChanged.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this)}return Object.defineProperty(Ve.prototype,"typeName",{get:function(){return Object.getPrototypeOf(this).constructor.typeName},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"container",{get:function(){return this._container},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"overlayContainer",{get:function(){return this._overlayContainer},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"state",{get:function(){return this._state},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"toolboxPanels",{get:function(){return[]},enumerable:!1,configurable:!0}),Ve.prototype.ownsTarget=function(be){return!1},Object.defineProperty(Ve.prototype,"isSelected",{get:function(){return this._isSelected},enumerable:!1,configurable:!0}),Ve.prototype.select=function(){this.container.style.cursor="move",this._isSelected=!0,this.manipulationStartState=this.getState()},Ve.prototype.deselect=function(){this.container.style.cursor="default",this._isSelected=!1,this.stateChanged()},Ve.prototype.pointerDown=function(be,Pe){},Ve.prototype.dblClick=function(be,Pe){},Ve.prototype.manipulate=function(be){},Ve.prototype.pointerUp=function(be){this.stateChanged()},Ve.prototype.dispose=function(){},Ve.prototype.addMarkerVisualToContainer=function(be){this.container.childNodes.length>0?this.container.insertBefore(be,this.container.childNodes[0]):this.container.appendChild(be)},Ve.prototype.getState=function(){return{typeName:Ve.typeName,state:this.state,notes:this.notes}},Ve.prototype.restoreState=function(be){this._state=be.state,this.notes=be.notes},Ve.prototype.scale=function(be,Pe){},Ve.prototype.colorChanged=function(be){this.onColorChanged&&this.onColorChanged(be),this.stateChanged()},Ve.prototype.fillColorChanged=function(be){this.onFillColorChanged&&this.onFillColorChanged(be),this.stateChanged()},Ve.prototype.stateChanged=function(){if(this.onStateChanged&&this.state!=="creating"&&this.state!=="new"){var be=this.getState();this.manipulationStartState!==void 0&&(this.manipulationStartState.state="select"),be.state="select",JSON.stringify(this.manipulationStartState)!=JSON.stringify(be)&&this.onStateChanged(this)}},Ve.typeName="MarkerBase",Ve}(),le=function(){function Ve(){this.findGripByVisual=this.findGripByVisual.bind(this)}return Ve.prototype.findGripByVisual=function(be){return this.topLeft.ownsTarget(be)?this.topLeft:this.topCenter.ownsTarget(be)?this.topCenter:this.topRight.ownsTarget(be)?this.topRight:this.centerLeft.ownsTarget(be)?this.centerLeft:this.centerRight.ownsTarget(be)?this.centerRight:this.bottomLeft.ownsTarget(be)?this.bottomLeft:this.bottomCenter.ownsTarget(be)?this.bottomCenter:this.bottomRight.ownsTarget(be)?this.bottomRight:void 0},Ve}(),pe=function(){function Ve(){this.GRIP_SIZE=10,this.visual=Ie.createGroup(),this.visual.appendChild(Ie.createCircle(1.5*this.GRIP_SIZE,[["fill","transparent"]])),this.visual.appendChild(Ie.createCircle(this.GRIP_SIZE,[["fill","#cccccc"],["fill-opacity","0.7"],["stroke","#333333"],["stroke-width","2"],["stroke-opacity","0.7"]]))}return Ve.prototype.ownsTarget=function(be){return be===this.visual||be===this.visual.childNodes[0]||be===this.visual.childNodes[1]},Ve}(),me=function(){function Ve(){}return Ve.toITransformMatrix=function(be){return{a:be.a,b:be.b,c:be.c,d:be.d,e:be.e,f:be.f}},Ve.toSVGMatrix=function(be,Pe){return be.a=Pe.a,be.b=Pe.b,be.c=Pe.c,be.d=Pe.d,be.e=Pe.e,be.f=Pe.f,be},Ve}(),xe=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.left=0,Fe.top=0,Fe.width=0,Fe.height=0,Fe.defaultSize={x:50,y:20},Fe.offsetX=0,Fe.offsetY=0,Fe.rotationAngle=0,Fe.CB_DISTANCE=10,Fe._suppressMarkerCreateEvent=!1,Fe.container.transform.baseVal.appendItem(Ie.createTransform()),Fe.setupControlBox(),Fe}return dt(be,Ve),Object.defineProperty(be.prototype,"centerX",{get:function(){return this.left+this.width/2},enumerable:!1,configurable:!0}),Object.defineProperty(be.prototype,"centerY",{get:function(){return this.top+this.height/2},enumerable:!1,configurable:!0}),Object.defineProperty(be.prototype,"visual",{get:function(){return this._visual},set:function(Pe){this._visual=Pe;var Be=Ie.createTransform();this._visual.transform.baseVal.appendItem(Be)},enumerable:!1,configurable:!0}),be.prototype.ownsTarget=function(Pe){return!!Ve.prototype.ownsTarget.call(this,Pe)||!!(this.controlGrips.findGripByVisual(Pe)!==void 0||this.rotatorGrip!==void 0&&this.rotatorGrip.ownsTarget(Pe))},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.state==="new"&&(this.left=Pe.x,this.top=Pe.y),this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.manipulationStartWidth=this.width,this.manipulationStartHeight=this.height;var Ze=this.unrotatePoint(Pe);if(this.manipulationStartX=Ze.x,this.manipulationStartY=Ze.y,this.offsetX=Ze.x-this.left,this.offsetY=Ze.y-this.top,this.state!=="new")if(this.select(),this.activeGrip=this.controlGrips.findGripByVisual(Be),this.activeGrip!==void 0)this._state="resize";else if(this.rotatorGrip!==void 0&&this.rotatorGrip.ownsTarget(Be)){this.activeGrip=this.rotatorGrip;var Fe=this.rotatePoint({x:this.centerX,y:this.centerY});this.left=Fe.x-this.width/2,this.top=Fe.y-this.height/2,this.moveVisual({x:this.left,y:this.top});var qe=this.container.transform.baseVal.getItem(0);qe.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(qe,0),this.adjustControlBox(),this._state="rotate"}else this._state="move"},be.prototype.pointerUp=function(Pe){var Be=this.state;Ve.prototype.pointerUp.call(this,Pe),this.state==="creating"&&this.width<10&&this.height<10?(this.width=this.defaultSize.x,this.height=this.defaultSize.y):this.manipulate(Pe),this._state="select",Be==="creating"&&this.onMarkerCreated&&this._suppressMarkerCreateEvent===!1&&this.onMarkerCreated(this)},be.prototype.moveVisual=function(Pe){this.visual.style.transform="translate("+Pe.x+"px, "+Pe.y+"px)"},be.prototype.manipulate=function(Pe){var Be=this.unrotatePoint(Pe);this.state==="creating"?this.resize(Pe):this.state==="move"?(this.left=this.manipulationStartLeft+(Be.x-this.manipulationStartLeft)-this.offsetX,this.top=this.manipulationStartTop+(Be.y-this.manipulationStartTop)-this.offsetY,this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()):this.state==="resize"?this.resize(Be):this.state==="rotate"&&this.rotate(Pe)},be.prototype.resize=function(Pe){var Be=this.manipulationStartLeft,Ze=this.manipulationStartWidth,Fe=this.manipulationStartTop,qe=this.manipulationStartHeight;switch(this.activeGrip){case this.controlGrips.bottomLeft:case this.controlGrips.centerLeft:case this.controlGrips.topLeft:Be=this.manipulationStartLeft+Pe.x-this.manipulationStartX,Ze=this.manipulationStartWidth+this.manipulationStartLeft-Be;break;case this.controlGrips.bottomRight:case this.controlGrips.centerRight:case this.controlGrips.topRight:case void 0:Ze=this.manipulationStartWidth+Pe.x-this.manipulationStartX}switch(this.activeGrip){case this.controlGrips.topCenter:case this.controlGrips.topLeft:case this.controlGrips.topRight:Fe=this.manipulationStartTop+Pe.y-this.manipulationStartY,qe=this.manipulationStartHeight+this.manipulationStartTop-Fe;break;case this.controlGrips.bottomCenter:case this.controlGrips.bottomLeft:case this.controlGrips.bottomRight:case void 0:qe=this.manipulationStartHeight+Pe.y-this.manipulationStartY}Ze>=0?(this.left=Be,this.width=Ze):(this.left=Be+Ze,this.width=-Ze),qe>=0?(this.top=Fe,this.height=qe):(this.top=Fe+qe,this.height=-qe),this.setSize()},be.prototype.setSize=function(){this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()},be.prototype.rotate=function(Pe){if(Math.abs(Pe.x-this.centerX)>.1){var Be=Math.sign(Pe.x-this.centerX);this.rotationAngle=180*Math.atan((Pe.y-this.centerY)/(Pe.x-this.centerX))/Math.PI+90*Be,this.applyRotation()}},be.prototype.applyRotation=function(){var Pe=this.container.transform.baseVal.getItem(0);Pe.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(Pe,0)},be.prototype.rotatePoint=function(Pe){if(this.rotationAngle===0)return Pe;var Be=this.container.getCTM(),Ze=Ie.createPoint(Pe.x,Pe.y);return{x:(Ze=Ze.matrixTransform(Be)).x,y:Ze.y}},be.prototype.unrotatePoint=function(Pe){if(this.rotationAngle===0)return Pe;var Be=this.container.getCTM();Be=Be.inverse();var Ze=Ie.createPoint(Pe.x,Pe.y);return{x:(Ze=Ze.matrixTransform(Be)).x,y:Ze.y}},be.prototype.select=function(){Ve.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},be.prototype.deselect=function(){Ve.prototype.deselect.call(this),this.controlBox.style.display="none"},be.prototype.setupControlBox=function(){this.controlBox=Ie.createGroup();var Pe=Ie.createTransform();Pe.setTranslate(-this.CB_DISTANCE/2,-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.appendItem(Pe),this.container.appendChild(this.controlBox),this.controlRect=Ie.createRect(this.width+this.CB_DISTANCE,this.height+this.CB_DISTANCE,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"],["fill","transparent"],["pointer-events","none"]]),this.controlBox.appendChild(this.controlRect),this.globalSettings.disableRotation!==!0&&(this.rotatorGripLine=Ie.createLine((this.width+2*this.CB_DISTANCE)/2,this.top-this.CB_DISTANCE,(this.width+2*this.CB_DISTANCE)/2,this.top-3*this.CB_DISTANCE,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.controlBox.appendChild(this.rotatorGripLine)),this.controlGrips=new le,this.addControlGrips(),this.controlBox.style.display="none"},be.prototype.adjustControlBox=function(){var Pe=this.controlBox.transform.baseVal.getItem(0);Pe.setTranslate(this.left-this.CB_DISTANCE/2,this.top-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.replaceItem(Pe,0),this.controlRect.setAttribute("width",(this.width+this.CB_DISTANCE).toString()),this.controlRect.setAttribute("height",(this.height+this.CB_DISTANCE).toString()),this.rotatorGripLine!==void 0&&(this.rotatorGripLine.setAttribute("x1",((this.width+this.CB_DISTANCE)/2).toString()),this.rotatorGripLine.setAttribute("y1",(-this.CB_DISTANCE/2).toString()),this.rotatorGripLine.setAttribute("x2",((this.width+this.CB_DISTANCE)/2).toString()),this.rotatorGripLine.setAttribute("y2",(3*-this.CB_DISTANCE).toString())),this.positionGrips()},be.prototype.addControlGrips=function(){this.controlGrips.topLeft=this.createGrip(),this.controlGrips.topCenter=this.createGrip(),this.controlGrips.topRight=this.createGrip(),this.controlGrips.centerLeft=this.createGrip(),this.controlGrips.centerRight=this.createGrip(),this.controlGrips.bottomLeft=this.createGrip(),this.controlGrips.bottomCenter=this.createGrip(),this.controlGrips.bottomRight=this.createGrip(),this.globalSettings.disableRotation!==!0&&(this.rotatorGrip=this.createGrip()),this.positionGrips()},be.prototype.createGrip=function(){var Pe=new pe;return Pe.visual.transform.baseVal.appendItem(Ie.createTransform()),this.controlBox.appendChild(Pe.visual),Pe},be.prototype.positionGrips=function(){var Pe=this.controlGrips.topLeft.GRIP_SIZE,Be=-Pe/2,Ze=Be,Fe=(this.width+this.CB_DISTANCE)/2-Pe/2,qe=(this.height+this.CB_DISTANCE)/2-Pe/2,dn=this.height+this.CB_DISTANCE-Pe/2,ui=this.width+this.CB_DISTANCE-Pe/2;this.positionGrip(this.controlGrips.topLeft.visual,Be,Ze),this.positionGrip(this.controlGrips.topCenter.visual,Fe,Ze),this.positionGrip(this.controlGrips.topRight.visual,ui,Ze),this.positionGrip(this.controlGrips.centerLeft.visual,Be,qe),this.positionGrip(this.controlGrips.centerRight.visual,ui,qe),this.positionGrip(this.controlGrips.bottomLeft.visual,Be,dn),this.positionGrip(this.controlGrips.bottomCenter.visual,Fe,dn),this.positionGrip(this.controlGrips.bottomRight.visual,ui,dn),this.rotatorGrip!==void 0&&this.positionGrip(this.rotatorGrip.visual,Fe,Ze-3*this.CB_DISTANCE)},be.prototype.positionGrip=function(Pe,Be,Ze){var Fe=Pe.transform.baseVal.getItem(0);Fe.setTranslate(Be,Ze),Pe.transform.baseVal.replaceItem(Fe,0)},be.prototype.hideControlBox=function(){this.controlBox.style.display="none"},be.prototype.showControlBox=function(){this.controlBox.style.display=""},be.prototype.getState=function(){return Object.assign({left:this.left,top:this.top,width:this.width,height:this.height,rotationAngle:this.rotationAngle,visualTransformMatrix:me.toITransformMatrix(this.visual.transform.baseVal.getItem(0).matrix),containerTransformMatrix:me.toITransformMatrix(this.container.transform.baseVal.getItem(0).matrix)},Ve.prototype.getState.call(this))},be.prototype.restoreState=function(Pe){Ve.prototype.restoreState.call(this,Pe);var Be=Pe;this.left=Be.left,this.top=Be.top,this.width=Be.width,this.height=Be.height,this.rotationAngle=Be.rotationAngle,this.visual.transform.baseVal.getItem(0).setMatrix(me.toSVGMatrix(this.visual.transform.baseVal.getItem(0).matrix,Be.visualTransformMatrix)),this.container.transform.baseVal.getItem(0).setMatrix(me.toSVGMatrix(this.container.transform.baseVal.getItem(0).matrix,Be.containerTransformMatrix))},be.prototype.scale=function(Pe,Be){Ve.prototype.scale.call(this,Pe,Be);var Ze=this.rotatePoint({x:this.left,y:this.top}),Fe=this.unrotatePoint({x:Ze.x*Pe,y:Ze.y*Be});this.left=Fe.x,this.top=Fe.y,this.width=this.width*Pe,this.height=this.height*Be,this.adjustControlBox()},be}(he),Ee=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.fillColor="transparent",Fe.strokeColor="transparent",Fe.strokeWidth=0,Fe.strokeDasharray="",Fe.opacity=1,Fe.setStrokeColor=Fe.setStrokeColor.bind(Fe),Fe.setFillColor=Fe.setFillColor.bind(Fe),Fe.setStrokeWidth=Fe.setStrokeWidth.bind(Fe),Fe.setStrokeDasharray=Fe.setStrokeDasharray.bind(Fe),Fe.createVisual=Fe.createVisual.bind(Fe),Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return!(!Ve.prototype.ownsTarget.call(this,Pe)&&Pe!==this.visual)},be.prototype.createVisual=function(){this.visual=Ie.createRect(1,1,[["fill",this.fillColor],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray],["opacity",this.opacity.toString()]]),this.addMarkerVisualToContainer(this.visual)},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.state==="new"&&(this.createVisual(),this.moveVisual(Pe),this._state="creating")},be.prototype.manipulate=function(Pe){Ve.prototype.manipulate.call(this,Pe)},be.prototype.resize=function(Pe){Ve.prototype.resize.call(this,Pe),this.setSize()},be.prototype.setSize=function(){Ve.prototype.setSize.call(this),Ie.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]])},be.prototype.pointerUp=function(Pe){Ve.prototype.pointerUp.call(this,Pe),this.setSize()},be.prototype.setStrokeColor=function(Pe){this.strokeColor=Pe,this.visual&&Ie.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(Pe),this.stateChanged()},be.prototype.setFillColor=function(Pe){this.fillColor=Pe,this.visual&&Ie.setAttributes(this.visual,[["fill",this.fillColor]]),this.stateChanged()},be.prototype.setStrokeWidth=function(Pe){this.strokeWidth=Pe,this.visual&&Ie.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},be.prototype.setStrokeDasharray=function(Pe){this.strokeDasharray=Pe,this.visual&&Ie.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},be.prototype.getState=function(){return Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},Ve.prototype.getState.call(this))},be.prototype.restoreState=function(Pe){var Be=Pe;this.fillColor=Be.fillColor,this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.opacity=Be.opacity,this.createVisual(),Ve.prototype.restoreState.call(this,Pe),this.setSize()},be.prototype.scale=function(Pe,Be){Ve.prototype.scale.call(this,Pe,Be),this.setSize()},be.title="Rectangle marker",be}(xe),Ge=function(Ve){function be(Pe,Be,Ze,Fe){var qe=Ve.call(this,Pe,Fe||'<svg viewBox="0 0 24 24"><path d="M3 17h18v-2H3v2m0 3h18v-1H3v1m0-7h18v-3H3v3m0-9v4h18V4H3z"/></svg>')||this;return qe.widths=[],qe.widthBoxes=[],qe.widths=Be,qe.currentWidth=Ze,qe.setCurrentWidth=qe.setCurrentWidth.bind(qe),qe}return dt(be,Ve),be.prototype.getUi=function(){var Pe=this,Be=document.createElement("div");return Be.style.display="flex",Be.style.overflow="hidden",Be.style.flexGrow="2",this.widths.forEach(function(Ze){var Fe=document.createElement("div");Fe.style.display="flex",Fe.style.flexGrow="2",Fe.style.alignItems="center",Fe.style.justifyContent="space-between",Fe.style.padding="5px",Fe.style.borderWidth="2px",Fe.style.borderStyle="solid",Fe.style.borderColor=Ze===Pe.currentWidth?Pe.uiStyleSettings.toolboxAccentColor:"transparent",Fe.addEventListener("click",function(){Pe.setCurrentWidth(Ze,Fe)}),Be.appendChild(Fe);var qe=document.createElement("div");qe.innerText=Ze.toString(),qe.style.marginRight="5px",Fe.appendChild(qe);var dn=document.createElement("div");dn.style.minHeight="20px",dn.style.flexGrow="2",dn.style.display="flex",dn.style.alignItems="center";var ui=document.createElement("hr");ui.style.minWidth="20px",ui.style.border="0px",ui.style.borderTop=Ze+"px solid "+Pe.uiStyleSettings.toolboxColor,ui.style.flexGrow="2",dn.appendChild(ui),Fe.appendChild(dn),Pe.widthBoxes.push(Fe)}),Be},be.prototype.setCurrentWidth=function(Pe,Be){var Ze=this;this.currentWidth=Pe,this.widthBoxes.forEach(function(Fe){Fe.style.borderColor=Fe===Be?Ze.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onWidthChanged&&this.onWidthChanged(this.currentWidth)},be}(ne),et=function(Ve){function be(Pe,Be,Ze,Fe){var qe=Ve.call(this,Pe,Fe||'<svg viewBox="0 0 24 24"><path d="M3 16h5v-2H3v2m6.5 0h5v-2h-5v2m6.5 0h5v-2h-5v2M3 20h2v-2H3v2m4 0h2v-2H7v2m4 0h2v-2h-2v2m4 0h2v-2h-2v2m4 0h2v-2h-2v2M3 12h8v-2H3v2m10 0h8v-2h-8v2M3 4v4h18V4H3z"/></svg>')||this;return qe.styles=[],qe.styleBoxes=[],qe.styles=Be,qe.currentStyle=Ze,qe.setCurrentStyle=qe.setCurrentStyle.bind(qe),qe}return dt(be,Ve),be.prototype.getUi=function(){var Pe=this,Be=document.createElement("div");return Be.style.display="flex",Be.style.overflow="hidden",Be.style.flexGrow="2",this.styles.forEach(function(Ze){var Fe=document.createElement("div");Fe.style.display="flex",Fe.style.alignItems="center",Fe.style.justifyContent="space-between",Fe.style.padding="5px",Fe.style.borderWidth="2px",Fe.style.borderStyle="solid",Fe.style.overflow="hidden",Fe.style.maxWidth=100/Pe.styles.length-5+"%",Fe.style.borderColor=Ze===Pe.currentStyle?Pe.uiStyleSettings.toolboxAccentColor:"transparent",Fe.addEventListener("click",function(){Pe.setCurrentStyle(Ze,Fe)}),Be.appendChild(Fe);var qe=document.createElement("div");qe.style.minHeight="20px",qe.style.flexGrow="2",qe.style.overflow="hidden";var dn=`<svg width="100" height="20">
<line x1="0" y1="10" x2="100" y2="10" stroke="`+Pe.uiStyleSettings.toolboxColor+'" stroke-width="3" '+(Ze!==""?'stroke-dasharray="'+Ze+'"':"")+` />
</svg>`;qe.innerHTML=dn,Fe.appendChild(qe),Pe.styleBoxes.push(Fe)}),Be},be.prototype.setCurrentStyle=function(Pe,Be){var Ze=this;this.currentStyle=Pe,this.styleBoxes.forEach(function(Fe){Fe.style.borderColor=Fe===Be?Ze.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onStyleChanged&&this.onStyleChanged(this.currentStyle)},be}(ne),ut=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.strokeColor=Ze.defaultColor,Fe.strokeWidth=Ze.defaultStrokeWidth,Fe.strokeDasharray=Ze.defaultStrokeDasharray,Fe.strokePanel=new te("Line color",Ze.defaultColorSet,Ze.defaultColor),Fe.strokePanel.onColorChanged=Fe.setStrokeColor,Fe.strokeWidthPanel=new Ge("Line width",Ze.defaultStrokeWidths,Ze.defaultStrokeWidth),Fe.strokeWidthPanel.onWidthChanged=Fe.setStrokeWidth,Fe.strokeStylePanel=new et("Line style",Ze.defaultStrokeDasharrays,Ze.defaultStrokeDasharray),Fe.strokeStylePanel.onStyleChanged=Fe.setStrokeDasharray,Fe}return dt(be,Ve),Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Ve.prototype.getState.call(this);return Pe.typeName=be.typeName,Pe},be.typeName="FrameMarker",be.title="Frame marker",be.icon='<svg viewBox="0 0 24 24"><path d="M4 6v13h16V6H4m14 11H6V8h12v9z"/></svg>',be}(Ee),st=function(){this.defaultColorSet=["#EF4444","#10B981","#2563EB","#FFFF00","#7C3AED","#F472B6","#000000","#FFFFFF"],this.defaultColor=this.defaultColorSet[0],this.defaultFillColor=this.defaultColorSet[0],this.defaultStrokeColor=this.defaultColorSet[7],this.defaultHighlightColor=this.defaultColorSet[3],this.defaultStrokeWidth=3,this.defaultStrokeDasharray="",this.defaultHighlightOpacity=.5,this.defaultFontFamily="Helvetica, Arial, sans-serif",this.defaultStrokeWidths=[1,2,3,5,10],this.defaultStrokeDasharrays=["","3","12 3","9 6 3 6"],this.defaultOpacitySteps=[.1,.25,.5,.75,1],this.displayMode="inline",this.defaultFontFamilies=['Times, "Times New Roman", serif',"Helvetica, Arial, sans-serif",'Courier, "Courier New", monospace',"cursive","fantasy"],this.popupMargin=30,this.newFreehandMarkerOnPointerUp=!1,this.defaultColorsFollowCurrentColors=!1,this.freehandPixelRatio=1,this.disableRotation=!1,this.defaultCaptionFontSize="1rem",this.defaultCaptionText="Text"},it=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.x1=0,Fe.y1=0,Fe.x2=0,Fe.y2=0,Fe.defaultLength=50,Fe.manipulationStartX=0,Fe.manipulationStartY=0,Fe.manipulationStartX1=0,Fe.manipulationStartY1=0,Fe.manipulationStartX2=0,Fe.manipulationStartY2=0,Fe.setupControlBox(),Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return!!Ve.prototype.ownsTarget.call(this,Pe)||!(!this.grip1.ownsTarget(Pe)&&!this.grip2.ownsTarget(Pe))},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.manipulationStartX=Pe.x,this.manipulationStartY=Pe.y,this.state==="new"&&(this.x1=Pe.x,this.y1=Pe.y,this.x2=Pe.x,this.y2=Pe.y),this.manipulationStartX1=this.x1,this.manipulationStartY1=this.y1,this.manipulationStartX2=this.x2,this.manipulationStartY2=this.y2,this.state!=="new"&&(this.select(),this.grip1.ownsTarget(Be)?this.activeGrip=this.grip1:this.grip2.ownsTarget(Be)?this.activeGrip=this.grip2:this.activeGrip=void 0,this.activeGrip?this._state="resize":this._state="move")},be.prototype.pointerUp=function(Pe){var Be=this.state;Ve.prototype.pointerUp.call(this,Pe),this.state==="creating"&&Math.abs(this.x1-this.x2)<10&&Math.abs(this.y1-this.y2)<10?(this.x2=this.x1+this.defaultLength,this.adjustVisual(),this.adjustControlBox()):this.manipulate(Pe),this._state="select",Be==="creating"&&this.onMarkerCreated&&this.onMarkerCreated(this)},be.prototype.adjustVisual=function(){},be.prototype.manipulate=function(Pe){this.state==="creating"?this.resize(Pe):this.state==="move"?(this.x1=this.manipulationStartX1+Pe.x-this.manipulationStartX,this.y1=this.manipulationStartY1+Pe.y-this.manipulationStartY,this.x2=this.manipulationStartX2+Pe.x-this.manipulationStartX,this.y2=this.manipulationStartY2+Pe.y-this.manipulationStartY,this.adjustVisual(),this.adjustControlBox()):this.state==="resize"&&this.resize(Pe)},be.prototype.resize=function(Pe){switch(this.activeGrip){case this.grip1:this.x1=Pe.x,this.y1=Pe.y;break;case this.grip2:case void 0:this.x2=Pe.x,this.y2=Pe.y}this.adjustVisual(),this.adjustControlBox()},be.prototype.select=function(){Ve.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},be.prototype.deselect=function(){Ve.prototype.deselect.call(this),this.controlBox.style.display="none"},be.prototype.setupControlBox=function(){this.controlBox=Ie.createGroup(),this.container.appendChild(this.controlBox),this.addControlGrips(),this.controlBox.style.display="none"},be.prototype.adjustControlBox=function(){this.positionGrips()},be.prototype.addControlGrips=function(){this.grip1=this.createGrip(),this.grip2=this.createGrip(),this.positionGrips()},be.prototype.createGrip=function(){var Pe=new pe;return Pe.visual.transform.baseVal.appendItem(Ie.createTransform()),this.controlBox.appendChild(Pe.visual),Pe},be.prototype.positionGrips=function(){var Pe=this.grip1.GRIP_SIZE;this.positionGrip(this.grip1.visual,this.x1-Pe/2,this.y1-Pe/2),this.positionGrip(this.grip2.visual,this.x2-Pe/2,this.y2-Pe/2)},be.prototype.positionGrip=function(Pe,Be,Ze){var Fe=Pe.transform.baseVal.getItem(0);Fe.setTranslate(Be,Ze),Pe.transform.baseVal.replaceItem(Fe,0)},be.prototype.getState=function(){return Object.assign({x1:this.x1,y1:this.y1,x2:this.x2,y2:this.y2},Ve.prototype.getState.call(this))},be.prototype.restoreState=function(Pe){Ve.prototype.restoreState.call(this,Pe);var Be=Pe;this.x1=Be.x1,this.y1=Be.y1,this.x2=Be.x2,this.y2=Be.y2},be.prototype.scale=function(Pe,Be){Ve.prototype.scale.call(this,Pe,Be),this.x1=this.x1*Pe,this.y1=this.y1*Be,this.x2=this.x2*Pe,this.y2=this.y2*Be,this.adjustVisual(),this.adjustControlBox()},be}(he),Nt=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.strokeColor="transparent",Fe.strokeWidth=0,Fe.strokeDasharray="",Fe.setStrokeColor=Fe.setStrokeColor.bind(Fe),Fe.setStrokeWidth=Fe.setStrokeWidth.bind(Fe),Fe.setStrokeDasharray=Fe.setStrokeDasharray.bind(Fe),Fe.strokeColor=Ze.defaultColor,Fe.strokeWidth=Ze.defaultStrokeWidth,Fe.strokeDasharray=Ze.defaultStrokeDasharray,Fe.strokePanel=new te("Line color",Ze.defaultColorSet,Ze.defaultColor),Fe.strokePanel.onColorChanged=Fe.setStrokeColor,Fe.strokeWidthPanel=new Ge("Line width",Ze.defaultStrokeWidths,Ze.defaultStrokeWidth),Fe.strokeWidthPanel.onWidthChanged=Fe.setStrokeWidth,Fe.strokeStylePanel=new et("Line style",Ze.defaultStrokeDasharrays,Ze.defaultStrokeDasharray),Fe.strokeStylePanel.onStyleChanged=Fe.setStrokeDasharray,Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return!(!Ve.prototype.ownsTarget.call(this,Pe)&&Pe!==this.visual&&Pe!==this.selectorLine&&Pe!==this.visibleLine)},be.prototype.createVisual=function(){this.visual=Ie.createGroup(),this.selectorLine=Ie.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()]]),this.visibleLine=Ie.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.visual.appendChild(this.selectorLine),this.visual.appendChild(this.visibleLine),this.addMarkerVisualToContainer(this.visual)},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.state==="new"&&(this.createVisual(),this.adjustVisual(),this._state="creating")},be.prototype.adjustVisual=function(){this.selectorLine&&this.visibleLine&&(this.selectorLine.setAttribute("x1",this.x1.toString()),this.selectorLine.setAttribute("y1",this.y1.toString()),this.selectorLine.setAttribute("x2",this.x2.toString()),this.selectorLine.setAttribute("y2",this.y2.toString()),this.visibleLine.setAttribute("x1",this.x1.toString()),this.visibleLine.setAttribute("y1",this.y1.toString()),this.visibleLine.setAttribute("x2",this.x2.toString()),this.visibleLine.setAttribute("y2",this.y2.toString()),Ie.setAttributes(this.visibleLine,[["stroke",this.strokeColor]]),Ie.setAttributes(this.visibleLine,[["stroke-width",this.strokeWidth.toString()]]),Ie.setAttributes(this.visibleLine,[["stroke-dasharray",this.strokeDasharray.toString()]]))},be.prototype.setStrokeColor=function(Pe){this.strokeColor=Pe,this.adjustVisual(),this.colorChanged(Pe)},be.prototype.setStrokeWidth=function(Pe){this.strokeWidth=Pe,this.adjustVisual()},be.prototype.setStrokeDasharray=function(Pe){this.strokeDasharray=Pe,this.adjustVisual(),this.stateChanged()},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray},Ve.prototype.getState.call(this));return Pe.typeName=be.typeName,Pe},be.prototype.restoreState=function(Pe){Ve.prototype.restoreState.call(this,Pe);var Be=Pe;this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.createVisual(),this.adjustVisual()},be.typeName="LineMarker",be.title="Line marker",be.icon='<svg viewBox="0 0 24 24"><path d="M19 13H5v-2h14v2z"/></svg>',be}(it),St=function(Ve){function be(Pe,Be,Ze,Fe){var qe=Ve.call(this,Pe,Fe||'<svg viewBox="0 0 24 24"><path d="M17 8h3v12h1v1h-4v-1h1v-3h-4l-1.5 3H14v1h-4v-1h1l6-12m1 1l-3.5 7H18V9M5 3h5c1.11 0 2 .89 2 2v11H9v-5H6v5H3V5c0-1.11.89-2 2-2m1 2v4h3V5H6z"/></svg>')||this;return qe.fonts=[],qe.fontBoxes=[],qe.fonts=Be,qe.currentFont=Ze,qe.setCurrentFont=qe.setCurrentFont.bind(qe),qe}return dt(be,Ve),be.prototype.getUi=function(){var Pe=this,Be=document.createElement("div");return Be.style.overflow="hidden",Be.style.flexGrow="2",this.fonts.forEach(function(Ze){var Fe=document.createElement("div");Fe.style.display="inline-block",Fe.style.alignItems="center",Fe.style.justifyContent="space-between",Fe.style.padding="5px",Fe.style.borderWidth="2px",Fe.style.borderStyle="solid",Fe.style.overflow="hidden",Fe.style.maxWidth=100/Pe.fonts.length-5+"%",Fe.style.borderColor=Ze===Pe.currentFont?Pe.uiStyleSettings.toolboxAccentColor:"transparent",Fe.addEventListener("click",function(){Pe.setCurrentFont(Ze,Fe)}),Be.appendChild(Fe);var qe=document.createElement("div");qe.style.display="flex",qe.style.minHeight="20px",qe.style.flexGrow="2",qe.style.fontFamily=Ze,qe.style.overflow="hidden";var dn=document.createElement("div");dn.style.whiteSpace="nowrap",dn.style.overflow="hidden",dn.style.textOverflow="ellipsis",dn.innerHTML="The quick brown fox jumps over the lazy dog",qe.appendChild(dn),Fe.appendChild(qe),Pe.fontBoxes.push(Fe)}),Be},be.prototype.setCurrentFont=function(Pe,Be){var Ze=this;this.currentFont=Pe,this.fontBoxes.forEach(function(Fe){Fe.style.borderColor=Fe===Be?Ze.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onFontChanged&&this.onFontChanged(this.currentFont)},be}(ne),Ft=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.color="transparent",Fe.padding=5,Fe.DEFAULT_TEXT="\u8BF7\u8F93\u5165\u6587\u672C",Fe.text=Fe.DEFAULT_TEXT,Fe.isMoved=!1,Fe.color=Ze.defaultColor,Fe.fontFamily=Ze.defaultFontFamily,Fe.defaultSize={x:100,y:30},Fe.setColor=Fe.setColor.bind(Fe),Fe.setFont=Fe.setFont.bind(Fe),Fe.renderText=Fe.renderText.bind(Fe),Fe.sizeText=Fe.sizeText.bind(Fe),Fe.textEditDivClicked=Fe.textEditDivClicked.bind(Fe),Fe.showTextEditor=Fe.showTextEditor.bind(Fe),Fe.setSize=Fe.setSize.bind(Fe),Fe.positionTextEditor=Fe.positionTextEditor.bind(Fe),Fe.colorPanel=new te("Color",Ze.defaultColorSet,Ze.defaultColor),Fe.colorPanel.onColorChanged=Fe.setColor,Fe.fontFamilyPanel=new St("Font",Ze.defaultFontFamilies,Ze.defaultFontFamily),Fe.fontFamilyPanel.onFontChanged=Fe.setFont,Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){if(Ve.prototype.ownsTarget.call(this,Pe)||Pe===this.visual||Pe===this.textElement||Pe===this.bgRectangle)return!0;var Be=!1;return this.textElement.childNodes.forEach(function(Ze){Ze===Pe&&(Be=!0)}),Be},be.prototype.createVisual=function(){this.visual=Ie.createGroup(),this.bgRectangle=Ie.createRect(1,1,[["fill","transparent"]]),this.visual.appendChild(this.bgRectangle),this.textElement=Ie.createText([["fill",this.color],["font-family",this.fontFamily],["font-size","16px"],["x","0"],["y","0"]]),this.textElement.transform.baseVal.appendItem(Ie.createTransform()),this.textElement.transform.baseVal.appendItem(Ie.createTransform()),this.visual.appendChild(this.textElement),this.addMarkerVisualToContainer(this.visual),this.renderText()},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.isMoved=!1,this.pointerDownPoint=Pe,this.pointerDownTimestamp=Date.now(),this.state==="new"&&(this.createVisual(),this.moveVisual(Pe),this._state="creating")},be.prototype.renderText=function(){var Pe=this;if(this.textElement){for(;this.textElement.lastChild;)this.textElement.removeChild(this.textElement.lastChild);this.text.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/).forEach(function(Be){Pe.textElement.appendChild(Ie.createTSpan(Be.trim()===""?" ":Be.trim(),[["x","0"],["dy","1.2em"]]))}),setTimeout(this.sizeText,10)}},be.prototype.getTextScale=function(){var Pe=this.textElement.getBBox(),Be=1;if(Pe.width>0&&Pe.height>0){var Ze=(1*this.width-this.width*this.padding*2/100)/Pe.width,Fe=(1*this.height-this.height*this.padding*2/100)/Pe.height;Be=Math.min(Ze,Fe)}return Be},be.prototype.getTextPosition=function(Pe){var Be=this.textElement.getBBox(),Ze=0,Fe=0;return Be.width>0&&Be.height>0&&(Ze=(this.width-Be.width*Pe)/2,Fe=this.height/2-Be.height*Pe/2),{x:Ze,y:Fe}},be.prototype.sizeText=function(){var Pe=this.textElement.getBBox(),Be=this.getTextScale(),Ze=this.getTextPosition(Be);Ze.y-=Pe.y*Be,navigator.userAgent.indexOf("Edge/")>-1?this.textElement.style.transform="translate("+Ze.x+"px, "+Ze.y+"px) scale("+Be+", "+Be+")":(this.textElement.transform.baseVal.getItem(0).setTranslate(Ze.x,Ze.y),this.textElement.transform.baseVal.getItem(1).setScale(Be,Be))},be.prototype.manipulate=function(Pe){Ve.prototype.manipulate.call(this,Pe),this.pointerDownPoint!==void 0&&(this.isMoved=Math.abs(Pe.x-this.pointerDownPoint.x)>5||Math.abs(Pe.y-this.pointerDownPoint.y)>5)},be.prototype.resize=function(Pe){Ve.prototype.resize.call(this,Pe),this.isMoved=!0,this.setSize(),this.sizeText()},be.prototype.setSize=function(){Ve.prototype.setSize.call(this),this.visual&&this.bgRectangle&&(Ie.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),Ie.setAttributes(this.bgRectangle,[["width",this.width.toString()],["height",this.height.toString()]]))},be.prototype.pointerUp=function(Pe){var Be=this.state;Be==="creating"&&(this._suppressMarkerCreateEvent=!0),Ve.prototype.pointerUp.call(this,Pe),this.setSize(),(Be==="creating"||!this.isMoved&&Date.now()-this.pointerDownTimestamp>500)&&this.showTextEditor(),this.pointerDownPoint=void 0},be.prototype.showTextEditor=function(){var Pe=this;this._state="edit",this.overlayContainer.innerHTML="",this.textEditDiv=document.createElement("div"),this.textEditDiv.style.flexGrow="2",this.textEditDiv.style.alignItems="center",this.textEditDiv.style.justifyContent="center",this.textEditDiv.style.pointerEvents="auto",this.textEditDiv.style.overflow="hidden",this.textEditor=document.createElement("div"),this.textEditor.style.position="absolute",this.textEditor.style.fontFamily=this.fontFamily,this.textEditor.style.lineHeight="1em",this.textEditor.innerText=this.text,this.textEditor.contentEditable="true",this.textEditor.style.color=this.color,this.textEditor.style.whiteSpace="pre",this.positionTextEditor(),this.textEditor.addEventListener("pointerup",function(Be){Be.stopPropagation()}),this.textEditor.addEventListener("input",function(){for(var Be=Number.parseFloat(Pe.textEditor.style.fontSize);Pe.textEditor.clientWidth>=Number.parseInt(Pe.textEditor.style.maxWidth)&&Be>.9;)Be-=.1,Pe.textEditor.style.fontSize=Math.max(Be,.9)+"em"}),this.textEditor.addEventListener("keyup",function(Be){Be.cancelBubble=!0}),this.textEditor.addEventListener("paste",function(Be){if(Be.clipboardData){var Ze=Be.clipboardData.getData("text"),Fe=window.getSelection();if(!Fe.rangeCount)return!1;Fe.deleteFromDocument(),Fe.getRangeAt(0).insertNode(document.createTextNode(Ze)),Be.preventDefault()}}),this.textEditDiv.addEventListener("pointerup",function(){Pe.textEditDivClicked(Pe.textEditor.innerText)}),this.textEditDiv.appendChild(this.textEditor),this.overlayContainer.appendChild(this.textEditDiv),this.hideVisual(),this.textEditor.focus(),document.execCommand("selectAll")},be.prototype.positionTextEditor=function(){if(this.state==="edit")if(this.textEditor===void 0)this.showTextEditor();else{this.textElement.style.display="";var Pe=this.getTextScale(),Be=this.rotatePoint({x:this.left+this.width/2,y:this.top+this.height/2}),Ze=this.textElement.getBBox(),Fe={x:Ze.width*Pe,y:Ze.height*Pe};Be.x-=Fe.x/2,Be.y-=Fe.y/2,this.textEditor.style.top=Be.y+"px",this.textEditor.style.left=Be.x+"px",this.textEditor.style.maxWidth=this.overlayContainer.offsetWidth-Be.x+"px",this.textEditor.style.fontSize=Math.max(16*Pe,12)+"px",this.textElement.style.display="none"}},be.prototype.textEditDivClicked=function(Pe){this.text=Pe.trim(),this.overlayContainer.innerHTML="",this.renderText(),this.showVisual(),this._suppressMarkerCreateEvent&&(this._suppressMarkerCreateEvent=!1,this.onMarkerCreated&&this.onMarkerCreated(this)),this.stateChanged()},be.prototype.select=function(){Ve.prototype.select.call(this),this.state==="edit"&&this.textEditDivClicked(this.textEditor.innerText)},be.prototype.deselect=function(){this.state==="edit"&&this.textEditDivClicked(this.textEditor.innerText),Ve.prototype.deselect.call(this)},be.prototype.dblClick=function(Pe,Be){Ve.prototype.dblClick.call(this,Pe,Be),this.showTextEditor()},be.prototype.setColor=function(Pe){this.textElement&&Ie.setAttributes(this.textElement,[["fill",Pe]]),this.color=Pe,this.textEditor&&(this.textEditor.style.color=this.color),this.colorChanged(Pe)},be.prototype.setFont=function(Pe){this.textElement&&Ie.setAttributes(this.textElement,[["font-family",Pe]]),this.fontFamily=Pe,this.textEditor&&(this.textEditor.style.fontFamily=this.fontFamily),this.renderText(),this.stateChanged()},be.prototype.hideVisual=function(){this.textElement.style.display="none",this.hideControlBox()},be.prototype.showVisual=function(){this.state==="edit"&&(this._state="select"),this.textElement.style.display="",this.showControlBox()},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Object.assign({color:this.color,fontFamily:this.fontFamily,padding:this.padding,text:this.text},Ve.prototype.getState.call(this));return Pe.typeName=be.typeName,Pe},be.prototype.restoreState=function(Pe){var Be=Pe;this.color=Be.color,this.fontFamily=Be.fontFamily,this.padding=Be.padding,this.text=Be.text,this.createVisual(),Ve.prototype.restoreState.call(this,Pe),this.setSize()},be.prototype.scale=function(Pe,Be){Ve.prototype.scale.call(this,Pe,Be),this.setSize(),this.sizeText(),this.positionTextEditor()},be.typeName="TextMarker",be.title="Text marker",be.icon='<svg viewBox="0 0 24 24"><path d="M9.6 14L12 7.7l2.4 6.3M11 5L5.5 19h2.2l1.1-3H15l1.1 3h2.2L13 5h-2z"/></svg>',be}(xe),cn=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.color="transparent",Fe.lineWidth=3,Fe.drawing=!1,Fe.pixelRatio=1,Fe.color=Ze.defaultColor,Fe.lineWidth=Ze.defaultStrokeWidth,Fe.pixelRatio=Ze.freehandPixelRatio,Fe.setColor=Fe.setColor.bind(Fe),Fe.addCanvas=Fe.addCanvas.bind(Fe),Fe.finishCreation=Fe.finishCreation.bind(Fe),Fe.setLineWidth=Fe.setLineWidth.bind(Fe),Fe.colorPanel=new te("Color",Ze.defaultColorSet,Ze.defaultColor),Fe.colorPanel.onColorChanged=Fe.setColor,Fe.lineWidthPanel=new Ge("Line width",Ze.defaultStrokeWidths,Ze.defaultStrokeWidth),Fe.lineWidthPanel.onWidthChanged=Fe.setLineWidth,Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return!(!Ve.prototype.ownsTarget.call(this,Pe)&&Pe!==this.visual&&Pe!==this.drawingImage)},be.prototype.createVisual=function(){this.visual=Ie.createGroup(),this.drawingImage=Ie.createImage(),this.visual.appendChild(this.drawingImage);var Pe=Ie.createTransform();this.visual.transform.baseVal.appendItem(Pe),this.addMarkerVisualToContainer(this.visual)},be.prototype.pointerDown=function(Pe,Be){this.state==="new"&&(this.addCanvas(),this.createVisual(),this._state="creating"),this.state==="creating"?(this.canvasContext.strokeStyle=this.color,this.canvasContext.lineWidth=this.lineWidth,this.canvasContext.beginPath(),this.canvasContext.moveTo(Pe.x,Pe.y),this.drawing=!0):Ve.prototype.pointerDown.call(this,Pe,Be)},be.prototype.manipulate=function(Pe){this.state==="creating"?this.drawing&&(this.canvasContext.lineTo(Pe.x,Pe.y),this.canvasContext.stroke()):Ve.prototype.manipulate.call(this,Pe)},be.prototype.resize=function(Pe){Ve.prototype.resize.call(this,Pe),Ie.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),Ie.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]])},be.prototype.pointerUp=function(Pe){this._state==="creating"?this.drawing&&(this.canvasContext.closePath(),this.drawing=!1,this.globalSettings.newFreehandMarkerOnPointerUp&&this.finishCreation()):Ve.prototype.pointerUp.call(this,Pe)},be.prototype.addCanvas=function(){this.overlayContainer.innerHTML="",this.canvasElement=document.createElement("canvas"),this.canvasElement.width=this.overlayContainer.clientWidth*this.pixelRatio,this.canvasElement.height=this.overlayContainer.clientHeight*this.pixelRatio,this.canvasContext=this.canvasElement.getContext("2d"),this.canvasContext.scale(this.pixelRatio,this.pixelRatio),this.overlayContainer.appendChild(this.canvasElement)},be.prototype.select=function(){this.state==="creating"&&this.finishCreation(),Ve.prototype.select.call(this)},be.prototype.deselect=function(){this.state==="creating"&&this.finishCreation(),Ve.prototype.deselect.call(this)},be.prototype.finishCreation=function(){for(var Pe=this.canvasContext.getImageData(0,0,this.canvasElement.width,this.canvasElement.height),Be=[this.canvasElement.width+1,this.canvasElement.height+1,-1,-1],Ze=Be[0],Fe=Be[1],qe=Be[2],dn=Be[3],ui=!1,$n=0;$n<this.canvasElement.height;$n++)for(var rn=0;rn<this.canvasElement.width;rn++)Pe.data[$n*this.canvasElement.width*4+4*rn+3]>0&&(ui=!0,$n<Fe&&(Fe=$n),rn<Ze&&(Ze=rn),$n>dn&&(dn=$n),rn>qe&&(qe=rn));if(ui){this.left=Ze/this.pixelRatio,this.top=Fe/this.pixelRatio,this.width=(qe-Ze)/this.pixelRatio,this.height=(dn-Fe)/this.pixelRatio;var Hn=document.createElement("canvas");Hn.width=qe-Ze,Hn.height=dn-Fe,Hn.getContext("2d").putImageData(this.canvasContext.getImageData(Ze,Fe,qe-Ze,dn-Fe),0,0),this.drawingImgUrl=Hn.toDataURL("image/png"),this.setDrawingImage(),this._state="select",this.onMarkerCreated&&this.onMarkerCreated(this)}this.overlayContainer.innerHTML=""},be.prototype.setDrawingImage=function(){Ie.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]]),Ie.setAttributes(this.drawingImage,[["href",this.drawingImgUrl]]),this.moveVisual({x:this.left,y:this.top})},be.prototype.setColor=function(Pe){this.color=Pe,this.colorChanged(Pe)},be.prototype.setLineWidth=function(Pe){this.lineWidth=Pe},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return this.state==="new"||this.state==="creating"?[this.colorPanel,this.lineWidthPanel]:[]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Object.assign({drawingImgUrl:this.drawingImgUrl},Ve.prototype.getState.call(this));return Pe.typeName=be.typeName,Pe},be.prototype.restoreState=function(Pe){this.createVisual(),Ve.prototype.restoreState.call(this,Pe),this.drawingImgUrl=Pe.drawingImgUrl,this.setDrawingImage()},be.prototype.scale=function(Pe,Be){Ve.prototype.scale.call(this,Pe,Be),this.setDrawingImage()},be.typeName="FreehandMarker",be.title="Freehand marker",be.icon='<svg viewBox="0 0 24 24"><path d="M9.75 20.85c1.78-.7 1.39-2.63.49-3.85-.89-1.25-2.12-2.11-3.36-2.94A9.817 9.817 0 014.54 12c-.28-.33-.85-.94-.27-1.06.59-.12 1.61.46 2.13.68.91.38 1.81.82 2.65 1.34l1.01-1.7C8.5 10.23 6.5 9.32 4.64 9.05c-1.06-.16-2.18.06-2.54 1.21-.32.99.19 1.99.77 2.77 1.37 1.83 3.5 2.71 5.09 4.29.34.33.75.72.95 1.18.21.44.16.47-.31.47-1.24 0-2.79-.97-3.8-1.61l-1.01 1.7c1.53.94 4.09 2.41 5.96 1.79m11.09-15.6c.22-.22.22-.58 0-.79l-1.3-1.3a.562.562 0 00-.78 0l-1.02 1.02 2.08 2.08M11 10.92V13h2.08l6.15-6.15-2.08-2.08L11 10.92z"/></svg>',be}(xe),Tt=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Ze||'<svg viewBox="0 0 24 24"><path d="M8 14v4l-6-6 6-6v4h8V6l6 6-6 6v-4H8z"/></svg>')||this;return Fe.typeBoxes=[],Fe.currentType=Be,Fe.setCurrentType=Fe.setCurrentType.bind(Fe),Fe}return dt(be,Ve),be.prototype.getUi=function(){var Pe=this,Be=document.createElement("div");Be.style.display="flex",Be.style.overflow="hidden",Be.style.flexGrow="2";for(var Ze=function(dn){var ui="both";switch(dn){case 0:ui="both";break;case 1:ui="start";break;case 2:ui="end";break;case 3:ui="none"}var $n=document.createElement("div");if($n.style.display="flex",$n.style.flexGrow="2",$n.style.alignItems="center",$n.style.justifyContent="space-between",$n.style.padding="5px",$n.style.borderWidth="2px",$n.style.borderStyle="solid",$n.style.borderColor=ui===Fe.currentType?Fe.uiStyleSettings.toolboxAccentColor:"transparent",$n.addEventListener("click",function(){Pe.setCurrentType(ui,$n)}),Be.appendChild($n),ui==="both"||ui==="start"){var rn=document.createElement("div");rn.style.display="flex",rn.style.alignItems="center",rn.style.minHeight="20px",rn.innerHTML=`<svg viewBox="0 0 10 10" width="10" height="10" xmlns="http://www.w3.org/2000/svg">
<polygon points="0,5 10,0 10,10" fill="`+(Fe.uiStyleSettings!==void 0?Fe.uiStyleSettings.toolboxColor:"#eeeeee")+`" />
</svg>`,rn.style.marginLeft="5px",$n.appendChild(rn)}var Hn=document.createElement("div");Hn.style.display="flex",Hn.style.alignItems="center",Hn.style.minHeight="20px",Hn.style.flexGrow="2";var Zt=document.createElement("hr");if(Zt.style.minWidth="20px",Zt.style.border="0px",Zt.style.borderTop="3px solid "+(Fe.uiStyleSettings!==void 0?Fe.uiStyleSettings.toolboxColor:"#eeeeee"),Zt.style.flexGrow="2",Hn.appendChild(Zt),$n.appendChild(Hn),ui==="both"||ui==="end"){var _n=document.createElement("div");_n.style.display="flex",_n.style.alignItems="center",_n.style.minHeight="20px",_n.innerHTML=`<svg viewBox="0 0 10 10" width="10" height="10" xmlns="http://www.w3.org/2000/svg">
<polygon points="0,0 10,5 0,10" fill="`+(Fe.uiStyleSettings!==void 0?Fe.uiStyleSettings.toolboxColor:"#eeeeee")+`" />
</svg>`,_n.style.marginRight="5px",$n.appendChild(_n)}Fe.typeBoxes.push($n)},Fe=this,qe=0;qe<4;qe++)Ze(qe);return Be},be.prototype.setCurrentType=function(Pe,Be){var Ze=this;this.currentType=Pe,this.typeBoxes.forEach(function(Fe){Fe.style.borderColor=Fe===Be?Ze.uiStyleSettings!==void 0?Ze.uiStyleSettings.toolboxAccentColor:"#3080c3":"transparent"}),this.onArrowTypeChanged&&this.onArrowTypeChanged(this.currentType)},be}(ne),hi=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.arrowType="end",Fe.arrowBaseHeight=10,Fe.arrowBaseWidth=10,Fe.getArrowPoints=Fe.getArrowPoints.bind(Fe),Fe.setArrowType=Fe.setArrowType.bind(Fe),Fe.arrowTypePanel=new Tt("Arrow type","end"),Fe.arrowTypePanel.onArrowTypeChanged=Fe.setArrowType,Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return!(!Ve.prototype.ownsTarget.call(this,Pe)&&Pe!==this.arrow1&&Pe!==this.arrow2)},be.prototype.getArrowPoints=function(Pe,Be){var Ze=this.arrowBaseWidth+2*this.strokeWidth,Fe=this.arrowBaseHeight+2*this.strokeWidth;return Pe-Ze/2+","+(Be+Fe/2)+" "+Pe+","+(Be-Fe/2)+" "+(Pe+Ze/2)+","+(Be+Fe/2)},be.prototype.createTips=function(){this.arrow1=Ie.createPolygon(this.getArrowPoints(this.x1,this.y1),[["fill",this.strokeColor]]),this.arrow1.transform.baseVal.appendItem(Ie.createTransform()),this.visual.appendChild(this.arrow1),this.arrow2=Ie.createPolygon(this.getArrowPoints(this.x2,this.y2),[["fill",this.strokeColor]]),this.arrow2.transform.baseVal.appendItem(Ie.createTransform()),this.visual.appendChild(this.arrow2)},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.state==="creating"&&this.createTips()},be.prototype.adjustVisual=function(){if(Ve.prototype.adjustVisual.call(this),this.arrow1&&this.arrow2){this.arrow1.style.display=this.arrowType==="both"||this.arrowType==="start"?"":"none",this.arrow2.style.display=this.arrowType==="both"||this.arrowType==="end"?"":"none",Ie.setAttributes(this.arrow1,[["points",this.getArrowPoints(this.x1,this.y1)],["fill",this.strokeColor]]),Ie.setAttributes(this.arrow2,[["points",this.getArrowPoints(this.x2,this.y2)],["fill",this.strokeColor]]);var Pe=0;Math.abs(this.x1-this.x2)>.1&&(Pe=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2));var Be=this.arrow1.transform.baseVal.getItem(0);Be.setRotate(Pe,this.x1,this.y1),this.arrow1.transform.baseVal.replaceItem(Be,0);var Ze=this.arrow2.transform.baseVal.getItem(0);Ze.setRotate(Pe+180,this.x2,this.y2),this.arrow2.transform.baseVal.replaceItem(Ze,0)}},be.prototype.setArrowType=function(Pe){this.arrowType=Pe,this.adjustVisual(),this.stateChanged()},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel,this.arrowTypePanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Object.assign({arrowType:this.arrowType},Ve.prototype.getState.call(this));return Pe.typeName=be.typeName,Pe},be.prototype.restoreState=function(Pe){Ve.prototype.restoreState.call(this,Pe);var Be=Pe;this.arrowType=Be.arrowType,this.createTips(),this.adjustVisual()},be.typeName="ArrowMarker",be.title="Arrow marker",be.icon='<svg viewBox="0 0 24 24"><path d="M19 6.41L17.59 5 7 15.59V9H5v10h10v-2H8.41L19 6.41z"/></svg>',be}(Nt),di=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.fillColor=Ze.defaultFillColor,Fe.strokeWidth=0,Fe.fillPanel=new te("Color",Ze.defaultColorSet,Ze.defaultFillColor),Fe.fillPanel.onColorChanged=Fe.setFillColor,Fe}return dt(be,Ve),Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.fillPanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Ve.prototype.getState.call(this);return Pe.typeName=be.typeName,Pe},be.typeName="CoverMarker",be.title="Cover marker",be.icon='<svg viewBox="0 0 24 24"><path d="M4 6v13h16V6H4z"/></svg>',be}(Ee),zn=function(Ve){function be(Pe,Be,Ze,Fe){var qe=Ve.call(this,Pe,Fe||'<svg viewBox="0 0 24 24"><path d="M17.66 8L12 2.35 6.34 8A8.02 8.02 0 004 13.64c0 2 .78 4.11 2.34 5.67a7.99 7.99 0 0011.32 0c1.56-1.56 2.34-3.67 2.34-5.67S19.22 9.56 17.66 8M6 14c0-2 .62-3.27 1.76-4.4L12 5.27l4.24 4.38C17.38 10.77 18 12 18 14H6z"/></svg>')||this;return qe.opacities=[],qe.opacityBoxes=[],qe.opacities=Be,qe.currentOpacity=Ze,qe.setCurrentOpacity=qe.setCurrentOpacity.bind(qe),qe}return dt(be,Ve),be.prototype.getUi=function(){var Pe=this,Be=document.createElement("div");return Be.style.display="flex",Be.style.overflow="hidden",Be.style.flexGrow="2",Be.style.justifyContent="space-between",this.opacities.forEach(function(Ze){var Fe=document.createElement("div");Fe.style.display="flex",Fe.style.alignItems="center",Fe.style.justifyContent="center",Fe.style.padding="5px",Fe.style.borderWidth="2px",Fe.style.borderStyle="solid",Fe.style.borderColor=Ze===Pe.currentOpacity?Pe.uiStyleSettings.toolboxAccentColor:"transparent",Fe.addEventListener("click",function(){Pe.setCurrentOpacity(Ze,Fe)}),Be.appendChild(Fe);var qe=document.createElement("div");qe.innerText=100*Ze+"%",Fe.appendChild(qe),Pe.opacityBoxes.push(Fe)}),Be},be.prototype.setCurrentOpacity=function(Pe,Be){var Ze=this;this.currentOpacity=Pe,this.opacityBoxes.forEach(function(Fe){Fe.style.borderColor=Fe===Be?Ze.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onOpacityChanged&&this.onOpacityChanged(this.currentOpacity)},be}(ne),Dn=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.setOpacity=Fe.setOpacity.bind(Fe),Fe.fillColor=Ze.defaultHighlightColor,Fe.strokeWidth=0,Fe.opacity=Ze.defaultHighlightOpacity,Fe.fillPanel=new te("Color",Ze.defaultColorSet,Fe.fillColor),Fe.fillPanel.onColorChanged=Fe.setFillColor,Fe.opacityPanel=new zn("Opacity",Ze.defaultOpacitySteps,Fe.opacity),Fe.opacityPanel.onOpacityChanged=Fe.setOpacity,Fe}return dt(be,Ve),be.prototype.setOpacity=function(Pe){this.opacity=Pe,this.visual&&Ie.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.fillPanel,this.opacityPanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Ve.prototype.getState.call(this);return Pe.typeName=be.typeName,Pe},be.typeName="HighlightMarker",be.title="Highlight marker",be.icon='<svg viewBox="0 0 24 24"><path d="M18.5 1.15c-.53 0-1.04.19-1.43.58l-5.81 5.82 5.65 5.65 5.82-5.81c.77-.78.77-2.04 0-2.83l-2.84-2.83c-.39-.39-.89-.58-1.39-.58M10.3 8.5l-5.96 5.96c-.78.78-.78 2.04.02 2.85C3.14 18.54 1.9 19.77.67 21h5.66l.86-.86c.78.76 2.03.75 2.81-.02l5.95-5.96"/></svg>',be}(di),nt='<svg viewBox="0 0 24 24"><path d="M9.62 12L12 5.67 14.37 12M11 3L5.5 17h2.25l1.12-3h6.25l1.13 3h2.25L13 3h-2z"/></svg>',ze='<svg viewBox="0 0 24 24"><path d="M19 11.5s-2 2.17-2 3.5a2 2 0 002 2 2 2 0 002-2c0-1.33-2-3.5-2-3.5M5.21 10L10 5.21 14.79 10m1.77-1.06L7.62 0 6.21 1.41l2.38 2.38-5.15 5.15c-.59.56-.59 1.53 0 2.12l5.5 5.5c.29.29.68.44 1.06.44s.77-.15 1.06-.44l5.5-5.5c.59-.59.59-1.56 0-2.12z"/></svg>',ke=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.bgColor="transparent",Fe.tipPosition={x:0,y:0},Fe.tipBase1Position={x:0,y:0},Fe.tipBase2Position={x:0,y:0},Fe.tipMoving=!1,Fe.color=Ze.defaultStrokeColor,Fe.bgColor=Ze.defaultFillColor,Fe.fontFamily=Ze.defaultFontFamily,Fe.defaultSize={x:100,y:30},Fe.setBgColor=Fe.setBgColor.bind(Fe),Fe.getTipPoints=Fe.getTipPoints.bind(Fe),Fe.positionTip=Fe.positionTip.bind(Fe),Fe.setTipPoints=Fe.setTipPoints.bind(Fe),Fe.colorPanel=new te("Text color",Ze.defaultColorSet,Fe.color,nt),Fe.colorPanel.onColorChanged=Fe.setColor,Fe.bgColorPanel=new te("Fill color",Ze.defaultColorSet,Fe.bgColor,ze),Fe.bgColorPanel.onColorChanged=Fe.setBgColor,Fe.fontFamilyPanel=new St("Font",Ze.defaultFontFamilies,Ze.defaultFontFamily),Fe.fontFamilyPanel.onFontChanged=Fe.setFont,Fe.tipGrip=new pe,Fe.tipGrip.visual.transform.baseVal.appendItem(Ie.createTransform()),Fe.controlBox.appendChild(Fe.tipGrip.visual),Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return Ve.prototype.ownsTarget.call(this,Pe)||this.tipGrip.ownsTarget(Pe)||this.tip===Pe},be.prototype.createTip=function(){Ie.setAttributes(this.bgRectangle,[["fill",this.bgColor],["rx","10px"]]),this.tip=Ie.createPolygon(this.getTipPoints(),[["fill",this.bgColor]]),this.visual.appendChild(this.tip)},be.prototype.pointerDown=function(Pe,Be){this.state==="new"&&Ve.prototype.pointerDown.call(this,Pe,Be),this.state==="creating"?this.createTip():this.tipGrip.ownsTarget(Be)?(this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.tipMoving=!0):Ve.prototype.pointerDown.call(this,Pe,Be)},be.prototype.pointerUp=function(Pe){if(this.tipMoving)this.tipMoving=!1,this.isMoved=!0,Ve.prototype.pointerUp.call(this,Pe);else{var Be=this.state==="creating";Ve.prototype.pointerUp.call(this,Pe),this.setTipPoints(Be),this.positionTip()}},be.prototype.manipulate=function(Pe){if(this.tipMoving){var Be=this.unrotatePoint(Pe);this.tipPosition={x:Be.x-this.manipulationStartLeft,y:Be.y-this.manipulationStartTop},this.positionTip()}else Ve.prototype.manipulate.call(this,Pe)},be.prototype.setBgColor=function(Pe){this.bgRectangle&&this.tip&&(Ie.setAttributes(this.bgRectangle,[["fill",Pe]]),Ie.setAttributes(this.tip,[["fill",Pe]])),this.bgColor=Pe,this.fillColorChanged(Pe)},be.prototype.getTipPoints=function(){return this.setTipPoints(this.state==="creating"),this.tipBase1Position.x+","+this.tipBase1Position.y+" "+this.tipBase2Position.x+","+this.tipBase2Position.y+" "+this.tipPosition.x+","+this.tipPosition.y},be.prototype.setTipPoints=function(Pe){Pe===void 0&&(Pe=!1);var Be=Math.min(this.height/2,15),Ze=this.height/5;Pe&&(this.tipPosition={x:Be+Ze/2,y:this.height+20});var Fe=Math.atan(this.height/2/(this.width/2));this.tipPosition.x<this.width/2&&this.tipPosition.y<this.height/2?Fe<Math.atan((this.height/2-this.tipPosition.y)/(this.width/2-this.tipPosition.x))?(Ze=this.width/5,Be=Math.min(this.width/2,15),this.tipBase1Position={x:Be,y:0},this.tipBase2Position={x:Be+Ze,y:0}):(this.tipBase1Position={x:0,y:Be},this.tipBase2Position={x:0,y:Be+Ze}):this.tipPosition.x>=this.width/2&&this.tipPosition.y<this.height/2?Fe<Math.atan((this.height/2-this.tipPosition.y)/(this.tipPosition.x-this.width/2))?(Ze=this.width/5,Be=Math.min(this.width/2,15),this.tipBase1Position={x:this.width-Be-Ze,y:0},this.tipBase2Position={x:this.width-Be,y:0}):(this.tipBase1Position={x:this.width,y:Be},this.tipBase2Position={x:this.width,y:Be+Ze}):this.tipPosition.x>=this.width/2&&this.tipPosition.y>=this.height/2?Fe<Math.atan((this.tipPosition.y-this.height/2)/(this.tipPosition.x-this.width/2))?(Ze=this.width/5,Be=Math.min(this.width/2,15),this.tipBase1Position={x:this.width-Be-Ze,y:this.height},this.tipBase2Position={x:this.width-Be,y:this.height}):(this.tipBase1Position={x:this.width,y:this.height-Be-Ze},this.tipBase2Position={x:this.width,y:this.height-Be}):Fe<Math.atan((this.tipPosition.y-this.height/2)/(this.width/2-this.tipPosition.x))?(Ze=this.width/5,Be=Math.min(this.width/2,15),this.tipBase1Position={x:Be,y:this.height},this.tipBase2Position={x:Be+Ze,y:this.height}):(this.tipBase1Position={x:0,y:this.height-Be},this.tipBase2Position={x:0,y:this.height-Be-Ze})},be.prototype.resize=function(Pe){Ve.prototype.resize.call(this,Pe),this.positionTip()},be.prototype.positionTip=function(){Ie.setAttributes(this.tip,[["points",this.getTipPoints()]]);var Pe=this.tipGrip.visual.transform.baseVal.getItem(0);Pe.setTranslate(this.tipPosition.x,this.tipPosition.y),this.tipGrip.visual.transform.baseVal.replaceItem(Pe,0)},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.bgColorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),be.prototype.select=function(){this.positionTip(),Ve.prototype.select.call(this)},be.prototype.getState=function(){var Pe=Object.assign({bgColor:this.bgColor,tipPosition:this.tipPosition},Ve.prototype.getState.call(this));return Pe.typeName=be.typeName,Pe},be.prototype.restoreState=function(Pe){var Be=Pe;this.bgColor=Be.bgColor,this.tipPosition=Be.tipPosition,Ve.prototype.restoreState.call(this,Pe),this.createTip(),this.setTipPoints()},be.prototype.scale=function(Pe,Be){Ve.prototype.scale.call(this,Pe,Be),this.tipPosition={x:this.tipPosition.x*Pe,y:this.tipPosition.y*Be},this.positionTip()},be.typeName="CalloutMarker",be.title="Callout marker",be.icon='<svg viewBox="0 0 24 24"><path d="M4 2h16a2 2 0 012 2v12a2 2 0 01-2 2h-4l-4 4-4-4H4a2 2 0 01-2-2V4a2 2 0 012-2m0 2v12h4.83L12 19.17 15.17 16H20V4H4m2 3h12v2H6V7m0 4h10v2H6v-2z"/></svg>',be}(Ft),Wt=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.fillColor="transparent",Fe.strokeColor="transparent",Fe.strokeWidth=0,Fe.strokeDasharray="",Fe.opacity=1,Fe.strokeColor=Ze.defaultColor,Fe.strokeWidth=Ze.defaultStrokeWidth,Fe.strokeDasharray=Ze.defaultStrokeDasharray,Fe.fillColor=Ze.defaultFillColor,Fe.setStrokeColor=Fe.setStrokeColor.bind(Fe),Fe.setFillColor=Fe.setFillColor.bind(Fe),Fe.setStrokeWidth=Fe.setStrokeWidth.bind(Fe),Fe.setStrokeDasharray=Fe.setStrokeDasharray.bind(Fe),Fe.setOpacity=Fe.setOpacity.bind(Fe),Fe.createVisual=Fe.createVisual.bind(Fe),Fe.strokePanel=new te("Line color",kt(Ze.defaultColorSet,["transparent"]),Ze.defaultColor),Fe.strokePanel.onColorChanged=Fe.setStrokeColor,Fe.fillPanel=new te("Fill color",kt(Ze.defaultColorSet,["transparent"]),Fe.fillColor,ze),Fe.fillPanel.onColorChanged=Fe.setFillColor,Fe.strokeWidthPanel=new Ge("Line width",Ze.defaultStrokeWidths,Ze.defaultStrokeWidth),Fe.strokeWidthPanel.onWidthChanged=Fe.setStrokeWidth,Fe.strokeStylePanel=new et("Line style",Ze.defaultStrokeDasharrays,Ze.defaultStrokeDasharray),Fe.strokeStylePanel.onStyleChanged=Fe.setStrokeDasharray,Fe.opacityPanel=new zn("Opacity",Ze.defaultOpacitySteps,Fe.opacity),Fe.opacityPanel.onOpacityChanged=Fe.setOpacity,Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return!(!Ve.prototype.ownsTarget.call(this,Pe)&&Pe!==this.visual)},be.prototype.createVisual=function(){this.visual=Ie.createEllipse(this.width/2,this.height/2,[["fill",this.fillColor],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray],["opacity",this.opacity.toString()]]),this.addMarkerVisualToContainer(this.visual)},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.state==="new"&&(this.createVisual(),this.moveVisual(Pe),this._state="creating")},be.prototype.manipulate=function(Pe){Ve.prototype.manipulate.call(this,Pe)},be.prototype.resize=function(Pe){Ve.prototype.resize.call(this,Pe),this.setSize()},be.prototype.setSize=function(){Ve.prototype.setSize.call(this),Ie.setAttributes(this.visual,[["cx",(this.width/2).toString()],["cy",(this.height/2).toString()],["rx",(this.width/2).toString()],["ry",(this.height/2).toString()]])},be.prototype.pointerUp=function(Pe){Ve.prototype.pointerUp.call(this,Pe),this.setSize()},be.prototype.setStrokeColor=function(Pe){this.strokeColor=Pe,this.visual&&Ie.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(Pe),this.stateChanged()},be.prototype.setFillColor=function(Pe){this.fillColor=Pe,this.visual&&Ie.setAttributes(this.visual,[["fill",this.fillColor]]),this.fillColorChanged(Pe),this.stateChanged()},be.prototype.setStrokeWidth=function(Pe){this.strokeWidth=Pe,this.visual&&Ie.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},be.prototype.setStrokeDasharray=function(Pe){this.strokeDasharray=Pe,this.visual&&Ie.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},be.prototype.setOpacity=function(Pe){this.opacity=Pe,this.visual&&Ie.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.fillPanel,this.strokeWidthPanel,this.strokeStylePanel,this.opacityPanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},Ve.prototype.getState.call(this));return Pe.typeName=be.typeName,Pe},be.prototype.restoreState=function(Pe){var Be=Pe;this.fillColor=Be.fillColor,this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.opacity=Be.opacity,this.createVisual(),Ve.prototype.restoreState.call(this,Pe),this.setSize()},be.prototype.scale=function(Pe,Be){Ve.prototype.scale.call(this,Pe,Be),this.setSize()},be.typeName="EllipseMarker",be.title="Ellipse marker",be.icon='<svg viewBox="0 0 24 24"><path d="M12 4C6.5 4 2 7.58 2 12s4.5 8 10 8 10-3.58 10-8-4.5-8-10-8z"/></svg>',be}(xe),On=function(Ve){function be(Pe,Be,Ze){return Ve.call(this,Pe,Be,Ze)||this}return dt(be,Ve),Object.defineProperty(be.prototype,"tipLength",{get:function(){return 10+3*this.strokeWidth},enumerable:!1,configurable:!0}),be.prototype.ownsTarget=function(Pe){return!(!Ve.prototype.ownsTarget.call(this,Pe)&&Pe!==this.tip1&&Pe!==this.tip2)},be.prototype.createTips=function(){this.tip1=Ie.createLine(this.x1-this.tipLength/2,this.y1,this.x1+this.tipLength/2,this.y1,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.tip1.transform.baseVal.appendItem(Ie.createTransform()),this.visual.appendChild(this.tip1),this.tip2=Ie.createLine(this.x2-this.tipLength/2,this.y2,this.x2+this.tipLength/2,this.y2,[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),this.tip2.transform.baseVal.appendItem(Ie.createTransform()),this.visual.appendChild(this.tip2)},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.state==="creating"&&this.createTips()},be.prototype.adjustVisual=function(){if(Ve.prototype.adjustVisual.call(this),this.tip1&&this.tip2&&(Ie.setAttributes(this.tip1,[["x1",(this.x1-this.tipLength/2).toString()],["y1",this.y1.toString()],["x2",(this.x1+this.tipLength/2).toString()],["y2",this.y1.toString()],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),Ie.setAttributes(this.tip2,[["x1",(this.x2-this.tipLength/2).toString()],["y1",this.y2.toString()],["x2",(this.x2+this.tipLength/2).toString()],["y2",this.y2.toString()],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()]]),Math.abs(this.x1-this.x2)>.1)){var Pe=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2),Be=this.tip1.transform.baseVal.getItem(0);Be.setRotate(Pe,this.x1,this.y1),this.tip1.transform.baseVal.replaceItem(Be,0);var Ze=this.tip2.transform.baseVal.getItem(0);Ze.setRotate(Pe+180,this.x2,this.y2),this.tip2.transform.baseVal.replaceItem(Ze,0)}},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Ve.prototype.getState.call(this);return Pe.typeName=be.typeName,Pe},be.prototype.restoreState=function(Pe){Ve.prototype.restoreState.call(this,Pe),this.createTips(),this.adjustVisual()},be.typeName="MeasurementMarker",be.title="Measurement marker",be.icon='<svg viewBox="0 0 24 24"><path d="M1.39 18.36l1.77-1.76L4.58 18l1.06-1.05-1.42-1.41 1.42-1.42 2.47 2.48 1.06-1.06-2.47-2.48 1.41-1.41 1.42 1.41L10.59 12l-1.42-1.41 1.42-1.42 2.47 2.48 1.06-1.06-2.47-2.48 1.41-1.41 1.41 1.41 1.07-1.06-1.42-1.41 1.42-1.42L18 6.7l1.07-1.06-2.47-2.48 1.76-1.77 4.25 4.25L5.64 22.61l-4.25-4.25z"/></svg>',be}(Nt),Lt=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.strokePanel.colors=Ze.defaultColorSet,Fe.fillColor="transparent",Fe}return dt(be,Ve),Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Ve.prototype.getState.call(this);return Pe.typeName=be.typeName,Pe},be.typeName="EllipseFrameMarker",be.title="Ellipse frame marker",be.icon='<svg viewBox="0 0 24 24"><path d="M12 6c4.41 0 8 2.69 8 6s-3.59 6-8 6-8-2.69-8-6 3.59-6 8-6m0-2C6.5 4 2 7.58 2 12s4.5 8 10 8 10-3.58 10-8-4.5-8-10-8z"/></svg>',be}(Wt),xn=function(){function Ve(){this.undoStack=[],this.redoStack=[]}return Object.defineProperty(Ve.prototype,"isUndoPossible",{get:function(){return this.undoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"isRedoPossible",{get:function(){return this.redoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"undoStepCount",{get:function(){return this.undoStack.length},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"redoStepCount",{get:function(){return this.redoStack.length},enumerable:!1,configurable:!0}),Ve.prototype.addUndoStep=function(be){this.undoStack.length!==0&&JSON.stringify(this.undoStack[this.undoStack.length-1])===JSON.stringify(be)||(this.undoStack.push(be),JSON.stringify(this.lastRedoStep)!==JSON.stringify(be)&&this.redoStack.splice(0,this.redoStack.length))},Ve.prototype.replaceLastUndoStep=function(be){this.undoStack.length>0&&(this.undoStack[this.undoStack.length-1]=be)},Ve.prototype.getLastUndoStep=function(){return this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0},Ve.prototype.undo=function(){if(this.undoStack.length>1){var be=this.undoStack.pop();return be!==void 0&&this.redoStack.push(be),this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0}},Ve.prototype.redo=function(){return this.lastRedoStep=this.redoStack.pop(),this.lastRedoStep},Ve}(),vn=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.strokeColor="transparent",Fe.strokeWidth=0,Fe.strokeDasharray="",Fe.curveX=0,Fe.curveY=0,Fe.manipulationStartCurveX=0,Fe.manipulationStartCurveY=0,Fe.setStrokeColor=Fe.setStrokeColor.bind(Fe),Fe.setStrokeWidth=Fe.setStrokeWidth.bind(Fe),Fe.setStrokeDasharray=Fe.setStrokeDasharray.bind(Fe),Fe.positionGrips=Fe.positionGrips.bind(Fe),Fe.addControlGrips=Fe.addControlGrips.bind(Fe),Fe.adjustVisual=Fe.adjustVisual.bind(Fe),Fe.setupControlBox=Fe.setupControlBox.bind(Fe),Fe.resize=Fe.resize.bind(Fe),Fe.strokeColor=Ze.defaultColor,Fe.strokeWidth=Ze.defaultStrokeWidth,Fe.strokeDasharray=Ze.defaultStrokeDasharray,Fe.strokePanel=new te("Line color",Ze.defaultColorSet,Ze.defaultColor),Fe.strokePanel.onColorChanged=Fe.setStrokeColor,Fe.strokeWidthPanel=new Ge("Line width",Ze.defaultStrokeWidths,Ze.defaultStrokeWidth),Fe.strokeWidthPanel.onWidthChanged=Fe.setStrokeWidth,Fe.strokeStylePanel=new et("Line style",Ze.defaultStrokeDasharrays,Ze.defaultStrokeDasharray),Fe.strokeStylePanel.onStyleChanged=Fe.setStrokeDasharray,Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return!(!Ve.prototype.ownsTarget.call(this,Pe)&&Pe!==this.visual&&Pe!==this.selectorCurve&&Pe!==this.visibleCurve&&!this.curveGrip.ownsTarget(Pe))},be.prototype.getPathD=function(){return"M "+this.x1+" "+this.y1+" Q "+this.curveX+" "+this.curveY+", "+this.x2+" "+this.y2},be.prototype.createVisual=function(){this.visual=Ie.createGroup(),this.selectorCurve=Ie.createPath(this.getPathD(),[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()],["fill","transparent"]]),this.visibleCurve=Ie.createPath(this.getPathD(),[["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["fill","transparent"]]),this.visual.appendChild(this.selectorCurve),this.visual.appendChild(this.visibleCurve),this.addMarkerVisualToContainer(this.visual)},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.manipulationStartCurveX=this.curveX,this.manipulationStartCurveY=this.curveY,this.state==="new"&&(this.curveX=Pe.x,this.curveY=Pe.y),this.state==="new"?(this.createVisual(),this.adjustVisual(),this._state="creating"):this.curveGrip.ownsTarget(Be)&&(this.activeGrip=this.curveGrip,this._state="resize")},be.prototype.adjustVisual=function(){this.selectorCurve&&this.visibleCurve&&(this.selectorCurve.setAttribute("d",this.getPathD()),this.visibleCurve.setAttribute("d",this.getPathD()),Ie.setAttributes(this.visibleCurve,[["stroke",this.strokeColor]]),Ie.setAttributes(this.visibleCurve,[["stroke-width",this.strokeWidth.toString()]]),Ie.setAttributes(this.visibleCurve,[["stroke-dasharray",this.strokeDasharray.toString()]]))},be.prototype.setupControlBox=function(){Ve.prototype.setupControlBox.call(this),this.curveControlLine1=Ie.createLine(this.x1,this.y1,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.curveControlLine2=Ie.createLine(this.x2,this.y2,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.controlBox.insertBefore(this.curveControlLine1,this.controlBox.firstChild),this.controlBox.insertBefore(this.curveControlLine2,this.controlBox.firstChild)},be.prototype.addControlGrips=function(){this.curveGrip=this.createGrip(),this.curveX=0,this.curveY=0,Ve.prototype.addControlGrips.call(this)},be.prototype.positionGrips=function(){Ve.prototype.positionGrips.call(this);var Pe=this.curveGrip.GRIP_SIZE;this.positionGrip(this.curveGrip.visual,this.curveX-Pe/2,this.curveY-Pe/2),this.curveControlLine1&&this.curveControlLine2&&(this.curveControlLine1.setAttribute("x1",this.x1.toString()),this.curveControlLine1.setAttribute("y1",this.y1.toString()),this.curveControlLine1.setAttribute("x2",this.curveX.toString()),this.curveControlLine1.setAttribute("y2",this.curveY.toString()),this.curveControlLine2.setAttribute("x1",this.x2.toString()),this.curveControlLine2.setAttribute("y1",this.y2.toString()),this.curveControlLine2.setAttribute("x2",this.curveX.toString()),this.curveControlLine2.setAttribute("y2",this.curveY.toString()))},be.prototype.manipulate=function(Pe){this.state==="move"&&(this.curveX=this.manipulationStartCurveX+Pe.x-this.manipulationStartX,this.curveY=this.manipulationStartCurveY+Pe.y-this.manipulationStartY),Ve.prototype.manipulate.call(this,Pe)},be.prototype.resize=function(Pe){this.activeGrip===this.curveGrip&&(this.curveX=Pe.x,this.curveY=Pe.y),Ve.prototype.resize.call(this,Pe),this.state==="creating"&&(this.curveX=this.x1+(this.x2-this.x1)/2,this.curveY=this.y1+(this.y2-this.y1)/2)},be.prototype.setStrokeColor=function(Pe){this.strokeColor=Pe,this.adjustVisual(),this.colorChanged(Pe)},be.prototype.setStrokeWidth=function(Pe){this.strokeWidth=Pe,this.adjustVisual()},be.prototype.setStrokeDasharray=function(Pe){this.strokeDasharray=Pe,this.adjustVisual()},be.prototype.scale=function(Pe,Be){this.curveX=this.curveX*Pe,this.curveY=this.curveY*Be,Ve.prototype.scale.call(this,Pe,Be)},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,curveX:this.curveX,curveY:this.curveY},Ve.prototype.getState.call(this));return Pe.typeName=be.typeName,Pe},be.prototype.restoreState=function(Pe){Ve.prototype.restoreState.call(this,Pe);var Be=Pe;this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.curveX=Be.curveX,this.curveY=Be.curveY,this.createVisual(),this.adjustVisual()},be.typeName="CurveMarker",be.title="Curve marker",be.icon='<svg viewBox="0 0 24 24"><path d="M18.5 2A1.5 1.5 0 0120 3.5 1.5 1.5 0 0118.5 5c-.23 0-.45-.05-.65-.15l-3.69 3.7.34.45c2.19-1.26 4.76-2 7.5-2l1 .03v2.01L22 9c-2.58 0-5 .75-7 2.04A3.96 3.96 0 0111.04 15C9.75 17 9 19.42 9 22l.04 1H7.03L7 22c0-2.74.74-5.31 2-7.5l-.45-.34-3.7 3.69c.1.2.15.42.15.65A1.5 1.5 0 013.5 20 1.5 1.5 0 012 18.5 1.5 1.5 0 013.5 17c.23 0 .45.05.65.15l3.69-3.7C7.31 12.78 7 11.92 7 11a4 4 0 014-4c.92 0 1.78.31 2.45.84l3.7-3.69c-.1-.2-.15-.42-.15-.65A1.5 1.5 0 0118.5 2M11 9a2 2 0 00-2 2 2 2 0 002 2 2 2 0 002-2 2 2 0 00-2-2z"/></svg>',be}(it),Xn=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,Be,Ze)||this;return Fe.fillColor="transparent",Fe.strokeColor="transparent",Fe.strokeWidth=0,Fe.strokeDasharray="",Fe.textColor="transparent",Fe.fontSize="1rem",Fe.isMoved=!1,Fe.captionText="Caption",Fe.PADDING=5,Fe.captionBoxWidth=0,Fe.captionBoxHeight=0,Fe.strokeColor=Ze.defaultColor,Fe.strokeWidth=Ze.defaultStrokeWidth,Fe.strokeDasharray=Ze.defaultStrokeDasharray,Fe.fillColor=Ze.defaultFillColor,Fe.textColor=Ze.defaultStrokeColor,Fe.fontFamily=Ze.defaultFontFamily,Fe.fontSize=Ze.defaultCaptionFontSize,Fe.captionText=Ze.defaultCaptionText,Fe.setStrokeColor=Fe.setStrokeColor.bind(Fe),Fe.setFillColor=Fe.setFillColor.bind(Fe),Fe.setStrokeWidth=Fe.setStrokeWidth.bind(Fe),Fe.setStrokeDasharray=Fe.setStrokeDasharray.bind(Fe),Fe.createVisual=Fe.createVisual.bind(Fe),Fe.sizeCaption=Fe.sizeCaption.bind(Fe),Fe.setCaptionText=Fe.setCaptionText.bind(Fe),Fe.showTextEditor=Fe.showTextEditor.bind(Fe),Fe.positionTextEditor=Fe.positionTextEditor.bind(Fe),Fe.finishTextEditing=Fe.finishTextEditing.bind(Fe),Fe.setFont=Fe.setFont.bind(Fe),Fe.setTextColor=Fe.setTextColor.bind(Fe),Fe.strokePanel=new te("Line color",kt(Ze.defaultColorSet,["transparent"]),Fe.strokeColor),Fe.strokePanel.onColorChanged=Fe.setStrokeColor,Fe.fillPanel=new te("Fill color",kt(Ze.defaultColorSet,["transparent"]),Fe.fillColor,ze),Fe.fillPanel.onColorChanged=Fe.setFillColor,Fe.strokeWidthPanel=new Ge("Line width",Ze.defaultStrokeWidths,Ze.defaultStrokeWidth),Fe.strokeWidthPanel.onWidthChanged=Fe.setStrokeWidth,Fe.strokeStylePanel=new et("Line style",Ze.defaultStrokeDasharrays,Ze.defaultStrokeDasharray),Fe.strokeStylePanel.onStyleChanged=Fe.setStrokeDasharray,Fe.fontFamilyPanel=new St("Font",Ze.defaultFontFamilies,Ze.defaultFontFamily),Fe.fontFamilyPanel.onFontChanged=Fe.setFont,Fe.textColorPanel=new te("Text color",Ze.defaultColorSet,Fe.textColor,nt),Fe.textColorPanel.onColorChanged=Fe.setTextColor,Fe}return dt(be,Ve),be.prototype.ownsTarget=function(Pe){return!(!Ve.prototype.ownsTarget.call(this,Pe)&&Pe!==this.visual&&Pe!==this.frame&&Pe!==this.captionBg&&Pe!==this.captionElement)},be.prototype.createVisual=function(){this.visual=Ie.createGroup(),this.addMarkerVisualToContainer(this.visual),this.captionBg=Ie.createRect(1,1,[["fill",this.fillColor]]),this.visual.appendChild(this.captionBg),this.captionElement=Ie.createText([["fill",this.textColor],["font-family",this.fontFamily]]),this.captionElement.style.fontSize=this.fontSize,this.captionElement.style.textAnchor="start",this.captionElement.style.dominantBaseline="text-before-edge",this.captionElement.textContent=this.captionText,this.visual.appendChild(this.captionElement),this.frame=Ie.createRect(this.width,this.height,[["fill","transparent"],["stroke",this.strokeColor],["stroke-width",this.strokeWidth.toString()],["stroke-dasharray",this.strokeDasharray]]),this.visual.appendChild(this.frame),this.sizeCaption()},be.prototype.setCaptionText=function(Pe){this.captionText=Pe,this.captionElement.textContent=this.captionText,this.sizeCaption()},be.prototype.pointerDown=function(Pe,Be){Ve.prototype.pointerDown.call(this,Pe,Be),this.isMoved=!1,this.pointerDownPoint=Pe,this.pointerDownTimestamp=Date.now(),this.state==="new"&&(this.createVisual(),this.moveVisual(Pe),this._state="creating")},be.prototype.manipulate=function(Pe){Ve.prototype.manipulate.call(this,Pe),this.pointerDownPoint!==void 0&&(this.isMoved=Math.abs(Pe.x-this.pointerDownPoint.x)>5||Math.abs(Pe.y-this.pointerDownPoint.y)>5)},be.prototype.resize=function(Pe){Ve.prototype.resize.call(this,Pe),this.setSize()},be.prototype.sizeCaption=function(){var Pe=this.captionElement.getBBox();this.captionText.trim()!==""?(this.captionBoxWidth=Pe.width+2*this.PADDING,this.captionBoxHeight=Pe.height+2*this.PADDING):(this.captionBoxWidth=0,this.captionBoxHeight=0),Ie.setAttributes(this.captionBg,[["width",this.captionBoxWidth.toString()],["height",this.captionBoxHeight.toString()],["clip-path","path('M0,0 H"+this.width+" V"+this.height+" H"+-this.width+" Z')"]]),Ie.setAttributes(this.captionElement,[["x",this.PADDING.toString()],["y",this.PADDING.toString()],["clip-path","path('M0,0 H"+(this.width-this.PADDING)+" V"+this.height+" H"+(-this.width-this.PADDING)+" Z')"]])},be.prototype.showTextEditor=function(){var Pe=this;this._state="edit",this.overlayContainer.innerHTML="",this.textEditDiv=document.createElement("div"),this.textEditDiv.style.flexGrow="2",this.textEditDiv.style.alignItems="center",this.textEditDiv.style.justifyContent="center",this.textEditDiv.style.pointerEvents="auto",this.textEditDiv.style.overflow="hidden",this.textEditBox=document.createElement("input"),this.textEditBox.style.position="absolute",this.textEditBox.style.width=this.width+"px",this.captionBoxHeight>0&&(this.textEditBox.style.height=this.captionBoxHeight+"px"),this.textEditBox.style.fontSize=this.fontSize,this.textEditBox.style.fontFamily=this.fontFamily,this.textEditBox.style.backgroundColor=this.fillColor,this.textEditBox.style.color=this.textColor,this.textEditBox.style.borderWidth="0",this.textEditBox.setAttribute("value",this.captionText),this.textEditBox.select(),this.textEditDiv.appendChild(this.textEditBox),this.overlayContainer.appendChild(this.textEditDiv),this.textEditBox.addEventListener("pointerup",function(Be){Be.stopPropagation()}),this.textEditBox.addEventListener("keypress",function(Be){Be.key==="Enter"&&Pe.finishTextEditing(Pe.textEditBox.value)}),this.textEditBox.addEventListener("keyup",function(Be){Be.cancelBubble=!0}),this.textEditBox.addEventListener("blur",function(){Pe.finishTextEditing(Pe.textEditBox.value)}),this.textEditDiv.addEventListener("pointerup",function(){Pe.finishTextEditing(Pe.textEditBox.value)}),this.positionTextEditor(),this.textEditBox.focus()},be.prototype.positionTextEditor=function(){this.state==="edit"&&(this.textEditBox===void 0?this.showTextEditor():(this.textEditBox.style.left=this.left+"px",this.textEditBox.style.top=this.top+"px",this.textEditBox.style.transform="rotate("+this.rotationAngle+"deg)",this.textEditBox.style.transformOrigin=this.width/2+"px "+this.height/2+"px"))},be.prototype.finishTextEditing=function(Pe){this.setCaptionText(Pe.trim()),this.overlayContainer.innerHTML="",this.stateChanged()},be.prototype.setFont=function(Pe){this.captionElement&&Ie.setAttributes(this.captionElement,[["font-family",Pe]]),this.fontFamily=Pe,this.textEditBox&&(this.textEditBox.style.fontFamily=this.fontFamily),this.sizeCaption(),this.stateChanged()},be.prototype.setTextColor=function(Pe){this.captionElement&&Ie.setAttributes(this.captionElement,[["fill",Pe]]),this.textColor=Pe,this.textEditBox&&(this.textEditBox.style.color=this.textColor),this.stateChanged()},be.prototype.setSize=function(){Ve.prototype.setSize.call(this),Ie.setAttributes(this.frame,[["width",this.width.toString()],["height",this.height.toString()]]),this.sizeCaption()},be.prototype.pointerUp=function(Pe){Ve.prototype.pointerUp.call(this,Pe),this.setSize(),!this.isMoved&&Date.now()-this.pointerDownTimestamp>500&&this.showTextEditor(),this.pointerDownPoint=void 0},be.prototype.dblClick=function(Pe,Be){Ve.prototype.dblClick.call(this,Pe,Be),this.showTextEditor()},be.prototype.setStrokeColor=function(Pe){this.strokeColor=Pe,this.frame&&Ie.setAttributes(this.frame,[["stroke",this.strokeColor]]),this.colorChanged(Pe),this.stateChanged()},be.prototype.setFillColor=function(Pe){this.fillColor=Pe,this.captionBg&&Ie.setAttributes(this.captionBg,[["fill",this.fillColor]]),this.fillColorChanged(Pe),this.stateChanged()},be.prototype.setStrokeWidth=function(Pe){this.strokeWidth=Pe,this.frame&&Ie.setAttributes(this.frame,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},be.prototype.setStrokeDasharray=function(Pe){this.strokeDasharray=Pe,this.frame&&Ie.setAttributes(this.frame,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},Object.defineProperty(be.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.fillPanel,this.strokeWidthPanel,this.strokeStylePanel,this.fontFamilyPanel,this.textColorPanel]},enumerable:!1,configurable:!0}),be.prototype.getState=function(){var Pe=Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:1,textColor:this.textColor,fontFamily:this.fontFamily,fontSize:this.fontSize,captionText:this.captionText},Ve.prototype.getState.call(this));return Pe.typeName=this.typeName,Pe},be.prototype.restoreState=function(Pe){var Be=Pe;this.fillColor=Be.fillColor,this.strokeColor=Be.strokeColor,this.strokeWidth=Be.strokeWidth,this.strokeDasharray=Be.strokeDasharray,this.textColor=Be.textColor,this.fontFamily=Be.fontFamily,this.captionText=Be.captionText,this.fontSize=Be.fontSize,this.createVisual(),Ve.prototype.restoreState.call(this,Pe),this.setSize()},be.prototype.scale=function(Pe,Be){Ve.prototype.scale.call(this,Pe,Be),this.setSize()},be.typeName="CaptionFrameMarker",be.title="Caption frame marker",be.icon='<svg viewBox="0 0 24 24"><path d="M5 3c-1.11 0-2 .89-2 2v14c0 1.11.89 2 2 2h14c1.11 0 2-.89 2-2V5c0-1.11-.89-2-2-2H5m0 2h14v14H5V5m2 2v2h10V7H7z"/></svg>',be}(xe),Ot=function(){function Ve(be,Pe){Pe===void 0&&(Pe=!1),this.cancelable=!1,this._defaultPrevented=!1,this.markerArea=be,this.cancelable=Pe}return Object.defineProperty(Ve.prototype,"defaultPrevented",{get:function(){return this._defaultPrevented},enumerable:!1,configurable:!0}),Ve.prototype.preventDefault=function(){this._defaultPrevented=!0},Ve}(),ft=function(Ve){function be(Pe,Be,Ze){var Fe=Ve.call(this,Pe,!1)||this;return Fe.dataUrl=Be,Fe.state=Ze,Fe}return dt(be,Ve),be}(Ot),Gt=function(Ve){function be(Pe,Be,Ze){Ze===void 0&&(Ze=!1);var Fe=Ve.call(this,Pe,Ze)||this;return Fe.marker=Be,Fe}return dt(be,Ve),be}(Ot),an=function(){function Ve(){this.render=[],this.beforeclose=[],this.close=[],this.show=[],this.restorestate=[],this.statechange=[],this.markerselect=[],this.markerdeselect=[],this.markercreating=[],this.markercreate=[],this.markerbeforedelete=[],this.markerdelete=[],this.markerchange=[],this.focus=[],this.blur=[]}return Ve.prototype.addEventListener=function(be,Pe){this[be].push(Pe)},Ve.prototype.removeEventListener=function(be,Pe){var Be=this[be].indexOf(Pe);Be>-1&&this[be].splice(Be,1)},Ve}(),Jt=function(){function Ve(be){this.touchPoints=0,this._availableMarkerTypes=this.DEFAULT_MARKER_TYPES,this.mode="select",this.markers=[],this.isDragging=!1,this.renderEventListeners=[],this.closeEventListeners=[],this.settings=new st,this._isOpen=!1,this.undoRedoManager=new xn,this.renderAtNaturalSize=!1,this.renderImageType="image/png",this.renderMarkersOnly=!1,this.zoomSteps=[1,1.5,2,4],this._zoomLevel=1,this._isResizing=!1,this.prevPanPoint={x:0,y:0},this.eventListeners=new an,this._silentRenderMode=!1,this._isFocused=!1,this._instanceNo=Ve.instanceCounter++,this.styles=new wt(this.instanceNo),this.uiStyleSettings=this.styles.settings,this.target=be,this.targetRoot=document.body,this.width=be.clientWidth,this.height=be.clientHeight,this.styles.removeStyleSheet(),this.open=this.open.bind(this),this.setTopLeft=this.setTopLeft.bind(this),this.toolbarButtonClicked=this.toolbarButtonClicked.bind(this),this.createNewMarker=this.createNewMarker.bind(this),this.addNewMarker=this.addNewMarker.bind(this),this.markerCreated=this.markerCreated.bind(this),this.setCurrentMarker=this.setCurrentMarker.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onDblClick=this.onDblClick.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.onPointerOut=this.onPointerOut.bind(this),this.onKeyUp=this.onKeyUp.bind(this),this.overrideOverflow=this.overrideOverflow.bind(this),this.restoreOverflow=this.restoreOverflow.bind(this),this.close=this.close.bind(this),this.closeUI=this.closeUI.bind(this),this.addCloseEventListener=this.addCloseEventListener.bind(this),this.removeCloseEventListener=this.removeCloseEventListener.bind(this),this.addRenderEventListener=this.addRenderEventListener.bind(this),this.removeRenderEventListener=this.removeRenderEventListener.bind(this),this.clientToLocalCoordinates=this.clientToLocalCoordinates.bind(this),this.onWindowResize=this.onWindowResize.bind(this),this.deleteSelectedMarker=this.deleteSelectedMarker.bind(this),this.setWindowHeight=this.setWindowHeight.bind(this),this.removeMarker=this.removeMarker.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this),this.onPopupTargetResize=this.onPopupTargetResize.bind(this),this.showNotesEditor=this.showNotesEditor.bind(this),this.hideNotesEditor=this.hideNotesEditor.bind(this),this.stepZoom=this.stepZoom.bind(this),this.focus=this.focus.bind(this),this.blur=this.blur.bind(this),this.markerStateChanged=this.markerStateChanged.bind(this),this.switchToSelectMode=this.switchToSelectMode.bind(this),this.addDefs=this.addDefs.bind(this),this.addDefsToImage=this.addDefsToImage.bind(this)}return Object.defineProperty(Ve.prototype,"ALL_MARKER_TYPES",{get:function(){return[ut,cn,hi,Ft,Lt,Wt,Dn,ke,On,di,Nt,vn,Xn]},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"DEFAULT_MARKER_TYPES",{get:function(){return[ut,cn,hi,Ft,Wt,Dn,ke]},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"BASIC_MARKER_TYPES",{get:function(){return[ut,cn,hi,Ft,Dn]},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"availableMarkerTypes",{get:function(){return this._availableMarkerTypes},set:function(be){var Pe=this;this._availableMarkerTypes.splice(0),be.forEach(function(Be){if(typeof Be=="string"){var Ze=Pe.ALL_MARKER_TYPES.find(function(Fe){return Fe.typeName===Be});Ze!==void 0&&Pe._availableMarkerTypes.push(Ze)}else Pe._availableMarkerTypes.push(Be)})},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"currentMarker",{get:function(){return this._currentMarker},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"isOpen",{get:function(){return this._isOpen},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"isUndoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isUndoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"isRedoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isRedoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"zoomLevel",{get:function(){return this._zoomLevel},set:function(be){this._zoomLevel=be,this.editorCanvas&&this.contentDiv&&(this.editorCanvas.style.transform="scale("+this._zoomLevel+")",this.contentDiv.scrollTo({left:(this.editorCanvas.clientWidth*this._zoomLevel-this.contentDiv.clientWidth)/2,top:(this.editorCanvas.clientHeight*this._zoomLevel-this.contentDiv.clientHeight)/2}))},enumerable:!1,configurable:!0}),Object.defineProperty(Ve.prototype,"instanceNo",{get:function(){return this._instanceNo},enumerable:!1,configurable:!0}),Ve.prototype.open=function(){this.setupResizeObserver(),this.setEditingTarget(),this.setTopLeft(),this.initMarkerCanvas(),this.initOverlay(),this.attachEvents(),this.settings.displayMode==="popup"&&this.onPopupTargetResize(),$e.isLicensed||this.addLogo(),this._isOpen=!0,this._isFocused=!0},Ve.prototype.show=function(){var be=this;this.styles.styleSheetRoot===void 0&&Pt.styleSheetRoot!==void 0&&(this.styles.styleSheetRoot=Pt.styleSheetRoot),this.setWindowHeight(),this.showUI(),this.open(),this.eventListeners.show.forEach(function(Pe){return Pe(new Ot(be))})},Ve.prototype.render=function(){return Ut(this,void 0,void 0,function(){var be;return $t(this,function(Pe){switch(Pe.label){case 0:return this.setCurrentMarker(),(be=new Mt).naturalSize=this.renderAtNaturalSize,be.imageType=this.renderImageType,be.imageQuality=this.renderImageQuality,be.markersOnly=this.renderMarkersOnly,be.width=this.renderWidth,be.height=this.renderHeight,[4,be.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 1:return Pe.sent(),[4,be.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 2:return[2,Pe.sent()]}})})},Ve.prototype.close=function(be){var Pe=this;if(be===void 0&&(be=!1),this.isOpen){var Be=!1;be||this.eventListeners.beforeclose.forEach(function(Ze){var Fe=new Ot(Pe,!0);Ze(Fe),Fe.defaultPrevented&&(Be=!0)}),Be||(this.coverDiv&&this.closeUI(),this.targetObserver&&(this.targetObserver.unobserve(this.target),this.targetObserver.unobserve(this.editorCanvas)),this.settings.displayMode==="popup"&&window.removeEventListener("resize",this.setWindowHeight),this.eventListeners.close.forEach(function(Ze){return Ze(new Ot(Pe))}),this.detachEvents(),this._isOpen=!1)}},Ve.prototype.addMarkersToToolbar=function(){for(var be,Pe=[],Be=0;Be<arguments.length;Be++)Pe[Be]=arguments[Be];(be=this._availableMarkerTypes).push.apply(be,Pe)},Ve.prototype.addRenderEventListener=function(be){this.addEventListener("render",function(Pe){be(Pe.dataUrl,Pe.state)})},Ve.prototype.removeRenderEventListener=function(be){},Ve.prototype.addCloseEventListener=function(be){this.addEventListener("close",function(){be()})},Ve.prototype.removeCloseEventListener=function(be){},Ve.prototype.setupResizeObserver=function(){var be=this;this.settings.displayMode==="inline"?window.ResizeObserver&&(this.targetObserver=new ResizeObserver(function(){be.resize(be.target.clientWidth,be.target.clientHeight)}),this.targetObserver.observe(this.target)):this.settings.displayMode==="popup"&&(window.ResizeObserver&&(this.targetObserver=new ResizeObserver(function(){return be.onPopupTargetResize()}),this.targetObserver.observe(this.editorCanvas)),window.addEventListener("resize",this.setWindowHeight))},Ve.prototype.onPopupTargetResize=function(){var be=1*this.target.clientWidth/this.target.clientHeight,Pe=this.editorCanvas.clientWidth/be>this.editorCanvas.clientHeight?this.editorCanvas.clientHeight*be:this.editorCanvas.clientWidth,Be=Pe<this.editorCanvas.clientWidth?this.editorCanvas.clientHeight:this.editorCanvas.clientWidth/be;this.resize(Pe,Be)},Ve.prototype.setWindowHeight=function(){this.windowHeight=window.innerHeight},Ve.prototype.resize=function(be,Pe){this._isResizing=!0;var Be=be/this.imageWidth,Ze=Pe/this.imageHeight;this.imageWidth=Math.round(be),this.imageHeight=Math.round(Pe),this.target instanceof HTMLImageElement&&this.editingTarget instanceof HTMLImageElement&&(this.editingTarget.src=this.target.src),this.editingTarget.width=this.imageWidth,this.editingTarget.height=this.imageHeight,this.editingTarget.style.width=this.imageWidth+"px",this.editingTarget.style.height=this.imageHeight+"px",this.markerImage.setAttribute("width",this.imageWidth.toString()),this.markerImage.setAttribute("height",this.imageHeight.toString()),this.markerImage.setAttribute("viewBox","0 0 "+this.imageWidth.toString()+" "+this.imageHeight.toString()),this.markerImageHolder.style.width=this.imageWidth+"px",this.markerImageHolder.style.height=this.imageHeight+"px",this.overlayContainer.style.width=this.imageWidth+"px",this.overlayContainer.style.height=this.imageHeight+"px",this.settings.displayMode!=="popup"?this.coverDiv.style.width=this.imageWidth.toString()+"px":(this.setTopLeft(),this.positionMarkerImage()),this.toolbar!==void 0&&this.toolbar.adjustLayout(),this.positionLogo(),this.scaleMarkers(Be,Ze),this._isResizing=!1},Ve.prototype.scaleMarkers=function(be,Pe){var Be,Ze=this;this._currentMarker&&this._currentMarker instanceof Ft?this._currentMarker.scale(be,Pe):(Be=this._currentMarker,this.setCurrentMarker()),this.markers.forEach(function(Fe){Fe!==Ze._currentMarker&&Fe.scale(be,Pe)}),Be!==void 0&&this.setCurrentMarker(Be)},Ve.prototype.setEditingTarget=function(){this.imageWidth=Math.round(this.target.clientWidth),this.imageHeight=Math.round(this.target.clientHeight),this.target instanceof HTMLImageElement&&this.editingTarget instanceof HTMLImageElement&&(this.editingTarget.src=this.target.src),this.editingTarget.width=this.imageWidth,this.editingTarget.height=this.imageHeight,this.editingTarget.style.width=this.imageWidth+"px",this.editingTarget.style.height=this.imageHeight+"px"},Ve.prototype.setTopLeft=function(){var be=this.editingTarget.getBoundingClientRect(),Pe=this.editorCanvas.getBoundingClientRect();this.left=be.left-Pe.left,this.top=be.top-Pe.top},Ve.prototype.initMarkerCanvas=function(){this.markerImageHolder=document.createElement("div"),this.markerImageHolder.style.setProperty("touch-action","pinch-zoom"),this.markerImage=document.createElementNS("http://www.w3.org/2000/svg","svg"),this.markerImage.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.markerImage.setAttribute("width",this.imageWidth.toString()),this.markerImage.setAttribute("height",this.imageHeight.toString()),this.markerImage.setAttribute("viewBox","0 0 "+this.imageWidth.toString()+" "+this.imageHeight.toString()),this.markerImage.style.pointerEvents="auto",this.markerImageHolder.style.position="absolute",this.markerImageHolder.style.width=this.imageWidth+"px",this.markerImageHolder.style.height=this.imageHeight+"px",this.markerImageHolder.style.transformOrigin="top left",this.positionMarkerImage(),this.markerImageHolder.appendChild(this.markerImage),this.editorCanvas.appendChild(this.markerImageHolder)},Ve.prototype.addDefs=function(){for(var be,Pe=[],Be=0;Be<arguments.length;Be++)Pe[Be]=arguments[Be];this.defs=Ie.createDefs(),this.addDefsToImage(),(be=this.defs).append.apply(be,Pe)},Ve.prototype.addDefsToImage=function(){this.defs&&this.markerImage.insertBefore(this.defs,this.markerImage.firstChild)},Ve.prototype.initOverlay=function(){this.overlayContainer=document.createElement("div"),this.overlayContainer.style.position="absolute",this.overlayContainer.style.left="0px",this.overlayContainer.style.top="0px",this.overlayContainer.style.width=this.imageWidth+"px",this.overlayContainer.style.height=this.imageHeight+"px",this.overlayContainer.style.display="flex",this.markerImageHolder.appendChild(this.overlayContainer)},Ve.prototype.positionMarkerImage=function(){this.markerImageHolder.style.top=this.top/this.zoomLevel+"px",this.markerImageHolder.style.left=this.left/this.zoomLevel+"px"},Ve.prototype.attachEvents=function(){this.markerImage.addEventListener("pointerdown",this.onPointerDown),this.markerImage.addEventListener("dblclick",this.onDblClick),this.attachWindowEvents()},Ve.prototype.attachWindowEvents=function(){window.addEventListener("pointermove",this.onPointerMove),window.addEventListener("pointerup",this.onPointerUp),window.addEventListener("pointercancel",this.onPointerOut),window.addEventListener("pointerout",this.onPointerOut),window.addEventListener("pointerleave",this.onPointerUp),window.addEventListener("resize",this.onWindowResize),window.addEventListener("keyup",this.onKeyUp)},Ve.prototype.detachEvents=function(){this.markerImage.removeEventListener("pointerdown",this.onPointerDown),this.markerImage.removeEventListener("dblclick",this.onDblClick),this.detachWindowEvents()},Ve.prototype.detachWindowEvents=function(){window.removeEventListener("pointermove",this.onPointerMove),window.removeEventListener("pointerup",this.onPointerUp),window.removeEventListener("pointercancel",this.onPointerOut),window.removeEventListener("pointerout",this.onPointerOut),window.removeEventListener("pointerleave",this.onPointerUp),window.removeEventListener("resize",this.onWindowResize),window.removeEventListener("keyup",this.onKeyUp)},Ve.prototype.addLogo=function(){this.logoUI=document.createElement("div"),this.logoUI.style.display="inline-block",this.logoUI.style.margin="0px",this.logoUI.style.padding="0px",this.logoUI.style.fill="#333333";var be=document.createElement("a");be.href="https://markerjs.com/",be.target="_blank",be.innerHTML='<svg viewBox="0 0 112 96" xmlns="http://www.w3.org/2000/svg" fill-rule="evenodd" clip-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="1.414"><path fill="#e5f20d" fill-opacity=".647" d="M0 40.386h111.96V95.62H0z"/><path d="M93.61 61.452c0 .987-.328 1.831-.987 2.53-.657.7-1.52 1.048-2.591 1.048-1.481 0-2.222-.74-2.222-2.22 0-16.617-.533-29.347-1.604-38.192-1.068-8.842-2.92-13.265-5.552-13.265-4.443 0-10.94 15.509-19.497 46.52v.124c0 .987-.328 1.831-.987 2.53-.657.7-1.52 1.048-2.592 1.048-1.48 0-2.22-.74-2.22-2.22 0-3.29.165-8.392.493-15.302.33-7.732.494-13.82.494-18.262 0-6.17-.186-10.55-.556-13.142-.37-2.591-1.172-3.887-2.406-3.887-2.796 0-6.333 5.12-10.612 15.363C38.494 34.367 34.01 46.44 29.32 60.34l-1.11 3.209a5.714 5.714 0 01-1.42 2.097c-.617.578-1.295.864-2.036.864-.987 0-1.644-.081-1.974-.247-.328-.162-.533-.656-.617-1.48-.41-4.03-.74-9.418-.987-16.165-.163-1.728-.329-4.566-.494-8.515-.822-13.901-1.562-23.3-2.221-28.196-.657-4.893-.987-7.628-.987-8.205 0-.657.33-1.44.987-2.345.659-.903 1.276-1.357 1.85-1.357 1.319 0 2.387.947 3.21 2.838.411.906.863 4.526 1.357 10.859.493 6.335.905 14.19 1.233 23.568l.617 18.88c4.527-13.983 9.216-26.673 14.068-38.068C45.65 6.686 50.093.988 54.123.988c2.715 0 4.566 1.974 5.553 5.923.987 3.949 1.481 9.667 1.481 17.152 0 3.949-.081 9.625-.247 17.029l-.123 5.676c3.373-11.762 6.725-21.634 10.057-29.615 3.331-7.979 6.685-11.97 10.056-11.97 8.475 0 12.71 18.757 12.71 56.269z" fill-rule="nonzero"/></svg>',be.title="Powered by marker.js",be.style.display="grid",be.style.alignItems="center",be.style.justifyItems="center",be.style.padding="3px",be.style.width="20px",be.style.height="20px",this.logoUI.appendChild(be),this.editorCanvas.appendChild(this.logoUI),this.logoUI.style.position="absolute",this.logoUI.style.pointerEvents="all",this.positionLogo()},Ve.prototype.positionLogo=function(){this.logoUI&&(this.uiStyleSettings.logoPosition!=="right"?this.logoUI.style.left=this.markerImageHolder.offsetLeft+10+"px":this.logoUI.style.left=this.markerImageHolder.offsetLeft+this.markerImageHolder.offsetWidth-this.logoUI.clientWidth-10+"px",this.logoUI.style.top=this.markerImageHolder.offsetTop+this.markerImageHolder.offsetHeight-this.logoUI.clientHeight-10+"px")},Ve.prototype.overrideOverflow=function(){this.scrollXState=window.scrollX,this.scrollYState=window.scrollY,this.bodyOverflowState=document.body.style.overflow,window.scroll({top:0,left:0}),document.body.style.overflow="hidden"},Ve.prototype.restoreOverflow=function(){document.body.style.overflow=this.bodyOverflowState,window.scroll({top:this.scrollYState,left:this.scrollXState})},Ve.prototype.showUI=function(){switch(this.settings.displayMode==="popup"&&this.overrideOverflow(),this.coverDiv=document.createElement("div"),this.coverDiv.style.visibility=this._silentRenderMode?"hidden":"visible",this.coverDiv.className=this.styles.classNamePrefixBase+" "+this.styles.classNamePrefix,this.coverDiv.style.fontSize="16px",this.coverDiv.style.userSelect="none",this.settings.displayMode){case"inline":this.coverDiv.style.position="absolute";var be=this.settings.uiOffsetTop!==void 0?this.target.offsetTop+this.settings.uiOffsetTop:this.target.offsetTop>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=be+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px",this.coverDiv.style.width=this.target.offsetWidth.toString()+"px",this.coverDiv.style.zIndex=this.uiStyleSettings.zIndex!==void 0?this.uiStyleSettings.zIndex:"5";break;case"popup":this.coverDiv.style.position="absolute",this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=window.innerHeight+"px",this.coverDiv.style.backgroundColor="rgba(0, 0, 0, 0.75)",this.coverDiv.style.zIndex=this.uiStyleSettings.zIndex!==void 0?this.uiStyleSettings.zIndex:"1000",this.coverDiv.style.display="flex"}this.targetRoot.appendChild(this.coverDiv),this.uiDiv=document.createElement("div"),this.uiDiv.style.display="flex",this.uiDiv.style.flexDirection="column",this.uiDiv.style.flexGrow="2",this.uiDiv.style.margin=this.settings.displayMode==="popup"?this.settings.popupMargin+"px":"0px",this.uiDiv.style.border="0px",this.coverDiv.appendChild(this.uiDiv),this.toolbar=new sn(this.uiDiv,this.settings.displayMode,this._availableMarkerTypes,this.uiStyleSettings,this.styles),this.toolbar.addButtonClickListener(this.toolbarButtonClicked),this.toolbar.show(this._silentRenderMode||this.uiStyleSettings.hideToolbar?"hidden":"visible"),this.contentDiv=document.createElement("div"),this.contentDiv.style.display="flex",this.contentDiv.style.flexDirection="row",this.contentDiv.style.flexGrow="2",this.contentDiv.style.flexShrink="1",this.settings.displayMode==="popup"&&(this.contentDiv.style.backgroundColor=this.uiStyleSettings.canvasBackgroundColor,this.contentDiv.style.maxHeight=this.windowHeight-2*this.settings.popupMargin-3.5*this.uiStyleSettings.toolbarHeight+"px",this.contentDiv.style.maxWidth="calc(100vw - "+2*this.settings.popupMargin+"px)"),this.contentDiv.style.overflow="auto",this.uiDiv.appendChild(this.contentDiv),this.editorCanvas=document.createElement("div"),this.editorCanvas.style.flexGrow="2",this.editorCanvas.style.flexShrink="1",this.editorCanvas.style.position="relative",this.editorCanvas.style.overflow="hidden",this.editorCanvas.style.display="flex",this.settings.displayMode==="popup"&&(this.editorCanvas.style.alignItems="center",this.editorCanvas.style.justifyContent="center"),this.editorCanvas.style.pointerEvents="none",this.editorCanvas.style.transformOrigin="left top",this.editorCanvas.style.transform="scale("+this.zoomLevel+")",this.contentDiv.appendChild(this.editorCanvas),this.editingTarget=this.target instanceof HTMLImageElement?document.createElement("img"):document.createElement("canvas"),this.settings.uiOffsetTop===void 0&&this.target.offsetTop<this.styles.settings.toolbarHeight&&(this.editingTarget.style.marginTop=this.target.offsetTop-this.styles.settings.toolbarHeight+"px"),this.editorCanvas.appendChild(this.editingTarget),this.toolbox=new Re(this.uiDiv,this.settings.displayMode,this.uiStyleSettings,this.styles),this.toolbox.show(this._silentRenderMode||this.uiStyleSettings.hideToolbox?"hidden":"visible")},Ve.prototype.closeUI=function(){this.settings.displayMode==="popup"&&this.restoreOverflow(),this.targetRoot.removeChild(this.coverDiv)},Ve.prototype.removeMarker=function(be){this.markerImage.removeChild(be.container),this.markers.indexOf(be)>-1&&this.markers.splice(this.markers.indexOf(be),1),be.dispose()},Ve.prototype.switchToSelectMode=function(){this.mode="select",this.hideNotesEditor(),this._currentMarker!==void 0&&(this._currentMarker.state!=="new"?this._currentMarker.select():(this.removeMarker(this._currentMarker),this.setCurrentMarker(),this.markerImage.style.cursor="default"),this.addUndoStep())},Ve.prototype.toolbarButtonClicked=function(be,Pe){if(be==="marker"&&Pe!==void 0)this.createNewMarker(Pe);else if(be==="action")switch(Pe){case"select":this.switchToSelectMode(),this.switchToSelectMode();break;case"delete":this.deleteSelectedMarker();break;case"clear":this.clear();break;case"undo":this.undo();break;case"redo":this.redo();break;case"zoom":this.stepZoom();break;case"zoom-out":this.zoomLevel=1;break;case"notes":this.notesArea===void 0?(this.switchToSelectMode(),this.zoomLevel=1,this.showNotesEditor()):this.switchToSelectMode();break;case"close":this.close();break;case"render":this.switchToSelectMode(),this.startRenderAndClose()}},Ve.prototype.deleteSelectedMarker=function(){var be=this;if(this._currentMarker!==void 0){var Pe=!1;if(this.eventListeners.markerbeforedelete.forEach(function(Ze){var Fe=new Gt(be,be._currentMarker,!0);Ze(Fe),Fe.defaultPrevented&&(Pe=!0)}),!Pe){var Be=this._currentMarker;this._currentMarker.dispose(),this.markerImage.removeChild(this._currentMarker.container),this.markers.splice(this.markers.indexOf(this._currentMarker),1),this.setCurrentMarker(),this.addUndoStep(),this.eventListeners.markerdelete.forEach(function(Ze){return Ze(new Gt(be,Be))})}}},Ve.prototype.clear=function(){var be=this,Pe=!1;if(this.markers.length>0&&(this.eventListeners.markerbeforedelete.forEach(function(qe){var dn=new Gt(be,void 0,!0);qe(dn),dn.defaultPrevented&&(Pe=!0)}),!Pe)){this.setCurrentMarker();for(var Be=function(qe){var dn=Ze.markers[qe];Ze.setCurrentMarker(Ze.markers[qe]),Ze._currentMarker.dispose(),Ze.markerImage.removeChild(Ze._currentMarker.container),Ze.markers.splice(Ze.markers.indexOf(Ze._currentMarker),1),Ze.eventListeners.markerdelete.forEach(function(ui){return ui(new Gt(be,dn))})},Ze=this,Fe=this.markers.length-1;Fe>=0;Fe--)Be(Fe);this.addUndoStep()}},Object.defineProperty(Ve.prototype,"isNotesAreaOpen",{get:function(){return this.notesArea!==void 0},enumerable:!1,configurable:!0}),Ve.prototype.showNotesEditor=function(){var be;this._currentMarker!==void 0&&(this.overlayContainer.innerHTML="",this.notesArea=document.createElement("textarea"),this.notesArea.className=this.uiStyleSettings.notesAreaStyleClassName,this.notesArea.style.pointerEvents="auto",this.notesArea.style.alignSelf="stretch",this.notesArea.style.width="100%",this.notesArea.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.notesArea.value=(be=this._currentMarker.notes)!==null&&be!==void 0?be:"",this.overlayContainer.appendChild(this.notesArea))},Ve.prototype.hideNotesEditor=function(){this.isNotesAreaOpen&&(this._currentMarker!==void 0&&(this._currentMarker.notes=this.notesArea.value.trim()!==""?this.notesArea.value:void 0),this.overlayContainer.removeChild(this.notesArea),this.notesArea=void 0)},Ve.prototype.selectLastMarker=function(){this.markers.length>0?this.setCurrentMarker(this.markers[this.markers.length-1]):this.setCurrentMarker()},Ve.prototype.addUndoStep=function(){var be=this;if(this._currentMarker===void 0||this._currentMarker.state!=="edit"){var Pe=this.getState(),Be=this.undoRedoManager.getLastUndoStep();if(!Be||Be.width===Pe.width&&Be.height===Pe.height){var Ze=this.undoRedoManager.undoStepCount;this.undoRedoManager.addUndoStep(Pe),Ze<this.undoRedoManager.undoStepCount&&this.eventListeners.statechange.forEach(function(Fe){return Fe(new Ot(be))})}else this.undoRedoManager.replaceLastUndoStep(Pe),this.eventListeners.statechange.forEach(function(Fe){return Fe(new Ot(be))})}},Ve.prototype.undo=function(){this.switchToSelectMode(),this.addUndoStep(),this.undoStep()},Ve.prototype.undoStep=function(){var be=this,Pe=this.undoRedoManager.undo();Pe!==void 0&&(this.restoreState(Pe),this.addDefsToImage(),this.selectLastMarker(),this.eventListeners.statechange.forEach(function(Be){return Be(new Ot(be))}))},Ve.prototype.redo=function(){this.switchToSelectMode(),this.redoStep()},Ve.prototype.redoStep=function(){var be=this,Pe=this.undoRedoManager.redo();Pe!==void 0&&(this.restoreState(Pe),this.addDefsToImage(),this.selectLastMarker(),this.eventListeners.statechange.forEach(function(Be){return Be(new Ot(be))}))},Ve.prototype.stepZoom=function(){var be=this.zoomSteps.indexOf(this.zoomLevel);this.zoomLevel=be<this.zoomSteps.length-1?this.zoomSteps[be+1]:this.zoomSteps[0]},Ve.prototype.panTo=function(be){this.contentDiv.scrollBy({left:this.prevPanPoint.x-be.x,top:this.prevPanPoint.y-be.y}),this.prevPanPoint=be},Ve.prototype.startRenderAndClose=function(){return Ut(this,void 0,void 0,function(){var be,Pe,Be=this;return $t(this,function(Ze){switch(Ze.label){case 0:return[4,this.render()];case 1:return be=Ze.sent(),Pe=this.getState(),this.eventListeners.render.forEach(function(Fe){return Fe(new ft(Be,be,Pe))}),this.close(!0),[2]}})})},Ve.prototype.getState=function(be){be===!0&&this.setCurrentMarker();var Pe={width:this.imageWidth,height:this.imageHeight,markers:[]};return this.markers.forEach(function(Be){return Pe.markers.push(Be.getState())}),Pe},Ve.prototype.restoreState=function(be){var Pe=this;for(this.markers.splice(0);this.markerImage.lastChild;)this.markerImage.removeChild(this.markerImage.lastChild);be.markers.forEach(function(Be){var Ze=Pe._availableMarkerTypes.find(function(qe){return qe.typeName===Be.typeName});if(Ze!==void 0){var Fe=Pe.addNewMarker(Ze);Fe.restoreState(Be),Pe.markers.push(Fe)}}),be.width&&be.height&&(be.width!==this.imageWidth||be.height!==this.imageHeight)&&this.scaleMarkers(this.imageWidth/be.width,this.imageHeight/be.height),this.eventListeners.restorestate.forEach(function(Be){return Be(new Ot(Pe))})},Ve.prototype.addNewMarker=function(be){var Pe=Ie.createGroup();return this.markerImage.appendChild(Pe),new be(Pe,this.overlayContainer,this.settings)},Ve.prototype.createNewMarker=function(be){var Pe,Be=this;(Pe=typeof be=="string"?this._availableMarkerTypes.find(function(Ze){return Ze.typeName===be}):be)&&(this.setCurrentMarker(),this.addUndoStep(),this._currentMarker=this.addNewMarker(Pe),this._currentMarker.onMarkerCreated=this.markerCreated,this._currentMarker.onColorChanged=this.colorChanged,this._currentMarker.onFillColorChanged=this.fillColorChanged,this._currentMarker.onStateChanged=this.markerStateChanged,this.markerImage.style.cursor="crosshair",this.toolbar.setActiveMarkerButton(Pe.typeName),this.toolbox.setPanelButtons(this._currentMarker.toolboxPanels),this.eventListeners.markercreating.forEach(function(Ze){return Ze(new Gt(Be,Be._currentMarker))}))},Ve.prototype.markerCreated=function(be){var Pe=this;this.mode="select",this.markerImage.style.cursor="default",this.markers.push(be),this.setCurrentMarker(be),be instanceof cn&&this.settings.newFreehandMarkerOnPointerUp?this.createNewMarker(cn):this.toolbar.setSelectMode(),this.addUndoStep(),this.eventListeners.markercreate.forEach(function(Be){return Be(new Gt(Pe,Pe._currentMarker))})},Ve.prototype.colorChanged=function(be){this.settings.defaultColorsFollowCurrentColors&&(this.settings.defaultColor=be,this.settings.defaultStrokeColor=be)},Ve.prototype.fillColorChanged=function(be){this.settings.defaultColorsFollowCurrentColors&&(this.settings.defaultFillColor=be)},Ve.prototype.markerStateChanged=function(be){var Pe=this;this.eventListeners.markerchange.forEach(function(Be){return Be(new Gt(Pe,be))})},Ve.prototype.setCurrentMarker=function(be){var Pe=this;this._currentMarker!==be&&this._currentMarker!==void 0&&(this._currentMarker.deselect(),this.toolbar.setCurrentMarker(),this.toolbox.setPanelButtons([]),this._isResizing||this.eventListeners.markerdeselect.forEach(function(Be){return Be(new Gt(Pe,Pe._currentMarker))})),this._currentMarker=be,this._currentMarker===void 0||this._currentMarker.isSelected||(this._currentMarker.state!=="new"&&this._currentMarker.select(),this.toolbar.setCurrentMarker(this._currentMarker),this.toolbox.setPanelButtons(this._currentMarker.toolboxPanels),this._isResizing||this.eventListeners.markerselect.forEach(function(Be){return Be(new Gt(Pe,Pe._currentMarker))}))},Ve.prototype.onPointerDown=function(be){if(this._isFocused||this.focus(),this.touchPoints++,this.touchPoints===1||be.pointerType!=="touch")if(this._currentMarker===void 0||this._currentMarker.state!=="new"&&this._currentMarker.state!=="creating"){if(this.mode==="select"){var Pe=this.markers.find(function(Be){return Be.ownsTarget(be.target)});Pe!==void 0?(this.setCurrentMarker(Pe),this.isDragging=!0,this._currentMarker.pointerDown(this.clientToLocalCoordinates(be.clientX,be.clientY),be.target)):(this.setCurrentMarker(),this.isDragging=!0,this.prevPanPoint={x:be.clientX,y:be.clientY})}}else this.isDragging=!0,this._currentMarker.pointerDown(this.clientToLocalCoordinates(be.clientX,be.clientY))},Ve.prototype.onDblClick=function(be){if(this._isFocused||this.focus(),this.mode==="select"){var Pe=this.markers.find(function(Be){return Be.ownsTarget(be.target)});Pe!==void 0&&Pe!==this._currentMarker&&this.setCurrentMarker(Pe),this._currentMarker!==void 0?this._currentMarker.dblClick(this.clientToLocalCoordinates(be.clientX,be.clientY),be.target):this.setCurrentMarker()}},Ve.prototype.onPointerMove=function(be){this.touchPoints!==1&&be.pointerType==="touch"||(this._currentMarker!==void 0||this.isDragging)&&(this._currentMarker!==void 0&&this._currentMarker.state==="edit"||be.preventDefault(),this._currentMarker!==void 0?this._currentMarker.manipulate(this.clientToLocalCoordinates(be.clientX,be.clientY)):this.zoomLevel>1&&this.panTo({x:be.clientX,y:be.clientY}))},Ve.prototype.onPointerUp=function(be){this.touchPoints>0&&this.touchPoints--,this.touchPoints===0&&this.isDragging&&this._currentMarker!==void 0&&this._currentMarker.pointerUp(this.clientToLocalCoordinates(be.clientX,be.clientY)),this.isDragging=!1,this.addUndoStep()},Ve.prototype.onPointerOut=function(){this.touchPoints>0&&this.touchPoints--},Ve.prototype.onKeyUp=function(be){this._currentMarker===void 0||this.notesArea!==void 0||be.key!=="Delete"&&be.key!=="Backspace"||this.deleteSelectedMarker()},Ve.prototype.clientToLocalCoordinates=function(be,Pe){var Be=this.markerImage.getBoundingClientRect();return{x:(be-Be.left)/this.zoomLevel,y:(Pe-Be.top)/this.zoomLevel}},Ve.prototype.onWindowResize=function(){this.positionUI()},Ve.prototype.positionUI=function(){switch(this.setTopLeft(),this.settings.displayMode){case"inline":var be=this.target.getClientRects().item(0).y>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=be+"px",this.coverDiv.style.left=this.target.offsetLeft.toString()+"px";break;case"popup":this.coverDiv.style.top="0px",this.coverDiv.style.left="0px",this.coverDiv.style.width="100vw",this.coverDiv.style.height=this.windowHeight+"px",this.contentDiv.style.maxHeight=this.windowHeight-2*this.settings.popupMargin-3.5*this.styles.settings.toolbarHeight+"px"}this.positionMarkerImage(),this.positionLogo()},Ve.prototype.addLicenseKey=function(be){$e.addKey(be)},Ve.prototype.addEventListener=function(be,Pe){this.eventListeners.addEventListener(be,Pe)},Ve.prototype.removeEventListener=function(be,Pe){this.eventListeners.removeEventListener(be,Pe)},Ve.prototype.renderState=function(be){this._silentRenderMode=!0,this.settings.displayMode="inline",this.isOpen||this.show(),this.restoreState(be),this.startRenderAndClose(),this._silentRenderMode=!1},Object.defineProperty(Ve.prototype,"isFocused",{get:function(){return this._isFocused},enumerable:!1,configurable:!0}),Ve.prototype.focus=function(){var be=this;this._isFocused||(this.attachWindowEvents(),this._isFocused=!0,this._previousCurrentMarker!==void 0&&this.setCurrentMarker(this._previousCurrentMarker),this.eventListeners.focus.forEach(function(Pe){return Pe(new Ot(be))}))},Ve.prototype.blur=function(){var be=this;this._isFocused&&(this.detachWindowEvents(),this._isFocused=!1,this._previousCurrentMarker=this._currentMarker,this.setCurrentMarker(),this.eventListeners.blur.forEach(function(Pe){return Pe(new Ot(be))}))},Ve.instanceCounter=0,Ve}()},13272:function(jn,li,De){"use strict";De.d(li,{s:function(){return la},default:function(){return Rt}});function Ne(){return Ne=Object.assign?Object.assign.bind():function(Se){for(var Le=1;Le<arguments.length;Le++){var je=arguments[Le];for(var Ke in je)({}).hasOwnProperty.call(je,Ke)&&(Se[Ke]=je[Ke])}return Se},Ne.apply(null,arguments)}function dt(Se){"@babel/helpers - typeof";return dt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Le){return typeof Le}:function(Le){return Le&&typeof Symbol=="function"&&Le.constructor===Symbol&&Le!==Symbol.prototype?"symbol":typeof Le},dt(Se)}function Ut(Se,Le){if(dt(Se)!="object"||!Se)return Se;var je=Se[Symbol.toPrimitive];if(je!==void 0){var Ke=je.call(Se,Le||"default");if(dt(Ke)!="object")return Ke;throw new TypeError("@@toPrimitive must return a primitive value.")}return(Le==="string"?String:Number)(Se)}function $t(Se){var Le=Ut(Se,"string");return dt(Le)=="symbol"?Le:Le+""}function kt(Se,Le,je){return(Le=$t(Le))in Se?Object.defineProperty(Se,Le,{value:je,enumerable:!0,configurable:!0,writable:!0}):Se[Le]=je,Se}function Ie(Se,Le){var je=Object.keys(Se);if(Object.getOwnPropertySymbols){var Ke=Object.getOwnPropertySymbols(Se);Le&&(Ke=Ke.filter(function(ct){return Object.getOwnPropertyDescriptor(Se,ct).enumerable})),je.push.apply(je,Ke)}return je}function $e(Se){for(var Le=1;Le<arguments.length;Le++){var je=arguments[Le]!=null?arguments[Le]:{};Le%2?Ie(Object(je),!0).forEach(function(Ke){kt(Se,Ke,je[Ke])}):Object.getOwnPropertyDescriptors?Object.defineProperties(Se,Object.getOwnPropertyDescriptors(je)):Ie(Object(je)).forEach(function(Ke){Object.defineProperty(Se,Ke,Object.getOwnPropertyDescriptor(je,Ke))})}return Se}function Mt(Se,Le){(Le==null||Le>Se.length)&&(Le=Se.length);for(var je=0,Ke=Array(Le);je<Le;je++)Ke[je]=Se[je];return Ke}function Pt(Se){if(Array.isArray(Se))return Mt(Se)}function wt(Se){if(typeof Symbol!="undefined"&&Se[Symbol.iterator]!=null||Se["@@iterator"]!=null)return Array.from(Se)}function Qt(Se,Le){if(Se){if(typeof Se=="string")return Mt(Se,Le);var je={}.toString.call(Se).slice(8,-1);return je==="Object"&&Se.constructor&&(je=Se.constructor.name),je==="Map"||je==="Set"?Array.from(Se):je==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(je)?Mt(Se,Le):void 0}}function It(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function sn(Se){return Pt(Se)||wt(Se)||Qt(Se)||It()}function Re(Se){if(Array.isArray(Se))return Se}function ne(Se,Le){var je=Se==null?null:typeof Symbol!="undefined"&&Se[Symbol.iterator]||Se["@@iterator"];if(je!=null){var Ke,ct,Et,Bt,hn=[],qt=!0,nn=!1;try{if(Et=(je=je.call(Se)).next,Le===0){if(Object(je)!==je)return;qt=!1}else for(;!(qt=(Ke=Et.call(je)).done)&&(hn.push(Ke.value),hn.length!==Le);qt=!0);}catch(Sn){nn=!0,ct=Sn}finally{try{if(!qt&&je.return!=null&&(Bt=je.return(),Object(Bt)!==Bt))return}finally{if(nn)throw ct}}return hn}}function te(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function he(Se,Le){return Re(Se)||ne(Se,Le)||Qt(Se,Le)||te()}function le(Se,Le){if(Se==null)return{};var je={};for(var Ke in Se)if({}.hasOwnProperty.call(Se,Ke)){if(Le.indexOf(Ke)!==-1)continue;je[Ke]=Se[Ke]}return je}function pe(Se,Le){if(Se==null)return{};var je,Ke,ct=le(Se,Le);if(Object.getOwnPropertySymbols){var Et=Object.getOwnPropertySymbols(Se);for(Ke=0;Ke<Et.length;Ke++)je=Et[Ke],Le.indexOf(je)===-1&&{}.propertyIsEnumerable.call(Se,je)&&(ct[je]=Se[je])}return ct}function me(){return me=Object.assign?Object.assign.bind():function(Se){for(var Le=1;Le<arguments.length;Le++){var je=arguments[Le];for(var Ke in je)Object.prototype.hasOwnProperty.call(je,Ke)&&(Se[Ke]=je[Ke])}return Se},me.apply(this,arguments)}function xe(Se,Le){(Le==null||Le>Se.length)&&(Le=Se.length);for(var je=0,Ke=new Array(Le);je<Le;je++)Ke[je]=Se[je];return Ke}function Ee(Se){if(Array.isArray(Se))return xe(Se)}function Ge(Se){if(typeof Symbol!="undefined"&&Se[Symbol.iterator]!=null||Se["@@iterator"]!=null)return Array.from(Se)}function et(Se,Le){if(Se){if(typeof Se=="string")return xe(Se,Le);var je=Object.prototype.toString.call(Se).slice(8,-1);if(je==="Object"&&Se.constructor&&(je=Se.constructor.name),je==="Map"||je==="Set")return Array.from(Se);if(je==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(je))return xe(Se,Le)}}function ut(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function st(Se){return Ee(Se)||Ge(Se)||et(Se)||ut()}function it(Se){"@babel/helpers - typeof";return it=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Le){return typeof Le}:function(Le){return Le&&typeof Symbol=="function"&&Le.constructor===Symbol&&Le!==Symbol.prototype?"symbol":typeof Le},it(Se)}function Nt(Se,Le){if(it(Se)!=="object"||Se===null)return Se;var je=Se[Symbol.toPrimitive];if(je!==void 0){var Ke=je.call(Se,Le||"default");if(it(Ke)!=="object")return Ke;throw new TypeError("@@toPrimitive must return a primitive value.")}return(Le==="string"?String:Number)(Se)}function St(Se){var Le=Nt(Se,"string");return it(Le)==="symbol"?Le:String(Le)}function Ft(Se,Le,je){return Le=St(Le),Le in Se?Object.defineProperty(Se,Le,{value:je,enumerable:!0,configurable:!0,writable:!0}):Se[Le]=je,Se}function cn(Se,Le){var je=Object.keys(Se);if(Object.getOwnPropertySymbols){var Ke=Object.getOwnPropertySymbols(Se);Le&&(Ke=Ke.filter(function(ct){return Object.getOwnPropertyDescriptor(Se,ct).enumerable})),je.push.apply(je,Ke)}return je}function Tt(Se){for(var Le=1;Le<arguments.length;Le++){var je=arguments[Le]!=null?arguments[Le]:{};Le%2?cn(Object(je),!0).forEach(function(Ke){Ft(Se,Ke,je[Ke])}):Object.getOwnPropertyDescriptors?Object.defineProperties(Se,Object.getOwnPropertyDescriptors(je)):cn(Object(je)).forEach(function(Ke){Object.defineProperty(Se,Ke,Object.getOwnPropertyDescriptor(je,Ke))})}return Se}function hi(Se){if(Array.isArray(Se))return Se}function di(Se,Le){var je=Se==null?null:typeof Symbol!="undefined"&&Se[Symbol.iterator]||Se["@@iterator"];if(je!=null){var Ke,ct,Et,Bt,hn=[],qt=!0,nn=!1;try{if(Et=(je=je.call(Se)).next,Le===0){if(Object(je)!==je)return;qt=!1}else for(;!(qt=(Ke=Et.call(je)).done)&&(hn.push(Ke.value),hn.length!==Le);qt=!0);}catch(Sn){nn=!0,ct=Sn}finally{try{if(!qt&&je.return!=null&&(Bt=je.return(),Object(Bt)!==Bt))return}finally{if(nn)throw ct}}return hn}}function zn(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Dn(Se,Le){return hi(Se)||di(Se,Le)||et(Se,Le)||zn()}function nt(Se,Le){if(Se==null)return{};var je={},Ke=Object.keys(Se),ct,Et;for(Et=0;Et<Ke.length;Et++)ct=Ke[Et],!(Le.indexOf(ct)>=0)&&(je[ct]=Se[ct]);return je}function ze(Se,Le){if(Se==null)return{};var je=nt(Se,Le),Ke,ct;if(Object.getOwnPropertySymbols){var Et=Object.getOwnPropertySymbols(Se);for(ct=0;ct<Et.length;ct++)Ke=Et[ct],!(Le.indexOf(Ke)>=0)&&Object.prototype.propertyIsEnumerable.call(Se,Ke)&&(je[Ke]=Se[Ke])}return je}var ke=De(67294);function Wt(Se){var Le=ke.useRef();Le.current=Se;var je=ke.useCallback(function(){for(var Ke,ct=arguments.length,Et=new Array(ct),Bt=0;Bt<ct;Bt++)Et[Bt]=arguments[Bt];return(Ke=Le.current)===null||Ke===void 0?void 0:Ke.call.apply(Ke,[Le].concat(Et))},[]);return je}function On(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var Lt=On()?ke.useLayoutEffect:ke.useEffect,xn=Lt,vn=function(Le,je){var Ke=ke.useRef(!0);Lt(function(){if(!Ke.current)return Le()},je),Lt(function(){return Ke.current=!1,function(){Ke.current=!0}},[])};function Xn(Se){var Le=ke.useRef(!1),je=ke.useState(Se),Ke=Dn(je,2),ct=Ke[0],Et=Ke[1];ke.useEffect(function(){return Le.current=!1,function(){Le.current=!0}},[]);function Bt(hn,qt){qt&&Le.current||Et(hn)}return[ct,Bt]}function Ot(Se){return Se!==void 0}function ft(Se,Le){var je=Le||{},Ke=je.defaultValue,ct=je.value,Et=je.onChange,Bt=je.postState,hn=Xn(function(){return Ot(ct)?ct:Ot(Ke)?typeof Ke=="function"?Ke():Ke:typeof Se=="function"?Se():Se}),qt=Dn(hn,2),nn=qt[0],Sn=qt[1],yn=ct!==void 0?ct:nn,Jn=Bt?Bt(yn):yn,In=Wt(Et),Mn=Xn([yn]),Kn=Dn(Mn,2),ni=Kn[0],yi=Kn[1];vn(function(){var Ai=ni[0];nn!==Ai&&In(nn,Ai)},[ni]),vn(function(){Ot(ct)||Sn(ct)},[ct]);var $i=Wt(function(Ai,bi){Sn(Ai,bi),yi([yn],bi)});return[Jn,$i]}var Gt={};function an(Se,Le){}function Jt(Se,Le){}function Ve(){Gt={}}function be(Se,Le,je){!Le&&!Gt[je]&&(Se(!1,je),Gt[je]=!0)}function Pe(Se,Le){be(an,Se,Le)}function Be(Se,Le){be(Jt,Se,Le)}var Ze=Pe,Fe=De(94184),qe=De.n(Fe),dn=function(){if(typeof navigator=="undefined"||typeof window=="undefined")return!1;var Se=navigator.userAgent||navigator.vendor||window.opera;return/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(Se)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(Se==null?void 0:Se.substr(0,4))},ui=De(16357);function $n(Se,Le,je){var Ke=ke.useRef({});return(!("value"in Ke.current)||je(Ke.current.condition,Le))&&(Ke.current.value=Se(),Ke.current.condition=Le),Ke.current.value}function rn(Se,Le){typeof Se=="function"?Se(Le):it(Se)==="object"&&Se&&"current"in Se&&(Se.current=Le)}function Hn(){for(var Se=arguments.length,Le=new Array(Se),je=0;je<Se;je++)Le[je]=arguments[je];var Ke=Le.filter(function(ct){return ct});return Ke.length<=1?Ke[0]:function(ct){Le.forEach(function(Et){rn(Et,ct)})}}function Zt(){for(var Se=arguments.length,Le=new Array(Se),je=0;je<Se;je++)Le[je]=arguments[je];return $n(function(){return Hn.apply(void 0,Le)},Le,function(Ke,ct){return Ke.length===ct.length&&Ke.every(function(Et,Bt){return Et===ct[Bt]})})}function _n(Se){var Le,je,Ke=isMemo(Se)?Se.type.type:Se.type;return!(typeof Ke=="function"&&!((Le=Ke.prototype)!==null&&Le!==void 0&&Le.render)||typeof Se=="function"&&!((je=Se.prototype)!==null&&je!==void 0&&je.render))}var ti=function(Le){var je=Le.className,Ke=Le.customizeIcon,ct=Le.customizeIconProps,Et=Le.children,Bt=Le.onMouseDown,hn=Le.onClick,qt=typeof Ke=="function"?Ke(ct):Ke;return ke.createElement("span",{className:je,onMouseDown:function(Sn){Sn.preventDefault(),Bt==null||Bt(Sn)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:hn,"aria-hidden":!0},qt!==void 0?qt:ke.createElement("span",{className:qe()(je.split(/\s+/).map(function(nn){return"".concat(nn,"-icon")}))},Et))},Ri=ti,oi=function(Le,je,Ke,ct,Et){var Bt=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,hn=arguments.length>6?arguments[6]:void 0,qt=arguments.length>7?arguments[7]:void 0,nn=ke.useMemo(function(){if(it(ct)==="object")return ct.clearIcon;if(Et)return Et},[ct,Et]),Sn=ke.useMemo(function(){return!!(!Bt&&ct&&(Ke.length||hn)&&!(qt==="combobox"&&hn===""))},[ct,Bt,Ke.length,hn,qt]);return{allowClear:Sn,clearIcon:ke.createElement(Ri,{className:"".concat(Le,"-clear"),onMouseDown:je,customizeIcon:nn},"\xD7")}},wr=ke.createContext(null);function fr(){return ke.useContext(wr)}function Ei(){var Se=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,Le=ke.useState(!1),je=Dn(Le,2),Ke=je[0],ct=je[1],Et=ke.useRef(null),Bt=function(){window.clearTimeout(Et.current)};ke.useEffect(function(){return Bt},[]);var hn=function(nn,Sn){Bt(),Et.current=window.setTimeout(function(){ct(nn),Sn&&Sn()},Se)};return[Ke,hn,Bt]}function Di(){var Se=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,Le=ke.useRef(null),je=ke.useRef(null);ke.useEffect(function(){return function(){window.clearTimeout(je.current)}},[]);function Ke(ct){(ct||Le.current===null)&&(Le.current=ct),window.clearTimeout(je.current),je.current=window.setTimeout(function(){Le.current=null},Se)}return[function(){return Le.current},Ke]}function uo(Se,Le,je,Ke){var ct=ke.useRef(null);ct.current={open:Le,triggerOpen:je,customizedTrigger:Ke},ke.useEffect(function(){function Et(Bt){var hn;if(!((hn=ct.current)!==null&&hn!==void 0&&hn.customizedTrigger)){var qt=Bt.target;qt.shadowRoot&&Bt.composed&&(qt=Bt.composedPath()[0]||qt),ct.current.open&&Se().filter(function(nn){return nn}).every(function(nn){return!nn.contains(qt)&&nn!==qt})&&ct.current.triggerOpen(!1)}}return window.addEventListener("mousedown",Et),function(){return window.removeEventListener("mousedown",Et)}},[])}var vt={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(Le){var je=Le.keyCode;if(Le.altKey&&!Le.ctrlKey||Le.metaKey||je>=vt.F1&&je<=vt.F12)return!1;switch(je){case vt.ALT:case vt.CAPS_LOCK:case vt.CONTEXT_MENU:case vt.CTRL:case vt.DOWN:case vt.END:case vt.ESC:case vt.HOME:case vt.INSERT:case vt.LEFT:case vt.MAC_FF_META:case vt.META:case vt.NUMLOCK:case vt.NUM_CENTER:case vt.PAGE_DOWN:case vt.PAGE_UP:case vt.PAUSE:case vt.PRINT_SCREEN:case vt.RIGHT:case vt.SHIFT:case vt.UP:case vt.WIN_KEY:case vt.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(Le){if(Le>=vt.ZERO&&Le<=vt.NINE||Le>=vt.NUM_ZERO&&Le<=vt.NUM_MULTIPLY||Le>=vt.A&&Le<=vt.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&Le===0)return!0;switch(Le){case vt.SPACE:case vt.QUESTION_MARK:case vt.NUM_PLUS:case vt.NUM_MINUS:case vt.NUM_PERIOD:case vt.NUM_DIVISION:case vt.SEMICOLON:case vt.DASH:case vt.EQUALS:case vt.COMMA:case vt.PERIOD:case vt.SLASH:case vt.APOSTROPHE:case vt.SINGLE_QUOTE:case vt.OPEN_SQUARE_BRACKET:case vt.BACKSLASH:case vt.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},ei=vt;function co(Se){return Se&&![ei.ESC,ei.SHIFT,ei.BACKSPACE,ei.TAB,ei.WIN_KEY,ei.ALT,ei.META,ei.WIN_KEY_RIGHT,ei.CTRL,ei.SEMICOLON,ei.EQUALS,ei.CAPS_LOCK,ei.CONTEXT_MENU,ei.F1,ei.F2,ei.F3,ei.F4,ei.F5,ei.F6,ei.F7,ei.F8,ei.F9,ei.F10,ei.F11,ei.F12].includes(Se)}var bo=`accept acceptCharset accessKey action allowFullScreen allowTransparency
alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge
charSet checked classID className colSpan cols content contentEditable contextMenu
controls coords crossOrigin data dateTime default defer dir disabled download draggable
encType form formAction formEncType formMethod formNoValidate formTarget frameBorder
headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity
is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media
mediaGroup method min minLength multiple muted name noValidate nonce open
optimum pattern placeholder poster preload radioGroup readOnly rel required
reversed role rowSpan rows sandbox scope scoped scrolling seamless selected
shape size sizes span spellCheck src srcDoc srcLang srcSet start step style
summary tabIndex target title type useMap value width wmode wrap`,Ui=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown
onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick
onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown
onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel
onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough
onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata
onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,yo="".concat(bo," ").concat(Ui).split(/[\s\n]+/),ha="aria-",Ka="data-";function Ra(Se,Le){return Se.indexOf(Le)===0}function ca(Se){var Le=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,je;Le===!1?je={aria:!0,data:!0,attr:!0}:Le===!0?je={aria:!0}:je=Tt({},Le);var Ke={};return Object.keys(Se).forEach(function(ct){(je.aria&&(ct==="role"||Ra(ct,ha))||je.data&&Ra(ct,Ka)||je.attr&&yo.includes(ct))&&(Ke[ct]=Se[ct])}),Ke}function ma(){return ma=Object.assign?Object.assign.bind():function(Se){for(var Le=1;Le<arguments.length;Le++){var je=arguments[Le];for(var Ke in je)Object.prototype.hasOwnProperty.call(je,Ke)&&(Se[Ke]=je[Ke])}return Se},ma.apply(this,arguments)}function Ho(Se){"@babel/helpers - typeof";return Ho=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Le){return typeof Le}:function(Le){return Le&&typeof Symbol=="function"&&Le.constructor===Symbol&&Le!==Symbol.prototype?"symbol":typeof Le},Ho(Se)}function _r(Se,Le){if(Ho(Se)!=="object"||Se===null)return Se;var je=Se[Symbol.toPrimitive];if(je!==void 0){var Ke=je.call(Se,Le||"default");if(Ho(Ke)!=="object")return Ke;throw new TypeError("@@toPrimitive must return a primitive value.")}return(Le==="string"?String:Number)(Se)}function Fn(Se){var Le=_r(Se,"string");return Ho(Le)==="symbol"?Le:String(Le)}function we(Se,Le,je){return Le=Fn(Le),Le in Se?Object.defineProperty(Se,Le,{value:je,enumerable:!0,configurable:!0,writable:!0}):Se[Le]=je,Se}function Qn(Se,Le){var je=Object.keys(Se);if(Object.getOwnPropertySymbols){var Ke=Object.getOwnPropertySymbols(Se);Le&&(Ke=Ke.filter(function(ct){return Object.getOwnPropertyDescriptor(Se,ct).enumerable})),je.push.apply(je,Ke)}return je}function bn(Se){for(var Le=1;Le<arguments.length;Le++){var je=arguments[Le]!=null?arguments[Le]:{};Le%2?Qn(Object(je),!0).forEach(function(Ke){we(Se,Ke,je[Ke])}):Object.getOwnPropertyDescriptors?Object.defineProperties(Se,Object.getOwnPropertyDescriptors(je)):Qn(Object(je)).forEach(function(Ke){Object.defineProperty(Se,Ke,Object.getOwnPropertyDescriptor(je,Ke))})}return Se}function on(Se){if(Array.isArray(Se))return Se}function ln(Se,Le){var je=Se==null?null:typeof Symbol!="undefined"&&Se[Symbol.iterator]||Se["@@iterator"];if(je!=null){var Ke,ct,Et,Bt,hn=[],qt=!0,nn=!1;try{if(Et=(je=je.call(Se)).next,Le===0){if(Object(je)!==je)return;qt=!1}else for(;!(qt=(Ke=Et.call(je)).done)&&(hn.push(Ke.value),hn.length!==Le);qt=!0);}catch(Sn){nn=!0,ct=Sn}finally{try{if(!qt&&je.return!=null&&(Bt=je.return(),Object(Bt)!==Bt))return}finally{if(nn)throw ct}}return hn}}function gn(Se,Le){(Le==null||Le>Se.length)&&(Le=Se.length);for(var je=0,Ke=new Array(Le);je<Le;je++)Ke[je]=Se[je];return Ke}function Vn(Se,Le){if(Se){if(typeof Se=="string")return gn(Se,Le);var je=Object.prototype.toString.call(Se).slice(8,-1);if(je==="Object"&&Se.constructor&&(je=Se.constructor.name),je==="Map"||je==="Set")return Array.from(Se);if(je==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(je))return gn(Se,Le)}}function _i(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function jt(Se,Le){return on(Se)||ln(Se,Le)||Vn(Se,Le)||_i()}function zt(Se,Le){if(Se==null)return{};var je={},Ke=Object.keys(Se),ct,Et;for(Et=0;Et<Ke.length;Et++)ct=Ke[Et],!(Le.indexOf(ct)>=0)&&(je[ct]=Se[ct]);return je}function Ct(Se,Le){if(Se==null)return{};var je=zt(Se,Le),Ke,ct;if(Object.getOwnPropertySymbols){var Et=Object.getOwnPropertySymbols(Se);for(ct=0;ct<Et.length;ct++)Ke=Et[ct],!(Le.indexOf(Ke)>=0)&&Object.prototype.propertyIsEnumerable.call(Se,Ke)&&(je[Ke]=Se[Ke])}return je}var Yt=De(48555);function ci(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var vi=ci()?ke.useLayoutEffect:ke.useEffect,ai=function(Le,je){var Ke=ke.useRef(!0);vi(function(){return Le(Ke.current)},je),vi(function(){return Ke.current=!1,function(){Ke.current=!0}},[])},Kt=function(Le,je){ai(function(Ke){if(!Ke)return Le()},je)},wn=ai,pi=["prefixCls","invalidate","item","renderItem","responsive","responsiveDisabled","registerSize","itemKey","className","style","children","display","order","component"],ji=void 0;function Rn(Se,Le){var je=Se.prefixCls,Ke=Se.invalidate,ct=Se.item,Et=Se.renderItem,Bt=Se.responsive,hn=Se.responsiveDisabled,qt=Se.registerSize,nn=Se.itemKey,Sn=Se.className,yn=Se.style,Jn=Se.children,In=Se.display,Mn=Se.order,Kn=Se.component,ni=Kn===void 0?"div":Kn,yi=Ct(Se,pi),$i=Bt&&!In;function Ai(Pi){qt(nn,Pi)}ke.useEffect(function(){return function(){Ai(null)}},[]);var bi=Et&&ct!==ji?Et(ct):Jn,dr;Ke||(dr={opacity:$i?0:1,height:$i?0:ji,overflowY:$i?"hidden":ji,order:Bt?Mn:ji,pointerEvents:$i?"none":ji,position:$i?"absolute":ji});var Wn={};$i&&(Wn["aria-hidden"]=!0);var Ji=ke.createElement(ni,ma({className:qe()(!Ke&&je,Sn),style:bn(bn({},dr),yn)},Wn,yi,{ref:Le}),bi);return Bt&&(Ji=ke.createElement(Yt.Z,{onResize:function(tr){var ar=tr.offsetWidth;Ai(ar)},disabled:hn},Ji)),Ji}var Dt=ke.forwardRef(Rn);Dt.displayName="Item";var wi=Dt;function gr(Se){var Le=ke.useRef();Le.current=Se;var je=ke.useCallback(function(){for(var Ke,ct=arguments.length,Et=new Array(ct),Bt=0;Bt<ct;Bt++)Et[Bt]=arguments[Bt];return(Ke=Le.current)===null||Ke===void 0?void 0:Ke.call.apply(Ke,[Le].concat(Et))},[]);return je}var eo=De(73935),kn=function(Le){return+setTimeout(Le,16)},Xi=function(Le){return clearTimeout(Le)};typeof window!="undefined"&&"requestAnimationFrame"in window&&(kn=function(Le){return window.requestAnimationFrame(Le)},Xi=function(Le){return window.cancelAnimationFrame(Le)});var Lo=0,La=new Map;function $o(Se){La.delete(Se)}var qi=function(Le){var je=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;Lo+=1;var Ke=Lo;function ct(Et){if(Et===0)$o(Ke),Le();else{var Bt=kn(function(){ct(Et-1)});La.set(Ke,Bt)}}return ct(je),Ke};qi.cancel=function(Se){var Le=La.get(Se);return $o(Le),Xi(Le)};var Zi=qi;function cr(Se){if(typeof MessageChannel=="undefined")Zi(Se);else{var Le=new MessageChannel;Le.port1.onmessage=function(){return Se()},Le.port2.postMessage(void 0)}}function Co(){var Se=ke.useRef(null),Le=function(Ke){Se.current||(Se.current=[],cr(function(){(0,eo.unstable_batchedUpdates)(function(){Se.current.forEach(function(ct){ct()}),Se.current=null})})),Se.current.push(Ke)};return Le}function Zo(Se,Le){var je=ke.useState(Le),Ke=jt(je,2),ct=Ke[0],Et=Ke[1],Bt=gr(function(hn){Se(function(){Et(hn)})});return[ct,Bt]}var ri=ke.createContext(null),Lr=["component"],ml=["className"],Fs=["className"],gs=function(Le,je){var Ke=ke.useContext(ri);if(!Ke){var ct=Le.component,Et=ct===void 0?"div":ct,Bt=Ct(Le,Lr);return ke.createElement(Et,ma({},Bt,{ref:je}))}var hn=Ke.className,qt=Ct(Ke,ml),nn=Le.className,Sn=Ct(Le,Fs);return ke.createElement(ri.Provider,{value:null},ke.createElement(wi,ma({ref:je,className:qe()(hn,nn)},qt,Sn)))},Vt=ke.forwardRef(gs);Vt.displayName="RawItem";var Kr=Vt,Ko=["prefixCls","data","renderItem","renderRawItem","itemKey","itemWidth","ssr","style","className","maxCount","renderRest","renderRawRest","suffix","component","itemComponent","onVisibleChange"],Er="responsive",Wa="invalidate";function Wo(Se){return"+ ".concat(Se.length," ...")}function ea(Se,Le){var je=Se.prefixCls,Ke=je===void 0?"rc-overflow":je,ct=Se.data,Et=ct===void 0?[]:ct,Bt=Se.renderItem,hn=Se.renderRawItem,qt=Se.itemKey,nn=Se.itemWidth,Sn=nn===void 0?10:nn,yn=Se.ssr,Jn=Se.style,In=Se.className,Mn=Se.maxCount,Kn=Se.renderRest,ni=Se.renderRawRest,yi=Se.suffix,$i=Se.component,Ai=$i===void 0?"div":$i,bi=Se.itemComponent,dr=Se.onVisibleChange,Wn=Ct(Se,Ko),Ji=yn==="full",Pi=Co(),tr=Zo(Pi,null),ar=jt(tr,2),ki=ar[0],Fr=ar[1],hr=ki||0,Mr=Zo(Pi,new Map),Ti=jt(Mr,2),pr=Ti[0],qr=Ti[1],Po=Zo(Pi,0),no=jt(Po,2),Qi=no[0],zr=no[1],$r=Zo(Pi,0),lo=jt($r,2),Uo=lo[0],So=lo[1],Ar=Zo(Pi,0),ur=jt(Ar,2),Vr=ur[0],Do=ur[1],Nr=(0,ke.useState)(null),Wi=jt(Nr,2),ir=Wi[0],rr=Wi[1],Fi=(0,ke.useState)(null),zi=jt(Fi,2),Sr=zi[0],io=zi[1],Xr=ke.useMemo(function(){return Sr===null&&Ji?Number.MAX_SAFE_INTEGER:Sr||0},[Sr,ki]),Ir=(0,ke.useState)(!1),wa=jt(Ir,2),ra=wa[0],Xo=wa[1],pa="".concat(Ke,"-item"),ro=Math.max(Qi,Uo),Jo=Mn===Er,va=Et.length&&Jo,ds=Mn===Wa,Pa=va||typeof Mn=="number"&&Et.length>Mn,Ba=(0,ke.useMemo)(function(){var Hi=Et;return va?ki===null&&Ji?Hi=Et:Hi=Et.slice(0,Math.min(Et.length,hr/Sn)):typeof Mn=="number"&&(Hi=Et.slice(0,Mn)),Hi},[Et,Sn,ki,Mn,va]),Bo=(0,ke.useMemo)(function(){return va?Et.slice(Xr+1):Et.slice(Ba.length)},[Et,Ba,va,Xr]),Za=(0,ke.useCallback)(function(Hi,Tr){var nr;return typeof qt=="function"?qt(Hi):(nr=qt&&(Hi==null?void 0:Hi[qt]))!==null&&nr!==void 0?nr:Tr},[qt]),Fa=(0,ke.useCallback)(Bt||function(Hi){return Hi},[Bt]);function ns(Hi,Tr,nr){Sr===Hi&&(Tr===void 0||Tr===ir)||(io(Hi),nr||(Xo(Hi<Et.length-1),dr==null||dr(Hi)),Tr!==void 0&&rr(Tr))}function Vi(Hi,Tr){Fr(Tr.clientWidth)}function Ki(Hi,Tr){qr(function(nr){var ho=new Map(nr);return Tr===null?ho.delete(Hi):ho.set(Hi,Tr),ho})}function or(Hi,Tr){So(Tr),zr(Uo)}function Jr(Hi,Tr){Do(Tr)}function ta(Hi){return pr.get(Za(Ba[Hi],Hi))}wn(function(){if(hr&&typeof ro=="number"&&Ba){var Hi=Vr,Tr=Ba.length,nr=Tr-1;if(!Tr){ns(0,null);return}for(var ho=0;ho<Tr;ho+=1){var Ca=ta(ho);if(Ji&&(Ca=Ca||0),Ca===void 0){ns(ho-1,void 0,!0);break}if(Hi+=Ca,nr===0&&Hi<=hr||ho===nr-1&&Hi+ta(nr)<=hr){ns(nr,null);break}else if(Hi+ro>hr){ns(ho-1,Hi-Ca-Vr+Uo);break}}yi&&ta(0)+Vr>hr&&rr(null)}},[hr,pr,Uo,Vr,Za,Ba]);var Ha=ra&&!!Bo.length,ls={};ir!==null&&va&&(ls={position:"absolute",left:ir,top:0});var bt={prefixCls:pa,responsive:va,component:bi,invalidate:ds},xo=hn?function(Hi,Tr){var nr=Za(Hi,Tr);return ke.createElement(ri.Provider,{key:nr,value:bn(bn({},bt),{},{order:Tr,item:Hi,itemKey:nr,registerSize:Ki,display:Tr<=Xr})},hn(Hi,Tr))}:function(Hi,Tr){var nr=Za(Hi,Tr);return ke.createElement(wi,ma({},bt,{order:Tr,key:nr,item:Hi,renderItem:Fa,itemKey:nr,registerSize:Ki,display:Tr<=Xr}))},zo,na={order:Ha?Xr:Number.MAX_SAFE_INTEGER,className:"".concat(pa,"-rest"),registerSize:or,display:Ha};if(ni)ni&&(zo=ke.createElement(ri.Provider,{value:bn(bn({},bt),na)},ni(Bo)));else{var js=Kn||Wo;zo=ke.createElement(wi,ma({},bt,na),typeof js=="function"?js(Bo):js)}var us=ke.createElement(Ai,ma({className:qe()(!ds&&Ke,In),style:Jn,ref:Le},Wn),Ba.map(xo),Pa?zo:null,yi&&ke.createElement(wi,ma({},bt,{responsive:Jo,responsiveDisabled:!va,order:Xr,className:"".concat(pa,"-suffix"),registerSize:Jr,display:!0,style:ls}),yi));return Jo&&(us=ke.createElement(Yt.Z,{onResize:Vi,disabled:!va},us)),us}var fo=ke.forwardRef(ea);fo.displayName="Overflow",fo.Item=Kr,fo.RESPONSIVE=Er,fo.INVALIDATE=Wa;var Oo=fo,xa=Oo,An=function(Le,je){var Ke,ct=Le.prefixCls,Et=Le.id,Bt=Le.inputElement,hn=Le.disabled,qt=Le.tabIndex,nn=Le.autoFocus,Sn=Le.autoComplete,yn=Le.editable,Jn=Le.activeDescendantId,In=Le.value,Mn=Le.maxLength,Kn=Le.onKeyDown,ni=Le.onMouseDown,yi=Le.onChange,$i=Le.onPaste,Ai=Le.onCompositionStart,bi=Le.onCompositionEnd,dr=Le.onBlur,Wn=Le.open,Ji=Le.attrs,Pi=Bt||ke.createElement("input",null),tr=Pi,ar=tr.ref,ki=tr.props,Fr=ki.onKeyDown,hr=ki.onChange,Mr=ki.onMouseDown,Ti=ki.onCompositionStart,pr=ki.onCompositionEnd,qr=ki.onBlur,Po=ki.style;return"maxLength"in Pi.props,Pi=ke.cloneElement(Pi,Tt(Tt(Tt({type:"search"},ki),{},{id:Et,ref:Hn(je,ar),disabled:hn,tabIndex:qt,autoComplete:Sn||"off",autoFocus:nn,className:qe()("".concat(ct,"-selection-search-input"),(Ke=Pi)===null||Ke===void 0||(Ke=Ke.props)===null||Ke===void 0?void 0:Ke.className),role:"combobox","aria-expanded":Wn||!1,"aria-haspopup":"listbox","aria-owns":"".concat(Et,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(Et,"_list"),"aria-activedescendant":Wn?Jn:void 0},Ji),{},{value:yn?In:"",maxLength:Mn,readOnly:!yn,unselectable:yn?null:"on",style:Tt(Tt({},Po),{},{opacity:yn?null:0}),onKeyDown:function(Qi){Kn(Qi),Fr&&Fr(Qi)},onMouseDown:function(Qi){ni(Qi),Mr&&Mr(Qi)},onChange:function(Qi){yi(Qi),hr&&hr(Qi)},onCompositionStart:function(Qi){Ai(Qi),Ti&&Ti(Qi)},onCompositionEnd:function(Qi){bi(Qi),pr&&pr(Qi)},onPaste:$i,onBlur:function(Qi){dr(Qi),qr&&qr(Qi)}})),Pi},Ya=ke.forwardRef(An),Pn=Ya;function jo(Se){return Array.isArray(Se)?Se:Se!==void 0?[Se]:[]}var Ws=typeof window!="undefined"&&window.document&&window.document.documentElement,qa=Ws;function bl(Se){return Se!=null}function Xa(Se){return!Se&&Se!==0}function _o(Se){return["string","number"].includes(it(Se))}function Va(Se){var Le=void 0;return Se&&(_o(Se.title)?Le=Se.title.toString():_o(Se.label)&&(Le=Se.label.toString())),Le}function il(Se,Le){qa?ke.useLayoutEffect(Se,Le):ke.useEffect(Se,Le)}function Na(Se){var Le;return(Le=Se.key)!==null&&Le!==void 0?Le:Se.value}var Li=function(Le){Le.preventDefault(),Le.stopPropagation()},Qe=function(Le){var je=Le.id,Ke=Le.prefixCls,ct=Le.values,Et=Le.open,Bt=Le.searchValue,hn=Le.autoClearSearchValue,qt=Le.inputRef,nn=Le.placeholder,Sn=Le.disabled,yn=Le.mode,Jn=Le.showSearch,In=Le.autoFocus,Mn=Le.autoComplete,Kn=Le.activeDescendantId,ni=Le.tabIndex,yi=Le.removeIcon,$i=Le.maxTagCount,Ai=Le.maxTagTextLength,bi=Le.maxTagPlaceholder,dr=bi===void 0?function(Fi){return"+ ".concat(Fi.length," ...")}:bi,Wn=Le.tagRender,Ji=Le.onToggleOpen,Pi=Le.onRemove,tr=Le.onInputChange,ar=Le.onInputPaste,ki=Le.onInputKeyDown,Fr=Le.onInputMouseDown,hr=Le.onInputCompositionStart,Mr=Le.onInputCompositionEnd,Ti=Le.onInputBlur,pr=ke.useRef(null),qr=(0,ke.useState)(0),Po=Dn(qr,2),no=Po[0],Qi=Po[1],zr=(0,ke.useState)(!1),$r=Dn(zr,2),lo=$r[0],Uo=$r[1],So="".concat(Ke,"-selection"),Ar=Et||yn==="multiple"&&hn===!1||yn==="tags"?Bt:"",ur=yn==="tags"||yn==="multiple"&&hn===!1||Jn&&(Et||lo);il(function(){Qi(pr.current.scrollWidth)},[Ar]);var Vr=function(zi,Sr,io,Xr,Ir){return ke.createElement("span",{title:Va(zi),className:qe()("".concat(So,"-item"),Ft({},"".concat(So,"-item-disabled"),io))},ke.createElement("span",{className:"".concat(So,"-item-content")},Sr),Xr&&ke.createElement(Ri,{className:"".concat(So,"-item-remove"),onMouseDown:Li,onClick:Ir,customizeIcon:yi},"\xD7"))},Do=function(zi,Sr,io,Xr,Ir,wa){var ra=function(pa){Li(pa),Ji(!Et)};return ke.createElement("span",{onMouseDown:ra},Wn({label:Sr,value:zi,disabled:io,closable:Xr,onClose:Ir,isMaxTag:!!wa}))},Nr=function(zi){var Sr=zi.disabled,io=zi.label,Xr=zi.value,Ir=!Sn&&!Sr,wa=io;if(typeof Ai=="number"&&(typeof io=="string"||typeof io=="number")){var ra=String(wa);ra.length>Ai&&(wa="".concat(ra.slice(0,Ai),"..."))}var Xo=function(ro){ro&&ro.stopPropagation(),Pi(zi)};return typeof Wn=="function"?Do(Xr,wa,Sr,Ir,Xo):Vr(zi,wa,Sr,Ir,Xo)},Wi=function(zi){if(!ct.length)return null;var Sr=typeof dr=="function"?dr(zi):dr;return typeof Wn=="function"?Do(void 0,Sr,!1,!1,void 0,!0):Vr({title:Sr},Sr,!1)},ir=ke.createElement("div",{className:"".concat(So,"-search"),style:{width:no},onFocus:function(){Uo(!0)},onBlur:function(){Uo(!1)}},ke.createElement(Pn,{ref:qt,open:Et,prefixCls:Ke,id:je,inputElement:null,disabled:Sn,autoFocus:In,autoComplete:Mn,editable:ur,activeDescendantId:Kn,value:Ar,onKeyDown:ki,onMouseDown:Fr,onChange:tr,onPaste:ar,onCompositionStart:hr,onCompositionEnd:Mr,onBlur:Ti,tabIndex:ni,attrs:ca(Le,!0)}),ke.createElement("span",{ref:pr,className:"".concat(So,"-search-mirror"),"aria-hidden":!0},Ar,"\xA0")),rr=ke.createElement(xa,{prefixCls:"".concat(So,"-overflow"),data:ct,renderItem:Nr,renderRest:Wi,suffix:ir,itemKey:Na,maxCount:$i});return ke.createElement("span",{className:"".concat(So,"-wrap")},rr,!ct.length&&!Ar&&ke.createElement("span",{className:"".concat(So,"-placeholder")},nn))},bs=Qe,Ul=function(Le){var je=Le.inputElement,Ke=Le.prefixCls,ct=Le.id,Et=Le.inputRef,Bt=Le.disabled,hn=Le.autoFocus,qt=Le.autoComplete,nn=Le.activeDescendantId,Sn=Le.mode,yn=Le.open,Jn=Le.values,In=Le.placeholder,Mn=Le.tabIndex,Kn=Le.showSearch,ni=Le.searchValue,yi=Le.activeValue,$i=Le.maxLength,Ai=Le.onInputKeyDown,bi=Le.onInputMouseDown,dr=Le.onInputChange,Wn=Le.onInputPaste,Ji=Le.onInputCompositionStart,Pi=Le.onInputCompositionEnd,tr=Le.onInputBlur,ar=Le.title,ki=ke.useState(!1),Fr=Dn(ki,2),hr=Fr[0],Mr=Fr[1],Ti=Sn==="combobox",pr=Ti||Kn,qr=Jn[0],Po=ni||"";Ti&&yi&&!hr&&(Po=yi),ke.useEffect(function(){Ti&&Mr(!1)},[Ti,yi]);var no=Sn!=="combobox"&&!yn&&!Kn?!1:!!Po,Qi=ar===void 0?Va(qr):ar,zr=ke.useMemo(function(){return qr?null:ke.createElement("span",{className:"".concat(Ke,"-selection-placeholder"),style:no?{visibility:"hidden"}:void 0},In)},[qr,no,In,Ke]);return ke.createElement("span",{className:"".concat(Ke,"-selection-wrap")},ke.createElement("span",{className:"".concat(Ke,"-selection-search")},ke.createElement(Pn,{ref:Et,prefixCls:Ke,id:ct,open:yn,inputElement:je,disabled:Bt,autoFocus:hn,autoComplete:qt,editable:pr,activeDescendantId:nn,value:Po,onKeyDown:Ai,onMouseDown:bi,onChange:function(lo){Mr(!0),dr(lo)},onPaste:Wn,onCompositionStart:Ji,onCompositionEnd:Pi,onBlur:tr,tabIndex:Mn,attrs:ca(Le,!0),maxLength:Ti?$i:void 0})),!Ti&&qr?ke.createElement("span",{className:"".concat(Ke,"-selection-item"),title:Qi,style:no?{visibility:"hidden"}:void 0},qr.label):null,zr)},Zl=Ul,rl=function(Le,je){var Ke=(0,ke.useRef)(null),ct=(0,ke.useRef)(!1),Et=Le.prefixCls,Bt=Le.open,hn=Le.mode,qt=Le.showSearch,nn=Le.tokenWithEnter,Sn=Le.disabled,yn=Le.prefix,Jn=Le.autoClearSearchValue,In=Le.onSearch,Mn=Le.onSearchSubmit,Kn=Le.onToggleOpen,ni=Le.onInputKeyDown,yi=Le.onInputBlur,$i=Le.domRef;ke.useImperativeHandle(je,function(){return{focus:function(Qi){Ke.current.focus(Qi)},blur:function(){Ke.current.blur()}}});var Ai=Di(0),bi=Dn(Ai,2),dr=bi[0],Wn=bi[1],Ji=function(Qi){var zr=Qi.which,$r=Ke.current instanceof HTMLTextAreaElement;!$r&&Bt&&(zr===ei.UP||zr===ei.DOWN)&&Qi.preventDefault(),ni&&ni(Qi),zr===ei.ENTER&&hn==="tags"&&!ct.current&&!Bt&&(Mn==null||Mn(Qi.target.value)),!($r&&!Bt&&~[ei.UP,ei.DOWN,ei.LEFT,ei.RIGHT].indexOf(zr))&&co(zr)&&Kn(!0)},Pi=function(){Wn(!0)},tr=(0,ke.useRef)(null),ar=function(Qi){In(Qi,!0,ct.current)!==!1&&Kn(!0)},ki=function(){ct.current=!0},Fr=function(Qi){ct.current=!1,hn!=="combobox"&&ar(Qi.target.value)},hr=function(Qi){var zr=Qi.target.value;if(nn&&tr.current&&/[\r\n]/.test(tr.current)){var $r=tr.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");zr=zr.replace($r,tr.current)}tr.current=null,ar(zr)},Mr=function(Qi){var zr=Qi.clipboardData,$r=zr==null?void 0:zr.getData("text");tr.current=$r||""},Ti=function(Qi){var zr=Qi.target;if(zr!==Ke.current){var $r=document.body.style.msTouchAction!==void 0;$r?setTimeout(function(){Ke.current.focus()}):Ke.current.focus()}},pr=function(Qi){var zr=dr();Qi.target!==Ke.current&&!zr&&!(hn==="combobox"&&Sn)&&Qi.preventDefault(),(hn!=="combobox"&&(!qt||!zr)||!Bt)&&(Bt&&Jn!==!1&&In("",!0,!1),Kn())},qr={inputRef:Ke,onInputKeyDown:Ji,onInputMouseDown:Pi,onInputChange:hr,onInputPaste:Mr,onInputCompositionStart:ki,onInputCompositionEnd:Fr,onInputBlur:yi},Po=hn==="multiple"||hn==="tags"?ke.createElement(bs,me({},Le,qr)):ke.createElement(Zl,me({},Le,qr));return ke.createElement("div",{ref:$i,className:"".concat(Et,"-selector"),onClick:Ti,onMouseDown:pr},yn&&ke.createElement("div",{className:"".concat(Et,"-prefix")},yn),Po)},tu=ke.forwardRef(rl),Il=tu,Hu=De(98280),nu=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],Ua=function(Le){var je=Le===!0?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:je,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:je,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:je,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:je,adjustY:1},htmlRegion:"scroll"}}},ps=function(Le,je){var Ke=Le.prefixCls,ct=Le.disabled,Et=Le.visible,Bt=Le.children,hn=Le.popupElement,qt=Le.animation,nn=Le.transitionName,Sn=Le.dropdownStyle,yn=Le.dropdownClassName,Jn=Le.direction,In=Jn===void 0?"ltr":Jn,Mn=Le.placement,Kn=Le.builtinPlacements,ni=Le.dropdownMatchSelectWidth,yi=Le.dropdownRender,$i=Le.dropdownAlign,Ai=Le.getPopupContainer,bi=Le.empty,dr=Le.getTriggerDOMNode,Wn=Le.onPopupVisibleChange,Ji=Le.onPopupMouseEnter,Pi=ze(Le,nu),tr="".concat(Ke,"-dropdown"),ar=hn;yi&&(ar=yi(hn));var ki=ke.useMemo(function(){return Kn||Ua(ni)},[Kn,ni]),Fr=qt?"".concat(tr,"-").concat(qt):nn,hr=typeof ni=="number",Mr=ke.useMemo(function(){return hr?null:ni===!1?"minWidth":"width"},[ni,hr]),Ti=Sn;hr&&(Ti=Tt(Tt({},Ti),{},{width:ni}));var pr=ke.useRef(null);return ke.useImperativeHandle(je,function(){return{getPopupElement:function(){var Po;return(Po=pr.current)===null||Po===void 0?void 0:Po.popupElement}}}),ke.createElement(Hu.Z,me({},Pi,{showAction:Wn?["click"]:[],hideAction:Wn?["click"]:[],popupPlacement:Mn||(In==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:ki,prefixCls:tr,popupTransitionName:Fr,popup:ke.createElement("div",{onMouseEnter:Ji},ar),ref:pr,stretch:Mr,popupAlign:$i,popupVisible:Et,getPopupContainer:Ai,popupClassName:qe()(yn,Ft({},"".concat(tr,"-empty"),bi)),popupStyle:Ti,getTriggerDOMNode:dr,onPopupVisibleChange:Wn}),Bt)},Or=ke.forwardRef(ps),Pr=Or;function so(Se){return hi(Se)||Ge(Se)||et(Se)||zn()}function fn(Se,Le){var je=Se.key,Ke;return"value"in Se&&(Ke=Se.value),je!=null?je:Ke!==void 0?Ke:"rc-index-key-".concat(Le)}function jr(Se){return typeof Se!="undefined"&&!Number.isNaN(Se)}function Ao(Se,Le){var je=Se||{},Ke=je.label,ct=je.value,Et=je.options,Bt=je.groupLabel,hn=Ke||(Le?"children":"label");return{label:hn,value:ct||"value",options:Et||"options",groupLabel:Bt||hn}}function $a(Se){var Le=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},je=Le.fieldNames,Ke=Le.childrenAsData,ct=[],Et=Ao(je,!1),Bt=Et.label,hn=Et.value,qt=Et.options,nn=Et.groupLabel;function Sn(yn,Jn){Array.isArray(yn)&&yn.forEach(function(In){if(Jn||!(qt in In)){var Mn=In[hn];ct.push({key:fn(In,ct.length),groupOption:Jn,data:In,label:In[Bt],value:Mn})}else{var Kn=In[nn];Kn===void 0&&Ke&&(Kn=In.label),ct.push({key:fn(In,ct.length),group:!0,data:In,label:Kn}),Sn(In[qt],!0)}})}return Sn(Se,!1),ct}function Ia(Se){var Le=Tt({},Se);return"props"in Le||Object.defineProperty(Le,"props",{get:function(){return Ze(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),Le}}),Le}var ms=function(Le,je,Ke){if(!je||!je.length)return null;var ct=!1,Et=function hn(qt,nn){var Sn=so(nn),yn=Sn[0],Jn=Sn.slice(1);if(!yn)return[qt];var In=qt.split(yn);return ct=ct||In.length>1,In.reduce(function(Mn,Kn){return[].concat(st(Mn),st(hn(Kn,Jn)))},[]).filter(Boolean)},Bt=Et(Le,je);return ct?typeof Ke!="undefined"?Bt.slice(0,Ke):Bt:null},Vs=ke.createContext(null),el=Vs;function vl(Se){var Le=Se.visible,je=Se.values;if(!Le)return null;var Ke=50;return ke.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},"".concat(je.slice(0,Ke).map(function(ct){var Et=ct.label,Bt=ct.value;return["number","string"].includes(it(Et))?Et:Bt}).join(", ")),je.length>Ke?", ...":null)}var Gu=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","prefix","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],Fu=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],Xt=function(Le){return Le==="tags"||Le==="multiple"},Ll=ke.forwardRef(function(Se,Le){var je,Ke=Se.id,ct=Se.prefixCls,Et=Se.className,Bt=Se.showSearch,hn=Se.tagRender,qt=Se.direction,nn=Se.omitDomProps,Sn=Se.displayValues,yn=Se.onDisplayValuesChange,Jn=Se.emptyOptions,In=Se.notFoundContent,Mn=In===void 0?"Not Found":In,Kn=Se.onClear,ni=Se.mode,yi=Se.disabled,$i=Se.loading,Ai=Se.getInputElement,bi=Se.getRawInputElement,dr=Se.open,Wn=Se.defaultOpen,Ji=Se.onDropdownVisibleChange,Pi=Se.activeValue,tr=Se.onActiveValueChange,ar=Se.activeDescendantId,ki=Se.searchValue,Fr=Se.autoClearSearchValue,hr=Se.onSearch,Mr=Se.onSearchSplit,Ti=Se.tokenSeparators,pr=Se.allowClear,qr=Se.prefix,Po=Se.suffixIcon,no=Se.clearIcon,Qi=Se.OptionList,zr=Se.animation,$r=Se.transitionName,lo=Se.dropdownStyle,Uo=Se.dropdownClassName,So=Se.dropdownMatchSelectWidth,Ar=Se.dropdownRender,ur=Se.dropdownAlign,Vr=Se.placement,Do=Se.builtinPlacements,Nr=Se.getPopupContainer,Wi=Se.showAction,ir=Wi===void 0?[]:Wi,rr=Se.onFocus,Fi=Se.onBlur,zi=Se.onKeyUp,Sr=Se.onKeyDown,io=Se.onMouseDown,Xr=ze(Se,Gu),Ir=Xt(ni),wa=(Bt!==void 0?Bt:Ir)||ni==="combobox",ra=Tt({},Xr);Fu.forEach(function(Ea){delete ra[Ea]}),nn==null||nn.forEach(function(Ea){delete ra[Ea]});var Xo=ke.useState(!1),pa=Dn(Xo,2),ro=pa[0],Jo=pa[1];ke.useEffect(function(){Jo(dn())},[]);var va=ke.useRef(null),ds=ke.useRef(null),Pa=ke.useRef(null),Ba=ke.useRef(null),Bo=ke.useRef(null),Za=ke.useRef(!1),Fa=Ei(),ns=Dn(Fa,3),Vi=ns[0],Ki=ns[1],or=ns[2];ke.useImperativeHandle(Le,function(){var Ea,ba;return{focus:(Ea=Ba.current)===null||Ea===void 0?void 0:Ea.focus,blur:(ba=Ba.current)===null||ba===void 0?void 0:ba.blur,scrollTo:function(zs){var dl;return(dl=Bo.current)===null||dl===void 0?void 0:dl.scrollTo(zs)},nativeElement:va.current||ds.current}});var Jr=ke.useMemo(function(){var Ea;if(ni!=="combobox")return ki;var ba=(Ea=Sn[0])===null||Ea===void 0?void 0:Ea.value;return typeof ba=="string"||typeof ba=="number"?String(ba):""},[ki,ni,Sn]),ta=ni==="combobox"&&typeof Ai=="function"&&Ai()||null,Ha=typeof bi=="function"&&bi(),ls=Zt(ds,Ha==null||(je=Ha.props)===null||je===void 0?void 0:je.ref),bt=ke.useState(!1),xo=Dn(bt,2),zo=xo[0],na=xo[1];xn(function(){na(!0)},[]);var js=ft(!1,{defaultValue:Wn,value:dr}),us=Dn(js,2),Hi=us[0],Tr=us[1],nr=zo?Hi:!1,ho=!Mn&&Jn;(yi||ho&&nr&&ni==="combobox")&&(nr=!1);var Ca=ho?!1:nr,Rr=ke.useCallback(function(Ea){var ba=Ea!==void 0?Ea:!nr;yi||(Tr(ba),nr!==ba&&(Ji==null||Ji(ba)))},[yi,nr,Tr,Ji]),Qo=ke.useMemo(function(){return(Ti||[]).some(function(Ea){return[`
`,`\r
`].includes(Ea)})},[Ti]),Eo=ke.useContext(el)||{},Go=Eo.maxCount,fa=Eo.rawValues,Aa=function(ba,cl,zs){if(!(Ir&&jr(Go)&&(fa==null?void 0:fa.size)>=Go)){var dl=!0,Sl=ba;tr==null||tr(null);var su=ms(ba,Ti,jr(Go)?Go-fa.size:void 0),Vl=zs?null:su;return ni!=="combobox"&&Vl&&(Sl="",Mr==null||Mr(Vl),Rr(!1),dl=!1),hr&&Jr!==Sl&&hr(Sl,{source:cl?"typing":"effect"}),dl}},ll=function(ba){!ba||!ba.trim()||hr(ba,{source:"submit"})};ke.useEffect(function(){!nr&&!Ir&&ni!=="combobox"&&Aa("",!1,!1)},[nr]),ke.useEffect(function(){Hi&&yi&&Tr(!1),yi&&!Za.current&&Ki(!1)},[yi]);var Yl=Di(),ya=Dn(Yl,2),Yo=ya[0],Sa=ya[1],is=ke.useRef(!1),Bs=function(ba){var cl=Yo(),zs=ba.key,dl=zs==="Enter";if(dl&&(ni!=="combobox"&&ba.preventDefault(),nr||Rr(!0)),Sa(!!Jr),zs==="Backspace"&&!cl&&Ir&&!Jr&&Sn.length){for(var Sl=st(Sn),su=null,Vl=Sl.length-1;Vl>=0;Vl-=1){var Mc=Sl[Vl];if(!Mc.disabled){Sl.splice(Vl,1),su=Mc;break}}su&&yn(Sl,{type:"remove",values:[su]})}for(var Ku=arguments.length,kc=new Array(Ku>1?Ku-1:0),td=1;td<Ku;td++)kc[td-1]=arguments[td];if(nr&&(!dl||!is.current)){var Hd;dl&&(is.current=!0),(Hd=Bo.current)===null||Hd===void 0||Hd.onKeyDown.apply(Hd,[ba].concat(kc))}Sr==null||Sr.apply(void 0,[ba].concat(kc))},tl=function(ba){for(var cl=arguments.length,zs=new Array(cl>1?cl-1:0),dl=1;dl<cl;dl++)zs[dl-1]=arguments[dl];if(nr){var Sl;(Sl=Bo.current)===null||Sl===void 0||Sl.onKeyUp.apply(Sl,[ba].concat(zs))}ba.key==="Enter"&&(is.current=!1),zi==null||zi.apply(void 0,[ba].concat(zs))},oo=function(ba){var cl=Sn.filter(function(zs){return zs!==ba});yn(cl,{type:"remove",values:[ba]})},Ur=function(){is.current=!1},hs=ke.useRef(!1),ul=function(){Ki(!0),yi||(rr&&!hs.current&&rr.apply(void 0,arguments),ir.includes("focus")&&Rr(!0)),hs.current=!0},nl=function(){Za.current=!0,Ki(!1,function(){hs.current=!1,Za.current=!1,Rr(!1)}),!yi&&(Jr&&(ni==="tags"?hr(Jr,{source:"submit"}):ni==="multiple"&&hr("",{source:"blur"})),Fi&&Fi.apply(void 0,arguments))},hl=[];ke.useEffect(function(){return function(){hl.forEach(function(Ea){return clearTimeout(Ea)}),hl.splice(0,hl.length)}},[]);var Os=function(ba){var cl,zs=ba.target,dl=(cl=Pa.current)===null||cl===void 0?void 0:cl.getPopupElement();if(dl&&dl.contains(zs)){var Sl=setTimeout(function(){var Ku=hl.indexOf(Sl);if(Ku!==-1&&hl.splice(Ku,1),or(),!ro&&!dl.contains(document.activeElement)){var kc;(kc=Ba.current)===null||kc===void 0||kc.focus()}});hl.push(Sl)}for(var su=arguments.length,Vl=new Array(su>1?su-1:0),Mc=1;Mc<su;Mc++)Vl[Mc-1]=arguments[Mc];io==null||io.apply(void 0,[ba].concat(Vl))},Xl=ke.useState({}),Ps=Dn(Xl,2),Ol=Ps[1];function eh(){Ol({})}var Vh;Ha&&(Vh=function(ba){Rr(ba)}),uo(function(){var Ea;return[va.current,(Ea=Pa.current)===null||Ea===void 0?void 0:Ea.getPopupElement()]},Ca,Rr,!!Ha);var jc=ke.useMemo(function(){return Tt(Tt({},Se),{},{notFoundContent:Mn,open:nr,triggerOpen:Ca,id:Ke,showSearch:wa,multiple:Ir,toggleOpen:Rr})},[Se,Mn,Ca,nr,Ke,wa,Ir,Rr]),Lc=!!Po||$i,pd;Lc&&(pd=ke.createElement(Ri,{className:qe()("".concat(ct,"-arrow"),Ft({},"".concat(ct,"-arrow-loading"),$i)),customizeIcon:Po,customizeIconProps:{loading:$i,searchValue:Jr,open:nr,focused:Vi,showSearch:wa}}));var zc=function(){var ba;Kn==null||Kn(),(ba=Ba.current)===null||ba===void 0||ba.focus(),yn([],{type:"clear",values:Sn}),Aa("",!1,!1)},ed=oi(ct,zc,Sn,pr,no,yi,Jr,ni),dh=ed.allowClear,cs=ed.clearIcon,Qa=ke.createElement(Qi,{ref:Bo}),au=qe()(ct,Et,Ft(Ft(Ft(Ft(Ft(Ft(Ft(Ft(Ft(Ft({},"".concat(ct,"-focused"),Vi),"".concat(ct,"-multiple"),Ir),"".concat(ct,"-single"),!Ir),"".concat(ct,"-allow-clear"),pr),"".concat(ct,"-show-arrow"),Lc),"".concat(ct,"-disabled"),yi),"".concat(ct,"-loading"),$i),"".concat(ct,"-open"),nr),"".concat(ct,"-customize-input"),ta),"".concat(ct,"-show-search"),wa)),Jl=ke.createElement(Pr,{ref:Pa,disabled:yi,prefixCls:ct,visible:Ca,popupElement:Qa,animation:zr,transitionName:$r,dropdownStyle:lo,dropdownClassName:Uo,direction:qt,dropdownMatchSelectWidth:So,dropdownRender:Ar,dropdownAlign:ur,placement:Vr,builtinPlacements:Do,getPopupContainer:Nr,empty:Jn,getTriggerDOMNode:function(ba){return ds.current||ba},onPopupVisibleChange:Vh,onPopupMouseEnter:eh},Ha?ke.cloneElement(Ha,{ref:ls}):ke.createElement(Il,me({},Se,{domRef:ds,prefixCls:ct,inputElement:ta,ref:Ba,id:Ke,prefix:qr,showSearch:wa,autoClearSearchValue:Fr,mode:ni,activeDescendantId:ar,tagRender:hn,values:Sn,open:nr,onToggleOpen:Rr,activeValue:Pi,searchValue:Jr,onSearch:Aa,onSearchSubmit:ll,onRemove:oo,tokenWithEnter:Qo,onInputBlur:Ur}))),Qs;return Ha?Qs=Jl:Qs=ke.createElement("div",me({className:au},ra,{ref:va,onMouseDown:Os,onKeyDown:Bs,onKeyUp:tl,onFocus:ul,onBlur:nl}),ke.createElement(vl,{visible:Vi&&!nr,values:Sn}),Jl,pd,dh&&cs),ke.createElement(wr.Provider,{value:jc},Qs)}),zl=Ll,fu=function(){return null};fu.isSelectOptGroup=!0;var As=fu,gu=function(){return null};gu.isSelectOption=!0;var xh=gu;function Xu(Se,Le){var je=Tt({},Se);return Array.isArray(Le)&&Le.forEach(function(Ke){delete je[Ke]}),je}var es=De(73299);function Ds(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var Mo=["disabled","title","children","style","className"];function Ro(Se){return typeof Se=="string"||typeof Se=="number"}var Ma=function(Le,je){var Ke=fr(),ct=Ke.prefixCls,Et=Ke.id,Bt=Ke.open,hn=Ke.multiple,qt=Ke.mode,nn=Ke.searchValue,Sn=Ke.toggleOpen,yn=Ke.notFoundContent,Jn=Ke.onPopupScroll,In=ke.useContext(el),Mn=In.maxCount,Kn=In.flattenOptions,ni=In.onActiveValue,yi=In.defaultActiveFirstOption,$i=In.onSelect,Ai=In.menuItemSelectedIcon,bi=In.rawValues,dr=In.fieldNames,Wn=In.virtual,Ji=In.direction,Pi=In.listHeight,tr=In.listItemHeight,ar=In.optionRender,ki="".concat(ct,"-item"),Fr=$n(function(){return Kn},[Bt,Kn],function(Wi,ir){return ir[0]&&Wi[1]!==ir[1]}),hr=ke.useRef(null),Mr=ke.useMemo(function(){return hn&&jr(Mn)&&(bi==null?void 0:bi.size)>=Mn},[hn,Mn,bi==null?void 0:bi.size]),Ti=function(ir){ir.preventDefault()},pr=function(ir){var rr;(rr=hr.current)===null||rr===void 0||rr.scrollTo(typeof ir=="number"?{index:ir}:ir)},qr=ke.useCallback(function(Wi){return qt==="combobox"?!1:bi.has(Wi)},[qt,st(bi).toString(),bi.size]),Po=function(ir){for(var rr=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,Fi=Fr.length,zi=0;zi<Fi;zi+=1){var Sr=(ir+zi*rr+Fi)%Fi,io=Fr[Sr]||{},Xr=io.group,Ir=io.data;if(!Xr&&!(Ir!=null&&Ir.disabled)&&(qr(Ir.value)||!Mr))return Sr}return-1},no=ke.useState(function(){return Po(0)}),Qi=Dn(no,2),zr=Qi[0],$r=Qi[1],lo=function(ir){var rr=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;$r(ir);var Fi={source:rr?"keyboard":"mouse"},zi=Fr[ir];if(!zi){ni(null,-1,Fi);return}ni(zi.value,ir,Fi)};(0,ke.useEffect)(function(){lo(yi!==!1?Po(0):-1)},[Fr.length,nn]);var Uo=ke.useCallback(function(Wi){return qt==="combobox"?String(Wi).toLowerCase()===nn.toLowerCase():bi.has(Wi)},[qt,nn,st(bi).toString(),bi.size]);(0,ke.useEffect)(function(){var Wi=setTimeout(function(){if(!hn&&Bt&&bi.size===1){var rr=Array.from(bi)[0],Fi=Fr.findIndex(function(zi){var Sr=zi.data;return Sr.value===rr});Fi!==-1&&(lo(Fi),pr(Fi))}});if(Bt){var ir;(ir=hr.current)===null||ir===void 0||ir.scrollTo(void 0)}return function(){return clearTimeout(Wi)}},[Bt,nn]);var So=function(ir){ir!==void 0&&$i(ir,{selected:!bi.has(ir)}),hn||Sn(!1)};if(ke.useImperativeHandle(je,function(){return{onKeyDown:function(ir){var rr=ir.which,Fi=ir.ctrlKey;switch(rr){case ei.N:case ei.P:case ei.UP:case ei.DOWN:{var zi=0;if(rr===ei.UP?zi=-1:rr===ei.DOWN?zi=1:Ds()&&Fi&&(rr===ei.N?zi=1:rr===ei.P&&(zi=-1)),zi!==0){var Sr=Po(zr+zi,zi);pr(Sr),lo(Sr,!0)}break}case ei.TAB:case ei.ENTER:{var io,Xr=Fr[zr];Xr&&!(Xr!=null&&(io=Xr.data)!==null&&io!==void 0&&io.disabled)&&!Mr?So(Xr.value):So(void 0),Bt&&ir.preventDefault();break}case ei.ESC:Sn(!1),Bt&&ir.stopPropagation()}},onKeyUp:function(){},scrollTo:function(ir){pr(ir)}}}),Fr.length===0)return ke.createElement("div",{role:"listbox",id:"".concat(Et,"_list"),className:"".concat(ki,"-empty"),onMouseDown:Ti},yn);var Ar=Object.keys(dr).map(function(Wi){return dr[Wi]}),ur=function(ir){return ir.label};function Vr(Wi,ir){var rr=Wi.group;return{role:rr?"presentation":"option",id:"".concat(Et,"_list_").concat(ir)}}var Do=function(ir){var rr=Fr[ir];if(!rr)return null;var Fi=rr.data||{},zi=Fi.value,Sr=rr.group,io=ca(Fi,!0),Xr=ur(rr);return rr?ke.createElement("div",me({"aria-label":typeof Xr=="string"&&!Sr?Xr:null},io,{key:ir},Vr(rr,ir),{"aria-selected":Uo(zi)}),zi):null},Nr={role:"listbox",id:"".concat(Et,"_list")};return ke.createElement(ke.Fragment,null,Wn&&ke.createElement("div",me({},Nr,{style:{height:0,width:0,overflow:"hidden"}}),Do(zr-1),Do(zr),Do(zr+1)),ke.createElement(es.Z,{itemKey:"key",ref:hr,data:Fr,height:Pi,itemHeight:tr,fullHeight:!1,onMouseDown:Ti,onScroll:Jn,virtual:Wn,direction:Ji,innerProps:Wn?null:Nr},function(Wi,ir){var rr=Wi.group,Fi=Wi.groupOption,zi=Wi.data,Sr=Wi.label,io=Wi.value,Xr=zi.key;if(rr){var Ir,wa=(Ir=zi.title)!==null&&Ir!==void 0?Ir:Ro(Sr)?Sr.toString():void 0;return ke.createElement("div",{className:qe()(ki,"".concat(ki,"-group"),zi.className),title:wa},Sr!==void 0?Sr:Xr)}var ra=zi.disabled,Xo=zi.title,pa=zi.children,ro=zi.style,Jo=zi.className,va=ze(zi,Mo),ds=Xu(va,Ar),Pa=qr(io),Ba=ra||!Pa&&Mr,Bo="".concat(ki,"-option"),Za=qe()(ki,Bo,Jo,Ft(Ft(Ft(Ft({},"".concat(Bo,"-grouped"),Fi),"".concat(Bo,"-active"),zr===ir&&!Ba),"".concat(Bo,"-disabled"),Ba),"".concat(Bo,"-selected"),Pa)),Fa=ur(Wi),ns=!Ai||typeof Ai=="function"||Pa,Vi=typeof Fa=="number"?Fa:Fa||io,Ki=Ro(Vi)?Vi.toString():void 0;return Xo!==void 0&&(Ki=Xo),ke.createElement("div",me({},ca(ds),Wn?{}:Vr(Wi,ir),{"aria-selected":Uo(io),className:Za,title:Ki,onMouseMove:function(){zr===ir||Ba||lo(ir)},onClick:function(){Ba||So(io)},style:ro}),ke.createElement("div",{className:"".concat(Bo,"-content")},typeof ar=="function"?ar(Wi,{index:ir}):Vi),ke.isValidElement(Ai)||Pa,ns&&ke.createElement(Ri,{className:"".concat(ki,"-option-state"),customizeIcon:Ai,customizeIconProps:{value:io,disabled:Ba,isSelected:Pa}},Pa?"\u2713":null))}))},Ls=ke.forwardRef(Ma),vr=Ls,$h=function(Se,Le){var je=ke.useRef({values:new Map,options:new Map}),Ke=ke.useMemo(function(){var Et=je.current,Bt=Et.values,hn=Et.options,qt=Se.map(function(yn){if(yn.label===void 0){var Jn;return Tt(Tt({},yn),{},{label:(Jn=Bt.get(yn.value))===null||Jn===void 0?void 0:Jn.label})}return yn}),nn=new Map,Sn=new Map;return qt.forEach(function(yn){nn.set(yn.value,yn),Sn.set(yn.value,Le.get(yn.value)||hn.get(yn.value))}),je.current.values=nn,je.current.options=Sn,qt},[Se,Le]),ct=ke.useCallback(function(Et){return Le.get(Et)||je.current.options.get(Et)},[Le]);return[Ke,ct]};function Nl(Se,Le){return jo(Se).join("").toUpperCase().includes(Le)}var Tl=function(Se,Le,je,Ke,ct){return ke.useMemo(function(){if(!je||Ke===!1)return Se;var Et=Le.options,Bt=Le.label,hn=Le.value,qt=[],nn=typeof Ke=="function",Sn=je.toUpperCase(),yn=nn?Ke:function(In,Mn){return ct?Nl(Mn[ct],Sn):Mn[Et]?Nl(Mn[Bt!=="children"?Bt:"label"],Sn):Nl(Mn[hn],Sn)},Jn=nn?function(In){return Ia(In)}:function(In){return In};return Se.forEach(function(In){if(In[Et]){var Mn=yn(je,Jn(In));if(Mn)qt.push(In);else{var Kn=In[Et].filter(function(ni){return yn(je,Jn(ni))});Kn.length&&qt.push(Tt(Tt({},In),{},Ft({},Et,Kn)))}return}yn(je,Jn(In))&&qt.push(In)}),qt},[Se,Ke,ct,je,Le])},wh=0,Ju=On();function Bi(){var Se;return Ju?(Se=wh,wh+=1):Se="TEST_OR_SSR",Se}function Ms(Se){var Le=ke.useState(),je=Dn(Le,2),Ke=je[0],ct=je[1];return ke.useEffect(function(){ct("rc_select_".concat(Bi()))},[]),Se||Ke}function Cs(Se){var Le=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},je=[];return ke.Children.forEach(Se,function(Ke){Ke==null&&!Le.keepEmpty||(Array.isArray(Ke)?je=je.concat(Cs(Ke)):(0,ui.isFragment)(Ke)&&Ke.props?je=je.concat(Cs(Ke.props.children,Le)):je.push(Ke))}),je}var _l=["children","value"],lh=["children"];function Ph(Se){var Le=Se,je=Le.key,Ke=Le.props,ct=Ke.children,Et=Ke.value,Bt=ze(Ke,_l);return Tt({key:je,value:Et!==void 0?Et:je,children:ct},Bt)}function ko(Se){var Le=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return Cs(Se).map(function(je,Ke){if(!ke.isValidElement(je)||!je.type)return null;var ct=je,Et=ct.type.isSelectOptGroup,Bt=ct.key,hn=ct.props,qt=hn.children,nn=ze(hn,lh);return Le||!Et?Ph(je):Tt(Tt({key:"__RC_SELECT_GRP__".concat(Bt===null?Ke:Bt,"__"),label:Bt},nn),{},{options:ko(qt)})}).filter(function(je){return je})}var Ch=function(Le,je,Ke,ct,Et){return ke.useMemo(function(){var Bt=Le,hn=!Le;hn&&(Bt=ko(je));var qt=new Map,nn=new Map,Sn=function(In,Mn,Kn){Kn&&typeof Kn=="string"&&In.set(Mn[Kn],Mn)},yn=function Jn(In){for(var Mn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Kn=0;Kn<In.length;Kn+=1){var ni=In[Kn];!ni[Ke.options]||Mn?(qt.set(ni[Ke.value],ni),Sn(nn,ni,Ke.label),Sn(nn,ni,ct),Sn(nn,ni,Et)):Jn(ni[Ke.options],!0)}};return yn(Bt),{options:Bt,valueOptions:qt,labelOptions:nn}},[Le,je,Ke,ct,Et])},iu=Ch;function yl(Se){var Le=ke.useRef();Le.current=Se;var je=ke.useCallback(function(){return Le.current.apply(Le,arguments)},[]);return je}function Hl(Se){var Le=Se.mode,je=Se.options,Ke=Se.children,ct=Se.backfill,Et=Se.allowClear,Bt=Se.placeholder,hn=Se.getInputElement,qt=Se.showSearch,nn=Se.onSearch,Sn=Se.defaultOpen,yn=Se.autoFocus,Jn=Se.labelInValue,In=Se.value,Mn=Se.inputValue,Kn=Se.optionLabelProp,ni=isMultiple(Le),yi=qt!==void 0?qt:ni||Le==="combobox",$i=je||convertChildrenToData(Ke);if(warning(Le!=="tags"||$i.every(function(Wn){return!Wn.disabled}),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),Le==="tags"||Le==="combobox"){var Ai=$i.some(function(Wn){return Wn.options?Wn.options.some(function(Ji){return typeof("value"in Ji?Ji.value:Ji.key)=="number"}):typeof("value"in Wn?Wn.value:Wn.key)=="number"});warning(!Ai,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(warning(Le!=="combobox"||!Kn,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),warning(Le==="combobox"||!ct,"`backfill` only works with `combobox` mode."),warning(Le==="combobox"||!hn,"`getInputElement` only work with `combobox` mode."),noteOnce(Le!=="combobox"||!hn||!Et||!Bt,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),nn&&!yi&&Le!=="combobox"&&Le!=="tags"&&warning(!1,"`onSearch` should work with `showSearch` instead of use alone."),noteOnce(!Sn||yn,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),In!=null){var bi=toArray(In);warning(!Jn||bi.every(function(Wn){return _typeof(Wn)==="object"&&("key"in Wn||"value"in Wn)}),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),warning(!ni||Array.isArray(In),"`value` should be array when `mode` is `multiple` or `tags`")}if(Ke){var dr=null;toNodeArray(Ke).some(function(Wn){if(!React.isValidElement(Wn)||!Wn.type)return!1;var Ji=Wn,Pi=Ji.type;if(Pi.isSelectOption)return!1;if(Pi.isSelectOptGroup){var tr=toNodeArray(Wn.props.children).every(function(ar){return!React.isValidElement(ar)||!Wn.type||ar.type.isSelectOption?!0:(dr=ar.type,!1)});return!tr}return dr=Pi,!0}),dr&&warning(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(dr.displayName||dr.name||dr,"`.")),warning(Mn===void 0,"`inputValue` is deprecated, please use `searchValue` instead.")}}function Eh(Se,Le){if(Se){var je=function Ke(ct){for(var Et=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Bt=0;Bt<ct.length;Bt++){var hn=ct[Bt];if(hn[Le==null?void 0:Le.value]===null)return warning(!1,"`value` in Select options should not be `null`."),!0;if(!Et&&Array.isArray(hn[Le==null?void 0:Le.options])&&Ke(hn[Le==null?void 0:Le.options],!0))break}};je(Se)}}var ec=null,Dl=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","labelRender","value","defaultValue","labelInValue","onChange","maxCount"],ru=["inputValue"];function uh(Se){return!Se||it(Se)!=="object"}var Ec=ke.forwardRef(function(Se,Le){var je=Se.id,Ke=Se.mode,ct=Se.prefixCls,Et=ct===void 0?"rc-select":ct,Bt=Se.backfill,hn=Se.fieldNames,qt=Se.inputValue,nn=Se.searchValue,Sn=Se.onSearch,yn=Se.autoClearSearchValue,Jn=yn===void 0?!0:yn,In=Se.onSelect,Mn=Se.onDeselect,Kn=Se.dropdownMatchSelectWidth,ni=Kn===void 0?!0:Kn,yi=Se.filterOption,$i=Se.filterSort,Ai=Se.optionFilterProp,bi=Se.optionLabelProp,dr=Se.options,Wn=Se.optionRender,Ji=Se.children,Pi=Se.defaultActiveFirstOption,tr=Se.menuItemSelectedIcon,ar=Se.virtual,ki=Se.direction,Fr=Se.listHeight,hr=Fr===void 0?200:Fr,Mr=Se.listItemHeight,Ti=Mr===void 0?20:Mr,pr=Se.labelRender,qr=Se.value,Po=Se.defaultValue,no=Se.labelInValue,Qi=Se.onChange,zr=Se.maxCount,$r=ze(Se,Dl),lo=Ms(je),Uo=Xt(Ke),So=!!(!dr&&Ji),Ar=ke.useMemo(function(){return yi===void 0&&Ke==="combobox"?!1:yi},[yi,Ke]),ur=ke.useMemo(function(){return Ao(hn,So)},[JSON.stringify(hn),So]),Vr=ft("",{value:nn!==void 0?nn:qt,postState:function(Qo){return Qo||""}}),Do=Dn(Vr,2),Nr=Do[0],Wi=Do[1],ir=iu(dr,Ji,ur,Ai,bi),rr=ir.valueOptions,Fi=ir.labelOptions,zi=ir.options,Sr=ke.useCallback(function(Rr){var Qo=jo(Rr);return Qo.map(function(Eo){var Go,fa,Aa,ll,Yl;if(uh(Eo))Go=Eo;else{var ya;Aa=Eo.key,fa=Eo.label,Go=(ya=Eo.value)!==null&&ya!==void 0?ya:Aa}var Yo=rr.get(Go);if(Yo){var Sa;if(fa===void 0&&(fa=Yo==null?void 0:Yo[bi||ur.label]),Aa===void 0&&(Aa=(Sa=Yo==null?void 0:Yo.key)!==null&&Sa!==void 0?Sa:Go),ll=Yo==null?void 0:Yo.disabled,Yl=Yo==null?void 0:Yo.title,0)var is}return{label:fa,value:Go,key:Aa,disabled:ll,title:Yl}})},[ur,bi,rr]),io=ft(Po,{value:qr}),Xr=Dn(io,2),Ir=Xr[0],wa=Xr[1],ra=ke.useMemo(function(){var Rr,Qo=Uo&&Ir===null?[]:Ir,Eo=Sr(Qo);return Ke==="combobox"&&Xa((Rr=Eo[0])===null||Rr===void 0?void 0:Rr.value)?[]:Eo},[Ir,Sr,Ke,Uo]),Xo=$h(ra,rr),pa=Dn(Xo,2),ro=pa[0],Jo=pa[1],va=ke.useMemo(function(){if(!Ke&&ro.length===1){var Rr=ro[0];if(Rr.value===null&&(Rr.label===null||Rr.label===void 0))return[]}return ro.map(function(Qo){var Eo;return Tt(Tt({},Qo),{},{label:(Eo=typeof pr=="function"?pr(Qo):Qo.label)!==null&&Eo!==void 0?Eo:Qo.value})})},[Ke,ro,pr]),ds=ke.useMemo(function(){return new Set(ro.map(function(Rr){return Rr.value}))},[ro]);ke.useEffect(function(){if(Ke==="combobox"){var Rr,Qo=(Rr=ro[0])===null||Rr===void 0?void 0:Rr.value;Wi(bl(Qo)?String(Qo):"")}},[ro]);var Pa=yl(function(Rr,Qo){var Eo=Qo!=null?Qo:Rr;return Ft(Ft({},ur.value,Rr),ur.label,Eo)}),Ba=ke.useMemo(function(){if(Ke!=="tags")return zi;var Rr=st(zi),Qo=function(Go){return rr.has(Go)};return st(ro).sort(function(Eo,Go){return Eo.value<Go.value?-1:1}).forEach(function(Eo){var Go=Eo.value;Qo(Go)||Rr.push(Pa(Go,Eo.label))}),Rr},[Pa,zi,rr,ro,Ke]),Bo=Tl(Ba,ur,Nr,Ar,Ai),Za=ke.useMemo(function(){return Ke!=="tags"||!Nr||Bo.some(function(Rr){return Rr[Ai||"value"]===Nr})||Bo.some(function(Rr){return Rr[ur.value]===Nr})?Bo:[Pa(Nr)].concat(st(Bo))},[Pa,Ai,Ke,Bo,Nr,ur]),Fa=function Rr(Qo){var Eo=st(Qo).sort(function(Go,fa){return $i(Go,fa,{searchValue:Nr})});return Eo.map(function(Go){return Array.isArray(Go.options)?Tt(Tt({},Go),{},{options:Go.options.length>0?Rr(Go.options):Go.options}):Go})},ns=ke.useMemo(function(){return $i?Fa(Za):Za},[Za,$i,Nr]),Vi=ke.useMemo(function(){return $a(ns,{fieldNames:ur,childrenAsData:So})},[ns,ur,So]),Ki=function(Qo){var Eo=Sr(Qo);if(wa(Eo),Qi&&(Eo.length!==ro.length||Eo.some(function(Aa,ll){var Yl;return((Yl=ro[ll])===null||Yl===void 0?void 0:Yl.value)!==(Aa==null?void 0:Aa.value)}))){var Go=no?Eo:Eo.map(function(Aa){return Aa.value}),fa=Eo.map(function(Aa){return Ia(Jo(Aa.value))});Qi(Uo?Go:Go[0],Uo?fa:fa[0])}},or=ke.useState(null),Jr=Dn(or,2),ta=Jr[0],Ha=Jr[1],ls=ke.useState(0),bt=Dn(ls,2),xo=bt[0],zo=bt[1],na=Pi!==void 0?Pi:Ke!=="combobox",js=ke.useCallback(function(Rr,Qo){var Eo=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Go=Eo.source,fa=Go===void 0?"keyboard":Go;zo(Qo),Bt&&Ke==="combobox"&&Rr!==null&&fa==="keyboard"&&Ha(String(Rr))},[Bt,Ke]),us=function(Qo,Eo,Go){var fa=function(){var oo,Ur=Jo(Qo);return[no?{label:Ur==null?void 0:Ur[ur.label],value:Qo,key:(oo=Ur==null?void 0:Ur.key)!==null&&oo!==void 0?oo:Qo}:Qo,Ia(Ur)]};if(Eo&&In){var Aa=fa(),ll=Dn(Aa,2),Yl=ll[0],ya=ll[1];In(Yl,ya)}else if(!Eo&&Mn&&Go!=="clear"){var Yo=fa(),Sa=Dn(Yo,2),is=Sa[0],Bs=Sa[1];Mn(is,Bs)}},Hi=yl(function(Rr,Qo){var Eo,Go=Uo?Qo.selected:!0;Go?Eo=Uo?[].concat(st(ro),[Rr]):[Rr]:Eo=ro.filter(function(fa){return fa.value!==Rr}),Ki(Eo),us(Rr,Go),Ke==="combobox"?Ha(""):(!Xt||Jn)&&(Wi(""),Ha(""))}),Tr=function(Qo,Eo){Ki(Qo);var Go=Eo.type,fa=Eo.values;(Go==="remove"||Go==="clear")&&fa.forEach(function(Aa){us(Aa.value,!1,Go)})},nr=function(Qo,Eo){if(Wi(Qo),Ha(null),Eo.source==="submit"){var Go=(Qo||"").trim();if(Go){var fa=Array.from(new Set([].concat(st(ds),[Go])));Ki(fa),us(Go,!0),Wi("")}return}Eo.source!=="blur"&&(Ke==="combobox"&&Ki(Qo),Sn==null||Sn(Qo))},ho=function(Qo){var Eo=Qo;Ke!=="tags"&&(Eo=Qo.map(function(fa){var Aa=Fi.get(fa);return Aa==null?void 0:Aa.value}).filter(function(fa){return fa!==void 0}));var Go=Array.from(new Set([].concat(st(ds),st(Eo))));Ki(Go),Go.forEach(function(fa){us(fa,!0)})},Ca=ke.useMemo(function(){var Rr=ar!==!1&&ni!==!1;return Tt(Tt({},ir),{},{flattenOptions:Vi,onActiveValue:js,defaultActiveFirstOption:na,onSelect:Hi,menuItemSelectedIcon:tr,rawValues:ds,fieldNames:ur,virtual:Rr,direction:ki,listHeight:hr,listItemHeight:Ti,childrenAsData:So,maxCount:zr,optionRender:Wn})},[zr,ir,Vi,js,na,Hi,tr,ds,ur,ar,ni,ki,hr,Ti,So,Wn]);return ke.createElement(el.Provider,{value:Ca},ke.createElement(zl,me({},$r,{id:lo,prefixCls:Et,ref:Le,omitDomProps:ru,mode:Ke,displayValues:va,onDisplayValuesChange:Tr,direction:ki,searchValue:Nr,onSearch:nr,autoClearSearchValue:Jn,onSearchSplit:ho,dropdownMatchSelectWidth:ni,OptionList:vr,emptyOptions:!Vi.length,activeValue:ta,activeDescendantId:"".concat(lo,"_list_").concat(xo)})))}),zh=Ec;zh.Option=xh,zh.OptGroup=As;var Rc=null,dc=null;function Gl(Se){var Le=ke.useRef();Le.current=Se;var je=ke.useCallback(function(){for(var Ke,ct=arguments.length,Et=new Array(ct),Bt=0;Bt<ct;Bt++)Et[Bt]=arguments[Bt];return(Ke=Le.current)===null||Ke===void 0?void 0:Ke.call.apply(Ke,[Le].concat(Et))},[]);return je}function Qu(Se){if(Array.isArray(Se))return Se}function pu(Se,Le){var je=Se==null?null:typeof Symbol!="undefined"&&Se[Symbol.iterator]||Se["@@iterator"];if(je!=null){var Ke,ct,Et,Bt,hn=[],qt=!0,nn=!1;try{if(Et=(je=je.call(Se)).next,Le===0){if(Object(je)!==je)return;qt=!1}else for(;!(qt=(Ke=Et.call(je)).done)&&(hn.push(Ke.value),hn.length!==Le);qt=!0);}catch(Sn){nn=!0,ct=Sn}finally{try{if(!qt&&je.return!=null&&(Bt=je.return(),Object(Bt)!==Bt))return}finally{if(nn)throw ct}}return hn}}function bh(Se,Le){(Le==null||Le>Se.length)&&(Le=Se.length);for(var je=0,Ke=new Array(Le);je<Le;je++)Ke[je]=Se[je];return Ke}function tc(Se,Le){if(Se){if(typeof Se=="string")return bh(Se,Le);var je=Object.prototype.toString.call(Se).slice(8,-1);if(je==="Object"&&Se.constructor&&(je=Se.constructor.name),je==="Map"||je==="Set")return Array.from(Se);if(je==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(je))return bh(Se,Le)}}function Hh(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vs(Se,Le){return Qu(Se)||pu(Se,Le)||tc(Se,Le)||Hh()}function tn(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var nc=tn()?ke.useLayoutEffect:ke.useEffect,Gh=function(Le,je){var Ke=ke.useRef(!0);nc(function(){return Le(Ke.current)},je),nc(function(){return Ke.current=!1,function(){Ke.current=!0}},[])},qu=function(Le,je){Gh(function(Ke){if(!Ke)return Le()},je)},Ml=null;function ol(Se){var Le=ke.useRef(!1),je=ke.useState(Se),Ke=vs(je,2),ct=Ke[0],Et=Ke[1];ke.useEffect(function(){return Le.current=!1,function(){Le.current=!0}},[]);function Bt(hn,qt){qt&&Le.current||Et(hn)}return[ct,Bt]}function Rs(Se){return Se!==void 0}function Us(Se,Le){var je=Le||{},Ke=je.defaultValue,ct=je.value,Et=je.onChange,Bt=je.postState,hn=ol(function(){return Rs(ct)?ct:Rs(Ke)?typeof Ke=="function"?Ke():Ke:typeof Se=="function"?Se():Se}),qt=vs(hn,2),nn=qt[0],Sn=qt[1],yn=ct!==void 0?ct:nn,Jn=Bt?Bt(yn):yn,In=Gl(Et),Mn=ol([yn]),Kn=vs(Mn,2),ni=Kn[0],yi=Kn[1];qu(function(){var Ai=ni[0];nn!==Ai&&In(nn,Ai)},[ni]),qu(function(){Rs(ct)||Sn(ct)},[ct]);var $i=Gl(function(Ai,bi){Sn(Ai,bi),yi([yn],bi)});return[Jn,$i]}var hh=ke.createContext({}),al=hh,Ss="__rc_cascader_search_mark__",os=function(Le,je,Ke){var ct=Ke.label,Et=ct===void 0?"":ct;return je.some(function(Bt){return String(Bt[Et]).toLowerCase().includes(Le.toLowerCase())})},Lh=function(Le,je,Ke,ct){return je.map(function(Et){return Et[ct.label]}).join(" / ")},Au=function(Le,je,Ke,ct,Et,Bt){var hn=Et.filter,qt=hn===void 0?os:hn,nn=Et.render,Sn=nn===void 0?Lh:nn,yn=Et.limit,Jn=yn===void 0?50:yn,In=Et.sort;return ke.useMemo(function(){var Mn=[];if(!Le)return[];function Kn(ni,yi){var $i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;ni.forEach(function(Ai){if(!(!In&&Jn!==!1&&Jn>0&&Mn.length>=Jn)){var bi=[].concat(sn(yi),[Ai]),dr=Ai[Ke.children],Wn=$i||Ai.disabled;if((!dr||dr.length===0||Bt)&&qt(Le,bi,{label:Ke.label})){var Ji;Mn.push($e($e({},Ai),{},(Ji={disabled:Wn},kt(Ji,Ke.label,Sn(Le,bi,ct,Ke)),kt(Ji,Ss,bi),kt(Ji,Ke.children,void 0),Ji)))}dr&&Kn(Ai[Ke.children],bi,Wn)}})}return Kn(je,[]),In&&Mn.sort(function(ni,yi){return In(ni[Ss],yi[Ss],Le,Ke)}),Jn!==!1&&Jn>0?Mn.slice(0,Jn):Mn},[Le,je,Ke,ct,Sn,Bt,qt,In,Jn])},kr=Au,Kh="__RC_CASCADER_SPLIT__",yt="SHOW_PARENT",Bn="SHOW_CHILD";function Kl(Se){return Se.join(Kh)}function ch(Se){return Se.map(Kl)}function $u(Se){return Se.split(Kh)}function Nu(Se){var Le=Se||{},je=Le.label,Ke=Le.value,ct=Le.children,Et=Ke||"value";return{label:je||"label",value:Et,key:Et,children:ct||"children"}}function Tu(Se,Le){var je,Ke;return(je=Se.isLeaf)!==null&&je!==void 0?je:!((Ke=Se[Le.children])!==null&&Ke!==void 0&&Ke.length)}function Wh(Se){var Le=Se.parentElement;if(Le){var je=Se.offsetTop-Le.offsetTop;je-Le.scrollTop<0?Le.scrollTo({top:je}):je+Se.offsetHeight-Le.scrollTop>Le.offsetHeight&&Le.scrollTo({top:je+Se.offsetHeight-Le.offsetHeight})}}function Du(Se,Le){return Se.map(function(je){var Ke;return(Ke=je[Ss])===null||Ke===void 0?void 0:Ke.map(function(ct){return ct[Le.value]})})}function Ns(Se){return Array.isArray(Se)&&Array.isArray(Se[0])}function to(Se){return Se?Ns(Se)?Se:(Se.length===0?[]:[Se]).map(function(Le){return Array.isArray(Le)?Le:[Le]}):[]}function Bl(Se,Le,je){var Ke=new Set(Se),ct=Le();return Se.filter(function(Et){var Bt=ct[Et],hn=Bt?Bt.parent:null,qt=Bt?Bt.children:null;return Bt&&Bt.node.disabled?!0:je===Bn?!(qt&&qt.some(function(nn){return nn.key&&Ke.has(nn.key)})):!(hn&&!hn.node.disabled&&Ke.has(hn.key))})}function Pl(Se,Le,je){for(var Ke=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,ct=Le,Et=[],Bt=function(){var nn,Sn,yn,Jn=Se[hn],In=(nn=ct)===null||nn===void 0?void 0:nn.findIndex(function(Kn){var ni=Kn[je.value];return Ke?String(ni)===String(Jn):ni===Jn}),Mn=In!==-1?(Sn=ct)===null||Sn===void 0?void 0:Sn[In]:null;Et.push({value:(yn=Mn==null?void 0:Mn[je.value])!==null&&yn!==void 0?yn:Jn,index:In,option:Mn}),ct=Mn==null?void 0:Mn[je.children]},hn=0;hn<Se.length;hn+=1)Bt();return Et}var xs=function(Se,Le,je,Ke,ct){return ke.useMemo(function(){var Et=ct||function(Bt){var hn=Ke?Bt.slice(-1):Bt,qt=" / ";return hn.every(function(nn){return["string","number"].includes(dt(nn))})?hn.join(qt):hn.reduce(function(nn,Sn,yn){var Jn=ke.isValidElement(Sn)?ke.cloneElement(Sn,{key:yn}):Sn;return yn===0?[Jn]:[].concat(sn(nn),[qt,Jn])},[])};return Se.map(function(Bt){var hn,qt=Pl(Bt,Le,je),nn=Et(qt.map(function(yn){var Jn,In=yn.option,Mn=yn.value;return(Jn=In==null?void 0:In[je.label])!==null&&Jn!==void 0?Jn:Mn}),qt.map(function(yn){var Jn=yn.option;return Jn})),Sn=Kl(Bt);return{label:nn,value:Sn,key:Sn,valueCells:Bt,disabled:(hn=qt[qt.length-1])===null||hn===void 0||(hn=hn.option)===null||hn===void 0?void 0:hn.disabled}})},[Se,Le,je,ct,Ke])};function fi(Se,Le){return ke.useCallback(function(je){var Ke=[],ct=[];return je.forEach(function(Et){var Bt=Pl(Et,Se,Le);Bt.every(function(hn){return hn.option})?ct.push(Et):Ke.push(Et)}),[ct,Ke]},[Se,Le])}var po=De(1089),Vo=function(Se,Le){var je=ke.useRef({options:[],info:{keyEntities:{},pathKeyEntities:{}}}),Ke=ke.useCallback(function(){return je.current.options!==Se&&(je.current.options=Se,je.current.info=(0,po.I8)(Se,{fieldNames:Le,initWrapper:function(Et){return $e($e({},Et),{},{pathKeyEntities:{}})},processEntity:function(Et,Bt){var hn=Et.nodes.map(function(qt){return qt[Le.value]}).join(Kh);Bt.pathKeyEntities[hn]=Et,Et.key=hn}})),je.current.info.pathKeyEntities},[Le,Se]);return Ke};function qo(Se,Le){var je=ke.useMemo(function(){return Le||[]},[Le]),Ke=Vo(je,Se),ct=ke.useCallback(function(Et){var Bt=Ke();return Et.map(function(hn){var qt=Bt[hn].nodes;return qt.map(function(nn){return nn[Se.value]})})},[Ke,Se]);return[je,Ke,ct]}var Ja={},Zs=[],mu=function(Le){Zs.push(Le)};function ka(Se,Le){if(0)var je}function sl(Se,Le){if(0)var je}function ga(){Ja={}}function ts(Se,Le,je){!Le&&!Ja[je]&&(Se(!1,je),Ja[je]=!0)}function ss(Se,Le){ts(ka,Se,Le)}function ws(Se,Le){ts(sl,Se,Le)}ss.preMessage=mu,ss.resetWarned=ga,ss.noteOnce=ws;var Ta=null;function vu(Se){return ke.useMemo(function(){if(!Se)return[!1,{}];var Le={matchInputWidth:!0,limit:50};return Se&&dt(Se)==="object"&&(Le=$e($e({},Le),Se)),Le.limit<=0&&(Le.limit=!1),[!0,Le]},[Se])}var Ni=De(17341);function ou(Se,Le,je,Ke,ct,Et,Bt,hn){return function(qt){if(!Se)Le(qt);else{var nn=Kl(qt),Sn=ch(je),yn=ch(Ke),Jn=Sn.includes(nn),In=ct.some(function(Wn){return Kl(Wn)===nn}),Mn=je,Kn=ct;if(In&&!Jn)Kn=ct.filter(function(Wn){return Kl(Wn)!==nn});else{var ni=Jn?Sn.filter(function(Wn){return Wn!==nn}):[].concat(sn(Sn),[nn]),yi=Et(),$i;if(Jn){var Ai=(0,Ni.S)(ni,{checked:!1,halfCheckedKeys:yn},yi);$i=Ai.checkedKeys}else{var bi=(0,Ni.S)(ni,!0,yi);$i=bi.checkedKeys}var dr=Bl($i,Et,hn);Mn=Bt(dr)}Le([].concat(sn(Kn),sn(Mn)))}}}function sa(Se,Le,je,Ke,ct){return ke.useMemo(function(){var Et=ct(Le),Bt=he(Et,2),hn=Bt[0],qt=Bt[1];if(!Se||!Le.length)return[hn,[],qt];var nn=ch(hn),Sn=je(),yn=(0,Ni.S)(nn,!0,Sn),Jn=yn.checkedKeys,In=yn.halfCheckedKeys;return[Ke(Jn),Ke(In),qt]},[Se,Le,je,Ke,ct])}var mo=ke.memo(function(Se){var Le=Se.children;return Le},function(Se,Le){return!Le.open}),Mh=mo;function bc(Se){var Le,je=Se.prefixCls,Ke=Se.checked,ct=Se.halfChecked,Et=Se.disabled,Bt=Se.onClick,hn=Se.disableCheckbox,qt=ke.useContext(al),nn=qt.checkable,Sn=typeof nn!="boolean"?nn:null;return ke.createElement("span",{className:qe()("".concat(je),(Le={},kt(Le,"".concat(je,"-checked"),Ke),kt(Le,"".concat(je,"-indeterminate"),!Ke&&ct),kt(Le,"".concat(je,"-disabled"),Et||hn),Le)),onClick:Bt},Sn)}var Ic="__cascader_fix_label__";function fc(Se){var Le=Se.prefixCls,je=Se.multiple,Ke=Se.options,ct=Se.activeValue,Et=Se.prevValuePath,Bt=Se.onToggleOpen,hn=Se.onSelect,qt=Se.onActive,nn=Se.checkedSet,Sn=Se.halfCheckedSet,yn=Se.loadingKeys,Jn=Se.isSelectable,In=Se.disabled,Mn="".concat(Le,"-menu"),Kn="".concat(Le,"-menu-item"),ni=ke.useContext(al),yi=ni.fieldNames,$i=ni.changeOnSelect,Ai=ni.expandTrigger,bi=ni.expandIcon,dr=ni.loadingIcon,Wn=ni.dropdownMenuColumnStyle,Ji=ni.optionRender,Pi=Ai==="hover",tr=function(Fr){return In||Fr},ar=ke.useMemo(function(){return Ke.map(function(ki){var Fr,hr=ki.disabled,Mr=ki.disableCheckbox,Ti=ki[Ss],pr=(Fr=ki[Ic])!==null&&Fr!==void 0?Fr:ki[yi.label],qr=ki[yi.value],Po=Tu(ki,yi),no=Ti?Ti.map(function(Uo){return Uo[yi.value]}):[].concat(sn(Et),[qr]),Qi=Kl(no),zr=yn.includes(Qi),$r=nn.has(Qi),lo=Sn.has(Qi);return{disabled:hr,label:pr,value:qr,isLeaf:Po,isLoading:zr,checked:$r,halfChecked:lo,option:ki,disableCheckbox:Mr,fullPath:no,fullPathKey:Qi}})},[Ke,nn,yi,Sn,yn,Et]);return ke.createElement("ul",{className:Mn,role:"menu"},ar.map(function(ki){var Fr,hr=ki.disabled,Mr=ki.label,Ti=ki.value,pr=ki.isLeaf,qr=ki.isLoading,Po=ki.checked,no=ki.halfChecked,Qi=ki.option,zr=ki.fullPath,$r=ki.fullPathKey,lo=ki.disableCheckbox,Uo=function(){if(!tr(hr)){var Vr=sn(zr);Pi&&pr&&Vr.pop(),qt(Vr)}},So=function(){Jn(Qi)&&!tr(hr)&&hn(zr,pr)},Ar;return typeof Qi.title=="string"?Ar=Qi.title:typeof Mr=="string"&&(Ar=Mr),ke.createElement("li",{key:$r,className:qe()(Kn,(Fr={},kt(Fr,"".concat(Kn,"-expand"),!pr),kt(Fr,"".concat(Kn,"-active"),ct===Ti||ct===$r),kt(Fr,"".concat(Kn,"-disabled"),tr(hr)),kt(Fr,"".concat(Kn,"-loading"),qr),Fr)),style:Wn,role:"menuitemcheckbox",title:Ar,"aria-checked":Po,"data-path-key":$r,onClick:function(){Uo(),!lo&&(!je||pr)&&So()},onDoubleClick:function(){$i&&Bt(!1)},onMouseEnter:function(){Pi&&Uo()},onMouseDown:function(Vr){Vr.preventDefault()}},je&&ke.createElement(bc,{prefixCls:"".concat(Le,"-checkbox"),checked:Po,halfChecked:no,disabled:tr(hr)||lo,disableCheckbox:lo,onClick:function(Vr){lo||(Vr.stopPropagation(),So())}}),ke.createElement("div",{className:"".concat(Kn,"-content")},Ji?Ji(Qi):Mr),!qr&&bi&&!pr&&ke.createElement("div",{className:"".concat(Kn,"-expand-icon")},bi),qr&&dr&&ke.createElement("div",{className:"".concat(Kn,"-loading-icon")},dr))}))}var kh=function(Le,je){var Ke=ke.useContext(al),ct=Ke.values,Et=ct[0],Bt=ke.useState([]),hn=he(Bt,2),qt=hn[0],nn=hn[1];return ke.useEffect(function(){Le||nn(Et||[])},[je,Et]),[qt,nn]},Fh=kh,Br={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(Le){var je=Le.keyCode;if(Le.altKey&&!Le.ctrlKey||Le.metaKey||je>=Br.F1&&je<=Br.F12)return!1;switch(je){case Br.ALT:case Br.CAPS_LOCK:case Br.CONTEXT_MENU:case Br.CTRL:case Br.DOWN:case Br.END:case Br.ESC:case Br.HOME:case Br.INSERT:case Br.LEFT:case Br.MAC_FF_META:case Br.META:case Br.NUMLOCK:case Br.NUM_CENTER:case Br.PAGE_DOWN:case Br.PAGE_UP:case Br.PAUSE:case Br.PRINT_SCREEN:case Br.RIGHT:case Br.SHIFT:case Br.UP:case Br.WIN_KEY:case Br.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(Le){if(Le>=Br.ZERO&&Le<=Br.NINE||Le>=Br.NUM_ZERO&&Le<=Br.NUM_MULTIPLY||Le>=Br.A&&Le<=Br.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&Le===0)return!0;switch(Le){case Br.SPACE:case Br.QUESTION_MARK:case Br.NUM_PLUS:case Br.NUM_MINUS:case Br.NUM_PERIOD:case Br.NUM_DIVISION:case Br.SEMICOLON:case Br.DASH:case Br.EQUALS:case Br.COMMA:case Br.PERIOD:case Br.SLASH:case Br.APOSTROPHE:case Br.SINGLE_QUOTE:case Br.OPEN_SQUARE_BRACKET:case Br.BACKSLASH:case Br.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},Wl=Br,Ue=function(Se,Le,je,Ke,ct,Et,Bt){var hn=Bt.direction,qt=Bt.searchValue,nn=Bt.toggleOpen,Sn=Bt.open,yn=hn==="rtl",Jn=ke.useMemo(function(){for(var Wn=-1,Ji=Le,Pi=[],tr=[],ar=Ke.length,ki=Du(Le,je),Fr=function(qr){var Po=Ji.findIndex(function(no,Qi){return(ki[Qi]?Kl(ki[Qi]):no[je.value])===Ke[qr]});if(Po===-1)return 1;Wn=Po,Pi.push(Wn),tr.push(Ke[qr]),Ji=Ji[Wn][je.children]},hr=0;hr<ar&&Ji&&!Fr(hr);hr+=1);for(var Mr=Le,Ti=0;Ti<Pi.length-1;Ti+=1)Mr=Mr[Pi[Ti]][je.children];return[tr,Wn,Mr,ki]},[Ke,je,Le]),In=he(Jn,4),Mn=In[0],Kn=In[1],ni=In[2],yi=In[3],$i=function(Ji){ct(Ji)},Ai=function(Ji){var Pi=ni.length,tr=Kn;tr===-1&&Ji<0&&(tr=Pi);for(var ar=0;ar<Pi;ar+=1){tr=(tr+Ji+Pi)%Pi;var ki=ni[tr];if(ki&&!ki.disabled){var Fr=Mn.slice(0,-1).concat(yi[tr]?Kl(yi[tr]):ki[je.value]);$i(Fr);return}}},bi=function(){if(Mn.length>1){var Ji=Mn.slice(0,-1);$i(Ji)}else nn(!1)},dr=function(){var Ji,Pi=((Ji=ni[Kn])===null||Ji===void 0?void 0:Ji[je.children])||[],tr=Pi.find(function(ki){return!ki.disabled});if(tr){var ar=[].concat(sn(Mn),[tr[je.value]]);$i(ar)}};ke.useImperativeHandle(Se,function(){return{onKeyDown:function(Ji){var Pi=Ji.which;switch(Pi){case Wl.UP:case Wl.DOWN:{var tr=0;Pi===Wl.UP?tr=-1:Pi===Wl.DOWN&&(tr=1),tr!==0&&Ai(tr);break}case Wl.LEFT:{if(qt)break;yn?dr():bi();break}case Wl.RIGHT:{if(qt)break;yn?bi():dr();break}case Wl.BACKSPACE:{qt||bi();break}case Wl.ENTER:{if(Mn.length){var ar=ni[Kn],ki=(ar==null?void 0:ar[Ss])||[];ki.length?Et(ki.map(function(Fr){return Fr[je.value]}),ki[ki.length-1]):Et(Mn,ni[Kn])}break}case Wl.ESC:nn(!1),Sn&&Ji.stopPropagation()}},onKeyUp:function(){}}})},ht=ke.forwardRef(function(Se,Le){var je,Ke,ct,Et=Se.prefixCls,Bt=Se.multiple,hn=Se.searchValue,qt=Se.toggleOpen,nn=Se.notFoundContent,Sn=Se.direction,yn=Se.open,Jn=Se.disabled,In=ke.useRef(null),Mn=Sn==="rtl",Kn=ke.useContext(al),ni=Kn.options,yi=Kn.values,$i=Kn.halfValues,Ai=Kn.fieldNames,bi=Kn.changeOnSelect,dr=Kn.onSelect,Wn=Kn.searchOptions,Ji=Kn.dropdownPrefixCls,Pi=Kn.loadData,tr=Kn.expandTrigger,ar=Ji||Et,ki=ke.useState([]),Fr=he(ki,2),hr=Fr[0],Mr=Fr[1],Ti=function(Fi){if(!(!Pi||hn)){var zi=Pl(Fi,ni,Ai),Sr=zi.map(function(Ir){var wa=Ir.option;return wa}),io=Sr[Sr.length-1];if(io&&!Tu(io,Ai)){var Xr=Kl(Fi);Mr(function(Ir){return[].concat(sn(Ir),[Xr])}),Pi(Sr)}}};ke.useEffect(function(){hr.length&&hr.forEach(function(rr){var Fi=$u(rr),zi=Pl(Fi,ni,Ai,!0).map(function(io){var Xr=io.option;return Xr}),Sr=zi[zi.length-1];(!Sr||Sr[Ai.children]||Tu(Sr,Ai))&&Mr(function(io){return io.filter(function(Xr){return Xr!==rr})})})},[ni,hr,Ai]);var pr=ke.useMemo(function(){return new Set(ch(yi))},[yi]),qr=ke.useMemo(function(){return new Set(ch($i))},[$i]),Po=Fh(Bt,yn),no=he(Po,2),Qi=no[0],zr=no[1],$r=function(Fi){zr(Fi),Ti(Fi)},lo=function(Fi){if(Jn)return!1;var zi=Fi.disabled,Sr=Tu(Fi,Ai);return!zi&&(Sr||bi||Bt)},Uo=function(Fi,zi){var Sr=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;dr(Fi),!Bt&&(zi||bi&&(tr==="hover"||Sr))&&qt(!1)},So=ke.useMemo(function(){return hn?Wn:ni},[hn,Wn,ni]),Ar=ke.useMemo(function(){for(var rr=[{options:So}],Fi=So,zi=Du(Fi,Ai),Sr=function(){var Ir=Qi[io],wa=Fi.find(function(Xo,pa){return(zi[pa]?Kl(zi[pa]):Xo[Ai.value])===Ir}),ra=wa==null?void 0:wa[Ai.children];if(!(ra!=null&&ra.length))return 1;Fi=ra,rr.push({options:ra})},io=0;io<Qi.length&&!Sr();io+=1);return rr},[So,Qi,Ai]),ur=function(Fi,zi){lo(zi)&&Uo(Fi,Tu(zi,Ai),!0)};Ue(Le,So,Ai,Qi,$r,ur,{direction:Sn,searchValue:hn,toggleOpen:qt,open:yn}),ke.useEffect(function(){if(!hn)for(var rr=0;rr<Qi.length;rr+=1){var Fi,zi=Qi.slice(0,rr+1),Sr=Kl(zi),io=(Fi=In.current)===null||Fi===void 0?void 0:Fi.querySelector('li[data-path-key="'.concat(Sr.replace(/\\{0,2}"/g,'\\"'),'"]'));io&&Wh(io)}},[Qi,hn]);var Vr=!((je=Ar[0])!==null&&je!==void 0&&(je=je.options)!==null&&je!==void 0&&je.length),Do=[(Ke={},kt(Ke,Ai.value,"__EMPTY__"),kt(Ke,Ic,nn),kt(Ke,"disabled",!0),Ke)],Nr=$e($e({},Se),{},{multiple:!Vr&&Bt,onSelect:Uo,onActive:$r,onToggleOpen:qt,checkedSet:pr,halfCheckedSet:qr,loadingKeys:hr,isSelectable:lo}),Wi=Vr?[{options:Do}]:Ar,ir=Wi.map(function(rr,Fi){var zi=Qi.slice(0,Fi),Sr=Qi[Fi];return ke.createElement(fc,Ne({key:Fi},Nr,{prefixCls:ar,options:rr.options,prevValuePath:zi,activeValue:Sr}))});return ke.createElement(Mh,{open:yn},ke.createElement("div",{className:qe()("".concat(ar,"-menus"),(ct={},kt(ct,"".concat(ar,"-menu-empty"),Vr),kt(ct,"".concat(ar,"-rtl"),Mn),ct)),ref:In},ir))}),pt=ht,xt=ke.forwardRef(function(Se,Le){var je=fr();return ke.createElement(pt,Ne({},Se,je,{ref:Le}))}),Ht=xt,en=De(80705);function un(Se,Le,je){var Ke=React.useRef({});return(!("value"in Ke.current)||je(Ke.current.condition,Le))&&(Ke.current.value=Se(),Ke.current.condition=Le),Ke.current.value}var En=Symbol.for("react.element"),Yn=Symbol.for("react.transitional.element"),Gn=Symbol.for("react.fragment");function Si(Se){return Se&&_typeof(Se)==="object"&&(Se.$$typeof===En||Se.$$typeof===Yn)&&Se.type===Gn}var Un=Number(ke.version.split(".")[0]),gi=function(Le,je){typeof Le=="function"?Le(je):_typeof(Le)==="object"&&Le&&"current"in Le&&(Le.current=je)},ii=function(){for(var Le=arguments.length,je=new Array(Le),Ke=0;Ke<Le;Ke++)je[Ke]=arguments[Ke];var ct=je.filter(Boolean);return ct.length<=1?ct[0]:function(Et){je.forEach(function(Bt){gi(Bt,Et)})}},Oi=function(){for(var Le=arguments.length,je=new Array(Le),Ke=0;Ke<Le;Ke++)je[Ke]=arguments[Ke];return useMemo(function(){return ii.apply(void 0,je)},je,function(ct,Et){return ct.length!==Et.length||ct.every(function(Bt,hn){return Bt!==Et[hn]})})},lr=function(Le){var je,Ke;if(!Le)return!1;if(br(Le)&&Un>=19)return!0;var ct=isMemo(Le)?Le.type.type:Le.type;return!(typeof ct=="function"&&!((je=ct.prototype)!==null&&je!==void 0&&je.render)&&ct.$$typeof!==ForwardRef||typeof Le=="function"&&!((Ke=Le.prototype)!==null&&Ke!==void 0&&Ke.render)&&Le.$$typeof!==ForwardRef)};function br(Se){return isValidElement(Se)&&!isFragment(Se)}var Zr=function(Le){return br(Le)&&lr(Le)},Gi=function(Le){if(Le&&br(Le)){var je=Le;return je.props.propertyIsEnumerable("ref")?je.props.ref:je.ref}return null};function mr(Se,Le,je,Ke){if(!Le.length)return je;var ct=_toArray(Le),Et=ct[0],Bt=ct.slice(1),hn;return!Se&&typeof Et=="number"?hn=[]:Array.isArray(Se)?hn=_toConsumableArray(Se):hn=_objectSpread({},Se),Ke&&je===void 0&&Bt.length===1?delete hn[Et][Bt[0]]:hn[Et]=mr(hn[Et],Bt,je,Ke),hn}function er(Se,Le,je){var Ke=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;return Le.length&&Ke&&je===void 0&&!get(Se,Le.slice(0,-1))?Se:mr(Se,Le,je,Ke)}function Yr(Se){return _typeof(Se)==="object"&&Se!==null&&Object.getPrototypeOf(Se)===Object.prototype}function No(Se){return Array.isArray(Se)?[]:{}}var Wr=typeof Reflect=="undefined"?Object.keys:Reflect.ownKeys;function da(){for(var Se=arguments.length,Le=new Array(Se),je=0;je<Se;je++)Le[je]=arguments[je];var Ke=No(Le[0]);return Le.forEach(function(ct){function Et(Bt,hn){var qt=new Set(hn),nn=get(ct,Bt),Sn=Array.isArray(nn);if(Sn||Yr(nn)){if(!qt.has(nn)){qt.add(nn);var yn=get(Ke,Bt);Sn?Ke=er(Ke,Bt,[]):(!yn||_typeof(yn)!=="object")&&(Ke=er(Ke,Bt,No(nn))),Wr(nn).forEach(function(Jn){Et([].concat(_toConsumableArray(Bt),[Jn]),qt)})}}else Ke=er(Ke,Bt,nn)}Et([])}),Ke}function To(){}function la(Se){var Le,je=Se,Ke=je.prefixCls,ct=Ke===void 0?"rc-cascader":Ke,Et=je.style,Bt=je.className,hn=je.options,qt=je.checkable,nn=je.defaultValue,Sn=je.value,yn=je.fieldNames,Jn=je.changeOnSelect,In=je.onChange,Mn=je.showCheckedStrategy,Kn=je.loadData,ni=je.expandTrigger,yi=je.expandIcon,$i=yi===void 0?">":yi,Ai=je.loadingIcon,bi=je.direction,dr=je.notFoundContent,Wn=dr===void 0?"Not Found":dr,Ji=je.disabled,Pi=!!qt,tr=Us(nn,{value:Sn,postState:to}),ar=he(tr,2),ki=ar[0],Fr=ar[1],hr=ke.useMemo(function(){return Nu(yn)},[JSON.stringify(yn)]),Mr=qo(hr,hn),Ti=he(Mr,3),pr=Ti[0],qr=Ti[1],Po=Ti[2],no=fi(pr,hr),Qi=sa(Pi,ki,qr,Po,no),zr=he(Qi,3),$r=zr[0],lo=zr[1],Uo=zr[2],So=Gl(function(Wi){if(Fr(Wi),In){var ir=to(Wi),rr=ir.map(function(Sr){return Pl(Sr,pr,hr).map(function(io){return io.option})}),Fi=Pi?ir:ir[0],zi=Pi?rr:rr[0];In(Fi,zi)}}),Ar=ou(Pi,So,$r,lo,Uo,qr,Po,Mn),ur=Gl(function(Wi){Ar(Wi)}),Vr=ke.useMemo(function(){return{options:pr,fieldNames:hr,values:$r,halfValues:lo,changeOnSelect:Jn,onSelect:ur,checkable:qt,searchOptions:[],dropdownPrefixCls:void 0,loadData:Kn,expandTrigger:ni,expandIcon:$i,loadingIcon:Ai,dropdownMenuColumnStyle:void 0}},[pr,hr,$r,lo,Jn,ur,qt,Kn,ni,$i,Ai]),Do="".concat(ct,"-panel"),Nr=!pr.length;return ke.createElement(al.Provider,{value:Vr},ke.createElement("div",{className:qe()(Do,(Le={},kt(Le,"".concat(Do,"-rtl"),bi==="rtl"),kt(Le,"".concat(Do,"-empty"),Nr),Le),Bt),style:Et},Nr?Wn:ke.createElement(pt,{prefixCls:ct,searchValue:"",multiple:Pi,toggleOpen:To,open:!0,direction:bi,disabled:Ji})))}function ys(Se){var Le=Se.onPopupVisibleChange,je=Se.popupVisible,Ke=Se.popupClassName,ct=Se.popupPlacement;warning(!Le,"`onPopupVisibleChange` is deprecated. Please use `onDropdownVisibleChange` instead."),warning(je===void 0,"`popupVisible` is deprecated. Please use `open` instead."),warning(Ke===void 0,"`popupClassName` is deprecated. Please use `dropdownClassName` instead."),warning(ct===void 0,"`popupPlacement` is deprecated. Please use `placement` instead.")}function Da(Se,Le){if(Se){var je=function Ke(ct){for(var Et=0;Et<ct.length;Et++){var Bt=ct[Et];if(Bt[Le==null?void 0:Le.value]===null)return warning(!1,"`value` in Cascader options should not be `null`."),!0;if(Array.isArray(Bt[Le==null?void 0:Le.children])&&Ke(Bt[Le==null?void 0:Le.children]))return!0}};je(Se)}}var Te=null,Oe=["id","prefixCls","fieldNames","defaultValue","value","changeOnSelect","onChange","displayRender","checkable","autoClearSearchValue","searchValue","onSearch","showSearch","expandTrigger","options","dropdownPrefixCls","loadData","popupVisible","open","popupClassName","dropdownClassName","dropdownMenuColumnStyle","dropdownStyle","popupPlacement","placement","onDropdownVisibleChange","onPopupVisibleChange","expandIcon","loadingIcon","children","dropdownMatchSelectWidth","showCheckedStrategy","optionRender"],Xe=ke.forwardRef(function(Se,Le){var je=Se.id,Ke=Se.prefixCls,ct=Ke===void 0?"rc-cascader":Ke,Et=Se.fieldNames,Bt=Se.defaultValue,hn=Se.value,qt=Se.changeOnSelect,nn=Se.onChange,Sn=Se.displayRender,yn=Se.checkable,Jn=Se.autoClearSearchValue,In=Jn===void 0?!0:Jn,Mn=Se.searchValue,Kn=Se.onSearch,ni=Se.showSearch,yi=Se.expandTrigger,$i=Se.options,Ai=Se.dropdownPrefixCls,bi=Se.loadData,dr=Se.popupVisible,Wn=Se.open,Ji=Se.popupClassName,Pi=Se.dropdownClassName,tr=Se.dropdownMenuColumnStyle,ar=Se.dropdownStyle,ki=Se.popupPlacement,Fr=Se.placement,hr=Se.onDropdownVisibleChange,Mr=Se.onPopupVisibleChange,Ti=Se.expandIcon,pr=Ti===void 0?">":Ti,qr=Se.loadingIcon,Po=Se.children,no=Se.dropdownMatchSelectWidth,Qi=no===void 0?!1:no,zr=Se.showCheckedStrategy,$r=zr===void 0?yt:zr,lo=Se.optionRender,Uo=pe(Se,Oe),So=Ms(je),Ar=!!yn,ur=Us(Bt,{value:hn,postState:to}),Vr=he(ur,2),Do=Vr[0],Nr=Vr[1],Wi=ke.useMemo(function(){return Nu(Et)},[JSON.stringify(Et)]),ir=qo(Wi,$i),rr=he(ir,3),Fi=rr[0],zi=rr[1],Sr=rr[2],io=Us("",{value:Mn,postState:function(Hi){return Hi||""}}),Xr=he(io,2),Ir=Xr[0],wa=Xr[1],ra=function(Hi,Tr){wa(Hi),Tr.source!=="blur"&&Kn&&Kn(Hi)},Xo=vu(ni),pa=he(Xo,2),ro=pa[0],Jo=pa[1],va=kr(Ir,Fi,Wi,Ai||ct,Jo,qt||Ar),ds=fi(Fi,Wi),Pa=sa(Ar,Do,zi,Sr,ds),Ba=he(Pa,3),Bo=Ba[0],Za=Ba[1],Fa=Ba[2],ns=ke.useMemo(function(){var us=ch(Bo),Hi=Bl(us,zi,$r);return[].concat(sn(Fa),sn(Sr(Hi)))},[Bo,zi,Sr,Fa,$r]),Vi=xs(ns,Fi,Wi,Ar,Sn),Ki=Gl(function(us){if(Nr(us),nn){var Hi=to(us),Tr=Hi.map(function(Ca){return Pl(Ca,Fi,Wi).map(function(Rr){return Rr.option})}),nr=Ar?Hi:Hi[0],ho=Ar?Tr:Tr[0];nn(nr,ho)}}),or=ou(Ar,Ki,Bo,Za,Fa,zi,Sr,$r),Jr=Gl(function(us){(!Ar||In)&&wa(""),or(us)}),ta=function(Hi,Tr){if(Tr.type==="clear"){Ki([]);return}var nr=Tr.values[0],ho=nr.valueCells;Jr(ho)},Ha=Wn!==void 0?Wn:dr,ls=Pi||Ji,bt=Fr||ki,xo=function(Hi){hr==null||hr(Hi),Mr==null||Mr(Hi)},zo=ke.useMemo(function(){return{options:Fi,fieldNames:Wi,values:Bo,halfValues:Za,changeOnSelect:qt,onSelect:Jr,checkable:yn,searchOptions:va,dropdownPrefixCls:Ai,loadData:bi,expandTrigger:yi,expandIcon:pr,loadingIcon:qr,dropdownMenuColumnStyle:tr,optionRender:lo}},[Fi,Wi,Bo,Za,qt,Jr,yn,va,Ai,bi,yi,pr,qr,tr,lo]),na=!(Ir?va:Fi).length,js=Ir&&Jo.matchInputWidth||na?{}:{minWidth:"auto"};return ke.createElement(al.Provider,{value:zo},ke.createElement(zl,Ne({},Uo,{ref:Le,id:So,prefixCls:ct,autoClearSearchValue:In,dropdownMatchSelectWidth:Qi,dropdownStyle:$e($e({},js),ar),displayValues:Vi,onDisplayValuesChange:ta,mode:Ar?"multiple":void 0,searchValue:Ir,onSearch:ra,showSearch:ro,OptionList:Ht,emptyOptions:na,open:Ha,dropdownClassName:ls,placement:bt,onDropdownVisibleChange:xo,getRawInputElement:function(){return Po}})))});Xe.SHOW_PARENT=yt,Xe.SHOW_CHILD=Bn,Xe.Panel=la;var ot=Xe,Rt=ot},42767:function(jn,li){"use strict";var De;var Ne=typeof Symbol=="function"&&Symbol.for,dt=Ne?Symbol.for("react.element"):60103,Ut=Ne?Symbol.for("react.portal"):60106,$t=Ne?Symbol.for("react.fragment"):60107,kt=Ne?Symbol.for("react.strict_mode"):60108,Ie=Ne?Symbol.for("react.profiler"):60114,$e=Ne?Symbol.for("react.provider"):60109,Mt=Ne?Symbol.for("react.context"):60110,Pt=Ne?Symbol.for("react.async_mode"):60111,wt=Ne?Symbol.for("react.concurrent_mode"):60111,Qt=Ne?Symbol.for("react.forward_ref"):60112,It=Ne?Symbol.for("react.suspense"):60113,sn=Ne?Symbol.for("react.suspense_list"):60120,Re=Ne?Symbol.for("react.memo"):60115,ne=Ne?Symbol.for("react.lazy"):60116,te=Ne?Symbol.for("react.block"):60121,he=Ne?Symbol.for("react.fundamental"):60117,le=Ne?Symbol.for("react.responder"):60118,pe=Ne?Symbol.for("react.scope"):60119;function me(Ee){if(typeof Ee=="object"&&Ee!==null){var Ge=Ee.$$typeof;switch(Ge){case dt:switch(Ee=Ee.type,Ee){case Pt:case wt:case $t:case Ie:case kt:case It:return Ee;default:switch(Ee=Ee&&Ee.$$typeof,Ee){case Mt:case Qt:case ne:case Re:case $e:return Ee;default:return Ge}}case Ut:return Ge}}}function xe(Ee){return me(Ee)===wt}De=Pt,De=wt,De=Mt,De=$e,De=dt,De=Qt,De=$t,De=ne,De=Re,De=Ut,De=Ie,De=kt,De=It,De=function(Ee){return xe(Ee)||me(Ee)===Pt},De=xe,De=function(Ee){return me(Ee)===Mt},De=function(Ee){return me(Ee)===$e},De=function(Ee){return typeof Ee=="object"&&Ee!==null&&Ee.$$typeof===dt},De=function(Ee){return me(Ee)===Qt},li.isFragment=function(Ee){return me(Ee)===$t},De=function(Ee){return me(Ee)===ne},De=function(Ee){return me(Ee)===Re},De=function(Ee){return me(Ee)===Ut},De=function(Ee){return me(Ee)===Ie},De=function(Ee){return me(Ee)===kt},De=function(Ee){return me(Ee)===It},De=function(Ee){return typeof Ee=="string"||typeof Ee=="function"||Ee===$t||Ee===wt||Ee===Ie||Ee===kt||Ee===It||Ee===sn||typeof Ee=="object"&&Ee!==null&&(Ee.$$typeof===ne||Ee.$$typeof===Re||Ee.$$typeof===$e||Ee.$$typeof===Mt||Ee.$$typeof===Qt||Ee.$$typeof===he||Ee.$$typeof===le||Ee.$$typeof===pe||Ee.$$typeof===te)},De=me},16357:function(jn,li,De){"use strict";jn.exports=De(42767)},16404:function(jn,li){"use strict";var De;var Ne=Symbol.for("react.element"),dt=Symbol.for("react.portal"),Ut=Symbol.for("react.fragment"),$t=Symbol.for("react.strict_mode"),kt=Symbol.for("react.profiler"),Ie=Symbol.for("react.provider"),$e=Symbol.for("react.context"),Mt=Symbol.for("react.server_context"),Pt=Symbol.for("react.forward_ref"),wt=Symbol.for("react.suspense"),Qt=Symbol.for("react.suspense_list"),It=Symbol.for("react.memo"),sn=Symbol.for("react.lazy"),Re=Symbol.for("react.offscreen"),ne;ne=Symbol.for("react.module.reference");function te(he){if(typeof he=="object"&&he!==null){var le=he.$$typeof;switch(le){case Ne:switch(he=he.type,he){case Ut:case kt:case $t:case wt:case Qt:return he;default:switch(he=he&&he.$$typeof,he){case Mt:case $e:case Pt:case sn:case It:case Ie:return he;default:return le}}case dt:return le}}}De=$e,De=Ie,De=Ne,De=Pt,De=Ut,De=sn,De=It,De=dt,De=kt,De=$t,De=wt,De=Qt,De=function(){return!1},De=function(){return!1},De=function(he){return te(he)===$e},De=function(he){return te(he)===Ie},De=function(he){return typeof he=="object"&&he!==null&&he.$$typeof===Ne},De=function(he){return te(he)===Pt},De=function(he){return te(he)===Ut},De=function(he){return te(he)===sn},De=function(he){return te(he)===It},De=function(he){return te(he)===dt},De=function(he){return te(he)===kt},De=function(he){return te(he)===$t},De=function(he){return te(he)===wt},De=function(he){return te(he)===Qt},De=function(he){return typeof he=="string"||typeof he=="function"||he===Ut||he===kt||he===$t||he===wt||he===Qt||he===Re||typeof he=="object"&&he!==null&&(he.$$typeof===sn||he.$$typeof===It||he.$$typeof===Ie||he.$$typeof===$e||he.$$typeof===Pt||he.$$typeof===ne||he.getModuleId!==void 0)},De=te},80705:function(jn,li,De){"use strict";De(16404)},31457:function(jn,li,De){"use strict";De.d(li,{Z:function(){return Gt}});var Ne=De(4942),dt=De(87462),Ut=De(71002),$t=De(1413),kt=De(97685),Ie=De(94184),$e=De.n(Ie),Mt=De(67294);function Pt(an){var Jt=Mt.useRef();Jt.current=an;var Ve=Mt.useCallback(function(){for(var be,Pe=arguments.length,Be=new Array(Pe),Ze=0;Ze<Pe;Ze++)Be[Ze]=arguments[Ze];return(be=Jt.current)===null||be===void 0?void 0:be.call.apply(be,[Jt].concat(Be))},[]);return Ve}function wt(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var Qt=wt()?Mt.useLayoutEffect:Mt.useEffect,It=function(Jt,Ve){var be=Mt.useRef(!0);Qt(function(){return Jt(be.current)},Ve),Qt(function(){return be.current=!1,function(){be.current=!0}},[])},sn=function(Jt,Ve){It(function(be){if(!be)return Jt()},Ve)},Re=null;function ne(an){var Jt=Mt.useRef(!1),Ve=Mt.useState(an),be=(0,kt.Z)(Ve,2),Pe=be[0],Be=be[1];Mt.useEffect(function(){return Jt.current=!1,function(){Jt.current=!0}},[]);function Ze(Fe,qe){qe&&Jt.current||Be(Fe)}return[Pe,Ze]}function te(an){return an!==void 0}function he(an,Jt){var Ve=Jt||{},be=Ve.defaultValue,Pe=Ve.value,Be=Ve.onChange,Ze=Ve.postState,Fe=ne(function(){return te(Pe)?Pe:te(be)?typeof be=="function"?be():be:typeof an=="function"?an():an}),qe=(0,kt.Z)(Fe,2),dn=qe[0],ui=qe[1],$n=Pe!==void 0?Pe:dn,rn=Ze?Ze($n):$n,Hn=Pt(Be),Zt=ne([$n]),_n=(0,kt.Z)(Zt,2),ti=_n[0],Ri=_n[1];sn(function(){var wr=ti[0];dn!==wr&&Hn(dn,wr)},[ti]),sn(function(){te(Pe)||ui(Pe)},[Pe]);var oi=Pt(function(wr,fr){ui(wr,fr),Ri([$n],fr)});return[rn,oi]}var le={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(Jt){var Ve=Jt.keyCode;if(Jt.altKey&&!Jt.ctrlKey||Jt.metaKey||Ve>=le.F1&&Ve<=le.F12)return!1;switch(Ve){case le.ALT:case le.CAPS_LOCK:case le.CONTEXT_MENU:case le.CTRL:case le.DOWN:case le.END:case le.ESC:case le.HOME:case le.INSERT:case le.LEFT:case le.MAC_FF_META:case le.META:case le.NUMLOCK:case le.NUM_CENTER:case le.PAGE_DOWN:case le.PAGE_UP:case le.PAUSE:case le.PRINT_SCREEN:case le.RIGHT:case le.SHIFT:case le.UP:case le.WIN_KEY:case le.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(Jt){if(Jt>=le.ZERO&&Jt<=le.NINE||Jt>=le.NUM_ZERO&&Jt<=le.NUM_MULTIPLY||Jt>=le.A&&Jt<=le.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&Jt===0)return!0;switch(Jt){case le.SPACE:case le.QUESTION_MARK:case le.NUM_PLUS:case le.NUM_MINUS:case le.NUM_PERIOD:case le.NUM_DIVISION:case le.SEMICOLON:case le.DASH:case le.EQUALS:case le.COMMA:case le.PERIOD:case le.SLASH:case le.APOSTROPHE:case le.SINGLE_QUOTE:case le.OPEN_SQUARE_BRACKET:case le.BACKSLASH:case le.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},pe=le,me=`accept acceptCharset accessKey action allowFullScreen allowTransparency
alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge
charSet checked classID className colSpan cols content contentEditable contextMenu
controls coords crossOrigin data dateTime default defer dir disabled download draggable
encType form formAction formEncType formMethod formNoValidate formTarget frameBorder
headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity
is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media
mediaGroup method min minLength multiple muted name noValidate nonce open
optimum pattern placeholder poster preload radioGroup readOnly rel required
reversed role rowSpan rows sandbox scope scoped scrolling seamless selected
shape size sizes span spellCheck src srcDoc srcLang srcSet start step style
summary tabIndex target title type useMap value width wmode wrap`,xe=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown
onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick
onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown
onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel
onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough
onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata
onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,Ee="".concat(me," ").concat(xe).split(/[\s\n]+/),Ge="aria-",et="data-";function ut(an,Jt){return an.indexOf(Jt)===0}function st(an){var Jt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Ve;Jt===!1?Ve={aria:!0,data:!0,attr:!0}:Jt===!0?Ve={aria:!0}:Ve=(0,$t.Z)({},Jt);var be={};return Object.keys(an).forEach(function(Pe){(Ve.aria&&(Pe==="role"||ut(Pe,Ge))||Ve.data&&ut(Pe,et)||Ve.attr&&Ee.includes(Pe))&&(be[Pe]=an[Pe])}),be}var it={},Nt=[],St=function(Jt){Nt.push(Jt)};function Ft(an,Jt){if(0)var Ve}function cn(an,Jt){if(0)var Ve}function Tt(){it={}}function hi(an,Jt,Ve){!Jt&&!it[Ve]&&(an(!1,Ve),it[Ve]=!0)}function di(an,Jt){hi(Ft,an,Jt)}function zn(an,Jt){hi(cn,an,Jt)}di.preMessage=St,di.resetWarned=Tt,di.noteOnce=zn;var Dn=null,nt=De(81626),ze=[10,20,50,100],ke=function(Jt){var Ve=Jt.pageSizeOptions,be=Ve===void 0?ze:Ve,Pe=Jt.locale,Be=Jt.changeSize,Ze=Jt.pageSize,Fe=Jt.goButton,qe=Jt.quickGo,dn=Jt.rootPrefixCls,ui=Jt.disabled,$n=Jt.buildOptionText,rn=Jt.showSizeChanger,Hn=Jt.sizeChangerRender,Zt=Mt.useState(""),_n=(0,kt.Z)(Zt,2),ti=_n[0],Ri=_n[1],oi=function(){return!ti||Number.isNaN(ti)?void 0:Number(ti)},wr=typeof $n=="function"?$n:function(Ui){return"".concat(Ui," ").concat(Pe.items_per_page)},fr=function(yo){Ri(yo.target.value)},Ei=function(yo){Fe||ti===""||(Ri(""),!(yo.relatedTarget&&(yo.relatedTarget.className.indexOf("".concat(dn,"-item-link"))>=0||yo.relatedTarget.className.indexOf("".concat(dn,"-item"))>=0))&&(qe==null||qe(oi())))},Di=function(yo){ti!==""&&(yo.keyCode===pe.ENTER||yo.type==="click")&&(Ri(""),qe==null||qe(oi()))},uo=function(){return be.some(function(yo){return yo.toString()===Ze.toString()})?be:be.concat([Ze]).sort(function(yo,ha){var Ka=Number.isNaN(Number(yo))?0:Number(yo),Ra=Number.isNaN(Number(ha))?0:Number(ha);return Ka-Ra})},vt="".concat(dn,"-options");if(!rn&&!qe)return null;var ei=null,co=null,bo=null;return rn&&Hn&&(ei=Hn({disabled:ui,size:Ze,onSizeChange:function(yo){Be==null||Be(Number(yo))},"aria-label":Pe.page_size,className:"".concat(vt,"-size-changer"),options:uo().map(function(Ui){return{label:wr(Ui),value:Ui}})})),qe&&(Fe&&(bo=typeof Fe=="boolean"?Mt.createElement("button",{type:"button",onClick:Di,onKeyUp:Di,disabled:ui,className:"".concat(vt,"-quick-jumper-button")},Pe.jump_to_confirm):Mt.createElement("span",{onClick:Di,onKeyUp:Di},Fe)),co=Mt.createElement("div",{className:"".concat(vt,"-quick-jumper")},Pe.jump_to,Mt.createElement("input",{disabled:ui,type:"text",value:ti,onChange:fr,onKeyUp:Di,onBlur:Ei,"aria-label":Pe.page}),Pe.page,bo)),Mt.createElement("li",{className:vt},ei,co)},Wt=ke,On=function(Jt){var Ve=Jt.rootPrefixCls,be=Jt.page,Pe=Jt.active,Be=Jt.className,Ze=Jt.showTitle,Fe=Jt.onClick,qe=Jt.onKeyPress,dn=Jt.itemRender,ui="".concat(Ve,"-item"),$n=$e()(ui,"".concat(ui,"-").concat(be),(0,Ne.Z)((0,Ne.Z)({},"".concat(ui,"-active"),Pe),"".concat(ui,"-disabled"),!be),Be),rn=function(){Fe(be)},Hn=function(ti){qe(ti,Fe,be)},Zt=dn(be,"page",Mt.createElement("a",{rel:"nofollow"},be));return Zt?Mt.createElement("li",{title:Ze?String(be):null,className:$n,onClick:rn,onKeyDown:Hn,tabIndex:0},Zt):null},Lt=On,xn=function(Jt,Ve,be){return be};function vn(){}function Xn(an){var Jt=Number(an);return typeof Jt=="number"&&!Number.isNaN(Jt)&&isFinite(Jt)&&Math.floor(Jt)===Jt}function Ot(an,Jt,Ve){var be=typeof an=="undefined"?Jt:an;return Math.floor((Ve-1)/be)+1}var ft=function(Jt){var Ve=Jt.prefixCls,be=Ve===void 0?"rc-pagination":Ve,Pe=Jt.selectPrefixCls,Be=Pe===void 0?"rc-select":Pe,Ze=Jt.className,Fe=Jt.current,qe=Jt.defaultCurrent,dn=qe===void 0?1:qe,ui=Jt.total,$n=ui===void 0?0:ui,rn=Jt.pageSize,Hn=Jt.defaultPageSize,Zt=Hn===void 0?10:Hn,_n=Jt.onChange,ti=_n===void 0?vn:_n,Ri=Jt.hideOnSinglePage,oi=Jt.align,wr=Jt.showPrevNextJumpers,fr=wr===void 0?!0:wr,Ei=Jt.showQuickJumper,Di=Jt.showLessItems,uo=Jt.showTitle,vt=uo===void 0?!0:uo,ei=Jt.onShowSizeChange,co=ei===void 0?vn:ei,bo=Jt.locale,Ui=bo===void 0?nt.Z:bo,yo=Jt.style,ha=Jt.totalBoundaryShowSizeChanger,Ka=ha===void 0?50:ha,Ra=Jt.disabled,ca=Jt.simple,ma=Jt.showTotal,Ho=Jt.showSizeChanger,_r=Ho===void 0?$n>Ka:Ho,Fn=Jt.sizeChangerRender,we=Jt.pageSizeOptions,Qn=Jt.itemRender,bn=Qn===void 0?xn:Qn,on=Jt.jumpPrevIcon,ln=Jt.jumpNextIcon,gn=Jt.prevIcon,Vn=Jt.nextIcon,_i=Mt.useRef(null),jt=he(10,{value:rn,defaultValue:Zt}),zt=(0,kt.Z)(jt,2),Ct=zt[0],Yt=zt[1],ci=he(1,{value:Fe,defaultValue:dn,postState:function(jr){return Math.max(1,Math.min(jr,Ot(void 0,Ct,$n)))}}),vi=(0,kt.Z)(ci,2),ai=vi[0],Kt=vi[1],wn=Mt.useState(ai),pi=(0,kt.Z)(wn,2),ji=pi[0],Rn=pi[1];(0,Mt.useEffect)(function(){Rn(ai)},[ai]);var Dt=ti!==vn,wi="current"in Jt,gr=Math.max(1,ai-(Di?3:5)),eo=Math.min(Ot(void 0,Ct,$n),ai+(Di?3:5));function kn(fn,jr){var Ao=fn||Mt.createElement("button",{type:"button","aria-label":jr,className:"".concat(be,"-item-link")});return typeof fn=="function"&&(Ao=Mt.createElement(fn,(0,$t.Z)({},Jt))),Ao}function Xi(fn){var jr=fn.target.value,Ao=Ot(void 0,Ct,$n),$a;return jr===""?$a=jr:Number.isNaN(Number(jr))?$a=ji:jr>=Ao?$a=Ao:$a=Number(jr),$a}function Lo(fn){return Xn(fn)&&fn!==ai&&Xn($n)&&$n>0}var La=$n>Ct?Ei:!1;function $o(fn){(fn.keyCode===pe.UP||fn.keyCode===pe.DOWN)&&fn.preventDefault()}function qi(fn){var jr=Xi(fn);switch(jr!==ji&&Rn(jr),fn.keyCode){case pe.ENTER:Co(jr);break;case pe.UP:Co(jr-1);break;case pe.DOWN:Co(jr+1);break;default:break}}function Zi(fn){Co(Xi(fn))}function cr(fn){var jr=Ot(fn,Ct,$n),Ao=ai>jr&&jr!==0?jr:ai;Yt(fn),Rn(Ao),co==null||co(ai,fn),Kt(Ao),ti==null||ti(Ao,fn)}function Co(fn){if(Lo(fn)&&!Ra){var jr=Ot(void 0,Ct,$n),Ao=fn;return fn>jr?Ao=jr:fn<1&&(Ao=1),Ao!==ji&&Rn(Ao),Kt(Ao),ti==null||ti(Ao,Ct),Ao}return ai}var Zo=ai>1,ri=ai<Ot(void 0,Ct,$n);function Lr(){Zo&&Co(ai-1)}function ml(){ri&&Co(ai+1)}function Fs(){Co(gr)}function gs(){Co(eo)}function Vt(fn,jr){if(fn.key==="Enter"||fn.charCode===pe.ENTER||fn.keyCode===pe.ENTER){for(var Ao=arguments.length,$a=new Array(Ao>2?Ao-2:0),Ia=2;Ia<Ao;Ia++)$a[Ia-2]=arguments[Ia];jr.apply(void 0,$a)}}function Kr(fn){Vt(fn,Lr)}function Ko(fn){Vt(fn,ml)}function Er(fn){Vt(fn,Fs)}function Wa(fn){Vt(fn,gs)}function Wo(fn){var jr=bn(fn,"prev",kn(gn,"prev page"));return Mt.isValidElement(jr)?Mt.cloneElement(jr,{disabled:!Zo}):jr}function ea(fn){var jr=bn(fn,"next",kn(Vn,"next page"));return Mt.isValidElement(jr)?Mt.cloneElement(jr,{disabled:!ri}):jr}function fo(fn){(fn.type==="click"||fn.keyCode===pe.ENTER)&&Co(ji)}var Oo=null,xa=st(Jt,{aria:!0,data:!0}),An=ma&&Mt.createElement("li",{className:"".concat(be,"-total-text")},ma($n,[$n===0?0:(ai-1)*Ct+1,ai*Ct>$n?$n:ai*Ct])),Ya=null,Pn=Ot(void 0,Ct,$n);if(Ri&&$n<=Ct)return null;var jo=[],Ws={rootPrefixCls:be,onClick:Co,onKeyPress:Vt,showTitle:vt,itemRender:bn,page:-1},qa=ai-1>0?ai-1:0,bl=ai+1<Pn?ai+1:Pn,Xa=Ei&&Ei.goButton,_o=(0,Ut.Z)(ca)==="object"?ca.readOnly:!ca,Va=Xa,il=null;ca&&(Xa&&(typeof Xa=="boolean"?Va=Mt.createElement("button",{type:"button",onClick:fo,onKeyUp:fo},Ui.jump_to_confirm):Va=Mt.createElement("span",{onClick:fo,onKeyUp:fo},Xa),Va=Mt.createElement("li",{title:vt?"".concat(Ui.jump_to).concat(ai,"/").concat(Pn):null,className:"".concat(be,"-simple-pager")},Va)),il=Mt.createElement("li",{title:vt?"".concat(ai,"/").concat(Pn):null,className:"".concat(be,"-simple-pager")},_o?ji:Mt.createElement("input",{type:"text","aria-label":Ui.jump_to,value:ji,disabled:Ra,onKeyDown:$o,onKeyUp:qi,onChange:qi,onBlur:Zi,size:3}),Mt.createElement("span",{className:"".concat(be,"-slash")},"/"),Pn));var Na=Di?1:2;if(Pn<=3+Na*2){Pn||jo.push(Mt.createElement(Lt,(0,dt.Z)({},Ws,{key:"noPager",page:1,className:"".concat(be,"-item-disabled")})));for(var Li=1;Li<=Pn;Li+=1)jo.push(Mt.createElement(Lt,(0,dt.Z)({},Ws,{key:Li,page:Li,active:ai===Li})))}else{var Qe=Di?Ui.prev_3:Ui.prev_5,bs=Di?Ui.next_3:Ui.next_5,Ul=bn(gr,"jump-prev",kn(on,"prev page")),Zl=bn(eo,"jump-next",kn(ln,"next page"));fr&&(Oo=Ul?Mt.createElement("li",{title:vt?Qe:null,key:"prev",onClick:Fs,tabIndex:0,onKeyDown:Er,className:$e()("".concat(be,"-jump-prev"),(0,Ne.Z)({},"".concat(be,"-jump-prev-custom-icon"),!!on))},Ul):null,Ya=Zl?Mt.createElement("li",{title:vt?bs:null,key:"next",onClick:gs,tabIndex:0,onKeyDown:Wa,className:$e()("".concat(be,"-jump-next"),(0,Ne.Z)({},"".concat(be,"-jump-next-custom-icon"),!!ln))},Zl):null);var rl=Math.max(1,ai-Na),tu=Math.min(ai+Na,Pn);ai-1<=Na&&(tu=1+Na*2),Pn-ai<=Na&&(rl=Pn-Na*2);for(var Il=rl;Il<=tu;Il+=1)jo.push(Mt.createElement(Lt,(0,dt.Z)({},Ws,{key:Il,page:Il,active:ai===Il})));if(ai-1>=Na*2&&ai!==3&&(jo[0]=Mt.cloneElement(jo[0],{className:$e()("".concat(be,"-item-after-jump-prev"),jo[0].props.className)}),jo.unshift(Oo)),Pn-ai>=Na*2&&ai!==Pn-2){var Hu=jo[jo.length-1];jo[jo.length-1]=Mt.cloneElement(Hu,{className:$e()("".concat(be,"-item-before-jump-next"),Hu.props.className)}),jo.push(Ya)}rl!==1&&jo.unshift(Mt.createElement(Lt,(0,dt.Z)({},Ws,{key:1,page:1}))),tu!==Pn&&jo.push(Mt.createElement(Lt,(0,dt.Z)({},Ws,{key:Pn,page:Pn})))}var nu=Wo(qa);if(nu){var Ua=!Zo||!Pn;nu=Mt.createElement("li",{title:vt?Ui.prev_page:null,onClick:Lr,tabIndex:Ua?null:0,onKeyDown:Kr,className:$e()("".concat(be,"-prev"),(0,Ne.Z)({},"".concat(be,"-disabled"),Ua)),"aria-disabled":Ua},nu)}var ps=ea(bl);if(ps){var Or,Pr;ca?(Or=!ri,Pr=Zo?0:null):(Or=!ri||!Pn,Pr=Or?null:0),ps=Mt.createElement("li",{title:vt?Ui.next_page:null,onClick:ml,tabIndex:Pr,onKeyDown:Ko,className:$e()("".concat(be,"-next"),(0,Ne.Z)({},"".concat(be,"-disabled"),Or)),"aria-disabled":Or},ps)}var so=$e()(be,Ze,(0,Ne.Z)((0,Ne.Z)((0,Ne.Z)((0,Ne.Z)((0,Ne.Z)({},"".concat(be,"-start"),oi==="start"),"".concat(be,"-center"),oi==="center"),"".concat(be,"-end"),oi==="end"),"".concat(be,"-simple"),ca),"".concat(be,"-disabled"),Ra));return Mt.createElement("ul",(0,dt.Z)({className:so,style:yo,ref:_i},xa),An,nu,ca?il:jo,ps,Mt.createElement(Wt,{locale:Ui,rootPrefixCls:be,disabled:Ra,selectPrefixCls:Be,changeSize:cr,pageSize:Ct,pageSizeOptions:we,quickGo:La?Co:null,goButton:Va,showSizeChanger:_r,sizeChangerRender:Fn}))},Gt=ft},43579:function(jn,li,De){"use strict";De.d(li,{Cd:function(){return Nt}});var Ne=De(87462),dt=De(1413),Ut=De(45987),$t=De(67294),kt=De(94184),Ie=De.n(kt),$e={percent:0,prefixCls:"rc-progress",strokeColor:"#2db7f5",strokeLinecap:"round",strokeWidth:1,trailColor:"#D9D9D9",trailWidth:1,gapPosition:"bottom"},Mt=function(){var cn=(0,$t.useRef)([]),Tt=(0,$t.useRef)(null);return(0,$t.useEffect)(function(){var hi=Date.now(),di=!1;cn.current.forEach(function(zn){if(zn){di=!0;var Dn=zn.style;Dn.transitionDuration=".3s, .3s, .3s, .06s",Tt.current&&hi-Tt.current<100&&(Dn.transitionDuration="0s, 0s")}}),di&&(Tt.current=Date.now())}),cn.current},Pt=["className","percent","prefixCls","strokeColor","strokeLinecap","strokeWidth","style","trailColor","trailWidth","transition"],wt=function(cn){var Tt=(0,dt.Z)((0,dt.Z)({},$e),cn),hi=Tt.className,di=Tt.percent,zn=Tt.prefixCls,Dn=Tt.strokeColor,nt=Tt.strokeLinecap,ze=Tt.strokeWidth,ke=Tt.style,Wt=Tt.trailColor,On=Tt.trailWidth,Lt=Tt.transition,xn=(0,Ut.Z)(Tt,Pt);delete xn.gapPosition;var vn=Array.isArray(di)?di:[di],Xn=Array.isArray(Dn)?Dn:[Dn],Ot=Mt(),ft=ze/2,Gt=100-ze/2,an="M ".concat(nt==="round"?ft:0,",").concat(ft,`
L `).concat(nt==="round"?Gt:100,",").concat(ft),Jt="0 0 100 ".concat(ze),Ve=0;return $t.createElement("svg",(0,Ne.Z)({className:Ie()("".concat(zn,"-line"),hi),viewBox:Jt,preserveAspectRatio:"none",style:ke},xn),$t.createElement("path",{className:"".concat(zn,"-line-trail"),d:an,strokeLinecap:nt,stroke:Wt,strokeWidth:On||ze,fillOpacity:"0"}),vn.map(function(be,Pe){var Be=1;switch(nt){case"round":Be=1-ze/100;break;case"square":Be=1-ze/2/100;break;default:Be=1;break}var Ze={strokeDasharray:"".concat(be*Be,"px, 100px"),strokeDashoffset:"-".concat(Ve,"px"),transition:Lt||"stroke-dashoffset 0.3s ease 0s, stroke-dasharray .3s ease 0s, stroke 0.3s linear"},Fe=Xn[Pe]||Xn[Xn.length-1];return Ve+=be,$t.createElement("path",{key:Pe,className:"".concat(zn,"-line-path"),d:an,strokeLinecap:nt,stroke:Fe,strokeWidth:ze,fillOpacity:"0",ref:function(dn){Ot[Pe]=dn},style:Ze})}))},Qt=wt,It=De(71002),sn=De(97685),Re=De(98924),ne=0,te=(0,Re.Z)();function he(){var Ft;return te?(Ft=ne,ne+=1):Ft="TEST_OR_SSR",Ft}var le=function(Ft){var cn=$t.useState(),Tt=(0,sn.Z)(cn,2),hi=Tt[0],di=Tt[1];return $t.useEffect(function(){di("rc_progress_".concat(he()))},[]),Ft||hi},pe=function(cn){var Tt=cn.bg,hi=cn.children;return $t.createElement("div",{style:{width:"100%",height:"100%",background:Tt}},hi)};function me(Ft,cn){return Object.keys(Ft).map(function(Tt){var hi=parseFloat(Tt),di="".concat(Math.floor(hi*cn),"%");return"".concat(Ft[Tt]," ").concat(di)})}var xe=$t.forwardRef(function(Ft,cn){var Tt=Ft.prefixCls,hi=Ft.color,di=Ft.gradientId,zn=Ft.radius,Dn=Ft.style,nt=Ft.ptg,ze=Ft.strokeLinecap,ke=Ft.strokeWidth,Wt=Ft.size,On=Ft.gapDegree,Lt=hi&&(0,It.Z)(hi)==="object",xn=Lt?"#FFF":void 0,vn=Wt/2,Xn=$t.createElement("circle",{className:"".concat(Tt,"-circle-path"),r:zn,cx:vn,cy:vn,stroke:xn,strokeLinecap:ze,strokeWidth:ke,opacity:nt===0?0:1,style:Dn,ref:cn});if(!Lt)return Xn;var Ot="".concat(di,"-conic"),ft=On?"".concat(180+On/2,"deg"):"0deg",Gt=me(hi,(360-On)/360),an=me(hi,1),Jt="conic-gradient(from ".concat(ft,", ").concat(Gt.join(", "),")"),Ve="linear-gradient(to ".concat(On?"bottom":"top",", ").concat(an.join(", "),")");return $t.createElement($t.Fragment,null,$t.createElement("mask",{id:Ot},Xn),$t.createElement("foreignObject",{x:0,y:0,width:Wt,height:Wt,mask:"url(#".concat(Ot,")")},$t.createElement(pe,{bg:Ve},$t.createElement(pe,{bg:Jt}))))}),Ee=xe,Ge=100,et=function(cn,Tt,hi,di,zn,Dn,nt,ze,ke,Wt){var On=arguments.length>10&&arguments[10]!==void 0?arguments[10]:0,Lt=hi/100*360*((360-Dn)/360),xn=Dn===0?0:{bottom:0,top:180,left:90,right:-90}[nt],vn=(100-di)/100*Tt;ke==="round"&&di!==100&&(vn+=Wt/2,vn>=Tt&&(vn=Tt-.01));var Xn=Ge/2;return{stroke:typeof ze=="string"?ze:void 0,strokeDasharray:"".concat(Tt,"px ").concat(cn),strokeDashoffset:vn+On,transform:"rotate(".concat(zn+Lt+xn,"deg)"),transformOrigin:"".concat(Xn,"px ").concat(Xn,"px"),transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s, stroke-width .06s ease .3s, opacity .3s ease 0s",fillOpacity:0}},ut=["id","prefixCls","steps","strokeWidth","trailWidth","gapDegree","gapPosition","trailColor","strokeLinecap","style","className","strokeColor","percent"];function st(Ft){var cn=Ft!=null?Ft:[];return Array.isArray(cn)?cn:[cn]}var it=function(cn){var Tt=(0,dt.Z)((0,dt.Z)({},$e),cn),hi=Tt.id,di=Tt.prefixCls,zn=Tt.steps,Dn=Tt.strokeWidth,nt=Tt.trailWidth,ze=Tt.gapDegree,ke=ze===void 0?0:ze,Wt=Tt.gapPosition,On=Tt.trailColor,Lt=Tt.strokeLinecap,xn=Tt.style,vn=Tt.className,Xn=Tt.strokeColor,Ot=Tt.percent,ft=(0,Ut.Z)(Tt,ut),Gt=Ge/2,an=le(hi),Jt="".concat(an,"-gradient"),Ve=Gt-Dn/2,be=Math.PI*2*Ve,Pe=ke>0?90+ke/2:-90,Be=be*((360-ke)/360),Ze=(0,It.Z)(zn)==="object"?zn:{count:zn,gap:2},Fe=Ze.count,qe=Ze.gap,dn=st(Ot),ui=st(Xn),$n=ui.find(function(oi){return oi&&(0,It.Z)(oi)==="object"}),rn=$n&&(0,It.Z)($n)==="object",Hn=rn?"butt":Lt,Zt=et(be,Be,0,100,Pe,ke,Wt,On,Hn,Dn),_n=Mt(),ti=function(){var wr=0;return dn.map(function(fr,Ei){var Di=ui[Ei]||ui[ui.length-1],uo=et(be,Be,wr,fr,Pe,ke,Wt,Di,Hn,Dn);return wr+=fr,$t.createElement(Ee,{key:Ei,color:Di,ptg:fr,radius:Ve,prefixCls:di,gradientId:Jt,style:uo,strokeLinecap:Hn,strokeWidth:Dn,gapDegree:ke,ref:function(ei){_n[Ei]=ei},size:Ge})}).reverse()},Ri=function(){var wr=Math.round(Fe*(dn[0]/100)),fr=100/Fe,Ei=0;return new Array(Fe).fill(null).map(function(Di,uo){var vt=uo<=wr-1?ui[0]:On,ei=vt&&(0,It.Z)(vt)==="object"?"url(#".concat(Jt,")"):void 0,co=et(be,Be,Ei,fr,Pe,ke,Wt,vt,"butt",Dn,qe);return Ei+=(Be-co.strokeDashoffset+qe)*100/Be,$t.createElement("circle",{key:uo,className:"".concat(di,"-circle-path"),r:Ve,cx:Gt,cy:Gt,stroke:ei,strokeWidth:Dn,opacity:1,style:co,ref:function(Ui){_n[uo]=Ui}})})};return $t.createElement("svg",(0,Ne.Z)({className:Ie()("".concat(di,"-circle"),vn),viewBox:"0 0 ".concat(Ge," ").concat(Ge),style:xn,id:hi,role:"presentation"},ft),!Fe&&$t.createElement("circle",{className:"".concat(di,"-circle-trail"),r:Ve,cx:Gt,cy:Gt,stroke:On,strokeLinecap:Hn,strokeWidth:nt||Dn,style:Zt}),Fe?Ri():ti())},Nt=it,St={Line:Qt,Circle:Nt}},71032:function(jn,li,De){"use strict";De.d(li,{Z:function(){return me}});var Ne=De(87462),dt=De(4942),Ut=De(97685),$t=De(45987),kt=De(94184),Ie=De.n(kt),$e=De(21770),Mt=De(15105),Pt=De(64217),wt=De(67294);function Qt(xe,Ee){var Ge=xe.disabled,et=xe.prefixCls,ut=xe.character,st=xe.characterRender,it=xe.index,Nt=xe.count,St=xe.value,Ft=xe.allowHalf,cn=xe.focused,Tt=xe.onHover,hi=xe.onClick,di=function(Lt){Tt(Lt,it)},zn=function(Lt){hi(Lt,it)},Dn=function(Lt){Lt.keyCode===Mt.Z.ENTER&&hi(Lt,it)},nt=it+1,ze=new Set([et]);St===0&&it===0&&cn?ze.add("".concat(et,"-focused")):Ft&&St+.5>=nt&&St<nt?(ze.add("".concat(et,"-half")),ze.add("".concat(et,"-active")),cn&&ze.add("".concat(et,"-focused"))):(nt<=St?ze.add("".concat(et,"-full")):ze.add("".concat(et,"-zero")),nt===St&&cn&&ze.add("".concat(et,"-focused")));var ke=typeof ut=="function"?ut(xe):ut,Wt=wt.createElement("li",{className:Ie()(Array.from(ze)),ref:Ee},wt.createElement("div",{onClick:Ge?null:zn,onKeyDown:Ge?null:Dn,onMouseMove:Ge?null:di,role:"radio","aria-checked":St>it?"true":"false","aria-posinset":it+1,"aria-setsize":Nt,tabIndex:Ge?-1:0},wt.createElement("div",{className:"".concat(et,"-first")},ke),wt.createElement("div",{className:"".concat(et,"-second")},ke)));return st&&(Wt=st(Wt,xe)),Wt}var It=wt.forwardRef(Qt);function sn(){var xe=wt.useRef({});function Ee(et){return xe.current[et]}function Ge(et){return function(ut){xe.current[et]=ut}}return[Ee,Ge]}function Re(xe){var Ee=xe.pageXOffset,Ge="scrollLeft";if(typeof Ee!="number"){var et=xe.document;Ee=et.documentElement[Ge],typeof Ee!="number"&&(Ee=et.body[Ge])}return Ee}function ne(xe){var Ee,Ge,et=xe.ownerDocument,ut=et.body,st=et&&et.documentElement,it=xe.getBoundingClientRect();return Ee=it.left,Ge=it.top,Ee-=st.clientLeft||ut.clientLeft||0,Ge-=st.clientTop||ut.clientTop||0,{left:Ee,top:Ge}}function te(xe){var Ee=ne(xe),Ge=xe.ownerDocument,et=Ge.defaultView||Ge.parentWindow;return Ee.left+=Re(et),Ee.left}var he=["prefixCls","className","defaultValue","value","count","allowHalf","allowClear","keyboard","character","characterRender","disabled","direction","tabIndex","autoFocus","onHoverChange","onChange","onFocus","onBlur","onKeyDown","onMouseLeave"];function le(xe,Ee){var Ge=xe.prefixCls,et=Ge===void 0?"rc-rate":Ge,ut=xe.className,st=xe.defaultValue,it=xe.value,Nt=xe.count,St=Nt===void 0?5:Nt,Ft=xe.allowHalf,cn=Ft===void 0?!1:Ft,Tt=xe.allowClear,hi=Tt===void 0?!0:Tt,di=xe.keyboard,zn=di===void 0?!0:di,Dn=xe.character,nt=Dn===void 0?"\u2605":Dn,ze=xe.characterRender,ke=xe.disabled,Wt=xe.direction,On=Wt===void 0?"ltr":Wt,Lt=xe.tabIndex,xn=Lt===void 0?0:Lt,vn=xe.autoFocus,Xn=xe.onHoverChange,Ot=xe.onChange,ft=xe.onFocus,Gt=xe.onBlur,an=xe.onKeyDown,Jt=xe.onMouseLeave,Ve=(0,$t.Z)(xe,he),be=sn(),Pe=(0,Ut.Z)(be,2),Be=Pe[0],Ze=Pe[1],Fe=wt.useRef(null),qe=function(){if(!ke){var _r;(_r=Fe.current)===null||_r===void 0||_r.focus()}};wt.useImperativeHandle(Ee,function(){return{focus:qe,blur:function(){if(!ke){var _r;(_r=Fe.current)===null||_r===void 0||_r.blur()}}}});var dn=(0,$e.Z)(st||0,{value:it}),ui=(0,Ut.Z)(dn,2),$n=ui[0],rn=ui[1],Hn=(0,$e.Z)(null),Zt=(0,Ut.Z)(Hn,2),_n=Zt[0],ti=Zt[1],Ri=function(_r,Fn){var we=On==="rtl",Qn=_r+1;if(cn){var bn=Be(_r),on=te(bn),ln=bn.clientWidth;(we&&Fn-on>ln/2||!we&&Fn-on<ln/2)&&(Qn-=.5)}return Qn},oi=function(_r){rn(_r),Ot==null||Ot(_r)},wr=wt.useState(!1),fr=(0,Ut.Z)(wr,2),Ei=fr[0],Di=fr[1],uo=function(){Di(!0),ft==null||ft()},vt=function(){Di(!1),Gt==null||Gt()},ei=wt.useState(null),co=(0,Ut.Z)(ei,2),bo=co[0],Ui=co[1],yo=function(_r,Fn){var we=Ri(Fn,_r.pageX);we!==_n&&(Ui(we),ti(null)),Xn==null||Xn(we)},ha=function(_r){ke||(Ui(null),ti(null),Xn==null||Xn(void 0)),_r&&(Jt==null||Jt(_r))},Ka=function(_r,Fn){var we=Ri(Fn,_r.pageX),Qn=!1;hi&&(Qn=we===$n),ha(),oi(Qn?0:we),ti(Qn?we:null)},Ra=function(_r){var Fn=_r.keyCode,we=On==="rtl",Qn=cn?.5:1;zn&&(Fn===Mt.Z.RIGHT&&$n<St&&!we?(oi($n+Qn),_r.preventDefault()):Fn===Mt.Z.LEFT&&$n>0&&!we||Fn===Mt.Z.RIGHT&&$n>0&&we?(oi($n-Qn),_r.preventDefault()):Fn===Mt.Z.LEFT&&$n<St&&we&&(oi($n+Qn),_r.preventDefault())),an==null||an(_r)};wt.useEffect(function(){vn&&!ke&&qe()},[]);var ca=new Array(St).fill(0).map(function(Ho,_r){return wt.createElement(It,{ref:Ze(_r),index:_r,count:St,disabled:ke,prefixCls:"".concat(et,"-star"),allowHalf:cn,value:bo===null?$n:bo,onClick:Ka,onHover:yo,key:Ho||_r,character:nt,characterRender:ze,focused:Ei})}),ma=Ie()(et,ut,(0,dt.Z)((0,dt.Z)({},"".concat(et,"-disabled"),ke),"".concat(et,"-rtl"),On==="rtl"));return wt.createElement("ul",(0,Ne.Z)({className:ma,onMouseLeave:ha,tabIndex:ke?-1:xn,onFocus:ke?null:uo,onBlur:ke?null:vt,onKeyDown:ke?null:Ra,ref:Fe},(0,Pt.Z)(Ve,{aria:!0,data:!0,attr:!0})),ca)}var pe=wt.forwardRef(le),me=pe},58212:function(jn,li,De){"use strict";De.d(li,{Z:function(){return Dn}});function Ne(){return Ne=Object.assign?Object.assign.bind():function(nt){for(var ze=1;ze<arguments.length;ze++){var ke=arguments[ze];for(var Wt in ke)Object.prototype.hasOwnProperty.call(ke,Wt)&&(nt[Wt]=ke[Wt])}return nt},Ne.apply(this,arguments)}function dt(nt){"@babel/helpers - typeof";return dt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ze){return typeof ze}:function(ze){return ze&&typeof Symbol=="function"&&ze.constructor===Symbol&&ze!==Symbol.prototype?"symbol":typeof ze},dt(nt)}function Ut(nt,ze){if(dt(nt)!=="object"||nt===null)return nt;var ke=nt[Symbol.toPrimitive];if(ke!==void 0){var Wt=ke.call(nt,ze||"default");if(dt(Wt)!=="object")return Wt;throw new TypeError("@@toPrimitive must return a primitive value.")}return(ze==="string"?String:Number)(nt)}function $t(nt){var ze=Ut(nt,"string");return dt(ze)==="symbol"?ze:String(ze)}function kt(nt,ze,ke){return ze=$t(ze),ze in nt?Object.defineProperty(nt,ze,{value:ke,enumerable:!0,configurable:!0,writable:!0}):nt[ze]=ke,nt}function Ie(nt){if(Array.isArray(nt))return nt}function $e(nt,ze){var ke=nt==null?null:typeof Symbol!="undefined"&&nt[Symbol.iterator]||nt["@@iterator"];if(ke!=null){var Wt,On,Lt,xn,vn=[],Xn=!0,Ot=!1;try{if(Lt=(ke=ke.call(nt)).next,ze===0){if(Object(ke)!==ke)return;Xn=!1}else for(;!(Xn=(Wt=Lt.call(ke)).done)&&(vn.push(Wt.value),vn.length!==ze);Xn=!0);}catch(ft){Ot=!0,On=ft}finally{try{if(!Xn&&ke.return!=null&&(xn=ke.return(),Object(xn)!==xn))return}finally{if(Ot)throw On}}return vn}}function Mt(nt,ze){(ze==null||ze>nt.length)&&(ze=nt.length);for(var ke=0,Wt=new Array(ze);ke<ze;ke++)Wt[ke]=nt[ke];return Wt}function Pt(nt,ze){if(nt){if(typeof nt=="string")return Mt(nt,ze);var ke=Object.prototype.toString.call(nt).slice(8,-1);if(ke==="Object"&&nt.constructor&&(ke=nt.constructor.name),ke==="Map"||ke==="Set")return Array.from(nt);if(ke==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ke))return Mt(nt,ze)}}function wt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Qt(nt,ze){return Ie(nt)||$e(nt,ze)||Pt(nt,ze)||wt()}function It(nt,ze){if(nt==null)return{};var ke={},Wt=Object.keys(nt),On,Lt;for(Lt=0;Lt<Wt.length;Lt++)On=Wt[Lt],!(ze.indexOf(On)>=0)&&(ke[On]=nt[On]);return ke}function sn(nt,ze){if(nt==null)return{};var ke=It(nt,ze),Wt,On;if(Object.getOwnPropertySymbols){var Lt=Object.getOwnPropertySymbols(nt);for(On=0;On<Lt.length;On++)Wt=Lt[On],!(ze.indexOf(Wt)>=0)&&Object.prototype.propertyIsEnumerable.call(nt,Wt)&&(ke[Wt]=nt[Wt])}return ke}var Re=De(67294),ne=De(94184),te=De.n(ne);function he(nt){if(Array.isArray(nt))return nt}function le(nt,ze){var ke=nt==null?null:typeof Symbol!="undefined"&&nt[Symbol.iterator]||nt["@@iterator"];if(ke!=null){var Wt,On,Lt,xn,vn=[],Xn=!0,Ot=!1;try{if(Lt=(ke=ke.call(nt)).next,ze===0){if(Object(ke)!==ke)return;Xn=!1}else for(;!(Xn=(Wt=Lt.call(ke)).done)&&(vn.push(Wt.value),vn.length!==ze);Xn=!0);}catch(ft){Ot=!0,On=ft}finally{try{if(!Xn&&ke.return!=null&&(xn=ke.return(),Object(xn)!==xn))return}finally{if(Ot)throw On}}return vn}}function pe(nt,ze){(ze==null||ze>nt.length)&&(ze=nt.length);for(var ke=0,Wt=new Array(ze);ke<ze;ke++)Wt[ke]=nt[ke];return Wt}function me(nt,ze){if(nt){if(typeof nt=="string")return pe(nt,ze);var ke=Object.prototype.toString.call(nt).slice(8,-1);if(ke==="Object"&&nt.constructor&&(ke=nt.constructor.name),ke==="Map"||ke==="Set")return Array.from(nt);if(ke==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ke))return pe(nt,ze)}}function xe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ee(nt,ze){return he(nt)||le(nt,ze)||me(nt,ze)||xe()}function Ge(nt){var ze=Re.useRef();ze.current=nt;var ke=Re.useCallback(function(){for(var Wt,On=arguments.length,Lt=new Array(On),xn=0;xn<On;xn++)Lt[xn]=arguments[xn];return(Wt=ze.current)===null||Wt===void 0?void 0:Wt.call.apply(Wt,[ze].concat(Lt))},[]);return ke}function et(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var ut=et()?Re.useLayoutEffect:Re.useEffect,st=function(ze,ke){var Wt=Re.useRef(!0);ut(function(){return ze(Wt.current)},ke),ut(function(){return Wt.current=!1,function(){Wt.current=!0}},[])},it=function(ze,ke){st(function(Wt){if(!Wt)return ze()},ke)},Nt=null;function St(nt){var ze=Re.useRef(!1),ke=Re.useState(nt),Wt=Ee(ke,2),On=Wt[0],Lt=Wt[1];Re.useEffect(function(){return ze.current=!1,function(){ze.current=!0}},[]);function xn(vn,Xn){Xn&&ze.current||Lt(vn)}return[On,xn]}function Ft(nt){return nt!==void 0}function cn(nt,ze){var ke=ze||{},Wt=ke.defaultValue,On=ke.value,Lt=ke.onChange,xn=ke.postState,vn=St(function(){return Ft(On)?On:Ft(Wt)?typeof Wt=="function"?Wt():Wt:typeof nt=="function"?nt():nt}),Xn=Ee(vn,2),Ot=Xn[0],ft=Xn[1],Gt=On!==void 0?On:Ot,an=xn?xn(Gt):Gt,Jt=Ge(Lt),Ve=St([Gt]),be=Ee(Ve,2),Pe=be[0],Be=be[1];it(function(){var Fe=Pe[0];Ot!==Fe&&Jt(Ot,Fe)},[Pe]),it(function(){Ft(On)||ft(On)},[On]);var Ze=Ge(function(Fe,qe){ft(Fe,qe),Be([Gt],qe)});return[an,Ze]}var Tt={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(ze){var ke=ze.keyCode;if(ze.altKey&&!ze.ctrlKey||ze.metaKey||ke>=Tt.F1&&ke<=Tt.F12)return!1;switch(ke){case Tt.ALT:case Tt.CAPS_LOCK:case Tt.CONTEXT_MENU:case Tt.CTRL:case Tt.DOWN:case Tt.END:case Tt.ESC:case Tt.HOME:case Tt.INSERT:case Tt.LEFT:case Tt.MAC_FF_META:case Tt.META:case Tt.NUMLOCK:case Tt.NUM_CENTER:case Tt.PAGE_DOWN:case Tt.PAGE_UP:case Tt.PAUSE:case Tt.PRINT_SCREEN:case Tt.RIGHT:case Tt.SHIFT:case Tt.UP:case Tt.WIN_KEY:case Tt.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(ze){if(ze>=Tt.ZERO&&ze<=Tt.NINE||ze>=Tt.NUM_ZERO&&ze<=Tt.NUM_MULTIPLY||ze>=Tt.A&&ze<=Tt.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&ze===0)return!0;switch(ze){case Tt.SPACE:case Tt.QUESTION_MARK:case Tt.NUM_PLUS:case Tt.NUM_MINUS:case Tt.NUM_PERIOD:case Tt.NUM_DIVISION:case Tt.SEMICOLON:case Tt.DASH:case Tt.EQUALS:case Tt.COMMA:case Tt.PERIOD:case Tt.SLASH:case Tt.APOSTROPHE:case Tt.SINGLE_QUOTE:case Tt.OPEN_SQUARE_BRACKET:case Tt.BACKSLASH:case Tt.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},hi=Tt,di=["prefixCls","className","checked","defaultChecked","disabled","loadingIcon","checkedChildren","unCheckedChildren","onClick","onChange","onKeyDown"],zn=Re.forwardRef(function(nt,ze){var ke,Wt=nt.prefixCls,On=Wt===void 0?"rc-switch":Wt,Lt=nt.className,xn=nt.checked,vn=nt.defaultChecked,Xn=nt.disabled,Ot=nt.loadingIcon,ft=nt.checkedChildren,Gt=nt.unCheckedChildren,an=nt.onClick,Jt=nt.onChange,Ve=nt.onKeyDown,be=sn(nt,di),Pe=cn(!1,{value:xn,defaultValue:vn}),Be=Qt(Pe,2),Ze=Be[0],Fe=Be[1];function qe(rn,Hn){var Zt=Ze;return Xn||(Zt=rn,Fe(Zt),Jt==null||Jt(Zt,Hn)),Zt}function dn(rn){rn.which===hi.LEFT?qe(!1,rn):rn.which===hi.RIGHT&&qe(!0,rn),Ve==null||Ve(rn)}function ui(rn){var Hn=qe(!Ze,rn);an==null||an(Hn,rn)}var $n=te()(On,Lt,(ke={},kt(ke,"".concat(On,"-checked"),Ze),kt(ke,"".concat(On,"-disabled"),Xn),ke));return Re.createElement("button",Ne({},be,{type:"button",role:"switch","aria-checked":Ze,disabled:Xn,className:$n,ref:ze,onKeyDown:dn,onClick:ui}),Ot,Re.createElement("span",{className:"".concat(On,"-inner")},Re.createElement("span",{className:"".concat(On,"-inner-checked")},ft),Re.createElement("span",{className:"".concat(On,"-inner-unchecked")},Gt)))});zn.displayName="Switch";var Dn=zn},45233:function(jn,li,De){"use strict";De.d(li,{R:function(){return dt},w:function(){return Ne}});var Ne={},dt="rc-table-internal-hook"},54768:function(jn,li,De){"use strict";De.d(li,{L:function(){return he},Z:function(){return Ee}});var Ne=De(97685),dt=De(4942),Ut=De(74902),$t=De(71002),kt=De(1413),Ie=De(45987),$e=De(63295),Mt=De(67294);function Pt(Ge){var et=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ut=[];return Mt.Children.forEach(Ge,function(st){st==null&&!et.keepEmpty||(Array.isArray(st)?ut=ut.concat(Pt(st)):(0,$e.Z)(st)&&st.props?ut=ut.concat(Pt(st.props.children,et)):ut.push(st))}),ut}var wt=De(40830),Qt=De(45233),It=De(62978);function sn(Ge){var et=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return typeof et=="number"?et:et.endsWith("%")?Ge*parseFloat(et)/100:null}function Re(Ge,et,ut){return Mt.useMemo(function(){if(et&&et>0){var st=0,it=0;Ge.forEach(function(zn){var Dn=sn(et,zn.width);Dn?st+=Dn:it+=1});var Nt=Math.max(et,ut),St=Math.max(Nt-st,it),Ft=it,cn=St/it,Tt=0,hi=Ge.map(function(zn){var Dn=(0,kt.Z)({},zn),nt=sn(et,Dn.width);if(nt)Dn.width=nt;else{var ze=Math.floor(cn);Dn.width=Ft===1?St:ze,St-=ze,Ft-=1}return Tt+=Dn.width,Dn});if(Tt<Nt){var di=Nt/Tt;St=Nt,hi.forEach(function(zn,Dn){var nt=Math.floor(zn.width*di);zn.width=Dn===hi.length-1?St:nt,St-=nt})}return[hi,Math.max(Tt,Nt)]}return[Ge,et]},[Ge,et,ut])}var ne=["children"],te=["fixed"];function he(Ge){return Pt(Ge).filter(function(et){return Mt.isValidElement(et)}).map(function(et){var ut=et.key,st=et.props,it=st.children,Nt=(0,Ie.Z)(st,ne),St=(0,kt.Z)({key:ut},Nt);return it&&(St.children=he(it)),St})}function le(Ge){return Ge.filter(function(et){return et&&(0,$t.Z)(et)==="object"&&!et.hidden}).map(function(et){var ut=et.children;return ut&&ut.length>0?(0,kt.Z)((0,kt.Z)({},et),{},{children:le(ut)}):et})}function pe(Ge){var et=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"key";return Ge.filter(function(ut){return ut&&(0,$t.Z)(ut)==="object"}).reduce(function(ut,st,it){var Nt=st.fixed,St=Nt===!0?"left":Nt,Ft="".concat(et,"-").concat(it),cn=st.children;return cn&&cn.length>0?[].concat((0,Ut.Z)(ut),(0,Ut.Z)(pe(cn,Ft).map(function(Tt){return(0,kt.Z)({fixed:St},Tt)}))):[].concat((0,Ut.Z)(ut),[(0,kt.Z)((0,kt.Z)({key:Ft},st),{},{fixed:St})])},[])}function me(Ge){return Ge.map(function(et){var ut=et.fixed,st=(0,Ie.Z)(et,te),it=ut;return ut==="left"?it="right":ut==="right"&&(it="left"),(0,kt.Z)({fixed:it},st)})}function xe(Ge,et){var ut=Ge.prefixCls,st=Ge.columns,it=Ge.children,Nt=Ge.expandable,St=Ge.expandedKeys,Ft=Ge.columnTitle,cn=Ge.getRowKey,Tt=Ge.onTriggerExpand,hi=Ge.expandIcon,di=Ge.rowExpandable,zn=Ge.expandIconColumnIndex,Dn=Ge.direction,nt=Ge.expandRowByClick,ze=Ge.columnWidth,ke=Ge.fixed,Wt=Ge.scrollWidth,On=Ge.clientWidth,Lt=Mt.useMemo(function(){var Ve=st||he(it)||[];return le(Ve.slice())},[st,it]),xn=Mt.useMemo(function(){if(Nt){var Ve=Lt.slice();if(!Ve.includes(Qt.w)){var be=zn||0;be>=0&&(be||ke==="left"||!ke)&&Ve.splice(be,0,Qt.w),ke==="right"&&Ve.splice(Lt.length,0,Qt.w)}var Pe=Ve.indexOf(Qt.w);Ve=Ve.filter(function(qe,dn){return qe!==Qt.w||dn===Pe});var Be=Lt[Pe],Ze;ke?Ze=ke:Ze=Be?Be.fixed:null;var Fe=(0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)({},It.v,{className:"".concat(ut,"-expand-icon-col"),columnType:"EXPAND_COLUMN"}),"title",Ft),"fixed",Ze),"className","".concat(ut,"-row-expand-icon-cell")),"width",ze),"render",function(dn,ui,$n){var rn=cn(ui,$n),Hn=St.has(rn),Zt=di?di(ui):!0,_n=hi({prefixCls:ut,expanded:Hn,expandable:Zt,record:ui,onExpand:Tt});return nt?Mt.createElement("span",{onClick:function(Ri){return Ri.stopPropagation()}},_n):_n});return Ve.map(function(qe){return qe===Qt.w?Fe:qe})}return Lt.filter(function(qe){return qe!==Qt.w})},[Nt,Lt,cn,St,hi,Dn]),vn=Mt.useMemo(function(){var Ve=xn;return et&&(Ve=et(Ve)),Ve.length||(Ve=[{render:function(){return null}}]),Ve},[et,xn,Dn]),Xn=Mt.useMemo(function(){return Dn==="rtl"?me(pe(vn)):pe(vn)},[vn,Dn,Wt]),Ot=Mt.useMemo(function(){for(var Ve=-1,be=Xn.length-1;be>=0;be-=1){var Pe=Xn[be].fixed;if(Pe==="left"||Pe===!0){Ve=be;break}}if(Ve>=0)for(var Be=0;Be<=Ve;Be+=1){var Ze=Xn[Be].fixed;if(Ze!=="left"&&Ze!==!0)return!0}var Fe=Xn.findIndex(function(ui){var $n=ui.fixed;return $n==="right"});if(Fe>=0)for(var qe=Fe;qe<Xn.length;qe+=1){var dn=Xn[qe].fixed;if(dn!=="right")return!0}return!1},[Xn]),ft=Re(Xn,Wt,On),Gt=(0,Ne.Z)(ft,2),an=Gt[0],Jt=Gt[1];return[vn,an,Jt,Ot]}var Ee=xe},29104:function(jn,li,De){"use strict";De.d(li,{w2:function(){return Ne.w},vP:function(){return fo.v},RQ:function(){return Ne.R},ER:function(){return Fn},Q$:function(){return Ds},TN:function(){return Fh}});var Ne=De(45233),dt=De(97685),Ut=De(66680),$t=De(8410),kt=De(91881),Ie=De(67294),$e=De(73935);function Mt(Ue){var ht=Ie.createContext(void 0),pt=function(Ht){var en=Ht.value,un=Ht.children,En=Ie.useRef(en);En.current=en;var Yn=Ie.useState(function(){return{getValue:function(){return En.current},listeners:new Set}}),Gn=(0,dt.Z)(Yn,1),Si=Gn[0];return(0,$t.Z)(function(){(0,$e.unstable_batchedUpdates)(function(){Si.listeners.forEach(function(Un){Un(en)})})},[en]),Ie.createElement(ht.Provider,{value:Si},un)};return{Context:ht,Provider:pt,defaultValue:Ue}}function Pt(Ue,ht){var pt=(0,Ut.Z)(typeof ht=="function"?ht:function(Un){if(ht===void 0)return Un;if(!Array.isArray(ht))return Un[ht];var gi={};return ht.forEach(function(ii){gi[ii]=Un[ii]}),gi}),xt=Ie.useContext(Ue==null?void 0:Ue.Context),Ht=xt||{},en=Ht.listeners,un=Ht.getValue,En=Ie.useRef();En.current=pt(xt?un():Ue==null?void 0:Ue.defaultValue);var Yn=Ie.useState({}),Gn=(0,dt.Z)(Yn,2),Si=Gn[1];return(0,$t.Z)(function(){if(!xt)return;function Un(gi){var ii=pt(gi);(0,kt.Z)(En.current,ii,!0)||Si({})}return en.add(Un),function(){en.delete(Un)}},[xt]),En.current}var wt=De(87462),Qt=De(42550);function It(){var Ue=Ie.createContext(null);function ht(){return Ie.useContext(Ue)}function pt(Ht,en){var un=(0,Qt.Yr)(Ht),En=function(Gn,Si){var Un=un?{ref:Si}:{},gi=Ie.useRef(0),ii=Ie.useRef(Gn),Oi=ht();return Oi!==null?Ie.createElement(Ht,(0,wt.Z)({},Gn,Un)):((!en||en(ii.current,Gn))&&(gi.current+=1),ii.current=Gn,Ie.createElement(Ue.Provider,{value:gi.current},Ie.createElement(Ht,(0,wt.Z)({},Gn,Un))))};return un?Ie.forwardRef(En):En}function xt(Ht,en){var un=(0,Qt.Yr)(Ht),En=function(Gn,Si){var Un=un?{ref:Si}:{};return ht(),Ie.createElement(Ht,(0,wt.Z)({},Gn,Un))};return un?Ie.memo(Ie.forwardRef(En),en):Ie.memo(En,en)}return{makeImmutable:pt,responseImmutable:xt,useImmutableMark:ht}}var sn=It(),Re=sn.makeImmutable,ne=sn.responseImmutable,te=sn.useImmutableMark,he=It(),le=he.makeImmutable,pe=he.responseImmutable,me=he.useImmutableMark,xe=Mt(),Ee=xe;function Ge(Ue,ht){var pt=React.useRef(0);pt.current+=1;var xt=React.useRef(Ue),Ht=[];Object.keys(Ue||{}).map(function(un){var En;(Ue==null?void 0:Ue[un])!==((En=xt.current)===null||En===void 0?void 0:En[un])&&Ht.push(un)}),xt.current=Ue;var en=React.useRef([]);return Ht.length&&(en.current=Ht),React.useDebugValue(pt.current),React.useDebugValue(en.current.join(", ")),ht&&console.log("".concat(ht,":"),pt.current,en.current),pt.current}var et=null,ut=null,st=De(71002),it=De(1413),Nt=De(4942),St=De(94184),Ft=De.n(St);function cn(Ue,ht,pt){var xt=Ie.useRef({});return(!("value"in xt.current)||pt(xt.current.condition,ht))&&(xt.current.value=Ue(),xt.current.condition=ht),xt.current.value}var Tt=De(40830);function hi(Ue,ht){var pt=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,xt=new Set;function Ht(en,un){var En=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,Yn=xt.has(en);if((0,Tt.ZP)(!Yn,"Warning: There may be circular references"),Yn)return!1;if(en===un)return!0;if(pt&&En>1)return!1;xt.add(en);var Gn=En+1;if(Array.isArray(en)){if(!Array.isArray(un)||en.length!==un.length)return!1;for(var Si=0;Si<en.length;Si++)if(!Ht(en[Si],un[Si],Gn))return!1;return!0}if(en&&un&&(0,st.Z)(en)==="object"&&(0,st.Z)(un)==="object"){var Un=Object.keys(en);return Un.length!==Object.keys(un).length?!1:Un.every(function(gi){return Ht(en[gi],un[gi],Gn)})}return!1}return Ht(Ue,ht)}var di=hi;function zn(Ue,ht){for(var pt=Ue,xt=0;xt<ht.length;xt+=1){if(pt==null)return;pt=pt[ht[xt]]}return pt}var Dn=Ie.createContext({renderWithProps:!1}),nt=Dn,ze="RC_TABLE_KEY";function ke(Ue){return Ue==null?[]:Array.isArray(Ue)?Ue:[Ue]}function Wt(Ue){var ht=[],pt={};return Ue.forEach(function(xt){for(var Ht=xt||{},en=Ht.key,un=Ht.dataIndex,En=en||ke(un).join("-")||ze;pt[En];)En="".concat(En,"_next");pt[En]=!0,ht.push(En)}),ht}function On(Ue){return Ue!=null}function Lt(Ue){return typeof Ue=="number"&&!Number.isNaN(Ue)}function xn(Ue){return Ue&&(0,st.Z)(Ue)==="object"&&!Array.isArray(Ue)&&!Ie.isValidElement(Ue)}function vn(Ue,ht,pt,xt,Ht,en){var un=Ie.useContext(nt),En=me(),Yn=cn(function(){if(On(xt))return[xt];var Gn=ht==null||ht===""?[]:Array.isArray(ht)?ht:[ht],Si=zn(Ue,Gn),Un=Si,gi=void 0;if(Ht){var ii=Ht(Si,Ue,pt);xn(ii)?(Un=ii.children,gi=ii.props,un.renderWithProps=!0):Un=ii}return[Un,gi]},[En,Ue,xt,ht,Ht,pt],function(Gn,Si){if(en){var Un=(0,dt.Z)(Gn,2),gi=Un[1],ii=(0,dt.Z)(Si,2),Oi=ii[1];return en(Oi,gi)}return un.renderWithProps?!0:!di(Gn,Si,!0)});return Yn}function Xn(Ue,ht,pt,xt){var Ht=Ue+ht-1;return Ue<=xt&&Ht>=pt}function Ot(Ue,ht){return Pt(Ee,function(pt){var xt=Xn(Ue,ht||1,pt.hoverStartRow,pt.hoverEndRow);return[xt,pt.onHover]})}function ft(Ue){var ht=Ie.useRef();ht.current=Ue;var pt=Ie.useCallback(function(){for(var xt,Ht=arguments.length,en=new Array(Ht),un=0;un<Ht;un++)en[un]=arguments[un];return(xt=ht.current)===null||xt===void 0?void 0:xt.call.apply(xt,[ht].concat(en))},[]);return pt}function Gt(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var an=Gt()?Ie.useLayoutEffect:Ie.useEffect,Jt=function(ht,pt){var xt=React.useRef(!0);an(function(){return ht(xt.current)},pt),an(function(){return xt.current=!1,function(){xt.current=!0}},[])},Ve=function(ht,pt){Jt(function(xt){if(!xt)return ht()},pt)},be=null;function Pe(Ue){var ht=React.useRef(!1),pt=React.useState(Ue),xt=_slicedToArray(pt,2),Ht=xt[0],en=xt[1];React.useEffect(function(){return ht.current=!1,function(){ht.current=!0}},[]);function un(En,Yn){Yn&&ht.current||en(En)}return[Ht,un]}function Be(Ue){return Ue!==void 0}function Ze(Ue,ht){var pt=ht||{},xt=pt.defaultValue,Ht=pt.value,en=pt.onChange,un=pt.postState,En=useState(function(){return Be(Ht)?Ht:Be(xt)?typeof xt=="function"?xt():xt:typeof Ue=="function"?Ue():Ue}),Yn=_slicedToArray(En,2),Gn=Yn[0],Si=Yn[1],Un=Ht!==void 0?Ht:Gn,gi=un?un(Un):Un,ii=useEvent(en),Oi=useState([Un]),lr=_slicedToArray(Oi,2),br=lr[0],Zr=lr[1];useLayoutUpdateEffect(function(){var mr=br[0];Gn!==mr&&ii(Gn,mr)},[br]),useLayoutUpdateEffect(function(){Be(Ht)||Si(Ht)},[Ht]);var Gi=useEvent(function(mr,er){Si(mr,er),Zr([Un],er)});return[gi,Gi]}var Fe=De(35110),qe=De(63295),dn=Number(Ie.version.split(".")[0]),ui=function(ht,pt){typeof ht=="function"?ht(pt):(0,st.Z)(ht)==="object"&&ht&&"current"in ht&&(ht.current=pt)},$n=function(){for(var ht=arguments.length,pt=new Array(ht),xt=0;xt<ht;xt++)pt[xt]=arguments[xt];var Ht=pt.filter(Boolean);return Ht.length<=1?Ht[0]:function(en){pt.forEach(function(un){ui(un,en)})}},rn=function(){for(var ht=arguments.length,pt=new Array(ht),xt=0;xt<ht;xt++)pt[xt]=arguments[xt];return useMemo(function(){return $n.apply(void 0,pt)},pt,function(Ht,en){return Ht.length!==en.length||Ht.every(function(un,En){return un!==en[En]})})},Hn=function(ht){var pt,xt;if(!ht)return!1;if(Zt(ht)&&dn>=19)return!0;var Ht=isMemo(ht)?ht.type.type:ht.type;return!(typeof Ht=="function"&&!((pt=Ht.prototype)!==null&&pt!==void 0&&pt.render)&&Ht.$$typeof!==ForwardRef||typeof ht=="function"&&!((xt=ht.prototype)!==null&&xt!==void 0&&xt.render)&&ht.$$typeof!==ForwardRef)};function Zt(Ue){return isValidElement(Ue)&&!isFragment(Ue)}var _n=function(ht){return Zt(ht)&&Hn(ht)},ti=function(ht){if(ht&&Zt(ht)){var pt=ht;return pt.props.propertyIsEnumerable("ref")?pt.props.ref:pt.ref}return null};function Ri(Ue,ht,pt,xt){if(!ht.length)return pt;var Ht=_toArray(ht),en=Ht[0],un=Ht.slice(1),En;return!Ue&&typeof en=="number"?En=[]:Array.isArray(Ue)?En=_toConsumableArray(Ue):En=_objectSpread({},Ue),xt&&pt===void 0&&un.length===1?delete En[en][un[0]]:En[en]=Ri(En[en],un,pt,xt),En}function oi(Ue,ht,pt){var xt=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;return ht.length&&xt&&pt===void 0&&!get(Ue,ht.slice(0,-1))?Ue:Ri(Ue,ht,pt,xt)}function wr(Ue){return _typeof(Ue)==="object"&&Ue!==null&&Object.getPrototypeOf(Ue)===Object.prototype}function fr(Ue){return Array.isArray(Ue)?[]:{}}var Ei=typeof Reflect=="undefined"?Object.keys:Reflect.ownKeys;function Di(){for(var Ue=arguments.length,ht=new Array(Ue),pt=0;pt<Ue;pt++)ht[pt]=arguments[pt];var xt=fr(ht[0]);return ht.forEach(function(Ht){function en(un,En){var Yn=new Set(En),Gn=get(Ht,un),Si=Array.isArray(Gn);if(Si||wr(Gn)){if(!Yn.has(Gn)){Yn.add(Gn);var Un=get(xt,un);Si?xt=oi(xt,un,[]):(!Un||_typeof(Un)!=="object")&&(xt=oi(xt,un,fr(Gn))),Ei(Gn).forEach(function(gi){en([].concat(_toConsumableArray(un),[gi]),Yn)})}}else xt=oi(xt,un,Gn)}en([])}),xt}var uo=function(ht){var pt=ht.ellipsis,xt=ht.rowType,Ht=ht.children,en,un=pt===!0?{showTitle:!0}:pt;return un&&(un.showTitle||xt==="header")&&(typeof Ht=="string"||typeof Ht=="number"?en=Ht.toString():Ie.isValidElement(Ht)&&typeof Ht.props.children=="string"&&(en=Ht.props.children)),en};function vt(Ue){var ht,pt,xt,Ht,en,un,En,Yn,Gn=Ue.component,Si=Ue.children,Un=Ue.ellipsis,gi=Ue.scope,ii=Ue.prefixCls,Oi=Ue.className,lr=Ue.align,br=Ue.record,Zr=Ue.render,Gi=Ue.dataIndex,mr=Ue.renderIndex,er=Ue.shouldCellUpdate,Yr=Ue.index,No=Ue.rowType,Wr=Ue.colSpan,da=Ue.rowSpan,To=Ue.fixLeft,la=Ue.fixRight,ys=Ue.firstFixLeft,Da=Ue.lastFixLeft,Te=Ue.firstFixRight,Oe=Ue.lastFixRight,Xe=Ue.appendNode,ot=Ue.additionalProps,Rt=ot===void 0?{}:ot,Se=Ue.isSticky,Le="".concat(ii,"-cell"),je=Pt(Ee,["supportSticky","allColumnsFixedLeft","rowHoverable"]),Ke=je.supportSticky,ct=je.allColumnsFixedLeft,Et=je.rowHoverable,Bt=vn(br,Gi,mr,Si,Zr,er),hn=(0,dt.Z)(Bt,2),qt=hn[0],nn=hn[1],Sn={},yn=typeof To=="number"&&Ke,Jn=typeof la=="number"&&Ke;yn&&(Sn.position="sticky",Sn.left=To),Jn&&(Sn.position="sticky",Sn.right=la);var In=(ht=(pt=(xt=nn==null?void 0:nn.colSpan)!==null&&xt!==void 0?xt:Rt.colSpan)!==null&&pt!==void 0?pt:Wr)!==null&&ht!==void 0?ht:1,Mn=(Ht=(en=(un=nn==null?void 0:nn.rowSpan)!==null&&un!==void 0?un:Rt.rowSpan)!==null&&en!==void 0?en:da)!==null&&Ht!==void 0?Ht:1,Kn=Ot(Yr,Mn),ni=(0,dt.Z)(Kn,2),yi=ni[0],$i=ni[1],Ai=ft(function(ar){var ki;br&&$i(Yr,Yr+Mn-1),Rt==null||(ki=Rt.onMouseEnter)===null||ki===void 0||ki.call(Rt,ar)}),bi=ft(function(ar){var ki;br&&$i(-1,-1),Rt==null||(ki=Rt.onMouseLeave)===null||ki===void 0||ki.call(Rt,ar)});if(In===0||Mn===0)return null;var dr=(En=Rt.title)!==null&&En!==void 0?En:uo({rowType:No,ellipsis:Un,children:qt}),Wn=Ft()(Le,Oi,(Yn={},(0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)(Yn,"".concat(Le,"-fix-left"),yn&&Ke),"".concat(Le,"-fix-left-first"),ys&&Ke),"".concat(Le,"-fix-left-last"),Da&&Ke),"".concat(Le,"-fix-left-all"),Da&&ct&&Ke),"".concat(Le,"-fix-right"),Jn&&Ke),"".concat(Le,"-fix-right-first"),Te&&Ke),"".concat(Le,"-fix-right-last"),Oe&&Ke),"".concat(Le,"-ellipsis"),Un),"".concat(Le,"-with-append"),Xe),"".concat(Le,"-fix-sticky"),(yn||Jn)&&Se&&Ke),(0,Nt.Z)(Yn,"".concat(Le,"-row-hover"),!nn&&yi)),Rt.className,nn==null?void 0:nn.className),Ji={};lr&&(Ji.textAlign=lr);var Pi=(0,it.Z)((0,it.Z)((0,it.Z)((0,it.Z)({},nn==null?void 0:nn.style),Sn),Ji),Rt.style),tr=qt;return(0,st.Z)(tr)==="object"&&!Array.isArray(tr)&&!Ie.isValidElement(tr)&&(tr=null),Un&&(Da||Te)&&(tr=Ie.createElement("span",{className:"".concat(Le,"-content")},tr)),Ie.createElement(Gn,(0,wt.Z)({},nn,Rt,{className:Wn,style:Pi,title:dr,scope:gi,onMouseEnter:Et?Ai:void 0,onMouseLeave:Et?bi:void 0,colSpan:In!==1?In:null,rowSpan:Mn!==1?Mn:null}),Xe,tr)}var ei=Ie.memo(vt);function co(Ue,ht,pt,xt,Ht){var en=pt[Ue]||{},un=pt[ht]||{},En,Yn;en.fixed==="left"?En=xt.left[Ht==="rtl"?ht:Ue]:un.fixed==="right"&&(Yn=xt.right[Ht==="rtl"?Ue:ht]);var Gn=!1,Si=!1,Un=!1,gi=!1,ii=pt[ht+1],Oi=pt[Ue-1],lr=ii&&!ii.fixed||Oi&&!Oi.fixed||pt.every(function(er){return er.fixed==="left"});if(Ht==="rtl"){if(En!==void 0){var br=Oi&&Oi.fixed==="left";gi=!br&&lr}else if(Yn!==void 0){var Zr=ii&&ii.fixed==="right";Un=!Zr&&lr}}else if(En!==void 0){var Gi=ii&&ii.fixed==="left";Gn=!Gi&&lr}else if(Yn!==void 0){var mr=Oi&&Oi.fixed==="right";Si=!mr&&lr}return{fixLeft:En,fixRight:Yn,lastFixLeft:Gn,firstFixRight:Si,lastFixRight:Un,firstFixLeft:gi,isSticky:xt.isSticky}}var bo=Ie.createContext({}),Ui=bo;function yo(Ue){var ht=Ue.className,pt=Ue.index,xt=Ue.children,Ht=Ue.colSpan,en=Ht===void 0?1:Ht,un=Ue.rowSpan,En=Ue.align,Yn=Pt(Ee,["prefixCls","direction"]),Gn=Yn.prefixCls,Si=Yn.direction,Un=Ie.useContext(Ui),gi=Un.scrollColumnIndex,ii=Un.stickyOffsets,Oi=Un.flattenColumns,lr=pt+en-1,br=lr+1===gi?en+1:en,Zr=co(pt,pt+br-1,Oi,ii,Si);return Ie.createElement(ei,(0,wt.Z)({className:ht,index:pt,component:"td",prefixCls:Gn,record:null,dataIndex:null,align:En,colSpan:br,rowSpan:un,render:function(){return xt}},Zr))}var ha=De(45987),Ka=["children"];function Ra(Ue){var ht=Ue.children,pt=(0,ha.Z)(Ue,Ka);return Ie.createElement("tr",pt,ht)}function ca(Ue){var ht=Ue.children;return ht}ca.Row=Ra,ca.Cell=yo;var ma=ca;function Ho(Ue){var ht=Ue.children,pt=Ue.stickyOffsets,xt=Ue.flattenColumns,Ht=Pt(Ee,"prefixCls"),en=xt.length-1,un=xt[en],En=Ie.useMemo(function(){return{stickyOffsets:pt,flattenColumns:xt,scrollColumnIndex:un!=null&&un.scrollbar?en:null}},[un,xt,en,pt]);return Ie.createElement(Ui.Provider,{value:En},Ie.createElement("tfoot",{className:"".concat(Ht,"-summary")},ht))}var _r=pe(Ho),Fn=ma,we=De(48555),Qn=function(Ue){if(!Ue)return!1;if(Ue instanceof Element){if(Ue.offsetParent)return!0;if(Ue.getBBox){var ht=Ue.getBBox(),pt=ht.width,xt=ht.height;if(pt||xt)return!0}if(Ue.getBoundingClientRect){var Ht=Ue.getBoundingClientRect(),en=Ht.width,un=Ht.height;if(en||un)return!0}}return!1},bn=function(ht){if(Gt()&&window.document.documentElement){var pt=Array.isArray(ht)?ht:[ht],xt=window.document.documentElement;return pt.some(function(Ht){return Ht in xt.style})}return!1},on=function(ht,pt){if(!bn(ht))return!1;var xt=document.createElement("div"),Ht=xt.style[ht];return xt.style[ht]=pt,xt.style[ht]!==Ht};function ln(Ue,ht){return!Array.isArray(Ue)&&ht!==void 0?on(Ue,ht):bn(Ue)}function gn(Ue,ht){if(!Ue)return!1;if(Ue.contains)return Ue.contains(ht);for(var pt=ht;pt;){if(pt===Ue)return!0;pt=pt.parentNode}return!1}var Vn="data-rc-order",_i="data-rc-priority",jt="rc-util-key",zt=new Map;function Ct(){var Ue=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},ht=Ue.mark;return ht?ht.startsWith("data-")?ht:"data-".concat(ht):jt}function Yt(Ue){if(Ue.attachTo)return Ue.attachTo;var ht=document.querySelector("head");return ht||document.body}function ci(Ue){return Ue==="queue"?"prependQueue":Ue?"prepend":"append"}function vi(Ue){return Array.from((zt.get(Ue)||Ue).children).filter(function(ht){return ht.tagName==="STYLE"})}function ai(Ue){var ht=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!Gt())return null;var pt=ht.csp,xt=ht.prepend,Ht=ht.priority,en=Ht===void 0?0:Ht,un=ci(xt),En=un==="prependQueue",Yn=document.createElement("style");Yn.setAttribute(Vn,un),En&&en&&Yn.setAttribute(_i,"".concat(en)),pt!=null&&pt.nonce&&(Yn.nonce=pt==null?void 0:pt.nonce),Yn.innerHTML=Ue;var Gn=Yt(ht),Si=Gn.firstChild;if(xt){if(En){var Un=(ht.styles||vi(Gn)).filter(function(gi){if(!["prepend","prependQueue"].includes(gi.getAttribute(Vn)))return!1;var ii=Number(gi.getAttribute(_i)||0);return en>=ii});if(Un.length)return Gn.insertBefore(Yn,Un[Un.length-1].nextSibling),Yn}Gn.insertBefore(Yn,Si)}else Gn.appendChild(Yn);return Yn}function Kt(Ue){var ht=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},pt=Yt(ht);return(ht.styles||vi(pt)).find(function(xt){return xt.getAttribute(Ct(ht))===Ue})}function wn(Ue){var ht=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},pt=Kt(Ue,ht);if(pt){var xt=Yt(ht);xt.removeChild(pt)}}function pi(Ue,ht){var pt=zt.get(Ue);if(!pt||!gn(document,pt)){var xt=ai("",ht),Ht=xt.parentNode;zt.set(Ue,Ht),Ue.removeChild(xt)}}function ji(){zt.clear()}function Rn(Ue,ht){var pt=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},xt=Yt(pt),Ht=vi(xt),en=(0,it.Z)((0,it.Z)({},pt),{},{styles:Ht});pi(xt,en);var un=Kt(ht,en);if(un){var En,Yn;if((En=en.csp)!==null&&En!==void 0&&En.nonce&&un.nonce!==((Yn=en.csp)===null||Yn===void 0?void 0:Yn.nonce)){var Gn;un.nonce=(Gn=en.csp)===null||Gn===void 0?void 0:Gn.nonce}return un.innerHTML!==Ue&&(un.innerHTML=Ue),un}var Si=ai(Ue,en);return Si.setAttribute(Ct(en),ht),Si}var Dt;function wi(Ue){var ht="rc-scrollbar-measure-".concat(Math.random().toString(36).substring(7)),pt=document.createElement("div");pt.id=ht;var xt=pt.style;xt.position="absolute",xt.left="0",xt.top="0",xt.width="100px",xt.height="100px",xt.overflow="scroll";var Ht,en;if(Ue){var un=getComputedStyle(Ue);xt.scrollbarColor=un.scrollbarColor,xt.scrollbarWidth=un.scrollbarWidth;var En=getComputedStyle(Ue,"::-webkit-scrollbar"),Yn=parseInt(En.width,10),Gn=parseInt(En.height,10);try{var Si=Yn?"width: ".concat(En.width,";"):"",Un=Gn?"height: ".concat(En.height,";"):"";Rn(`
#`.concat(ht,`::-webkit-scrollbar {
`).concat(Si,`
`).concat(Un,`
}`),ht)}catch(Oi){console.error(Oi),Ht=Yn,en=Gn}}document.body.appendChild(pt);var gi=Ue&&Ht&&!isNaN(Ht)?Ht:pt.offsetWidth-pt.clientWidth,ii=Ue&&en&&!isNaN(en)?en:pt.offsetHeight-pt.clientHeight;return document.body.removeChild(pt),wn(ht),{width:gi,height:ii}}function gr(Ue){return typeof document=="undefined"?0:((Ue||Dt===void 0)&&(Dt=wi()),Dt.width)}function eo(Ue){return typeof document=="undefined"||!Ue||!(Ue instanceof Element)?{width:0,height:0}:wi(Ue)}var kn=`accept acceptCharset accessKey action allowFullScreen allowTransparency
alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge
charSet checked classID className colSpan cols content contentEditable contextMenu
controls coords crossOrigin data dateTime default defer dir disabled download draggable
encType form formAction formEncType formMethod formNoValidate formTarget frameBorder
headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity
is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media
mediaGroup method min minLength multiple muted name noValidate nonce open
optimum pattern placeholder poster preload radioGroup readOnly rel required
reversed role rowSpan rows sandbox scope scoped scrolling seamless selected
shape size sizes span spellCheck src srcDoc srcLang srcSet start step style
summary tabIndex target title type useMap value width wmode wrap`,Xi=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown
onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick
onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown
onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel
onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough
onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata
onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,Lo="".concat(kn," ").concat(Xi).split(/[\s\n]+/),La="aria-",$o="data-";function qi(Ue,ht){return Ue.indexOf(ht)===0}function Zi(Ue){var ht=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,pt;ht===!1?pt={aria:!0,data:!0,attr:!0}:ht===!0?pt={aria:!0}:pt=(0,it.Z)({},ht);var xt={};return Object.keys(Ue).forEach(function(Ht){(pt.aria&&(Ht==="role"||qi(Ht,La))||pt.data&&qi(Ht,$o)||pt.attr&&Lo.includes(Ht))&&(xt[Ht]=Ue[Ht])}),xt}function cr(Ue,ht,pt,xt,Ht,en,un){Ue.push({record:ht,indent:pt,index:un});var En=en(ht),Yn=Ht==null?void 0:Ht.has(En);if(ht&&Array.isArray(ht[xt])&&Yn)for(var Gn=0;Gn<ht[xt].length;Gn+=1)cr(Ue,ht[xt][Gn],pt+1,xt,Ht,en,Gn)}function Co(Ue,ht,pt,xt){var Ht=Ie.useMemo(function(){if(pt!=null&&pt.size){for(var en=[],un=0;un<(Ue==null?void 0:Ue.length);un+=1){var En=Ue[un];cr(en,En,0,ht,pt,xt,un)}return en}return Ue==null?void 0:Ue.map(function(Yn,Gn){return{record:Yn,indent:0,index:Gn}})},[Ue,ht,pt,xt]);return Ht}function Zo(Ue,ht,pt,xt){var Ht=Pt(Ee,["prefixCls","fixedInfoList","flattenColumns","expandableType","expandRowByClick","onTriggerExpand","rowClassName","expandedRowClassName","indentSize","expandIcon","expandedRowRender","expandIconColumnIndex","expandedKeys","childrenColumnName","rowExpandable","onRow"]),en=Ht.flattenColumns,un=Ht.expandableType,En=Ht.expandedKeys,Yn=Ht.childrenColumnName,Gn=Ht.onTriggerExpand,Si=Ht.rowExpandable,Un=Ht.onRow,gi=Ht.expandRowByClick,ii=Ht.rowClassName,Oi=un==="nest",lr=un==="row"&&(!Si||Si(Ue)),br=lr||Oi,Zr=En&&En.has(ht),Gi=Yn&&Ue&&Ue[Yn],mr=ft(Gn),er=Un==null?void 0:Un(Ue,pt),Yr=er==null?void 0:er.onClick,No=function(la){gi&&br&&Gn(Ue,la);for(var ys=arguments.length,Da=new Array(ys>1?ys-1:0),Te=1;Te<ys;Te++)Da[Te-1]=arguments[Te];Yr==null||Yr.apply(void 0,[la].concat(Da))},Wr;typeof ii=="string"?Wr=ii:typeof ii=="function"&&(Wr=ii(Ue,pt,xt));var da=Wt(en);return(0,it.Z)((0,it.Z)({},Ht),{},{columnsKey:da,nestExpandable:Oi,expanded:Zr,hasNestChildren:Gi,record:Ue,onTriggerExpand:mr,rowSupportExpand:lr,expandable:br,rowProps:(0,it.Z)((0,it.Z)({},er),{},{className:Ft()(Wr,er==null?void 0:er.className),onClick:No})})}function ri(Ue){var ht=Ue.prefixCls,pt=Ue.children,xt=Ue.component,Ht=Ue.cellComponent,en=Ue.className,un=Ue.expanded,En=Ue.colSpan,Yn=Ue.isEmpty,Gn=Pt(Ee,["scrollbarSize","fixHeader","fixColumn","componentWidth","horizonScroll"]),Si=Gn.scrollbarSize,Un=Gn.fixHeader,gi=Gn.fixColumn,ii=Gn.componentWidth,Oi=Gn.horizonScroll,lr=pt;return(Yn?Oi&&ii:gi)&&(lr=Ie.createElement("div",{style:{width:ii-(Un&&!Yn?Si:0),position:"sticky",left:0,overflow:"hidden"},className:"".concat(ht,"-expanded-row-fixed")},lr)),Ie.createElement(xt,{className:en,style:{display:un?null:"none"}},Ie.createElement(ei,{component:Ht,prefixCls:ht,colSpan:En},lr))}var Lr=ri;function ml(Ue){var ht=Ue.prefixCls,pt=Ue.record,xt=Ue.onExpand,Ht=Ue.expanded,en=Ue.expandable,un="".concat(ht,"-row-expand-icon");if(!en)return Ie.createElement("span",{className:Ft()(un,"".concat(ht,"-row-spaced"))});var En=function(Gn){xt(pt,Gn),Gn.stopPropagation()};return Ie.createElement("span",{className:Ft()(un,(0,Nt.Z)((0,Nt.Z)({},"".concat(ht,"-row-expanded"),Ht),"".concat(ht,"-row-collapsed"),!Ht)),onClick:En})}function Fs(Ue,ht,pt){var xt=[];function Ht(en){(en||[]).forEach(function(un,En){xt.push(ht(un,En)),Ht(un[pt])})}return Ht(Ue),xt}function gs(Ue,ht,pt,xt){return typeof Ue=="string"?Ue:typeof Ue=="function"?Ue(ht,pt,xt):""}function Vt(Ue,ht,pt,xt,Ht){var en=Ue.record,un=Ue.prefixCls,En=Ue.columnsKey,Yn=Ue.fixedInfoList,Gn=Ue.expandIconColumnIndex,Si=Ue.nestExpandable,Un=Ue.indentSize,gi=Ue.expandIcon,ii=Ue.expanded,Oi=Ue.hasNestChildren,lr=Ue.onTriggerExpand,br=En[pt],Zr=Yn[pt],Gi;pt===(Gn||0)&&Si&&(Gi=Ie.createElement(Ie.Fragment,null,Ie.createElement("span",{style:{paddingLeft:"".concat(Un*xt,"px")},className:"".concat(un,"-row-indent indent-level-").concat(xt)}),gi({prefixCls:un,expanded:ii,expandable:Oi,record:en,onExpand:lr})));var mr;return ht.onCell&&(mr=ht.onCell(en,Ht)),{key:br,fixedInfo:Zr,appendCellNode:Gi,additionalCellProps:mr||{}}}function Kr(Ue){var ht=Ue.className,pt=Ue.style,xt=Ue.record,Ht=Ue.index,en=Ue.renderIndex,un=Ue.rowKey,En=Ue.indent,Yn=En===void 0?0:En,Gn=Ue.rowComponent,Si=Ue.cellComponent,Un=Ue.scopeCellComponent,gi=Zo(xt,un,Ht,Yn),ii=gi.prefixCls,Oi=gi.flattenColumns,lr=gi.expandedRowClassName,br=gi.expandedRowRender,Zr=gi.rowProps,Gi=gi.expanded,mr=gi.rowSupportExpand,er=Ie.useRef(!1);er.current||(er.current=Gi);var Yr=gs(lr,xt,Ht,Yn),No=Ie.createElement(Gn,(0,wt.Z)({},Zr,{"data-row-key":un,className:Ft()(ht,"".concat(ii,"-row"),"".concat(ii,"-row-level-").concat(Yn),Zr==null?void 0:Zr.className,(0,Nt.Z)({},Yr,Yn>=1)),style:(0,it.Z)((0,it.Z)({},pt),Zr==null?void 0:Zr.style)}),Oi.map(function(To,la){var ys=To.render,Da=To.dataIndex,Te=To.className,Oe=Vt(gi,To,la,Yn,Ht),Xe=Oe.key,ot=Oe.fixedInfo,Rt=Oe.appendCellNode,Se=Oe.additionalCellProps;return Ie.createElement(ei,(0,wt.Z)({className:Te,ellipsis:To.ellipsis,align:To.align,scope:To.rowScope,component:To.rowScope?Un:Si,prefixCls:ii,key:Xe,record:xt,index:Ht,renderIndex:en,dataIndex:Da,render:ys,shouldCellUpdate:To.shouldCellUpdate},ot,{appendNode:Rt,additionalProps:Se}))})),Wr;if(mr&&(er.current||Gi)){var da=br(xt,Ht,Yn+1,Gi);Wr=Ie.createElement(Lr,{expanded:Gi,className:Ft()("".concat(ii,"-expanded-row"),"".concat(ii,"-expanded-row-level-").concat(Yn+1),Yr),prefixCls:ii,component:Gn,cellComponent:Si,colSpan:Oi.length,isEmpty:!1},da)}return Ie.createElement(Ie.Fragment,null,No,Wr)}var Ko=pe(Kr);function Er(Ue){var ht=Ue.columnKey,pt=Ue.onColumnResize,xt=Ie.useRef();return Ie.useEffect(function(){xt.current&&pt(ht,xt.current.offsetWidth)},[]),Ie.createElement(we.Z,{data:ht},Ie.createElement("td",{ref:xt,style:{padding:0,border:0,height:0}},Ie.createElement("div",{style:{height:0,overflow:"hidden"}},"\xA0")))}function Wa(Ue){var ht=Ue.prefixCls,pt=Ue.columnsKey,xt=Ue.onColumnResize;return Ie.createElement("tr",{"aria-hidden":"true",className:"".concat(ht,"-measure-row"),style:{height:0,fontSize:0}},Ie.createElement(we.Z.Collection,{onBatchResize:function(en){en.forEach(function(un){var En=un.data,Yn=un.size;xt(En,Yn.offsetWidth)})}},pt.map(function(Ht){return Ie.createElement(Er,{key:Ht,columnKey:Ht,onColumnResize:xt})})))}function Wo(Ue){var ht=Ue.data,pt=Ue.measureColumnWidth,xt=Pt(Ee,["prefixCls","getComponent","onColumnResize","flattenColumns","getRowKey","expandedKeys","childrenColumnName","emptyNode"]),Ht=xt.prefixCls,en=xt.getComponent,un=xt.onColumnResize,En=xt.flattenColumns,Yn=xt.getRowKey,Gn=xt.expandedKeys,Si=xt.childrenColumnName,Un=xt.emptyNode,gi=Co(ht,Si,Gn,Yn),ii=Ie.useRef({renderWithProps:!1}),Oi=en(["body","wrapper"],"tbody"),lr=en(["body","row"],"tr"),br=en(["body","cell"],"td"),Zr=en(["body","cell"],"th"),Gi;ht.length?Gi=gi.map(function(er,Yr){var No=er.record,Wr=er.indent,da=er.index,To=Yn(No,Yr);return Ie.createElement(Ko,{key:To,rowKey:To,record:No,index:Yr,renderIndex:da,rowComponent:lr,cellComponent:br,scopeCellComponent:Zr,indent:Wr})}):Gi=Ie.createElement(Lr,{expanded:!0,className:"".concat(Ht,"-placeholder"),prefixCls:Ht,component:lr,cellComponent:br,colSpan:En.length,isEmpty:!0},Un);var mr=Wt(En);return Ie.createElement(nt.Provider,{value:ii.current},Ie.createElement(Oi,{className:"".concat(Ht,"-tbody")},pt&&Ie.createElement(Wa,{prefixCls:Ht,columnsKey:mr,onColumnResize:un}),Gi))}var ea=pe(Wo),fo=De(62978),Oo=["columnType"];function xa(Ue){for(var ht=Ue.colWidths,pt=Ue.columns,xt=Ue.columCount,Ht=Pt(Ee,["tableLayout"]),en=Ht.tableLayout,un=[],En=xt||pt.length,Yn=!1,Gn=En-1;Gn>=0;Gn-=1){var Si=ht[Gn],Un=pt&&pt[Gn],gi=void 0,ii=void 0;if(Un&&(gi=Un[fo.v],en==="auto"&&(ii=Un.minWidth)),Si||ii||gi||Yn){var Oi=gi||{},lr=Oi.columnType,br=(0,ha.Z)(Oi,Oo);un.unshift(Ie.createElement("col",(0,wt.Z)({key:Gn,style:{width:Si,minWidth:ii}},br))),Yn=!0}}return Ie.createElement("colgroup",null,un)}var An=xa,Ya=De(74902),Pn=["className","noData","columns","flattenColumns","colWidths","columCount","stickyOffsets","direction","fixHeader","stickyTopOffset","stickyBottomOffset","stickyClassName","onScroll","maxContentScroll","children"];function jo(Ue,ht){return(0,Ie.useMemo)(function(){for(var pt=[],xt=0;xt<ht;xt+=1){var Ht=Ue[xt];if(Ht!==void 0)pt[xt]=Ht;else return null}return pt},[Ue.join("_"),ht])}var Ws=Ie.forwardRef(function(Ue,ht){var pt=Ue.className,xt=Ue.noData,Ht=Ue.columns,en=Ue.flattenColumns,un=Ue.colWidths,En=Ue.columCount,Yn=Ue.stickyOffsets,Gn=Ue.direction,Si=Ue.fixHeader,Un=Ue.stickyTopOffset,gi=Ue.stickyBottomOffset,ii=Ue.stickyClassName,Oi=Ue.onScroll,lr=Ue.maxContentScroll,br=Ue.children,Zr=(0,ha.Z)(Ue,Pn),Gi=Pt(Ee,["prefixCls","scrollbarSize","isSticky","getComponent"]),mr=Gi.prefixCls,er=Gi.scrollbarSize,Yr=Gi.isSticky,No=Gi.getComponent,Wr=No(["header","table"],"table"),da=Yr&&!Si?0:er,To=Ie.useRef(null),la=Ie.useCallback(function(Se){ui(ht,Se),ui(To,Se)},[]);Ie.useEffect(function(){var Se;function Le(je){var Ke=je,ct=Ke.currentTarget,Et=Ke.deltaX;Et&&(Oi({currentTarget:ct,scrollLeft:ct.scrollLeft+Et}),je.preventDefault())}return(Se=To.current)===null||Se===void 0||Se.addEventListener("wheel",Le,{passive:!1}),function(){var je;(je=To.current)===null||je===void 0||je.removeEventListener("wheel",Le)}},[]);var ys=Ie.useMemo(function(){return en.every(function(Se){return Se.width})},[en]),Da=en[en.length-1],Te={fixed:Da?Da.fixed:null,scrollbar:!0,onHeaderCell:function(){return{className:"".concat(mr,"-cell-scrollbar")}}},Oe=(0,Ie.useMemo)(function(){return da?[].concat((0,Ya.Z)(Ht),[Te]):Ht},[da,Ht]),Xe=(0,Ie.useMemo)(function(){return da?[].concat((0,Ya.Z)(en),[Te]):en},[da,en]),ot=(0,Ie.useMemo)(function(){var Se=Yn.right,Le=Yn.left;return(0,it.Z)((0,it.Z)({},Yn),{},{left:Gn==="rtl"?[].concat((0,Ya.Z)(Le.map(function(je){return je+da})),[0]):Le,right:Gn==="rtl"?Se:[].concat((0,Ya.Z)(Se.map(function(je){return je+da})),[0]),isSticky:Yr})},[da,Yn,Yr]),Rt=jo(un,En);return Ie.createElement("div",{style:(0,it.Z)({overflow:"hidden"},Yr?{top:Un,bottom:gi}:{}),ref:la,className:Ft()(pt,(0,Nt.Z)({},ii,!!ii))},Ie.createElement(Wr,{style:{tableLayout:"fixed",visibility:xt||Rt?null:"hidden"}},(!xt||!lr||ys)&&Ie.createElement(An,{colWidths:Rt?[].concat((0,Ya.Z)(Rt),[da]):[],columCount:En+1,columns:Xe}),br((0,it.Z)((0,it.Z)({},Zr),{},{stickyOffsets:ot,columns:Oe,flattenColumns:Xe}))))}),qa=Ie.memo(Ws),bl=function(ht){var pt=ht.cells,xt=ht.stickyOffsets,Ht=ht.flattenColumns,en=ht.rowComponent,un=ht.cellComponent,En=ht.onHeaderRow,Yn=ht.index,Gn=Pt(Ee,["prefixCls","direction"]),Si=Gn.prefixCls,Un=Gn.direction,gi;En&&(gi=En(pt.map(function(Oi){return Oi.column}),Yn));var ii=Wt(pt.map(function(Oi){return Oi.column}));return Ie.createElement(en,gi,pt.map(function(Oi,lr){var br=Oi.column,Zr=co(Oi.colStart,Oi.colEnd,Ht,xt,Un),Gi;return br&&br.onHeaderCell&&(Gi=Oi.column.onHeaderCell(br)),Ie.createElement(ei,(0,wt.Z)({},Oi,{scope:br.title?Oi.colSpan>1?"colgroup":"col":null,ellipsis:br.ellipsis,align:br.align,component:un,prefixCls:Si,key:ii[lr]},Zr,{additionalProps:Gi,rowType:"header"}))}))},Xa=bl;function _o(Ue){var ht=[];function pt(un,En){var Yn=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;ht[Yn]=ht[Yn]||[];var Gn=En,Si=un.filter(Boolean).map(function(Un){var gi={key:Un.key,className:Un.className||"",children:Un.title,column:Un,colStart:Gn},ii=1,Oi=Un.children;return Oi&&Oi.length>0&&(ii=pt(Oi,Gn,Yn+1).reduce(function(lr,br){return lr+br},0),gi.hasSubColumns=!0),"colSpan"in Un&&(ii=Un.colSpan),"rowSpan"in Un&&(gi.rowSpan=Un.rowSpan),gi.colSpan=ii,gi.colEnd=gi.colStart+ii-1,ht[Yn].push(gi),Gn+=ii,ii});return Si}pt(Ue,0);for(var xt=ht.length,Ht=function(En){ht[En].forEach(function(Yn){!("rowSpan"in Yn)&&!Yn.hasSubColumns&&(Yn.rowSpan=xt-En)})},en=0;en<xt;en+=1)Ht(en);return ht}var Va=function(ht){var pt=ht.stickyOffsets,xt=ht.columns,Ht=ht.flattenColumns,en=ht.onHeaderRow,un=Pt(Ee,["prefixCls","getComponent"]),En=un.prefixCls,Yn=un.getComponent,Gn=Ie.useMemo(function(){return _o(xt)},[xt]),Si=Yn(["header","wrapper"],"thead"),Un=Yn(["header","row"],"tr"),gi=Yn(["header","cell"],"th");return Ie.createElement(Si,{className:"".concat(En,"-thead")},Gn.map(function(ii,Oi){var lr=Ie.createElement(Xa,{key:Oi,flattenColumns:Ht,cells:ii,stickyOffsets:pt,rowComponent:Un,cellComponent:gi,onHeaderRow:en,index:Oi});return lr}))},il=pe(Va),Na=De(54768);function Li(Ue,ht,pt){var xt=(0,fo.g)(Ue),Ht=xt.expandIcon,en=xt.expandedRowKeys,un=xt.defaultExpandedRowKeys,En=xt.defaultExpandAllRows,Yn=xt.expandedRowRender,Gn=xt.onExpand,Si=xt.onExpandedRowsChange,Un=xt.childrenColumnName,gi=Ht||ml,ii=Un||"children",Oi=Ie.useMemo(function(){return Yn?"row":Ue.expandable&&Ue.internalHooks===Ne.R&&Ue.expandable.__PARENT_RENDER_ICON__||ht.some(function(Yr){return Yr&&(0,st.Z)(Yr)==="object"&&Yr[ii]})?"nest":!1},[!!Yn,ht]),lr=Ie.useState(function(){return un||(En?Fs(ht,pt,ii):[])}),br=(0,dt.Z)(lr,2),Zr=br[0],Gi=br[1],mr=Ie.useMemo(function(){return new Set(en||Zr||[])},[en,Zr]),er=Ie.useCallback(function(Yr){var No=pt(Yr,ht.indexOf(Yr)),Wr,da=mr.has(No);da?(mr.delete(No),Wr=(0,Ya.Z)(mr)):Wr=[].concat((0,Ya.Z)(mr),[No]),Gi(Wr),Gn&&Gn(!da,Yr),Si&&Si(Wr)},[pt,mr,ht,Gn,Si]);return[xt,Oi,mr,gi,ii,er]}function Qe(Ue,ht,pt){var xt=Ue.map(function(Ht,en){return co(en,en,Ue,ht,pt)});return cn(function(){return xt},[xt],function(Ht,en){return!di(Ht,en)})}function bs(Ue){var ht=(0,Ie.useRef)(Ue),pt=(0,Ie.useState)({}),xt=(0,dt.Z)(pt,2),Ht=xt[1],en=(0,Ie.useRef)(null),un=(0,Ie.useRef)([]);function En(Yn){un.current.push(Yn);var Gn=Promise.resolve();en.current=Gn,Gn.then(function(){if(en.current===Gn){var Si=un.current,Un=ht.current;un.current=[],Si.forEach(function(gi){ht.current=gi(ht.current)}),en.current=null,Un!==ht.current&&Ht({})}})}return(0,Ie.useEffect)(function(){return function(){en.current=null}},[]),[ht.current,En]}function Ul(Ue){var ht=(0,Ie.useRef)(Ue||null),pt=(0,Ie.useRef)();function xt(){window.clearTimeout(pt.current)}function Ht(un){ht.current=un,xt(),pt.current=window.setTimeout(function(){ht.current=null,pt.current=void 0},100)}function en(){return ht.current}return(0,Ie.useEffect)(function(){return xt},[]),[Ht,en]}function Zl(){var Ue=Ie.useState(-1),ht=(0,dt.Z)(Ue,2),pt=ht[0],xt=ht[1],Ht=Ie.useState(-1),en=(0,dt.Z)(Ht,2),un=en[0],En=en[1],Yn=Ie.useCallback(function(Gn,Si){xt(Gn),En(Si)},[]);return[pt,un,Yn]}var rl=Gt()?window:null;function tu(Ue,ht){var pt=(0,st.Z)(Ue)==="object"?Ue:{},xt=pt.offsetHeader,Ht=xt===void 0?0:xt,en=pt.offsetSummary,un=en===void 0?0:en,En=pt.offsetScroll,Yn=En===void 0?0:En,Gn=pt.getContainer,Si=Gn===void 0?function(){return rl}:Gn,Un=Si()||rl,gi=!!Ue;return Ie.useMemo(function(){return{isSticky:gi,stickyClassName:gi?"".concat(ht,"-sticky-holder"):"",offsetHeader:Ht,offsetSummary:un,offsetScroll:Yn,container:Un}},[gi,Yn,Ht,un,ht,Un])}function Il(Ue,ht,pt){var xt=(0,Ie.useMemo)(function(){var Ht=ht.length,en=function(Gn,Si,Un){for(var gi=[],ii=0,Oi=Gn;Oi!==Si;Oi+=Un)gi.push(ii),ht[Oi].fixed&&(ii+=Ue[Oi]||0);return gi},un=en(0,Ht,1),En=en(Ht-1,-1,-1).reverse();return pt==="rtl"?{left:En,right:un}:{left:un,right:En}},[Ue,ht,pt]);return xt}var Hu=Il;function nu(Ue){var ht=Ue.className,pt=Ue.children;return Ie.createElement("div",{className:ht},pt)}var Ua=nu;function ps(Ue,ht,pt,xt){var Ht=$e.unstable_batchedUpdates?function(un){$e.unstable_batchedUpdates(pt,un)}:pt;return Ue!=null&&Ue.addEventListener&&Ue.addEventListener(ht,Ht,xt),{remove:function(){Ue!=null&&Ue.removeEventListener&&Ue.removeEventListener(ht,Ht,xt)}}}var Or=function(ht){return+setTimeout(ht,16)},Pr=function(ht){return clearTimeout(ht)};typeof window!="undefined"&&"requestAnimationFrame"in window&&(Or=function(ht){return window.requestAnimationFrame(ht)},Pr=function(ht){return window.cancelAnimationFrame(ht)});var so=0,fn=new Map;function jr(Ue){fn.delete(Ue)}var Ao=function(ht){var pt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;so+=1;var xt=so;function Ht(en){if(en===0)jr(xt),ht();else{var un=Or(function(){Ht(en-1)});fn.set(xt,un)}}return Ht(pt),xt};Ao.cancel=function(Ue){var ht=fn.get(Ue);return jr(Ue),Pr(ht)};var $a=Ao;function Ia(Ue){return Ue instanceof HTMLElement||Ue instanceof SVGElement}function ms(Ue){return Ue&&(0,st.Z)(Ue)==="object"&&Ia(Ue.nativeElement)?Ue.nativeElement:Ia(Ue)?Ue:null}function Vs(Ue){var ht=ms(Ue);if(ht)return ht;if(Ue instanceof React.Component){var pt;return(pt=ReactDOM.findDOMNode)===null||pt===void 0?void 0:pt.call(ReactDOM,Ue)}return null}function el(Ue){var ht=ms(Ue),pt=ht.getBoundingClientRect(),xt=document.documentElement;return{left:pt.left+(window.pageXOffset||xt.scrollLeft)-(xt.clientLeft||document.body.clientLeft||0),top:pt.top+(window.pageYOffset||xt.scrollTop)-(xt.clientTop||document.body.clientTop||0)}}var vl=function(ht,pt){var xt,Ht,en=ht.scrollBodyRef,un=ht.onScroll,En=ht.offsetScroll,Yn=ht.container,Gn=ht.direction,Si=Pt(Ee,"prefixCls"),Un=((xt=en.current)===null||xt===void 0?void 0:xt.scrollWidth)||0,gi=((Ht=en.current)===null||Ht===void 0?void 0:Ht.clientWidth)||0,ii=Un&&gi*(gi/Un),Oi=Ie.useRef(),lr=bs({scrollLeft:0,isHiddenScrollBar:!0}),br=(0,dt.Z)(lr,2),Zr=br[0],Gi=br[1],mr=Ie.useRef({delta:0,x:0}),er=Ie.useState(!1),Yr=(0,dt.Z)(er,2),No=Yr[0],Wr=Yr[1],da=Ie.useRef(null);Ie.useEffect(function(){return function(){$a.cancel(da.current)}},[]);var To=function(){Wr(!1)},la=function(Xe){Xe.persist(),mr.current.delta=Xe.pageX-Zr.scrollLeft,mr.current.x=0,Wr(!0),Xe.preventDefault()},ys=function(Xe){var ot,Rt=Xe||((ot=window)===null||ot===void 0?void 0:ot.event),Se=Rt.buttons;if(!No||Se===0){No&&Wr(!1);return}var Le=mr.current.x+Xe.pageX-mr.current.x-mr.current.delta,je=Gn==="rtl";Le=Math.max(je?ii-gi:0,Math.min(je?0:gi-ii,Le));var Ke=!je||Math.abs(Le)+Math.abs(ii)<gi;Ke&&(un({scrollLeft:Le/gi*(Un+2)}),mr.current.x=Xe.pageX)},Da=function(){$a.cancel(da.current),da.current=$a(function(){if(en.current){var Xe=el(en.current).top,ot=Xe+en.current.offsetHeight,Rt=Yn===window?document.documentElement.scrollTop+window.innerHeight:el(Yn).top+Yn.clientHeight;ot-gr()<=Rt||Xe>=Rt-En?Gi(function(Se){return(0,it.Z)((0,it.Z)({},Se),{},{isHiddenScrollBar:!0})}):Gi(function(Se){return(0,it.Z)((0,it.Z)({},Se),{},{isHiddenScrollBar:!1})})}})},Te=function(Xe){Gi(function(ot){return(0,it.Z)((0,it.Z)({},ot),{},{scrollLeft:Xe/Un*gi||0})})};return Ie.useImperativeHandle(pt,function(){return{setScrollLeft:Te,checkScrollBarVisible:Da}}),Ie.useEffect(function(){var Oe=ps(document.body,"mouseup",To,!1),Xe=ps(document.body,"mousemove",ys,!1);return Da(),function(){Oe.remove(),Xe.remove()}},[ii,No]),Ie.useEffect(function(){if(en.current){for(var Oe=[],Xe=ms(en.current);Xe;)Oe.push(Xe),Xe=Xe.parentElement;return Oe.forEach(function(ot){return ot.addEventListener("scroll",Da,!1)}),window.addEventListener("resize",Da,!1),window.addEventListener("scroll",Da,!1),Yn.addEventListener("scroll",Da,!1),function(){Oe.forEach(function(ot){return ot.removeEventListener("scroll",Da)}),window.removeEventListener("resize",Da),window.removeEventListener("scroll",Da),Yn.removeEventListener("scroll",Da)}}},[Yn]),Ie.useEffect(function(){Zr.isHiddenScrollBar||Gi(function(Oe){var Xe=en.current;return Xe?(0,it.Z)((0,it.Z)({},Oe),{},{scrollLeft:Xe.scrollLeft/Xe.scrollWidth*Xe.clientWidth}):Oe})},[Zr.isHiddenScrollBar]),Un<=gi||!ii||Zr.isHiddenScrollBar?null:Ie.createElement("div",{style:{height:gr(),width:gi,bottom:En},className:"".concat(Si,"-sticky-scroll")},Ie.createElement("div",{onMouseDown:la,ref:Oi,className:Ft()("".concat(Si,"-sticky-scroll-bar"),(0,Nt.Z)({},"".concat(Si,"-sticky-scroll-bar-active"),No)),style:{width:"".concat(ii,"px"),transform:"translate3d(".concat(Zr.scrollLeft,"px, 0, 0)")}}))},Gu=Ie.forwardRef(vl);function Fu(Ue){return null}var Xt=Fu;function Ll(Ue){return null}var zl=Ll,fu="rc-table",As=[],gu={};function xh(){return"No Data"}function Xu(Ue,ht){var pt=(0,it.Z)({rowKey:"key",prefixCls:fu,emptyText:xh},Ue),xt=pt.prefixCls,Ht=pt.className,en=pt.rowClassName,un=pt.style,En=pt.data,Yn=pt.rowKey,Gn=pt.scroll,Si=pt.tableLayout,Un=pt.direction,gi=pt.title,ii=pt.footer,Oi=pt.summary,lr=pt.caption,br=pt.id,Zr=pt.showHeader,Gi=pt.components,mr=pt.emptyText,er=pt.onRow,Yr=pt.onHeaderRow,No=pt.onScroll,Wr=pt.internalHooks,da=pt.transformColumns,To=pt.internalRefs,la=pt.tailor,ys=pt.getContainerWidth,Da=pt.sticky,Te=pt.rowHoverable,Oe=Te===void 0?!0:Te,Xe=En||As,ot=!!Xe.length,Rt=Wr===Ne.R,Se=Ie.useCallback(function(oo,Ur){return zn(Gi,oo)||Ur},[Gi]),Le=Ie.useMemo(function(){return typeof Yn=="function"?Yn:function(oo){var Ur=oo&&oo[Yn];return Ur}},[Yn]),je=Se(["body"]),Ke=Zl(),ct=(0,dt.Z)(Ke,3),Et=ct[0],Bt=ct[1],hn=ct[2],qt=Li(pt,Xe,Le),nn=(0,dt.Z)(qt,6),Sn=nn[0],yn=nn[1],Jn=nn[2],In=nn[3],Mn=nn[4],Kn=nn[5],ni=Gn==null?void 0:Gn.x,yi=Ie.useState(0),$i=(0,dt.Z)(yi,2),Ai=$i[0],bi=$i[1],dr=(0,Na.Z)((0,it.Z)((0,it.Z)((0,it.Z)({},pt),Sn),{},{expandable:!!Sn.expandedRowRender,columnTitle:Sn.columnTitle,expandedKeys:Jn,getRowKey:Le,onTriggerExpand:Kn,expandIcon:In,expandIconColumnIndex:Sn.expandIconColumnIndex,direction:Un,scrollWidth:Rt&&la&&typeof ni=="number"?ni:null,clientWidth:Ai}),Rt?da:null),Wn=(0,dt.Z)(dr,4),Ji=Wn[0],Pi=Wn[1],tr=Wn[2],ar=Wn[3],ki=tr!=null?tr:ni,Fr=Ie.useMemo(function(){return{columns:Ji,flattenColumns:Pi}},[Ji,Pi]),hr=Ie.useRef(),Mr=Ie.useRef(),Ti=Ie.useRef(),pr=Ie.useRef();Ie.useImperativeHandle(ht,function(){return{nativeElement:hr.current,scrollTo:function(Ur){var hs;if(Ti.current instanceof HTMLElement){var ul=Ur.index,nl=Ur.top,hl=Ur.key;if(Lt(nl)){var Os;(Os=Ti.current)===null||Os===void 0||Os.scrollTo({top:nl})}else{var Xl,Ps=hl!=null?hl:Le(Xe[ul]);(Xl=Ti.current.querySelector('[data-row-key="'.concat(Ps,'"]')))===null||Xl===void 0||Xl.scrollIntoView()}}else(hs=Ti.current)!==null&&hs!==void 0&&hs.scrollTo&&Ti.current.scrollTo(Ur)}}});var qr=Ie.useRef(),Po=Ie.useState(!1),no=(0,dt.Z)(Po,2),Qi=no[0],zr=no[1],$r=Ie.useState(!1),lo=(0,dt.Z)($r,2),Uo=lo[0],So=lo[1],Ar=bs(new Map),ur=(0,dt.Z)(Ar,2),Vr=ur[0],Do=ur[1],Nr=Wt(Pi),Wi=Nr.map(function(oo){return Vr.get(oo)}),ir=Ie.useMemo(function(){return Wi},[Wi.join("_")]),rr=Hu(ir,Pi,Un),Fi=Gn&&On(Gn.y),zi=Gn&&On(ki)||!!Sn.fixed,Sr=zi&&Pi.some(function(oo){var Ur=oo.fixed;return Ur}),io=Ie.useRef(),Xr=tu(Da,xt),Ir=Xr.isSticky,wa=Xr.offsetHeader,ra=Xr.offsetSummary,Xo=Xr.offsetScroll,pa=Xr.stickyClassName,ro=Xr.container,Jo=Ie.useMemo(function(){return Oi==null?void 0:Oi(Xe)},[Oi,Xe]),va=(Fi||Ir)&&Ie.isValidElement(Jo)&&Jo.type===ma&&Jo.props.fixed,ds,Pa,Ba;Fi&&(Pa={overflowY:ot?"scroll":"auto",maxHeight:Gn.y}),zi&&(ds={overflowX:"auto"},Fi||(Pa={overflowY:"hidden"}),Ba={width:ki===!0?"auto":ki,minWidth:"100%"});var Bo=Ie.useCallback(function(oo,Ur){Qn(hr.current)&&Do(function(hs){if(hs.get(oo)!==Ur){var ul=new Map(hs);return ul.set(oo,Ur),ul}return hs})},[]),Za=Ul(null),Fa=(0,dt.Z)(Za,2),ns=Fa[0],Vi=Fa[1];function Ki(oo,Ur){Ur&&(typeof Ur=="function"?Ur(oo):Ur.scrollLeft!==oo&&(Ur.scrollLeft=oo,Ur.scrollLeft!==oo&&setTimeout(function(){Ur.scrollLeft=oo},0)))}var or=ft(function(oo){var Ur=oo.currentTarget,hs=oo.scrollLeft,ul=Un==="rtl",nl=typeof hs=="number"?hs:Ur.scrollLeft,hl=Ur||gu;if(!Vi()||Vi()===hl){var Os;ns(hl),Ki(nl,Mr.current),Ki(nl,Ti.current),Ki(nl,qr.current),Ki(nl,(Os=io.current)===null||Os===void 0?void 0:Os.setScrollLeft)}var Xl=Ur||Mr.current;if(Xl){var Ps=Rt&&la&&typeof ki=="number"?ki:Xl.scrollWidth,Ol=Xl.clientWidth;if(Ps===Ol){zr(!1),So(!1);return}ul?(zr(-nl<Ps-Ol),So(-nl>0)):(zr(nl>0),So(nl<Ps-Ol))}}),Jr=ft(function(oo){or(oo),No==null||No(oo)}),ta=function(){if(zi&&Ti.current){var Ur;or({currentTarget:ms(Ti.current),scrollLeft:(Ur=Ti.current)===null||Ur===void 0?void 0:Ur.scrollLeft})}else zr(!1),So(!1)},Ha=function(Ur){var hs,ul=Ur.width;(hs=io.current)===null||hs===void 0||hs.checkScrollBarVisible();var nl=hr.current?hr.current.offsetWidth:ul;Rt&&ys&&hr.current&&(nl=ys(hr.current,nl)||nl),nl!==Ai&&(ta(),bi(nl))},ls=Ie.useRef(!1);Ie.useEffect(function(){ls.current&&ta()},[zi,En,Ji.length]),Ie.useEffect(function(){ls.current=!0},[]);var bt=Ie.useState(0),xo=(0,dt.Z)(bt,2),zo=xo[0],na=xo[1],js=Ie.useState(!0),us=(0,dt.Z)(js,2),Hi=us[0],Tr=us[1];Ie.useEffect(function(){(!la||!Rt)&&(Ti.current instanceof Element?na(eo(Ti.current).width):na(eo(pr.current).width)),Tr(ln("position","sticky"))},[]),Ie.useEffect(function(){Rt&&To&&(To.body.current=Ti.current)});var nr=Ie.useCallback(function(oo){return Ie.createElement(Ie.Fragment,null,Ie.createElement(il,oo),va==="top"&&Ie.createElement(_r,oo,Jo))},[va,Jo]),ho=Ie.useCallback(function(oo){return Ie.createElement(_r,oo,Jo)},[Jo]),Ca=Se(["table"],"table"),Rr=Ie.useMemo(function(){return Si||(Sr?ki==="max-content"?"auto":"fixed":Fi||Ir||Pi.some(function(oo){var Ur=oo.ellipsis;return Ur})?"fixed":"auto")},[Fi,Sr,Pi,Si,Ir]),Qo,Eo={colWidths:ir,columCount:Pi.length,stickyOffsets:rr,onHeaderRow:Yr,fixHeader:Fi,scroll:Gn},Go=Ie.useMemo(function(){return ot?null:typeof mr=="function"?mr():mr},[ot,mr]),fa=Ie.createElement(ea,{data:Xe,measureColumnWidth:Fi||zi||Ir}),Aa=Ie.createElement(An,{colWidths:Pi.map(function(oo){var Ur=oo.width;return Ur}),columns:Pi}),ll=lr!=null?Ie.createElement("caption",{className:"".concat(xt,"-caption")},lr):void 0,Yl=Zi(pt,{data:!0}),ya=Zi(pt,{aria:!0});if(Fi||Ir){var Yo;typeof je=="function"?(Yo=je(Xe,{scrollbarSize:zo,ref:Ti,onScroll:or}),Eo.colWidths=Pi.map(function(oo,Ur){var hs=oo.width,ul=Ur===Pi.length-1?hs-zo:hs;return typeof ul=="number"&&!Number.isNaN(ul)?ul:0})):Yo=Ie.createElement("div",{style:(0,it.Z)((0,it.Z)({},ds),Pa),onScroll:Jr,ref:Ti,className:Ft()("".concat(xt,"-body"))},Ie.createElement(Ca,(0,wt.Z)({style:(0,it.Z)((0,it.Z)({},Ba),{},{tableLayout:Rr})},ya),ll,Aa,fa,!va&&Jo&&Ie.createElement(_r,{stickyOffsets:rr,flattenColumns:Pi},Jo)));var Sa=(0,it.Z)((0,it.Z)((0,it.Z)({noData:!Xe.length,maxContentScroll:zi&&ki==="max-content"},Eo),Fr),{},{direction:Un,stickyClassName:pa,onScroll:or});Qo=Ie.createElement(Ie.Fragment,null,Zr!==!1&&Ie.createElement(qa,(0,wt.Z)({},Sa,{stickyTopOffset:wa,className:"".concat(xt,"-header"),ref:Mr}),nr),Yo,va&&va!=="top"&&Ie.createElement(qa,(0,wt.Z)({},Sa,{stickyBottomOffset:ra,className:"".concat(xt,"-summary"),ref:qr}),ho),Ir&&Ti.current&&Ti.current instanceof Element&&Ie.createElement(Gu,{ref:io,offsetScroll:Xo,scrollBodyRef:Ti,onScroll:or,container:ro,direction:Un}))}else Qo=Ie.createElement("div",{style:(0,it.Z)((0,it.Z)({},ds),Pa),className:Ft()("".concat(xt,"-content")),onScroll:or,ref:Ti},Ie.createElement(Ca,(0,wt.Z)({style:(0,it.Z)((0,it.Z)({},Ba),{},{tableLayout:Rr})},ya),ll,Aa,Zr!==!1&&Ie.createElement(il,(0,wt.Z)({},Eo,Fr)),fa,Jo&&Ie.createElement(_r,{stickyOffsets:rr,flattenColumns:Pi},Jo)));var is=Ie.createElement("div",(0,wt.Z)({className:Ft()(xt,Ht,(0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)({},"".concat(xt,"-rtl"),Un==="rtl"),"".concat(xt,"-ping-left"),Qi),"".concat(xt,"-ping-right"),Uo),"".concat(xt,"-layout-fixed"),Si==="fixed"),"".concat(xt,"-fixed-header"),Fi),"".concat(xt,"-fixed-column"),Sr),"".concat(xt,"-fixed-column-gapped"),Sr&&ar),"".concat(xt,"-scroll-horizontal"),zi),"".concat(xt,"-has-fix-left"),Pi[0]&&Pi[0].fixed),"".concat(xt,"-has-fix-right"),Pi[Pi.length-1]&&Pi[Pi.length-1].fixed==="right")),style:un,id:br,ref:hr},Yl),gi&&Ie.createElement(Ua,{className:"".concat(xt,"-title")},gi(Xe)),Ie.createElement("div",{ref:pr,className:"".concat(xt,"-container")},Qo),ii&&Ie.createElement(Ua,{className:"".concat(xt,"-footer")},ii(Xe)));zi&&(is=Ie.createElement(we.Z,{onResize:Ha},is));var Bs=Qe(Pi,rr,Un),tl=Ie.useMemo(function(){return{scrollX:ki,prefixCls:xt,getComponent:Se,scrollbarSize:zo,direction:Un,fixedInfoList:Bs,isSticky:Ir,supportSticky:Hi,componentWidth:Ai,fixHeader:Fi,fixColumn:Sr,horizonScroll:zi,tableLayout:Rr,rowClassName:en,expandedRowClassName:Sn.expandedRowClassName,expandIcon:In,expandableType:yn,expandRowByClick:Sn.expandRowByClick,expandedRowRender:Sn.expandedRowRender,onTriggerExpand:Kn,expandIconColumnIndex:Sn.expandIconColumnIndex,indentSize:Sn.indentSize,allColumnsFixedLeft:Pi.every(function(oo){return oo.fixed==="left"}),emptyNode:Go,columns:Ji,flattenColumns:Pi,onColumnResize:Bo,hoverStartRow:Et,hoverEndRow:Bt,onHover:hn,rowExpandable:Sn.rowExpandable,onRow:er,getRowKey:Le,expandedKeys:Jn,childrenColumnName:Mn,rowHoverable:Oe}},[ki,xt,Se,zo,Un,Bs,Ir,Hi,Ai,Fi,Sr,zi,Rr,en,Sn.expandedRowClassName,In,yn,Sn.expandRowByClick,Sn.expandedRowRender,Kn,Sn.expandIconColumnIndex,Sn.indentSize,Go,Ji,Pi,Bo,Et,Bt,hn,Sn.rowExpandable,er,Le,Jn,Mn,Oe]);return Ie.createElement(Ee.Provider,{value:tl},is)}var es=Ie.forwardRef(Xu);function Ds(Ue){return le(es,Ue)}var Mo=Ds();Mo.EXPAND_COLUMN=Ne.w,Mo.INTERNAL_HOOKS=Ne.R,Mo.Column=Xt,Mo.ColumnGroup=zl,Mo.Summary=Fn;var Ro=Mo;function Ma(Ue){var ht=Ie.useRef();ht.current=Ue;var pt=Ie.useCallback(function(){for(var xt,Ht=arguments.length,en=new Array(Ht),un=0;un<Ht;un++)en[un]=arguments[un];return(xt=ht.current)===null||xt===void 0?void 0:xt.call.apply(xt,[ht].concat(en))},[]);return pt}function Ls(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var vr=Ls()?Ie.useLayoutEffect:Ie.useEffect,$h=function(ht,pt){var xt=Ie.useRef(!0);vr(function(){return ht(xt.current)},pt),vr(function(){return xt.current=!1,function(){xt.current=!0}},[])},Nl=function(ht,pt){$h(function(xt){if(!xt)return ht()},pt)},Tl=$h;function wh(Ue){var ht=React.useRef(!1),pt=React.useState(Ue),xt=_slicedToArray(pt,2),Ht=xt[0],en=xt[1];React.useEffect(function(){return ht.current=!1,function(){ht.current=!0}},[]);function un(En,Yn){Yn&&ht.current||en(En)}return[Ht,un]}function Ju(Ue){return Ue!==void 0}function Bi(Ue,ht){var pt=ht||{},xt=pt.defaultValue,Ht=pt.value,en=pt.onChange,un=pt.postState,En=useState(function(){return Ju(Ht)?Ht:Ju(xt)?typeof xt=="function"?xt():xt:typeof Ue=="function"?Ue():Ue}),Yn=_slicedToArray(En,2),Gn=Yn[0],Si=Yn[1],Un=Ht!==void 0?Ht:Gn,gi=un?un(Un):Un,ii=useEvent(en),Oi=useState([Un]),lr=_slicedToArray(Oi,2),br=lr[0],Zr=lr[1];useLayoutUpdateEffect(function(){var mr=br[0];Gn!==mr&&ii(Gn,mr)},[br]),useLayoutUpdateEffect(function(){Ju(Ht)||Si(Ht)},[Ht]);var Gi=useEvent(function(mr,er){Si(mr,er),Zr([Un],er)});return[gi,Gi]}function Ms(Ue,ht,pt){var xt=React.useRef({});return(!("value"in xt.current)||pt(xt.current.condition,ht))&&(xt.current.value=Ue(),xt.current.condition=ht),xt.current.value}function Cs(Ue,ht){typeof Ue=="function"?Ue(ht):_typeof(Ue)==="object"&&Ue&&"current"in Ue&&(Ue.current=ht)}function _l(){for(var Ue=arguments.length,ht=new Array(Ue),pt=0;pt<Ue;pt++)ht[pt]=arguments[pt];var xt=ht.filter(function(Ht){return Ht});return xt.length<=1?xt[0]:function(Ht){ht.forEach(function(en){Cs(en,Ht)})}}function lh(){for(var Ue=arguments.length,ht=new Array(Ue),pt=0;pt<Ue;pt++)ht[pt]=arguments[pt];return useMemo(function(){return _l.apply(void 0,ht)},ht,function(xt,Ht){return xt.length!==Ht.length||xt.every(function(en,un){return en!==Ht[un]})})}function Ph(Ue){var ht,pt,xt=isMemo(Ue)?Ue.type.type:Ue.type;return!(typeof xt=="function"&&!((ht=xt.prototype)!==null&&ht!==void 0&&ht.render)||typeof Ue=="function"&&!((pt=Ue.prototype)!==null&&pt!==void 0&&pt.render))}function ko(Ue){return!isValidElement(Ue)||isFragment(Ue)?!1:Ph(Ue)}function Ch(Ue,ht,pt,xt){if(!ht.length)return pt;var Ht=_toArray(ht),en=Ht[0],un=Ht.slice(1),En;return!Ue&&typeof en=="number"?En=[]:Array.isArray(Ue)?En=_toConsumableArray(Ue):En=_objectSpread({},Ue),xt&&pt===void 0&&un.length===1?delete En[en][un[0]]:En[en]=Ch(En[en],un,pt,xt),En}function iu(Ue,ht,pt){var xt=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;return ht.length&&xt&&pt===void 0&&!get(Ue,ht.slice(0,-1))?Ue:Ch(Ue,ht,pt,xt)}function yl(Ue){return _typeof(Ue)==="object"&&Ue!==null&&Object.getPrototypeOf(Ue)===Object.prototype}function Hl(Ue){return Array.isArray(Ue)?[]:{}}var Eh=typeof Reflect=="undefined"?Object.keys:Reflect.ownKeys;function ec(){for(var Ue=arguments.length,ht=new Array(Ue),pt=0;pt<Ue;pt++)ht[pt]=arguments[pt];var xt=Hl(ht[0]);return ht.forEach(function(Ht){function en(un,En){var Yn=new Set(En),Gn=get(Ht,un),Si=Array.isArray(Gn);if(Si||yl(Gn)){if(!Yn.has(Gn)){Yn.add(Gn);var Un=get(xt,un);Si?xt=iu(xt,un,[]):(!Un||_typeof(Un)!=="object")&&(xt=iu(xt,un,Hl(Gn))),Eh(Gn).forEach(function(gi){en([].concat(_toConsumableArray(un),[gi]),Yn)})}}else xt=iu(xt,un,Gn)}en([])}),xt}var Dl={},ru=[],uh=function(ht){ru.push(ht)};function Ec(Ue,ht){if(0)var pt}function zh(Ue,ht){if(0)var pt}function Rc(){Dl={}}function dc(Ue,ht,pt){!ht&&!Dl[pt]&&(Ue(!1,pt),Dl[pt]=!0)}function Gl(Ue,ht){dc(Ec,Ue,ht)}function Qu(Ue,ht){dc(zh,Ue,ht)}Gl.preMessage=uh,Gl.resetWarned=Rc,Gl.noteOnce=Qu;var pu=null,bh=Ie.forwardRef(function(Ue,ht){var pt=Ue.height,xt=Ue.offsetY,Ht=Ue.offsetX,en=Ue.children,un=Ue.prefixCls,En=Ue.onInnerResize,Yn=Ue.innerProps,Gn=Ue.rtl,Si=Ue.extra,Un={},gi={display:"flex",flexDirection:"column"};return xt!==void 0&&(Un={height:pt,position:"relative",overflow:"hidden"},gi=(0,it.Z)((0,it.Z)({},gi),{},(0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)((0,Nt.Z)({transform:"translateY(".concat(xt,"px)")},Gn?"marginRight":"marginLeft",-Ht),"position","absolute"),"left",0),"right",0),"top",0))),Ie.createElement("div",{style:Un},Ie.createElement(we.Z,{onResize:function(Oi){var lr=Oi.offsetHeight;lr&&En&&En()}},Ie.createElement("div",(0,wt.Z)({style:gi,className:Ft()((0,Nt.Z)({},"".concat(un,"-holder-inner"),un)),ref:ht},Yn),en,Si)))});bh.displayName="Filler";var tc=bh;function Hh(Ue){var ht=Ue.children,pt=Ue.setRef,xt=Ie.useCallback(function(Ht){pt(Ht)},[]);return Ie.cloneElement(ht,{ref:xt})}function vs(Ue,ht,pt,xt,Ht,en,un,En){var Yn=En.getKey;return Ue.slice(ht,pt+1).map(function(Gn,Si){var Un=ht+Si,gi=un(Gn,Un,{style:{width:xt},offsetX:Ht}),ii=Yn(Gn);return Ie.createElement(Hh,{key:ii,setRef:function(lr){return en(Gn,lr)}},gi)})}function tn(Ue,ht,pt,xt){var Ht=pt-Ue,en=ht-pt,un=Math.min(Ht,en)*2;if(xt<=un){var En=Math.floor(xt/2);return xt%2?pt+En+1:pt-En}return Ht>en?pt-(xt-en):pt+(xt-Ht)}function nc(Ue,ht,pt){var xt=Ue.length,Ht=ht.length,en,un;if(xt===0&&Ht===0)return null;xt<Ht?(en=Ue,un=ht):(en=ht,un=Ue);var En={__EMPTY_ITEM__:!0};function Yn(Oi){return Oi!==void 0?pt(Oi):En}for(var Gn=null,Si=Math.abs(xt-Ht)!==1,Un=0;Un<un.length;Un+=1){var gi=Yn(en[Un]),ii=Yn(un[Un]);if(gi!==ii){Gn=Un,Si=Si||gi!==Yn(un[Un+1]);break}}return Gn===null?null:{index:Gn,multiple:Si}}function Gh(Ue,ht,pt){var xt=Ie.useState(Ue),Ht=(0,dt.Z)(xt,2),en=Ht[0],un=Ht[1],En=Ie.useState(null),Yn=(0,dt.Z)(En,2),Gn=Yn[0],Si=Yn[1];return Ie.useEffect(function(){var Un=nc(en||[],Ue||[],ht);(Un==null?void 0:Un.index)!==void 0&&(pt==null||pt(Un.index),Si(Ue[Un.index])),un(Ue)},[Ue]),[Gn]}var qu=function(ht){return+setTimeout(ht,16)},Ml=function(ht){return clearTimeout(ht)};typeof window!="undefined"&&"requestAnimationFrame"in window&&(qu=function(ht){return window.requestAnimationFrame(ht)},Ml=function(ht){return window.cancelAnimationFrame(ht)});var ol=0,Rs=new Map;function Us(Ue){Rs.delete(Ue)}var hh=function(ht){var pt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;ol+=1;var xt=ol;function Ht(en){if(en===0)Us(xt),ht();else{var un=qu(function(){Ht(en-1)});Rs.set(xt,un)}}return Ht(pt),xt};hh.cancel=function(Ue){var ht=Rs.get(Ue);return Us(ht),Ml(ht)};var al=hh,Ss=(typeof navigator=="undefined"?"undefined":(0,st.Z)(navigator))==="object"&&/Firefox/i.test(navigator.userAgent),os=Ss,Lh=function(Ue,ht,pt,xt){var Ht=(0,Ie.useRef)(!1),en=(0,Ie.useRef)(null);function un(){clearTimeout(en.current),Ht.current=!0,en.current=setTimeout(function(){Ht.current=!1},50)}var En=(0,Ie.useRef)({top:Ue,bottom:ht,left:pt,right:xt});return En.current.top=Ue,En.current.bottom=ht,En.current.left=pt,En.current.right=xt,function(Yn,Gn){var Si=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,Un=Yn?Gn<0&&En.current.left||Gn>0&&En.current.right:Gn<0&&En.current.top||Gn>0&&En.current.bottom;return Si&&Un?(clearTimeout(en.current),Ht.current=!1):(!Un||Ht.current)&&un(),!Ht.current&&Un}};function Au(Ue,ht,pt,xt,Ht,en,un){var En=(0,Ie.useRef)(0),Yn=(0,Ie.useRef)(null),Gn=(0,Ie.useRef)(null),Si=(0,Ie.useRef)(!1),Un=Lh(ht,pt,xt,Ht);function gi(Gi,mr){if(al.cancel(Yn.current),!Un(!1,mr)){var er=Gi;if(!er._virtualHandled)er._virtualHandled=!0;else return;En.current+=mr,Gn.current=mr,os||er.preventDefault(),Yn.current=al(function(){var Yr=Si.current?10:1;un(En.current*Yr,!1),En.current=0})}}function ii(Gi,mr){un(mr,!0),os||Gi.preventDefault()}var Oi=(0,Ie.useRef)(null),lr=(0,Ie.useRef)(null);function br(Gi){if(Ue){al.cancel(lr.current),lr.current=al(function(){Oi.current=null},2);var mr=Gi.deltaX,er=Gi.deltaY,Yr=Gi.shiftKey,No=mr,Wr=er;(Oi.current==="sx"||!Oi.current&&Yr&&er&&!mr)&&(No=er,Wr=0,Oi.current="sx");var da=Math.abs(No),To=Math.abs(Wr);Oi.current===null&&(Oi.current=en&&da>To?"x":"y"),Oi.current==="y"?gi(Gi,Wr):ii(Gi,No)}}function Zr(Gi){Ue&&(Si.current=Gi.detail===Gn.current)}return[br,Zr]}function kr(Ue,ht,pt,xt){var Ht=Ie.useMemo(function(){return[new Map,[]]},[Ue,pt.id,xt]),en=(0,dt.Z)(Ht,2),un=en[0],En=en[1],Yn=function(Si){var Un=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Si,gi=un.get(Si),ii=un.get(Un);if(gi===void 0||ii===void 0)for(var Oi=Ue.length,lr=En.length;lr<Oi;lr+=1){var br,Zr=Ue[lr],Gi=ht(Zr);un.set(Gi,lr);var mr=(br=pt.get(Gi))!==null&&br!==void 0?br:xt;if(En[lr]=(En[lr-1]||0)+mr,Gi===Si&&(gi=lr),Gi===Un&&(ii=lr),gi!==void 0&&ii!==void 0)break}return{top:En[gi-1]||0,bottom:En[ii]}};return Yn}var Kh=De(15671),yt=De(43144),Bn=function(){function Ue(){(0,Kh.Z)(this,Ue),(0,Nt.Z)(this,"maps",void 0),(0,Nt.Z)(this,"id",0),(0,Nt.Z)(this,"diffKeys",new Set),this.maps=Object.create(null)}return(0,yt.Z)(Ue,[{key:"set",value:function(pt,xt){this.maps[pt]=xt,this.id+=1,this.diffKeys.add(pt)}},{key:"get",value:function(pt){return this.maps[pt]}},{key:"resetRecord",value:function(){this.diffKeys.clear()}},{key:"getRecord",value:function(){return this.diffKeys}}]),Ue}(),Kl=Bn;function ch(Ue){var ht=parseFloat(Ue);return isNaN(ht)?0:ht}function $u(Ue,ht,pt){var xt=Ie.useState(0),Ht=(0,dt.Z)(xt,2),en=Ht[0],un=Ht[1],En=(0,Ie.useRef)(new Map),Yn=(0,Ie.useRef)(new Kl),Gn=(0,Ie.useRef)(0);function Si(){Gn.current+=1}function Un(){var ii=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;Si();var Oi=function(){var Zr=!1;En.current.forEach(function(Gi,mr){if(Gi&&Gi.offsetParent){var er=Gi.offsetHeight,Yr=getComputedStyle(Gi),No=Yr.marginTop,Wr=Yr.marginBottom,da=ch(No),To=ch(Wr),la=er+da+To;Yn.current.get(mr)!==la&&(Yn.current.set(mr,la),Zr=!0)}}),Zr&&un(function(Gi){return Gi+1})};if(ii)Oi();else{Gn.current+=1;var lr=Gn.current;Promise.resolve().then(function(){lr===Gn.current&&Oi()})}}function gi(ii,Oi){var lr=Ue(ii),br=En.current.get(lr);Oi?(En.current.set(lr,Oi),Un()):En.current.delete(lr),!br!=!Oi&&(Oi?ht==null||ht(ii):pt==null||pt(ii))}return(0,Ie.useEffect)(function(){return Si},[]),[gi,Un,Yn.current,en]}var Nu=14/15;function Tu(Ue,ht,pt){var xt=(0,Ie.useRef)(!1),Ht=(0,Ie.useRef)(0),en=(0,Ie.useRef)(0),un=(0,Ie.useRef)(null),En=(0,Ie.useRef)(null),Yn,Gn=function(ii){if(xt.current){var Oi=Math.ceil(ii.touches[0].pageX),lr=Math.ceil(ii.touches[0].pageY),br=Ht.current-Oi,Zr=en.current-lr,Gi=Math.abs(br)>Math.abs(Zr);Gi?Ht.current=Oi:en.current=lr;var mr=pt(Gi,Gi?br:Zr,!1,ii);mr&&ii.preventDefault(),clearInterval(En.current),mr&&(En.current=setInterval(function(){Gi?br*=Nu:Zr*=Nu;var er=Math.floor(Gi?br:Zr);(!pt(Gi,er,!0)||Math.abs(er)<=.1)&&clearInterval(En.current)},16))}},Si=function(){xt.current=!1,Yn()},Un=function(ii){Yn(),ii.touches.length===1&&!xt.current&&(xt.current=!0,Ht.current=Math.ceil(ii.touches[0].pageX),en.current=Math.ceil(ii.touches[0].pageY),un.current=ii.target,un.current.addEventListener("touchmove",Gn,{passive:!1}),un.current.addEventListener("touchend",Si,{passive:!0}))};Yn=function(){un.current&&(un.current.removeEventListener("touchmove",Gn),un.current.removeEventListener("touchend",Si))},Tl(function(){return Ue&&ht.current.addEventListener("touchstart",Un,{passive:!0}),function(){var gi;(gi=ht.current)===null||gi===void 0||gi.removeEventListener("touchstart",Un),Yn(),clearInterval(En.current)}},[Ue])}function Wh(Ue){return Math.floor(Math.pow(Ue,.5))}function Du(Ue,ht){var pt="touches"in Ue?Ue.touches[0]:Ue;return pt[ht?"pageX":"pageY"]-window[ht?"scrollX":"scrollY"]}function Ns(Ue,ht,pt){Ie.useEffect(function(){var xt=ht.current;if(Ue&&xt){var Ht=!1,en,un,En=function(){al.cancel(en)},Yn=function gi(){En(),en=al(function(){pt(un),gi()})},Gn=function(ii){if(!(ii.target.draggable||ii.button!==0)){var Oi=ii;Oi._virtualHandled||(Oi._virtualHandled=!0,Ht=!0)}},Si=function(){Ht=!1,En()},Un=function(ii){if(Ht){var Oi=Du(ii,!1),lr=xt.getBoundingClientRect(),br=lr.top,Zr=lr.bottom;if(Oi<=br){var Gi=br-Oi;un=-Wh(Gi),Yn()}else if(Oi>=Zr){var mr=Oi-Zr;un=Wh(mr),Yn()}else En()}};return xt.addEventListener("mousedown",Gn),xt.ownerDocument.addEventListener("mouseup",Si),xt.ownerDocument.addEventListener("mousemove",Un),function(){xt.removeEventListener("mousedown",Gn),xt.ownerDocument.removeEventListener("mouseup",Si),xt.ownerDocument.removeEventListener("mousemove",Un),En()}}},[Ue])}var to=10;function Bl(Ue,ht,pt,xt,Ht,en,un,En){var Yn=Ie.useRef(),Gn=Ie.useState(null),Si=(0,dt.Z)(Gn,2),Un=Si[0],gi=Si[1];return Tl(function(){if(Un&&Un.times<to){if(!Ue.current){gi(function(Le){return(0,it.Z)({},Le)});return}en();var ii=Un.targetAlign,Oi=Un.originAlign,lr=Un.index,br=Un.offset,Zr=Ue.current.clientHeight,Gi=!1,mr=ii,er=null;if(Zr){for(var Yr=ii||Oi,No=0,Wr=0,da=0,To=Math.min(ht.length-1,lr),la=0;la<=To;la+=1){var ys=Ht(ht[la]);Wr=No;var Da=pt.get(ys);da=Wr+(Da===void 0?xt:Da),No=da}for(var Te=Yr==="top"?br:Zr-br,Oe=To;Oe>=0;Oe-=1){var Xe=Ht(ht[Oe]),ot=pt.get(Xe);if(ot===void 0){Gi=!0;break}if(Te-=ot,Te<=0)break}switch(Yr){case"top":er=Wr-br;break;case"bottom":er=da-Zr+br;break;default:{var Rt=Ue.current.scrollTop,Se=Rt+Zr;Wr<Rt?mr="top":da>Se&&(mr="bottom")}}er!==null&&un(er),er!==Un.lastTop&&(Gi=!0)}Gi&&gi((0,it.Z)((0,it.Z)({},Un),{},{times:Un.times+1,targetAlign:mr,lastTop:er}))}},[Un,Ue.current]),function(ii){if(ii==null){En();return}if(al.cancel(Yn.current),typeof ii=="number")un(ii);else if(ii&&(0,st.Z)(ii)==="object"){var Oi,lr=ii.align;"index"in ii?Oi=ii.index:Oi=ht.findIndex(function(Gi){return Ht(Gi)===ii.key});var br=ii.offset,Zr=br===void 0?0:br;gi({times:0,index:Oi,offset:Zr,originAlign:lr})}}}var Pl=Ie.forwardRef(function(Ue,ht){var pt=Ue.prefixCls,xt=Ue.rtl,Ht=Ue.scrollOffset,en=Ue.scrollRange,un=Ue.onStartMove,En=Ue.onStopMove,Yn=Ue.onScroll,Gn=Ue.horizontal,Si=Ue.spinSize,Un=Ue.containerSize,gi=Ue.style,ii=Ue.thumbStyle,Oi=Ue.showScrollBar,lr=Ie.useState(!1),br=(0,dt.Z)(lr,2),Zr=br[0],Gi=br[1],mr=Ie.useState(null),er=(0,dt.Z)(mr,2),Yr=er[0],No=er[1],Wr=Ie.useState(null),da=(0,dt.Z)(Wr,2),To=da[0],la=da[1],ys=!xt,Da=Ie.useRef(),Te=Ie.useRef(),Oe=Ie.useState(Oi),Xe=(0,dt.Z)(Oe,2),ot=Xe[0],Rt=Xe[1],Se=Ie.useRef(),Le=function(){Oi===!0||Oi===!1||(clearTimeout(Se.current),Rt(!0),Se.current=setTimeout(function(){Rt(!1)},3e3))},je=en-Un||0,Ke=Un-Si||0,ct=Ie.useMemo(function(){if(Ht===0||je===0)return 0;var In=Ht/je;return In*Ke},[Ht,je,Ke]),Et=function(Mn){Mn.stopPropagation(),Mn.preventDefault()},Bt=Ie.useRef({top:ct,dragging:Zr,pageY:Yr,startTop:To});Bt.current={top:ct,dragging:Zr,pageY:Yr,startTop:To};var hn=function(Mn){Gi(!0),No(Du(Mn,Gn)),la(Bt.current.top),un(),Mn.stopPropagation(),Mn.preventDefault()};Ie.useEffect(function(){var In=function(yi){yi.preventDefault()},Mn=Da.current,Kn=Te.current;return Mn.addEventListener("touchstart",In,{passive:!1}),Kn.addEventListener("touchstart",hn,{passive:!1}),function(){Mn.removeEventListener("touchstart",In),Kn.removeEventListener("touchstart",hn)}},[]);var qt=Ie.useRef();qt.current=je;var nn=Ie.useRef();nn.current=Ke,Ie.useEffect(function(){if(Zr){var In,Mn=function(yi){var $i=Bt.current,Ai=$i.dragging,bi=$i.pageY,dr=$i.startTop;al.cancel(In);var Wn=Da.current.getBoundingClientRect(),Ji=Un/(Gn?Wn.width:Wn.height);if(Ai){var Pi=(Du(yi,Gn)-bi)*Ji,tr=dr;!ys&&Gn?tr-=Pi:tr+=Pi;var ar=qt.current,ki=nn.current,Fr=ki?tr/ki:0,hr=Math.ceil(Fr*ar);hr=Math.max(hr,0),hr=Math.min(hr,ar),In=al(function(){Yn(hr,Gn)})}},Kn=function(){Gi(!1),En()};return window.addEventListener("mousemove",Mn,{passive:!0}),window.addEventListener("touchmove",Mn,{passive:!0}),window.addEventListener("mouseup",Kn,{passive:!0}),window.addEventListener("touchend",Kn,{passive:!0}),function(){window.removeEventListener("mousemove",Mn),window.removeEventListener("touchmove",Mn),window.removeEventListener("mouseup",Kn),window.removeEventListener("touchend",Kn),al.cancel(In)}}},[Zr]),Ie.useEffect(function(){return Le(),function(){clearTimeout(Se.current)}},[Ht]),Ie.useImperativeHandle(ht,function(){return{delayHidden:Le}});var Sn="".concat(pt,"-scrollbar"),yn={position:"absolute",visibility:ot?null:"hidden"},Jn={position:"absolute",background:"rgba(0, 0, 0, 0.5)",borderRadius:99,cursor:"pointer",userSelect:"none"};return Gn?(yn.height=8,yn.left=0,yn.right=0,yn.bottom=0,Jn.height="100%",Jn.width=Si,ys?Jn.left=ct:Jn.right=ct):(yn.width=8,yn.top=0,yn.bottom=0,ys?yn.right=0:yn.left=0,Jn.width="100%",Jn.height=Si,Jn.top=ct),Ie.createElement("div",{ref:Da,className:Ft()(Sn,(0,Nt.Z)((0,Nt.Z)((0,Nt.Z)({},"".concat(Sn,"-horizontal"),Gn),"".concat(Sn,"-vertical"),!Gn),"".concat(Sn,"-visible"),ot)),style:(0,it.Z)((0,it.Z)({},yn),gi),onMouseDown:Et,onMouseMove:Le},Ie.createElement("div",{ref:Te,className:Ft()("".concat(Sn,"-thumb"),(0,Nt.Z)({},"".concat(Sn,"-thumb-moving"),Zr)),style:(0,it.Z)((0,it.Z)({},Jn),ii),onMouseDown:hn}))}),xs=Pl,fi=20;function po(){var Ue=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,ht=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,pt=Ue/ht*Ue;return isNaN(pt)&&(pt=0),pt=Math.max(pt,fi),Math.floor(pt)}var Vo=["prefixCls","className","height","itemHeight","fullHeight","style","data","children","itemKey","virtual","direction","scrollWidth","component","onScroll","onVirtualScroll","onVisibleChange","innerProps","extraRender","styles","showScrollBar"],qo=[],Ja={overflowY:"auto",overflowAnchor:"none"};function Zs(Ue,ht){var pt=Ue.prefixCls,xt=pt===void 0?"rc-virtual-list":pt,Ht=Ue.className,en=Ue.height,un=Ue.itemHeight,En=Ue.fullHeight,Yn=En===void 0?!0:En,Gn=Ue.style,Si=Ue.data,Un=Ue.children,gi=Ue.itemKey,ii=Ue.virtual,Oi=Ue.direction,lr=Ue.scrollWidth,br=Ue.component,Zr=br===void 0?"div":br,Gi=Ue.onScroll,mr=Ue.onVirtualScroll,er=Ue.onVisibleChange,Yr=Ue.innerProps,No=Ue.extraRender,Wr=Ue.styles,da=Ue.showScrollBar,To=da===void 0?"optional":da,la=(0,ha.Z)(Ue,Vo),ys=Ie.useCallback(function(Vi){return typeof gi=="function"?gi(Vi):Vi==null?void 0:Vi[gi]},[gi]),Da=$u(ys,null,null),Te=(0,dt.Z)(Da,4),Oe=Te[0],Xe=Te[1],ot=Te[2],Rt=Te[3],Se=!!(ii!==!1&&en&&un),Le=Ie.useMemo(function(){return Object.values(ot.maps).reduce(function(Vi,Ki){return Vi+Ki},0)},[ot.id,ot.maps]),je=Se&&Si&&(Math.max(un*Si.length,Le)>en||!!lr),Ke=Oi==="rtl",ct=Ft()(xt,(0,Nt.Z)({},"".concat(xt,"-rtl"),Ke),Ht),Et=Si||qo,Bt=(0,Ie.useRef)(),hn=(0,Ie.useRef)(),qt=(0,Ie.useRef)(),nn=(0,Ie.useState)(0),Sn=(0,dt.Z)(nn,2),yn=Sn[0],Jn=Sn[1],In=(0,Ie.useState)(0),Mn=(0,dt.Z)(In,2),Kn=Mn[0],ni=Mn[1],yi=(0,Ie.useState)(!1),$i=(0,dt.Z)(yi,2),Ai=$i[0],bi=$i[1],dr=function(){bi(!0)},Wn=function(){bi(!1)},Ji={getKey:ys};function Pi(Vi){Jn(function(Ki){var or;typeof Vi=="function"?or=Vi(Ki):or=Vi;var Jr=Nr(or);return Bt.current.scrollTop=Jr,Jr})}var tr=(0,Ie.useRef)({start:0,end:Et.length}),ar=(0,Ie.useRef)(),ki=Gh(Et,ys),Fr=(0,dt.Z)(ki,1),hr=Fr[0];ar.current=hr;var Mr=Ie.useMemo(function(){if(!Se)return{scrollHeight:void 0,start:0,end:Et.length-1,offset:void 0};if(!je){var Vi;return{scrollHeight:((Vi=hn.current)===null||Vi===void 0?void 0:Vi.offsetHeight)||0,start:0,end:Et.length-1,offset:void 0}}for(var Ki=0,or,Jr,ta,Ha=Et.length,ls=0;ls<Ha;ls+=1){var bt=Et[ls],xo=ys(bt),zo=ot.get(xo),na=Ki+(zo===void 0?un:zo);na>=yn&&or===void 0&&(or=ls,Jr=Ki),na>yn+en&&ta===void 0&&(ta=ls),Ki=na}return or===void 0&&(or=0,Jr=0,ta=Math.ceil(en/un)),ta===void 0&&(ta=Et.length-1),ta=Math.min(ta+1,Et.length-1),{scrollHeight:Ki,start:or,end:ta,offset:Jr}},[je,Se,yn,Et,Rt,en]),Ti=Mr.scrollHeight,pr=Mr.start,qr=Mr.end,Po=Mr.offset;tr.current.start=pr,tr.current.end=qr,Ie.useLayoutEffect(function(){var Vi=ot.getRecord();if(Vi.size===1){var Ki=Array.from(Vi)[0],or=Et[pr];if(or){var Jr=ys(or);if(Jr===Ki){var ta=ot.get(Ki),Ha=ta-un;Pi(function(ls){return ls+Ha})}}}ot.resetRecord()},[Ti]);var no=Ie.useState({width:0,height:en}),Qi=(0,dt.Z)(no,2),zr=Qi[0],$r=Qi[1],lo=function(Ki){$r({width:Ki.offsetWidth,height:Ki.offsetHeight})},Uo=(0,Ie.useRef)(),So=(0,Ie.useRef)(),Ar=Ie.useMemo(function(){return po(zr.width,lr)},[zr.width,lr]),ur=Ie.useMemo(function(){return po(zr.height,Ti)},[zr.height,Ti]),Vr=Ti-en,Do=(0,Ie.useRef)(Vr);Do.current=Vr;function Nr(Vi){var Ki=Vi;return Number.isNaN(Do.current)||(Ki=Math.min(Ki,Do.current)),Ki=Math.max(Ki,0),Ki}var Wi=yn<=0,ir=yn>=Vr,rr=Kn<=0,Fi=Kn>=lr,zi=Lh(Wi,ir,rr,Fi),Sr=function(){return{x:Ke?-Kn:Kn,y:yn}},io=(0,Ie.useRef)(Sr()),Xr=Ma(function(Vi){if(mr){var Ki=(0,it.Z)((0,it.Z)({},Sr()),Vi);(io.current.x!==Ki.x||io.current.y!==Ki.y)&&(mr(Ki),io.current=Ki)}});function Ir(Vi,Ki){var or=Vi;Ki?((0,$e.flushSync)(function(){ni(or)}),Xr()):Pi(or)}function wa(Vi){var Ki=Vi.currentTarget.scrollTop;Ki!==yn&&Pi(Ki),Gi==null||Gi(Vi),Xr()}var ra=function(Ki){var or=Ki,Jr=lr?lr-zr.width:0;return or=Math.max(or,0),or=Math.min(or,Jr),or},Xo=Ma(function(Vi,Ki){Ki?((0,$e.flushSync)(function(){ni(function(or){var Jr=or+(Ke?-Vi:Vi);return ra(Jr)})}),Xr()):Pi(function(or){var Jr=or+Vi;return Jr})}),pa=Au(Se,Wi,ir,rr,Fi,!!lr,Xo),ro=(0,dt.Z)(pa,2),Jo=ro[0],va=ro[1];Tu(Se,Bt,function(Vi,Ki,or,Jr){var ta=Jr;return zi(Vi,Ki,or)?!1:!ta||!ta._virtualHandled?(ta&&(ta._virtualHandled=!0),Jo({preventDefault:function(){},deltaX:Vi?Ki:0,deltaY:Vi?0:Ki}),!0):!1}),Ns(je,Bt,function(Vi){Pi(function(Ki){return Ki+Vi})}),Tl(function(){function Vi(or){var Jr=Wi&&or.detail<0,ta=ir&&or.detail>0;Se&&!Jr&&!ta&&or.preventDefault()}var Ki=Bt.current;return Ki.addEventListener("wheel",Jo,{passive:!1}),Ki.addEventListener("DOMMouseScroll",va,{passive:!0}),Ki.addEventListener("MozMousePixelScroll",Vi,{passive:!1}),function(){Ki.removeEventListener("wheel",Jo),Ki.removeEventListener("DOMMouseScroll",va),Ki.removeEventListener("MozMousePixelScroll",Vi)}},[Se,Wi,ir]),Tl(function(){if(lr){var Vi=ra(Kn);ni(Vi),Xr({x:Vi})}},[zr.width,lr]);var ds=function(){var Ki,or;(Ki=Uo.current)===null||Ki===void 0||Ki.delayHidden(),(or=So.current)===null||or===void 0||or.delayHidden()},Pa=Bl(Bt,Et,ot,un,ys,function(){return Xe(!0)},Pi,ds);Ie.useImperativeHandle(ht,function(){return{nativeElement:qt.current,getScrollInfo:Sr,scrollTo:function(Ki){function or(Jr){return Jr&&(0,st.Z)(Jr)==="object"&&("left"in Jr||"top"in Jr)}or(Ki)?(Ki.left!==void 0&&ni(ra(Ki.left)),Pa(Ki.top)):Pa(Ki)}}}),Tl(function(){if(er){var Vi=Et.slice(pr,qr+1);er(Vi,Et)}},[pr,qr,Et]);var Ba=kr(Et,ys,ot,un),Bo=No==null?void 0:No({start:pr,end:qr,virtual:je,offsetX:Kn,offsetY:Po,rtl:Ke,getSize:Ba}),Za=vs(Et,pr,qr,lr,Kn,Oe,Un,Ji),Fa=null;en&&(Fa=(0,it.Z)((0,Nt.Z)({},Yn?"height":"maxHeight",en),Ja),Se&&(Fa.overflowY="hidden",lr&&(Fa.overflowX="hidden"),Ai&&(Fa.pointerEvents="none")));var ns={};return Ke&&(ns.dir="rtl"),Ie.createElement("div",(0,wt.Z)({ref:qt,style:(0,it.Z)((0,it.Z)({},Gn),{},{position:"relative"}),className:ct},ns,la),Ie.createElement(we.Z,{onResize:lo},Ie.createElement(Zr,{className:"".concat(xt,"-holder"),style:Fa,ref:Bt,onScroll:wa,onMouseEnter:ds},Ie.createElement(tc,{prefixCls:xt,height:Ti,offsetX:Kn,offsetY:Po,scrollWidth:lr,onInnerResize:Xe,ref:hn,innerProps:Yr,rtl:Ke,extra:Bo},Za))),je&&Ti>en&&Ie.createElement(xs,{ref:Uo,prefixCls:xt,scrollOffset:yn,scrollRange:Ti,rtl:Ke,onScroll:Ir,onStartMove:dr,onStopMove:Wn,spinSize:ur,containerSize:zr.height,style:Wr==null?void 0:Wr.verticalScrollBar,thumbStyle:Wr==null?void 0:Wr.verticalScrollBarThumb,showScrollBar:To}),je&&lr>zr.width&&Ie.createElement(xs,{ref:So,prefixCls:xt,scrollOffset:Kn,scrollRange:lr,rtl:Ke,onScroll:Ir,onStartMove:dr,onStopMove:Wn,spinSize:Ar,containerSize:zr.width,horizontal:!0,style:Wr==null?void 0:Wr.horizontalScrollBar,thumbStyle:Wr==null?void 0:Wr.horizontalScrollBarThumb,showScrollBar:To}))}var mu=Ie.forwardRef(Zs);mu.displayName="List";var ka=mu,sl=ka,ga=Mt(null),ts=Mt(null);function ss(Ue,ht,pt){var xt=ht||1;return pt[Ue+xt]-(pt[Ue]||0)}function ws(Ue){var ht=Ue.rowInfo,pt=Ue.column,xt=Ue.colIndex,Ht=Ue.indent,en=Ue.index,un=Ue.component,En=Ue.renderIndex,Yn=Ue.record,Gn=Ue.style,Si=Ue.className,Un=Ue.inverse,gi=Ue.getHeight,ii=pt.render,Oi=pt.dataIndex,lr=pt.className,br=pt.width,Zr=Pt(ts,["columnsOffset"]),Gi=Zr.columnsOffset,mr=Vt(ht,pt,xt,Ht,en),er=mr.key,Yr=mr.fixedInfo,No=mr.appendCellNode,Wr=mr.additionalCellProps,da=Wr.style,To=Wr.colSpan,la=To===void 0?1:To,ys=Wr.rowSpan,Da=ys===void 0?1:ys,Te=xt-1,Oe=ss(Te,la,Gi),Xe=la>1?br-Oe:0,ot=(0,it.Z)((0,it.Z)((0,it.Z)({},da),Gn),{},{flex:"0 0 ".concat(Oe,"px"),width:"".concat(Oe,"px"),marginRight:Xe,pointerEvents:"auto"}),Rt=Ie.useMemo(function(){return Un?Da<=1:la===0||Da===0||Da>1},[Da,la,Un]);Rt?ot.visibility="hidden":Un&&(ot.height=gi==null?void 0:gi(Da));var Se=Rt?function(){return null}:ii,Le={};return(Da===0||la===0)&&(Le.rowSpan=1,Le.colSpan=1),Ie.createElement(ei,(0,wt.Z)({className:Ft()(lr,Si),ellipsis:pt.ellipsis,align:pt.align,scope:pt.rowScope,component:un,prefixCls:ht.prefixCls,key:er,record:Yn,index:en,renderIndex:En,dataIndex:Oi,render:Se,shouldCellUpdate:pt.shouldCellUpdate},Yr,{appendNode:No,additionalProps:(0,it.Z)((0,it.Z)({},Wr),{},{style:ot},Le)}))}var Ta=ws,vu=["data","index","className","rowKey","style","extra","getHeight"],Ni=Ie.forwardRef(function(Ue,ht){var pt=Ue.data,xt=Ue.index,Ht=Ue.className,en=Ue.rowKey,un=Ue.style,En=Ue.extra,Yn=Ue.getHeight,Gn=(0,ha.Z)(Ue,vu),Si=pt.record,Un=pt.indent,gi=pt.index,ii=Pt(Ee,["prefixCls","flattenColumns","fixColumn","componentWidth","scrollX"]),Oi=ii.scrollX,lr=ii.flattenColumns,br=ii.prefixCls,Zr=ii.fixColumn,Gi=ii.componentWidth,mr=Pt(ga,["getComponent"]),er=mr.getComponent,Yr=Zo(Si,en,xt,Un),No=er(["body","row"],"div"),Wr=er(["body","cell"],"div"),da=Yr.rowSupportExpand,To=Yr.expanded,la=Yr.rowProps,ys=Yr.expandedRowRender,Da=Yr.expandedRowClassName,Te;if(da&&To){var Oe=ys(Si,xt,Un+1,To),Xe=gs(Da,Si,xt,Un),ot={};Zr&&(ot={style:(0,Nt.Z)({},"--virtual-width","".concat(Gi,"px"))});var Rt="".concat(br,"-expanded-row-cell");Te=Ie.createElement(No,{className:Ft()("".concat(br,"-expanded-row"),"".concat(br,"-expanded-row-level-").concat(Un+1),Xe)},Ie.createElement(ei,{component:Wr,prefixCls:br,className:Ft()(Rt,(0,Nt.Z)({},"".concat(Rt,"-fixed"),Zr)),additionalProps:ot},Oe))}var Se=(0,it.Z)((0,it.Z)({},un),{},{width:Oi});En&&(Se.position="absolute",Se.pointerEvents="none");var Le=Ie.createElement(No,(0,wt.Z)({},la,Gn,{"data-row-key":en,ref:da?null:ht,className:Ft()(Ht,"".concat(br,"-row"),la==null?void 0:la.className,(0,Nt.Z)({},"".concat(br,"-row-extra"),En)),style:(0,it.Z)((0,it.Z)({},Se),la==null?void 0:la.style)}),lr.map(function(je,Ke){return Ie.createElement(Ta,{key:Ke,component:Wr,rowInfo:Yr,column:je,colIndex:Ke,indent:Un,index:xt,renderIndex:gi,record:Si,inverse:En,getHeight:Yn})}));return da?Ie.createElement("div",{ref:ht},Le,Te):Le}),ou=pe(Ni),sa=ou,mo=Ie.forwardRef(function(Ue,ht){var pt=Ue.data,xt=Ue.onScroll,Ht=Pt(Ee,["flattenColumns","onColumnResize","getRowKey","prefixCls","expandedKeys","childrenColumnName","scrollX","direction"]),en=Ht.flattenColumns,un=Ht.onColumnResize,En=Ht.getRowKey,Yn=Ht.expandedKeys,Gn=Ht.prefixCls,Si=Ht.childrenColumnName,Un=Ht.scrollX,gi=Ht.direction,ii=Pt(ga),Oi=ii.sticky,lr=ii.scrollY,br=ii.listItemHeight,Zr=ii.getComponent,Gi=ii.onScroll,mr=Ie.useRef(),er=Co(pt,Si,Yn,En),Yr=Ie.useMemo(function(){var Te=0;return en.map(function(Oe){var Xe=Oe.width,ot=Oe.key;return Te+=Xe,[ot,Xe,Te]})},[en]),No=Ie.useMemo(function(){return Yr.map(function(Te){return Te[2]})},[Yr]);Ie.useEffect(function(){Yr.forEach(function(Te){var Oe=(0,dt.Z)(Te,2),Xe=Oe[0],ot=Oe[1];un(Xe,ot)})},[Yr]),Ie.useImperativeHandle(ht,function(){var Te,Oe={scrollTo:function(ot){var Rt;(Rt=mr.current)===null||Rt===void 0||Rt.scrollTo(ot)},nativeElement:(Te=mr.current)===null||Te===void 0?void 0:Te.nativeElement};return Object.defineProperty(Oe,"scrollLeft",{get:function(){var ot;return((ot=mr.current)===null||ot===void 0?void 0:ot.getScrollInfo().x)||0},set:function(ot){var Rt;(Rt=mr.current)===null||Rt===void 0||Rt.scrollTo({left:ot})}}),Oe});var Wr=function(Oe,Xe){var ot,Rt=(ot=er[Xe])===null||ot===void 0?void 0:ot.record,Se=Oe.onCell;if(Se){var Le,je=Se(Rt,Xe);return(Le=je==null?void 0:je.rowSpan)!==null&&Le!==void 0?Le:1}return 1},da=function(Oe){var Xe=Oe.start,ot=Oe.end,Rt=Oe.getSize,Se=Oe.offsetY;if(ot<0)return null;for(var Le=en.filter(function(In){return Wr(In,Xe)===0}),je=Xe,Ke=function(Mn){if(Le=Le.filter(function(Kn){return Wr(Kn,Mn)===0}),!Le.length)return je=Mn,1},ct=Xe;ct>=0&&!Ke(ct);ct-=1);for(var Et=en.filter(function(In){return Wr(In,ot)!==1}),Bt=ot,hn=function(Mn){if(Et=Et.filter(function(Kn){return Wr(Kn,Mn)!==1}),!Et.length)return Bt=Math.max(Mn-1,ot),1},qt=ot;qt<er.length&&!hn(qt);qt+=1);for(var nn=[],Sn=function(Mn){var Kn=er[Mn];if(!Kn)return 1;en.some(function(ni){return Wr(ni,Mn)>1})&&nn.push(Mn)},yn=je;yn<=Bt;yn+=1)Sn(yn);var Jn=nn.map(function(In){var Mn=er[In],Kn=En(Mn.record,In),ni=function(Ai){var bi=In+Ai-1,dr=En(er[bi].record,bi),Wn=Rt(Kn,dr);return Wn.bottom-Wn.top},yi=Rt(Kn);return Ie.createElement(sa,{key:In,data:Mn,rowKey:Kn,index:In,style:{top:-Se+yi.top},extra:!0,getHeight:ni})});return Jn},To=Ie.useMemo(function(){return{columnsOffset:No}},[No]),la="".concat(Gn,"-tbody"),ys=Zr(["body","wrapper"]),Da={};return Oi&&(Da.position="sticky",Da.bottom=0,(0,st.Z)(Oi)==="object"&&Oi.offsetScroll&&(Da.bottom=Oi.offsetScroll)),Ie.createElement(ts.Provider,{value:To},Ie.createElement(sl,{fullHeight:!1,ref:mr,prefixCls:"".concat(la,"-virtual"),styles:{horizontalScrollBar:Da},className:la,height:lr,itemHeight:br||24,data:er,itemKey:function(Oe){return En(Oe.record)},component:ys,scrollWidth:Un,direction:gi,onVirtualScroll:function(Oe){var Xe,ot=Oe.x;xt({currentTarget:(Xe=mr.current)===null||Xe===void 0?void 0:Xe.nativeElement,scrollLeft:ot})},onScroll:Gi,extraRender:da},function(Te,Oe,Xe){var ot=En(Te.record,Oe);return Ie.createElement(sa,{data:Te,rowKey:ot,index:Oe,style:Xe.style})}))}),Mh=pe(mo),bc=Mh,Ic=function(ht,pt){var xt=pt.ref,Ht=pt.onScroll;return Ie.createElement(bc,{ref:xt,data:ht,onScroll:Ht})};function fc(Ue,ht){var pt=Ue.data,xt=Ue.columns,Ht=Ue.scroll,en=Ue.sticky,un=Ue.prefixCls,En=un===void 0?fu:un,Yn=Ue.className,Gn=Ue.listItemHeight,Si=Ue.components,Un=Ue.onScroll,gi=Ht||{},ii=gi.x,Oi=gi.y;typeof ii!="number"&&(ii=1),typeof Oi!="number"&&(Oi=500);var lr=ft(function(Gi,mr){return zn(Si,Gi)||mr}),br=ft(Un),Zr=Ie.useMemo(function(){return{sticky:en,scrollY:Oi,listItemHeight:Gn,getComponent:lr,onScroll:br}},[en,Oi,Gn,lr,br]);return Ie.createElement(ga.Provider,{value:Zr},Ie.createElement(Ro,(0,wt.Z)({},Ue,{className:Ft()(Yn,"".concat(En,"-virtual")),scroll:(0,it.Z)((0,it.Z)({},Ht),{},{x:ii}),components:(0,it.Z)((0,it.Z)({},Si),{},{body:pt!=null&&pt.length?Ic:void 0}),columns:xt,internalHooks:Ne.R,tailor:!0,ref:ht})))}var kh=Ie.forwardRef(fc);function Fh(Ue){return le(kh,Ue)}var Br=Fh(),Wl=null},62978:function(jn,li,De){"use strict";De.d(li,{g:function(){return Ie},v:function(){return kt}});var Ne=De(1413),dt=De(45987),Ut=De(40830),$t=["expandable"],kt="RC_TABLE_INTERNAL_COL_DEFINE";function Ie($e){var Mt=$e.expandable,Pt=(0,dt.Z)($e,$t),wt;return"expandable"in $e?wt=(0,Ne.Z)((0,Ne.Z)({},Pt),Mt):wt=Pt,wt.showExpandColumn===!1&&(wt.expandIconColumnIndex=-1),wt}},63295:function(jn,li,De){"use strict";De.d(li,{Z:function(){return kt}});var Ne=De(71002),dt=Symbol.for("react.element"),Ut=Symbol.for("react.transitional.element"),$t=Symbol.for("react.fragment");function kt(Ie){return Ie&&(0,Ne.Z)(Ie)==="object"&&(Ie.$$typeof===dt||Ie.$$typeof===Ut)&&Ie.type===$t}},40830:function(jn,li,De){"use strict";var Ne={},dt=[],Ut=function(Qt){dt.push(Qt)};function $t(wt,Qt){if(0)var It}function kt(wt,Qt){if(0)var It}function Ie(){Ne={}}function $e(wt,Qt,It){!Qt&&!Ne[It]&&(wt(!1,It),Ne[It]=!0)}function Mt(wt,Qt){$e($t,wt,Qt)}function Pt(wt,Qt){$e(kt,wt,Qt)}Mt.preMessage=Ut,Mt.resetWarned=Ie,Mt.noteOnce=Pt,li.ZP=Mt},46762:function(jn,li){"use strict";var De;var Ne=Symbol.for("react.element"),dt=Symbol.for("react.portal"),Ut=Symbol.for("react.fragment"),$t=Symbol.for("react.strict_mode"),kt=Symbol.for("react.profiler"),Ie=Symbol.for("react.provider"),$e=Symbol.for("react.context"),Mt=Symbol.for("react.server_context"),Pt=Symbol.for("react.forward_ref"),wt=Symbol.for("react.suspense"),Qt=Symbol.for("react.suspense_list"),It=Symbol.for("react.memo"),sn=Symbol.for("react.lazy"),Re=Symbol.for("react.offscreen"),ne;ne=Symbol.for("react.module.reference");function te(he){if(typeof he=="object"&&he!==null){var le=he.$$typeof;switch(le){case Ne:switch(he=he.type,he){case Ut:case kt:case $t:case wt:case Qt:return he;default:switch(he=he&&he.$$typeof,he){case Mt:case $e:case Pt:case sn:case It:case Ie:return he;default:return le}}case dt:return le}}}De=$e,De=Ie,De=Ne,De=Pt,De=Ut,De=sn,De=It,De=dt,De=kt,De=$t,De=wt,De=Qt,De=function(){return!1},De=function(){return!1},De=function(he){return te(he)===$e},De=function(he){return te(he)===Ie},De=function(he){return typeof he=="object"&&he!==null&&he.$$typeof===Ne},De=function(he){return te(he)===Pt},De=function(he){return te(he)===Ut},De=function(he){return te(he)===sn},De=function(he){return te(he)===It},De=function(he){return te(he)===dt},De=function(he){return te(he)===kt},De=function(he){return te(he)===$t},De=function(he){return te(he)===wt},De=function(he){return te(he)===Qt},De=function(he){return typeof he=="string"||typeof he=="function"||he===Ut||he===kt||he===$t||he===wt||he===Qt||he===Re||typeof he=="object"&&he!==null&&(he.$$typeof===sn||he.$$typeof===It||he.$$typeof===Ie||he.$$typeof===$e||he.$$typeof===Pt||he.$$typeof===ne||he.getModuleId!==void 0)},De=te},35110:function(jn,li,De){"use strict";De(46762)},48387:function(jn,li,De){"use strict";De.d(li,{Qw:function(){return Zr},FJ:function(){return mr},hT:function(){return Gi},OF:function(){return po},ZP:function(){return Da}});function Ne(){return Ne=Object.assign?Object.assign.bind():function(Te){for(var Oe=1;Oe<arguments.length;Oe++){var Xe=arguments[Oe];for(var ot in Xe)({}).hasOwnProperty.call(Xe,ot)&&(Te[ot]=Xe[ot])}return Te},Ne.apply(null,arguments)}function dt(Te,Oe){(Oe==null||Oe>Te.length)&&(Oe=Te.length);for(var Xe=0,ot=Array(Oe);Xe<Oe;Xe++)ot[Xe]=Te[Xe];return ot}function Ut(Te){if(Array.isArray(Te))return dt(Te)}function $t(Te){if(typeof Symbol!="undefined"&&Te[Symbol.iterator]!=null||Te["@@iterator"]!=null)return Array.from(Te)}function kt(Te,Oe){if(Te){if(typeof Te=="string")return dt(Te,Oe);var Xe={}.toString.call(Te).slice(8,-1);return Xe==="Object"&&Te.constructor&&(Xe=Te.constructor.name),Xe==="Map"||Xe==="Set"?Array.from(Te):Xe==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Xe)?dt(Te,Oe):void 0}}function Ie(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function $e(Te){return Ut(Te)||$t(Te)||kt(Te)||Ie()}function Mt(Te){"@babel/helpers - typeof";return Mt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Oe){return typeof Oe}:function(Oe){return Oe&&typeof Symbol=="function"&&Oe.constructor===Symbol&&Oe!==Symbol.prototype?"symbol":typeof Oe},Mt(Te)}function Pt(Te,Oe){if(Mt(Te)!="object"||!Te)return Te;var Xe=Te[Symbol.toPrimitive];if(Xe!==void 0){var ot=Xe.call(Te,Oe||"default");if(Mt(ot)!="object")return ot;throw new TypeError("@@toPrimitive must return a primitive value.")}return(Oe==="string"?String:Number)(Te)}function wt(Te){var Oe=Pt(Te,"string");return Mt(Oe)=="symbol"?Oe:Oe+""}function Qt(Te,Oe,Xe){return(Oe=wt(Oe))in Te?Object.defineProperty(Te,Oe,{value:Xe,enumerable:!0,configurable:!0,writable:!0}):Te[Oe]=Xe,Te}function It(Te,Oe){var Xe=Object.keys(Te);if(Object.getOwnPropertySymbols){var ot=Object.getOwnPropertySymbols(Te);Oe&&(ot=ot.filter(function(Rt){return Object.getOwnPropertyDescriptor(Te,Rt).enumerable})),Xe.push.apply(Xe,ot)}return Xe}function sn(Te){for(var Oe=1;Oe<arguments.length;Oe++){var Xe=arguments[Oe]!=null?arguments[Oe]:{};Oe%2?It(Object(Xe),!0).forEach(function(ot){Qt(Te,ot,Xe[ot])}):Object.getOwnPropertyDescriptors?Object.defineProperties(Te,Object.getOwnPropertyDescriptors(Xe)):It(Object(Xe)).forEach(function(ot){Object.defineProperty(Te,ot,Object.getOwnPropertyDescriptor(Xe,ot))})}return Te}function Re(Te){if(Array.isArray(Te))return Te}function ne(Te,Oe){var Xe=Te==null?null:typeof Symbol!="undefined"&&Te[Symbol.iterator]||Te["@@iterator"];if(Xe!=null){var ot,Rt,Se,Le,je=[],Ke=!0,ct=!1;try{if(Se=(Xe=Xe.call(Te)).next,Oe===0){if(Object(Xe)!==Xe)return;Ke=!1}else for(;!(Ke=(ot=Se.call(Xe)).done)&&(je.push(ot.value),je.length!==Oe);Ke=!0);}catch(Et){ct=!0,Rt=Et}finally{try{if(!Ke&&Xe.return!=null&&(Le=Xe.return(),Object(Le)!==Le))return}finally{if(ct)throw Rt}}return je}}function te(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function he(Te,Oe){return Re(Te)||ne(Te,Oe)||kt(Te,Oe)||te()}function le(Te,Oe){if(Te==null)return{};var Xe={};for(var ot in Te)if({}.hasOwnProperty.call(Te,ot)){if(Oe.indexOf(ot)!==-1)continue;Xe[ot]=Te[ot]}return Xe}function pe(Te,Oe){if(Te==null)return{};var Xe,ot,Rt=le(Te,Oe);if(Object.getOwnPropertySymbols){var Se=Object.getOwnPropertySymbols(Te);for(ot=0;ot<Se.length;ot++)Xe=Se[ot],Oe.indexOf(Xe)===-1&&{}.propertyIsEnumerable.call(Te,Xe)&&(Rt[Xe]=Te[Xe])}return Rt}function me(){return me=Object.assign?Object.assign.bind():function(Te){for(var Oe=1;Oe<arguments.length;Oe++){var Xe=arguments[Oe];for(var ot in Xe)Object.prototype.hasOwnProperty.call(Xe,ot)&&(Te[ot]=Xe[ot])}return Te},me.apply(this,arguments)}function xe(Te,Oe){(Oe==null||Oe>Te.length)&&(Oe=Te.length);for(var Xe=0,ot=new Array(Oe);Xe<Oe;Xe++)ot[Xe]=Te[Xe];return ot}function Ee(Te){if(Array.isArray(Te))return xe(Te)}function Ge(Te){if(typeof Symbol!="undefined"&&Te[Symbol.iterator]!=null||Te["@@iterator"]!=null)return Array.from(Te)}function et(Te,Oe){if(Te){if(typeof Te=="string")return xe(Te,Oe);var Xe=Object.prototype.toString.call(Te).slice(8,-1);if(Xe==="Object"&&Te.constructor&&(Xe=Te.constructor.name),Xe==="Map"||Xe==="Set")return Array.from(Te);if(Xe==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Xe))return xe(Te,Oe)}}function ut(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function st(Te){return Ee(Te)||Ge(Te)||et(Te)||ut()}function it(Te){"@babel/helpers - typeof";return it=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Oe){return typeof Oe}:function(Oe){return Oe&&typeof Symbol=="function"&&Oe.constructor===Symbol&&Oe!==Symbol.prototype?"symbol":typeof Oe},it(Te)}function Nt(Te,Oe){if(it(Te)!=="object"||Te===null)return Te;var Xe=Te[Symbol.toPrimitive];if(Xe!==void 0){var ot=Xe.call(Te,Oe||"default");if(it(ot)!=="object")return ot;throw new TypeError("@@toPrimitive must return a primitive value.")}return(Oe==="string"?String:Number)(Te)}function St(Te){var Oe=Nt(Te,"string");return it(Oe)==="symbol"?Oe:String(Oe)}function Ft(Te,Oe,Xe){return Oe=St(Oe),Oe in Te?Object.defineProperty(Te,Oe,{value:Xe,enumerable:!0,configurable:!0,writable:!0}):Te[Oe]=Xe,Te}function cn(Te,Oe){var Xe=Object.keys(Te);if(Object.getOwnPropertySymbols){var ot=Object.getOwnPropertySymbols(Te);Oe&&(ot=ot.filter(function(Rt){return Object.getOwnPropertyDescriptor(Te,Rt).enumerable})),Xe.push.apply(Xe,ot)}return Xe}function Tt(Te){for(var Oe=1;Oe<arguments.length;Oe++){var Xe=arguments[Oe]!=null?arguments[Oe]:{};Oe%2?cn(Object(Xe),!0).forEach(function(ot){Ft(Te,ot,Xe[ot])}):Object.getOwnPropertyDescriptors?Object.defineProperties(Te,Object.getOwnPropertyDescriptors(Xe)):cn(Object(Xe)).forEach(function(ot){Object.defineProperty(Te,ot,Object.getOwnPropertyDescriptor(Xe,ot))})}return Te}function hi(Te){if(Array.isArray(Te))return Te}function di(Te,Oe){var Xe=Te==null?null:typeof Symbol!="undefined"&&Te[Symbol.iterator]||Te["@@iterator"];if(Xe!=null){var ot,Rt,Se,Le,je=[],Ke=!0,ct=!1;try{if(Se=(Xe=Xe.call(Te)).next,Oe===0){if(Object(Xe)!==Xe)return;Ke=!1}else for(;!(Ke=(ot=Se.call(Xe)).done)&&(je.push(ot.value),je.length!==Oe);Ke=!0);}catch(Et){ct=!0,Rt=Et}finally{try{if(!Ke&&Xe.return!=null&&(Le=Xe.return(),Object(Le)!==Le))return}finally{if(ct)throw Rt}}return je}}function zn(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Dn(Te,Oe){return hi(Te)||di(Te,Oe)||et(Te,Oe)||zn()}function nt(Te,Oe){if(Te==null)return{};var Xe={},ot=Object.keys(Te),Rt,Se;for(Se=0;Se<ot.length;Se++)Rt=ot[Se],!(Oe.indexOf(Rt)>=0)&&(Xe[Rt]=Te[Rt]);return Xe}function ze(Te,Oe){if(Te==null)return{};var Xe=nt(Te,Oe),ot,Rt;if(Object.getOwnPropertySymbols){var Se=Object.getOwnPropertySymbols(Te);for(Rt=0;Rt<Se.length;Rt++)ot=Se[Rt],!(Oe.indexOf(ot)>=0)&&Object.prototype.propertyIsEnumerable.call(Te,ot)&&(Xe[ot]=Te[ot])}return Xe}var ke=De(67294);function Wt(Te){var Oe=ke.useRef();Oe.current=Te;var Xe=ke.useCallback(function(){for(var ot,Rt=arguments.length,Se=new Array(Rt),Le=0;Le<Rt;Le++)Se[Le]=arguments[Le];return(ot=Oe.current)===null||ot===void 0?void 0:ot.call.apply(ot,[Oe].concat(Se))},[]);return Xe}function On(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var Lt=On()?ke.useLayoutEffect:ke.useEffect,xn=Lt,vn=function(Oe,Xe){var ot=ke.useRef(!0);Lt(function(){if(!ot.current)return Oe()},Xe),Lt(function(){return ot.current=!1,function(){ot.current=!0}},[])};function Xn(Te){var Oe=ke.useRef(!1),Xe=ke.useState(Te),ot=Dn(Xe,2),Rt=ot[0],Se=ot[1];ke.useEffect(function(){return Oe.current=!1,function(){Oe.current=!0}},[]);function Le(je,Ke){Ke&&Oe.current||Se(je)}return[Rt,Le]}function Ot(Te){return Te!==void 0}function ft(Te,Oe){var Xe=Oe||{},ot=Xe.defaultValue,Rt=Xe.value,Se=Xe.onChange,Le=Xe.postState,je=Xn(function(){return Ot(Rt)?Rt:Ot(ot)?typeof ot=="function"?ot():ot:typeof Te=="function"?Te():Te}),Ke=Dn(je,2),ct=Ke[0],Et=Ke[1],Bt=Rt!==void 0?Rt:ct,hn=Le?Le(Bt):Bt,qt=Wt(Se),nn=Xn([Bt]),Sn=Dn(nn,2),yn=Sn[0],Jn=Sn[1];vn(function(){var Mn=yn[0];ct!==Mn&&qt(ct,Mn)},[yn]),vn(function(){Ot(Rt)||Et(Rt)},[Rt]);var In=Wt(function(Mn,Kn){Et(Mn,Kn),Jn([Bt],Kn)});return[hn,In]}var Gt={};function an(Te,Oe){}function Jt(Te,Oe){}function Ve(){Gt={}}function be(Te,Oe,Xe){!Oe&&!Gt[Xe]&&(Te(!1,Xe),Gt[Xe]=!0)}function Pe(Te,Oe){be(an,Te,Oe)}function Be(Te,Oe){be(Jt,Te,Oe)}var Ze=Pe,Fe=De(94184),qe=De.n(Fe),dn=function(){if(typeof navigator=="undefined"||typeof window=="undefined")return!1;var Te=navigator.userAgent||navigator.vendor||window.opera;return/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i.test(Te)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw-(n|u)|c55\/|capi|ccwa|cdm-|cell|chtm|cldc|cmd-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc-s|devi|dica|dmob|do(c|p)o|ds(12|-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(-|_)|g1 u|g560|gene|gf-5|g-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd-(m|p|t)|hei-|hi(pt|ta)|hp( i|ip)|hs-c|ht(c(-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i-(20|go|ma)|i230|iac( |-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|-[a-w])|libw|lynx|m1-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|-([1-8]|c))|phil|pire|pl(ay|uc)|pn-2|po(ck|rt|se)|prox|psio|pt-g|qa-a|qc(07|12|21|32|60|-[2-7]|i-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h-|oo|p-)|sdk\/|se(c(-|0|1)|47|mc|nd|ri)|sgh-|shar|sie(-|m)|sk-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h-|v-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl-|tdg-|tel(i|m)|tim-|t-mo|to(pl|sh)|ts(70|m-|m3|m5)|tx-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas-|your|zeto|zte-/i.test(Te==null?void 0:Te.substr(0,4))},ui=De(95936);function $n(Te,Oe,Xe){var ot=ke.useRef({});return(!("value"in ot.current)||Xe(ot.current.condition,Oe))&&(ot.current.value=Te(),ot.current.condition=Oe),ot.current.value}function rn(Te,Oe){typeof Te=="function"?Te(Oe):it(Te)==="object"&&Te&&"current"in Te&&(Te.current=Oe)}function Hn(){for(var Te=arguments.length,Oe=new Array(Te),Xe=0;Xe<Te;Xe++)Oe[Xe]=arguments[Xe];var ot=Oe.filter(function(Rt){return Rt});return ot.length<=1?ot[0]:function(Rt){Oe.forEach(function(Se){rn(Se,Rt)})}}function Zt(){for(var Te=arguments.length,Oe=new Array(Te),Xe=0;Xe<Te;Xe++)Oe[Xe]=arguments[Xe];return $n(function(){return Hn.apply(void 0,Oe)},Oe,function(ot,Rt){return ot.length===Rt.length&&ot.every(function(Se,Le){return Se===Rt[Le]})})}function _n(Te){var Oe,Xe,ot=isMemo(Te)?Te.type.type:Te.type;return!(typeof ot=="function"&&!((Oe=ot.prototype)!==null&&Oe!==void 0&&Oe.render)||typeof Te=="function"&&!((Xe=Te.prototype)!==null&&Xe!==void 0&&Xe.render))}var ti=function(Oe){var Xe=Oe.className,ot=Oe.customizeIcon,Rt=Oe.customizeIconProps,Se=Oe.children,Le=Oe.onMouseDown,je=Oe.onClick,Ke=typeof ot=="function"?ot(Rt):ot;return ke.createElement("span",{className:Xe,onMouseDown:function(Et){Et.preventDefault(),Le==null||Le(Et)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:je,"aria-hidden":!0},Ke!==void 0?Ke:ke.createElement("span",{className:qe()(Xe.split(/\s+/).map(function(ct){return"".concat(ct,"-icon")}))},Se))},Ri=ti,oi=function(Oe,Xe,ot,Rt,Se){var Le=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,je=arguments.length>6?arguments[6]:void 0,Ke=arguments.length>7?arguments[7]:void 0,ct=ke.useMemo(function(){if(it(Rt)==="object")return Rt.clearIcon;if(Se)return Se},[Rt,Se]),Et=ke.useMemo(function(){return!!(!Le&&Rt&&(ot.length||je)&&!(Ke==="combobox"&&je===""))},[Rt,Le,ot.length,je,Ke]);return{allowClear:Et,clearIcon:ke.createElement(Ri,{className:"".concat(Oe,"-clear"),onMouseDown:Xe,customizeIcon:ct},"\xD7")}},wr=ke.createContext(null);function fr(){return ke.useContext(wr)}function Ei(){var Te=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,Oe=ke.useState(!1),Xe=Dn(Oe,2),ot=Xe[0],Rt=Xe[1],Se=ke.useRef(null),Le=function(){window.clearTimeout(Se.current)};ke.useEffect(function(){return Le},[]);var je=function(ct,Et){Le(),Se.current=window.setTimeout(function(){Rt(ct),Et&&Et()},Te)};return[ot,je,Le]}function Di(){var Te=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,Oe=ke.useRef(null),Xe=ke.useRef(null);ke.useEffect(function(){return function(){window.clearTimeout(Xe.current)}},[]);function ot(Rt){(Rt||Oe.current===null)&&(Oe.current=Rt),window.clearTimeout(Xe.current),Xe.current=window.setTimeout(function(){Oe.current=null},Te)}return[function(){return Oe.current},ot]}function uo(Te,Oe,Xe,ot){var Rt=ke.useRef(null);Rt.current={open:Oe,triggerOpen:Xe,customizedTrigger:ot},ke.useEffect(function(){function Se(Le){var je;if(!((je=Rt.current)!==null&&je!==void 0&&je.customizedTrigger)){var Ke=Le.target;Ke.shadowRoot&&Le.composed&&(Ke=Le.composedPath()[0]||Ke),Rt.current.open&&Te().filter(function(ct){return ct}).every(function(ct){return!ct.contains(Ke)&&ct!==Ke})&&Rt.current.triggerOpen(!1)}}return window.addEventListener("mousedown",Se),function(){return window.removeEventListener("mousedown",Se)}},[])}var vt={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(Oe){var Xe=Oe.keyCode;if(Oe.altKey&&!Oe.ctrlKey||Oe.metaKey||Xe>=vt.F1&&Xe<=vt.F12)return!1;switch(Xe){case vt.ALT:case vt.CAPS_LOCK:case vt.CONTEXT_MENU:case vt.CTRL:case vt.DOWN:case vt.END:case vt.ESC:case vt.HOME:case vt.INSERT:case vt.LEFT:case vt.MAC_FF_META:case vt.META:case vt.NUMLOCK:case vt.NUM_CENTER:case vt.PAGE_DOWN:case vt.PAGE_UP:case vt.PAUSE:case vt.PRINT_SCREEN:case vt.RIGHT:case vt.SHIFT:case vt.UP:case vt.WIN_KEY:case vt.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(Oe){if(Oe>=vt.ZERO&&Oe<=vt.NINE||Oe>=vt.NUM_ZERO&&Oe<=vt.NUM_MULTIPLY||Oe>=vt.A&&Oe<=vt.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&Oe===0)return!0;switch(Oe){case vt.SPACE:case vt.QUESTION_MARK:case vt.NUM_PLUS:case vt.NUM_MINUS:case vt.NUM_PERIOD:case vt.NUM_DIVISION:case vt.SEMICOLON:case vt.DASH:case vt.EQUALS:case vt.COMMA:case vt.PERIOD:case vt.SLASH:case vt.APOSTROPHE:case vt.SINGLE_QUOTE:case vt.OPEN_SQUARE_BRACKET:case vt.BACKSLASH:case vt.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},ei=vt;function co(Te){return Te&&![ei.ESC,ei.SHIFT,ei.BACKSPACE,ei.TAB,ei.WIN_KEY,ei.ALT,ei.META,ei.WIN_KEY_RIGHT,ei.CTRL,ei.SEMICOLON,ei.EQUALS,ei.CAPS_LOCK,ei.CONTEXT_MENU,ei.F1,ei.F2,ei.F3,ei.F4,ei.F5,ei.F6,ei.F7,ei.F8,ei.F9,ei.F10,ei.F11,ei.F12].includes(Te)}var bo=`accept acceptCharset accessKey action allowFullScreen allowTransparency
alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge
charSet checked classID className colSpan cols content contentEditable contextMenu
controls coords crossOrigin data dateTime default defer dir disabled download draggable
encType form formAction formEncType formMethod formNoValidate formTarget frameBorder
headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity
is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media
mediaGroup method min minLength multiple muted name noValidate nonce open
optimum pattern placeholder poster preload radioGroup readOnly rel required
reversed role rowSpan rows sandbox scope scoped scrolling seamless selected
shape size sizes span spellCheck src srcDoc srcLang srcSet start step style
summary tabIndex target title type useMap value width wmode wrap`,Ui=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown
onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick
onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown
onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel
onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough
onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata
onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,yo="".concat(bo," ").concat(Ui).split(/[\s\n]+/),ha="aria-",Ka="data-";function Ra(Te,Oe){return Te.indexOf(Oe)===0}function ca(Te){var Oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Xe;Oe===!1?Xe={aria:!0,data:!0,attr:!0}:Oe===!0?Xe={aria:!0}:Xe=Tt({},Oe);var ot={};return Object.keys(Te).forEach(function(Rt){(Xe.aria&&(Rt==="role"||Ra(Rt,ha))||Xe.data&&Ra(Rt,Ka)||Xe.attr&&yo.includes(Rt))&&(ot[Rt]=Te[Rt])}),ot}function ma(){return ma=Object.assign?Object.assign.bind():function(Te){for(var Oe=1;Oe<arguments.length;Oe++){var Xe=arguments[Oe];for(var ot in Xe)Object.prototype.hasOwnProperty.call(Xe,ot)&&(Te[ot]=Xe[ot])}return Te},ma.apply(this,arguments)}function Ho(Te){"@babel/helpers - typeof";return Ho=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Oe){return typeof Oe}:function(Oe){return Oe&&typeof Symbol=="function"&&Oe.constructor===Symbol&&Oe!==Symbol.prototype?"symbol":typeof Oe},Ho(Te)}function _r(Te,Oe){if(Ho(Te)!=="object"||Te===null)return Te;var Xe=Te[Symbol.toPrimitive];if(Xe!==void 0){var ot=Xe.call(Te,Oe||"default");if(Ho(ot)!=="object")return ot;throw new TypeError("@@toPrimitive must return a primitive value.")}return(Oe==="string"?String:Number)(Te)}function Fn(Te){var Oe=_r(Te,"string");return Ho(Oe)==="symbol"?Oe:String(Oe)}function we(Te,Oe,Xe){return Oe=Fn(Oe),Oe in Te?Object.defineProperty(Te,Oe,{value:Xe,enumerable:!0,configurable:!0,writable:!0}):Te[Oe]=Xe,Te}function Qn(Te,Oe){var Xe=Object.keys(Te);if(Object.getOwnPropertySymbols){var ot=Object.getOwnPropertySymbols(Te);Oe&&(ot=ot.filter(function(Rt){return Object.getOwnPropertyDescriptor(Te,Rt).enumerable})),Xe.push.apply(Xe,ot)}return Xe}function bn(Te){for(var Oe=1;Oe<arguments.length;Oe++){var Xe=arguments[Oe]!=null?arguments[Oe]:{};Oe%2?Qn(Object(Xe),!0).forEach(function(ot){we(Te,ot,Xe[ot])}):Object.getOwnPropertyDescriptors?Object.defineProperties(Te,Object.getOwnPropertyDescriptors(Xe)):Qn(Object(Xe)).forEach(function(ot){Object.defineProperty(Te,ot,Object.getOwnPropertyDescriptor(Xe,ot))})}return Te}function on(Te){if(Array.isArray(Te))return Te}function ln(Te,Oe){var Xe=Te==null?null:typeof Symbol!="undefined"&&Te[Symbol.iterator]||Te["@@iterator"];if(Xe!=null){var ot,Rt,Se,Le,je=[],Ke=!0,ct=!1;try{if(Se=(Xe=Xe.call(Te)).next,Oe===0){if(Object(Xe)!==Xe)return;Ke=!1}else for(;!(Ke=(ot=Se.call(Xe)).done)&&(je.push(ot.value),je.length!==Oe);Ke=!0);}catch(Et){ct=!0,Rt=Et}finally{try{if(!Ke&&Xe.return!=null&&(Le=Xe.return(),Object(Le)!==Le))return}finally{if(ct)throw Rt}}return je}}function gn(Te,Oe){(Oe==null||Oe>Te.length)&&(Oe=Te.length);for(var Xe=0,ot=new Array(Oe);Xe<Oe;Xe++)ot[Xe]=Te[Xe];return ot}function Vn(Te,Oe){if(Te){if(typeof Te=="string")return gn(Te,Oe);var Xe=Object.prototype.toString.call(Te).slice(8,-1);if(Xe==="Object"&&Te.constructor&&(Xe=Te.constructor.name),Xe==="Map"||Xe==="Set")return Array.from(Te);if(Xe==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Xe))return gn(Te,Oe)}}function _i(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function jt(Te,Oe){return on(Te)||ln(Te,Oe)||Vn(Te,Oe)||_i()}function zt(Te,Oe){if(Te==null)return{};var Xe={},ot=Object.keys(Te),Rt,Se;for(Se=0;Se<ot.length;Se++)Rt=ot[Se],!(Oe.indexOf(Rt)>=0)&&(Xe[Rt]=Te[Rt]);return Xe}function Ct(Te,Oe){if(Te==null)return{};var Xe=zt(Te,Oe),ot,Rt;if(Object.getOwnPropertySymbols){var Se=Object.getOwnPropertySymbols(Te);for(Rt=0;Rt<Se.length;Rt++)ot=Se[Rt],!(Oe.indexOf(ot)>=0)&&Object.prototype.propertyIsEnumerable.call(Te,ot)&&(Xe[ot]=Te[ot])}return Xe}var Yt=De(48555);function ci(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var vi=ci()?ke.useLayoutEffect:ke.useEffect,ai=function(Oe,Xe){var ot=ke.useRef(!0);vi(function(){return Oe(ot.current)},Xe),vi(function(){return ot.current=!1,function(){ot.current=!0}},[])},Kt=function(Oe,Xe){ai(function(ot){if(!ot)return Oe()},Xe)},wn=ai,pi=["prefixCls","invalidate","item","renderItem","responsive","responsiveDisabled","registerSize","itemKey","className","style","children","display","order","component"],ji=void 0;function Rn(Te,Oe){var Xe=Te.prefixCls,ot=Te.invalidate,Rt=Te.item,Se=Te.renderItem,Le=Te.responsive,je=Te.responsiveDisabled,Ke=Te.registerSize,ct=Te.itemKey,Et=Te.className,Bt=Te.style,hn=Te.children,qt=Te.display,nn=Te.order,Sn=Te.component,yn=Sn===void 0?"div":Sn,Jn=Ct(Te,pi),In=Le&&!qt;function Mn(Ai){Ke(ct,Ai)}ke.useEffect(function(){return function(){Mn(null)}},[]);var Kn=Se&&Rt!==ji?Se(Rt):hn,ni;ot||(ni={opacity:In?0:1,height:In?0:ji,overflowY:In?"hidden":ji,order:Le?nn:ji,pointerEvents:In?"none":ji,position:In?"absolute":ji});var yi={};In&&(yi["aria-hidden"]=!0);var $i=ke.createElement(yn,ma({className:qe()(!ot&&Xe,Et),style:bn(bn({},ni),Bt)},yi,Jn,{ref:Oe}),Kn);return Le&&($i=ke.createElement(Yt.Z,{onResize:function(bi){var dr=bi.offsetWidth;Mn(dr)},disabled:je},$i)),$i}var Dt=ke.forwardRef(Rn);Dt.displayName="Item";var wi=Dt;function gr(Te){var Oe=ke.useRef();Oe.current=Te;var Xe=ke.useCallback(function(){for(var ot,Rt=arguments.length,Se=new Array(Rt),Le=0;Le<Rt;Le++)Se[Le]=arguments[Le];return(ot=Oe.current)===null||ot===void 0?void 0:ot.call.apply(ot,[Oe].concat(Se))},[]);return Xe}var eo=De(73935),kn=function(Oe){return+setTimeout(Oe,16)},Xi=function(Oe){return clearTimeout(Oe)};typeof window!="undefined"&&"requestAnimationFrame"in window&&(kn=function(Oe){return window.requestAnimationFrame(Oe)},Xi=function(Oe){return window.cancelAnimationFrame(Oe)});var Lo=0,La=new Map;function $o(Te){La.delete(Te)}var qi=function(Oe){var Xe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;Lo+=1;var ot=Lo;function Rt(Se){if(Se===0)$o(ot),Oe();else{var Le=kn(function(){Rt(Se-1)});La.set(ot,Le)}}return Rt(Xe),ot};qi.cancel=function(Te){var Oe=La.get(Te);return $o(Oe),Xi(Oe)};var Zi=qi;function cr(Te){if(typeof MessageChannel=="undefined")Zi(Te);else{var Oe=new MessageChannel;Oe.port1.onmessage=function(){return Te()},Oe.port2.postMessage(void 0)}}function Co(){var Te=ke.useRef(null),Oe=function(ot){Te.current||(Te.current=[],cr(function(){(0,eo.unstable_batchedUpdates)(function(){Te.current.forEach(function(Rt){Rt()}),Te.current=null})})),Te.current.push(ot)};return Oe}function Zo(Te,Oe){var Xe=ke.useState(Oe),ot=jt(Xe,2),Rt=ot[0],Se=ot[1],Le=gr(function(je){Te(function(){Se(je)})});return[Rt,Le]}var ri=ke.createContext(null),Lr=["component"],ml=["className"],Fs=["className"],gs=function(Oe,Xe){var ot=ke.useContext(ri);if(!ot){var Rt=Oe.component,Se=Rt===void 0?"div":Rt,Le=Ct(Oe,Lr);return ke.createElement(Se,ma({},Le,{ref:Xe}))}var je=ot.className,Ke=Ct(ot,ml),ct=Oe.className,Et=Ct(Oe,Fs);return ke.createElement(ri.Provider,{value:null},ke.createElement(wi,ma({ref:Xe,className:qe()(je,ct)},Ke,Et)))},Vt=ke.forwardRef(gs);Vt.displayName="RawItem";var Kr=Vt,Ko=["prefixCls","data","renderItem","renderRawItem","itemKey","itemWidth","ssr","style","className","maxCount","renderRest","renderRawRest","suffix","component","itemComponent","onVisibleChange"],Er="responsive",Wa="invalidate";function Wo(Te){return"+ ".concat(Te.length," ...")}function ea(Te,Oe){var Xe=Te.prefixCls,ot=Xe===void 0?"rc-overflow":Xe,Rt=Te.data,Se=Rt===void 0?[]:Rt,Le=Te.renderItem,je=Te.renderRawItem,Ke=Te.itemKey,ct=Te.itemWidth,Et=ct===void 0?10:ct,Bt=Te.ssr,hn=Te.style,qt=Te.className,nn=Te.maxCount,Sn=Te.renderRest,yn=Te.renderRawRest,Jn=Te.suffix,In=Te.component,Mn=In===void 0?"div":In,Kn=Te.itemComponent,ni=Te.onVisibleChange,yi=Ct(Te,Ko),$i=Bt==="full",Ai=Co(),bi=Zo(Ai,null),dr=jt(bi,2),Wn=dr[0],Ji=dr[1],Pi=Wn||0,tr=Zo(Ai,new Map),ar=jt(tr,2),ki=ar[0],Fr=ar[1],hr=Zo(Ai,0),Mr=jt(hr,2),Ti=Mr[0],pr=Mr[1],qr=Zo(Ai,0),Po=jt(qr,2),no=Po[0],Qi=Po[1],zr=Zo(Ai,0),$r=jt(zr,2),lo=$r[0],Uo=$r[1],So=(0,ke.useState)(null),Ar=jt(So,2),ur=Ar[0],Vr=Ar[1],Do=(0,ke.useState)(null),Nr=jt(Do,2),Wi=Nr[0],ir=Nr[1],rr=ke.useMemo(function(){return Wi===null&&$i?Number.MAX_SAFE_INTEGER:Wi||0},[Wi,Wn]),Fi=(0,ke.useState)(!1),zi=jt(Fi,2),Sr=zi[0],io=zi[1],Xr="".concat(ot,"-item"),Ir=Math.max(Ti,no),wa=nn===Er,ra=Se.length&&wa,Xo=nn===Wa,pa=ra||typeof nn=="number"&&Se.length>nn,ro=(0,ke.useMemo)(function(){var xo=Se;return ra?Wn===null&&$i?xo=Se:xo=Se.slice(0,Math.min(Se.length,Pi/Et)):typeof nn=="number"&&(xo=Se.slice(0,nn)),xo},[Se,Et,Wn,nn,ra]),Jo=(0,ke.useMemo)(function(){return ra?Se.slice(rr+1):Se.slice(ro.length)},[Se,ro,ra,rr]),va=(0,ke.useCallback)(function(xo,zo){var na;return typeof Ke=="function"?Ke(xo):(na=Ke&&(xo==null?void 0:xo[Ke]))!==null&&na!==void 0?na:zo},[Ke]),ds=(0,ke.useCallback)(Le||function(xo){return xo},[Le]);function Pa(xo,zo,na){Wi===xo&&(zo===void 0||zo===ur)||(ir(xo),na||(io(xo<Se.length-1),ni==null||ni(xo)),zo!==void 0&&Vr(zo))}function Ba(xo,zo){Ji(zo.clientWidth)}function Bo(xo,zo){Fr(function(na){var js=new Map(na);return zo===null?js.delete(xo):js.set(xo,zo),js})}function Za(xo,zo){Qi(zo),pr(no)}function Fa(xo,zo){Uo(zo)}function ns(xo){return ki.get(va(ro[xo],xo))}wn(function(){if(Pi&&typeof Ir=="number"&&ro){var xo=lo,zo=ro.length,na=zo-1;if(!zo){Pa(0,null);return}for(var js=0;js<zo;js+=1){var us=ns(js);if($i&&(us=us||0),us===void 0){Pa(js-1,void 0,!0);break}if(xo+=us,na===0&&xo<=Pi||js===na-1&&xo+ns(na)<=Pi){Pa(na,null);break}else if(xo+Ir>Pi){Pa(js-1,xo-us-lo+no);break}}Jn&&ns(0)+lo>Pi&&Vr(null)}},[Pi,ki,no,lo,va,ro]);var Vi=Sr&&!!Jo.length,Ki={};ur!==null&&ra&&(Ki={position:"absolute",left:ur,top:0});var or={prefixCls:Xr,responsive:ra,component:Kn,invalidate:Xo},Jr=je?function(xo,zo){var na=va(xo,zo);return ke.createElement(ri.Provider,{key:na,value:bn(bn({},or),{},{order:zo,item:xo,itemKey:na,registerSize:Bo,display:zo<=rr})},je(xo,zo))}:function(xo,zo){var na=va(xo,zo);return ke.createElement(wi,ma({},or,{order:zo,key:na,item:xo,renderItem:ds,itemKey:na,registerSize:Bo,display:zo<=rr}))},ta,Ha={order:Vi?rr:Number.MAX_SAFE_INTEGER,className:"".concat(Xr,"-rest"),registerSize:Za,display:Vi};if(yn)yn&&(ta=ke.createElement(ri.Provider,{value:bn(bn({},or),Ha)},yn(Jo)));else{var ls=Sn||Wo;ta=ke.createElement(wi,ma({},or,Ha),typeof ls=="function"?ls(Jo):ls)}var bt=ke.createElement(Mn,ma({className:qe()(!Xo&&ot,qt),style:hn,ref:Oe},yi),ro.map(Jr),pa?ta:null,Jn&&ke.createElement(wi,ma({},or,{responsive:wa,responsiveDisabled:!ra,order:rr,className:"".concat(Xr,"-suffix"),registerSize:Fa,display:!0,style:Ki}),Jn));return wa&&(bt=ke.createElement(Yt.Z,{onResize:Ba,disabled:!ra},bt)),bt}var fo=ke.forwardRef(ea);fo.displayName="Overflow",fo.Item=Kr,fo.RESPONSIVE=Er,fo.INVALIDATE=Wa;var Oo=fo,xa=Oo,An=function(Oe,Xe){var ot,Rt=Oe.prefixCls,Se=Oe.id,Le=Oe.inputElement,je=Oe.disabled,Ke=Oe.tabIndex,ct=Oe.autoFocus,Et=Oe.autoComplete,Bt=Oe.editable,hn=Oe.activeDescendantId,qt=Oe.value,nn=Oe.maxLength,Sn=Oe.onKeyDown,yn=Oe.onMouseDown,Jn=Oe.onChange,In=Oe.onPaste,Mn=Oe.onCompositionStart,Kn=Oe.onCompositionEnd,ni=Oe.onBlur,yi=Oe.open,$i=Oe.attrs,Ai=Le||ke.createElement("input",null),bi=Ai,dr=bi.ref,Wn=bi.props,Ji=Wn.onKeyDown,Pi=Wn.onChange,tr=Wn.onMouseDown,ar=Wn.onCompositionStart,ki=Wn.onCompositionEnd,Fr=Wn.onBlur,hr=Wn.style;return"maxLength"in Ai.props,Ai=ke.cloneElement(Ai,Tt(Tt(Tt({type:"search"},Wn),{},{id:Se,ref:Hn(Xe,dr),disabled:je,tabIndex:Ke,autoComplete:Et||"off",autoFocus:ct,className:qe()("".concat(Rt,"-selection-search-input"),(ot=Ai)===null||ot===void 0||(ot=ot.props)===null||ot===void 0?void 0:ot.className),role:"combobox","aria-expanded":yi||!1,"aria-haspopup":"listbox","aria-owns":"".concat(Se,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(Se,"_list"),"aria-activedescendant":yi?hn:void 0},$i),{},{value:Bt?qt:"",maxLength:nn,readOnly:!Bt,unselectable:Bt?null:"on",style:Tt(Tt({},hr),{},{opacity:Bt?null:0}),onKeyDown:function(Ti){Sn(Ti),Ji&&Ji(Ti)},onMouseDown:function(Ti){yn(Ti),tr&&tr(Ti)},onChange:function(Ti){Jn(Ti),Pi&&Pi(Ti)},onCompositionStart:function(Ti){Mn(Ti),ar&&ar(Ti)},onCompositionEnd:function(Ti){Kn(Ti),ki&&ki(Ti)},onPaste:In,onBlur:function(Ti){ni(Ti),Fr&&Fr(Ti)}})),Ai},Ya=ke.forwardRef(An),Pn=Ya;function jo(Te){return Array.isArray(Te)?Te:Te!==void 0?[Te]:[]}var Ws=typeof window!="undefined"&&window.document&&window.document.documentElement,qa=Ws;function bl(Te){return Te!=null}function Xa(Te){return!Te&&Te!==0}function _o(Te){return["string","number"].includes(it(Te))}function Va(Te){var Oe=void 0;return Te&&(_o(Te.title)?Oe=Te.title.toString():_o(Te.label)&&(Oe=Te.label.toString())),Oe}function il(Te,Oe){qa?ke.useLayoutEffect(Te,Oe):ke.useEffect(Te,Oe)}function Na(Te){var Oe;return(Oe=Te.key)!==null&&Oe!==void 0?Oe:Te.value}var Li=function(Oe){Oe.preventDefault(),Oe.stopPropagation()},Qe=function(Oe){var Xe=Oe.id,ot=Oe.prefixCls,Rt=Oe.values,Se=Oe.open,Le=Oe.searchValue,je=Oe.autoClearSearchValue,Ke=Oe.inputRef,ct=Oe.placeholder,Et=Oe.disabled,Bt=Oe.mode,hn=Oe.showSearch,qt=Oe.autoFocus,nn=Oe.autoComplete,Sn=Oe.activeDescendantId,yn=Oe.tabIndex,Jn=Oe.removeIcon,In=Oe.maxTagCount,Mn=Oe.maxTagTextLength,Kn=Oe.maxTagPlaceholder,ni=Kn===void 0?function(Do){return"+ ".concat(Do.length," ...")}:Kn,yi=Oe.tagRender,$i=Oe.onToggleOpen,Ai=Oe.onRemove,bi=Oe.onInputChange,dr=Oe.onInputPaste,Wn=Oe.onInputKeyDown,Ji=Oe.onInputMouseDown,Pi=Oe.onInputCompositionStart,tr=Oe.onInputCompositionEnd,ar=Oe.onInputBlur,ki=ke.useRef(null),Fr=(0,ke.useState)(0),hr=Dn(Fr,2),Mr=hr[0],Ti=hr[1],pr=(0,ke.useState)(!1),qr=Dn(pr,2),Po=qr[0],no=qr[1],Qi="".concat(ot,"-selection"),zr=Se||Bt==="multiple"&&je===!1||Bt==="tags"?Le:"",$r=Bt==="tags"||Bt==="multiple"&&je===!1||hn&&(Se||Po);il(function(){Ti(ki.current.scrollWidth)},[zr]);var lo=function(Nr,Wi,ir,rr,Fi){return ke.createElement("span",{title:Va(Nr),className:qe()("".concat(Qi,"-item"),Ft({},"".concat(Qi,"-item-disabled"),ir))},ke.createElement("span",{className:"".concat(Qi,"-item-content")},Wi),rr&&ke.createElement(Ri,{className:"".concat(Qi,"-item-remove"),onMouseDown:Li,onClick:Fi,customizeIcon:Jn},"\xD7"))},Uo=function(Nr,Wi,ir,rr,Fi,zi){var Sr=function(Xr){Li(Xr),$i(!Se)};return ke.createElement("span",{onMouseDown:Sr},yi({label:Wi,value:Nr,disabled:ir,closable:rr,onClose:Fi,isMaxTag:!!zi}))},So=function(Nr){var Wi=Nr.disabled,ir=Nr.label,rr=Nr.value,Fi=!Et&&!Wi,zi=ir;if(typeof Mn=="number"&&(typeof ir=="string"||typeof ir=="number")){var Sr=String(zi);Sr.length>Mn&&(zi="".concat(Sr.slice(0,Mn),"..."))}var io=function(Ir){Ir&&Ir.stopPropagation(),Ai(Nr)};return typeof yi=="function"?Uo(rr,zi,Wi,Fi,io):lo(Nr,zi,Wi,Fi,io)},Ar=function(Nr){if(!Rt.length)return null;var Wi=typeof ni=="function"?ni(Nr):ni;return typeof yi=="function"?Uo(void 0,Wi,!1,!1,void 0,!0):lo({title:Wi},Wi,!1)},ur=ke.createElement("div",{className:"".concat(Qi,"-search"),style:{width:Mr},onFocus:function(){no(!0)},onBlur:function(){no(!1)}},ke.createElement(Pn,{ref:Ke,open:Se,prefixCls:ot,id:Xe,inputElement:null,disabled:Et,autoFocus:qt,autoComplete:nn,editable:$r,activeDescendantId:Sn,value:zr,onKeyDown:Wn,onMouseDown:Ji,onChange:bi,onPaste:dr,onCompositionStart:Pi,onCompositionEnd:tr,onBlur:ar,tabIndex:yn,attrs:ca(Oe,!0)}),ke.createElement("span",{ref:ki,className:"".concat(Qi,"-search-mirror"),"aria-hidden":!0},zr,"\xA0")),Vr=ke.createElement(xa,{prefixCls:"".concat(Qi,"-overflow"),data:Rt,renderItem:So,renderRest:Ar,suffix:ur,itemKey:Na,maxCount:In});return ke.createElement("span",{className:"".concat(Qi,"-wrap")},Vr,!Rt.length&&!zr&&ke.createElement("span",{className:"".concat(Qi,"-placeholder")},ct))},bs=Qe,Ul=function(Oe){var Xe=Oe.inputElement,ot=Oe.prefixCls,Rt=Oe.id,Se=Oe.inputRef,Le=Oe.disabled,je=Oe.autoFocus,Ke=Oe.autoComplete,ct=Oe.activeDescendantId,Et=Oe.mode,Bt=Oe.open,hn=Oe.values,qt=Oe.placeholder,nn=Oe.tabIndex,Sn=Oe.showSearch,yn=Oe.searchValue,Jn=Oe.activeValue,In=Oe.maxLength,Mn=Oe.onInputKeyDown,Kn=Oe.onInputMouseDown,ni=Oe.onInputChange,yi=Oe.onInputPaste,$i=Oe.onInputCompositionStart,Ai=Oe.onInputCompositionEnd,bi=Oe.onInputBlur,dr=Oe.title,Wn=ke.useState(!1),Ji=Dn(Wn,2),Pi=Ji[0],tr=Ji[1],ar=Et==="combobox",ki=ar||Sn,Fr=hn[0],hr=yn||"";ar&&Jn&&!Pi&&(hr=Jn),ke.useEffect(function(){ar&&tr(!1)},[ar,Jn]);var Mr=Et!=="combobox"&&!Bt&&!Sn?!1:!!hr,Ti=dr===void 0?Va(Fr):dr,pr=ke.useMemo(function(){return Fr?null:ke.createElement("span",{className:"".concat(ot,"-selection-placeholder"),style:Mr?{visibility:"hidden"}:void 0},qt)},[Fr,Mr,qt,ot]);return ke.createElement("span",{className:"".concat(ot,"-selection-wrap")},ke.createElement("span",{className:"".concat(ot,"-selection-search")},ke.createElement(Pn,{ref:Se,prefixCls:ot,id:Rt,open:Bt,inputElement:Xe,disabled:Le,autoFocus:je,autoComplete:Ke,editable:ki,activeDescendantId:ct,value:hr,onKeyDown:Mn,onMouseDown:Kn,onChange:function(Po){tr(!0),ni(Po)},onPaste:yi,onCompositionStart:$i,onCompositionEnd:Ai,onBlur:bi,tabIndex:nn,attrs:ca(Oe,!0),maxLength:ar?In:void 0})),!ar&&Fr?ke.createElement("span",{className:"".concat(ot,"-selection-item"),title:Ti,style:Mr?{visibility:"hidden"}:void 0},Fr.label):null,pr)},Zl=Ul,rl=function(Oe,Xe){var ot=(0,ke.useRef)(null),Rt=(0,ke.useRef)(!1),Se=Oe.prefixCls,Le=Oe.open,je=Oe.mode,Ke=Oe.showSearch,ct=Oe.tokenWithEnter,Et=Oe.disabled,Bt=Oe.prefix,hn=Oe.autoClearSearchValue,qt=Oe.onSearch,nn=Oe.onSearchSubmit,Sn=Oe.onToggleOpen,yn=Oe.onInputKeyDown,Jn=Oe.onInputBlur,In=Oe.domRef;ke.useImperativeHandle(Xe,function(){return{focus:function(Ti){ot.current.focus(Ti)},blur:function(){ot.current.blur()}}});var Mn=Di(0),Kn=Dn(Mn,2),ni=Kn[0],yi=Kn[1],$i=function(Ti){var pr=Ti.which,qr=ot.current instanceof HTMLTextAreaElement;!qr&&Le&&(pr===ei.UP||pr===ei.DOWN)&&Ti.preventDefault(),yn&&yn(Ti),pr===ei.ENTER&&je==="tags"&&!Rt.current&&!Le&&(nn==null||nn(Ti.target.value)),!(qr&&!Le&&~[ei.UP,ei.DOWN,ei.LEFT,ei.RIGHT].indexOf(pr))&&co(pr)&&Sn(!0)},Ai=function(){yi(!0)},bi=(0,ke.useRef)(null),dr=function(Ti){qt(Ti,!0,Rt.current)!==!1&&Sn(!0)},Wn=function(){Rt.current=!0},Ji=function(Ti){Rt.current=!1,je!=="combobox"&&dr(Ti.target.value)},Pi=function(Ti){var pr=Ti.target.value;if(ct&&bi.current&&/[\r\n]/.test(bi.current)){var qr=bi.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");pr=pr.replace(qr,bi.current)}bi.current=null,dr(pr)},tr=function(Ti){var pr=Ti.clipboardData,qr=pr==null?void 0:pr.getData("text");bi.current=qr||""},ar=function(Ti){var pr=Ti.target;if(pr!==ot.current){var qr=document.body.style.msTouchAction!==void 0;qr?setTimeout(function(){ot.current.focus()}):ot.current.focus()}},ki=function(Ti){var pr=ni();Ti.target!==ot.current&&!pr&&!(je==="combobox"&&Et)&&Ti.preventDefault(),(je!=="combobox"&&(!Ke||!pr)||!Le)&&(Le&&hn!==!1&&qt("",!0,!1),Sn())},Fr={inputRef:ot,onInputKeyDown:$i,onInputMouseDown:Ai,onInputChange:Pi,onInputPaste:tr,onInputCompositionStart:Wn,onInputCompositionEnd:Ji,onInputBlur:Jn},hr=je==="multiple"||je==="tags"?ke.createElement(bs,me({},Oe,Fr)):ke.createElement(Zl,me({},Oe,Fr));return ke.createElement("div",{ref:In,className:"".concat(Se,"-selector"),onClick:ar,onMouseDown:ki},Bt&&ke.createElement("div",{className:"".concat(Se,"-prefix")},Bt),hr)},tu=ke.forwardRef(rl),Il=tu,Hu=De(98280),nu=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],Ua=function(Oe){var Xe=Oe===!0?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:Xe,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:Xe,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:Xe,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:Xe,adjustY:1},htmlRegion:"scroll"}}},ps=function(Oe,Xe){var ot=Oe.prefixCls,Rt=Oe.disabled,Se=Oe.visible,Le=Oe.children,je=Oe.popupElement,Ke=Oe.animation,ct=Oe.transitionName,Et=Oe.dropdownStyle,Bt=Oe.dropdownClassName,hn=Oe.direction,qt=hn===void 0?"ltr":hn,nn=Oe.placement,Sn=Oe.builtinPlacements,yn=Oe.dropdownMatchSelectWidth,Jn=Oe.dropdownRender,In=Oe.dropdownAlign,Mn=Oe.getPopupContainer,Kn=Oe.empty,ni=Oe.getTriggerDOMNode,yi=Oe.onPopupVisibleChange,$i=Oe.onPopupMouseEnter,Ai=ze(Oe,nu),bi="".concat(ot,"-dropdown"),dr=je;Jn&&(dr=Jn(je));var Wn=ke.useMemo(function(){return Sn||Ua(yn)},[Sn,yn]),Ji=Ke?"".concat(bi,"-").concat(Ke):ct,Pi=typeof yn=="number",tr=ke.useMemo(function(){return Pi?null:yn===!1?"minWidth":"width"},[yn,Pi]),ar=Et;Pi&&(ar=Tt(Tt({},ar),{},{width:yn}));var ki=ke.useRef(null);return ke.useImperativeHandle(Xe,function(){return{getPopupElement:function(){var hr;return(hr=ki.current)===null||hr===void 0?void 0:hr.popupElement}}}),ke.createElement(Hu.Z,me({},Ai,{showAction:yi?["click"]:[],hideAction:yi?["click"]:[],popupPlacement:nn||(qt==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:Wn,prefixCls:bi,popupTransitionName:Ji,popup:ke.createElement("div",{onMouseEnter:$i},dr),ref:ki,stretch:tr,popupAlign:In,popupVisible:Se,getPopupContainer:Mn,popupClassName:qe()(Bt,Ft({},"".concat(bi,"-empty"),Kn)),popupStyle:ar,getTriggerDOMNode:ni,onPopupVisibleChange:yi}),Le)},Or=ke.forwardRef(ps),Pr=Or;function so(Te){return hi(Te)||Ge(Te)||et(Te)||zn()}function fn(Te,Oe){var Xe=Te.key,ot;return"value"in Te&&(ot=Te.value),Xe!=null?Xe:ot!==void 0?ot:"rc-index-key-".concat(Oe)}function jr(Te){return typeof Te!="undefined"&&!Number.isNaN(Te)}function Ao(Te,Oe){var Xe=Te||{},ot=Xe.label,Rt=Xe.value,Se=Xe.options,Le=Xe.groupLabel,je=ot||(Oe?"children":"label");return{label:je,value:Rt||"value",options:Se||"options",groupLabel:Le||je}}function $a(Te){var Oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Xe=Oe.fieldNames,ot=Oe.childrenAsData,Rt=[],Se=Ao(Xe,!1),Le=Se.label,je=Se.value,Ke=Se.options,ct=Se.groupLabel;function Et(Bt,hn){Array.isArray(Bt)&&Bt.forEach(function(qt){if(hn||!(Ke in qt)){var nn=qt[je];Rt.push({key:fn(qt,Rt.length),groupOption:hn,data:qt,label:qt[Le],value:nn})}else{var Sn=qt[ct];Sn===void 0&&ot&&(Sn=qt.label),Rt.push({key:fn(qt,Rt.length),group:!0,data:qt,label:Sn}),Et(qt[Ke],!0)}})}return Et(Te,!1),Rt}function Ia(Te){var Oe=Tt({},Te);return"props"in Oe||Object.defineProperty(Oe,"props",{get:function(){return Ze(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),Oe}}),Oe}var ms=function(Oe,Xe,ot){if(!Xe||!Xe.length)return null;var Rt=!1,Se=function je(Ke,ct){var Et=so(ct),Bt=Et[0],hn=Et.slice(1);if(!Bt)return[Ke];var qt=Ke.split(Bt);return Rt=Rt||qt.length>1,qt.reduce(function(nn,Sn){return[].concat(st(nn),st(je(Sn,hn)))},[]).filter(Boolean)},Le=Se(Oe,Xe);return Rt?typeof ot!="undefined"?Le.slice(0,ot):Le:null},Vs=ke.createContext(null),el=Vs;function vl(Te){var Oe=Te.visible,Xe=Te.values;if(!Oe)return null;var ot=50;return ke.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},"".concat(Xe.slice(0,ot).map(function(Rt){var Se=Rt.label,Le=Rt.value;return["number","string"].includes(it(Se))?Se:Le}).join(", ")),Xe.length>ot?", ...":null)}var Gu=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","prefix","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],Fu=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],Xt=function(Oe){return Oe==="tags"||Oe==="multiple"},Ll=ke.forwardRef(function(Te,Oe){var Xe,ot=Te.id,Rt=Te.prefixCls,Se=Te.className,Le=Te.showSearch,je=Te.tagRender,Ke=Te.direction,ct=Te.omitDomProps,Et=Te.displayValues,Bt=Te.onDisplayValuesChange,hn=Te.emptyOptions,qt=Te.notFoundContent,nn=qt===void 0?"Not Found":qt,Sn=Te.onClear,yn=Te.mode,Jn=Te.disabled,In=Te.loading,Mn=Te.getInputElement,Kn=Te.getRawInputElement,ni=Te.open,yi=Te.defaultOpen,$i=Te.onDropdownVisibleChange,Ai=Te.activeValue,bi=Te.onActiveValueChange,dr=Te.activeDescendantId,Wn=Te.searchValue,Ji=Te.autoClearSearchValue,Pi=Te.onSearch,tr=Te.onSearchSplit,ar=Te.tokenSeparators,ki=Te.allowClear,Fr=Te.prefix,hr=Te.suffixIcon,Mr=Te.clearIcon,Ti=Te.OptionList,pr=Te.animation,qr=Te.transitionName,Po=Te.dropdownStyle,no=Te.dropdownClassName,Qi=Te.dropdownMatchSelectWidth,zr=Te.dropdownRender,$r=Te.dropdownAlign,lo=Te.placement,Uo=Te.builtinPlacements,So=Te.getPopupContainer,Ar=Te.showAction,ur=Ar===void 0?[]:Ar,Vr=Te.onFocus,Do=Te.onBlur,Nr=Te.onKeyUp,Wi=Te.onKeyDown,ir=Te.onMouseDown,rr=ze(Te,Gu),Fi=Xt(yn),zi=(Le!==void 0?Le:Fi)||yn==="combobox",Sr=Tt({},rr);Fu.forEach(function(cs){delete Sr[cs]}),ct==null||ct.forEach(function(cs){delete Sr[cs]});var io=ke.useState(!1),Xr=Dn(io,2),Ir=Xr[0],wa=Xr[1];ke.useEffect(function(){wa(dn())},[]);var ra=ke.useRef(null),Xo=ke.useRef(null),pa=ke.useRef(null),ro=ke.useRef(null),Jo=ke.useRef(null),va=ke.useRef(!1),ds=Ei(),Pa=Dn(ds,3),Ba=Pa[0],Bo=Pa[1],Za=Pa[2];ke.useImperativeHandle(Oe,function(){var cs,Qa;return{focus:(cs=ro.current)===null||cs===void 0?void 0:cs.focus,blur:(Qa=ro.current)===null||Qa===void 0?void 0:Qa.blur,scrollTo:function(Jl){var Qs;return(Qs=Jo.current)===null||Qs===void 0?void 0:Qs.scrollTo(Jl)},nativeElement:ra.current||Xo.current}});var Fa=ke.useMemo(function(){var cs;if(yn!=="combobox")return Wn;var Qa=(cs=Et[0])===null||cs===void 0?void 0:cs.value;return typeof Qa=="string"||typeof Qa=="number"?String(Qa):""},[Wn,yn,Et]),ns=yn==="combobox"&&typeof Mn=="function"&&Mn()||null,Vi=typeof Kn=="function"&&Kn(),Ki=Zt(Xo,Vi==null||(Xe=Vi.props)===null||Xe===void 0?void 0:Xe.ref),or=ke.useState(!1),Jr=Dn(or,2),ta=Jr[0],Ha=Jr[1];xn(function(){Ha(!0)},[]);var ls=ft(!1,{defaultValue:yi,value:ni}),bt=Dn(ls,2),xo=bt[0],zo=bt[1],na=ta?xo:!1,js=!nn&&hn;(Jn||js&&na&&yn==="combobox")&&(na=!1);var us=js?!1:na,Hi=ke.useCallback(function(cs){var Qa=cs!==void 0?cs:!na;Jn||(zo(Qa),na!==Qa&&($i==null||$i(Qa)))},[Jn,na,zo,$i]),Tr=ke.useMemo(function(){return(ar||[]).some(function(cs){return[`
`,`\r
`].includes(cs)})},[ar]),nr=ke.useContext(el)||{},ho=nr.maxCount,Ca=nr.rawValues,Rr=function(Qa,au,Jl){if(!(Fi&&jr(ho)&&(Ca==null?void 0:Ca.size)>=ho)){var Qs=!0,Ea=Qa;bi==null||bi(null);var ba=ms(Qa,ar,jr(ho)?ho-Ca.size:void 0),cl=Jl?null:ba;return yn!=="combobox"&&cl&&(Ea="",tr==null||tr(cl),Hi(!1),Qs=!1),Pi&&Fa!==Ea&&Pi(Ea,{source:au?"typing":"effect"}),Qs}},Qo=function(Qa){!Qa||!Qa.trim()||Pi(Qa,{source:"submit"})};ke.useEffect(function(){!na&&!Fi&&yn!=="combobox"&&Rr("",!1,!1)},[na]),ke.useEffect(function(){xo&&Jn&&zo(!1),Jn&&!va.current&&Bo(!1)},[Jn]);var Eo=Di(),Go=Dn(Eo,2),fa=Go[0],Aa=Go[1],ll=ke.useRef(!1),Yl=function(Qa){var au=fa(),Jl=Qa.key,Qs=Jl==="Enter";if(Qs&&(yn!=="combobox"&&Qa.preventDefault(),na||Hi(!0)),Aa(!!Fa),Jl==="Backspace"&&!au&&Fi&&!Fa&&Et.length){for(var Ea=st(Et),ba=null,cl=Ea.length-1;cl>=0;cl-=1){var zs=Ea[cl];if(!zs.disabled){Ea.splice(cl,1),ba=zs;break}}ba&&Bt(Ea,{type:"remove",values:[ba]})}for(var dl=arguments.length,Sl=new Array(dl>1?dl-1:0),su=1;su<dl;su++)Sl[su-1]=arguments[su];if(na&&(!Qs||!ll.current)){var Vl;Qs&&(ll.current=!0),(Vl=Jo.current)===null||Vl===void 0||Vl.onKeyDown.apply(Vl,[Qa].concat(Sl))}Wi==null||Wi.apply(void 0,[Qa].concat(Sl))},ya=function(Qa){for(var au=arguments.length,Jl=new Array(au>1?au-1:0),Qs=1;Qs<au;Qs++)Jl[Qs-1]=arguments[Qs];if(na){var Ea;(Ea=Jo.current)===null||Ea===void 0||Ea.onKeyUp.apply(Ea,[Qa].concat(Jl))}Qa.key==="Enter"&&(ll.current=!1),Nr==null||Nr.apply(void 0,[Qa].concat(Jl))},Yo=function(Qa){var au=Et.filter(function(Jl){return Jl!==Qa});Bt(au,{type:"remove",values:[Qa]})},Sa=function(){ll.current=!1},is=ke.useRef(!1),Bs=function(){Bo(!0),Jn||(Vr&&!is.current&&Vr.apply(void 0,arguments),ur.includes("focus")&&Hi(!0)),is.current=!0},tl=function(){va.current=!0,Bo(!1,function(){is.current=!1,va.current=!1,Hi(!1)}),!Jn&&(Fa&&(yn==="tags"?Pi(Fa,{source:"submit"}):yn==="multiple"&&Pi("",{source:"blur"})),Do&&Do.apply(void 0,arguments))},oo=[];ke.useEffect(function(){return function(){oo.forEach(function(cs){return clearTimeout(cs)}),oo.splice(0,oo.length)}},[]);var Ur=function(Qa){var au,Jl=Qa.target,Qs=(au=pa.current)===null||au===void 0?void 0:au.getPopupElement();if(Qs&&Qs.contains(Jl)){var Ea=setTimeout(function(){var dl=oo.indexOf(Ea);if(dl!==-1&&oo.splice(dl,1),Za(),!Ir&&!Qs.contains(document.activeElement)){var Sl;(Sl=ro.current)===null||Sl===void 0||Sl.focus()}});oo.push(Ea)}for(var ba=arguments.length,cl=new Array(ba>1?ba-1:0),zs=1;zs<ba;zs++)cl[zs-1]=arguments[zs];ir==null||ir.apply(void 0,[Qa].concat(cl))},hs=ke.useState({}),ul=Dn(hs,2),nl=ul[1];function hl(){nl({})}var Os;Vi&&(Os=function(Qa){Hi(Qa)}),uo(function(){var cs;return[ra.current,(cs=pa.current)===null||cs===void 0?void 0:cs.getPopupElement()]},us,Hi,!!Vi);var Xl=ke.useMemo(function(){return Tt(Tt({},Te),{},{notFoundContent:nn,open:na,triggerOpen:us,id:ot,showSearch:zi,multiple:Fi,toggleOpen:Hi})},[Te,nn,us,na,ot,zi,Fi,Hi]),Ps=!!hr||In,Ol;Ps&&(Ol=ke.createElement(Ri,{className:qe()("".concat(Rt,"-arrow"),Ft({},"".concat(Rt,"-arrow-loading"),In)),customizeIcon:hr,customizeIconProps:{loading:In,searchValue:Fa,open:na,focused:Ba,showSearch:zi}}));var eh=function(){var Qa;Sn==null||Sn(),(Qa=ro.current)===null||Qa===void 0||Qa.focus(),Bt([],{type:"clear",values:Et}),Rr("",!1,!1)},Vh=oi(Rt,eh,Et,ki,Mr,Jn,Fa,yn),jc=Vh.allowClear,Lc=Vh.clearIcon,pd=ke.createElement(Ti,{ref:Jo}),zc=qe()(Rt,Se,Ft(Ft(Ft(Ft(Ft(Ft(Ft(Ft(Ft(Ft({},"".concat(Rt,"-focused"),Ba),"".concat(Rt,"-multiple"),Fi),"".concat(Rt,"-single"),!Fi),"".concat(Rt,"-allow-clear"),ki),"".concat(Rt,"-show-arrow"),Ps),"".concat(Rt,"-disabled"),Jn),"".concat(Rt,"-loading"),In),"".concat(Rt,"-open"),na),"".concat(Rt,"-customize-input"),ns),"".concat(Rt,"-show-search"),zi)),ed=ke.createElement(Pr,{ref:pa,disabled:Jn,prefixCls:Rt,visible:us,popupElement:pd,animation:pr,transitionName:qr,dropdownStyle:Po,dropdownClassName:no,direction:Ke,dropdownMatchSelectWidth:Qi,dropdownRender:zr,dropdownAlign:$r,placement:lo,builtinPlacements:Uo,getPopupContainer:So,empty:hn,getTriggerDOMNode:function(Qa){return Xo.current||Qa},onPopupVisibleChange:Os,onPopupMouseEnter:hl},Vi?ke.cloneElement(Vi,{ref:Ki}):ke.createElement(Il,me({},Te,{domRef:Xo,prefixCls:Rt,inputElement:ns,ref:ro,id:ot,prefix:Fr,showSearch:zi,autoClearSearchValue:Ji,mode:yn,activeDescendantId:dr,tagRender:je,values:Et,open:na,onToggleOpen:Hi,activeValue:Ai,searchValue:Fa,onSearch:Rr,onSearchSubmit:Qo,onRemove:Yo,tokenWithEnter:Tr,onInputBlur:Sa}))),dh;return Vi?dh=ed:dh=ke.createElement("div",me({className:zc},Sr,{ref:ra,onMouseDown:Ur,onKeyDown:Yl,onKeyUp:ya,onFocus:Bs,onBlur:tl}),ke.createElement(vl,{visible:Ba&&!na,values:Et}),ed,Ol,jc&&Lc),ke.createElement(wr.Provider,{value:Xl},dh)}),zl=Ll,fu=function(){return null};fu.isSelectOptGroup=!0;var As=fu,gu=function(){return null};gu.isSelectOption=!0;var xh=gu;function Xu(Te,Oe){var Xe=Tt({},Te);return Array.isArray(Oe)&&Oe.forEach(function(ot){delete Xe[ot]}),Xe}var es=De(73299);function Ds(){return/(mac\sos|macintosh)/i.test(navigator.appVersion)}var Mo=["disabled","title","children","style","className"];function Ro(Te){return typeof Te=="string"||typeof Te=="number"}var Ma=function(Oe,Xe){var ot=fr(),Rt=ot.prefixCls,Se=ot.id,Le=ot.open,je=ot.multiple,Ke=ot.mode,ct=ot.searchValue,Et=ot.toggleOpen,Bt=ot.notFoundContent,hn=ot.onPopupScroll,qt=ke.useContext(el),nn=qt.maxCount,Sn=qt.flattenOptions,yn=qt.onActiveValue,Jn=qt.defaultActiveFirstOption,In=qt.onSelect,Mn=qt.menuItemSelectedIcon,Kn=qt.rawValues,ni=qt.fieldNames,yi=qt.virtual,$i=qt.direction,Ai=qt.listHeight,bi=qt.listItemHeight,dr=qt.optionRender,Wn="".concat(Rt,"-item"),Ji=$n(function(){return Sn},[Le,Sn],function(Ar,ur){return ur[0]&&Ar[1]!==ur[1]}),Pi=ke.useRef(null),tr=ke.useMemo(function(){return je&&jr(nn)&&(Kn==null?void 0:Kn.size)>=nn},[je,nn,Kn==null?void 0:Kn.size]),ar=function(ur){ur.preventDefault()},ki=function(ur){var Vr;(Vr=Pi.current)===null||Vr===void 0||Vr.scrollTo(typeof ur=="number"?{index:ur}:ur)},Fr=ke.useCallback(function(Ar){return Ke==="combobox"?!1:Kn.has(Ar)},[Ke,st(Kn).toString(),Kn.size]),hr=function(ur){for(var Vr=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1,Do=Ji.length,Nr=0;Nr<Do;Nr+=1){var Wi=(ur+Nr*Vr+Do)%Do,ir=Ji[Wi]||{},rr=ir.group,Fi=ir.data;if(!rr&&!(Fi!=null&&Fi.disabled)&&(Fr(Fi.value)||!tr))return Wi}return-1},Mr=ke.useState(function(){return hr(0)}),Ti=Dn(Mr,2),pr=Ti[0],qr=Ti[1],Po=function(ur){var Vr=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;qr(ur);var Do={source:Vr?"keyboard":"mouse"},Nr=Ji[ur];if(!Nr){yn(null,-1,Do);return}yn(Nr.value,ur,Do)};(0,ke.useEffect)(function(){Po(Jn!==!1?hr(0):-1)},[Ji.length,ct]);var no=ke.useCallback(function(Ar){return Ke==="combobox"?String(Ar).toLowerCase()===ct.toLowerCase():Kn.has(Ar)},[Ke,ct,st(Kn).toString(),Kn.size]);(0,ke.useEffect)(function(){var Ar=setTimeout(function(){if(!je&&Le&&Kn.size===1){var Vr=Array.from(Kn)[0],Do=Ji.findIndex(function(Nr){var Wi=Nr.data;return Wi.value===Vr});Do!==-1&&(Po(Do),ki(Do))}});if(Le){var ur;(ur=Pi.current)===null||ur===void 0||ur.scrollTo(void 0)}return function(){return clearTimeout(Ar)}},[Le,ct]);var Qi=function(ur){ur!==void 0&&In(ur,{selected:!Kn.has(ur)}),je||Et(!1)};if(ke.useImperativeHandle(Xe,function(){return{onKeyDown:function(ur){var Vr=ur.which,Do=ur.ctrlKey;switch(Vr){case ei.N:case ei.P:case ei.UP:case ei.DOWN:{var Nr=0;if(Vr===ei.UP?Nr=-1:Vr===ei.DOWN?Nr=1:Ds()&&Do&&(Vr===ei.N?Nr=1:Vr===ei.P&&(Nr=-1)),Nr!==0){var Wi=hr(pr+Nr,Nr);ki(Wi),Po(Wi,!0)}break}case ei.TAB:case ei.ENTER:{var ir,rr=Ji[pr];rr&&!(rr!=null&&(ir=rr.data)!==null&&ir!==void 0&&ir.disabled)&&!tr?Qi(rr.value):Qi(void 0),Le&&ur.preventDefault();break}case ei.ESC:Et(!1),Le&&ur.stopPropagation()}},onKeyUp:function(){},scrollTo:function(ur){ki(ur)}}}),Ji.length===0)return ke.createElement("div",{role:"listbox",id:"".concat(Se,"_list"),className:"".concat(Wn,"-empty"),onMouseDown:ar},Bt);var zr=Object.keys(ni).map(function(Ar){return ni[Ar]}),$r=function(ur){return ur.label};function lo(Ar,ur){var Vr=Ar.group;return{role:Vr?"presentation":"option",id:"".concat(Se,"_list_").concat(ur)}}var Uo=function(ur){var Vr=Ji[ur];if(!Vr)return null;var Do=Vr.data||{},Nr=Do.value,Wi=Vr.group,ir=ca(Do,!0),rr=$r(Vr);return Vr?ke.createElement("div",me({"aria-label":typeof rr=="string"&&!Wi?rr:null},ir,{key:ur},lo(Vr,ur),{"aria-selected":no(Nr)}),Nr):null},So={role:"listbox",id:"".concat(Se,"_list")};return ke.createElement(ke.Fragment,null,yi&&ke.createElement("div",me({},So,{style:{height:0,width:0,overflow:"hidden"}}),Uo(pr-1),Uo(pr),Uo(pr+1)),ke.createElement(es.Z,{itemKey:"key",ref:Pi,data:Ji,height:Ai,itemHeight:bi,fullHeight:!1,onMouseDown:ar,onScroll:hn,virtual:yi,direction:$i,innerProps:yi?null:So},function(Ar,ur){var Vr=Ar.group,Do=Ar.groupOption,Nr=Ar.data,Wi=Ar.label,ir=Ar.value,rr=Nr.key;if(Vr){var Fi,zi=(Fi=Nr.title)!==null&&Fi!==void 0?Fi:Ro(Wi)?Wi.toString():void 0;return ke.createElement("div",{className:qe()(Wn,"".concat(Wn,"-group"),Nr.className),title:zi},Wi!==void 0?Wi:rr)}var Sr=Nr.disabled,io=Nr.title,Xr=Nr.children,Ir=Nr.style,wa=Nr.className,ra=ze(Nr,Mo),Xo=Xu(ra,zr),pa=Fr(ir),ro=Sr||!pa&&tr,Jo="".concat(Wn,"-option"),va=qe()(Wn,Jo,wa,Ft(Ft(Ft(Ft({},"".concat(Jo,"-grouped"),Do),"".concat(Jo,"-active"),pr===ur&&!ro),"".concat(Jo,"-disabled"),ro),"".concat(Jo,"-selected"),pa)),ds=$r(Ar),Pa=!Mn||typeof Mn=="function"||pa,Ba=typeof ds=="number"?ds:ds||ir,Bo=Ro(Ba)?Ba.toString():void 0;return io!==void 0&&(Bo=io),ke.createElement("div",me({},ca(Xo),yi?{}:lo(Ar,ur),{"aria-selected":no(ir),className:va,title:Bo,onMouseMove:function(){pr===ur||ro||Po(ur)},onClick:function(){ro||Qi(ir)},style:Ir}),ke.createElement("div",{className:"".concat(Jo,"-content")},typeof dr=="function"?dr(Ar,{index:ur}):Ba),ke.isValidElement(Mn)||pa,Pa&&ke.createElement(Ri,{className:"".concat(Wn,"-option-state"),customizeIcon:Mn,customizeIconProps:{value:ir,disabled:ro,isSelected:pa}},pa?"\u2713":null))}))},Ls=ke.forwardRef(Ma),vr=Ls,$h=function(Te,Oe){var Xe=ke.useRef({values:new Map,options:new Map}),ot=ke.useMemo(function(){var Se=Xe.current,Le=Se.values,je=Se.options,Ke=Te.map(function(Bt){if(Bt.label===void 0){var hn;return Tt(Tt({},Bt),{},{label:(hn=Le.get(Bt.value))===null||hn===void 0?void 0:hn.label})}return Bt}),ct=new Map,Et=new Map;return Ke.forEach(function(Bt){ct.set(Bt.value,Bt),Et.set(Bt.value,Oe.get(Bt.value)||je.get(Bt.value))}),Xe.current.values=ct,Xe.current.options=Et,Ke},[Te,Oe]),Rt=ke.useCallback(function(Se){return Oe.get(Se)||Xe.current.options.get(Se)},[Oe]);return[ot,Rt]};function Nl(Te,Oe){return jo(Te).join("").toUpperCase().includes(Oe)}var Tl=function(Te,Oe,Xe,ot,Rt){return ke.useMemo(function(){if(!Xe||ot===!1)return Te;var Se=Oe.options,Le=Oe.label,je=Oe.value,Ke=[],ct=typeof ot=="function",Et=Xe.toUpperCase(),Bt=ct?ot:function(qt,nn){return Rt?Nl(nn[Rt],Et):nn[Se]?Nl(nn[Le!=="children"?Le:"label"],Et):Nl(nn[je],Et)},hn=ct?function(qt){return Ia(qt)}:function(qt){return qt};return Te.forEach(function(qt){if(qt[Se]){var nn=Bt(Xe,hn(qt));if(nn)Ke.push(qt);else{var Sn=qt[Se].filter(function(yn){return Bt(Xe,hn(yn))});Sn.length&&Ke.push(Tt(Tt({},qt),{},Ft({},Se,Sn)))}return}Bt(Xe,hn(qt))&&Ke.push(qt)}),Ke},[Te,ot,Rt,Xe,Oe])},wh=0,Ju=On();function Bi(){var Te;return Ju?(Te=wh,wh+=1):Te="TEST_OR_SSR",Te}function Ms(Te){var Oe=ke.useState(),Xe=Dn(Oe,2),ot=Xe[0],Rt=Xe[1];return ke.useEffect(function(){Rt("rc_select_".concat(Bi()))},[]),Te||ot}function Cs(Te){var Oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Xe=[];return ke.Children.forEach(Te,function(ot){ot==null&&!Oe.keepEmpty||(Array.isArray(ot)?Xe=Xe.concat(Cs(ot)):(0,ui.isFragment)(ot)&&ot.props?Xe=Xe.concat(Cs(ot.props.children,Oe)):Xe.push(ot))}),Xe}var _l=["children","value"],lh=["children"];function Ph(Te){var Oe=Te,Xe=Oe.key,ot=Oe.props,Rt=ot.children,Se=ot.value,Le=ze(ot,_l);return Tt({key:Xe,value:Se!==void 0?Se:Xe,children:Rt},Le)}function ko(Te){var Oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return Cs(Te).map(function(Xe,ot){if(!ke.isValidElement(Xe)||!Xe.type)return null;var Rt=Xe,Se=Rt.type.isSelectOptGroup,Le=Rt.key,je=Rt.props,Ke=je.children,ct=ze(je,lh);return Oe||!Se?Ph(Xe):Tt(Tt({key:"__RC_SELECT_GRP__".concat(Le===null?ot:Le,"__"),label:Le},ct),{},{options:ko(Ke)})}).filter(function(Xe){return Xe})}var Ch=function(Oe,Xe,ot,Rt,Se){return ke.useMemo(function(){var Le=Oe,je=!Oe;je&&(Le=ko(Xe));var Ke=new Map,ct=new Map,Et=function(qt,nn,Sn){Sn&&typeof Sn=="string"&&qt.set(nn[Sn],nn)},Bt=function hn(qt){for(var nn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Sn=0;Sn<qt.length;Sn+=1){var yn=qt[Sn];!yn[ot.options]||nn?(Ke.set(yn[ot.value],yn),Et(ct,yn,ot.label),Et(ct,yn,Rt),Et(ct,yn,Se)):hn(yn[ot.options],!0)}};return Bt(Le),{options:Le,valueOptions:Ke,labelOptions:ct}},[Oe,Xe,ot,Rt,Se])},iu=Ch;function yl(Te){var Oe=ke.useRef();Oe.current=Te;var Xe=ke.useCallback(function(){return Oe.current.apply(Oe,arguments)},[]);return Xe}function Hl(Te){var Oe=Te.mode,Xe=Te.options,ot=Te.children,Rt=Te.backfill,Se=Te.allowClear,Le=Te.placeholder,je=Te.getInputElement,Ke=Te.showSearch,ct=Te.onSearch,Et=Te.defaultOpen,Bt=Te.autoFocus,hn=Te.labelInValue,qt=Te.value,nn=Te.inputValue,Sn=Te.optionLabelProp,yn=isMultiple(Oe),Jn=Ke!==void 0?Ke:yn||Oe==="combobox",In=Xe||convertChildrenToData(ot);if(warning(Oe!=="tags"||In.every(function(yi){return!yi.disabled}),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),Oe==="tags"||Oe==="combobox"){var Mn=In.some(function(yi){return yi.options?yi.options.some(function($i){return typeof("value"in $i?$i.value:$i.key)=="number"}):typeof("value"in yi?yi.value:yi.key)=="number"});warning(!Mn,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(warning(Oe!=="combobox"||!Sn,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),warning(Oe==="combobox"||!Rt,"`backfill` only works with `combobox` mode."),warning(Oe==="combobox"||!je,"`getInputElement` only work with `combobox` mode."),noteOnce(Oe!=="combobox"||!je||!Se||!Le,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),ct&&!Jn&&Oe!=="combobox"&&Oe!=="tags"&&warning(!1,"`onSearch` should work with `showSearch` instead of use alone."),noteOnce(!Et||Bt,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),qt!=null){var Kn=toArray(qt);warning(!hn||Kn.every(function(yi){return _typeof(yi)==="object"&&("key"in yi||"value"in yi)}),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),warning(!yn||Array.isArray(qt),"`value` should be array when `mode` is `multiple` or `tags`")}if(ot){var ni=null;toNodeArray(ot).some(function(yi){if(!React.isValidElement(yi)||!yi.type)return!1;var $i=yi,Ai=$i.type;if(Ai.isSelectOption)return!1;if(Ai.isSelectOptGroup){var bi=toNodeArray(yi.props.children).every(function(dr){return!React.isValidElement(dr)||!yi.type||dr.type.isSelectOption?!0:(ni=dr.type,!1)});return!bi}return ni=Ai,!0}),ni&&warning(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(ni.displayName||ni.name||ni,"`.")),warning(nn===void 0,"`inputValue` is deprecated, please use `searchValue` instead.")}}function Eh(Te,Oe){if(Te){var Xe=function ot(Rt){for(var Se=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Le=0;Le<Rt.length;Le++){var je=Rt[Le];if(je[Oe==null?void 0:Oe.value]===null)return warning(!1,"`value` in Select options should not be `null`."),!0;if(!Se&&Array.isArray(je[Oe==null?void 0:Oe.options])&&ot(je[Oe==null?void 0:Oe.options],!0))break}};Xe(Te)}}var ec=null,Dl=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","labelRender","value","defaultValue","labelInValue","onChange","maxCount"],ru=["inputValue"];function uh(Te){return!Te||it(Te)!=="object"}var Ec=ke.forwardRef(function(Te,Oe){var Xe=Te.id,ot=Te.mode,Rt=Te.prefixCls,Se=Rt===void 0?"rc-select":Rt,Le=Te.backfill,je=Te.fieldNames,Ke=Te.inputValue,ct=Te.searchValue,Et=Te.onSearch,Bt=Te.autoClearSearchValue,hn=Bt===void 0?!0:Bt,qt=Te.onSelect,nn=Te.onDeselect,Sn=Te.dropdownMatchSelectWidth,yn=Sn===void 0?!0:Sn,Jn=Te.filterOption,In=Te.filterSort,Mn=Te.optionFilterProp,Kn=Te.optionLabelProp,ni=Te.options,yi=Te.optionRender,$i=Te.children,Ai=Te.defaultActiveFirstOption,bi=Te.menuItemSelectedIcon,dr=Te.virtual,Wn=Te.direction,Ji=Te.listHeight,Pi=Ji===void 0?200:Ji,tr=Te.listItemHeight,ar=tr===void 0?20:tr,ki=Te.labelRender,Fr=Te.value,hr=Te.defaultValue,Mr=Te.labelInValue,Ti=Te.onChange,pr=Te.maxCount,qr=ze(Te,Dl),Po=Ms(Xe),no=Xt(ot),Qi=!!(!ni&&$i),zr=ke.useMemo(function(){return Jn===void 0&&ot==="combobox"?!1:Jn},[Jn,ot]),$r=ke.useMemo(function(){return Ao(je,Qi)},[JSON.stringify(je),Qi]),lo=ft("",{value:ct!==void 0?ct:Ke,postState:function(Tr){return Tr||""}}),Uo=Dn(lo,2),So=Uo[0],Ar=Uo[1],ur=iu(ni,$i,$r,Mn,Kn),Vr=ur.valueOptions,Do=ur.labelOptions,Nr=ur.options,Wi=ke.useCallback(function(Hi){var Tr=jo(Hi);return Tr.map(function(nr){var ho,Ca,Rr,Qo,Eo;if(uh(nr))ho=nr;else{var Go;Rr=nr.key,Ca=nr.label,ho=(Go=nr.value)!==null&&Go!==void 0?Go:Rr}var fa=Vr.get(ho);if(fa){var Aa;if(Ca===void 0&&(Ca=fa==null?void 0:fa[Kn||$r.label]),Rr===void 0&&(Rr=(Aa=fa==null?void 0:fa.key)!==null&&Aa!==void 0?Aa:ho),Qo=fa==null?void 0:fa.disabled,Eo=fa==null?void 0:fa.title,0)var ll}return{label:Ca,value:ho,key:Rr,disabled:Qo,title:Eo}})},[$r,Kn,Vr]),ir=ft(hr,{value:Fr}),rr=Dn(ir,2),Fi=rr[0],zi=rr[1],Sr=ke.useMemo(function(){var Hi,Tr=no&&Fi===null?[]:Fi,nr=Wi(Tr);return ot==="combobox"&&Xa((Hi=nr[0])===null||Hi===void 0?void 0:Hi.value)?[]:nr},[Fi,Wi,ot,no]),io=$h(Sr,Vr),Xr=Dn(io,2),Ir=Xr[0],wa=Xr[1],ra=ke.useMemo(function(){if(!ot&&Ir.length===1){var Hi=Ir[0];if(Hi.value===null&&(Hi.label===null||Hi.label===void 0))return[]}return Ir.map(function(Tr){var nr;return Tt(Tt({},Tr),{},{label:(nr=typeof ki=="function"?ki(Tr):Tr.label)!==null&&nr!==void 0?nr:Tr.value})})},[ot,Ir,ki]),Xo=ke.useMemo(function(){return new Set(Ir.map(function(Hi){return Hi.value}))},[Ir]);ke.useEffect(function(){if(ot==="combobox"){var Hi,Tr=(Hi=Ir[0])===null||Hi===void 0?void 0:Hi.value;Ar(bl(Tr)?String(Tr):"")}},[Ir]);var pa=yl(function(Hi,Tr){var nr=Tr!=null?Tr:Hi;return Ft(Ft({},$r.value,Hi),$r.label,nr)}),ro=ke.useMemo(function(){if(ot!=="tags")return Nr;var Hi=st(Nr),Tr=function(ho){return Vr.has(ho)};return st(Ir).sort(function(nr,ho){return nr.value<ho.value?-1:1}).forEach(function(nr){var ho=nr.value;Tr(ho)||Hi.push(pa(ho,nr.label))}),Hi},[pa,Nr,Vr,Ir,ot]),Jo=Tl(ro,$r,So,zr,Mn),va=ke.useMemo(function(){return ot!=="tags"||!So||Jo.some(function(Hi){return Hi[Mn||"value"]===So})||Jo.some(function(Hi){return Hi[$r.value]===So})?Jo:[pa(So)].concat(st(Jo))},[pa,Mn,ot,Jo,So,$r]),ds=function Hi(Tr){var nr=st(Tr).sort(function(ho,Ca){return In(ho,Ca,{searchValue:So})});return nr.map(function(ho){return Array.isArray(ho.options)?Tt(Tt({},ho),{},{options:ho.options.length>0?Hi(ho.options):ho.options}):ho})},Pa=ke.useMemo(function(){return In?ds(va):va},[va,In,So]),Ba=ke.useMemo(function(){return $a(Pa,{fieldNames:$r,childrenAsData:Qi})},[Pa,$r,Qi]),Bo=function(Tr){var nr=Wi(Tr);if(zi(nr),Ti&&(nr.length!==Ir.length||nr.some(function(Rr,Qo){var Eo;return((Eo=Ir[Qo])===null||Eo===void 0?void 0:Eo.value)!==(Rr==null?void 0:Rr.value)}))){var ho=Mr?nr:nr.map(function(Rr){return Rr.value}),Ca=nr.map(function(Rr){return Ia(wa(Rr.value))});Ti(no?ho:ho[0],no?Ca:Ca[0])}},Za=ke.useState(null),Fa=Dn(Za,2),ns=Fa[0],Vi=Fa[1],Ki=ke.useState(0),or=Dn(Ki,2),Jr=or[0],ta=or[1],Ha=Ai!==void 0?Ai:ot!=="combobox",ls=ke.useCallback(function(Hi,Tr){var nr=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},ho=nr.source,Ca=ho===void 0?"keyboard":ho;ta(Tr),Le&&ot==="combobox"&&Hi!==null&&Ca==="keyboard"&&Vi(String(Hi))},[Le,ot]),bt=function(Tr,nr,ho){var Ca=function(){var Yo,Sa=wa(Tr);return[Mr?{label:Sa==null?void 0:Sa[$r.label],value:Tr,key:(Yo=Sa==null?void 0:Sa.key)!==null&&Yo!==void 0?Yo:Tr}:Tr,Ia(Sa)]};if(nr&&qt){var Rr=Ca(),Qo=Dn(Rr,2),Eo=Qo[0],Go=Qo[1];qt(Eo,Go)}else if(!nr&&nn&&ho!=="clear"){var fa=Ca(),Aa=Dn(fa,2),ll=Aa[0],Yl=Aa[1];nn(ll,Yl)}},xo=yl(function(Hi,Tr){var nr,ho=no?Tr.selected:!0;ho?nr=no?[].concat(st(Ir),[Hi]):[Hi]:nr=Ir.filter(function(Ca){return Ca.value!==Hi}),Bo(nr),bt(Hi,ho),ot==="combobox"?Vi(""):(!Xt||hn)&&(Ar(""),Vi(""))}),zo=function(Tr,nr){Bo(Tr);var ho=nr.type,Ca=nr.values;(ho==="remove"||ho==="clear")&&Ca.forEach(function(Rr){bt(Rr.value,!1,ho)})},na=function(Tr,nr){if(Ar(Tr),Vi(null),nr.source==="submit"){var ho=(Tr||"").trim();if(ho){var Ca=Array.from(new Set([].concat(st(Xo),[ho])));Bo(Ca),bt(ho,!0),Ar("")}return}nr.source!=="blur"&&(ot==="combobox"&&Bo(Tr),Et==null||Et(Tr))},js=function(Tr){var nr=Tr;ot!=="tags"&&(nr=Tr.map(function(Ca){var Rr=Do.get(Ca);return Rr==null?void 0:Rr.value}).filter(function(Ca){return Ca!==void 0}));var ho=Array.from(new Set([].concat(st(Xo),st(nr))));Bo(ho),ho.forEach(function(Ca){bt(Ca,!0)})},us=ke.useMemo(function(){var Hi=dr!==!1&&yn!==!1;return Tt(Tt({},ur),{},{flattenOptions:Ba,onActiveValue:ls,defaultActiveFirstOption:Ha,onSelect:xo,menuItemSelectedIcon:bi,rawValues:Xo,fieldNames:$r,virtual:Hi,direction:Wn,listHeight:Pi,listItemHeight:ar,childrenAsData:Qi,maxCount:pr,optionRender:yi})},[pr,ur,Ba,ls,Ha,xo,bi,Xo,$r,dr,yn,Wn,Pi,ar,Qi,yi]);return ke.createElement(el.Provider,{value:us},ke.createElement(zl,me({},qr,{id:Po,prefixCls:Se,ref:Oe,omitDomProps:ru,mode:ot,displayValues:ra,onDisplayValuesChange:zo,direction:Wn,searchValue:So,onSearch:na,autoClearSearchValue:hn,onSearchSplit:js,dropdownMatchSelectWidth:yn,OptionList:vr,emptyOptions:!Ba.length,activeValue:ns,activeDescendantId:"".concat(Po,"_list_").concat(Jr)})))}),zh=Ec;zh.Option=xh,zh.OptGroup=As;var Rc=null,dc=null,Gl=De(17341);function Qu(Te){if(Array.isArray(Te))return Te}function pu(Te,Oe){var Xe=Te==null?null:typeof Symbol!="undefined"&&Te[Symbol.iterator]||Te["@@iterator"];if(Xe!=null){var ot,Rt,Se,Le,je=[],Ke=!0,ct=!1;try{if(Se=(Xe=Xe.call(Te)).next,Oe===0){if(Object(Xe)!==Xe)return;Ke=!1}else for(;!(Ke=(ot=Se.call(Xe)).done)&&(je.push(ot.value),je.length!==Oe);Ke=!0);}catch(Et){ct=!0,Rt=Et}finally{try{if(!Ke&&Xe.return!=null&&(Le=Xe.return(),Object(Le)!==Le))return}finally{if(ct)throw Rt}}return je}}function bh(Te,Oe){(Oe==null||Oe>Te.length)&&(Oe=Te.length);for(var Xe=0,ot=new Array(Oe);Xe<Oe;Xe++)ot[Xe]=Te[Xe];return ot}function tc(Te,Oe){if(Te){if(typeof Te=="string")return bh(Te,Oe);var Xe=Object.prototype.toString.call(Te).slice(8,-1);if(Xe==="Object"&&Te.constructor&&(Xe=Te.constructor.name),Xe==="Map"||Xe==="Set")return Array.from(Te);if(Xe==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(Xe))return bh(Te,Oe)}}function Hh(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vs(Te,Oe){return Qu(Te)||pu(Te,Oe)||tc(Te,Oe)||Hh()}function tn(Te){var Oe=ke.useRef();Oe.current=Te;var Xe=ke.useCallback(function(){for(var ot,Rt=arguments.length,Se=new Array(Rt),Le=0;Le<Rt;Le++)Se[Le]=arguments[Le];return(ot=Oe.current)===null||ot===void 0?void 0:ot.call.apply(ot,[Oe].concat(Se))},[]);return Xe}function nc(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var Gh=nc()?ke.useLayoutEffect:ke.useEffect,qu=function(Oe,Xe){var ot=ke.useRef(!0);Gh(function(){return Oe(ot.current)},Xe),Gh(function(){return ot.current=!1,function(){ot.current=!0}},[])},Ml=function(Oe,Xe){qu(function(ot){if(!ot)return Oe()},Xe)},ol=null;function Rs(Te){var Oe=ke.useRef(!1),Xe=ke.useState(Te),ot=vs(Xe,2),Rt=ot[0],Se=ot[1];ke.useEffect(function(){return Oe.current=!1,function(){Oe.current=!0}},[]);function Le(je,Ke){Ke&&Oe.current||Se(je)}return[Rt,Le]}function Us(Te){return Te!==void 0}function hh(Te,Oe){var Xe=Oe||{},ot=Xe.defaultValue,Rt=Xe.value,Se=Xe.onChange,Le=Xe.postState,je=Rs(function(){return Us(Rt)?Rt:Us(ot)?typeof ot=="function"?ot():ot:typeof Te=="function"?Te():Te}),Ke=vs(je,2),ct=Ke[0],Et=Ke[1],Bt=Rt!==void 0?Rt:ct,hn=Le?Le(Bt):Bt,qt=tn(Se),nn=Rs([Bt]),Sn=vs(nn,2),yn=Sn[0],Jn=Sn[1];Ml(function(){var Mn=yn[0];ct!==Mn&&qt(ct,Mn)},[yn]),Ml(function(){Us(Rt)||Et(Rt)},[Rt]);var In=tn(function(Mn,Kn){Et(Mn,Kn),Jn([Bt],Kn)});return[hn,In]}var al={},Ss=[],os=function(Oe){Ss.push(Oe)};function Lh(Te,Oe){if(0)var Xe}function Au(Te,Oe){if(0)var Xe}function kr(){al={}}function Kh(Te,Oe,Xe){!Oe&&!al[Xe]&&(Te(!1,Xe),al[Xe]=!0)}function yt(Te,Oe){Kh(Lh,Te,Oe)}function Bn(Te,Oe){Kh(Au,Te,Oe)}yt.preMessage=os,yt.resetWarned=kr,yt.noteOnce=Bn;var Kl=yt,ch=function(Te){var Oe=ke.useRef({valueLabels:new Map});return ke.useMemo(function(){var Xe=Oe.current.valueLabels,ot=new Map,Rt=Te.map(function(Se){var Le=Se.value,je=Se.label,Ke=je!=null?je:Xe.get(Le);return ot.set(Le,Ke),sn(sn({},Se),{},{label:Ke})});return Oe.current.valueLabels=ot,[Rt]},[Te])},$u=function(Oe,Xe,ot,Rt){return ke.useMemo(function(){var Se=function(qt){return qt.map(function(nn){var Sn=nn.value;return Sn})},Le=Se(Oe),je=Se(Xe),Ke=Le.filter(function(hn){return!Rt[hn]}),ct=Le,Et=je;if(ot){var Bt=(0,Gl.S)(Le,!0,Rt);ct=Bt.checkedKeys,Et=Bt.halfCheckedKeys}return[Array.from(new Set([].concat($e(Ke),$e(ct)))),Et]},[Oe,Xe,ot,Rt])},Nu=$u,Tu=De(1089),Wh=function(Te,Oe){return ke.useMemo(function(){var Xe=(0,Tu.I8)(Te,{fieldNames:Oe,initWrapper:function(Rt){return sn(sn({},Rt),{},{valueEntities:new Map})},processEntity:function(Rt,Se){var Le=Rt.node[Oe.value];if(0)var je;Se.valueEntities.set(Le,Rt)}});return Xe},[Te,Oe])};function Du(Te){"@babel/helpers - typeof";return Du=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Oe){return typeof Oe}:function(Oe){return Oe&&typeof Symbol=="function"&&Oe.constructor===Symbol&&Oe!==Symbol.prototype?"symbol":typeof Oe},Du(Te)}var Ns=Symbol.for("react.element"),to=Symbol.for("react.transitional.element"),Bl=Symbol.for("react.fragment");function Pl(Te){return Te&&Du(Te)==="object"&&(Te.$$typeof===Ns||Te.$$typeof===to)&&Te.type===Bl}function xs(Te){var Oe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Xe=[];return ke.Children.forEach(Te,function(ot){ot==null&&!Oe.keepEmpty||(Array.isArray(ot)?Xe=Xe.concat(xs(ot)):Pl(ot)&&ot.props?Xe=Xe.concat(xs(ot.props.children,Oe)):Xe.push(ot))}),Xe}var fi=function(){return null},po=fi,Vo=["children","value"];function qo(Te){return xs(Te).map(function(Oe){if(!ke.isValidElement(Oe)||!Oe.type)return null;var Xe=Oe,ot=Xe.key,Rt=Xe.props,Se=Rt.children,Le=Rt.value,je=pe(Rt,Vo),Ke=sn({key:ot,value:Le},je),ct=qo(Se);return ct.length&&(Ke.children=ct),Ke}).filter(function(Oe){return Oe})}function Ja(Te){if(!Te)return Te;var Oe=sn({},Te);return"props"in Oe||Object.defineProperty(Oe,"props",{get:function(){return Kl(!1,"New `rc-tree-select` not support return node instance as argument anymore. Please consider to remove `props` access."),Oe}}),Oe}function Zs(Te,Oe,Xe,ot,Rt,Se){var Le=null,je=null;function Ke(){function ct(Et){var Bt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"0",hn=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;return Et.map(function(qt,nn){var Sn="".concat(Bt,"-").concat(nn),yn=qt[Se.value],Jn=Xe.includes(yn),In=ct(qt[Se.children]||[],Sn,Jn),Mn=ke.createElement(po,qt,In.map(function(ni){return ni.node}));if(Oe===yn&&(Le=Mn),Jn){var Kn={pos:Sn,node:Mn,children:In};return hn||je.push(Kn),Kn}return null}).filter(function(qt){return qt})}je||(je=[],ct(ot),je.sort(function(Et,Bt){var hn=Et.node.props.value,qt=Bt.node.props.value,nn=Xe.indexOf(hn),Sn=Xe.indexOf(qt);return nn-Sn}))}Object.defineProperty(Te,"triggerNode",{get:function(){return Kl(!1,"`triggerNode` is deprecated. Please consider decoupling data with node."),Ke(),Le}}),Object.defineProperty(Te,"allCheckedNodes",{get:function(){return Kl(!1,"`allCheckedNodes` is deprecated. Please consider decoupling data with node."),Ke(),Rt?je:je.map(function(Et){var Bt=Et.node;return Bt})}})}var mu=function(Oe,Xe,ot){var Rt=ot.fieldNames,Se=ot.treeNodeFilterProp,Le=ot.filterTreeNode,je=Rt.children;return ke.useMemo(function(){if(!Xe||Le===!1)return Oe;var Ke=typeof Le=="function"?Le:function(Et,Bt){return String(Bt[Se]).toUpperCase().includes(Xe.toUpperCase())},ct=function Et(Bt){var hn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return Bt.reduce(function(qt,nn){var Sn=nn[je],yn=hn||Ke(Xe,Ja(nn)),Jn=Et(Sn||[],yn);return(yn||Jn.length)&&qt.push(sn(sn({},nn),{},Qt({isLeaf:void 0},je,Jn))),qt},[])};return ct(Oe)},[Oe,Xe,je,Se,Le])},ka=mu;function sl(Te){var Oe=ke.useRef();Oe.current=Te;var Xe=ke.useCallback(function(){return Oe.current.apply(Oe,arguments)},[]);return Xe}function ga(Te,Oe){var Xe=Oe.id,ot=Oe.pId,Rt=Oe.rootPId,Se=new Map,Le=[];return Te.forEach(function(je){var Ke=je[Xe],ct=sn(sn({},je),{},{key:je.key||Ke});Se.set(Ke,ct)}),Se.forEach(function(je){var Ke=je[ot],ct=Se.get(Ke);ct?(ct.children=ct.children||[],ct.children.push(je)):(Ke===Rt||Rt===null)&&Le.push(je)}),Le}function ts(Te,Oe,Xe){return ke.useMemo(function(){if(Te){if(Xe){var ot=sn({id:"id",pId:"pId",rootPId:null},Mt(Xe)==="object"?Xe:{});return ga(Te,ot)}return Te}return qo(Oe)},[Oe,Xe,Te])}var ss=ke.createContext(null),ws=ss;function Ta(Te,Oe){var Xe=typeof Symbol!="undefined"&&Te[Symbol.iterator]||Te["@@iterator"];if(!Xe){if(Array.isArray(Te)||(Xe=kt(Te))||Oe&&Te&&typeof Te.length=="number"){Xe&&(Te=Xe);var ot=0,Rt=function(){};return{s:Rt,n:function(){return ot>=Te.length?{done:!0}:{done:!1,value:Te[ot++]}},e:function(ct){throw ct},f:Rt}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var Se,Le=!0,je=!1;return{s:function(){Xe=Xe.call(Te)},n:function(){var ct=Xe.next();return Le=ct.done,ct},e:function(ct){je=!0,Se=ct},f:function(){try{Le||Xe.return==null||Xe.return()}finally{if(je)throw Se}}}}var vu=De(70593),Ni={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(Oe){var Xe=Oe.keyCode;if(Oe.altKey&&!Oe.ctrlKey||Oe.metaKey||Xe>=Ni.F1&&Xe<=Ni.F12)return!1;switch(Xe){case Ni.ALT:case Ni.CAPS_LOCK:case Ni.CONTEXT_MENU:case Ni.CTRL:case Ni.DOWN:case Ni.END:case Ni.ESC:case Ni.HOME:case Ni.INSERT:case Ni.LEFT:case Ni.MAC_FF_META:case Ni.META:case Ni.NUMLOCK:case Ni.NUM_CENTER:case Ni.PAGE_DOWN:case Ni.PAGE_UP:case Ni.PAUSE:case Ni.PRINT_SCREEN:case Ni.RIGHT:case Ni.SHIFT:case Ni.UP:case Ni.WIN_KEY:case Ni.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(Oe){if(Oe>=Ni.ZERO&&Oe<=Ni.NINE||Oe>=Ni.NUM_ZERO&&Oe<=Ni.NUM_MULTIPLY||Oe>=Ni.A&&Oe<=Ni.Z||window.navigator.userAgent.indexOf("WebKit")!==-1&&Oe===0)return!0;switch(Oe){case Ni.SPACE:case Ni.QUESTION_MARK:case Ni.NUM_PLUS:case Ni.NUM_MINUS:case Ni.NUM_PERIOD:case Ni.NUM_DIVISION:case Ni.SEMICOLON:case Ni.DASH:case Ni.EQUALS:case Ni.COMMA:case Ni.PERIOD:case Ni.SLASH:case Ni.APOSTROPHE:case Ni.SINGLE_QUOTE:case Ni.OPEN_SQUARE_BRACKET:case Ni.BACKSLASH:case Ni.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}},ou=Ni;function sa(Te,Oe,Xe){var ot=ke.useRef({});return(!("value"in ot.current)||Xe(ot.current.condition,Oe))&&(ot.current.value=Te(),ot.current.condition=Oe),ot.current.value}var mo=ke.createContext(null),Mh=mo,bc=function(Oe){return Array.isArray(Oe)?Oe:Oe!==void 0?[Oe]:[]},Ic=function(Oe){var Xe=Oe||{},ot=Xe.label,Rt=Xe.value,Se=Xe.children;return{_title:ot?[ot]:["title","label"],value:Rt||"value",key:Rt||"value",children:Se||"children"}},fc=function(Oe){return!Oe||Oe.disabled||Oe.disableCheckbox||Oe.checkable===!1},kh=function(Oe,Xe){var ot=[],Rt=function Se(Le){Le.forEach(function(je){var Ke=je[Xe.children];Ke&&(ot.push(je[Xe.value]),Se(Ke))})};return Rt(Oe),ot},Fh=function(Oe){return Oe==null},Br=De(66133),Wl=Number(ke.version.split(".")[0]),Ue=function(Oe,Xe){typeof Oe=="function"?Oe(Xe):_typeof(Oe)==="object"&&Oe&&"current"in Oe&&(Oe.current=Xe)},ht=function(){for(var Oe=arguments.length,Xe=new Array(Oe),ot=0;ot<Oe;ot++)Xe[ot]=arguments[ot];var Rt=Xe.filter(Boolean);return Rt.length<=1?Rt[0]:function(Se){Xe.forEach(function(Le){Ue(Le,Se)})}},pt=function(){for(var Oe=arguments.length,Xe=new Array(Oe),ot=0;ot<Oe;ot++)Xe[ot]=arguments[ot];return useMemo(function(){return ht.apply(void 0,Xe)},Xe,function(Rt,Se){return Rt.length!==Se.length||Rt.every(function(Le,je){return Le!==Se[je]})})},xt=function(Oe){var Xe,ot;if(!Oe)return!1;if(Ht(Oe)&&Wl>=19)return!0;var Rt=isMemo(Oe)?Oe.type.type:Oe.type;return!(typeof Rt=="function"&&!((Xe=Rt.prototype)!==null&&Xe!==void 0&&Xe.render)&&Rt.$$typeof!==ForwardRef||typeof Oe=="function"&&!((ot=Oe.prototype)!==null&&ot!==void 0&&ot.render)&&Oe.$$typeof!==ForwardRef)};function Ht(Te){return isValidElement(Te)&&!isFragment(Te)}var en=function(Oe){return Ht(Oe)&&xt(Oe)},un=function(Oe){if(Oe&&Ht(Oe)){var Xe=Oe;return Xe.props.propertyIsEnumerable("ref")?Xe.props.ref:Xe.ref}return null};function En(Te,Oe,Xe,ot){if(!Oe.length)return Xe;var Rt=_toArray(Oe),Se=Rt[0],Le=Rt.slice(1),je;return!Te&&typeof Se=="number"?je=[]:Array.isArray(Te)?je=_toConsumableArray(Te):je=_objectSpread({},Te),ot&&Xe===void 0&&Le.length===1?delete je[Se][Le[0]]:je[Se]=En(je[Se],Le,Xe,ot),je}function Yn(Te,Oe,Xe){var ot=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;return Oe.length&&ot&&Xe===void 0&&!get(Te,Oe.slice(0,-1))?Te:En(Te,Oe,Xe,ot)}function Gn(Te){return _typeof(Te)==="object"&&Te!==null&&Object.getPrototypeOf(Te)===Object.prototype}function Si(Te){return Array.isArray(Te)?[]:{}}var Un=typeof Reflect=="undefined"?Object.keys:Reflect.ownKeys;function gi(){for(var Te=arguments.length,Oe=new Array(Te),Xe=0;Xe<Te;Xe++)Oe[Xe]=arguments[Xe];var ot=Si(Oe[0]);return Oe.forEach(function(Rt){function Se(Le,je){var Ke=new Set(je),ct=get(Rt,Le),Et=Array.isArray(ct);if(Et||Gn(ct)){if(!Ke.has(ct)){Ke.add(ct);var Bt=get(ot,Le);Et?ot=Yn(ot,Le,[]):(!Bt||_typeof(Bt)!=="object")&&(ot=Yn(ot,Le,Si(ct))),Un(ct).forEach(function(hn){Se([].concat(_toConsumableArray(Le),[hn]),Ke)})}}else ot=Yn(ot,Le,ct)}Se([])}),ot}var ii={width:0,height:0,display:"flex",overflow:"hidden",opacity:0,border:0,padding:0,margin:0},Oi=function(Oe,Xe){var ot=fr(),Rt=ot.prefixCls,Se=ot.multiple,Le=ot.searchValue,je=ot.toggleOpen,Ke=ot.open,ct=ot.notFoundContent,Et=ke.useContext(Mh),Bt=Et.virtual,hn=Et.listHeight,qt=Et.listItemHeight,nn=Et.listItemScrollOffset,Sn=Et.treeData,yn=Et.fieldNames,Jn=Et.onSelect,In=Et.dropdownMatchSelectWidth,Mn=Et.treeExpandAction,Kn=Et.treeTitleRender,ni=Et.onPopupScroll,yi=Et.leftMaxCount,$i=Et.leafCountOnly,Ai=Et.valueEntities,bi=ke.useContext(ws),dr=bi.checkable,Wn=bi.checkedKeys,Ji=bi.halfCheckedKeys,Pi=bi.treeExpandedKeys,tr=bi.treeDefaultExpandAll,ar=bi.treeDefaultExpandedKeys,ki=bi.onTreeExpand,Fr=bi.treeIcon,hr=bi.showTreeIcon,Mr=bi.switcherIcon,Ti=bi.treeLine,pr=bi.treeNodeFilterProp,qr=bi.loadData,Po=bi.treeLoadedKeys,no=bi.treeMotion,Qi=bi.onTreeLoad,zr=bi.keyEntities,$r=ke.useRef(),lo=sa(function(){return Sn},[Ke,Sn],function(Vi,Ki){return Ki[0]&&Vi[1]!==Ki[1]}),Uo=ke.useMemo(function(){return dr?{checked:Wn,halfChecked:Ji}:null},[dr,Wn,Ji]);ke.useEffect(function(){if(Ke&&!Se&&Wn.length){var Vi;(Vi=$r.current)===null||Vi===void 0||Vi.scrollTo({key:Wn[0]})}},[Ke]);var So=function(Ki){Ki.preventDefault()},Ar=function(Ki,or){var Jr=or.node;dr&&fc(Jr)||(Jn(Jr.key,{selected:!Wn.includes(Jr.key)}),Se||je(!1))},ur=ke.useState(ar),Vr=he(ur,2),Do=Vr[0],Nr=Vr[1],Wi=ke.useState(null),ir=he(Wi,2),rr=ir[0],Fi=ir[1],zi=ke.useMemo(function(){return Pi?$e(Pi):Le?rr:Do},[Do,rr,Pi,Le]),Sr=function(Ki){Nr(Ki),Fi(Ki),ki&&ki(Ki)},io=String(Le).toLowerCase(),Xr=function(Ki){return io?String(Ki[pr]).toLowerCase().includes(io):!1};ke.useEffect(function(){Le&&Fi(kh(Sn,yn))},[Le]);var Ir=ke.useState(function(){return new Map}),wa=he(Ir,2),ra=wa[0],Xo=wa[1];ke.useEffect(function(){yi&&Xo(new Map)},[yi]);function pa(Vi){var Ki=Vi[yn.value];if(!ra.has(Ki)){var or=Ai.get(Ki),Jr=(or.children||[]).length===0;if(Jr)ra.set(Ki,!1);else{var ta=or.children.filter(function(ls){return!ls.node.disabled&&!ls.node.disableCheckbox&&!Wn.includes(ls.node[yn.value])}),Ha=ta.length;ra.set(Ki,Ha>yi)}}return ra.get(Ki)}var ro=tn(function(Vi){var Ki=Vi[yn.value];return Wn.includes(Ki)||yi===null?!1:yi<=0?!0:$i&&yi?pa(Vi):!1}),Jo=function Vi(Ki){var or=Ta(Ki),Jr;try{for(or.s();!(Jr=or.n()).done;){var ta=Jr.value;if(!(ta.disabled||ta.selectable===!1)){if(Le){if(Xr(ta))return ta}else return ta;if(ta[yn.children]){var Ha=Vi(ta[yn.children]);if(Ha)return Ha}}}}catch(ls){or.e(ls)}finally{or.f()}return null},va=ke.useState(null),ds=he(va,2),Pa=ds[0],Ba=ds[1],Bo=zr[Pa];ke.useEffect(function(){if(Ke){var Vi=null,Ki=function(){var Jr=Jo(lo);return Jr?Jr[yn.value]:null};!Se&&Wn.length&&!Le?Vi=Wn[0]:Vi=Ki(),Ba(Vi)}},[Ke,Le]),ke.useImperativeHandle(Xe,function(){var Vi;return{scrollTo:(Vi=$r.current)===null||Vi===void 0?void 0:Vi.scrollTo,onKeyDown:function(or){var Jr,ta=or.which;switch(ta){case ou.UP:case ou.DOWN:case ou.LEFT:case ou.RIGHT:(Jr=$r.current)===null||Jr===void 0||Jr.onKeyDown(or);break;case ou.ENTER:{if(Bo){var Ha=ro(Bo.node),ls=(Bo==null?void 0:Bo.node)||{},bt=ls.selectable,xo=ls.value,zo=ls.disabled;bt!==!1&&!zo&&!Ha&&Ar(null,{node:{key:Pa},selected:!Wn.includes(xo)})}break}case ou.ESC:je(!1)}},onKeyUp:function(){}}});var Za=sa(function(){return!Le},[Le,Pi||Do],function(Vi,Ki){var or=he(Vi,1),Jr=or[0],ta=he(Ki,2),Ha=ta[0],ls=ta[1];return Jr!==Ha&&!!(Ha||ls)}),Fa=Za?qr:null;if(lo.length===0)return ke.createElement("div",{role:"listbox",className:"".concat(Rt,"-empty"),onMouseDown:So},ct);var ns={fieldNames:yn};return Po&&(ns.loadedKeys=Po),zi&&(ns.expandedKeys=zi),ke.createElement("div",{onMouseDown:So},Bo&&Ke&&ke.createElement("span",{style:ii,"aria-live":"assertive"},Bo.node.value),ke.createElement(vu.y6.Provider,{value:{nodeDisabled:ro}},ke.createElement(vu.ZP,Ne({ref:$r,focusable:!1,prefixCls:"".concat(Rt,"-tree"),treeData:lo,height:hn,itemHeight:qt,itemScrollOffset:nn,virtual:Bt!==!1&&In!==!1,multiple:Se,icon:Fr,showIcon:hr,switcherIcon:Mr,showLine:Ti,loadData:Fa,motion:no,activeKey:Pa,checkable:dr,checkStrictly:!0,checkedKeys:Uo,selectedKeys:dr?[]:Wn,defaultExpandAll:tr,titleRender:Kn},ns,{onActiveChange:Ba,onSelect:Ar,onCheck:Ar,onExpand:Sr,onLoad:Qi,filterTreeNode:Xr,expandAction:Mn,onScroll:ni}))))},lr=ke.forwardRef(Oi),br=lr,Zr="SHOW_ALL",Gi="SHOW_PARENT",mr="SHOW_CHILD";function er(Te,Oe,Xe,ot){var Rt=new Set(Te);return Oe===mr?Te.filter(function(Se){var Le=Xe[Se];return!Le||!Le.children||!Le.children.some(function(je){var Ke=je.node;return Rt.has(Ke[ot.value])})||!Le.children.every(function(je){var Ke=je.node;return fc(Ke)||Rt.has(Ke[ot.value])})}):Oe===Gi?Te.filter(function(Se){var Le=Xe[Se],je=Le?Le.parent:null;return!je||fc(je.node)||!Rt.has(je.key)}):Te}function Yr(Te){var Oe=Te.searchPlaceholder,Xe=Te.treeCheckStrictly,ot=Te.treeCheckable,Rt=Te.labelInValue,Se=Te.value,Le=Te.multiple,je=Te.showCheckedStrategy,Ke=Te.maxCount;warning(!Oe,"`searchPlaceholder` has been removed."),Xe&&Rt===!1&&warning(!1,"`treeCheckStrictly` will force set `labelInValue` to `true`."),(Rt||Xe)&&warning(toArray(Se).every(function(ct){return ct&&_typeof(ct)==="object"&&"value"in ct}),"Invalid prop `value` supplied to `TreeSelect`. You should use { label: string, value: string | number } or [{ label: string, value: string | number }] instead."),Xe||Le||ot?warning(!Se||Array.isArray(Se),"`value` should be an array when `TreeSelect` is checkable or multiple."):warning(!Array.isArray(Se),"`value` should not be array when `TreeSelect` is single mode."),Ke&&(je==="SHOW_ALL"&&!Xe||je==="SHOW_PARENT")&&warning(!1,"`maxCount` not work with `showCheckedStrategy=SHOW_ALL` (when `treeCheckStrictly=false`) or `showCheckedStrategy=SHOW_PARENT`.")}var No=null,Wr=["id","prefixCls","value","defaultValue","onChange","onSelect","onDeselect","searchValue","inputValue","onSearch","autoClearSearchValue","filterTreeNode","treeNodeFilterProp","showCheckedStrategy","treeNodeLabelProp","multiple","treeCheckable","treeCheckStrictly","labelInValue","maxCount","fieldNames","treeDataSimpleMode","treeData","children","loadData","treeLoadedKeys","onTreeLoad","treeDefaultExpandAll","treeExpandedKeys","treeDefaultExpandedKeys","onTreeExpand","treeExpandAction","virtual","listHeight","listItemHeight","listItemScrollOffset","onDropdownVisibleChange","dropdownMatchSelectWidth","treeLine","treeIcon","showTreeIcon","switcherIcon","treeMotion","treeTitleRender","onPopupScroll"];function da(Te){return!Te||Mt(Te)!=="object"}var To=ke.forwardRef(function(Te,Oe){var Xe=Te.id,ot=Te.prefixCls,Rt=ot===void 0?"rc-tree-select":ot,Se=Te.value,Le=Te.defaultValue,je=Te.onChange,Ke=Te.onSelect,ct=Te.onDeselect,Et=Te.searchValue,Bt=Te.inputValue,hn=Te.onSearch,qt=Te.autoClearSearchValue,nn=qt===void 0?!0:qt,Sn=Te.filterTreeNode,yn=Te.treeNodeFilterProp,Jn=yn===void 0?"value":yn,In=Te.showCheckedStrategy,Mn=Te.treeNodeLabelProp,Kn=Te.multiple,ni=Te.treeCheckable,yi=Te.treeCheckStrictly,$i=Te.labelInValue,Ai=Te.maxCount,bi=Te.fieldNames,dr=Te.treeDataSimpleMode,Wn=Te.treeData,Ji=Te.children,Pi=Te.loadData,tr=Te.treeLoadedKeys,ar=Te.onTreeLoad,ki=Te.treeDefaultExpandAll,Fr=Te.treeExpandedKeys,hr=Te.treeDefaultExpandedKeys,Mr=Te.onTreeExpand,Ti=Te.treeExpandAction,pr=Te.virtual,qr=Te.listHeight,Po=qr===void 0?200:qr,no=Te.listItemHeight,Qi=no===void 0?20:no,zr=Te.listItemScrollOffset,$r=zr===void 0?0:zr,lo=Te.onDropdownVisibleChange,Uo=Te.dropdownMatchSelectWidth,So=Uo===void 0?!0:Uo,Ar=Te.treeLine,ur=Te.treeIcon,Vr=Te.showTreeIcon,Do=Te.switcherIcon,Nr=Te.treeMotion,Wi=Te.treeTitleRender,ir=Te.onPopupScroll,rr=pe(Te,Wr),Fi=Ms(Xe),zi=ni&&!yi,Sr=ni||yi,io=yi||$i,Xr=Sr||Kn,Ir=hh(Le,{value:Se}),wa=he(Ir,2),ra=wa[0],Xo=wa[1],pa=ke.useMemo(function(){return ni?In||mr:Zr},[In,ni]),ro=ke.useMemo(function(){return Ic(bi)},[JSON.stringify(bi)]),Jo=hh("",{value:Et!==void 0?Et:Bt,postState:function(Yo){return Yo||""}}),va=he(Jo,2),ds=va[0],Pa=va[1],Ba=function(Yo){Pa(Yo),hn==null||hn(Yo)},Bo=ts(Wn,Ji,dr),Za=Wh(Bo,ro),Fa=Za.keyEntities,ns=Za.valueEntities,Vi=ke.useCallback(function(ya){var Yo=[],Sa=[];return ya.forEach(function(is){ns.has(is)?Sa.push(is):Yo.push(is)}),{missingRawValues:Yo,existRawValues:Sa}},[ns]),Ki=ka(Bo,ds,{fieldNames:ro,treeNodeFilterProp:Jn,filterTreeNode:Sn}),or=ke.useCallback(function(ya){if(ya){if(Mn)return ya[Mn];for(var Yo=ro._title,Sa=0;Sa<Yo.length;Sa+=1){var is=ya[Yo[Sa]];if(is!==void 0)return is}}},[ro,Mn]),Jr=ke.useCallback(function(ya){var Yo=bc(ya);return Yo.map(function(Sa){return da(Sa)?{value:Sa}:Sa})},[]),ta=ke.useCallback(function(ya){var Yo=Jr(ya);return Yo.map(function(Sa){var is=Sa.label,Bs=Sa.value,tl=Sa.halfChecked,oo,Ur=ns.get(Bs);if(Ur){var hs;is=Wi?Wi(Ur.node):(hs=is)!==null&&hs!==void 0?hs:or(Ur.node),oo=Ur.node.disabled}else if(is===void 0){var ul=Jr(ra).find(function(nl){return nl.value===Bs});is=ul.label}return{label:is,value:Bs,halfChecked:tl,disabled:oo}})},[ns,or,Jr,ra]),Ha=ke.useMemo(function(){return Jr(ra===null?[]:ra)},[Jr,ra]),ls=ke.useMemo(function(){var ya=[],Yo=[];return Ha.forEach(function(Sa){Sa.halfChecked?Yo.push(Sa):ya.push(Sa)}),[ya,Yo]},[Ha]),bt=he(ls,2),xo=bt[0],zo=bt[1],na=ke.useMemo(function(){return xo.map(function(ya){return ya.value})},[xo]),js=Nu(xo,zo,zi,Fa),us=he(js,2),Hi=us[0],Tr=us[1],nr=ke.useMemo(function(){var ya=er(Hi,pa,Fa,ro),Yo=ya.map(function(tl){var oo,Ur;return(oo=(Ur=Fa[tl])===null||Ur===void 0||(Ur=Ur.node)===null||Ur===void 0?void 0:Ur[ro.value])!==null&&oo!==void 0?oo:tl}),Sa=Yo.map(function(tl){var oo=xo.find(function(hs){return hs.value===tl}),Ur=$i?oo==null?void 0:oo.label:Wi==null?void 0:Wi(oo);return{value:tl,label:Ur}}),is=ta(Sa),Bs=is[0];return!Xr&&Bs&&Fh(Bs.value)&&Fh(Bs.label)?[]:is.map(function(tl){var oo;return sn(sn({},tl),{},{label:(oo=tl.label)!==null&&oo!==void 0?oo:tl.value})})},[ro,Xr,Hi,xo,ta,pa,Fa]),ho=ch(nr),Ca=he(ho,1),Rr=Ca[0],Qo=ke.useMemo(function(){return Xr&&(pa==="SHOW_CHILD"||yi||!ni)?Ai:null},[Ai,Xr,yi,pa,ni]),Eo=sl(function(ya,Yo,Sa){var is=er(ya,pa,Fa,ro);if(!(Qo&&is.length>Qo)){var Bs=ta(ya);if(Xo(Bs),nn&&Pa(""),je){var tl=ya;zi&&(tl=is.map(function(Ol){var eh=ns.get(Ol);return eh?eh.node[ro.value]:Ol}));var oo=Yo||{triggerValue:void 0,selected:void 0},Ur=oo.triggerValue,hs=oo.selected,ul=tl;if(yi){var nl=zo.filter(function(Ol){return!tl.includes(Ol.value)});ul=[].concat($e(ul),$e(nl))}var hl=ta(ul),Os={preValue:xo,triggerValue:Ur},Xl=!0;(yi||Sa==="selection"&&!hs)&&(Xl=!1),Zs(Os,Ur,ya,Bo,Xl,ro),Sr?Os.checked=hs:Os.selected=hs;var Ps=io?hl:hl.map(function(Ol){return Ol.value});je(Xr?Ps:Ps[0],io?null:hl.map(function(Ol){return Ol.label}),Os)}}}),Go=ke.useCallback(function(ya,Yo){var Sa,is=Yo.selected,Bs=Yo.source,tl=Fa[ya],oo=tl==null?void 0:tl.node,Ur=(Sa=oo==null?void 0:oo[ro.value])!==null&&Sa!==void 0?Sa:ya;if(!Xr)Eo([Ur],{selected:!0,triggerValue:Ur},"option");else{var hs=is?[].concat($e(na),[Ur]):Hi.filter(function(eh){return eh!==Ur});if(zi){var ul=Vi(hs),nl=ul.missingRawValues,hl=ul.existRawValues,Os=hl.map(function(eh){return ns.get(eh).key}),Xl;if(is){var Ps=(0,Gl.S)(Os,!0,Fa);Xl=Ps.checkedKeys}else{var Ol=(0,Gl.S)(Os,{checked:!1,halfCheckedKeys:Tr},Fa);Xl=Ol.checkedKeys}hs=[].concat($e(nl),$e(Xl.map(function(eh){return Fa[eh].node[ro.value]})))}Eo(hs,{selected:is,triggerValue:Ur},Bs||"option")}is||!Xr?Ke==null||Ke(Ur,Ja(oo)):ct==null||ct(Ur,Ja(oo))},[Vi,ns,Fa,ro,Xr,na,Eo,zi,Ke,ct,Hi,Tr,Ai]),fa=ke.useCallback(function(ya){if(lo){var Yo={};Object.defineProperty(Yo,"documentClickClose",{get:function(){return Kl(!1,"Second param of `onDropdownVisibleChange` has been removed."),!1}}),lo(ya,Yo)}},[lo]),Aa=sl(function(ya,Yo){var Sa=ya.map(function(is){return is.value});if(Yo.type==="clear"){Eo(Sa,{},"selection");return}Yo.values.length&&Go(Yo.values[0].value,{selected:!1,source:"selection"})}),ll=ke.useMemo(function(){return{virtual:pr,dropdownMatchSelectWidth:So,listHeight:Po,listItemHeight:Qi,listItemScrollOffset:$r,treeData:Ki,fieldNames:ro,onSelect:Go,treeExpandAction:Ti,treeTitleRender:Wi,onPopupScroll:ir,leftMaxCount:Ai===void 0?null:Ai-Rr.length,leafCountOnly:pa==="SHOW_CHILD"&&!yi&&!!ni,valueEntities:ns}},[pr,So,Po,Qi,$r,Ki,ro,Go,Ti,Wi,ir,Ai,Rr.length,pa,yi,ni,ns]),Yl=ke.useMemo(function(){return{checkable:Sr,loadData:Pi,treeLoadedKeys:tr,onTreeLoad:ar,checkedKeys:Hi,halfCheckedKeys:Tr,treeDefaultExpandAll:ki,treeExpandedKeys:Fr,treeDefaultExpandedKeys:hr,onTreeExpand:Mr,treeIcon:ur,treeMotion:Nr,showTreeIcon:Vr,switcherIcon:Do,treeLine:Ar,treeNodeFilterProp:Jn,keyEntities:Fa}},[Sr,Pi,tr,ar,Hi,Tr,ki,Fr,hr,Mr,ur,Nr,Vr,Do,Ar,Jn,Fa]);return ke.createElement(Mh.Provider,{value:ll},ke.createElement(ws.Provider,{value:Yl},ke.createElement(zl,Ne({ref:Oe},rr,{id:Fi,prefixCls:Rt,mode:Xr?"multiple":void 0,displayValues:Rr,onDisplayValuesChange:Aa,searchValue:ds,onSearch:Ba,OptionList:br,emptyOptions:!Bo.length,onDropdownVisibleChange:fa,dropdownMatchSelectWidth:So}))))}),la=To;la.TreeNode=po,la.SHOW_ALL=Zr,la.SHOW_PARENT=Gi,la.SHOW_CHILD=mr;var ys=la,Da=ys},18798:function(jn,li){"use strict";var De;var Ne=typeof Symbol=="function"&&Symbol.for,dt=Ne?Symbol.for("react.element"):60103,Ut=Ne?Symbol.for("react.portal"):60106,$t=Ne?Symbol.for("react.fragment"):60107,kt=Ne?Symbol.for("react.strict_mode"):60108,Ie=Ne?Symbol.for("react.profiler"):60114,$e=Ne?Symbol.for("react.provider"):60109,Mt=Ne?Symbol.for("react.context"):60110,Pt=Ne?Symbol.for("react.async_mode"):60111,wt=Ne?Symbol.for("react.concurrent_mode"):60111,Qt=Ne?Symbol.for("react.forward_ref"):60112,It=Ne?Symbol.for("react.suspense"):60113,sn=Ne?Symbol.for("react.suspense_list"):60120,Re=Ne?Symbol.for("react.memo"):60115,ne=Ne?Symbol.for("react.lazy"):60116,te=Ne?Symbol.for("react.block"):60121,he=Ne?Symbol.for("react.fundamental"):60117,le=Ne?Symbol.for("react.responder"):60118,pe=Ne?Symbol.for("react.scope"):60119;function me(Ee){if(typeof Ee=="object"&&Ee!==null){var Ge=Ee.$$typeof;switch(Ge){case dt:switch(Ee=Ee.type,Ee){case Pt:case wt:case $t:case Ie:case kt:case It:return Ee;default:switch(Ee=Ee&&Ee.$$typeof,Ee){case Mt:case Qt:case ne:case Re:case $e:return Ee;default:return Ge}}case Ut:return Ge}}}function xe(Ee){return me(Ee)===wt}De=Pt,De=wt,De=Mt,De=$e,De=dt,De=Qt,De=$t,De=ne,De=Re,De=Ut,De=Ie,De=kt,De=It,De=function(Ee){return xe(Ee)||me(Ee)===Pt},De=xe,De=function(Ee){return me(Ee)===Mt},De=function(Ee){return me(Ee)===$e},De=function(Ee){return typeof Ee=="object"&&Ee!==null&&Ee.$$typeof===dt},De=function(Ee){return me(Ee)===Qt},li.isFragment=function(Ee){return me(Ee)===$t},De=function(Ee){return me(Ee)===ne},De=function(Ee){return me(Ee)===Re},De=function(Ee){return me(Ee)===Ut},De=function(Ee){return me(Ee)===Ie},De=function(Ee){return me(Ee)===kt},De=function(Ee){return me(Ee)===It},De=function(Ee){return typeof Ee=="string"||typeof Ee=="function"||Ee===$t||Ee===wt||Ee===Ie||Ee===kt||Ee===It||Ee===sn||typeof Ee=="object"&&Ee!==null&&(Ee.$$typeof===ne||Ee.$$typeof===Re||Ee.$$typeof===$e||Ee.$$typeof===Mt||Ee.$$typeof===Qt||Ee.$$typeof===he||Ee.$$typeof===le||Ee.$$typeof===pe||Ee.$$typeof===te)},De=me},95936:function(jn,li,De){"use strict";jn.exports=De(18798)},39988:function(jn,li){"use strict";var De;var Ne=Symbol.for("react.element"),dt=Symbol.for("react.portal"),Ut=Symbol.for("react.fragment"),$t=Symbol.for("react.strict_mode"),kt=Symbol.for("react.profiler"),Ie=Symbol.for("react.provider"),$e=Symbol.for("react.context"),Mt=Symbol.for("react.server_context"),Pt=Symbol.for("react.forward_ref"),wt=Symbol.for("react.suspense"),Qt=Symbol.for("react.suspense_list"),It=Symbol.for("react.memo"),sn=Symbol.for("react.lazy"),Re=Symbol.for("react.offscreen"),ne;ne=Symbol.for("react.module.reference");function te(he){if(typeof he=="object"&&he!==null){var le=he.$$typeof;switch(le){case Ne:switch(he=he.type,he){case Ut:case kt:case $t:case wt:case Qt:return he;default:switch(he=he&&he.$$typeof,he){case Mt:case $e:case Pt:case sn:case It:case Ie:return he;default:return le}}case dt:return le}}}De=$e,De=Ie,De=Ne,De=Pt,De=Ut,De=sn,De=It,De=dt,De=kt,De=$t,De=wt,De=Qt,De=function(){return!1},De=function(){return!1},De=function(he){return te(he)===$e},De=function(he){return te(he)===Ie},De=function(he){return typeof he=="object"&&he!==null&&he.$$typeof===Ne},De=function(he){return te(he)===Pt},De=function(he){return te(he)===Ut},De=function(he){return te(he)===sn},De=function(he){return te(he)===It},De=function(he){return te(he)===dt},De=function(he){return te(he)===kt},De=function(he){return te(he)===$t},De=function(he){return te(he)===wt},De=function(he){return te(he)===Qt},De=function(he){return typeof he=="string"||typeof he=="function"||he===Ut||he===kt||he===$t||he===wt||he===Qt||he===Re||typeof he=="object"&&he!==null&&(he.$$typeof===sn||he.$$typeof===It||he.$$typeof===Ie||he.$$typeof===$e||he.$$typeof===Pt||he.$$typeof===ne||he.getModuleId!==void 0)},De=te},66133:function(jn,li,De){"use strict";De(39988)},86128:function(jn,li,De){"use strict";De.d(li,{Z:function(){return me}});var Ne=De(87462),dt=De(4942),Ut=De(1413),$t=De(97685),kt=De(45987),Ie=De(67294),$e=De(94184),Mt=De.n($e),Pt=De(64217),wt=De(27822),Qt=function(Ee){for(var Ge=Ee.prefixCls,et=Ee.level,ut=Ee.isStart,st=Ee.isEnd,it="".concat(Ge,"-indent-unit"),Nt=[],St=0;St<et;St+=1)Nt.push(Ie.createElement("span",{key:St,className:Mt()(it,(0,dt.Z)((0,dt.Z)({},"".concat(it,"-start"),ut[St]),"".concat(it,"-end"),st[St]))}));return Ie.createElement("span",{"aria-hidden":"true",className:"".concat(Ge,"-indent")},Nt)},It=Ie.memo(Qt),sn=De(35381),Re=De(1089),ne=["eventKey","className","style","dragOver","dragOverGapTop","dragOverGapBottom","isLeaf","isStart","isEnd","expanded","selected","checked","halfChecked","loading","domRef","active","data","onMouseMove","selectable"],te="open",he="close",le="---",pe=function(Ee){var Ge,et,ut,st=Ee.eventKey,it=Ee.className,Nt=Ee.style,St=Ee.dragOver,Ft=Ee.dragOverGapTop,cn=Ee.dragOverGapBottom,Tt=Ee.isLeaf,hi=Ee.isStart,di=Ee.isEnd,zn=Ee.expanded,Dn=Ee.selected,nt=Ee.checked,ze=Ee.halfChecked,ke=Ee.loading,Wt=Ee.domRef,On=Ee.active,Lt=Ee.data,xn=Ee.onMouseMove,vn=Ee.selectable,Xn=(0,kt.Z)(Ee,ne),Ot=Ie.useContext(wt.k),ft=Ie.useContext(wt.y),Gt=Ie.useRef(null),an=Ie.useState(!1),Jt=(0,$t.Z)(an,2),Ve=Jt[0],be=Jt[1],Pe=!!(Ot.disabled||Ee.disabled||(Ge=ft.nodeDisabled)!==null&&Ge!==void 0&&Ge.call(ft,Lt)),Be=Ie.useMemo(function(){return!Ot.checkable||Ee.checkable===!1?!1:Ot.checkable},[Ot.checkable,Ee.checkable]),Ze=function(bn){Pe||Ot.onNodeSelect(bn,(0,Re.F)(Ee))},Fe=function(bn){Pe||!Be||Ee.disableCheckbox||Ot.onNodeCheck(bn,(0,Re.F)(Ee),!nt)},qe=Ie.useMemo(function(){return typeof vn=="boolean"?vn:Ot.selectable},[vn,Ot.selectable]),dn=function(bn){Ot.onNodeClick(bn,(0,Re.F)(Ee)),qe?Ze(bn):Fe(bn)},ui=function(bn){Ot.onNodeDoubleClick(bn,(0,Re.F)(Ee))},$n=function(bn){Ot.onNodeMouseEnter(bn,(0,Re.F)(Ee))},rn=function(bn){Ot.onNodeMouseLeave(bn,(0,Re.F)(Ee))},Hn=function(bn){Ot.onNodeContextMenu(bn,(0,Re.F)(Ee))},Zt=Ie.useMemo(function(){return!!(Ot.draggable&&(!Ot.draggable.nodeDraggable||Ot.draggable.nodeDraggable(Lt)))},[Ot.draggable,Lt]),_n=function(bn){bn.stopPropagation(),be(!0),Ot.onNodeDragStart(bn,Ee);try{bn.dataTransfer.setData("text/plain","")}catch(on){}},ti=function(bn){bn.preventDefault(),bn.stopPropagation(),Ot.onNodeDragEnter(bn,Ee)},Ri=function(bn){bn.preventDefault(),bn.stopPropagation(),Ot.onNodeDragOver(bn,Ee)},oi=function(bn){bn.stopPropagation(),Ot.onNodeDragLeave(bn,Ee)},wr=function(bn){bn.stopPropagation(),be(!1),Ot.onNodeDragEnd(bn,Ee)},fr=function(bn){bn.preventDefault(),bn.stopPropagation(),be(!1),Ot.onNodeDrop(bn,Ee)},Ei=function(bn){ke||Ot.onNodeExpand(bn,(0,Re.F)(Ee))},Di=Ie.useMemo(function(){var Qn=(0,sn.Z)(Ot.keyEntities,st)||{},bn=Qn.children;return!!(bn||[]).length},[Ot.keyEntities,st]),uo=Ie.useMemo(function(){return Tt===!1?!1:Tt||!Ot.loadData&&!Di||Ot.loadData&&Ee.loaded&&!Di},[Tt,Ot.loadData,Di,Ee.loaded]);Ie.useEffect(function(){ke||typeof Ot.loadData=="function"&&zn&&!uo&&!Ee.loaded&&Ot.onNodeLoad((0,Re.F)(Ee))},[ke,Ot.loadData,Ot.onNodeLoad,zn,uo,Ee]);var vt=Ie.useMemo(function(){var Qn;return(Qn=Ot.draggable)!==null&&Qn!==void 0&&Qn.icon?Ie.createElement("span",{className:"".concat(Ot.prefixCls,"-draggable-icon")},Ot.draggable.icon):null},[Ot.draggable]),ei=function(bn){var on=Ee.switcherIcon||Ot.switcherIcon;return typeof on=="function"?on((0,Ut.Z)((0,Ut.Z)({},Ee),{},{isLeaf:bn})):on},co=function(){if(uo){var bn=ei(!0);return bn!==!1?Ie.createElement("span",{className:Mt()("".concat(Ot.prefixCls,"-switcher"),"".concat(Ot.prefixCls,"-switcher-noop"))},bn):null}var on=ei(!1);return on!==!1?Ie.createElement("span",{onClick:Ei,className:Mt()("".concat(Ot.prefixCls,"-switcher"),"".concat(Ot.prefixCls,"-switcher_").concat(zn?te:he))},on):null},bo=Ie.useMemo(function(){if(!Be)return null;var Qn=typeof Be!="boolean"?Be:null;return Ie.createElement("span",{className:Mt()("".concat(Ot.prefixCls,"-checkbox"),(0,dt.Z)((0,dt.Z)((0,dt.Z)({},"".concat(Ot.prefixCls,"-checkbox-checked"),nt),"".concat(Ot.prefixCls,"-checkbox-indeterminate"),!nt&&ze),"".concat(Ot.prefixCls,"-checkbox-disabled"),Pe||Ee.disableCheckbox)),onClick:Fe,role:"checkbox","aria-checked":ze?"mixed":nt,"aria-disabled":Pe||Ee.disableCheckbox,"aria-label":"Select ".concat(typeof Ee.title=="string"?Ee.title:"tree node")},Qn)},[Be,nt,ze,Pe,Ee.disableCheckbox,Ee.title]),Ui=Ie.useMemo(function(){return uo?null:zn?te:he},[uo,zn]),yo=Ie.useMemo(function(){return Ie.createElement("span",{className:Mt()("".concat(Ot.prefixCls,"-iconEle"),"".concat(Ot.prefixCls,"-icon__").concat(Ui||"docu"),(0,dt.Z)({},"".concat(Ot.prefixCls,"-icon_loading"),ke))})},[Ot.prefixCls,Ui,ke]),ha=Ie.useMemo(function(){var Qn=!!Ot.draggable,bn=!Ee.disabled&&Qn&&Ot.dragOverNodeKey===st;return bn?Ot.dropIndicatorRender({dropPosition:Ot.dropPosition,dropLevelOffset:Ot.dropLevelOffset,indent:Ot.indent,prefixCls:Ot.prefixCls,direction:Ot.direction}):null},[Ot.dropPosition,Ot.dropLevelOffset,Ot.indent,Ot.prefixCls,Ot.direction,Ot.draggable,Ot.dragOverNodeKey,Ot.dropIndicatorRender]),Ka=Ie.useMemo(function(){var Qn=Ee.title,bn=Qn===void 0?le:Qn,on="".concat(Ot.prefixCls,"-node-content-wrapper"),ln;if(Ot.showIcon){var gn=Ee.icon||Ot.icon;ln=gn?Ie.createElement("span",{className:Mt()("".concat(Ot.prefixCls,"-iconEle"),"".concat(Ot.prefixCls,"-icon__customize"))},typeof gn=="function"?gn(Ee):gn):yo}else Ot.loadData&&ke&&(ln=yo);var Vn;return typeof bn=="function"?Vn=bn(Lt):Ot.titleRender?Vn=Ot.titleRender(Lt):Vn=bn,Ie.createElement("span",{ref:Gt,title:typeof bn=="string"?bn:"",className:Mt()(on,"".concat(on,"-").concat(Ui||"normal"),(0,dt.Z)({},"".concat(Ot.prefixCls,"-node-selected"),!Pe&&(Dn||Ve))),onMouseEnter:$n,onMouseLeave:rn,onContextMenu:Hn,onClick:dn,onDoubleClick:ui},ln,Ie.createElement("span",{className:"".concat(Ot.prefixCls,"-title")},Vn),ha)},[Ot.prefixCls,Ot.showIcon,Ee,Ot.icon,yo,Ot.titleRender,Lt,Ui,$n,rn,Hn,dn,ui]),Ra=(0,Pt.Z)(Xn,{aria:!0,data:!0}),ca=(0,sn.Z)(Ot.keyEntities,st)||{},ma=ca.level,Ho=di[di.length-1],_r=!Pe&&Zt,Fn=Ot.draggingNodeKey===st,we=vn!==void 0?{"aria-selected":!!vn}:void 0;return Ie.createElement("div",(0,Ne.Z)({ref:Wt,role:"treeitem","aria-expanded":Tt?void 0:zn,className:Mt()(it,"".concat(Ot.prefixCls,"-treenode"),(ut={},(0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)(ut,"".concat(Ot.prefixCls,"-treenode-disabled"),Pe),"".concat(Ot.prefixCls,"-treenode-switcher-").concat(zn?"open":"close"),!Tt),"".concat(Ot.prefixCls,"-treenode-checkbox-checked"),nt),"".concat(Ot.prefixCls,"-treenode-checkbox-indeterminate"),ze),"".concat(Ot.prefixCls,"-treenode-selected"),Dn),"".concat(Ot.prefixCls,"-treenode-loading"),ke),"".concat(Ot.prefixCls,"-treenode-active"),On),"".concat(Ot.prefixCls,"-treenode-leaf-last"),Ho),"".concat(Ot.prefixCls,"-treenode-draggable"),Zt),"dragging",Fn),(0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)((0,dt.Z)(ut,"drop-target",Ot.dropTargetKey===st),"drop-container",Ot.dropContainerKey===st),"drag-over",!Pe&&St),"drag-over-gap-top",!Pe&&Ft),"drag-over-gap-bottom",!Pe&&cn),"filter-node",(et=Ot.filterTreeNode)===null||et===void 0?void 0:et.call(Ot,(0,Re.F)(Ee))),"".concat(Ot.prefixCls,"-treenode-leaf"),uo))),style:Nt,draggable:_r,onDragStart:_r?_n:void 0,onDragEnter:Zt?ti:void 0,onDragOver:Zt?Ri:void 0,onDragLeave:Zt?oi:void 0,onDrop:Zt?fr:void 0,onDragEnd:Zt?wr:void 0,onMouseMove:xn},we,Ra),Ie.createElement(It,{prefixCls:Ot.prefixCls,level:ma,isStart:hi,isEnd:di}),vt,co(),bo,Ka)};pe.isTreeNode=1;var me=pe},27822:function(jn,li,De){"use strict";De.d(li,{k:function(){return dt},y:function(){return Ut}});var Ne=De(67294),dt=Ne.createContext(null),Ut=Ne.createContext({})},70593:function(jn,li,De){"use strict";De.d(li,{OF:function(){return st.Z},y6:function(){return he.y},ZP:function(){return Pe}});var Ne=De(87462),dt=De(71002),Ut=De(1413),$t=De(74902),kt=De(15671),Ie=De(43144),$e=De(97326),Mt=De(60136),Pt=De(29388),wt=De(4942),Qt=De(94184),It=De.n(Qt),sn=De(15105),Re=De(64217),ne=De(80334),te=De(67294),he=De(27822),le=function(Ze){var Fe=Ze.dropPosition,qe=Ze.dropLevelOffset,dn=Ze.indent,ui={pointerEvents:"none",position:"absolute",right:0,backgroundColor:"red",height:2};switch(Fe){case-1:ui.top=0,ui.left=-qe*dn;break;case 1:ui.bottom=0,ui.left=-qe*dn;break;case 0:ui.bottom=0,ui.left=dn;break}return te.createElement("div",{style:ui})},pe=le;function me(Be){if(Be==null)throw new TypeError("Cannot destructure "+Be)}var xe=De(97685),Ee=De(45987),Ge=De(8410),et=De(73299),ut=De(62874),st=De(86128);function it(Be,Ze){var Fe=te.useState(!1),qe=(0,xe.Z)(Fe,2),dn=qe[0],ui=qe[1];(0,Ge.Z)(function(){if(dn)return Be(),function(){Ze()}},[dn]),(0,Ge.Z)(function(){return ui(!0),function(){ui(!1)}},[])}var Nt=it,St=De(1089),Ft=["className","style","motion","motionNodes","motionType","onMotionStart","onMotionEnd","active","treeNodeRequiredProps"],cn=te.forwardRef(function(Be,Ze){var Fe=Be.className,qe=Be.style,dn=Be.motion,ui=Be.motionNodes,$n=Be.motionType,rn=Be.onMotionStart,Hn=Be.onMotionEnd,Zt=Be.active,_n=Be.treeNodeRequiredProps,ti=(0,Ee.Z)(Be,Ft),Ri=te.useState(!0),oi=(0,xe.Z)(Ri,2),wr=oi[0],fr=oi[1],Ei=te.useContext(he.k),Di=Ei.prefixCls,uo=ui&&$n!=="hide";(0,Ge.Z)(function(){ui&&uo!==wr&&fr(uo)},[ui]);var vt=function(){ui&&rn()},ei=te.useRef(!1),co=function(){ui&&!ei.current&&(ei.current=!0,Hn())};Nt(vt,co);var bo=function(yo){uo===yo&&co()};return ui?te.createElement(ut.Z,(0,Ne.Z)({ref:Ze,visible:wr},dn,{motionAppear:$n==="show",onVisibleChanged:bo}),function(Ui,yo){var ha=Ui.className,Ka=Ui.style;return te.createElement("div",{ref:yo,className:It()("".concat(Di,"-treenode-motion"),ha),style:Ka},ui.map(function(Ra){var ca=Object.assign({},(me(Ra.data),Ra.data)),ma=Ra.title,Ho=Ra.key,_r=Ra.isStart,Fn=Ra.isEnd;delete ca.children;var we=(0,St.H8)(Ho,_n);return te.createElement(st.Z,(0,Ne.Z)({},ca,we,{title:ma,active:Zt,data:Ra.data,key:Ho,isStart:_r,isEnd:Fn}))}))}):te.createElement(st.Z,(0,Ne.Z)({domRef:Ze,className:Fe,style:qe},ti,{active:Zt}))}),Tt=cn;function hi(){var Be=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],Ze=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],Fe=Be.length,qe=Ze.length;if(Math.abs(Fe-qe)!==1)return{add:!1,key:null};function dn(ui,$n){var rn=new Map;ui.forEach(function(Zt){rn.set(Zt,!0)});var Hn=$n.filter(function(Zt){return!rn.has(Zt)});return Hn.length===1?Hn[0]:null}return Fe<qe?{add:!0,key:dn(Be,Ze)}:{add:!1,key:dn(Ze,Be)}}function di(Be,Ze,Fe){var qe=Be.findIndex(function(rn){return rn.key===Fe}),dn=Be[qe+1],ui=Ze.findIndex(function(rn){return rn.key===Fe});if(dn){var $n=Ze.findIndex(function(rn){return rn.key===dn.key});return Ze.slice(ui+1,$n)}return Ze.slice(ui+1)}var zn=["prefixCls","data","selectable","checkable","expandedKeys","selectedKeys","checkedKeys","loadedKeys","loadingKeys","halfCheckedKeys","keyEntities","disabled","dragging","dragOverNodeKey","dropPosition","motion","height","itemHeight","virtual","scrollWidth","focusable","activeItem","focused","tabIndex","onKeyDown","onFocus","onBlur","onActiveChange","onListChangeStart","onListChangeEnd"],Dn={width:0,height:0,display:"flex",overflow:"hidden",opacity:0,border:0,padding:0,margin:0},nt=function(){},ze="RC_TREE_MOTION_".concat(Math.random()),ke={key:ze},Wt={key:ze,level:0,index:0,pos:"0",node:ke,nodes:[ke]},On={parent:null,children:[],pos:Wt.pos,data:ke,title:null,key:ze,isStart:[],isEnd:[]};function Lt(Be,Ze,Fe,qe){return Ze===!1||!Fe?Be:Be.slice(0,Math.ceil(Fe/qe)+1)}function xn(Be){var Ze=Be.key,Fe=Be.pos;return(0,St.km)(Ze,Fe)}function vn(Be){for(var Ze=String(Be.data.key),Fe=Be;Fe.parent;)Fe=Fe.parent,Ze="".concat(Fe.data.key," > ").concat(Ze);return Ze}var Xn=te.forwardRef(function(Be,Ze){var Fe=Be.prefixCls,qe=Be.data,dn=Be.selectable,ui=Be.checkable,$n=Be.expandedKeys,rn=Be.selectedKeys,Hn=Be.checkedKeys,Zt=Be.loadedKeys,_n=Be.loadingKeys,ti=Be.halfCheckedKeys,Ri=Be.keyEntities,oi=Be.disabled,wr=Be.dragging,fr=Be.dragOverNodeKey,Ei=Be.dropPosition,Di=Be.motion,uo=Be.height,vt=Be.itemHeight,ei=Be.virtual,co=Be.scrollWidth,bo=Be.focusable,Ui=Be.activeItem,yo=Be.focused,ha=Be.tabIndex,Ka=Be.onKeyDown,Ra=Be.onFocus,ca=Be.onBlur,ma=Be.onActiveChange,Ho=Be.onListChangeStart,_r=Be.onListChangeEnd,Fn=(0,Ee.Z)(Be,zn),we=te.useRef(null),Qn=te.useRef(null);te.useImperativeHandle(Ze,function(){return{scrollTo:function(La){we.current.scrollTo(La)},getIndentWidth:function(){return Qn.current.offsetWidth}}});var bn=te.useState($n),on=(0,xe.Z)(bn,2),ln=on[0],gn=on[1],Vn=te.useState(qe),_i=(0,xe.Z)(Vn,2),jt=_i[0],zt=_i[1],Ct=te.useState(qe),Yt=(0,xe.Z)(Ct,2),ci=Yt[0],vi=Yt[1],ai=te.useState([]),Kt=(0,xe.Z)(ai,2),wn=Kt[0],pi=Kt[1],ji=te.useState(null),Rn=(0,xe.Z)(ji,2),Dt=Rn[0],wi=Rn[1],gr=te.useRef(qe);gr.current=qe;function eo(){var Lo=gr.current;zt(Lo),vi(Lo),pi([]),wi(null),_r()}(0,Ge.Z)(function(){gn($n);var Lo=hi(ln,$n);if(Lo.key!==null)if(Lo.add){var La=jt.findIndex(function(Zo){var ri=Zo.key;return ri===Lo.key}),$o=Lt(di(jt,qe,Lo.key),ei,uo,vt),qi=jt.slice();qi.splice(La+1,0,On),vi(qi),pi($o),wi("show")}else{var Zi=qe.findIndex(function(Zo){var ri=Zo.key;return ri===Lo.key}),cr=Lt(di(qe,jt,Lo.key),ei,uo,vt),Co=qe.slice();Co.splice(Zi+1,0,On),vi(Co),pi(cr),wi("hide")}else jt!==qe&&(zt(qe),vi(qe))},[$n,qe]),te.useEffect(function(){wr||eo()},[wr]);var kn=Di?ci:qe,Xi={expandedKeys:$n,selectedKeys:rn,loadedKeys:Zt,loadingKeys:_n,checkedKeys:Hn,halfCheckedKeys:ti,dragOverNodeKey:fr,dropPosition:Ei,keyEntities:Ri};return te.createElement(te.Fragment,null,yo&&Ui&&te.createElement("span",{style:Dn,"aria-live":"assertive"},vn(Ui)),te.createElement("div",null,te.createElement("input",{style:Dn,disabled:bo===!1||oi,tabIndex:bo!==!1?ha:null,onKeyDown:Ka,onFocus:Ra,onBlur:ca,value:"",onChange:nt,"aria-label":"for screen reader"})),te.createElement("div",{className:"".concat(Fe,"-treenode"),"aria-hidden":!0,style:{position:"absolute",pointerEvents:"none",visibility:"hidden",height:0,overflow:"hidden",border:0,padding:0}},te.createElement("div",{className:"".concat(Fe,"-indent")},te.createElement("div",{ref:Qn,className:"".concat(Fe,"-indent-unit")}))),te.createElement(et.Z,(0,Ne.Z)({},Fn,{data:kn,itemKey:xn,height:uo,fullHeight:!1,virtual:ei,itemHeight:vt,scrollWidth:co,prefixCls:"".concat(Fe,"-list"),ref:we,role:"tree",onVisibleChange:function(La){La.every(function($o){return xn($o)!==ze})&&eo()}}),function(Lo){var La=Lo.pos,$o=Object.assign({},(me(Lo.data),Lo.data)),qi=Lo.title,Zi=Lo.key,cr=Lo.isStart,Co=Lo.isEnd,Zo=(0,St.km)(Zi,La);delete $o.key,delete $o.children;var ri=(0,St.H8)(Zo,Xi);return te.createElement(Tt,(0,Ne.Z)({},$o,ri,{title:qi,active:!!Ui&&Zi===Ui.key,pos:La,data:Lo.data,isStart:cr,isEnd:Co,motion:Di,motionNodes:Zi===ze?wn:null,motionType:Dt,onMotionStart:Ho,onMotionEnd:eo,treeNodeRequiredProps:Xi,onMouseMove:function(){ma(null)}}))}))}),Ot=Xn,ft=De(10225),Gt=De(17341),an=De(35381),Jt=10,Ve=function(Be){(0,Mt.Z)(Fe,Be);var Ze=(0,Pt.Z)(Fe);function Fe(){var qe;(0,kt.Z)(this,Fe);for(var dn=arguments.length,ui=new Array(dn),$n=0;$n<dn;$n++)ui[$n]=arguments[$n];return qe=Ze.call.apply(Ze,[this].concat(ui)),(0,wt.Z)((0,$e.Z)(qe),"destroyed",!1),(0,wt.Z)((0,$e.Z)(qe),"delayedDragEnterLogic",void 0),(0,wt.Z)((0,$e.Z)(qe),"loadingRetryTimes",{}),(0,wt.Z)((0,$e.Z)(qe),"state",{keyEntities:{},indent:null,selectedKeys:[],checkedKeys:[],halfCheckedKeys:[],loadedKeys:[],loadingKeys:[],expandedKeys:[],draggingNodeKey:null,dragChildrenKeys:[],dropTargetKey:null,dropPosition:null,dropContainerKey:null,dropLevelOffset:null,dropTargetPos:null,dropAllowed:!0,dragOverNodeKey:null,treeData:[],flattenNodes:[],focused:!1,activeKey:null,listChanging:!1,prevProps:null,fieldNames:(0,St.w$)()}),(0,wt.Z)((0,$e.Z)(qe),"dragStartMousePosition",null),(0,wt.Z)((0,$e.Z)(qe),"dragNodeProps",null),(0,wt.Z)((0,$e.Z)(qe),"currentMouseOverDroppableNodeKey",null),(0,wt.Z)((0,$e.Z)(qe),"listRef",te.createRef()),(0,wt.Z)((0,$e.Z)(qe),"onNodeDragStart",function(rn,Hn){var Zt=qe.state,_n=Zt.expandedKeys,ti=Zt.keyEntities,Ri=qe.props.onDragStart,oi=Hn.eventKey;qe.dragNodeProps=Hn,qe.dragStartMousePosition={x:rn.clientX,y:rn.clientY};var wr=(0,ft._5)(_n,oi);qe.setState({draggingNodeKey:oi,dragChildrenKeys:(0,ft.wA)(oi,ti),indent:qe.listRef.current.getIndentWidth()}),qe.setExpandedKeys(wr),window.addEventListener("dragend",qe.onWindowDragEnd),Ri==null||Ri({event:rn,node:(0,St.F)(Hn)})}),(0,wt.Z)((0,$e.Z)(qe),"onNodeDragEnter",function(rn,Hn){var Zt=qe.state,_n=Zt.expandedKeys,ti=Zt.keyEntities,Ri=Zt.dragChildrenKeys,oi=Zt.flattenNodes,wr=Zt.indent,fr=qe.props,Ei=fr.onDragEnter,Di=fr.onExpand,uo=fr.allowDrop,vt=fr.direction,ei=Hn.pos,co=Hn.eventKey;if(qe.currentMouseOverDroppableNodeKey!==co&&(qe.currentMouseOverDroppableNodeKey=co),!qe.dragNodeProps){qe.resetDragState();return}var bo=(0,ft.OM)(rn,qe.dragNodeProps,Hn,wr,qe.dragStartMousePosition,uo,oi,ti,_n,vt),Ui=bo.dropPosition,yo=bo.dropLevelOffset,ha=bo.dropTargetKey,Ka=bo.dropContainerKey,Ra=bo.dropTargetPos,ca=bo.dropAllowed,ma=bo.dragOverNodeKey;if(Ri.includes(ha)||!ca){qe.resetDragState();return}if(qe.delayedDragEnterLogic||(qe.delayedDragEnterLogic={}),Object.keys(qe.delayedDragEnterLogic).forEach(function(Ho){clearTimeout(qe.delayedDragEnterLogic[Ho])}),qe.dragNodeProps.eventKey!==Hn.eventKey&&(rn.persist(),qe.delayedDragEnterLogic[ei]=window.setTimeout(function(){if(qe.state.draggingNodeKey!==null){var Ho=(0,$t.Z)(_n),_r=(0,an.Z)(ti,Hn.eventKey);_r&&(_r.children||[]).length&&(Ho=(0,ft.L0)(_n,Hn.eventKey)),qe.props.hasOwnProperty("expandedKeys")||qe.setExpandedKeys(Ho),Di==null||Di(Ho,{node:(0,St.F)(Hn),expanded:!0,nativeEvent:rn.nativeEvent})}},800)),qe.dragNodeProps.eventKey===ha&&yo===0){qe.resetDragState();return}qe.setState({dragOverNodeKey:ma,dropPosition:Ui,dropLevelOffset:yo,dropTargetKey:ha,dropContainerKey:Ka,dropTargetPos:Ra,dropAllowed:ca}),Ei==null||Ei({event:rn,node:(0,St.F)(Hn),expandedKeys:_n})}),(0,wt.Z)((0,$e.Z)(qe),"onNodeDragOver",function(rn,Hn){var Zt=qe.state,_n=Zt.dragChildrenKeys,ti=Zt.flattenNodes,Ri=Zt.keyEntities,oi=Zt.expandedKeys,wr=Zt.indent,fr=qe.props,Ei=fr.onDragOver,Di=fr.allowDrop,uo=fr.direction;if(qe.dragNodeProps){var vt=(0,ft.OM)(rn,qe.dragNodeProps,Hn,wr,qe.dragStartMousePosition,Di,ti,Ri,oi,uo),ei=vt.dropPosition,co=vt.dropLevelOffset,bo=vt.dropTargetKey,Ui=vt.dropContainerKey,yo=vt.dropTargetPos,ha=vt.dropAllowed,Ka=vt.dragOverNodeKey;_n.includes(bo)||!ha||(qe.dragNodeProps.eventKey===bo&&co===0?qe.state.dropPosition===null&&qe.state.dropLevelOffset===null&&qe.state.dropTargetKey===null&&qe.state.dropContainerKey===null&&qe.state.dropTargetPos===null&&qe.state.dropAllowed===!1&&qe.state.dragOverNodeKey===null||qe.resetDragState():ei===qe.state.dropPosition&&co===qe.state.dropLevelOffset&&bo===qe.state.dropTargetKey&&Ui===qe.state.dropContainerKey&&yo===qe.state.dropTargetPos&&ha===qe.state.dropAllowed&&Ka===qe.state.dragOverNodeKey||qe.setState({dropPosition:ei,dropLevelOffset:co,dropTargetKey:bo,dropContainerKey:Ui,dropTargetPos:yo,dropAllowed:ha,dragOverNodeKey:Ka}),Ei==null||Ei({event:rn,node:(0,St.F)(Hn)}))}}),(0,wt.Z)((0,$e.Z)(qe),"onNodeDragLeave",function(rn,Hn){qe.currentMouseOverDroppableNodeKey===Hn.eventKey&&!rn.currentTarget.contains(rn.relatedTarget)&&(qe.resetDragState(),qe.currentMouseOverDroppableNodeKey=null);var Zt=qe.props.onDragLeave;Zt==null||Zt({event:rn,node:(0,St.F)(Hn)})}),(0,wt.Z)((0,$e.Z)(qe),"onWindowDragEnd",function(rn){qe.onNodeDragEnd(rn,null,!0),window.removeEventListener("dragend",qe.onWindowDragEnd)}),(0,wt.Z)((0,$e.Z)(qe),"onNodeDragEnd",function(rn,Hn){var Zt=qe.props.onDragEnd;qe.setState({dragOverNodeKey:null}),qe.cleanDragState(),Zt==null||Zt({event:rn,node:(0,St.F)(Hn)}),qe.dragNodeProps=null,window.removeEventListener("dragend",qe.onWindowDragEnd)}),(0,wt.Z)((0,$e.Z)(qe),"onNodeDrop",function(rn,Hn){var Zt,_n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,ti=qe.state,Ri=ti.dragChildrenKeys,oi=ti.dropPosition,wr=ti.dropTargetKey,fr=ti.dropTargetPos,Ei=ti.dropAllowed;if(Ei){var Di=qe.props.onDrop;if(qe.setState({dragOverNodeKey:null}),qe.cleanDragState(),wr!==null){var uo=(0,Ut.Z)((0,Ut.Z)({},(0,St.H8)(wr,qe.getTreeNodeRequiredProps())),{},{active:((Zt=qe.getActiveItem())===null||Zt===void 0?void 0:Zt.key)===wr,data:(0,an.Z)(qe.state.keyEntities,wr).node}),vt=Ri.includes(wr);(0,ne.ZP)(!vt,"Can not drop to dragNode's children node. This is a bug of rc-tree. Please report an issue.");var ei=(0,ft.yx)(fr),co={event:rn,node:(0,St.F)(uo),dragNode:qe.dragNodeProps?(0,St.F)(qe.dragNodeProps):null,dragNodesKeys:[qe.dragNodeProps.eventKey].concat(Ri),dropToGap:oi!==0,dropPosition:oi+Number(ei[ei.length-1])};_n||Di==null||Di(co),qe.dragNodeProps=null}}}),(0,wt.Z)((0,$e.Z)(qe),"cleanDragState",function(){var rn=qe.state.draggingNodeKey;rn!==null&&qe.setState({draggingNodeKey:null,dropPosition:null,dropContainerKey:null,dropTargetKey:null,dropLevelOffset:null,dropAllowed:!0,dragOverNodeKey:null}),qe.dragStartMousePosition=null,qe.currentMouseOverDroppableNodeKey=null}),(0,wt.Z)((0,$e.Z)(qe),"triggerExpandActionExpand",function(rn,Hn){var Zt=qe.state,_n=Zt.expandedKeys,ti=Zt.flattenNodes,Ri=Hn.expanded,oi=Hn.key,wr=Hn.isLeaf;if(!(wr||rn.shiftKey||rn.metaKey||rn.ctrlKey)){var fr=ti.filter(function(Di){return Di.key===oi})[0],Ei=(0,St.F)((0,Ut.Z)((0,Ut.Z)({},(0,St.H8)(oi,qe.getTreeNodeRequiredProps())),{},{data:fr.data}));qe.setExpandedKeys(Ri?(0,ft._5)(_n,oi):(0,ft.L0)(_n,oi)),qe.onNodeExpand(rn,Ei)}}),(0,wt.Z)((0,$e.Z)(qe),"onNodeClick",function(rn,Hn){var Zt=qe.props,_n=Zt.onClick,ti=Zt.expandAction;ti==="click"&&qe.triggerExpandActionExpand(rn,Hn),_n==null||_n(rn,Hn)}),(0,wt.Z)((0,$e.Z)(qe),"onNodeDoubleClick",function(rn,Hn){var Zt=qe.props,_n=Zt.onDoubleClick,ti=Zt.expandAction;ti==="doubleClick"&&qe.triggerExpandActionExpand(rn,Hn),_n==null||_n(rn,Hn)}),(0,wt.Z)((0,$e.Z)(qe),"onNodeSelect",function(rn,Hn){var Zt=qe.state.selectedKeys,_n=qe.state,ti=_n.keyEntities,Ri=_n.fieldNames,oi=qe.props,wr=oi.onSelect,fr=oi.multiple,Ei=Hn.selected,Di=Hn[Ri.key],uo=!Ei;uo?fr?Zt=(0,ft.L0)(Zt,Di):Zt=[Di]:Zt=(0,ft._5)(Zt,Di);var vt=Zt.map(function(ei){var co=(0,an.Z)(ti,ei);return co?co.node:null}).filter(Boolean);qe.setUncontrolledState({selectedKeys:Zt}),wr==null||wr(Zt,{event:"select",selected:uo,node:Hn,selectedNodes:vt,nativeEvent:rn.nativeEvent})}),(0,wt.Z)((0,$e.Z)(qe),"onNodeCheck",function(rn,Hn,Zt){var _n=qe.state,ti=_n.keyEntities,Ri=_n.checkedKeys,oi=_n.halfCheckedKeys,wr=qe.props,fr=wr.checkStrictly,Ei=wr.onCheck,Di=Hn.key,uo,vt={event:"check",node:Hn,checked:Zt,nativeEvent:rn.nativeEvent};if(fr){var ei=Zt?(0,ft.L0)(Ri,Di):(0,ft._5)(Ri,Di),co=(0,ft._5)(oi,Di);uo={checked:ei,halfChecked:co},vt.checkedNodes=ei.map(function(Ra){return(0,an.Z)(ti,Ra)}).filter(Boolean).map(function(Ra){return Ra.node}),qe.setUncontrolledState({checkedKeys:ei})}else{var bo=(0,Gt.S)([].concat((0,$t.Z)(Ri),[Di]),!0,ti),Ui=bo.checkedKeys,yo=bo.halfCheckedKeys;if(!Zt){var ha=new Set(Ui);ha.delete(Di);var Ka=(0,Gt.S)(Array.from(ha),{checked:!1,halfCheckedKeys:yo},ti);Ui=Ka.checkedKeys,yo=Ka.halfCheckedKeys}uo=Ui,vt.checkedNodes=[],vt.checkedNodesPositions=[],vt.halfCheckedKeys=yo,Ui.forEach(function(Ra){var ca=(0,an.Z)(ti,Ra);if(ca){var ma=ca.node,Ho=ca.pos;vt.checkedNodes.push(ma),vt.checkedNodesPositions.push({node:ma,pos:Ho})}}),qe.setUncontrolledState({checkedKeys:Ui},!1,{halfCheckedKeys:yo})}Ei==null||Ei(uo,vt)}),(0,wt.Z)((0,$e.Z)(qe),"onNodeLoad",function(rn){var Hn,Zt=rn.key,_n=qe.state.keyEntities,ti=(0,an.Z)(_n,Zt);if(!(ti!=null&&(Hn=ti.children)!==null&&Hn!==void 0&&Hn.length)){var Ri=new Promise(function(oi,wr){qe.setState(function(fr){var Ei=fr.loadedKeys,Di=Ei===void 0?[]:Ei,uo=fr.loadingKeys,vt=uo===void 0?[]:uo,ei=qe.props,co=ei.loadData,bo=ei.onLoad;if(!co||Di.includes(Zt)||vt.includes(Zt))return null;var Ui=co(rn);return Ui.then(function(){var yo=qe.state.loadedKeys,ha=(0,ft.L0)(yo,Zt);bo==null||bo(ha,{event:"load",node:rn}),qe.setUncontrolledState({loadedKeys:ha}),qe.setState(function(Ka){return{loadingKeys:(0,ft._5)(Ka.loadingKeys,Zt)}}),oi()}).catch(function(yo){if(qe.setState(function(Ka){return{loadingKeys:(0,ft._5)(Ka.loadingKeys,Zt)}}),qe.loadingRetryTimes[Zt]=(qe.loadingRetryTimes[Zt]||0)+1,qe.loadingRetryTimes[Zt]>=Jt){var ha=qe.state.loadedKeys;(0,ne.ZP)(!1,"Retry for `loadData` many times but still failed. No more retry."),qe.setUncontrolledState({loadedKeys:(0,ft.L0)(ha,Zt)}),oi()}wr(yo)}),{loadingKeys:(0,ft.L0)(vt,Zt)}})});return Ri.catch(function(){}),Ri}}),(0,wt.Z)((0,$e.Z)(qe),"onNodeMouseEnter",function(rn,Hn){var Zt=qe.props.onMouseEnter;Zt==null||Zt({event:rn,node:Hn})}),(0,wt.Z)((0,$e.Z)(qe),"onNodeMouseLeave",function(rn,Hn){var Zt=qe.props.onMouseLeave;Zt==null||Zt({event:rn,node:Hn})}),(0,wt.Z)((0,$e.Z)(qe),"onNodeContextMenu",function(rn,Hn){var Zt=qe.props.onRightClick;Zt&&(rn.preventDefault(),Zt({event:rn,node:Hn}))}),(0,wt.Z)((0,$e.Z)(qe),"onFocus",function(){var rn=qe.props.onFocus;qe.setState({focused:!0});for(var Hn=arguments.length,Zt=new Array(Hn),_n=0;_n<Hn;_n++)Zt[_n]=arguments[_n];rn==null||rn.apply(void 0,Zt)}),(0,wt.Z)((0,$e.Z)(qe),"onBlur",function(){var rn=qe.props.onBlur;qe.setState({focused:!1}),qe.onActiveChange(null);for(var Hn=arguments.length,Zt=new Array(Hn),_n=0;_n<Hn;_n++)Zt[_n]=arguments[_n];rn==null||rn.apply(void 0,Zt)}),(0,wt.Z)((0,$e.Z)(qe),"getTreeNodeRequiredProps",function(){var rn=qe.state,Hn=rn.expandedKeys,Zt=rn.selectedKeys,_n=rn.loadedKeys,ti=rn.loadingKeys,Ri=rn.checkedKeys,oi=rn.halfCheckedKeys,wr=rn.dragOverNodeKey,fr=rn.dropPosition,Ei=rn.keyEntities;return{expandedKeys:Hn||[],selectedKeys:Zt||[],loadedKeys:_n||[],loadingKeys:ti||[],checkedKeys:Ri||[],halfCheckedKeys:oi||[],dragOverNodeKey:wr,dropPosition:fr,keyEntities:Ei}}),(0,wt.Z)((0,$e.Z)(qe),"setExpandedKeys",function(rn){var Hn=qe.state,Zt=Hn.treeData,_n=Hn.fieldNames,ti=(0,St.oH)(Zt,rn,_n);qe.setUncontrolledState({expandedKeys:rn,flattenNodes:ti},!0)}),(0,wt.Z)((0,$e.Z)(qe),"onNodeExpand",function(rn,Hn){var Zt=qe.state.expandedKeys,_n=qe.state,ti=_n.listChanging,Ri=_n.fieldNames,oi=qe.props,wr=oi.onExpand,fr=oi.loadData,Ei=Hn.expanded,Di=Hn[Ri.key];if(!ti){var uo=Zt.includes(Di),vt=!Ei;if((0,ne.ZP)(Ei&&uo||!Ei&&!uo,"Expand state not sync with index check"),Zt=vt?(0,ft.L0)(Zt,Di):(0,ft._5)(Zt,Di),qe.setExpandedKeys(Zt),wr==null||wr(Zt,{node:Hn,expanded:vt,nativeEvent:rn.nativeEvent}),vt&&fr){var ei=qe.onNodeLoad(Hn);ei&&ei.then(function(){var co=(0,St.oH)(qe.state.treeData,Zt,Ri);qe.setUncontrolledState({flattenNodes:co})}).catch(function(){var co=qe.state.expandedKeys,bo=(0,ft._5)(co,Di);qe.setExpandedKeys(bo)})}}}),(0,wt.Z)((0,$e.Z)(qe),"onListChangeStart",function(){qe.setUncontrolledState({listChanging:!0})}),(0,wt.Z)((0,$e.Z)(qe),"onListChangeEnd",function(){setTimeout(function(){qe.setUncontrolledState({listChanging:!1})})}),(0,wt.Z)((0,$e.Z)(qe),"onActiveChange",function(rn){var Hn=qe.state.activeKey,Zt=qe.props,_n=Zt.onActiveChange,ti=Zt.itemScrollOffset,Ri=ti===void 0?0:ti;Hn!==rn&&(qe.setState({activeKey:rn}),rn!==null&&qe.scrollTo({key:rn,offset:Ri}),_n==null||_n(rn))}),(0,wt.Z)((0,$e.Z)(qe),"getActiveItem",function(){var rn=qe.state,Hn=rn.activeKey,Zt=rn.flattenNodes;return Hn===null?null:Zt.find(function(_n){var ti=_n.key;return ti===Hn})||null}),(0,wt.Z)((0,$e.Z)(qe),"offsetActiveKey",function(rn){var Hn=qe.state,Zt=Hn.flattenNodes,_n=Hn.activeKey,ti=Zt.findIndex(function(wr){var fr=wr.key;return fr===_n});ti===-1&&rn<0&&(ti=Zt.length),ti=(ti+rn+Zt.length)%Zt.length;var Ri=Zt[ti];if(Ri){var oi=Ri.key;qe.onActiveChange(oi)}else qe.onActiveChange(null)}),(0,wt.Z)((0,$e.Z)(qe),"onKeyDown",function(rn){var Hn=qe.state,Zt=Hn.activeKey,_n=Hn.expandedKeys,ti=Hn.checkedKeys,Ri=Hn.fieldNames,oi=qe.props,wr=oi.onKeyDown,fr=oi.checkable,Ei=oi.selectable;switch(rn.which){case sn.Z.UP:{qe.offsetActiveKey(-1),rn.preventDefault();break}case sn.Z.DOWN:{qe.offsetActiveKey(1),rn.preventDefault();break}}var Di=qe.getActiveItem();if(Di&&Di.data){var uo=qe.getTreeNodeRequiredProps(),vt=Di.data.isLeaf===!1||!!(Di.data[Ri.children]||[]).length,ei=(0,St.F)((0,Ut.Z)((0,Ut.Z)({},(0,St.H8)(Zt,uo)),{},{data:Di.data,active:!0}));switch(rn.which){case sn.Z.LEFT:{vt&&_n.includes(Zt)?qe.onNodeExpand({},ei):Di.parent&&qe.onActiveChange(Di.parent.key),rn.preventDefault();break}case sn.Z.RIGHT:{vt&&!_n.includes(Zt)?qe.onNodeExpand({},ei):Di.children&&Di.children.length&&qe.onActiveChange(Di.children[0].key),rn.preventDefault();break}case sn.Z.ENTER:case sn.Z.SPACE:{fr&&!ei.disabled&&ei.checkable!==!1&&!ei.disableCheckbox?qe.onNodeCheck({},ei,!ti.includes(Zt)):!fr&&Ei&&!ei.disabled&&ei.selectable!==!1&&qe.onNodeSelect({},ei);break}}}wr==null||wr(rn)}),(0,wt.Z)((0,$e.Z)(qe),"setUncontrolledState",function(rn){var Hn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,Zt=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null;if(!qe.destroyed){var _n=!1,ti=!0,Ri={};Object.keys(rn).forEach(function(oi){if(qe.props.hasOwnProperty(oi)){ti=!1;return}_n=!0,Ri[oi]=rn[oi]}),_n&&(!Hn||ti)&&qe.setState((0,Ut.Z)((0,Ut.Z)({},Ri),Zt))}}),(0,wt.Z)((0,$e.Z)(qe),"scrollTo",function(rn){qe.listRef.current.scrollTo(rn)}),qe}return(0,Ie.Z)(Fe,[{key:"componentDidMount",value:function(){this.destroyed=!1,this.onUpdated()}},{key:"componentDidUpdate",value:function(){this.onUpdated()}},{key:"onUpdated",value:function(){var dn=this.props,ui=dn.activeKey,$n=dn.itemScrollOffset,rn=$n===void 0?0:$n;ui!==void 0&&ui!==this.state.activeKey&&(this.setState({activeKey:ui}),ui!==null&&this.scrollTo({key:ui,offset:rn}))}},{key:"componentWillUnmount",value:function(){window.removeEventListener("dragend",this.onWindowDragEnd),this.destroyed=!0}},{key:"resetDragState",value:function(){this.setState({dragOverNodeKey:null,dropPosition:null,dropLevelOffset:null,dropTargetKey:null,dropContainerKey:null,dropTargetPos:null,dropAllowed:!1})}},{key:"render",value:function(){var dn=this.state,ui=dn.focused,$n=dn.flattenNodes,rn=dn.keyEntities,Hn=dn.draggingNodeKey,Zt=dn.activeKey,_n=dn.dropLevelOffset,ti=dn.dropContainerKey,Ri=dn.dropTargetKey,oi=dn.dropPosition,wr=dn.dragOverNodeKey,fr=dn.indent,Ei=this.props,Di=Ei.prefixCls,uo=Ei.className,vt=Ei.style,ei=Ei.showLine,co=Ei.focusable,bo=Ei.tabIndex,Ui=bo===void 0?0:bo,yo=Ei.selectable,ha=Ei.showIcon,Ka=Ei.icon,Ra=Ei.switcherIcon,ca=Ei.draggable,ma=Ei.checkable,Ho=Ei.checkStrictly,_r=Ei.disabled,Fn=Ei.motion,we=Ei.loadData,Qn=Ei.filterTreeNode,bn=Ei.height,on=Ei.itemHeight,ln=Ei.scrollWidth,gn=Ei.virtual,Vn=Ei.titleRender,_i=Ei.dropIndicatorRender,jt=Ei.onContextMenu,zt=Ei.onScroll,Ct=Ei.direction,Yt=Ei.rootClassName,ci=Ei.rootStyle,vi=(0,Re.Z)(this.props,{aria:!0,data:!0}),ai;ca&&((0,dt.Z)(ca)==="object"?ai=ca:typeof ca=="function"?ai={nodeDraggable:ca}:ai={});var Kt={prefixCls:Di,selectable:yo,showIcon:ha,icon:Ka,switcherIcon:Ra,draggable:ai,draggingNodeKey:Hn,checkable:ma,checkStrictly:Ho,disabled:_r,keyEntities:rn,dropLevelOffset:_n,dropContainerKey:ti,dropTargetKey:Ri,dropPosition:oi,dragOverNodeKey:wr,indent:fr,direction:Ct,dropIndicatorRender:_i,loadData:we,filterTreeNode:Qn,titleRender:Vn,onNodeClick:this.onNodeClick,onNodeDoubleClick:this.onNodeDoubleClick,onNodeExpand:this.onNodeExpand,onNodeSelect:this.onNodeSelect,onNodeCheck:this.onNodeCheck,onNodeLoad:this.onNodeLoad,onNodeMouseEnter:this.onNodeMouseEnter,onNodeMouseLeave:this.onNodeMouseLeave,onNodeContextMenu:this.onNodeContextMenu,onNodeDragStart:this.onNodeDragStart,onNodeDragEnter:this.onNodeDragEnter,onNodeDragOver:this.onNodeDragOver,onNodeDragLeave:this.onNodeDragLeave,onNodeDragEnd:this.onNodeDragEnd,onNodeDrop:this.onNodeDrop};return te.createElement(he.k.Provider,{value:Kt},te.createElement("div",{className:It()(Di,uo,Yt,(0,wt.Z)((0,wt.Z)((0,wt.Z)({},"".concat(Di,"-show-line"),ei),"".concat(Di,"-focused"),ui),"".concat(Di,"-active-focused"),Zt!==null)),style:ci},te.createElement(Ot,(0,Ne.Z)({ref:this.listRef,prefixCls:Di,style:vt,data:$n,disabled:_r,selectable:yo,checkable:!!ma,motion:Fn,dragging:Hn!==null,height:bn,itemHeight:on,virtual:gn,focusable:co,focused:ui,tabIndex:Ui,activeItem:this.getActiveItem(),onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:this.onKeyDown,onActiveChange:this.onActiveChange,onListChangeStart:this.onListChangeStart,onListChangeEnd:this.onListChangeEnd,onContextMenu:jt,onScroll:zt,scrollWidth:ln},this.getTreeNodeRequiredProps(),vi))))}}],[{key:"getDerivedStateFromProps",value:function(dn,ui){var $n=ui.prevProps,rn={prevProps:dn};function Hn(Ui){return!$n&&dn.hasOwnProperty(Ui)||$n&&$n[Ui]!==dn[Ui]}var Zt,_n=ui.fieldNames;if(Hn("fieldNames")&&(_n=(0,St.w$)(dn.fieldNames),rn.fieldNames=_n),Hn("treeData")?Zt=dn.treeData:Hn("children")&&((0,ne.ZP)(!1,"`children` of Tree is deprecated. Please use `treeData` instead."),Zt=(0,St.zn)(dn.children)),Zt){rn.treeData=Zt;var ti=(0,St.I8)(Zt,{fieldNames:_n});rn.keyEntities=(0,Ut.Z)((0,wt.Z)({},ze,Wt),ti.keyEntities)}var Ri=rn.keyEntities||ui.keyEntities;if(Hn("expandedKeys")||$n&&Hn("autoExpandParent"))rn.expandedKeys=dn.autoExpandParent||!$n&&dn.defaultExpandParent?(0,ft.r7)(dn.expandedKeys,Ri):dn.expandedKeys;else if(!$n&&dn.defaultExpandAll){var oi=(0,Ut.Z)({},Ri);delete oi[ze];var wr=[];Object.keys(oi).forEach(function(Ui){var yo=oi[Ui];yo.children&&yo.children.length&&wr.push(yo.key)}),rn.expandedKeys=wr}else!$n&&dn.defaultExpandedKeys&&(rn.expandedKeys=dn.autoExpandParent||dn.defaultExpandParent?(0,ft.r7)(dn.defaultExpandedKeys,Ri):dn.defaultExpandedKeys);if(rn.expandedKeys||delete rn.expandedKeys,Zt||rn.expandedKeys){var fr=(0,St.oH)(Zt||ui.treeData,rn.expandedKeys||ui.expandedKeys,_n);rn.flattenNodes=fr}if(dn.selectable&&(Hn("selectedKeys")?rn.selectedKeys=(0,ft.BT)(dn.selectedKeys,dn):!$n&&dn.defaultSelectedKeys&&(rn.selectedKeys=(0,ft.BT)(dn.defaultSelectedKeys,dn))),dn.checkable){var Ei;if(Hn("checkedKeys")?Ei=(0,ft.E6)(dn.checkedKeys)||{}:!$n&&dn.defaultCheckedKeys?Ei=(0,ft.E6)(dn.defaultCheckedKeys)||{}:Zt&&(Ei=(0,ft.E6)(dn.checkedKeys)||{checkedKeys:ui.checkedKeys,halfCheckedKeys:ui.halfCheckedKeys}),Ei){var Di=Ei,uo=Di.checkedKeys,vt=uo===void 0?[]:uo,ei=Di.halfCheckedKeys,co=ei===void 0?[]:ei;if(!dn.checkStrictly){var bo=(0,Gt.S)(vt,!0,Ri);vt=bo.checkedKeys,co=bo.halfCheckedKeys}rn.checkedKeys=vt,rn.halfCheckedKeys=co}}return Hn("loadedKeys")&&(rn.loadedKeys=dn.loadedKeys),rn}}]),Fe}(te.Component);(0,wt.Z)(Ve,"defaultProps",{prefixCls:"rc-tree",showLine:!1,showIcon:!0,selectable:!0,multiple:!1,checkable:!1,disabled:!1,checkStrictly:!1,draggable:!1,defaultExpandParent:!0,autoExpandParent:!1,defaultExpandAll:!1,defaultExpandedKeys:[],defaultCheckedKeys:[],defaultSelectedKeys:[],dropIndicatorRender:pe,allowDrop:function(){return!0},expandAction:!1}),(0,wt.Z)(Ve,"TreeNode",st.Z);var be=Ve,Pe=be},10225:function(jn,li,De){"use strict";De.d(li,{BT:function(){return te},E6:function(){return pe},L0:function(){return wt},OM:function(){return ne},_5:function(){return Pt},r7:function(){return me},wA:function(){return It},yx:function(){return Qt}});var Ne=De(74902),dt=De(71002),Ut=De(80334),$t=De(67294),kt=De(86128),Ie=De(35381),$e=De(1089),Mt=null;function Pt(xe,Ee){if(!xe)return[];var Ge=xe.slice(),et=Ge.indexOf(Ee);return et>=0&&Ge.splice(et,1),Ge}function wt(xe,Ee){var Ge=(xe||[]).slice();return Ge.indexOf(Ee)===-1&&Ge.push(Ee),Ge}function Qt(xe){return xe.split("-")}function It(xe,Ee){var Ge=[],et=(0,Ie.Z)(Ee,xe);function ut(){var st=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];st.forEach(function(it){var Nt=it.key,St=it.children;Ge.push(Nt),ut(St)})}return ut(et.children),Ge}function sn(xe){if(xe.parent){var Ee=Qt(xe.pos);return Number(Ee[Ee.length-1])===xe.parent.children.length-1}return!1}function Re(xe){var Ee=Qt(xe.pos);return Number(Ee[Ee.length-1])===0}function ne(xe,Ee,Ge,et,ut,st,it,Nt,St,Ft){var cn,Tt=xe.clientX,hi=xe.clientY,di=xe.target.getBoundingClientRect(),zn=di.top,Dn=di.height,nt=(Ft==="rtl"?-1:1)*(((ut==null?void 0:ut.x)||0)-Tt),ze=(nt-12)/et,ke=St.filter(function(Pe){var Be;return(Be=Nt[Pe])===null||Be===void 0||(Be=Be.children)===null||Be===void 0?void 0:Be.length}),Wt=(0,Ie.Z)(Nt,Ge.eventKey);if(hi<zn+Dn/2){var On=it.findIndex(function(Pe){return Pe.key===Wt.key}),Lt=On<=0?0:On-1,xn=it[Lt].key;Wt=(0,Ie.Z)(Nt,xn)}var vn=Wt.key,Xn=Wt,Ot=Wt.key,ft=0,Gt=0;if(!ke.includes(vn))for(var an=0;an<ze&&sn(Wt);an+=1)Wt=Wt.parent,Gt+=1;var Jt=Ee.data,Ve=Wt.node,be=!0;return Re(Wt)&&Wt.level===0&&hi<zn+Dn/2&&st({dragNode:Jt,dropNode:Ve,dropPosition:-1})&&Wt.key===Ge.eventKey?ft=-1:(Xn.children||[]).length&&ke.includes(Ot)?st({dragNode:Jt,dropNode:Ve,dropPosition:0})?ft=0:be=!1:Gt===0?ze>-1.5?st({dragNode:Jt,dropNode:Ve,dropPosition:1})?ft=1:be=!1:st({dragNode:Jt,dropNode:Ve,dropPosition:0})?ft=0:st({dragNode:Jt,dropNode:Ve,dropPosition:1})?ft=1:be=!1:st({dragNode:Jt,dropNode:Ve,dropPosition:1})?ft=1:be=!1,{dropPosition:ft,dropLevelOffset:Gt,dropTargetKey:Wt.key,dropTargetPos:Wt.pos,dragOverNodeKey:Ot,dropContainerKey:ft===0?null:((cn=Wt.parent)===null||cn===void 0?void 0:cn.key)||null,dropAllowed:be}}function te(xe,Ee){if(xe){var Ge=Ee.multiple;return Ge?xe.slice():xe.length?[xe[0]]:xe}}var he=function(Ee){return Ee};function le(xe,Ee){if(!xe)return[];var Ge=Ee||{},et=Ge.processProps,ut=et===void 0?he:et,st=Array.isArray(xe)?xe:[xe];return st.map(function(it){var Nt=it.children,St=_objectWithoutProperties(it,Mt),Ft=le(Nt,Ee);return React.createElement(TreeNode,_extends({key:St.key},ut(St)),Ft)})}function pe(xe){if(!xe)return null;var Ee;if(Array.isArray(xe))Ee={checkedKeys:xe,halfCheckedKeys:void 0};else if((0,dt.Z)(xe)==="object")Ee={checkedKeys:xe.checked||void 0,halfCheckedKeys:xe.halfChecked||void 0};else return(0,Ut.ZP)(!1,"`checkedKeys` is not an array or an object"),null;return Ee}function me(xe,Ee){var Ge=new Set;function et(ut){if(!Ge.has(ut)){var st=(0,Ie.Z)(Ee,ut);if(st){Ge.add(ut);var it=st.parent,Nt=st.node;Nt.disabled||it&&et(it.key)}}}return(xe||[]).forEach(function(ut){et(ut)}),(0,Ne.Z)(Ge)}},17341:function(jn,li,De){"use strict";De.d(li,{S:function(){return $e}});var Ne=De(80334),dt=De(35381);function Ut(Mt,Pt){var wt=new Set;return Mt.forEach(function(Qt){Pt.has(Qt)||wt.add(Qt)}),wt}function $t(Mt){var Pt=Mt||{},wt=Pt.disabled,Qt=Pt.disableCheckbox,It=Pt.checkable;return!!(wt||Qt)||It===!1}function kt(Mt,Pt,wt,Qt){for(var It=new Set(Mt),sn=new Set,Re=0;Re<=wt;Re+=1){var ne=Pt.get(Re)||new Set;ne.forEach(function(pe){var me=pe.key,xe=pe.node,Ee=pe.children,Ge=Ee===void 0?[]:Ee;It.has(me)&&!Qt(xe)&&Ge.filter(function(et){return!Qt(et.node)}).forEach(function(et){It.add(et.key)})})}for(var te=new Set,he=wt;he>=0;he-=1){var le=Pt.get(he)||new Set;le.forEach(function(pe){var me=pe.parent,xe=pe.node;if(!(Qt(xe)||!pe.parent||te.has(pe.parent.key))){if(Qt(pe.parent.node)){te.add(me.key);return}var Ee=!0,Ge=!1;(me.children||[]).filter(function(et){return!Qt(et.node)}).forEach(function(et){var ut=et.key,st=It.has(ut);Ee&&!st&&(Ee=!1),!Ge&&(st||sn.has(ut))&&(Ge=!0)}),Ee&&It.add(me.key),Ge&&sn.add(me.key),te.add(me.key)}})}return{checkedKeys:Array.from(It),halfCheckedKeys:Array.from(Ut(sn,It))}}function Ie(Mt,Pt,wt,Qt,It){for(var sn=new Set(Mt),Re=new Set(Pt),ne=0;ne<=Qt;ne+=1){var te=wt.get(ne)||new Set;te.forEach(function(me){var xe=me.key,Ee=me.node,Ge=me.children,et=Ge===void 0?[]:Ge;!sn.has(xe)&&!Re.has(xe)&&!It(Ee)&&et.filter(function(ut){return!It(ut.node)}).forEach(function(ut){sn.delete(ut.key)})})}Re=new Set;for(var he=new Set,le=Qt;le>=0;le-=1){var pe=wt.get(le)||new Set;pe.forEach(function(me){var xe=me.parent,Ee=me.node;if(!(It(Ee)||!me.parent||he.has(me.parent.key))){if(It(me.parent.node)){he.add(xe.key);return}var Ge=!0,et=!1;(xe.children||[]).filter(function(ut){return!It(ut.node)}).forEach(function(ut){var st=ut.key,it=sn.has(st);Ge&&!it&&(Ge=!1),!et&&(it||Re.has(st))&&(et=!0)}),Ge||sn.delete(xe.key),et&&Re.add(xe.key),he.add(xe.key)}})}return{checkedKeys:Array.from(sn),halfCheckedKeys:Array.from(Ut(Re,sn))}}function $e(Mt,Pt,wt,Qt){var It=[],sn;Qt?sn=Qt:sn=$t;var Re=new Set(Mt.filter(function(le){var pe=!!(0,dt.Z)(wt,le);return pe||It.push(le),pe})),ne=new Map,te=0;Object.keys(wt).forEach(function(le){var pe=wt[le],me=pe.level,xe=ne.get(me);xe||(xe=new Set,ne.set(me,xe)),xe.add(pe),te=Math.max(te,me)}),(0,Ne.ZP)(!It.length,"Tree missing follow keys: ".concat(It.slice(0,100).map(function(le){return"'".concat(le,"'")}).join(", ")));var he;return Pt===!0?he=kt(Re,ne,te,sn):he=Ie(Re,Pt.halfCheckedKeys,ne,te,sn),he}},35381:function(jn,li,De){"use strict";De.d(li,{Z:function(){return Ne}});function Ne(dt,Ut){return dt[Ut]}},1089:function(jn,li,De){"use strict";De.d(li,{F:function(){return me},H8:function(){return pe},I8:function(){return le},km:function(){return It},oH:function(){return te},w$:function(){return sn},zn:function(){return ne}});var Ne=De(71002),dt=De(74902),Ut=De(1413),$t=De(45987),kt=De(50344),Ie=De(98423),$e=De(80334),Mt=De(35381),Pt=["children"];function wt(xe,Ee){return"".concat(xe,"-").concat(Ee)}function Qt(xe){return xe&&xe.type&&xe.type.isTreeNode}function It(xe,Ee){return xe!=null?xe:Ee}function sn(xe){var Ee=xe||{},Ge=Ee.title,et=Ee._title,ut=Ee.key,st=Ee.children,it=Ge||"title";return{title:it,_title:et||[it],key:ut||"key",children:st||"children"}}function Re(xe,Ee){var Ge=new Map;function et(ut){var st=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";(ut||[]).forEach(function(it){var Nt=it[Ee.key],St=it[Ee.children];warning(Nt!=null,"Tree node must have a certain key: [".concat(st).concat(Nt,"]"));var Ft=String(Nt);warning(!Ge.has(Ft)||Nt===null||Nt===void 0,"Same 'key' exist in the Tree: ".concat(Ft)),Ge.set(Ft,!0),et(St,"".concat(st).concat(Ft," > "))})}et(xe)}function ne(xe){function Ee(Ge){var et=(0,kt.Z)(Ge);return et.map(function(ut){if(!Qt(ut))return(0,$e.ZP)(!ut,"Tree/TreeNode can only accept TreeNode as children."),null;var st=ut.key,it=ut.props,Nt=it.children,St=(0,$t.Z)(it,Pt),Ft=(0,Ut.Z)({key:st},St),cn=Ee(Nt);return cn.length&&(Ft.children=cn),Ft}).filter(function(ut){return ut})}return Ee(xe)}function te(xe,Ee,Ge){var et=sn(Ge),ut=et._title,st=et.key,it=et.children,Nt=new Set(Ee===!0?[]:Ee),St=[];function Ft(cn){var Tt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;return cn.map(function(hi,di){for(var zn=wt(Tt?Tt.pos:"0",di),Dn=It(hi[st],zn),nt,ze=0;ze<ut.length;ze+=1){var ke=ut[ze];if(hi[ke]!==void 0){nt=hi[ke];break}}var Wt=Object.assign((0,Ie.Z)(hi,[].concat((0,dt.Z)(ut),[st,it])),{title:nt,key:Dn,parent:Tt,pos:zn,children:null,data:hi,isStart:[].concat((0,dt.Z)(Tt?Tt.isStart:[]),[di===0]),isEnd:[].concat((0,dt.Z)(Tt?Tt.isEnd:[]),[di===cn.length-1])});return St.push(Wt),Ee===!0||Nt.has(Dn)?Wt.children=Ft(hi[it]||[],Wt):Wt.children=[],Wt})}return Ft(xe),St}function he(xe,Ee,Ge){var et={};(0,Ne.Z)(Ge)==="object"?et=Ge:et={externalGetKey:Ge},et=et||{};var ut=et,st=ut.childrenPropName,it=ut.externalGetKey,Nt=ut.fieldNames,St=sn(Nt),Ft=St.key,cn=St.children,Tt=st||cn,hi;it?typeof it=="string"?hi=function(Dn){return Dn[it]}:typeof it=="function"&&(hi=function(Dn){return it(Dn)}):hi=function(Dn,nt){return It(Dn[Ft],nt)};function di(zn,Dn,nt,ze){var ke=zn?zn[Tt]:xe,Wt=zn?wt(nt.pos,Dn):"0",On=zn?[].concat((0,dt.Z)(ze),[zn]):[];if(zn){var Lt=hi(zn,Wt),xn={node:zn,index:Dn,pos:Wt,key:Lt,parentPos:nt.node?nt.pos:null,level:nt.level+1,nodes:On};Ee(xn)}ke&&ke.forEach(function(vn,Xn){di(vn,Xn,{node:zn,pos:Wt,level:nt?nt.level+1:-1},On)})}di(null)}function le(xe){var Ee=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Ge=Ee.initWrapper,et=Ee.processEntity,ut=Ee.onProcessFinished,st=Ee.externalGetKey,it=Ee.childrenPropName,Nt=Ee.fieldNames,St=arguments.length>2?arguments[2]:void 0,Ft=st||St,cn={},Tt={},hi={posEntities:cn,keyEntities:Tt};return Ge&&(hi=Ge(hi)||hi),he(xe,function(di){var zn=di.node,Dn=di.index,nt=di.pos,ze=di.key,ke=di.parentPos,Wt=di.level,On=di.nodes,Lt={node:zn,nodes:On,index:Dn,key:ze,pos:nt,level:Wt},xn=It(ze,nt);cn[nt]=Lt,Tt[xn]=Lt,Lt.parent=cn[ke],Lt.parent&&(Lt.parent.children=Lt.parent.children||[],Lt.parent.children.push(Lt)),et&&et(Lt,hi)},{externalGetKey:Ft,childrenPropName:it,fieldNames:Nt}),ut&&ut(hi),hi}function pe(xe,Ee){var Ge=Ee.expandedKeys,et=Ee.selectedKeys,ut=Ee.loadedKeys,st=Ee.loadingKeys,it=Ee.checkedKeys,Nt=Ee.halfCheckedKeys,St=Ee.dragOverNodeKey,Ft=Ee.dropPosition,cn=Ee.keyEntities,Tt=(0,Mt.Z)(cn,xe),hi={eventKey:xe,expanded:Ge.indexOf(xe)!==-1,selected:et.indexOf(xe)!==-1,loaded:ut.indexOf(xe)!==-1,loading:st.indexOf(xe)!==-1,checked:it.indexOf(xe)!==-1,halfChecked:Nt.indexOf(xe)!==-1,pos:String(Tt?Tt.pos:""),dragOver:St===xe&&Ft===0,dragOverGapTop:St===xe&&Ft===-1,dragOverGapBottom:St===xe&&Ft===1};return hi}function me(xe){var Ee=xe.data,Ge=xe.expanded,et=xe.selected,ut=xe.checked,st=xe.loaded,it=xe.loading,Nt=xe.halfChecked,St=xe.dragOver,Ft=xe.dragOverGapTop,cn=xe.dragOverGapBottom,Tt=xe.pos,hi=xe.active,di=xe.eventKey,zn=(0,Ut.Z)((0,Ut.Z)({},Ee),{},{expanded:Ge,selected:et,checked:ut,loaded:st,loading:it,halfChecked:Nt,dragOver:St,dragOverGapTop:Ft,dragOverGapBottom:cn,pos:Tt,active:hi,key:di});return"props"in zn||Object.defineProperty(zn,"props",{get:function(){return(0,$e.ZP)(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),xe}}),zn}},36356:function(jn,li,De){"use strict";De.d(li,{Z:function(){return di}});var Ne=De(87462),dt=De(15671),Ut=De(43144),$t=De(97326),kt=De(60136),Ie=De(29388),$e=De(4942),Mt=De(67294),Pt=De(1413),wt=De(45987),Qt=De(71002),It=De(74165),sn=De(15861),Re=De(74902),ne=De(94184),te=De.n(ne),he=De(64217),le=De(80334),pe=function(zn,Dn){if(zn&&Dn){var nt=Array.isArray(Dn)?Dn:Dn.split(","),ze=zn.name||"",ke=zn.type||"",Wt=ke.replace(/\/.*$/,"");return nt.some(function(On){var Lt=On.trim();if(/^\*(\/\*)?$/.test(On))return!0;if(Lt.charAt(0)==="."){var xn=ze.toLowerCase(),vn=Lt.toLowerCase(),Xn=[vn];return(vn===".jpg"||vn===".jpeg")&&(Xn=[".jpg",".jpeg"]),Xn.some(function(Ot){return xn.endsWith(Ot)})}return/\/\*$/.test(Lt)?Wt===Lt.replace(/\/.*$/,""):ke===Lt?!0:/^\w+$/.test(Lt)?((0,le.ZP)(!1,"Upload takes an invalidate 'accept' type '".concat(Lt,"'.Skip for check.")),!0):!1})}return!0};function me(zn,Dn){var nt="cannot ".concat(zn.method," ").concat(zn.action," ").concat(Dn.status,"'"),ze=new Error(nt);return ze.status=Dn.status,ze.method=zn.method,ze.url=zn.action,ze}function xe(zn){var Dn=zn.responseText||zn.response;if(!Dn)return Dn;try{return JSON.parse(Dn)}catch(nt){return Dn}}function Ee(zn){var Dn=new XMLHttpRequest;zn.onProgress&&Dn.upload&&(Dn.upload.onprogress=function(Wt){Wt.total>0&&(Wt.percent=Wt.loaded/Wt.total*100),zn.onProgress(Wt)});var nt=new FormData;zn.data&&Object.keys(zn.data).forEach(function(ke){var Wt=zn.data[ke];if(Array.isArray(Wt)){Wt.forEach(function(On){nt.append("".concat(ke,"[]"),On)});return}nt.append(ke,Wt)}),zn.file instanceof Blob?nt.append(zn.filename,zn.file,zn.file.name):nt.append(zn.filename,zn.file),Dn.onerror=function(Wt){zn.onError(Wt)},Dn.onload=function(){return Dn.status<200||Dn.status>=300?zn.onError(me(zn,Dn),xe(Dn)):zn.onSuccess(xe(Dn),Dn)},Dn.open(zn.method,zn.action,!0),zn.withCredentials&&"withCredentials"in Dn&&(Dn.withCredentials=!0);var ze=zn.headers||{};return ze["X-Requested-With"]!==null&&Dn.setRequestHeader("X-Requested-With","XMLHttpRequest"),Object.keys(ze).forEach(function(ke){ze[ke]!==null&&Dn.setRequestHeader(ke,ze[ke])}),Dn.send(nt),{abort:function(){Dn.abort()}}}var Ge=function(){var zn=(0,sn.Z)((0,It.Z)().mark(function Dn(nt,ze){var ke,Wt,On,Lt,xn,vn,Xn,Ot;return(0,It.Z)().wrap(function(Gt){for(;;)switch(Gt.prev=Gt.next){case 0:vn=function(){return vn=(0,sn.Z)((0,It.Z)().mark(function Jt(Ve){return(0,It.Z)().wrap(function(Pe){for(;;)switch(Pe.prev=Pe.next){case 0:return Pe.abrupt("return",new Promise(function(Be){Ve.file(function(Ze){ze(Ze)?(Ve.fullPath&&!Ze.webkitRelativePath&&(Object.defineProperties(Ze,{webkitRelativePath:{writable:!0}}),Ze.webkitRelativePath=Ve.fullPath.replace(/^\//,""),Object.defineProperties(Ze,{webkitRelativePath:{writable:!1}})),Be(Ze)):Be(null)})}));case 1:case"end":return Pe.stop()}},Jt)})),vn.apply(this,arguments)},xn=function(Jt){return vn.apply(this,arguments)},Lt=function(){return Lt=(0,sn.Z)((0,It.Z)().mark(function Jt(Ve){var be,Pe,Be,Ze,Fe;return(0,It.Z)().wrap(function(dn){for(;;)switch(dn.prev=dn.next){case 0:be=Ve.createReader(),Pe=[];case 2:return dn.next=5,new Promise(function(ui){be.readEntries(ui,function(){return ui([])})});case 5:if(Be=dn.sent,Ze=Be.length,Ze){dn.next=9;break}return dn.abrupt("break",12);case 9:for(Fe=0;Fe<Ze;Fe++)Pe.push(Be[Fe]);dn.next=2;break;case 12:return dn.abrupt("return",Pe);case 13:case"end":return dn.stop()}},Jt)})),Lt.apply(this,arguments)},On=function(Jt){return Lt.apply(this,arguments)},ke=[],Wt=[],nt.forEach(function(an){return Wt.push(an.webkitGetAsEntry())}),Xn=function(){var an=(0,sn.Z)((0,It.Z)().mark(function Jt(Ve,be){var Pe,Be;return(0,It.Z)().wrap(function(Fe){for(;;)switch(Fe.prev=Fe.next){case 0:if(Ve){Fe.next=2;break}return Fe.abrupt("return");case 2:if(Ve.path=be||"",!Ve.isFile){Fe.next=10;break}return Fe.next=6,xn(Ve);case 6:Pe=Fe.sent,Pe&&ke.push(Pe),Fe.next=15;break;case 10:if(!Ve.isDirectory){Fe.next=15;break}return Fe.next=13,On(Ve);case 13:Be=Fe.sent,Wt.push.apply(Wt,(0,Re.Z)(Be));case 15:case"end":return Fe.stop()}},Jt)}));return function(Ve,be){return an.apply(this,arguments)}}(),Ot=0;case 9:if(!(Ot<Wt.length)){Gt.next=15;break}return Gt.next=12,Xn(Wt[Ot]);case 12:Ot++,Gt.next=9;break;case 15:return Gt.abrupt("return",ke);case 16:case"end":return Gt.stop()}},Dn)}));return function(nt,ze){return zn.apply(this,arguments)}}(),et=Ge,ut=+new Date,st=0;function it(){return"rc-upload-".concat(ut,"-").concat(++st)}var Nt=["component","prefixCls","className","classNames","disabled","id","name","style","styles","multiple","accept","capture","children","directory","openFileDialogOnClick","onMouseEnter","onMouseLeave","hasControlInside"],St=function(zn){(0,kt.Z)(nt,zn);var Dn=(0,Ie.Z)(nt);function nt(){var ze;(0,dt.Z)(this,nt);for(var ke=arguments.length,Wt=new Array(ke),On=0;On<ke;On++)Wt[On]=arguments[On];return ze=Dn.call.apply(Dn,[this].concat(Wt)),(0,$e.Z)((0,$t.Z)(ze),"state",{uid:it()}),(0,$e.Z)((0,$t.Z)(ze),"reqs",{}),(0,$e.Z)((0,$t.Z)(ze),"fileInput",void 0),(0,$e.Z)((0,$t.Z)(ze),"_isMounted",void 0),(0,$e.Z)((0,$t.Z)(ze),"onChange",function(Lt){var xn=ze.props,vn=xn.accept,Xn=xn.directory,Ot=Lt.target.files,ft=(0,Re.Z)(Ot).filter(function(Gt){return!Xn||pe(Gt,vn)});ze.uploadFiles(ft),ze.reset()}),(0,$e.Z)((0,$t.Z)(ze),"onClick",function(Lt){var xn=ze.fileInput;if(xn){var vn=Lt.target,Xn=ze.props.onClick;if(vn&&vn.tagName==="BUTTON"){var Ot=xn.parentNode;Ot.focus(),vn.blur()}xn.click(),Xn&&Xn(Lt)}}),(0,$e.Z)((0,$t.Z)(ze),"onKeyDown",function(Lt){Lt.key==="Enter"&&ze.onClick(Lt)}),(0,$e.Z)((0,$t.Z)(ze),"onFileDrop",function(){var Lt=(0,sn.Z)((0,It.Z)().mark(function xn(vn){var Xn,Ot,ft;return(0,It.Z)().wrap(function(an){for(;;)switch(an.prev=an.next){case 0:if(Xn=ze.props.multiple,vn.preventDefault(),vn.type!=="dragover"){an.next=4;break}return an.abrupt("return");case 4:if(!ze.props.directory){an.next=11;break}return an.next=7,et(Array.prototype.slice.call(vn.dataTransfer.items),function(Jt){return pe(Jt,ze.props.accept)});case 7:Ot=an.sent,ze.uploadFiles(Ot),an.next=14;break;case 11:ft=(0,Re.Z)(vn.dataTransfer.files).filter(function(Jt){return pe(Jt,ze.props.accept)}),Xn===!1&&(ft=ft.slice(0,1)),ze.uploadFiles(ft);case 14:case"end":return an.stop()}},xn)}));return function(xn){return Lt.apply(this,arguments)}}()),(0,$e.Z)((0,$t.Z)(ze),"uploadFiles",function(Lt){var xn=(0,Re.Z)(Lt),vn=xn.map(function(Xn){return Xn.uid=it(),ze.processFile(Xn,xn)});Promise.all(vn).then(function(Xn){var Ot=ze.props.onBatchStart;Ot==null||Ot(Xn.map(function(ft){var Gt=ft.origin,an=ft.parsedFile;return{file:Gt,parsedFile:an}})),Xn.filter(function(ft){return ft.parsedFile!==null}).forEach(function(ft){ze.post(ft)})})}),(0,$e.Z)((0,$t.Z)(ze),"processFile",function(){var Lt=(0,sn.Z)((0,It.Z)().mark(function xn(vn,Xn){var Ot,ft,Gt,an,Jt,Ve,be,Pe,Be;return(0,It.Z)().wrap(function(Fe){for(;;)switch(Fe.prev=Fe.next){case 0:if(Ot=ze.props.beforeUpload,ft=vn,!Ot){Fe.next=14;break}return Fe.prev=3,Fe.next=6,Ot(vn,Xn);case 6:ft=Fe.sent,Fe.next=12;break;case 9:Fe.prev=9,Fe.t0=Fe.catch(3),ft=!1;case 12:if(ft!==!1){Fe.next=14;break}return Fe.abrupt("return",{origin:vn,parsedFile:null,action:null,data:null});case 14:if(Gt=ze.props.action,typeof Gt!="function"){Fe.next=21;break}return Fe.next=18,Gt(vn);case 18:an=Fe.sent,Fe.next=22;break;case 21:an=Gt;case 22:if(Jt=ze.props.data,typeof Jt!="function"){Fe.next=29;break}return Fe.next=26,Jt(vn);case 26:Ve=Fe.sent,Fe.next=30;break;case 29:Ve=Jt;case 30:return be=((0,Qt.Z)(ft)==="object"||typeof ft=="string")&&ft?ft:vn,be instanceof File?Pe=be:Pe=new File([be],vn.name,{type:vn.type}),Be=Pe,Be.uid=vn.uid,Fe.abrupt("return",{origin:vn,data:Ve,parsedFile:Be,action:an});case 35:case"end":return Fe.stop()}},xn,null,[[3,9]])}));return function(xn,vn){return Lt.apply(this,arguments)}}()),(0,$e.Z)((0,$t.Z)(ze),"saveFileInput",function(Lt){ze.fileInput=Lt}),ze}return(0,Ut.Z)(nt,[{key:"componentDidMount",value:function(){this._isMounted=!0}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,this.abort()}},{key:"post",value:function(ke){var Wt=this,On=ke.data,Lt=ke.origin,xn=ke.action,vn=ke.parsedFile;if(this._isMounted){var Xn=this.props,Ot=Xn.onStart,ft=Xn.customRequest,Gt=Xn.name,an=Xn.headers,Jt=Xn.withCredentials,Ve=Xn.method,be=Lt.uid,Pe=ft||Ee,Be={action:xn,filename:Gt,data:On,file:vn,headers:an,withCredentials:Jt,method:Ve||"post",onProgress:function(Fe){var qe=Wt.props.onProgress;qe==null||qe(Fe,vn)},onSuccess:function(Fe,qe){var dn=Wt.props.onSuccess;dn==null||dn(Fe,vn,qe),delete Wt.reqs[be]},onError:function(Fe,qe){var dn=Wt.props.onError;dn==null||dn(Fe,qe,vn),delete Wt.reqs[be]}};Ot(Lt),this.reqs[be]=Pe(Be)}}},{key:"reset",value:function(){this.setState({uid:it()})}},{key:"abort",value:function(ke){var Wt=this.reqs;if(ke){var On=ke.uid?ke.uid:ke;Wt[On]&&Wt[On].abort&&Wt[On].abort(),delete Wt[On]}else Object.keys(Wt).forEach(function(Lt){Wt[Lt]&&Wt[Lt].abort&&Wt[Lt].abort(),delete Wt[Lt]})}},{key:"render",value:function(){var ke=this.props,Wt=ke.component,On=ke.prefixCls,Lt=ke.className,xn=ke.classNames,vn=xn===void 0?{}:xn,Xn=ke.disabled,Ot=ke.id,ft=ke.name,Gt=ke.style,an=ke.styles,Jt=an===void 0?{}:an,Ve=ke.multiple,be=ke.accept,Pe=ke.capture,Be=ke.children,Ze=ke.directory,Fe=ke.openFileDialogOnClick,qe=ke.onMouseEnter,dn=ke.onMouseLeave,ui=ke.hasControlInside,$n=(0,wt.Z)(ke,Nt),rn=te()((0,$e.Z)((0,$e.Z)((0,$e.Z)({},On,!0),"".concat(On,"-disabled"),Xn),Lt,Lt)),Hn=Ze?{directory:"directory",webkitdirectory:"webkitdirectory"}:{},Zt=Xn?{}:{onClick:Fe?this.onClick:function(){},onKeyDown:Fe?this.onKeyDown:function(){},onMouseEnter:qe,onMouseLeave:dn,onDrop:this.onFileDrop,onDragOver:this.onFileDrop,tabIndex:ui?void 0:"0"};return Mt.createElement(Wt,(0,Ne.Z)({},Zt,{className:rn,role:ui?void 0:"button",style:Gt}),Mt.createElement("input",(0,Ne.Z)({},(0,he.Z)($n,{aria:!0,data:!0}),{id:Ot,name:ft,disabled:Xn,type:"file",ref:this.saveFileInput,onClick:function(ti){return ti.stopPropagation()},key:this.state.uid,style:(0,Pt.Z)({display:"none"},Jt.input),className:vn.input,accept:be},Hn,{multiple:Ve,onChange:this.onChange},Pe!=null?{capture:Pe}:{})),Be)}}]),nt}(Mt.Component),Ft=St;function cn(){}var Tt=function(zn){(0,kt.Z)(nt,zn);var Dn=(0,Ie.Z)(nt);function nt(){var ze;(0,dt.Z)(this,nt);for(var ke=arguments.length,Wt=new Array(ke),On=0;On<ke;On++)Wt[On]=arguments[On];return ze=Dn.call.apply(Dn,[this].concat(Wt)),(0,$e.Z)((0,$t.Z)(ze),"uploader",void 0),(0,$e.Z)((0,$t.Z)(ze),"saveUploader",function(Lt){ze.uploader=Lt}),ze}return(0,Ut.Z)(nt,[{key:"abort",value:function(ke){this.uploader.abort(ke)}},{key:"render",value:function(){return Mt.createElement(Ft,(0,Ne.Z)({},this.props,{ref:this.saveUploader}))}}]),nt}(Mt.Component);(0,$e.Z)(Tt,"defaultProps",{component:"span",prefixCls:"rc-upload",data:{},headers:{},name:"file",multipart:!1,onStart:cn,onError:cn,onSuccess:cn,multiple:!1,beforeUpload:null,customRequest:null,withCredentials:!1,openFileDialogOnClick:!0,hasControlInside:!1});var hi=Tt,di=hi},73299:function(jn,li,De){"use strict";De.d(li,{Z:function(){return _r}});var Ne=De(87462),dt=De(1413),Ut=De(71002),$t=De(97685),kt=De(4942),Ie=De(45987),$e=De(67294),Mt=De(73935),Pt=De(94184),wt=De.n(Pt),Qt=De(48555),It=$e.forwardRef(function(Fn,we){var Qn=Fn.height,bn=Fn.offsetY,on=Fn.offsetX,ln=Fn.children,gn=Fn.prefixCls,Vn=Fn.onInnerResize,_i=Fn.innerProps,jt=Fn.rtl,zt=Fn.extra,Ct={},Yt={display:"flex",flexDirection:"column"};if(bn!==void 0){var ci;Ct={height:Qn,position:"relative",overflow:"hidden"},Yt=(0,dt.Z)((0,dt.Z)({},Yt),{},(ci={transform:"translateY(".concat(bn,"px)")},(0,kt.Z)(ci,jt?"marginRight":"marginLeft",-on),(0,kt.Z)(ci,"position","absolute"),(0,kt.Z)(ci,"left",0),(0,kt.Z)(ci,"right",0),(0,kt.Z)(ci,"top",0),ci))}return $e.createElement("div",{style:Ct},$e.createElement(Qt.Z,{onResize:function(ai){var Kt=ai.offsetHeight;Kt&&Vn&&Vn()}},$e.createElement("div",(0,Ne.Z)({style:Yt,className:wt()((0,kt.Z)({},"".concat(gn,"-holder-inner"),gn)),ref:we},_i),ln,zt)))});It.displayName="Filler";var sn=It,Re=function(we){return+setTimeout(we,16)},ne=function(we){return clearTimeout(we)};typeof window!="undefined"&&"requestAnimationFrame"in window&&(Re=function(we){return window.requestAnimationFrame(we)},ne=function(we){return window.cancelAnimationFrame(we)});var te=0,he=new Map;function le(Fn){he.delete(Fn)}var pe=function(we){var Qn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;te+=1;var bn=te;function on(ln){if(ln===0)le(bn),we();else{var gn=Re(function(){on(ln-1)});he.set(bn,gn)}}return on(Qn),bn};pe.cancel=function(Fn){var we=he.get(Fn);return le(we),ne(we)};var me=pe;function xe(Fn,we){var Qn="touches"in Fn?Fn.touches[0]:Fn;return Qn[we?"pageX":"pageY"]}var Ee=$e.forwardRef(function(Fn,we){var Qn,bn=Fn.prefixCls,on=Fn.rtl,ln=Fn.scrollOffset,gn=Fn.scrollRange,Vn=Fn.onStartMove,_i=Fn.onStopMove,jt=Fn.onScroll,zt=Fn.horizontal,Ct=Fn.spinSize,Yt=Fn.containerSize,ci=Fn.style,vi=Fn.thumbStyle,ai=$e.useState(!1),Kt=(0,$t.Z)(ai,2),wn=Kt[0],pi=Kt[1],ji=$e.useState(null),Rn=(0,$t.Z)(ji,2),Dt=Rn[0],wi=Rn[1],gr=$e.useState(null),eo=(0,$t.Z)(gr,2),kn=eo[0],Xi=eo[1],Lo=!on,La=$e.useRef(),$o=$e.useRef(),qi=$e.useState(!1),Zi=(0,$t.Z)(qi,2),cr=Zi[0],Co=Zi[1],Zo=$e.useRef(),ri=function(){clearTimeout(Zo.current),Co(!0),Zo.current=setTimeout(function(){Co(!1)},3e3)},Lr=gn-Yt||0,ml=Yt-Ct||0,Fs=Lr>0,gs=$e.useMemo(function(){if(ln===0||Lr===0)return 0;var Oo=ln/Lr;return Oo*ml},[ln,Lr,ml]),Vt=function(xa){xa.stopPropagation(),xa.preventDefault()},Kr=$e.useRef({top:gs,dragging:wn,pageY:Dt,startTop:kn});Kr.current={top:gs,dragging:wn,pageY:Dt,startTop:kn};var Ko=function(xa){pi(!0),wi(xe(xa,zt)),Xi(Kr.current.top),Vn(),xa.stopPropagation(),xa.preventDefault()};$e.useEffect(function(){var Oo=function(Pn){Pn.preventDefault()},xa=La.current,An=$o.current;return xa.addEventListener("touchstart",Oo),An.addEventListener("touchstart",Ko),function(){xa.removeEventListener("touchstart",Oo),An.removeEventListener("touchstart",Ko)}},[]);var Er=$e.useRef();Er.current=Lr;var Wa=$e.useRef();Wa.current=ml,$e.useEffect(function(){if(wn){var Oo,xa=function(Pn){var jo=Kr.current,Ws=jo.dragging,qa=jo.pageY,bl=jo.startTop;if(me.cancel(Oo),Ws){var Xa=xe(Pn,zt)-qa,_o=bl;!Lo&&zt?_o-=Xa:_o+=Xa;var Va=Er.current,il=Wa.current,Na=il?_o/il:0,Li=Math.ceil(Na*Va);Li=Math.max(Li,0),Li=Math.min(Li,Va),Oo=me(function(){jt(Li,zt)})}},An=function(){pi(!1),_i()};return window.addEventListener("mousemove",xa),window.addEventListener("touchmove",xa),window.addEventListener("mouseup",An),window.addEventListener("touchend",An),function(){window.removeEventListener("mousemove",xa),window.removeEventListener("touchmove",xa),window.removeEventListener("mouseup",An),window.removeEventListener("touchend",An),me.cancel(Oo)}}},[wn]),$e.useEffect(function(){ri()},[ln]),$e.useImperativeHandle(we,function(){return{delayHidden:ri}});var Wo="".concat(bn,"-scrollbar"),ea={position:"absolute",visibility:cr&&Fs?null:"hidden"},fo={position:"absolute",background:"rgba(0, 0, 0, 0.5)",borderRadius:99,cursor:"pointer",userSelect:"none"};return zt?(ea.height=8,ea.left=0,ea.right=0,ea.bottom=0,fo.height="100%",fo.width=Ct,Lo?fo.left=gs:fo.right=gs):(ea.width=8,ea.top=0,ea.bottom=0,Lo?ea.right=0:ea.left=0,fo.width="100%",fo.height=Ct,fo.top=gs),$e.createElement("div",{ref:La,className:wt()(Wo,(Qn={},(0,kt.Z)(Qn,"".concat(Wo,"-horizontal"),zt),(0,kt.Z)(Qn,"".concat(Wo,"-vertical"),!zt),(0,kt.Z)(Qn,"".concat(Wo,"-visible"),cr),Qn)),style:(0,dt.Z)((0,dt.Z)({},ea),ci),onMouseDown:Vt,onMouseMove:ri},$e.createElement("div",{ref:$o,className:wt()("".concat(Wo,"-thumb"),(0,kt.Z)({},"".concat(Wo,"-thumb-moving"),wn)),style:(0,dt.Z)((0,dt.Z)({},fo),vi),onMouseDown:Ko}))}),Ge=Ee;function et(Fn){var we=Fn.children,Qn=Fn.setRef,bn=$e.useCallback(function(on){Qn(on)},[]);return $e.cloneElement(we,{ref:bn})}function ut(Fn,we,Qn,bn,on,ln,gn){var Vn=gn.getKey;return Fn.slice(we,Qn+1).map(function(_i,jt){var zt=we+jt,Ct=ln(_i,zt,{style:{width:bn}}),Yt=Vn(_i);return $e.createElement(et,{key:Yt,setRef:function(vi){return on(_i,vi)}},Ct)})}function st(Fn){return Fn instanceof HTMLElement||Fn instanceof SVGElement}function it(Fn){return st(Fn)?Fn:Fn instanceof $e.Component?Mt.findDOMNode(Fn):null}var Nt=De(15671),St=De(43144),Ft=function(){function Fn(){(0,Nt.Z)(this,Fn),this.maps=void 0,this.id=0,this.maps=Object.create(null)}return(0,St.Z)(Fn,[{key:"set",value:function(Qn,bn){this.maps[Qn]=bn,this.id+=1}},{key:"get",value:function(Qn){return this.maps[Qn]}}]),Fn}(),cn=Ft;function Tt(Fn,we,Qn){var bn=$e.useState(0),on=(0,$t.Z)(bn,2),ln=on[0],gn=on[1],Vn=(0,$e.useRef)(new Map),_i=(0,$e.useRef)(new cn),jt=(0,$e.useRef)();function zt(){me.cancel(jt.current)}function Ct(){var ci=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;zt();var vi=function(){Vn.current.forEach(function(Kt,wn){if(Kt&&Kt.offsetParent){var pi=it(Kt),ji=pi.offsetHeight;_i.current.get(wn)!==ji&&_i.current.set(wn,pi.offsetHeight)}}),gn(function(Kt){return Kt+1})};ci?vi():jt.current=me(vi)}function Yt(ci,vi){var ai=Fn(ci),Kt=Vn.current.get(ai);vi?(Vn.current.set(ai,vi),Ct()):Vn.current.delete(ai),!Kt!=!vi&&(vi?we==null||we(ci):Qn==null||Qn(ci))}return(0,$e.useEffect)(function(){return zt},[]),[Yt,Ct,_i.current,ln]}function hi(){return!!(typeof window!="undefined"&&window.document&&window.document.createElement)}var di=hi()?$e.useLayoutEffect:$e.useEffect,zn=function(we,Qn){var bn=$e.useRef(!0);di(function(){return we(bn.current)},Qn),di(function(){return bn.current=!1,function(){bn.current=!0}},[])},Dn=function(we,Qn){zn(function(bn){if(!bn)return we()},Qn)},nt=zn;function ze(Fn){var we=$e.useRef();we.current=Fn;var Qn=$e.useCallback(function(){for(var bn,on=arguments.length,ln=new Array(on),gn=0;gn<on;gn++)ln[gn]=arguments[gn];return(bn=we.current)===null||bn===void 0?void 0:bn.call.apply(bn,[we].concat(ln))},[]);return Qn}function ke(Fn){var we=React.useRef(!1),Qn=React.useState(Fn),bn=_slicedToArray(Qn,2),on=bn[0],ln=bn[1];React.useEffect(function(){return we.current=!1,function(){we.current=!0}},[]);function gn(Vn,_i){_i&&we.current||ln(Vn)}return[on,gn]}function Wt(Fn){return Fn!==void 0}function On(Fn,we){var Qn=we||{},bn=Qn.defaultValue,on=Qn.value,ln=Qn.onChange,gn=Qn.postState,Vn=useState(function(){return Wt(on)?on:Wt(bn)?typeof bn=="function"?bn():bn:typeof Fn=="function"?Fn():Fn}),_i=_slicedToArray(Vn,2),jt=_i[0],zt=_i[1],Ct=on!==void 0?on:jt,Yt=gn?gn(Ct):Ct,ci=useEvent(ln),vi=useState([Ct]),ai=_slicedToArray(vi,2),Kt=ai[0],wn=ai[1];useLayoutUpdateEffect(function(){var ji=Kt[0];jt!==ji&&ci(jt,ji)},[Kt]),useLayoutUpdateEffect(function(){Wt(on)||zt(on)},[on]);var pi=useEvent(function(ji,Rn){zt(ji,Rn),wn([Ct],Rn)});return[Yt,pi]}var Lt=De(31461);function xn(Fn,we,Qn){var bn=React.useRef({});return(!("value"in bn.current)||Qn(bn.current.condition,we))&&(bn.current.value=Fn(),bn.current.condition=we),bn.current.value}function vn(Fn,we){typeof Fn=="function"?Fn(we):_typeof(Fn)==="object"&&Fn&&"current"in Fn&&(Fn.current=we)}function Xn(){for(var Fn=arguments.length,we=new Array(Fn),Qn=0;Qn<Fn;Qn++)we[Qn]=arguments[Qn];var bn=we.filter(function(on){return on});return bn.length<=1?bn[0]:function(on){we.forEach(function(ln){vn(ln,on)})}}function Ot(){for(var Fn=arguments.length,we=new Array(Fn),Qn=0;Qn<Fn;Qn++)we[Qn]=arguments[Qn];return useMemo(function(){return Xn.apply(void 0,we)},we,function(bn,on){return bn.length!==on.length||bn.every(function(ln,gn){return ln!==on[gn]})})}function ft(Fn){var we,Qn,bn=isMemo(Fn)?Fn.type.type:Fn.type;return!(typeof bn=="function"&&!((we=bn.prototype)!==null&&we!==void 0&&we.render)||typeof Fn=="function"&&!((Qn=Fn.prototype)!==null&&Qn!==void 0&&Qn.render))}function Gt(Fn){return!isValidElement(Fn)||isFragment(Fn)?!1:ft(Fn)}function an(Fn,we,Qn,bn){if(!we.length)return Qn;var on=_toArray(we),ln=on[0],gn=on.slice(1),Vn;return!Fn&&typeof ln=="number"?Vn=[]:Array.isArray(Fn)?Vn=_toConsumableArray(Fn):Vn=_objectSpread({},Fn),bn&&Qn===void 0&&gn.length===1?delete Vn[ln][gn[0]]:Vn[ln]=an(Vn[ln],gn,Qn,bn),Vn}function Jt(Fn,we,Qn){var bn=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;return we.length&&bn&&Qn===void 0&&!get(Fn,we.slice(0,-1))?Fn:an(Fn,we,Qn,bn)}function Ve(Fn){return _typeof(Fn)==="object"&&Fn!==null&&Object.getPrototypeOf(Fn)===Object.prototype}function be(Fn){return Array.isArray(Fn)?[]:{}}var Pe=typeof Reflect=="undefined"?Object.keys:Reflect.ownKeys;function Be(){for(var Fn=arguments.length,we=new Array(Fn),Qn=0;Qn<Fn;Qn++)we[Qn]=arguments[Qn];var bn=be(we[0]);return we.forEach(function(on){function ln(gn,Vn){var _i=new Set(Vn),jt=get(on,gn),zt=Array.isArray(jt);if(zt||Ve(jt)){if(!_i.has(jt)){_i.add(jt);var Ct=get(bn,gn);zt?bn=Jt(bn,gn,[]):(!Ct||_typeof(Ct)!=="object")&&(bn=Jt(bn,gn,be(jt))),Pe(jt).forEach(function(Yt){ln([].concat(_toConsumableArray(gn),[Yt]),_i)})}}else bn=Jt(bn,gn,jt)}ln([])}),bn}var Ze={},Fe=[],qe=function(we){Fe.push(we)};function dn(Fn,we){if(0)var Qn}function ui(Fn,we){if(0)var Qn}function $n(){Ze={}}function rn(Fn,we,Qn){!we&&!Ze[Qn]&&(Fn(!1,Qn),Ze[Qn]=!0)}function Hn(Fn,we){rn(dn,Fn,we)}function Zt(Fn,we){rn(ui,Fn,we)}Hn.preMessage=qe,Hn.resetWarned=$n,Hn.noteOnce=Zt;var _n=null,ti=10;function Ri(Fn,we,Qn,bn,on,ln,gn,Vn){var _i=$e.useRef(),jt=$e.useState(null),zt=(0,$t.Z)(jt,2),Ct=zt[0],Yt=zt[1];return nt(function(){if(Ct&&Ct.times<ti){if(!Fn.current){Yt(function(ri){return(0,dt.Z)({},ri)});return}ln();var ci=Ct.targetAlign,vi=Ct.originAlign,ai=Ct.index,Kt=Ct.offset,wn=Fn.current.clientHeight,pi=!1,ji=ci,Rn=null;if(wn){for(var Dt=ci||vi,wi=0,gr=0,eo=0,kn=Math.min(we.length-1,ai),Xi=0;Xi<=kn;Xi+=1){var Lo=on(we[Xi]);gr=wi;var La=Qn.get(Lo);eo=gr+(La===void 0?bn:La),wi=eo}for(var $o=Dt==="top"?Kt:wn-Kt,qi=kn;qi>=0;qi-=1){var Zi=on(we[qi]),cr=Qn.get(Zi);if(cr===void 0){pi=!0;break}if($o-=cr,$o<=0)break}switch(Dt){case"top":Rn=gr-Kt;break;case"bottom":Rn=eo-wn+Kt;break;default:{var Co=Fn.current.scrollTop,Zo=Co+wn;gr<Co?ji="top":eo>Zo&&(ji="bottom")}}Rn!==null&&gn(Rn),Rn!==Ct.lastTop&&(pi=!0)}pi&&Yt(function(ri){return(0,dt.Z)((0,dt.Z)({},ri),{},{times:ri.times+1,targetAlign:ji,lastTop:Rn})})}},[Ct,Fn.current]),function(ci){if(ci==null){Vn();return}if(me.cancel(_i.current),typeof ci=="number")gn(ci);else if(ci&&(0,Ut.Z)(ci)==="object"){var vi,ai=ci.align;"index"in ci?vi=ci.index:vi=we.findIndex(function(pi){return on(pi)===ci.key});var Kt=ci.offset,wn=Kt===void 0?0:Kt;Yt({times:0,index:vi,offset:wn,originAlign:ai})}}}function oi(Fn,we,Qn,bn){var on=Qn-Fn,ln=we-Qn,gn=Math.min(on,ln)*2;if(bn<=gn){var Vn=Math.floor(bn/2);return bn%2?Qn+Vn+1:Qn-Vn}return on>ln?Qn-(bn-ln):Qn+(bn-on)}function wr(Fn,we,Qn){var bn=Fn.length,on=we.length,ln,gn;if(bn===0&&on===0)return null;bn<on?(ln=Fn,gn=we):(ln=we,gn=Fn);var Vn={__EMPTY_ITEM__:!0};function _i(vi){return vi!==void 0?Qn(vi):Vn}for(var jt=null,zt=Math.abs(bn-on)!==1,Ct=0;Ct<gn.length;Ct+=1){var Yt=_i(ln[Ct]),ci=_i(gn[Ct]);if(Yt!==ci){jt=Ct,zt=zt||Yt!==_i(gn[Ct+1]);break}}return jt===null?null:{index:jt,multiple:zt}}function fr(Fn,we,Qn){var bn=$e.useState(Fn),on=(0,$t.Z)(bn,2),ln=on[0],gn=on[1],Vn=$e.useState(null),_i=(0,$t.Z)(Vn,2),jt=_i[0],zt=_i[1];return $e.useEffect(function(){var Ct=wr(ln||[],Fn||[],we);(Ct==null?void 0:Ct.index)!==void 0&&(Qn==null||Qn(Ct.index),zt(Fn[Ct.index])),gn(Fn)},[Fn]),[jt]}var Ei=(typeof navigator=="undefined"?"undefined":(0,Ut.Z)(navigator))==="object"&&/Firefox/i.test(navigator.userAgent),Di=Ei,uo=function(Fn,we){var Qn=(0,$e.useRef)(!1),bn=(0,$e.useRef)(null);function on(){clearTimeout(bn.current),Qn.current=!0,bn.current=setTimeout(function(){Qn.current=!1},50)}var ln=(0,$e.useRef)({top:Fn,bottom:we});return ln.current.top=Fn,ln.current.bottom=we,function(gn){var Vn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,_i=gn<0&&ln.current.top||gn>0&&ln.current.bottom;return Vn&&_i?(clearTimeout(bn.current),Qn.current=!1):(!_i||Qn.current)&&on(),!Qn.current&&_i}};function vt(Fn,we,Qn,bn,on){var ln=(0,$e.useRef)(0),gn=(0,$e.useRef)(null),Vn=(0,$e.useRef)(null),_i=(0,$e.useRef)(!1),jt=uo(we,Qn);function zt(Kt,wn){me.cancel(gn.current),ln.current+=wn,Vn.current=wn,!jt(wn)&&(Di||Kt.preventDefault(),gn.current=me(function(){var pi=_i.current?10:1;on(ln.current*pi),ln.current=0}))}function Ct(Kt,wn){on(wn,!0),Di||Kt.preventDefault()}var Yt=(0,$e.useRef)(null),ci=(0,$e.useRef)(null);function vi(Kt){if(Fn){me.cancel(ci.current),ci.current=me(function(){Yt.current=null},2);var wn=Kt.deltaX,pi=Kt.deltaY,ji=Kt.shiftKey,Rn=wn,Dt=pi;(Yt.current==="sx"||!Yt.current&&ji&&pi&&!wn)&&(Rn=pi,Dt=0,Yt.current="sx");var wi=Math.abs(Rn),gr=Math.abs(Dt);Yt.current===null&&(Yt.current=bn&&wi>gr?"x":"y"),Yt.current==="y"?zt(Kt,Dt):Ct(Kt,Rn)}}function ai(Kt){Fn&&(_i.current=Kt.detail===Vn.current)}return[vi,ai]}var ei=14/15;function co(Fn,we,Qn){var bn=(0,$e.useRef)(!1),on=(0,$e.useRef)(0),ln=(0,$e.useRef)(null),gn=(0,$e.useRef)(null),Vn,_i=function(Yt){if(bn.current){var ci=Math.ceil(Yt.touches[0].pageY),vi=on.current-ci;on.current=ci,Qn(vi)&&Yt.preventDefault(),clearInterval(gn.current),gn.current=setInterval(function(){vi*=ei,(!Qn(vi,!0)||Math.abs(vi)<=.1)&&clearInterval(gn.current)},16)}},jt=function(){bn.current=!1,Vn()},zt=function(Yt){Vn(),Yt.touches.length===1&&!bn.current&&(bn.current=!0,on.current=Math.ceil(Yt.touches[0].pageY),ln.current=Yt.target,ln.current.addEventListener("touchmove",_i),ln.current.addEventListener("touchend",jt))};Vn=function(){ln.current&&(ln.current.removeEventListener("touchmove",_i),ln.current.removeEventListener("touchend",jt))},nt(function(){return Fn&&we.current.addEventListener("touchstart",zt),function(){var Ct;(Ct=we.current)===null||Ct===void 0||Ct.removeEventListener("touchstart",zt),Vn(),clearInterval(gn.current)}},[Fn])}var bo=20;function Ui(){var Fn=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,we=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,Qn=Fn/we*100;return isNaN(Qn)&&(Qn=0),Qn=Math.max(Qn,bo),Qn=Math.min(Qn,Fn/2),Math.floor(Qn)}function yo(Fn,we,Qn,bn){var on=$e.useMemo(function(){return[new Map,[]]},[Fn,Qn.id,bn]),ln=(0,$t.Z)(on,2),gn=ln[0],Vn=ln[1],_i=function(zt){var Ct=arguments.length>1&&arguments[1]!==void 0?arguments[1]:zt,Yt=gn.get(zt),ci=gn.get(Ct);if(Yt===void 0||ci===void 0)for(var vi=Fn.length,ai=Vn.length;ai<vi;ai+=1){var Kt,wn=Fn[ai],pi=we(wn);gn.set(pi,ai);var ji=(Kt=Qn.get(pi))!==null&&Kt!==void 0?Kt:bn;if(Vn[ai]=(Vn[ai-1]||0)+ji,pi===zt&&(Yt=ai),pi===Ct&&(ci=ai),Yt!==void 0&&ci!==void 0)break}return{top:Vn[Yt-1]||0,bottom:Vn[ci]}};return _i}var ha=["prefixCls","className","height","itemHeight","fullHeight","style","data","children","itemKey","virtual","direction","scrollWidth","component","onScroll","onVirtualScroll","onVisibleChange","innerProps","extraRender","styles"],Ka=[],Ra={overflowY:"auto",overflowAnchor:"none"};function ca(Fn,we){var Qn=Fn.prefixCls,bn=Qn===void 0?"rc-virtual-list":Qn,on=Fn.className,ln=Fn.height,gn=Fn.itemHeight,Vn=Fn.fullHeight,_i=Vn===void 0?!0:Vn,jt=Fn.style,zt=Fn.data,Ct=Fn.children,Yt=Fn.itemKey,ci=Fn.virtual,vi=Fn.direction,ai=Fn.scrollWidth,Kt=Fn.component,wn=Kt===void 0?"div":Kt,pi=Fn.onScroll,ji=Fn.onVirtualScroll,Rn=Fn.onVisibleChange,Dt=Fn.innerProps,wi=Fn.extraRender,gr=Fn.styles,eo=(0,Ie.Z)(Fn,ha),kn=!!(ci!==!1&&ln&&gn),Xi=kn&&zt&&(gn*zt.length>ln||!!ai),Lo=vi==="rtl",La=wt()(bn,(0,kt.Z)({},"".concat(bn,"-rtl"),Lo),on),$o=zt||Ka,qi=(0,$e.useRef)(),Zi=(0,$e.useRef)(),cr=(0,$e.useState)(0),Co=(0,$t.Z)(cr,2),Zo=Co[0],ri=Co[1],Lr=(0,$e.useState)(0),ml=(0,$t.Z)(Lr,2),Fs=ml[0],gs=ml[1],Vt=(0,$e.useState)(!1),Kr=(0,$t.Z)(Vt,2),Ko=Kr[0],Er=Kr[1],Wa=function(){Er(!0)},Wo=function(){Er(!1)},ea=$e.useCallback(function(Mo){return typeof Yt=="function"?Yt(Mo):Mo==null?void 0:Mo[Yt]},[Yt]),fo={getKey:ea};function Oo(Mo){ri(function(Ro){var Ma;typeof Mo=="function"?Ma=Mo(Ro):Ma=Mo;var Ls=so(Ma);return qi.current.scrollTop=Ls,Ls})}var xa=(0,$e.useRef)({start:0,end:$o.length}),An=(0,$e.useRef)(),Ya=fr($o,ea),Pn=(0,$t.Z)(Ya,1),jo=Pn[0];An.current=jo;var Ws=Tt(ea,null,null),qa=(0,$t.Z)(Ws,4),bl=qa[0],Xa=qa[1],_o=qa[2],Va=qa[3],il=$e.useMemo(function(){if(!kn)return{scrollHeight:void 0,start:0,end:$o.length-1,offset:void 0};if(!Xi){var Mo;return{scrollHeight:((Mo=Zi.current)===null||Mo===void 0?void 0:Mo.offsetHeight)||0,start:0,end:$o.length-1,offset:void 0}}for(var Ro=0,Ma,Ls,vr,$h=$o.length,Nl=0;Nl<$h;Nl+=1){var Tl=$o[Nl],wh=ea(Tl),Ju=_o.get(wh),Bi=Ro+(Ju===void 0?gn:Ju);Bi>=Zo&&Ma===void 0&&(Ma=Nl,Ls=Ro),Bi>Zo+ln&&vr===void 0&&(vr=Nl),Ro=Bi}return Ma===void 0&&(Ma=0,Ls=0,vr=Math.ceil(ln/gn)),vr===void 0&&(vr=$o.length-1),vr=Math.min(vr+1,$o.length-1),{scrollHeight:Ro,start:Ma,end:vr,offset:Ls}},[Xi,kn,Zo,$o,Va,ln]),Na=il.scrollHeight,Li=il.start,Qe=il.end,bs=il.offset;xa.current.start=Li,xa.current.end=Qe;var Ul=$e.useState({width:0,height:ln}),Zl=(0,$t.Z)(Ul,2),rl=Zl[0],tu=Zl[1],Il=function(Ro){tu({width:Ro.width||Ro.offsetWidth,height:Ro.height||Ro.offsetHeight})},Hu=(0,$e.useRef)(),nu=(0,$e.useRef)(),Ua=$e.useMemo(function(){return Ui(rl.width,ai)},[rl.width,ai]),ps=$e.useMemo(function(){return Ui(rl.height,Na)},[rl.height,Na]),Or=Na-ln,Pr=(0,$e.useRef)(Or);Pr.current=Or;function so(Mo){var Ro=Mo;return Number.isNaN(Pr.current)||(Ro=Math.min(Ro,Pr.current)),Ro=Math.max(Ro,0),Ro}var fn=Zo<=0,jr=Zo>=Or,Ao=uo(fn,jr),$a=function(){return{x:Lo?-Fs:Fs,y:Zo}},Ia=(0,$e.useRef)($a()),ms=ze(function(){if(ji){var Mo=$a();(Ia.current.x!==Mo.x||Ia.current.y!==Mo.y)&&(ji(Mo),Ia.current=Mo)}});function Vs(Mo,Ro){var Ma=Mo;Ro?((0,Mt.flushSync)(function(){gs(Ma)}),ms()):Oo(Ma)}function el(Mo){var Ro=Mo.currentTarget.scrollTop;Ro!==Zo&&Oo(Ro),pi==null||pi(Mo),ms()}var vl=function(Ro){var Ma=Ro,Ls=ai-rl.width;return Ma=Math.max(Ma,0),Ma=Math.min(Ma,Ls),Ma},Gu=ze(function(Mo,Ro){Ro?((0,Mt.flushSync)(function(){gs(function(Ma){var Ls=Ma+(Lo?-Mo:Mo);return vl(Ls)})}),ms()):Oo(function(Ma){var Ls=Ma+Mo;return Ls})}),Fu=vt(kn,fn,jr,!!ai,Gu),Xt=(0,$t.Z)(Fu,2),Ll=Xt[0],zl=Xt[1];co(kn,qi,function(Mo,Ro){return Ao(Mo,Ro)?!1:(Ll({preventDefault:function(){},deltaY:Mo}),!0)}),nt(function(){function Mo(Ma){kn&&Ma.preventDefault()}var Ro=qi.current;return Ro.addEventListener("wheel",Ll),Ro.addEventListener("DOMMouseScroll",zl),Ro.addEventListener("MozMousePixelScroll",Mo),function(){Ro.removeEventListener("wheel",Ll),Ro.removeEventListener("DOMMouseScroll",zl),Ro.removeEventListener("MozMousePixelScroll",Mo)}},[kn]),nt(function(){ai&&gs(function(Mo){return vl(Mo)})},[rl.width,ai]);var fu=function(){var Ro,Ma;(Ro=Hu.current)===null||Ro===void 0||Ro.delayHidden(),(Ma=nu.current)===null||Ma===void 0||Ma.delayHidden()},As=Ri(qi,$o,_o,gn,ea,function(){return Xa(!0)},Oo,fu);$e.useImperativeHandle(we,function(){return{getScrollInfo:$a,scrollTo:function(Ro){function Ma(Ls){return Ls&&(0,Ut.Z)(Ls)==="object"&&("left"in Ls||"top"in Ls)}Ma(Ro)?(Ro.left!==void 0&&gs(vl(Ro.left)),As(Ro.top)):As(Ro)}}}),nt(function(){if(Rn){var Mo=$o.slice(Li,Qe+1);Rn(Mo,$o)}},[Li,Qe,$o]);var gu=yo($o,ea,_o,gn),xh=wi==null?void 0:wi({start:Li,end:Qe,virtual:Xi,offsetX:Fs,offsetY:bs,rtl:Lo,getSize:gu}),Xu=ut($o,Li,Qe,ai,bl,Ct,fo),es=null;ln&&(es=(0,dt.Z)((0,kt.Z)({},_i?"height":"maxHeight",ln),Ra),kn&&(es.overflowY="hidden",ai&&(es.overflowX="hidden"),Ko&&(es.pointerEvents="none")));var Ds={};return Lo&&(Ds.dir="rtl"),$e.createElement("div",(0,Ne.Z)({style:(0,dt.Z)((0,dt.Z)({},jt),{},{position:"relative"}),className:La},Ds,eo),$e.createElement(Qt.Z,{onResize:Il},$e.createElement(wn,{className:"".concat(bn,"-holder"),style:es,ref:qi,onScroll:el,onMouseEnter:fu},$e.createElement(sn,{prefixCls:bn,height:Na,offsetX:Fs,offsetY:bs,scrollWidth:ai,onInnerResize:Xa,ref:Zi,innerProps:Dt,rtl:Lo,extra:xh},Xu))),Xi&&Na>ln&&$e.createElement(Ge,{ref:Hu,prefixCls:bn,scrollOffset:Zo,scrollRange:Na,rtl:Lo,onScroll:Vs,onStartMove:Wa,onStopMove:Wo,spinSize:ps,containerSize:rl.height,style:gr==null?void 0:gr.verticalScrollBar,thumbStyle:gr==null?void 0:gr.verticalScrollBarThumb}),Xi&&ai&&$e.createElement(Ge,{ref:nu,prefixCls:bn,scrollOffset:Fs,scrollRange:ai,rtl:Lo,onScroll:Vs,onStartMove:Wa,onStopMove:Wo,spinSize:Ua,containerSize:rl.width,horizontal:!0,style:gr==null?void 0:gr.horizontalScrollBar,thumbStyle:gr==null?void 0:gr.horizontalScrollBarThumb}))}var ma=$e.forwardRef(ca);ma.displayName="List";var Ho=ma,_r=Ho},66392:function(jn,li){"use strict";var De;var Ne=Symbol.for("react.element"),dt=Symbol.for("react.portal"),Ut=Symbol.for("react.fragment"),$t=Symbol.for("react.strict_mode"),kt=Symbol.for("react.profiler"),Ie=Symbol.for("react.provider"),$e=Symbol.for("react.context"),Mt=Symbol.for("react.server_context"),Pt=Symbol.for("react.forward_ref"),wt=Symbol.for("react.suspense"),Qt=Symbol.for("react.suspense_list"),It=Symbol.for("react.memo"),sn=Symbol.for("react.lazy"),Re=Symbol.for("react.offscreen"),ne;ne=Symbol.for("react.module.reference");function te(he){if(typeof he=="object"&&he!==null){var le=he.$$typeof;switch(le){case Ne:switch(he=he.type,he){case Ut:case kt:case $t:case wt:case Qt:return he;default:switch(he=he&&he.$$typeof,he){case Mt:case $e:case Pt:case sn:case It:case Ie:return he;default:return le}}case dt:return le}}}De=$e,De=Ie,De=Ne,De=Pt,De=Ut,De=sn,De=It,De=dt,De=kt,De=$t,De=wt,De=Qt,De=function(){return!1},De=function(){return!1},De=function(he){return te(he)===$e},De=function(he){return te(he)===Ie},De=function(he){return typeof he=="object"&&he!==null&&he.$$typeof===Ne},De=function(he){return te(he)===Pt},De=function(he){return te(he)===Ut},De=function(he){return te(he)===sn},De=function(he){return te(he)===It},De=function(he){return te(he)===dt},De=function(he){return te(he)===kt},De=function(he){return te(he)===$t},De=function(he){return te(he)===wt},De=function(he){return te(he)===Qt},De=function(he){return typeof he=="string"||typeof he=="function"||he===Ut||he===kt||he===$t||he===wt||he===Qt||he===Re||typeof he=="object"&&he!==null&&(he.$$typeof===sn||he.$$typeof===It||he.$$typeof===Ie||he.$$typeof===$e||he.$$typeof===Pt||he.$$typeof===ne||he.getModuleId!==void 0)},De=te},31461:function(jn,li,De){"use strict";De(66392)},32637:function(jn,li,De){"use strict";jn.exports=De.p+"static/AssistantCode3.a8740efb.jpeg"},4977:function(jn){"use strict";jn.exports="data:image/png;base64,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"},96908:function(jn){"use strict";jn.exports="data:image/png;base64,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"},57177:function(jn){"use strict";jn.exports="data:image/png;base64,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"},81378:function(jn){"use strict";jn.exports="data:image/png;base64,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"},17423:function(jn,li,De){"use strict";De.d(li,{Z:function(){return Mt}});const Ne=Pt=>typeof Pt=="object"&&Pt!=null&&Pt.nodeType===1,dt=(Pt,wt)=>(!wt||Pt!=="hidden")&&Pt!=="visible"&&Pt!=="clip",Ut=(Pt,wt)=>{if(Pt.clientHeight<Pt.scrollHeight||Pt.clientWidth<Pt.scrollWidth){const Qt=getComputedStyle(Pt,null);return dt(Qt.overflowY,wt)||dt(Qt.overflowX,wt)||(It=>{const sn=(Re=>{if(!Re.ownerDocument||!Re.ownerDocument.defaultView)return null;try{return Re.ownerDocument.defaultView.frameElement}catch(ne){return null}})(It);return!!sn&&(sn.clientHeight<It.scrollHeight||sn.clientWidth<It.scrollWidth)})(Pt)}return!1},$t=(Pt,wt,Qt,It,sn,Re,ne,te)=>Re<Pt&&ne>wt||Re>Pt&&ne<wt?0:Re<=Pt&&te<=Qt||ne>=wt&&te>=Qt?Re-Pt-It:ne>wt&&te<Qt||Re<Pt&&te>Qt?ne-wt+sn:0,kt=Pt=>{const wt=Pt.parentElement;return wt==null?Pt.getRootNode().host||null:wt},Ie=(Pt,wt)=>{var Qt,It,sn,Re;if(typeof document=="undefined")return[];const{scrollMode:ne,block:te,inline:he,boundary:le,skipOverflowHiddenElements:pe}=wt,me=typeof le=="function"?le:On=>On!==le;if(!Ne(Pt))throw new TypeError("Invalid target");const xe=document.scrollingElement||document.documentElement,Ee=[];let Ge=Pt;for(;Ne(Ge)&&me(Ge);){if(Ge=kt(Ge),Ge===xe){Ee.push(Ge);break}Ge!=null&&Ge===document.body&&Ut(Ge)&&!Ut(document.documentElement)||Ge!=null&&Ut(Ge,pe)&&Ee.push(Ge)}const et=(It=(Qt=window.visualViewport)==null?void 0:Qt.width)!=null?It:innerWidth,ut=(Re=(sn=window.visualViewport)==null?void 0:sn.height)!=null?Re:innerHeight,{scrollX:st,scrollY:it}=window,{height:Nt,width:St,top:Ft,right:cn,bottom:Tt,left:hi}=Pt.getBoundingClientRect(),{top:di,right:zn,bottom:Dn,left:nt}=(On=>{const Lt=window.getComputedStyle(On);return{top:parseFloat(Lt.scrollMarginTop)||0,right:parseFloat(Lt.scrollMarginRight)||0,bottom:parseFloat(Lt.scrollMarginBottom)||0,left:parseFloat(Lt.scrollMarginLeft)||0}})(Pt);let ze=te==="start"||te==="nearest"?Ft-di:te==="end"?Tt+Dn:Ft+Nt/2-di+Dn,ke=he==="center"?hi+St/2-nt+zn:he==="end"?cn+zn:hi-nt;const Wt=[];for(let On=0;On<Ee.length;On++){const Lt=Ee[On],{height:xn,width:vn,top:Xn,right:Ot,bottom:ft,left:Gt}=Lt.getBoundingClientRect();if(ne==="if-needed"&&Ft>=0&&hi>=0&&Tt<=ut&&cn<=et&&Ft>=Xn&&Tt<=ft&&hi>=Gt&&cn<=Ot)return Wt;const an=getComputedStyle(Lt),Jt=parseInt(an.borderLeftWidth,10),Ve=parseInt(an.borderTopWidth,10),be=parseInt(an.borderRightWidth,10),Pe=parseInt(an.borderBottomWidth,10);let Be=0,Ze=0;const Fe="offsetWidth"in Lt?Lt.offsetWidth-Lt.clientWidth-Jt-be:0,qe="offsetHeight"in Lt?Lt.offsetHeight-Lt.clientHeight-Ve-Pe:0,dn="offsetWidth"in Lt?Lt.offsetWidth===0?0:vn/Lt.offsetWidth:0,ui="offsetHeight"in Lt?Lt.offsetHeight===0?0:xn/Lt.offsetHeight:0;if(xe===Lt)Be=te==="start"?ze:te==="end"?ze-ut:te==="nearest"?$t(it,it+ut,ut,Ve,Pe,it+ze,it+ze+Nt,Nt):ze-ut/2,Ze=he==="start"?ke:he==="center"?ke-et/2:he==="end"?ke-et:$t(st,st+et,et,Jt,be,st+ke,st+ke+St,St),Be=Math.max(0,Be+it),Ze=Math.max(0,Ze+st);else{Be=te==="start"?ze-Xn-Ve:te==="end"?ze-ft+Pe+qe:te==="nearest"?$t(Xn,ft,xn,Ve,Pe+qe,ze,ze+Nt,Nt):ze-(Xn+xn/2)+qe/2,Ze=he==="start"?ke-Gt-Jt:he==="center"?ke-(Gt+vn/2)+Fe/2:he==="end"?ke-Ot+be+Fe:$t(Gt,Ot,vn,Jt,be+Fe,ke,ke+St,St);const{scrollLeft:$n,scrollTop:rn}=Lt;Be=ui===0?0:Math.max(0,Math.min(rn+Be/ui,Lt.scrollHeight-xn/ui+qe)),Ze=dn===0?0:Math.max(0,Math.min($n+Ze/dn,Lt.scrollWidth-vn/dn+Fe)),ze+=rn-Be,ke+=$n-Ze}Wt.push({el:Lt,top:Be,left:Ze})}return Wt},$e=Pt=>Pt===!1?{block:"end",inline:"nearest"}:(wt=>wt===Object(wt)&&Object.keys(wt).length!==0)(Pt)?Pt:{block:"start",inline:"nearest"};function Mt(Pt,wt){if(!Pt.isConnected||!(sn=>{let Re=sn;for(;Re&&Re.parentNode;){if(Re.parentNode===document)return!0;Re=Re.parentNode instanceof ShadowRoot?Re.parentNode.host:Re.parentNode}return!1})(Pt))return;const Qt=(sn=>{const Re=window.getComputedStyle(sn);return{top:parseFloat(Re.scrollMarginTop)||0,right:parseFloat(Re.scrollMarginRight)||0,bottom:parseFloat(Re.scrollMarginBottom)||0,left:parseFloat(Re.scrollMarginLeft)||0}})(Pt);if((sn=>typeof sn=="object"&&typeof sn.behavior=="function")(wt))return wt.behavior(Ie(Pt,wt));const It=typeof wt=="boolean"||wt==null?void 0:wt.behavior;for(const{el:sn,top:Re,left:ne}of Ie(Pt,$e(wt))){const te=Re-Qt.top+Qt.bottom,he=ne-Qt.left+Qt.right;sn.scroll({top:te,left:he,behavior:It})}}}}]);