(self.webpackChunk=self.webpackChunk||[]).push([[1578],{27812:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M872 474H286.9l350.2-304c5.6-4.9 2.2-14-5.2-14h-88.5c-3.9 0-7.6 1.4-10.5 3.9L155 487.8a31.96 31.96 0 000 48.3L535.1 866c1.5 1.3 3.3 2 5.2 2h91.5c7.4 0 10.8-9.2 5.2-14L286.9 550H872c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"arrow-left",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},89489:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},59477:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M858.9 689L530.5 308.2c-9.4-10.9-27.5-10.9-37 0L165.1 689c-12.2 14.2-1.2 35 18.5 35h656.8c19.7 0 30.7-20.8 18.5-35z"}}]},name:"caret-up",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},40001:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},26227:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},49198:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M533.2 492.3L277.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H188c-6.7 0-10.4 7.7-6.3 12.9L447.1 512 181.7 851.1A7.98 7.98 0 00188 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5zm304 0L581.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H492c-6.7 0-10.4 7.7-6.3 12.9L751.1 512 485.7 851.1A7.98 7.98 0 00492 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5z"}}]},name:"double-right",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},73331:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z"}},{tag:"path",attrs:{d:"M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z"}}]},name:"eye-invisible",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},15277:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},52671:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM790.2 326H602V137.8L790.2 326zm1.8 562H232V136h302v216a42 42 0 0042 42h216v494z"}}]},name:"file",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},8657:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M928 444H820V330.4c0-17.7-14.3-32-32-32H473L355.7 186.2a8.15 8.15 0 00-5.5-2.2H96c-17.7 0-32 14.3-32 32v592c0 17.7 14.3 32 32 32h698c13 0 24.8-7.9 29.7-20l134-332c1.5-3.8 2.3-7.9 2.3-12 0-17.7-14.3-32-32-32zM136 256h188.5l119.6 114.4H748V444H238c-13 0-24.8 7.9-29.7 20L136 643.2V256zm635.3 512H159l103.3-256h612.4L771.3 768z"}}]},name:"folder-open",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},56082:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M300 276.5a56 56 0 1056-97 56 56 0 00-56 97zm0 284a56 56 0 1056-97 56 56 0 00-56 97zM640 228a56 56 0 10112 0 56 56 0 00-112 0zm0 284a56 56 0 10112 0 56 56 0 00-112 0zM300 844.5a56 56 0 1056-97 56 56 0 00-56 97zM640 796a56 56 0 10112 0 56 56 0 00-112 0z"}}]},name:"holder",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},33853:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"}}]},name:"left",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},63524:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M885.9 533.7c16.8-22.2 26.1-49.4 26.1-77.7 0-44.9-25.1-87.4-65.5-111.1a67.67 67.67 0 00-34.3-9.3H572.4l6-122.9c1.4-29.7-9.1-57.9-29.5-79.4A106.62 106.62 0 00471 99.9c-52 0-98 35-111.8 85.1l-85.9 311H144c-17.7 0-32 14.3-32 32v364c0 17.7 14.3 32 32 32h601.3c9.2 0 18.2-1.8 26.5-5.4 47.6-20.3 78.3-66.8 78.3-118.4 0-12.6-1.8-25-5.4-37 16.8-22.2 26.1-49.4 26.1-77.7 0-12.6-1.8-25-5.4-37 16.8-22.2 26.1-49.4 26.1-77.7-.2-12.6-2-25.1-5.6-37.1zM184 852V568h81v284h-81zm636.4-353l-21.9 19 13.9 25.4a56.2 56.2 0 016.9 27.3c0 16.5-7.2 32.2-19.6 43l-21.9 19 13.9 25.4a56.2 56.2 0 016.9 27.3c0 16.5-7.2 32.2-19.6 43l-21.9 19 13.9 25.4a56.2 56.2 0 016.9 27.3c0 22.4-13.2 42.6-33.6 51.8H329V564.8l99.5-360.5a44.1 44.1 0 0142.2-32.3c7.6 0 15.1 2.2 21.1 6.7 9.9 7.4 15.2 18.6 14.6 30.5l-9.6 198.4h314.4C829 418.5 840 436.9 840 456c0 16.5-7.2 32.1-19.6 43z"}}]},name:"like",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},15075:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M328 544h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z"}},{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"minus-square",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},43531:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M328 544h152v152c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V544h152c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H544V328c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v152H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8z"}},{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z"}}]},name:"plus-square",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},61485:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7-21.2 8.1-39.2 22.3-52.1 40.9-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0130.9-44.8c59-22.7 97.1-74.7 97.1-132.5.1-39.3-17.1-76-48.3-103.3zM472 732a40 40 0 1080 0 40 40 0 10-80 0z"}}]},name:"question-circle",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},38819:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={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"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},47472:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(Qt,Fe){return Ht.createElement(Vt.Z,(0,Ft.Z)({},Qt,{ref:Fe,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt},37036:function(){"use strict"},95625:function(){"use strict"},88010:function(Cn,cn){"use strict";cn.Z={lists:"lists___xhHyq",item:"item___pWJAA",children:"children___sDG61",diamond:"diamond___FwgzD",button:"button___WPN6r",mathWrap:"mathWrap___FmnMJ",mathFillWrap:"mathFillWrap___PmY3H"}},74413:function(){"use strict";function Cn(It,et,nt,dt){nt===void 0&&(nt=0),dt===void 0&&(dt=1/0),this._name=It,this._defaultValue=et,this._minimum=nt,this._maximum=dt}Object.defineProperty(Cn.prototype,"name",{get:function(){return this._name},set:function(It){if(typeof It!="string"||It==="")throw new Error("Shape name must be a valid string.");this._name=It}}),Object.defineProperty(Cn.prototype,"defaultValue",{get:function(){return this._defaultValue},set:function(It){if(typeof It!="number"||isNaN(It))throw new Error("The default value must be a real number, not: "+It);this._defaultValue=It}}),Object.defineProperty(Cn.prototype,"minimum",{get:function(){return this._minimum},set:function(It){if(typeof It!="number"||isNaN(It))throw new Error("Minimum must be a real number, not: "+It);this._minimum=It}}),Object.defineProperty(Cn.prototype,"maximum",{get:function(){return this._maximum},set:function(It){if(typeof It!="number"||isNaN(It))throw new Error("Maximum must be a real number, not: "+It);this._maximum=It}}),go.Shape._FigureParameters={},go.Shape.getFigureParameter=function(It,et){var nt=go.Shape._FigureParameters[It];return nt?nt[et]:null},go.Shape.setFigureParameter=function(It,et,nt){if(!(nt instanceof Cn))throw new Error("Third argument to Shape.setFigureParameter is not FigureParameter: "+nt);if(nt.defaultValuent.maximum)throw new Error("defaultValue must be between minimum and maximum, not: "+nt.defaultValue);var dt=go.Shape._FigureParameters[It];dt||(dt=[],go.Shape._FigureParameters[It]=dt),dt[et]=nt};var cn=[];function wt(It,et){var nt=cn.pop();return nt===void 0?new go.Point(It,et):(nt.x=It,nt.y=et,nt)}function Ft(){var It=cn.pop();return It===void 0?new go.Point:It}function Ht(It){cn.push(It)}function oe(It,et,nt,dt,at,gt,mt,Pt,kt){kt||(kt=new go.Point);var Tt=It-nt,Dt=at-mt,$t=NaN,ie=NaN;if(Tt===0)if(Dt===0)It===nt&&($t=It,ie=et);else{var Yt=(gt-Pt)/Dt,fe=gt-Yt*at;$t=It,ie=Yt*$t+fe}else if(Dt===0){var Zt=(et-dt)/Tt,je=et-Zt*It;$t=at,ie=Zt*$t+je}else{var Zt=(et-dt)/Tt,Yt=(gt-Pt)/Dt,je=et-Zt*It,fe=gt-Yt*at;$t=(fe-je)/(Zt-Yt),ie=Zt*$t+je}return kt.x=$t,kt.y=ie,kt}function ke(It,et,nt,dt,at,gt,mt,Pt,kt,Tt,Dt,$t,ie,Yt){var fe=1-kt,Zt=kt,je=It*fe+nt*Zt,me=et*fe+dt*Zt,Xe=nt*fe+at*Zt,Se=dt*fe+gt*Zt,Ie=at*fe+mt*Zt,ze=gt*fe+Pt*Zt,Ue=je*fe+Xe*Zt,se=me*fe+Se*Zt,jt=Xe*fe+Ie*Zt,$e=Se*fe+ze*Zt,xn=Ue*fe+jt*Zt,En=se*fe+$e*Zt;Tt.x=je,Tt.y=me,Dt.x=Ue,Dt.y=se,$t.x=xn,$t.y=En,ie.x=jt,ie.y=$e,Yt.x=Ie,Yt.y=ze}var Vt=new go.Spot(.156,.156),qt=new go.Spot(.844,.844),Nt=4*((Math.sqrt(2)-1)/3);go.Shape.setFigureParameter("RoundedRectangle",0,new Cn("CornerRounding",5)),go.Shape.defineFigureGenerator("RoundedRectangle",function(It,et,nt){var dt=It?It.parameter1:NaN;(isNaN(dt)||dt<0)&&(dt=5),dt=Math.min(dt,et/3),dt=Math.min(dt,nt/3);var at=dt*Nt,gt=new go.Geometry().add(new go.PathFigure(dt,0,!0).add(new go.PathSegment(go.PathSegment.Line,et-dt,0)).add(new go.PathSegment(go.PathSegment.Bezier,et,dt,et-at,0,et,at)).add(new go.PathSegment(go.PathSegment.Line,et,nt-dt)).add(new go.PathSegment(go.PathSegment.Bezier,et-dt,nt,et,nt-at,et-at,nt)).add(new go.PathSegment(go.PathSegment.Line,dt,nt)).add(new go.PathSegment(go.PathSegment.Bezier,0,nt-dt,at,nt,0,nt-at)).add(new go.PathSegment(go.PathSegment.Line,0,dt)).add(new go.PathSegment(go.PathSegment.Bezier,dt,0,0,at,at,0).close()));return at>1&&(gt.spot1=new go.Spot(0,0,at,at),gt.spot2=new go.Spot(1,1,-at,-at)),gt}),go.Shape.defineFigureGenerator("Border","RoundedRectangle"),go.Shape.defineFigureGenerator("TriangleRight",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())).setSpots(0,.25,.5,.75)}),go.Shape.defineFigureGenerator("TriangleDown",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,.5*et,nt).close())).setSpots(.25,0,.75,.5)}),go.Shape.defineFigureGenerator("TriangleLeft",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(et,nt).add(new go.PathSegment(go.PathSegment.Line,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,et,0).close())).setSpots(.5,.25,1,.75)}),go.Shape.defineFigureGenerator("TriangleUp",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(et,nt).add(new go.PathSegment(go.PathSegment.Line,0,nt)).add(new go.PathSegment(go.PathSegment.Line,.5*et,0).close())).setSpots(.25,.5,.75,1)}),go.Shape.defineFigureGenerator("Triangle","TriangleUp"),go.Shape.defineFigureGenerator("Diamond",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(.5*et,0).add(new go.PathSegment(go.PathSegment.Line,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt).close())).setSpots(.25,.25,.75,.75)}),go.Shape.defineFigureGenerator("LineH",function(It,et,nt){var dt=new go.Geometry(go.Geometry.Line);return dt.startX=0,dt.startY=nt/2,dt.endX=et,dt.endY=nt/2,dt}),go.Shape.defineFigureGenerator("LineV",function(It,et,nt){var dt=new go.Geometry(go.Geometry.Line);return dt.startX=et/2,dt.startY=0,dt.endX=et/2,dt.endY=nt,dt}),go.Shape.defineFigureGenerator("BarH","Rectangle"),go.Shape.defineFigureGenerator("BarV","Rectangle"),go.Shape.defineFigureGenerator("MinusLine","LineH"),go.Shape.defineFigureGenerator("PlusLine",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,nt/2,!1).add(new go.PathSegment(go.PathSegment.Line,et,nt/2)).add(new go.PathSegment(go.PathSegment.Move,et/2,0)).add(new go.PathSegment(go.PathSegment.Line,et/2,nt)))}),go.Shape.defineFigureGenerator("XLine",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,nt,!1).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Move,0,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt)))}),go.Shape.defineFigureGenerator("LineRight",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(.25*et,0,!1).add(new go.PathSegment(go.PathSegment.Line,.75*et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,.25*et,nt)))}),go.Shape.defineFigureGenerator("LineDown",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,.25*nt,!1).add(new go.PathSegment(go.PathSegment.Line,.5*et,.75*nt)).add(new go.PathSegment(go.PathSegment.Line,et,.25*nt)))}),go.Shape.defineFigureGenerator("LineLeft",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(.75*et,0,!1).add(new go.PathSegment(go.PathSegment.Line,.25*et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,.75*et,nt)))}),go.Shape.defineFigureGenerator("LineUp",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,.75*nt,!1).add(new go.PathSegment(go.PathSegment.Line,.5*et,.25*nt)).add(new go.PathSegment(go.PathSegment.Line,et,.75*nt)))}),go.Shape.defineFigureGenerator("AsteriskLine",function(It,et,nt){var dt=.2/Math.SQRT2;return new go.Geometry().add(new go.PathFigure(dt*et,(1-dt)*nt,!1).add(new go.PathSegment(go.PathSegment.Line,(1-dt)*et,dt*nt)).add(new go.PathSegment(go.PathSegment.Move,dt*et,dt*nt)).add(new go.PathSegment(go.PathSegment.Line,(1-dt)*et,(1-dt)*nt)).add(new go.PathSegment(go.PathSegment.Move,0,nt/2)).add(new go.PathSegment(go.PathSegment.Line,et,nt/2)).add(new go.PathSegment(go.PathSegment.Move,et/2,0)).add(new go.PathSegment(go.PathSegment.Line,et/2,nt)))}),go.Shape.defineFigureGenerator("CircleLine",function(It,et,nt){var dt=et/2,at=new go.Geometry().add(new go.PathFigure(et,et/2,!1).add(new go.PathSegment(go.PathSegment.Arc,0,360,dt,dt,dt,dt).close()));return at.spot1=Vt,at.spot2=qt,at.defaultStretch=go.GraphObject.Uniform,at}),go.Shape.defineFigureGenerator("Line1",function(It,et,nt){var dt=new go.Geometry(go.Geometry.Line);return dt.startX=0,dt.startY=0,dt.endX=et,dt.endY=nt,dt}),go.Shape.defineFigureGenerator("Line2",function(It,et,nt){var dt=new go.Geometry(go.Geometry.Line);return dt.startX=et,dt.startY=0,dt.endX=0,dt.endY=nt,dt}),go.Shape.defineFigureGenerator("Curve1",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Bezier,et,nt,Nt*et,0,et,(1-Nt)*nt)))}),go.Shape.defineFigureGenerator("Curve2",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Bezier,et,nt,0,Nt*nt,(1-Nt)*et,nt)))}),go.Shape.defineFigureGenerator("Curve3",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(et,0,!1).add(new go.PathSegment(go.PathSegment.Bezier,0,nt,et,Nt*nt,Nt*et,nt)))}),go.Shape.defineFigureGenerator("Curve4",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(et,0,!1).add(new go.PathSegment(go.PathSegment.Bezier,0,nt,(1-Nt)*et,0,0,(1-Nt)*nt)))}),go.Shape.defineFigureGenerator("TriangleDownLeft",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())).setSpots(0,.5,.5,1)}),go.Shape.defineFigureGenerator("TriangleDownRight",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(et,0,!0).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())).setSpots(.5,.5,1,1)}),go.Shape.defineFigureGenerator("TriangleUpLeft",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())).setSpots(0,0,.5,.5)}),go.Shape.defineFigureGenerator("TriangleUpRight",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt).close())).setSpots(.5,0,1,.5)}),go.Shape.defineFigureGenerator("RightTriangle","TriangleDownLeft"),go.Shape.setFigureParameter("Parallelogram1",0,new Cn("Indent",.1,-.99,.99)),go.Shape.defineFigureGenerator("Parallelogram1",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)?dt=.1:dt<-1?dt=-1:dt>1&&(dt=1);var at=Math.abs(dt)*et;if(dt===0){var gt=new go.Geometry(go.Geometry.Rectangle);return gt.startX=0,gt.startY=0,gt.endX=et,gt.endY=nt,gt}else{var gt=new go.Geometry;return dt>0?gt.add(new go.PathFigure(at,0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et-at,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())):gt.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,et-at,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,at,nt).close())),atet&&(dt=et);var at=Math.abs(dt);if(dt===0){var gt=new go.Geometry(go.Geometry.Rectangle);return gt.startX=0,gt.startY=0,gt.endX=et,gt.endY=nt,gt}else{var gt=new go.Geometry;return dt>0?gt.add(new go.PathFigure(at,0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et-at,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())):gt.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,et-at,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,at,nt).close())),at.5&&(dt=.5);var at=Math.abs(dt)*et;if(dt===0){var gt=new go.Geometry(go.Geometry.Rectangle);return gt.startX=0,gt.startY=0,gt.endX=et,gt.endY=nt,gt}else{var gt=new go.Geometry;return dt>0?gt.add(new go.PathFigure(at,0).add(new go.PathSegment(go.PathSegment.Line,et-at,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())):gt.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et-at,nt)).add(new go.PathSegment(go.PathSegment.Line,at,nt).close())),atet&&(dt=et/2);var at=Math.abs(dt);if(dt===0){var gt=new go.Geometry(go.Geometry.Rectangle);return gt.startX=0,gt.startY=0,gt.endX=et,gt.endY=nt,gt}else{var gt=new go.Geometry;return dt>0?gt.add(new go.PathFigure(at,0).add(new go.PathSegment(go.PathSegment.Line,et-at,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())):gt.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et-at,nt)).add(new go.PathSegment(go.PathSegment.Line,at,nt).close())),atet&&(dt=et/2);var at=Math.abs(dt);if(dt===0){var gt=new go.Geometry(go.Geometry.Rectangle);return gt.startX=0,gt.startY=0,gt.endX=et,gt.endY=nt,gt}else{var gt=new go.Geometry;return dt>0?gt.add(new go.PathFigure(0,0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et-at,nt)).add(new go.PathSegment(go.PathSegment.Line,at,nt).close())):gt.add(new go.PathFigure(at,0).add(new go.PathSegment(go.PathSegment.Line,et-at,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close())),at0&&(mt.add(new go.PathSegment(go.PathSegment.Move,et/2+Pt,et/2)),mt.add(new go.PathSegment(go.PathSegment.Arc,0,-360,at,at,Pt,Pt).close())),gt.spot1=Vt,gt.spot2=qt,gt.defaultStretch=go.GraphObject.Uniform,gt}),go.Shape.defineFigureGenerator("Cloud",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(.08034461*et,.1944299*nt,!0).add(new go.PathSegment(go.PathSegment.Bezier,.2008615*et,.05349299*nt,-.09239631*et,.07836421*nt,.1406031*et,-.0542823*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.4338609*et,.074219*nt,.2450511*et,-.00697547*nt,.3776197*et,-.01112067*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.6558228*et,.07004196*nt,.4539471*et,0,.6066018*et,-.02526587*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.8921095*et,.08370865*nt,.6914277*et,-.01904177*nt,.8921095*et,-.01220843*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.9147671*et,.3194596*nt,1.036446*et,.04105738*nt,1.020377*et,.3022052*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.9082935*et,.562044*nt,1.04448*et,.360238*nt,.992256*et,.5219009*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.9212406*et,.8217117*nt,1.032337*et,.5771781*nt,1.018411*et,.8120651*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.7592566*et,.9156953*nt,1.028411*et,.9571472*nt,.8556702*et,1.052487*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.5101666*et,.9310455*nt,.7431877*et,1.009325*nt,.5624123*et,1.021761*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.2609328*et,.9344623*nt,.4820677*et,1.031761*nt,.3030112*et,1.002796*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.08034461*et,.870098*nt,.2329994*et,1.01518*nt,.03213784*et,1.01518*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.06829292*et,.6545475*nt,-.02812061*et,.9032597*nt,-.01205169*et,.6835638*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.06427569*et,.4265613*nt,-.01812061*et,.6089503*nt,-.00606892*et,.4555777*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.08034461*et,.1944299*nt,-.01606892*et,.3892545*nt,-.01205169*et,.1944299*nt))).setSpots(.1,.1,.9,.9)}),go.Shape.defineFigureGenerator("StopSign",function(It,et,nt){var dt=1/(Math.SQRT2+2);return new go.Geometry().add(new go.PathFigure(dt*et,0,!0).add(new go.PathSegment(go.PathSegment.Line,(1-dt)*et,0)).add(new go.PathSegment(go.PathSegment.Line,et,dt*nt)).add(new go.PathSegment(go.PathSegment.Line,et,(1-dt)*nt)).add(new go.PathSegment(go.PathSegment.Line,(1-dt)*et,nt)).add(new go.PathSegment(go.PathSegment.Line,dt*et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,(1-dt)*nt)).add(new go.PathSegment(go.PathSegment.Line,0,dt*nt).close())).setSpots(dt/2,dt/2,1-dt/2,1-dt/2)}),go.Shape.setFigureParameter("Pie",0,new Cn("Start",0,-360,360)),go.Shape.setFigureParameter("Pie",1,new Cn("Sweep",315,-360,360)),go.Shape.defineFigureGenerator("Pie",function(It,et,nt){var dt=It?It.parameter1:NaN,at=It?It.parameter2:NaN;isNaN(dt)&&(dt=0),isNaN(at)&&(at=315);var gt=dt%360;gt<0&&(gt+=360);var mt=at%360,Pt=Math.min(et,nt)/2;return new go.Geometry().add(new go.PathFigure(Pt,Pt).add(new go.PathSegment(go.PathSegment.Arc,gt,mt,Pt,Pt,Pt,Pt).close()))}),go.Shape.defineFigureGenerator("PiePiece",function(It,et,nt){var dt=Nt/Math.SQRT2*.5,at=Math.SQRT2/2,gt=1-Math.SQRT2/2;return new go.Geometry().add(new go.PathFigure(et,nt,!0).add(new go.PathSegment(go.PathSegment.Bezier,at*et,gt*nt,et,(1-dt)*nt,(at+dt)*et,(gt+dt)*nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close()))}),go.Shape.setFigureParameter("ThickCross",0,new Cn("Thickness",30)),go.Shape.defineFigureGenerator("ThickCross",function(It,et,nt){var dt=It?It.parameter1:NaN;(isNaN(dt)||dt<0)&&(dt=30);var at=Math.min(dt,et)/2,gt=et/2,mt=nt/2;return new go.Geometry().add(new go.PathFigure(gt-at,0,!0).add(new go.PathSegment(go.PathSegment.Line,gt+at,0)).add(new go.PathSegment(go.PathSegment.Line,gt+at,mt-at)).add(new go.PathSegment(go.PathSegment.Line,et,mt-at)).add(new go.PathSegment(go.PathSegment.Line,et,mt+at)).add(new go.PathSegment(go.PathSegment.Line,gt+at,mt+at)).add(new go.PathSegment(go.PathSegment.Line,gt+at,nt)).add(new go.PathSegment(go.PathSegment.Line,gt-at,nt)).add(new go.PathSegment(go.PathSegment.Line,gt-at,mt+at)).add(new go.PathSegment(go.PathSegment.Line,0,mt+at)).add(new go.PathSegment(go.PathSegment.Line,0,mt-at)).add(new go.PathSegment(go.PathSegment.Line,gt-at,mt-at).close()))}),go.Shape.setFigureParameter("ThinCross",0,new Cn("Thickness",10)),go.Shape.defineFigureGenerator("ThinCross",function(It,et,nt){var dt=It?It.parameter1:NaN;(isNaN(dt)||dt<0)&&(dt=10);var at=Math.min(dt,et)/2,gt=et/2,mt=nt/2;return new go.Geometry().add(new go.PathFigure(gt-at,0,!0).add(new go.PathSegment(go.PathSegment.Line,gt+at,0)).add(new go.PathSegment(go.PathSegment.Line,gt+at,mt-at)).add(new go.PathSegment(go.PathSegment.Line,et,mt-at)).add(new go.PathSegment(go.PathSegment.Line,et,mt+at)).add(new go.PathSegment(go.PathSegment.Line,gt+at,mt+at)).add(new go.PathSegment(go.PathSegment.Line,gt+at,nt)).add(new go.PathSegment(go.PathSegment.Line,gt-at,nt)).add(new go.PathSegment(go.PathSegment.Line,gt-at,mt+at)).add(new go.PathSegment(go.PathSegment.Line,0,mt+at)).add(new go.PathSegment(go.PathSegment.Line,0,mt-at)).add(new go.PathSegment(go.PathSegment.Line,gt-at,mt-at).close()))}),go.Shape.setFigureParameter("ThickX",0,new Cn("Thickness",30)),go.Shape.defineFigureGenerator("ThickX",function(It,et,nt){var dt=It?It.parameter1:NaN;if((isNaN(dt)||dt<0)&&(dt=30),et===0||nt===0){var at=new go.Geometry(go.Geometry.Rectangle);return at.startX=0,at.startY=0,at.endX=et,at.endY=nt,at}else{var gt=et/2,mt=nt/2,Pt=Math.atan2(nt,et),kt=dt-Math.min(Math.cos(Pt)*dt/2,gt),Tt=dt-Math.min(Math.sin(Pt)*dt/2,mt),at=new go.Geometry,Dt=new go.PathFigure(kt,0,!0);return at.add(Dt),Dt.add(new go.PathSegment(go.PathSegment.Line,gt,.2*nt)),Dt.add(new go.PathSegment(go.PathSegment.Line,et-kt,0)),Dt.add(new go.PathSegment(go.PathSegment.Line,et,Tt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.8*et,mt)),Dt.add(new go.PathSegment(go.PathSegment.Line,et,nt-Tt)),Dt.add(new go.PathSegment(go.PathSegment.Line,et-kt,nt)),Dt.add(new go.PathSegment(go.PathSegment.Line,gt,.8*nt)),Dt.add(new go.PathSegment(go.PathSegment.Line,kt,nt)),Dt.add(new go.PathSegment(go.PathSegment.Line,0,nt-Tt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.2*et,mt)),Dt.add(new go.PathSegment(go.PathSegment.Line,0,Tt).close()),at}}),go.Shape.setFigureParameter("ThinX",0,new Cn("Thickness",10)),go.Shape.defineFigureGenerator("ThinX",function(It,et,nt){var dt=It?It.parameter1:NaN;(isNaN(dt)||dt<0)&&(dt=10);var at=new go.Geometry,gt=new go.PathFigure(.1*et,0,!0);return at.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.9*et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,.1*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.6*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,.9*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.9*et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.1*et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,.9*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.4*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,.1*nt).close()),at}),go.Shape.setFigureParameter("SquareIBeam",0,new Cn("BeamWidth",.2,.1,.9)),go.Shape.defineFigureGenerator("SquareIBeam",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.2);var at=new go.Geometry,gt=new go.PathFigure(0,0,!0);return at.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,dt*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(.5+dt/2)*et,dt*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(.5+dt/2)*et,(1-dt)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,(1-dt)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,(1-dt)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(.5-dt/2)*et,(1-dt)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(.5-dt/2)*et,dt*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,dt*nt).close()),at}),go.Shape.setFigureParameter("RoundedIBeam",0,new Cn("Curviness",.5,.05,.65)),go.Shape.defineFigureGenerator("RoundedIBeam",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.5);var at=new go.Geometry,gt=new go.PathFigure(0,0,!0);return at.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Bezier,et,nt,Math.abs(1-dt)*et,.25*nt,Math.abs(1-dt)*et,.75*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,0,0,dt*et,.75*nt,dt*et,.25*nt).close()),at}),go.Shape.defineFigureGenerator("HalfEllipse",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,Nt*et,0,et,(.5-Nt/2)*nt)).add(new go.PathSegment(go.PathSegment.Bezier,0,nt,et,(.5+Nt/2)*nt,Nt*et,nt).close())).setSpots(0,.156,.844,.844)}),go.Shape.defineFigureGenerator("Crescent",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Bezier,0,nt,et,0,et,nt)).add(new go.PathSegment(go.PathSegment.Bezier,0,0,.5*et,.75*nt,.5*et,.25*nt).close())).setSpots(.311,.266,.744,.744)}),go.Shape.defineFigureGenerator("Heart",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(.5*et,nt,!0).add(new go.PathSegment(go.PathSegment.Bezier,0,.3*nt,.1*et,.8*nt,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.3*nt,0,0,.45*et,0)).add(new go.PathSegment(go.PathSegment.Bezier,et,.3*nt,.55*et,0,et,0)).add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt,et,.5*nt,.9*et,.8*nt).close())).setSpots(.14,.29,.86,.78)}),go.Shape.defineFigureGenerator("Spade",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(.5*et,0,!0).add(new go.PathSegment(go.PathSegment.Line,.51*et,.01*nt)).add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,.6*et,.2*nt,et,.25*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.55*et,.7*nt,et,.8*nt,.6*et,.8*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.75*et,nt,.5*et,.75*nt,.55*et,.95*nt)).add(new go.PathSegment(go.PathSegment.Line,.25*et,nt)).add(new go.PathSegment(go.PathSegment.Bezier,.45*et,.7*nt,.45*et,.95*nt,.5*et,.75*nt)).add(new go.PathSegment(go.PathSegment.Bezier,0,.5*nt,.4*et,.8*nt,0,.8*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.49*et,.01*nt,0,.25*nt,.4*et,.2*nt).close())).setSpots(.14,.26,.86,.78)}),go.Shape.defineFigureGenerator("Club",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.4*et,.6*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Bezier,.15*et,nt,.5*et,.75*nt,.45*et,.95*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.85*et,nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.6*et,.6*nt,.55*et,.95*nt,.5*et,.75*nt));var gt=.2,mt=.3,Pt=0,kt=gt*Nt;return at.add(new go.PathSegment(go.PathSegment.Bezier,(.5+mt)*et,(.5+gt+Pt)*nt,(.5-gt+mt)*et,(.5+kt+Pt)*nt,(.5-kt+mt)*et,(.5+gt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,(1-.5+gt+mt)*et,(.5+Pt)*nt,(.5+kt+mt)*et,(.5+gt+Pt)*nt,(.5+gt+mt)*et,(.5+kt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,(.5+mt)*et,(.5-gt+Pt)*nt,(1-.5+gt+mt)*et,(.5-kt+Pt)*nt,(.5+kt+mt)*et,(.5-gt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.65*et,.36771243*nt,(.5-kt+mt)*et,(.5-gt+Pt)*nt,(.5-gt+mt+.05)*et,(.5-kt+Pt-.02)*nt)),gt=.2,mt=0,Pt=-.3,kt=gt*Nt,at.add(new go.PathSegment(go.PathSegment.Bezier,(1-.5+gt+mt)*et,(.5+Pt)*nt,(.5+kt+mt)*et,(.5+gt+Pt)*nt,(.5+gt+mt)*et,(.5+kt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,(.5+mt)*et,(.5-gt+Pt)*nt,(1-.5+gt+mt)*et,(.5-kt+Pt)*nt,(.5+kt+mt)*et,(.5-gt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,(.5-gt+mt)*et,(.5+Pt)*nt,(.5-kt+mt)*et,(.5-gt+Pt)*nt,(.5-gt+mt)*et,(.5-kt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,(.5-kt+mt)*et,(.5+gt+Pt)*nt,(.5-gt+mt)*et,(.5+kt+Pt)*nt,(.5-kt+mt)*et,(.5+gt+Pt)*nt)),gt=.2,mt=-.3,Pt=0,kt=gt*Nt,at.add(new go.PathSegment(go.PathSegment.Bezier,(.5+mt)*et,(.5-gt+Pt)*nt,(1-.5+gt+mt-.05)*et,(.5-kt+Pt-.02)*nt,(.5+kt+mt)*et,(.5-gt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,(.5-gt+mt)*et,(.5+Pt)*nt,(.5-kt+mt)*et,(.5-gt+Pt)*nt,(.5-gt+mt)*et,(.5-kt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,(.5+mt)*et,(.5+gt+Pt)*nt,(.5-gt+mt)*et,(.5+kt+Pt)*nt,(.5-kt+mt)*et,(.5+gt+Pt)*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.4*et,.6*nt,(.5+kt+mt)*et,(.5+gt+Pt)*nt,(.5+gt+mt)*et,(.5+kt+Pt)*nt).close()),dt.setSpots(.06,.33,.93,.68),dt}),go.Shape.defineFigureGenerator("YinYang",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*.5,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Arc,270,180,et*.5,et*.5,et*.5,et*.5)),at.add(new go.PathSegment(go.PathSegment.Arc,90,-180,et*.5,et*.75,et*.25,et*.25)),at.add(new go.PathSegment(go.PathSegment.Arc,90,180,et*.5,et*.25,et*.25,et*.25));var gt=.1,mt=.5,Pt=.25;return at.add(new go.PathSegment(go.PathSegment.Move,(mt+gt)*et,Pt*nt)),at.add(new go.PathSegment(go.PathSegment.Arc,0,-360,et*mt,nt*Pt,gt*et,gt*et).close()),at=new go.PathFigure(et*.5,0,!1),dt.add(at),at.add(new go.PathSegment(go.PathSegment.Arc,270,-180,et*.5,et*.5,et*.5,et*.5)),Pt=.75,at=new go.PathFigure((mt+gt)*et,Pt*nt,!0),dt.add(at),at.add(new go.PathSegment(go.PathSegment.Arc,0,360,et*mt,nt*Pt,gt*et,gt*et).close()),dt.defaultStretch=go.GraphObject.Uniform,dt}),go.Shape.defineFigureGenerator("Peace",function(It,et,nt){var dt=.8535533905932737,at=.5*et,gt=.5*nt;return new go.Geometry().add(new go.PathFigure(at,0,!1).add(new go.PathSegment(go.PathSegment.Arc,270,360,at,gt,at,gt)).add(new go.PathSegment(go.PathSegment.Line,at,nt)).add(new go.PathSegment(go.PathSegment.Move,at,gt)).add(new go.PathSegment(go.PathSegment.Line,(1-dt)*et,dt*nt)).add(new go.PathSegment(go.PathSegment.Move,at,gt)).add(new go.PathSegment(go.PathSegment.Line,dt*et,dt*nt)))}),go.Shape.defineFigureGenerator("NotAllowed",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=.5,mt=.5,Pt=.5,kt=new go.PathFigure(mt*et,(Pt-gt)*nt);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-gt)*et,Pt*nt,(mt-at)*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+gt)*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,Pt*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-gt)*nt,(mt+gt)*et,(Pt-at)*nt,(mt+at)*et,(Pt-gt)*nt)),gt=.4,at=Nt*.4;var Tt=Ft(),Dt=Ft(),$t=Ft(),ie=Ft();ke(mt,Pt-gt,mt+at,Pt-gt,mt+gt,Pt-at,mt+gt,Pt,.42,Tt,Dt,$t,ie,ie);var Yt=Ft(),fe=Ft(),Zt=Ft();ke(mt,Pt-gt,mt+at,Pt-gt,mt+gt,Pt-at,mt+gt,Pt,.58,ie,ie,Zt,Yt,fe);var je=Ft(),me=Ft(),Xe=Ft();ke(mt,Pt+gt,mt-at,Pt+gt,mt-gt,Pt+at,mt-gt,Pt,.42,je,me,Xe,ie,ie);var Se=Ft(),Ie=Ft(),ze=Ft();return ke(mt,Pt+gt,mt-at,Pt+gt,mt-gt,Pt+at,mt-gt,Pt,.58,ie,ie,ze,Se,Ie),kt.add(new go.PathSegment(go.PathSegment.Move,ze.x*et,ze.y*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-gt)*et,Pt*nt,Se.x*et,Se.y*nt,Ie.x*et,Ie.y*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,$t.x*et,$t.y*nt,Tt.x*et,Tt.y*nt,Dt.x*et,Dt.y*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,ze.x*et,ze.y*nt).close()),kt.add(new go.PathSegment(go.PathSegment.Move,Xe.x*et,Xe.y*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,Zt.x*et,Zt.y*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,Pt*nt,Yt.x*et,Yt.y*nt,fe.x*et,fe.y*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,Xe.x*et,Xe.y*nt,je.x*et,je.y*nt,me.x*et,me.y*nt).close()),Ht(Tt),Ht(Dt),Ht($t),Ht(ie),Ht(Yt),Ht(fe),Ht(Zt),Ht(je),Ht(me),Ht(Xe),Ht(Se),Ht(Ie),Ht(ze),dt.defaultStretch=go.GraphObject.Uniform,dt}),go.Shape.defineFigureGenerator("Fragile",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,.25*et,0)).add(new go.PathSegment(go.PathSegment.Line,.2*et,.15*nt)).add(new go.PathSegment(go.PathSegment.Line,.3*et,.25*nt)).add(new go.PathSegment(go.PathSegment.Line,.29*et,.33*nt)).add(new go.PathSegment(go.PathSegment.Line,.35*et,.25*nt)).add(new go.PathSegment(go.PathSegment.Line,.3*et,.15*nt)).add(new go.PathSegment(go.PathSegment.Line,.4*et,0)).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Bezier,.55*et,.5*nt,et,.25*nt,.75*et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,.55*et,.9*nt)).add(new go.PathSegment(go.PathSegment.Line,.7*et,.9*nt)).add(new go.PathSegment(go.PathSegment.Line,.7*et,nt)).add(new go.PathSegment(go.PathSegment.Line,.3*et,nt)).add(new go.PathSegment(go.PathSegment.Line,.3*et,.9*nt)).add(new go.PathSegment(go.PathSegment.Line,.45*et,.9*nt)).add(new go.PathSegment(go.PathSegment.Line,.45*et,.5*nt)).add(new go.PathSegment(go.PathSegment.Bezier,0,0,.25*et,.5*nt,0,.25*nt).close()))}),go.Shape.setFigureParameter("HourGlass",0,new Cn("Thickness",30)),go.Shape.defineFigureGenerator("HourGlass",function(It,et,nt){var dt=It?It.parameter1:NaN;(isNaN(dt)||dt<0)&&(dt=30),dt>et&&(dt=et);var at=(et-dt)/2,gt=at+dt;return new go.Geometry().add(new go.PathFigure(gt,.5*nt).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt)).add(new go.PathSegment(go.PathSegment.Line,at,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,0,0)).add(new go.PathSegment(go.PathSegment.Line,et,0).close()))}),go.Shape.defineFigureGenerator("Lightning",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,.55*nt).add(new go.PathSegment(go.PathSegment.Line,.6*et,0)).add(new go.PathSegment(go.PathSegment.Line,.3*et,.45*nt)).add(new go.PathSegment(go.PathSegment.Line,et,.45*nt)).add(new go.PathSegment(go.PathSegment.Line,.4*et,nt)).add(new go.PathSegment(go.PathSegment.Line,.7*et,.55*nt).close()))}),go.Shape.defineFigureGenerator("GenderMale",function(It,et,nt){var dt=new go.Geometry,at=Nt*.4,gt=.4,mt=.5,Pt=.5,kt=Ft(),Tt=Ft(),Dt=Ft(),$t=Ft(),ie=new go.PathFigure((mt-gt)*et,Pt*nt,!1);dt.add(ie),ie.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt)),ke(mt,Pt-gt,mt+at,Pt-gt,mt+gt,Pt-at,mt+gt,Pt,.44,Dt,$t,Tt,kt,kt),ie.add(new go.PathSegment(go.PathSegment.Bezier,Tt.x*et,Tt.y*nt,Dt.x*et,Dt.y*nt,$t.x*et,$t.y*nt));var Yt=wt(Tt.x,Tt.y);ke(mt,Pt-gt,mt+at,Pt-gt,mt+gt,Pt-at,mt+gt,Pt,.56,kt,kt,Tt,Dt,$t);var fe=wt(Tt.x,Tt.y);ie.add(new go.PathSegment(go.PathSegment.Line,(Yt.x*.1+.95*.9)*et,Yt.y*.1*nt)),ie.add(new go.PathSegment(go.PathSegment.Line,.85*et,Yt.y*.1*nt)),ie.add(new go.PathSegment(go.PathSegment.Line,.85*et,0)),ie.add(new go.PathSegment(go.PathSegment.Line,et,0)),ie.add(new go.PathSegment(go.PathSegment.Line,et,.15*nt)),ie.add(new go.PathSegment(go.PathSegment.Line,(fe.x*.1+.9)*et,.15*nt)),ie.add(new go.PathSegment(go.PathSegment.Line,(fe.x*.1+.9)*et,(fe.y*.1+.05*.9)*nt)),ie.add(new go.PathSegment(go.PathSegment.Line,fe.x*et,fe.y*nt)),ie.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,Pt*nt,Dt.x*et,Dt.y*nt,$t.x*et,$t.y*nt)),ie.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt)),ie.add(new go.PathSegment(go.PathSegment.Bezier,(mt-gt)*et,Pt*nt,(mt-at)*et,(Pt+gt)*nt,(mt-gt)*et,(Pt+at)*nt)),gt=.35,at=Nt*.35;var Zt=new go.PathFigure(mt*et,(Pt-gt)*nt,!1);dt.add(Zt),Zt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-gt)*et,Pt*nt,(mt-at)*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt)),Zt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+gt)*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt)),Zt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,Pt*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),Zt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-gt)*nt,(mt+gt)*et,(Pt-at)*nt,(mt+at)*et,(Pt-gt)*nt));var je=new go.PathFigure((mt-gt)*et,Pt*nt,!1);return dt.add(je),Ht(kt),Ht(Tt),Ht(Dt),Ht($t),Ht(Yt),Ht(fe),dt.spot1=new go.Spot(.202,.257),dt.spot2=new go.Spot(.792,.739),dt.defaultStretch=go.GraphObject.Uniform,dt}),go.Shape.defineFigureGenerator("GenderFemale",function(It,et,nt){var dt=new go.Geometry,at=.375,gt=0,mt=-.125,Pt=at*Nt,kt=new go.PathFigure((.525+gt)*et,(.5+at+mt)*nt,!1);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,(1-.5+at+gt)*et,(.5+mt)*nt,(.5+Pt+gt)*et,(.5+at+mt)*nt,(.5+at+gt)*et,(.5+Pt+mt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(.5+gt)*et,(.5-at+mt)*nt,(1-.5+at+gt)*et,(.5-Pt+mt)*nt,(.5+Pt+gt)*et,(.5-at+mt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(.5-at+gt)*et,(.5+mt)*nt,(.5-Pt+gt)*et,(.5-at+mt)*nt,(.5-at+gt)*et,(.5-Pt+mt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(.475+gt)*et,(.5+at+mt)*nt,(.5-at+gt)*et,(.5+Pt+mt)*nt,(.5-Pt+gt)*et,(.5+at+mt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.475*et,.85*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.425*et,.85*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.425*et,.9*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.475*et,.9*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.475*et,nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.525*et,nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.525*et,.9*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.575*et,.9*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.575*et,.85*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.525*et,.85*nt).close()),at=.325,gt=0,mt=-.125,Pt=at*Nt;var kt=new go.PathFigure((1-.5+at+gt)*et,(.5+mt)*nt,!1);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,(.5+gt)*et,(.5+at+mt)*nt,(.5+at+gt)*et,(.5+Pt+mt)*nt,(.5+Pt+gt)*et,(.5+at+mt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(.5-at+gt)*et,(.5+mt)*nt,(.5-Pt+gt)*et,(.5+at+mt)*nt,(.5-at+gt)*et,(.5+Pt+mt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(.5+gt)*et,(.5-at+mt)*nt,(.5-at+gt)*et,(.5-Pt+mt)*nt,(.5-Pt+gt)*et,(.5-at+mt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(1-.5+at+gt)*et,(.5+mt)*nt,(.5+Pt+gt)*et,(.5-at+mt)*nt,(1-.5+at+gt)*et,(.5-Pt+mt)*nt));var kt=new go.PathFigure((.525+gt)*et,(.5+at+mt)*nt,!1);return dt.add(kt),dt.spot1=new go.Spot(.232,.136),dt.spot2=new go.Spot(.682,.611),dt.defaultStretch=go.GraphObject.Uniform,dt}),go.Shape.defineFigureGenerator("LogicImplies",function(It,et,nt){var dt=It?It.parameter1:NaN;return isNaN(dt)&&(dt=.2),new go.Geometry().add(new go.PathFigure((1-dt)*et,0,!1).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,(1-dt)*et,nt)).add(new go.PathSegment(go.PathSegment.Move,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt))).setSpots(0,0,.8,.5)}),go.Shape.defineFigureGenerator("LogicIff",function(It,et,nt){var dt=It?It.parameter1:NaN;return isNaN(dt)&&(dt=.2),new go.Geometry().add(new go.PathFigure((1-dt)*et,0,!1).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,(1-dt)*et,nt)).add(new go.PathSegment(go.PathSegment.Move,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)).add(new go.PathSegment(go.PathSegment.Move,dt*et,0)).add(new go.PathSegment(go.PathSegment.Line,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,dt*et,nt))).setSpots(.2,0,.8,.5)}),go.Shape.defineFigureGenerator("LogicNot",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt)))}),go.Shape.defineFigureGenerator("LogicAnd",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,nt,!1).add(new go.PathSegment(go.PathSegment.Line,.5*et,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt))).setSpots(.25,.5,.75,1)}),go.Shape.defineFigureGenerator("LogicOr",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)).add(new go.PathSegment(go.PathSegment.Line,et,0))).setSpots(.219,0,.78,.409)}),go.Shape.defineFigureGenerator("LogicXor",function(It,et,nt){var dt=new go.Geometry().add(new go.PathFigure(.5*et,0,!1).add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)).add(new go.PathSegment(go.PathSegment.Move,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)).add(new go.PathSegment(go.PathSegment.Arc,0,360,.5*et,.5*nt,.5*et,.5*nt)));return dt.defaultStretch=go.GraphObject.Uniform,dt}),go.Shape.defineFigureGenerator("LogicTruth",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Move,.5*et,0)).add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)))}),go.Shape.defineFigureGenerator("LogicFalsity",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,nt,!1).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Move,.5*et,nt)).add(new go.PathSegment(go.PathSegment.Line,.5*et,0)))}),go.Shape.defineFigureGenerator("LogicThereExists",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Move,et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt)))}),go.Shape.defineFigureGenerator("LogicForAll",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Move,.25*et,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,.75*et,.5*nt))).setSpots(.25,0,.75,.5)}),go.Shape.defineFigureGenerator("LogicIsDefinedAs",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!1).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Move,0,.5*nt)).add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)).add(new go.PathSegment(go.PathSegment.Move,0,nt)).add(new go.PathSegment(go.PathSegment.Line,et,nt))).setSpots(.01,.01,.99,.49)}),go.Shape.defineFigureGenerator("LogicIntersect",function(It,et,nt){var dt=.5;return new go.Geometry().add(new go.PathFigure(0,nt,!1).add(new go.PathSegment(go.PathSegment.Line,0,dt*nt)).add(new go.PathSegment(go.PathSegment.Arc,180,180,dt*et,dt*nt,dt*et,dt*nt)).add(new go.PathSegment(go.PathSegment.Line,et,nt))).setSpots(0,.5,1,1)}),go.Shape.defineFigureGenerator("LogicUnion",function(It,et,nt){var dt=.5;return new go.Geometry().add(new go.PathFigure(et,0,!1).add(new go.PathSegment(go.PathSegment.Line,et,dt*nt)).add(new go.PathSegment(go.PathSegment.Arc,0,180,dt*et,dt*nt,dt*et,dt*nt)).add(new go.PathSegment(go.PathSegment.Line,0,0))).setSpots(0,0,1,.5)}),go.Shape.setFigureParameter("Arrow",0,new Cn("ArrowheadWidth",.3,.01,.99)),go.Shape.setFigureParameter("Arrow",1,new Cn("TailHeight",.3,.01,.99)),go.Shape.defineFigureGenerator("Arrow",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.3);var at=It?It.parameter2:NaN;isNaN(at)&&(at=.3);var gt=(1-dt)*et,mt=(.5-at/2)*nt,Pt=(.5+at/2)*nt,kt=new go.Geometry,Tt=new go.PathFigure(0,mt,!0);kt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Line,gt,mt)),Tt.add(new go.PathSegment(go.PathSegment.Line,gt,0)),Tt.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),Tt.add(new go.PathSegment(go.PathSegment.Line,gt,nt)),Tt.add(new go.PathSegment(go.PathSegment.Line,gt,Pt)),Tt.add(new go.PathSegment(go.PathSegment.Line,0,Pt).close()),kt.spot1=new go.Spot(0,mt/nt);var Dt=oe(0,Pt/nt,1,Pt/nt,gt/et,1,1,.5,Ft());return kt.spot2=new go.Spot(Dt.x,Dt.y),Ht(Dt),kt}),go.Shape.setFigureParameter("Arrow2",0,new Cn("ArrowheadWidth",30)),go.Shape.setFigureParameter("Arrow2",0,new Cn("TailHeight",30)),go.Shape.defineFigureGenerator("Arrow2",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=30),dt>et&&(dt=et);var at=It?It.parameter2:NaN;isNaN(at)&&(at=30),at=Math.min(at,nt/2);var gt=et-dt,mt=(nt-at)/2,Pt=mt+at,kt=new go.Geometry,Tt=new go.PathFigure(0,mt,!0);kt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Line,gt,mt)),Tt.add(new go.PathSegment(go.PathSegment.Line,gt,0)),Tt.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),Tt.add(new go.PathSegment(go.PathSegment.Line,gt,nt)),Tt.add(new go.PathSegment(go.PathSegment.Line,gt,Pt)),Tt.add(new go.PathSegment(go.PathSegment.Line,0,Pt).close()),kt.spot1=new go.Spot(0,mt/nt);var Dt=oe(0,Pt/nt,1,Pt/nt,gt/et,1,1,.5,Ft());return kt.spot2=new go.Spot(Dt.x,Dt.y),Ht(Dt),kt}),go.Shape.defineFigureGenerator("Chevron",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt).close()),dt}),go.Shape.defineFigureGenerator("DoubleArrow",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,.214*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,1*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,1*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,.786*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,1*nt).close()),dt}),go.Shape.setFigureParameter("DoubleEndArrow",0,new Cn("ConnecterHeight",.3,.01,.99)),go.Shape.defineFigureGenerator("DoubleEndArrow",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.3);var at=(.5-dt/2)*nt,gt=(.5+dt/2)*nt,mt=new go.Geometry,Pt=new go.PathFigure(et,.5*nt,!0);mt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.3*et,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.3*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.3*et,0)),Pt.add(new go.PathSegment(go.PathSegment.Line,.3*et,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,0).close());var kt=oe(0,.5,.3,0,0,at/nt,.1,at/nt,Ft());return mt.spot1=new go.Spot(kt.x,kt.y),kt=oe(.7,1,1,.5,0,gt/nt,1,gt/nt,kt),mt.spot2=new go.Spot(kt.x,kt.y),Ht(kt),mt}),go.Shape.setFigureParameter("DoubleEndArrow2",0,new Cn("ConnecterHeight",40)),go.Shape.setFigureParameter("DoubleEndArrow2",1,new Cn("ArrowHeight",100)),go.Shape.defineFigureGenerator("DoubleEndArrow2",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=40);var at=It?It.parameter2:NaN;isNaN(at)&&(at=100);var gt=(nt-dt)/2,mt=gt+dt,Pt=(nt-at)/2,kt=Pt+at;(dt>nt||at>nt)&&(at>dt?(dt=dt*nt/at,gt=(nt-dt)/2,mt=gt+dt,Pt=0,kt=nt):(gt=0,mt=nt,Pt=0,kt=nt));var Tt=new go.Geometry,Dt=new go.PathFigure(et,.5*nt,!0);Tt.add(Dt),Dt.add(new go.PathSegment(go.PathSegment.Line,.7*et,kt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.7*et,mt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.3*et,mt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.3*et,kt)),Dt.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.3*et,Pt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.3*et,gt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.7*et,gt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.7*et,Pt).close());var $t=oe(0,.5,.3,Pt/nt,0,gt/nt,1,gt/nt,Ft());return Tt.spot1=new go.Spot($t.x,$t.y),$t=oe(.7,kt/nt,1,.5,0,mt/nt,1,mt/nt,$t),Tt.spot2=new go.Spot($t.x,$t.y),Ht($t),Tt}),go.Shape.setFigureParameter("IBeamArrow",0,new Cn("ConnectorHeight",.7,.51,.97)),go.Shape.defineFigureGenerator("IBeamArrow",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.3);var at=(.5-dt/2)*nt,gt=(.5+dt/2)*nt,mt=new go.Geometry,Pt=new go.PathFigure(et,.5*nt,!0);mt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.2*et,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.2*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,0,0)),Pt.add(new go.PathSegment(go.PathSegment.Line,.2*et,0)),Pt.add(new go.PathSegment(go.PathSegment.Line,.2*et,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,0).close()),mt.spot1=new go.Spot(0,at/nt);var kt=oe(.7,1,1,.5,0,gt/nt,1,gt/nt,Ft());return mt.spot2=new go.Spot(kt.x,kt.y),Ht(kt),mt}),go.Shape.setFigureParameter("IBeamArrow2",0,new Cn("ConnectorHeight",40)),go.Shape.setFigureParameter("IBeamArrow2",1,new Cn("BeamArrowHeight",100)),go.Shape.defineFigureGenerator("IBeamArrow2",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=40);var at=It?It.parameter2:NaN;isNaN(at)&&(at=100);var gt=(nt-dt)/2,mt=gt+dt,Pt=(nt-at)/2,kt=Pt+at;(dt>nt||at>nt)&&(at>dt?(dt=dt*nt/at,gt=(nt-dt)/2,mt=gt+dt,Pt=0,kt=nt):(gt=0,mt=nt,Pt=0,kt=nt));var Tt=new go.Geometry,Dt=new go.PathFigure(et,.5*nt,!0);Tt.add(Dt),Dt.add(new go.PathSegment(go.PathSegment.Line,.7*et,kt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.7*et,mt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.2*et,mt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.2*et,kt)),Dt.add(new go.PathSegment(go.PathSegment.Line,0,kt)),Dt.add(new go.PathSegment(go.PathSegment.Line,0,Pt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.2*et,Pt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.2*et,gt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.7*et,gt)),Dt.add(new go.PathSegment(go.PathSegment.Line,.7*et,Pt).close()),Tt.spot1=new go.Spot(0,gt/nt);var $t=oe(.7,kt/nt,1,.5,0,mt/nt,1,mt/nt,Ft());return Tt.spot2=new go.Spot($t.x,$t.y),Ht($t),Tt}),go.Shape.setFigureParameter("Pointer",0,new Cn("BackPoint",.1,0,.2)),go.Shape.defineFigureGenerator("Pointer",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.1);var at=new go.Geometry,gt=new go.PathFigure(et,.5*nt,!0);at.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,dt*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,0).close()),at.spot1=new go.Spot(dt,.35);var mt=oe(.2,.65,1,.65,0,1,1,.5,Ft());return at.spot2=new go.Spot(mt.x,mt.y),Ht(mt),at}),go.Shape.setFigureParameter("RoundedPointer",0,new Cn("RoundedEdge",.3,0,.5)),go.Shape.defineFigureGenerator("RoundedPointer",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.3);var at=new go.Geometry,gt=new go.PathFigure(et,.5*nt,!0);at.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,0,0,dt*et,.75*nt,dt*et,.25*nt).close()),at.spot1=new go.Spot(dt,.35);var mt=oe(0,.65,1,.65,0,1,1,.5,Ft());return at.spot2=new go.Spot(mt.x,mt.y),Ht(mt),at}),go.Shape.setFigureParameter("SplitEndArrow",0,new Cn("TailHeight",.4,.01,.99)),go.Shape.defineFigureGenerator("SplitEndArrow",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.4);var at=(.5-dt/2)*nt,gt=(.5+dt/2)*nt,mt=new go.Geometry,Pt=new go.PathFigure(et,.5*nt,!0);mt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,0,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.2*et,.5*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,0,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,0).close()),mt.spot1=new go.Spot(.2,.3);var kt=oe(.7,1,1,.5,0,gt/nt,1,gt/nt,Ft());return mt.spot2=new go.Spot(kt.x,kt.y),Ht(kt),mt}),go.Shape.setFigureParameter("SplitEndArrow2",0,new Cn("TailThickness",50)),go.Shape.defineFigureGenerator("SplitEndArrow2",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=50);var at=(nt-dt)/2,gt=at+dt;dt>nt&&(at=0,gt=nt);var mt=new go.Geometry,Pt=new go.PathFigure(et,.5*nt,!0);mt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,0,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.2*et,.5*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,0,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,.7*et,0).close()),mt.spot1=new go.Spot(.2,at/nt);var kt=oe(.7,1,1,.5,0,gt/nt,1,gt/nt,Ft());return mt.spot2=new go.Spot(kt.x,kt.y),Ht(kt),mt}),go.Shape.setFigureParameter("SquareArrow",0,new Cn("ArrowPoint",.7,.2,.9)),go.Shape.defineFigureGenerator("SquareArrow",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.7);var at=new go.Geometry,gt=new go.PathFigure(et,.5*nt,!0);return at.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,dt*et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,0)),gt.add(new go.PathSegment(go.PathSegment.Line,dt*et,0).close()),at.spot1=go.Spot.TopLeft,at.spot2=new go.Spot(dt,1),at}),go.Shape.defineFigureGenerator("Cone1",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=Nt*.1,mt=new go.PathFigure(0,.9*nt,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,et,.9*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt,et,(.9+gt)*nt,(.5+at)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,.9*nt,(.5-at)*et,nt,0,(.9+gt)*nt).close()),dt.spot1=new go.Spot(.25,.5),dt.spot2=new go.Spot(.75,.97),dt}),go.Shape.defineFigureGenerator("Cone2",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.9*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Bezier,et,.9*nt,(1-.85/.9)*et,nt,.85/.9*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,0,.9*nt).close());var gt=new go.PathFigure(0,.9*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Bezier,et,.9*nt,(1-.85/.9)*et,.8*nt,.85/.9*et,.8*nt)),dt.spot1=new go.Spot(.25,.5),dt.spot2=new go.Spot(.75,.82),dt}),go.Shape.defineFigureGenerator("Cube1",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.85*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.15*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,0,.15*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.85*nt).close());var gt=new go.PathFigure(.5*et,nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.3*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,.15*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.5*et,.3*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,.15*nt)),dt.spot1=new go.Spot(0,.3),dt.spot2=new go.Spot(.5,.85),dt}),go.Shape.defineFigureGenerator("Cube2",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.3*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.7*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,0).close());var gt=new go.PathFigure(0,.3*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.7*et,.3*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Move,.7*et,.3*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.7*et,nt)),dt.spot1=new go.Spot(0,.3),dt.spot2=new go.Spot(.7,1),dt}),go.Shape.defineFigureGenerator("Cylinder1",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=5),dt=Math.min(dt,nt/3);var at=new go.Geometry,gt=Nt*.5,mt=new go.PathFigure(0,dt,!0);at.add(mt),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,0,0,Nt*dt,(.5-gt)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,1*et,dt,(.5+gt)*et,0,1*et,Nt*dt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,nt-dt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,1*nt,1*et,nt-Nt*dt,(.5+gt)*et,1*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,nt-dt,(.5-gt)*et,1*nt,0,nt-Nt*dt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,dt));var Pt=new go.PathFigure(et,dt,!1);return at.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,2*dt,1*et,2*dt-Nt*dt,(.5+gt)*et,2*dt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,0,dt,(.5-gt)*et,2*dt,0,2*dt-Nt*dt)),at.spot1=new go.Spot(0,0,0,2*dt),at.spot2=new go.Spot(1,1),at}),go.Shape.defineFigureGenerator("Cylinder2",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=5),dt=Math.min(dt,nt/3);var at=new go.Geometry,gt=Nt*.5,mt=new go.PathFigure(0,nt-dt,!0);at.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,0,dt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,0,0,Nt*dt,(.5-gt)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,dt,(.5+gt)*et,0,et,Nt*dt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,nt-dt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt,et,nt-Nt*dt,(.5+gt)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,nt-dt,(.5-gt)*et,nt,0,nt-Nt*dt));var Pt=new go.PathFigure(0,nt-dt,!1);return at.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt-2*dt,0,nt-dt-Nt*dt,(.5-gt)*et,nt-2*dt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,et,nt-dt,(.5+gt)*et,nt-2*dt,et,nt-dt-Nt*dt)),at.spot1=new go.Spot(0,0),at.spot2=new go.Spot(1,1,0,-2*dt),at}),go.Shape.defineFigureGenerator("Cylinder3",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=5),dt=Math.min(dt,et/3);var at=new go.Geometry,gt=Nt*.5,mt=new go.PathFigure(dt,0,!0);at.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et-dt,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,et-Nt*dt,0,et,(.5-gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et-dt,nt,et,(.5+gt)*nt,et-Nt*dt,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,dt,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*nt,Nt*dt,nt,0,(.5+gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,dt,0,0,(.5-gt)*nt,Nt*dt,0));var Pt=new go.PathFigure(dt,0,!1);return at.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Bezier,2*dt,.5*nt,dt+Nt*dt,0,2*dt,(.5-gt)*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,dt,nt,2*dt,(.5+gt)*nt,dt+Nt*dt,nt)),at.spot1=new go.Spot(0,0,2*dt,0),at.spot2=new go.Spot(1,1),at}),go.Shape.defineFigureGenerator("Cylinder4",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=5),dt=Math.min(dt,et/3);var at=new go.Geometry,gt=Nt*.5,mt=new go.PathFigure(et-dt,0,!0);at.add(mt),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,et-Nt*dt,0,et,(.5-gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et-dt,nt,et,(.5+gt)*nt,et-Nt*dt,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,dt,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*nt,Nt*dt,nt,0,(.5+gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,dt,0,0,(.5-gt)*nt,Nt*dt,0)),mt.add(new go.PathSegment(go.PathSegment.Line,et-dt,0));var Pt=new go.PathFigure(et-dt,0,!1);return at.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Bezier,et-2*dt,.5*nt,et-dt-Nt*dt,0,et-2*dt,(.5-gt)*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,et-dt,nt,et-2*dt,(.5+gt)*nt,et-dt-Nt*dt,nt)),at.spot1=new go.Spot(0,0),at.spot2=new go.Spot(1,1,-2*dt,0),at}),go.Shape.defineFigureGenerator("Prism1",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.25*et,.25*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var gt=new go.PathFigure(.25*et,.25*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),dt.spot1=new go.Spot(.408,.172),dt.spot2=new go.Spot(.833,.662),dt}),go.Shape.defineFigureGenerator("Prism2",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.25*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var gt=new go.PathFigure(0,nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.25*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,.25*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,0,.25*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.25*et,.5*nt)),dt.spot1=new go.Spot(.25,.5),dt.spot2=new go.Spot(.75,.75),dt}),go.Shape.defineFigureGenerator("Pyramid1",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.75*nt).close());var gt=new go.PathFigure(.5*et,0,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),dt.spot1=new go.Spot(.25,.367),dt.spot2=new go.Spot(.75,.875),dt}),go.Shape.defineFigureGenerator("Pyramid2",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.85*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.85*nt).close());var gt=new go.PathFigure(.5*et,0,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.7*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,.85*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.5*et,.7*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,.85*nt)),dt.spot1=new go.Spot(.25,.367),dt.spot2=new go.Spot(.75,.875),dt}),go.Shape.defineFigureGenerator("Actor",function(It,et,nt){var dt=new go.Geometry,at=.2,gt=.1,mt=Nt*at,Pt=Nt*gt,kt=.5,Tt=.1,Dt=new go.PathFigure(kt*et,(Tt+gt)*nt,!0);dt.add(Dt),Dt.add(new go.PathSegment(go.PathSegment.Bezier,(kt-at)*et,Tt*nt,(kt-mt)*et,(Tt+gt)*nt,(kt-at)*et,(Tt+Pt)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt-gt)*nt,(kt-at)*et,(Tt-Pt)*nt,(kt-mt)*et,(Tt-gt)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,(kt+at)*et,Tt*nt,(kt+mt)*et,(Tt-gt)*nt,(kt+at)*et,(Tt-Pt)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt+gt)*nt,(kt+at)*et,(Tt+Pt)*nt,(kt+mt)*et,(Tt+gt)*nt));var $t=.05,ie=Nt*$t;kt=.05,Tt=.25;var Yt=new go.PathFigure(.5*et,.2*nt,!0);return dt.add(Yt),Yt.add(new go.PathSegment(go.PathSegment.Line,.95*et,.2*nt)),kt=.95,Tt=.25,Yt.add(new go.PathSegment(go.PathSegment.Bezier,(kt+$t)*et,Tt*nt,(kt+ie)*et,(Tt-$t)*nt,(kt+$t)*et,(Tt-ie)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,et,.6*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.85*et,.6*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.85*et,.35*nt)),$t=.025,ie=Nt*$t,kt=.825,Tt=.35,Yt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt-$t)*nt,(kt+$t)*et,(Tt-ie)*nt,(kt+ie)*et,(Tt-$t)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(kt-$t)*et,Tt*nt,(kt-ie)*et,(Tt-$t)*nt,(kt-$t)*et,(Tt-ie)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.8*et,nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.55*et,nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.7*nt)),$t=.05,ie=Nt*$t,kt=.5,Tt=.7,Yt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt-$t)*nt,(kt+$t)*et,(Tt-ie)*nt,(kt+ie)*et,(Tt-$t)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(kt-$t)*et,Tt*nt,(kt-ie)*et,(Tt-$t)*nt,(kt-$t)*et,(Tt-ie)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.45*et,nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.2*et,nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.2*et,.35*nt)),$t=.025,ie=Nt*$t,kt=.175,Tt=.35,Yt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt-$t)*nt,(kt+$t)*et,(Tt-ie)*nt,(kt+ie)*et,(Tt-$t)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(kt-$t)*et,Tt*nt,(kt-ie)*et,(Tt-$t)*nt,(kt-$t)*et,(Tt-ie)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.15*et,.6*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,0,.6*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,0,.25*nt)),$t=.05,ie=Nt*$t,kt=.05,Tt=.25,Yt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt-$t)*nt,(kt-$t)*et,(Tt-ie)*nt,(kt-ie)*et,(Tt-$t)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.2*nt)),dt.spot1=new go.Spot(.2,.2),dt.spot2=new go.Spot(.8,.65),dt}),go.Shape.setFigureParameter("Card",0,new Cn("CornerCutoutSize",.2,.1,.9)),go.Shape.defineFigureGenerator("Card",function(It,et,nt){var dt=It?It.parameter1:NaN;isNaN(dt)&&(dt=.2);var at=new go.Geometry,gt=new go.PathFigure(et,0,!0);return at.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,dt*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,dt*et,0).close()),at.spot1=new go.Spot(0,dt),at.spot2=go.Spot.BottomRight,at}),go.Shape.defineFigureGenerator("Collate",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,.5*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt));var gt=new go.PathFigure(.5*et,.5*nt,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt)),dt.spot1=new go.Spot(.25,0),dt.spot2=new go.Spot(.75,.25),dt}),go.Shape.defineFigureGenerator("CreateRequest",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)&&(at=.1);var gt=new go.PathFigure(0,0,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var mt=new go.PathFigure(0,at*nt,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,at*nt)),mt.add(new go.PathSegment(go.PathSegment.Move,0,(1-at)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,(1-at)*nt)),dt}),go.Shape.defineFigureGenerator("Database",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=Nt*.1,mt=new go.PathFigure(et,.1*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,.9*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt,et,(.9+gt)*nt,(.5+at)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,.9*nt,(.5-at)*et,nt,0,(.9+gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,.1*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,0,0,(.1-gt)*nt,(.5-at)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,.1*nt,(.5+at)*et,0,et,(.1-gt)*nt));var Pt=new go.PathFigure(et,.1*nt,!1);return dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.2*nt,et,(.1+gt)*nt,(.5+at)*et,.2*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,0,.1*nt,(.5-at)*et,.2*nt,0,(.1+gt)*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,et,.2*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.3*nt,et,(.2+gt)*nt,(.5+at)*et,.3*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,0,.2*nt,(.5-at)*et,.3*nt,0,(.2+gt)*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,et,.3*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.4*nt,et,(.3+gt)*nt,(.5+at)*et,.4*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,0,.3*nt,(.5-at)*et,.4*nt,0,(.3+gt)*nt)),dt.spot1=new go.Spot(0,.4),dt.spot2=new go.Spot(1,.9),dt}),go.Shape.defineFigureGenerator("DataStorage",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Bezier,.75*et,nt,et,0,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,0,.25*et,.9*nt,.25*et,.1*nt).close()),dt.spot1=new go.Spot(.226,0),dt.spot2=new go.Spot(.81,1),dt}),go.Shape.defineFigureGenerator("DiskStorage",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=Nt*.1,mt=new go.PathFigure(et,.1*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,.9*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt,et,(.9+gt)*nt,(.5+at)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,.9*nt,(.5-at)*et,nt,0,(.9+gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,.1*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,0,0,(.1-gt)*nt,(.5-at)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,.1*nt,(.5+at)*et,0,et,(.1-gt)*nt));var Pt=new go.PathFigure(et,.1*nt,!1);return dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.2*nt,et,(.1+gt)*nt,(.5+at)*et,.2*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,0,.1*nt,(.5-at)*et,.2*nt,0,(.1+gt)*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,et,.2*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.3*nt,et,(.2+gt)*nt,(.5+at)*et,.3*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,0,.2*nt,(.5-at)*et,.3*nt,0,(.2+gt)*nt)),dt.spot1=new go.Spot(0,.3),dt.spot2=new go.Spot(1,.9),dt}),go.Shape.defineFigureGenerator("Display",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.25*et,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Bezier,.75*et,nt,et,0,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.25*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt).close()),dt.spot1=new go.Spot(.25,0),dt.spot2=new go.Spot(.75,1),dt}),go.Shape.defineFigureGenerator("DividedEvent",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)?at=.2:at<.15&&(at=.15);var gt=Nt*.2,mt=new go.PathFigure(0,.2*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Bezier,.2*et,0,0,(.2-gt)*nt,(.2-gt)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,.8*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,.2*nt,(.8+gt)*et,0,et,(.2-gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,.8*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.8*et,nt,et,(.8+gt)*nt,(.8+gt)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.2*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,.8*nt,(.2-gt)*et,nt,0,(.8+gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,.2*nt));var Pt=new go.PathFigure(0,at*nt,!1);return dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et,at*nt)),dt}),go.Shape.defineFigureGenerator("DividedProcess",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;(isNaN(at)||at<.1)&&(at=.1);var gt=new go.PathFigure(0,0,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var mt=new go.PathFigure(0,at*nt,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,at*nt)),dt}),go.Shape.defineFigureGenerator("Document",function(It,et,nt){var dt=new go.Geometry;nt=nt/.8;var at=new go.PathFigure(0,.7*nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,.7*nt,.5*et,.4*nt,.5*et,nt).close()),dt.spot1=go.Spot.TopLeft,dt.spot2=new go.Spot(1,.6),dt}),go.Shape.defineFigureGenerator("ExternalOrganization",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;(isNaN(at)||at<.2)&&(at=.2);var gt=new go.PathFigure(0,0,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var mt=new go.PathFigure(at*et,0,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,0,at*nt)),mt.add(new go.PathSegment(go.PathSegment.Move,et,at*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,(1-at)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Move,0,(1-at)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,at*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Move,(1-at)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,(1-at)*nt)),dt}),go.Shape.defineFigureGenerator("ExternalProcess",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt).close());var gt=new go.PathFigure(.1*et,.4*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.1*et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.9*et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.9*et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.6*et,.1*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.4*et,.1*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.4*et,.9*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.6*et,.9*nt)),dt.spot1=new go.Spot(.25,.25),dt.spot2=new go.Spot(.75,.75),dt}),go.Shape.defineFigureGenerator("File",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var gt=new go.PathFigure(.75*et,0,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.75*et,.25*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,.25*nt)),dt.spot1=new go.Spot(0,.25),dt.spot2=go.Spot.BottomRight,dt}),go.Shape.defineFigureGenerator("Interrupt",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et,.5*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt));var gt=new go.PathFigure(et,.5*nt,!1);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt));var mt=new go.PathFigure(et,.5*nt,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,0)),dt.spot1=new go.Spot(0,.25),dt.spot2=new go.Spot(.5,.75),dt}),go.Shape.defineFigureGenerator("InternalStorage",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN,gt=It?It.parameter2:NaN;isNaN(at)&&(at=.1),isNaN(gt)&&(gt=.1);var mt=new go.PathFigure(0,0,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var Pt=new go.PathFigure(at*et,0,!1);return dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,at*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,0,gt*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,et,gt*nt)),dt}),go.Shape.defineFigureGenerator("Junction",function(It,et,nt){var dt=new go.Geometry,at=1/Math.SQRT2,gt=(1-1/Math.SQRT2)/2,mt=Nt*.5,Pt=.5,kt=new go.PathFigure(et,Pt*nt,!0);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,Pt*et,nt,et,(Pt+mt)*nt,(Pt+mt)*et,nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,0,Pt*nt,(Pt-mt)*et,nt,0,(Pt+mt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,Pt*et,0,0,(Pt-mt)*nt,(Pt-mt)*et,0)),kt.add(new go.PathSegment(go.PathSegment.Bezier,et,Pt*nt,(Pt+mt)*et,0,et,(Pt-mt)*nt));var Tt=new go.PathFigure((gt+at)*et,(gt+at)*nt,!1);return dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Line,gt*et,gt*nt)),Tt.add(new go.PathSegment(go.PathSegment.Move,gt*et,(gt+at)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Line,(gt+at)*et,gt*nt)),dt}),go.Shape.defineFigureGenerator("LinedDocument",function(It,et,nt){var dt=new go.Geometry;nt=nt/.8;var at=new go.PathFigure(0,.7*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,.7*nt,.5*et,.4*nt,.5*et,nt).close());var gt=new go.PathFigure(.1*et,0,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.1*et,.75*nt)),dt.spot1=new go.Spot(.1,0),dt.spot2=new go.Spot(1,.6),dt}),go.Shape.defineFigureGenerator("LoopLimit",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.25*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt).close()),dt.spot1=new go.Spot(0,.25),dt.spot2=go.Spot.BottomRight,dt}),go.Shape.defineFigureGenerator("MagneticTape",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=.5,mt=new go.PathFigure(.5*et,nt,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,gt*nt,(gt-at)*et,nt,0,(gt+at)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,gt*et,0,0,(gt-at)*nt,(gt-at)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,gt*nt,(gt+at)*et,0,et,(gt-at)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,(gt+.1)*et,.9*nt,et,(gt+at)*nt,(gt+at)*et,.9*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,.9*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),dt.spot1=new go.Spot(.15,.15),dt.spot2=new go.Spot(.85,.8),dt}),go.Shape.defineFigureGenerator("ManualInput",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.25*nt).close()),dt.spot1=new go.Spot(0,.25),dt.spot2=go.Spot.BottomRight,dt}),go.Shape.defineFigureGenerator("MessageFromUser",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)&&(at=.7);var gt=new go.PathFigure(0,0,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,at*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt.spot1=go.Spot.TopLeft,dt}),go.Shape.defineFigureGenerator("MicroformProcessing",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)&&(at=.25);var gt=new go.PathFigure(0,0,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,at*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,(1-at)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt}),go.Shape.defineFigureGenerator("MicroformRecording",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.15*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.85*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt.spot1=new go.Spot(0,.25),dt.spot2=new go.Spot(1,.75),dt}),go.Shape.defineFigureGenerator("MultiDocument",function(It,et,nt){var dt=new go.Geometry;nt=nt/.8;var at=new go.PathFigure(et,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.9*et,.44*nt,.96*et,.47*nt,.93*et,.45*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.8*et,.54*nt,.86*et,.57*nt,.83*et,.55*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,.7*nt,.4*et,.4*nt,.4*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,0).close());var gt=new go.PathFigure(.1*et,.2*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.2*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.54*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.2*et,.1*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.9*et,.1*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.9*et,.44*nt)),dt.spot1=new go.Spot(0,.25),dt.spot2=new go.Spot(.8,.77),dt}),go.Shape.defineFigureGenerator("MultiProcess",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.1*et,.1*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,.9*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,.9*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,.2*nt).close());var gt=new go.PathFigure(.2*et,.1*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.9*et,.1*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.9*et,.8*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.1*et,.2*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.2*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.9*nt)),dt.spot1=new go.Spot(0,.2),dt.spot2=new go.Spot(.8,1),dt}),go.Shape.defineFigureGenerator("OfflineStorage",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)&&(at=.1);var gt=1-at,mt=new go.PathFigure(0,0,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt).close());var Pt=new go.PathFigure(.5*at*et,at*nt,!1);return dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,(1-.5*at)*et,at*nt)),dt}),go.Shape.defineFigureGenerator("OffPageConnector",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt.spot1=go.Spot.TopLeft,dt.spot2=new go.Spot(.75,1),dt}),go.Shape.defineFigureGenerator("Or",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=.5,mt=new go.PathFigure(et,gt*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Bezier,gt*et,nt,et,(gt+at)*nt,(gt+at)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,gt*nt,(gt-at)*et,nt,0,(gt+at)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,gt*et,0,0,(gt-at)*nt,(gt-at)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,gt*nt,(gt+at)*et,0,et,(gt-at)*nt));var Pt=new go.PathFigure(et,.5*nt,!1);return dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,.5*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),dt}),go.Shape.defineFigureGenerator("PaperTape",function(It,et,nt){var dt=new go.Geometry;nt=nt/.8;var at=new go.PathFigure(0,.7*nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,.3*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,et,.3*nt,.5*et,.6*nt,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,.7*nt,.5*et,.4*nt,.5*et,nt).close()),dt.spot1=new go.Spot(0,.49),dt.spot2=new go.Spot(1,.75),dt}),go.Shape.defineFigureGenerator("PrimitiveFromCall",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN,gt=It?It.parameter2:NaN;isNaN(at)&&(at=.1),isNaN(gt)&&(gt=.3);var mt=new go.PathFigure(0,0,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,(1-gt)*et,.5*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt}),go.Shape.defineFigureGenerator("PrimitiveToCall",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN,gt=It?It.parameter2:NaN;isNaN(at)&&(at=.1),isNaN(gt)&&(gt=.3);var mt=new go.PathFigure(0,0,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,(1-gt)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,(1-gt)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt}),go.Shape.defineFigureGenerator("Procedure",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)&&(at=.1);var gt=new go.PathFigure(0,0,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var mt=new go.PathFigure((1-at)*et,0,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,(1-at)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Move,at*et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,at*et,nt)),dt}),go.Shape.defineFigureGenerator("Process",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)&&(at=.1);var gt=new go.PathFigure(0,0,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var mt=new go.PathFigure(at*et,0,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,at*et,nt)),dt.spot2=go.Spot.BottomRight,dt}),go.Shape.defineFigureGenerator("Sort",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt).close());var gt=new go.PathFigure(0,.5*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),dt.spot1=new go.Spot(.25,.25),dt.spot2=new go.Spot(.75,.5),dt}),go.Shape.defineFigureGenerator("Start",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)&&(at=.25);var gt=new go.PathFigure(at*et,0,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Arc,270,180,.75*et,.5*nt,.25*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Arc,90,180,.25*et,.5*nt,.25*et,.5*nt));var mt=new go.PathFigure(at*et,0,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,at*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Move,(1-at)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,(1-at)*et,nt)),dt.spot1=new go.Spot(at,0),dt.spot2=new go.Spot(1-at,1),dt}),go.Shape.defineFigureGenerator("Terminator",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.25*et,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Arc,270,180,.75*et,.5*nt,.25*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Arc,90,180,.25*et,.5*nt,.25*et,.5*nt)),dt.spot1=new go.Spot(.23,0),dt.spot2=new go.Spot(.77,1),dt}),go.Shape.defineFigureGenerator("TransmittalTape",function(It,et,nt){var dt=new go.Geometry,at=It?It.parameter1:NaN;isNaN(at)&&(at=.1);var gt=new go.PathFigure(0,0,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.75*et,(1-at)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,(1-at)*nt).close()),dt.spot1=go.Spot.TopLeft,dt}),go.Shape.defineFigureGenerator("AndGate",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=new go.PathFigure(0,0,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),gt.add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,(.5+at)*et,0,et,(.5-at)*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt,et,(.5+at)*nt,(.5+at)*et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt.spot1=go.Spot.TopLeft,dt.spot2=new go.Spot(.55,1),dt}),go.Shape.defineFigureGenerator("Buffer",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt.spot1=new go.Spot(0,.25),dt.spot2=new go.Spot(.5,.75),dt}),go.Shape.defineFigureGenerator("Clock",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=.5,mt=new go.PathFigure(et,gt*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Bezier,gt*et,nt,et,(gt+at)*nt,(gt+at)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,gt*nt,(gt-at)*et,nt,0,(gt+at)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,gt*et,0,0,(gt-at)*nt,(gt-at)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,gt*nt,(gt+at)*et,0,et,(gt-at)*nt));var Pt=new go.PathFigure(et,gt*nt,!1);dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et,gt*nt));var kt=new go.PathFigure(.8*et,.75*nt,!1);return dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.25*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.6*et,.25*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.6*et,.75*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.4*et,.75*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.4*et,.25*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.2*et,.25*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,.2*et,.75*nt)),dt}),go.Shape.defineFigureGenerator("Ground",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.2*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.3*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.7*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.4*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,nt)),dt}),go.Shape.defineFigureGenerator("Inverter",function(It,et,nt){var dt=new go.Geometry,at=Nt*.1,gt=.1,mt=.9,Pt=.5,kt=new go.PathFigure(.8*et,.5*nt,!0);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),kt.add(new go.PathSegment(go.PathSegment.Line,0,0)),kt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.5*nt));var Tt=new go.PathFigure((mt+gt)*et,Pt*nt,!0);return dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-gt)*et,Pt*nt,(mt-at)*et,(Pt+gt)*nt,(mt-gt)*et,(Pt+at)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,Pt*nt,(mt+at)*et,(Pt-gt)*nt,(mt+gt)*et,(Pt-at)*nt)),dt.spot1=new go.Spot(0,.25),dt.spot2=new go.Spot(.4,.75),dt}),go.Shape.defineFigureGenerator("NandGate",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=Nt*.4,mt=Nt*.1,Pt=.1,kt=.9,Tt=.5,Dt=new go.PathFigure(.8*et,.5*nt,!0);dt.add(Dt),Dt.add(new go.PathSegment(go.PathSegment.Bezier,.4*et,nt,.8*et,(.5+gt)*nt,(.4+at)*et,nt)),Dt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),Dt.add(new go.PathSegment(go.PathSegment.Line,0,0)),Dt.add(new go.PathSegment(go.PathSegment.Line,.4*et,0)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,.8*et,.5*nt,(.4+at)*et,0,.8*et,(.5-gt)*nt));var $t=new go.PathFigure((kt+Pt)*et,Tt*nt,!0);return dt.add($t),$t.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt+Pt)*nt,(kt+Pt)*et,(Tt+mt)*nt,(kt+mt)*et,(Tt+Pt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,(kt-Pt)*et,Tt*nt,(kt-mt)*et,(Tt+Pt)*nt,(kt-Pt)*et,(Tt+mt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt-Pt)*nt,(kt-Pt)*et,(Tt-mt)*nt,(kt-mt)*et,(Tt-Pt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,(kt+Pt)*et,Tt*nt,(kt+mt)*et,(Tt-Pt)*nt,(kt+Pt)*et,(Tt-mt)*nt)),dt.spot1=new go.Spot(0,.05),dt.spot2=new go.Spot(.55,.95),dt}),go.Shape.defineFigureGenerator("NorGate",function(It,et,nt){var dt=new go.Geometry,at=.5,gt=Nt*at,mt=0,Pt=.5,kt=new go.PathFigure(.8*et,.5*nt,!0);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,0,nt,.7*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,0,0,.25*et,.75*nt,.25*et,.25*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,.8*et,.5*nt,(mt+gt)*et,(Pt-at)*nt,.7*et,(Pt-gt)*nt)),at=.1,gt=Nt*.1,mt=.9,Pt=.5;var Tt=new go.PathFigure((mt-at)*et,Pt*nt,!0);return dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+at)*et,Pt*nt,(mt+gt)*et,(Pt-at)*nt,(mt+at)*et,(Pt-gt)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-at)*et,Pt*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt)),dt.spot1=new go.Spot(.2,.25),dt.spot2=new go.Spot(.6,.75),dt}),go.Shape.defineFigureGenerator("OrGate",function(It,et,nt){var dt=new go.Geometry,at=.5,gt=Nt*at,mt=0,Pt=.5,kt=new go.PathFigure(0,0,!0);return dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,(mt+gt+gt)*et,(Pt-at)*nt,.8*et,(Pt-gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,0,nt,.8*et,(Pt+gt)*nt,(mt+gt+gt)*et,(Pt+at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,0,0,.25*et,.75*nt,.25*et,.25*nt).close()),dt.spot1=new go.Spot(.2,.25),dt.spot2=new go.Spot(.75,.75),dt}),go.Shape.defineFigureGenerator("XnorGate",function(It,et,nt){var dt=new go.Geometry,at=.5,gt=Nt*at,mt=.2,Pt=.5,kt=new go.PathFigure(.1*et,0,!1);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,.1*et,nt,.35*et,.25*nt,.35*et,.75*nt));var Tt=new go.PathFigure(.8*et,.5*nt,!0);dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Bezier,.2*et,nt,.7*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,.2*et,0,.45*et,.75*nt,.45*et,.25*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,.8*et,.5*nt,(mt+gt)*et,(Pt-at)*nt,.7*et,(Pt-gt)*nt)),at=.1,gt=Nt*.1,mt=.9,Pt=.5;var Dt=new go.PathFigure((mt-at)*et,Pt*nt,!0);return dt.add(Dt),Dt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+at)*et,Pt*nt,(mt+gt)*et,(Pt-at)*nt,(mt+at)*et,(Pt-gt)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-at)*et,Pt*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt)),dt.spot1=new go.Spot(.4,.25),dt.spot2=new go.Spot(.65,.75),dt}),go.Shape.defineFigureGenerator("XorGate",function(It,et,nt){var dt=new go.Geometry,at=.5,gt=Nt*at,mt=.2,Pt=.5,kt=new go.PathFigure(.1*et,0,!1);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,.1*et,nt,.35*et,.25*nt,.35*et,.75*nt));var Tt=new go.PathFigure(.2*et,0,!0);return dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,(mt+gt)*et,(Pt-at)*nt,.9*et,(Pt-gt)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,.2*et,nt,.9*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,.2*et,0,.45*et,.75*nt,.45*et,.25*nt).close()),dt.spot1=new go.Spot(.4,.25),dt.spot2=new go.Spot(.8,.75),dt}),go.Shape.defineFigureGenerator("Capacitor",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Move,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),dt}),go.Shape.defineFigureGenerator("Resistor",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.5*nt,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.4*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.7*et,.5*nt)),dt}),go.Shape.defineFigureGenerator("Inductor",function(It,et,nt){var dt=new go.Geometry,at=Nt*.1,gt=.1,mt=.1,Pt=.5,kt=new go.PathFigure((mt-at*.5)*et,nt,!1);return dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,0,(mt-at)*et,nt,(mt-gt)*et,0)),mt=.3,kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,nt,(mt+gt)*et,0,(mt+at)*et,nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,0,(mt-at)*et,nt,(mt-gt)*et,0)),mt=.5,kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,nt,(mt+gt)*et,0,(mt+at)*et,nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,0,(mt-at)*et,nt,(mt-gt)*et,0)),mt=.7,kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,nt,(mt+gt)*et,0,(mt+at)*et,nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,0,(mt-at)*et,nt,(mt-gt)*et,0)),mt=.9,kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+at*.5)*et,nt,(mt+gt)*et,0,(mt+at)*et,nt)),dt}),go.Shape.defineFigureGenerator("ACvoltageSource",function(It,et,nt){var dt=new go.Geometry,at=Nt*.5,gt=.5,mt=.5,Pt=.5,kt=new go.PathFigure((mt-gt)*et,Pt*nt,!1);return dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,Pt*nt,(mt+at)*et,(Pt-gt)*nt,(mt+gt)*et,(Pt-at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-gt)*et,Pt*nt,(mt-at)*et,(Pt+gt)*nt,(mt-gt)*et,(Pt+at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Move,(mt-gt+.1)*et,Pt*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt-.1)*et,Pt*nt,mt*et,(Pt-gt)*nt,mt*et,(Pt+gt)*nt)),dt}),go.Shape.defineFigureGenerator("DCvoltageSource",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.75*nt,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Move,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),dt}),go.Shape.defineFigureGenerator("Diode",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et,0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),dt.spot1=new go.Spot(0,.25),dt.spot2=new go.Spot(.5,.75),dt}),go.Shape.defineFigureGenerator("Wifi",function(It,et,nt){var dt=new go.Geometry,at=et,gt=nt;et=et*.38,nt=nt*.6;var mt=Nt*.8,Pt=.8,kt=0,Tt=.5,Dt=(at-et)/2,$t=(gt-nt)/2,ie=new go.PathFigure(kt*et+Dt,(Tt+Pt)*nt+$t,!0);dt.add(ie),ie.add(new go.PathSegment(go.PathSegment.Bezier,(kt-Pt)*et+Dt,Tt*nt+$t,(kt-mt)*et+Dt,(Tt+Pt)*nt+$t,(kt-Pt)*et+Dt,(Tt+mt)*nt+$t)),ie.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt-Pt)*nt+$t,(kt-Pt)*et+Dt,(Tt-mt)*nt+$t,(kt-mt)*et+Dt,(Tt-Pt)*nt+$t)),ie.add(new go.PathSegment(go.PathSegment.Bezier,(kt-Pt+mt*.5)*et+Dt,Tt*nt+$t,kt*et+Dt,(Tt-Pt)*nt+$t,(kt-Pt+mt*.5)*et+Dt,(Tt-mt)*nt+$t)),ie.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt+Pt)*nt+$t,(kt-Pt+mt*.5)*et+Dt,(Tt+mt)*nt+$t,kt*et+Dt,(Tt+Pt)*nt+$t).close()),mt=Nt*.4,Pt=.4,kt=.2,Tt=.5;var Yt=new go.PathFigure(kt*et+Dt,(Tt+Pt)*nt+$t,!0);dt.add(Yt),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(kt-Pt)*et+Dt,Tt*nt+$t,(kt-mt)*et+Dt,(Tt+Pt)*nt+$t,(kt-Pt)*et+Dt,(Tt+mt)*nt+$t)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt-Pt)*nt+$t,(kt-Pt)*et+Dt,(Tt-mt)*nt+$t,(kt-mt)*et+Dt,(Tt-Pt)*nt+$t)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(kt-Pt+mt*.5)*et+Dt,Tt*nt+$t,kt*et+Dt,(Tt-Pt)*nt+$t,(kt-Pt+mt*.5)*et+Dt,(Tt-mt)*nt+$t)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt+Pt)*nt+$t,(kt-Pt+mt*.5)*et+Dt,(Tt+mt)*nt+$t,kt*et+Dt,(Tt+Pt)*nt+$t).close()),mt=Nt*.2,Pt=.2,kt=.5,Tt=.5;var fe=new go.PathFigure((kt-Pt)*et+Dt,Tt*nt+$t,!0);dt.add(fe),fe.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt-Pt)*nt+$t,(kt-Pt)*et+Dt,(Tt-mt)*nt+$t,(kt-mt)*et+Dt,(Tt-Pt)*nt+$t)),fe.add(new go.PathSegment(go.PathSegment.Bezier,(kt+Pt)*et+Dt,Tt*nt+$t,(kt+mt)*et+Dt,(Tt-Pt)*nt+$t,(kt+Pt)*et+Dt,(Tt-mt)*nt+$t)),fe.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt+Pt)*nt+$t,(kt+Pt)*et+Dt,(Tt+mt)*nt+$t,(kt+mt)*et+Dt,(Tt+Pt)*nt+$t)),fe.add(new go.PathSegment(go.PathSegment.Bezier,(kt-Pt)*et+Dt,Tt*nt+$t,(kt-mt)*et+Dt,(Tt+Pt)*nt+$t,(kt-Pt)*et+Dt,(Tt+mt)*nt+$t)),mt=Nt*.4,Pt=.4,kt=.8,Tt=.5;var Zt=new go.PathFigure(kt*et+Dt,(Tt-Pt)*nt+$t,!0);dt.add(Zt),Zt.add(new go.PathSegment(go.PathSegment.Bezier,(kt+Pt)*et+Dt,Tt*nt+$t,(kt+mt)*et+Dt,(Tt-Pt)*nt+$t,(kt+Pt)*et+Dt,(Tt-mt)*nt+$t)),Zt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt+Pt)*nt+$t,(kt+Pt)*et+Dt,(Tt+mt)*nt+$t,(kt+mt)*et+Dt,(Tt+Pt)*nt+$t)),Zt.add(new go.PathSegment(go.PathSegment.Bezier,(kt+Pt-mt*.5)*et+Dt,Tt*nt+$t,kt*et+Dt,(Tt+Pt)*nt+$t,(kt+Pt-mt*.5)*et+Dt,(Tt+mt)*nt+$t)),Zt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt-Pt)*nt+$t,(kt+Pt-mt*.5)*et+Dt,(Tt-mt)*nt+$t,kt*et+Dt,(Tt-Pt)*nt+$t).close()),mt=Nt*.8,Pt=.8,kt=1,Tt=.5;var je=new go.PathFigure(kt*et+Dt,(Tt-Pt)*nt+$t,!0);return dt.add(je),je.add(new go.PathSegment(go.PathSegment.Bezier,(kt+Pt)*et+Dt,Tt*nt+$t,(kt+mt)*et+Dt,(Tt-Pt)*nt+$t,(kt+Pt)*et+Dt,(Tt-mt)*nt+$t)),je.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt+Pt)*nt+$t,(kt+Pt)*et+Dt,(Tt+mt)*nt+$t,(kt+mt)*et+Dt,(Tt+Pt)*nt+$t)),je.add(new go.PathSegment(go.PathSegment.Bezier,(kt+Pt-mt*.5)*et+Dt,Tt*nt+$t,kt*et+Dt,(Tt+Pt)*nt+$t,(kt+Pt-mt*.5)*et+Dt,(Tt+mt)*nt+$t)),je.add(new go.PathSegment(go.PathSegment.Bezier,kt*et+Dt,(Tt-Pt)*nt+$t,(kt+Pt-mt*.5)*et+Dt,(Tt-mt)*nt+$t,kt*et+Dt,(Tt-Pt)*nt+$t).close()),dt}),go.Shape.defineFigureGenerator("Email",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,0).close());var gt=new go.PathFigure(0,0,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,0)),gt.add(new go.PathSegment(go.PathSegment.Move,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.45*et,.54*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.54*nt)),dt}),go.Shape.defineFigureGenerator("Ethernet",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.35*et,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.65*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.65*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.35*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.35*et,0).close());var gt=new go.PathFigure(.1*et,nt,!0,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.4*et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.4*et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.1*et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.1*et,nt).close());var mt=new go.PathFigure(.6*et,nt,!0,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.9*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.9*et,.6*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.6*et,.6*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.6*et,nt).close());var Pt=new go.PathFigure(0,.5*nt,!1);return dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,.5*et,.5*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.4*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,.75*et,.5*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.75*et,.6*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,.25*et,.5*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.25*et,.6*nt)),dt}),go.Shape.defineFigureGenerator("Power",function(It,et,nt){var dt=new go.Geometry,at=Nt*.4,gt=.4,mt=.5,Pt=.5,kt=Ft(),Tt=Ft(),Dt=Ft(),$t=Ft();ke(mt,Pt-gt,mt+at,Pt-gt,mt+gt,Pt-at,mt+gt,Pt,.5,kt,kt,Tt,Dt,$t);var ie=wt(Tt.x,Tt.y),Yt=new go.PathFigure(Tt.x*et,Tt.y*nt,!0);dt.add(Yt),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,Pt*nt,Dt.x*et,Dt.y*nt,$t.x*et,$t.y*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-gt)*et,Pt*nt,(mt-at)*et,(Pt+gt)*nt,(mt-gt)*et,(Pt+at)*nt)),ke(mt-gt,Pt,mt-gt,Pt-at,mt-at,Pt-gt,mt,Pt-gt,.5,Dt,$t,Tt,kt,kt),Yt.add(new go.PathSegment(go.PathSegment.Bezier,Tt.x*et,Tt.y*nt,Dt.x*et,Dt.y*nt,$t.x*et,$t.y*nt)),at=Nt*.3,gt=.3,ke(mt-gt,Pt,mt-gt,Pt-at,mt-at,Pt-gt,mt,Pt-gt,.5,Dt,$t,Tt,kt,kt),Yt.add(new go.PathSegment(go.PathSegment.Line,Tt.x*et,Tt.y*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-gt)*et,Pt*nt,$t.x*et,$t.y*nt,Dt.x*et,Dt.y*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+gt)*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+gt)*et,Pt*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),ke(mt,Pt-gt,mt+at,Pt-gt,mt+gt,Pt-at,mt+gt,Pt,.5,kt,kt,Tt,Dt,$t),Yt.add(new go.PathSegment(go.PathSegment.Bezier,Tt.x*et,Tt.y*nt,$t.x*et,$t.y*nt,Dt.x*et,Dt.y*nt).close());var Yt=new go.PathFigure(.45*et,0,!0);return dt.add(Yt),Yt.add(new go.PathSegment(go.PathSegment.Line,.45*et,.5*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.5*nt)),Yt.add(new go.PathSegment(go.PathSegment.Line,.55*et,0).close()),Ht(kt),Ht(Tt),Ht(Dt),Ht($t),Ht(ie),dt.spot1=new go.Spot(.25,.45),dt.spot2=new go.Spot(.75,.8),dt}),go.Shape.defineFigureGenerator("Fallout",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt/2,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Arc,180,360,et/2,nt/2,et/2,nt/2));function gt(mt,Pt,kt){mt.add(new go.PathSegment(go.PathSegment.Move,(.3+Pt)*et,(.8+kt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,(.5+Pt)*et,(.5+kt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,(.1+Pt)*et,(.5+kt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,(.3+Pt)*et,(.8+kt)*nt).close())}return gt(at,0,0),gt(at,.4,0),gt(at,.2,-.3),dt}),go.Shape.defineFigureGenerator("IrritationHazard",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.2*et,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.3*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.7*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.2*nt).close()),dt.spot1=new go.Spot(.3,.3),dt.spot2=new go.Spot(.7,.7),dt}),go.Shape.defineFigureGenerator("ElectricalHazard",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.37*et,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.11*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.77*et,.04*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.33*et,.49*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.37*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.63*et,.86*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.77*et,.91*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.34*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.34*et,.78*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.44*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.65*et,.56*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.68*nt).close()),dt}),go.Shape.defineFigureGenerator("FireHazard",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.1*et,nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Bezier,.29*et,0,-.25*et,.63*nt,.45*et,.44*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.51*et,.42*nt,.48*et,.17*nt,.54*et,.35*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.59*et,.18*nt,.59*et,.29*nt,.58*et,.28*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.75*et,.6*nt,.8*et,.34*nt,.88*et,.43*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.88*et,.31*nt,.87*et,.48*nt,.88*et,.43*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.9*et,nt,1.17*et,.76*nt,.82*et,.8*nt).close()),dt.spot1=new go.Spot(.07,.445),dt.spot2=new go.Spot(.884,.958),dt}),go.Shape.defineFigureGenerator("BpmnActivityLoop",function(It,et,nt){var dt=new go.Geometry,at=.5,gt=0,mt=0,Pt=at*Nt,kt=.4*Math.SQRT2/2+.5,Tt=.5-.5*Math.SQRT2/2,Dt=1,$t=.5,ie=.5,Yt=0,fe=new go.PathFigure(kt*et,(1-Tt)*nt,!1);return dt.add(fe),fe.add(new go.PathSegment(go.PathSegment.Bezier,Dt*et,$t*nt,Dt*et,.7*nt,Dt*et,$t*nt)),fe.add(new go.PathSegment(go.PathSegment.Bezier,(ie+gt)*et,(Yt+gt)*nt,(.5+at+gt)*et,(.5-Pt+gt)*nt,(.5+Pt+gt)*et,(.5-at+gt)*nt)),fe.add(new go.PathSegment(go.PathSegment.Bezier,(.5-at+gt)*et,(.5+mt)*nt,(.5-Pt+gt)*et,(.5-at+mt)*nt,(.5-at+gt)*et,(.5-Pt+mt)*nt)),fe.add(new go.PathSegment(go.PathSegment.Bezier,(.35+gt)*et,.9*nt,(.5-at+gt)*et,(.5+Pt+mt)*nt,(.5-Pt+gt)*et,.9*nt)),fe.add(new go.PathSegment(go.PathSegment.Move,(.25+gt)*et,.8*nt)),fe.add(new go.PathSegment(go.PathSegment.Line,(.35+gt)*et,.9*nt)),fe.add(new go.PathSegment(go.PathSegment.Line,(.2+gt)*et,.95*nt)),dt}),go.Shape.defineFigureGenerator("BpmnActivityParallel",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Move,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Move,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),dt}),go.Shape.defineFigureGenerator("BpmnActivitySequential",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Move,0,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Move,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),dt}),go.Shape.defineFigureGenerator("BpmnActivityAdHoc",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!1);dt.add(at);var gt=new go.PathFigure(et,nt,!1);dt.add(gt);var mt=new go.PathFigure(0,.5*nt,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.5*nt,.2*et,.35*nt,.3*et,.35*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,.7*et,.65*nt,.8*et,.65*nt)),dt}),go.Shape.defineFigureGenerator("BpmnActivityCompensation",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.5*nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt).close()),dt}),go.Shape.defineFigureGenerator("BpmnTaskMessage",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.2*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.8*nt).close());var at=new go.PathFigure(0,.2*nt,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.2*nt)),dt}),go.Shape.defineFigureGenerator("BpmnTaskScript",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.7*et,nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.3*et,0,.6*et,.5*nt,0,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.7*et,0)),at.add(new go.PathSegment(go.PathSegment.Bezier,.7*et,nt,.4*et,.5*nt,et,.5*nt).close());var gt=new go.PathFigure(.45*et,.73*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.7*et,.73*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.38*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.63*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.31*et,.27*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.56*et,.27*nt)),dt}),go.Shape.defineFigureGenerator("BpmnTaskUser",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!1);dt.add(at);var gt=new go.PathFigure(.335*et,(1-.555)*nt,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.335*et,(1-.405)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(1-.335)*et,(1-.405)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(1-.335)*et,(1-.555)*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,et,.68*nt,(1-.12)*et,.46*nt,(1-.02)*et,.54*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,.68*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,.335*et,(1-.555)*nt,.02*et,.54*nt,.12*et,.46*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.365*et,(1-.595)*nt));var mt=.5-.285,Pt=.5,kt=mt,Tt=Math.PI/4,Dt=4*(1-Math.cos(Tt))/(3*Math.sin(Tt)),$t=Dt*.5,ie=mt,Yt=mt,fe=Dt*ie,Zt=Dt*Yt;gt.add(new go.PathSegment(go.PathSegment.Bezier,(Pt-ie)*et,kt*nt,(Pt-(fe+ie)/2)*et,(kt+(Yt+Zt)/2)*nt,(Pt-ie)*et,(kt+Zt)*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,Pt*et,(kt-Yt)*nt,(Pt-ie)*et,(kt-Zt)*nt,(Pt-fe)*et,(kt-Yt)*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,(Pt+ie)*et,kt*nt,(Pt+fe)*et,(kt-Yt)*nt,(Pt+ie)*et,(kt-Zt)*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,(1-.365)*et,(1-.595)*nt,(Pt+ie)*et,(kt+Zt)*nt,(Pt+(fe+ie)/2)*et,(kt+(Yt+Zt)/2)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(1-.365)*et,(1-.595)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(1-.335)*et,(1-.555)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,(1-.335)*et,(1-.405)*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.335*et,(1-.405)*nt));var je=new go.PathFigure(.2*et,nt,!1);dt.add(je),je.add(new go.PathSegment(go.PathSegment.Line,.2*et,.8*nt));var me=new go.PathFigure(.8*et,nt,!1);return dt.add(me),me.add(new go.PathSegment(go.PathSegment.Line,.8*et,.8*nt)),dt}),go.Shape.defineFigureGenerator("BpmnEventConditional",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.1*et,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,nt).close());var gt=new go.PathFigure(.2*et,.2*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.2*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.2*et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.2*et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Move,.2*et,.8*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.8*nt)),dt}),go.Shape.defineFigureGenerator("BpmnEventError",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.33*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.66*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.66*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.33*et,.5*nt).close()),dt}),go.Shape.defineFigureGenerator("BpmnEventEscalation",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!1);dt.add(at);var gt=new go.PathFigure(et,nt,!1);dt.add(gt);var mt=new go.PathFigure(.1*et,nt,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),mt.add(new go.PathSegment(go.PathSegment.Line,.9*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt).close()),dt}),go.Shape.defineFigureGenerator("Caution",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.05*et,nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Bezier,.1*et,.8*nt,0,nt,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.45*et,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.55*et,.1*nt,.5*et,0,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.95*et,.9*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.9*et,nt,et,nt,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.05*et,nt));var gt=.05;return at.add(new go.PathSegment(go.PathSegment.Move,(.5-gt)*et,.875*nt)),at.add(new go.PathSegment(go.PathSegment.Arc,180,-360,.5*et,.875*nt,gt*et,gt*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.5*et,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.325*nt,.575*et,.725*nt,.625*et,.375*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.75*nt,.375*et,.375*nt,.425*et,.725*nt)),dt}),go.Shape.defineFigureGenerator("Recycle",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.45*et,.95*nt,!1);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,.95*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.185*et,.85*nt,.17*et,.95*nt,.15*et,.9*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.235*et,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.3*et,.625*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.35*et,.65*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.275*et,.45*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.05*et,.45*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.05*et,.575*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.1875*et,.95*nt,0,.675*nt,0,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.45*et,.95*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.45*et,.775*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.22*et,.775*nt));var gt=new go.PathFigure(.475*et,.2*nt,!1);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.4*et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.225*et,.3*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.275*et,.175*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.325*et,.05*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,.4*et,.05*nt,.35*et,0,.375*et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,.575*et,.375*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.525*et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.75*et,.475*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.85*et,.315*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.32*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.65*et,.05*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,.575*et,0,.65*et,.05*nt,.625*et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,.38*et,.0105*nt));var mt=new go.PathFigure(.675*et,.575*nt,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.875*et,.525*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,.775*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,.85*et,.95*nt,et,.8*nt,et,.85*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.65*et,.95*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.65*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.85*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.65*et,.725*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.65*et,.775*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.7*et,.775*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,et,.775*nt)),mt.add(new go.PathSegment(go.PathSegment.Move,.675*et,.575*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.775*et,.775*nt)),dt}),go.Shape.defineFigureGenerator("BpmnEventTimer",function(It,et,nt){var dt=new go.Geometry,at=.5,gt=Nt*.5,mt=new go.PathFigure(et,at*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Bezier,at*et,nt,et,(at+gt)*nt,(at+gt)*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,at*nt,(at-gt)*et,nt,0,(at+gt)*nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,at*et,0,0,(at-gt)*nt,(at-gt)*et,0)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et,at*nt,(at+gt)*et,0,et,(at-gt)*nt));var Pt=new go.PathFigure(at*et,0,!1);return dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,at*et,.15*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,at*et,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,at*et,.85*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,0,at*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.15*et,at*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,et,at*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.85*et,at*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,at*et,at*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.58*et,.1*nt)),Pt.add(new go.PathSegment(go.PathSegment.Move,at*et,at*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.78*et,.54*nt)),dt}),go.Shape.defineFigureGenerator("Package",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.15*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,.15*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close());var gt=new go.PathFigure(0,.15*nt,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,0,0)),gt.add(new go.PathSegment(go.PathSegment.Line,.6*et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,.65*et,.15*nt).close()),dt.spot1=new go.Spot(0,.1),dt.spot2=new go.Spot(1,1),dt}),go.Shape.defineFigureGenerator("Class",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,0).close());var gt=new go.PathFigure(0,.2*nt,!1);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,.2*nt).close());var mt=new go.PathFigure(0,.5*nt,!1);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt).close()),dt}),go.Shape.defineFigureGenerator("Component",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et,nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.15*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.15*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt).close());var gt=new go.PathFigure(0,.2*nt,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.45*et,.2*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.45*et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,.2*nt).close());var mt=new go.PathFigure(0,.6*nt,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.45*et,.6*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.45*et,.8*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,.8*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,.6*nt).close()),dt}),go.Shape.defineFigureGenerator("Boat Shipment",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.15*et,.6*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.15*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.15*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.85*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.85*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.15*et,.6*nt));var gt=new go.PathFigure(.15*et,.6*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.85*et,.6*nt)),dt}),go.Shape.defineFigureGenerator("Customer/Supplier",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et,nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.66*et,.33*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.66*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.33*et,.33*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.33*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,0,.33*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt).close()),dt}),go.Shape.defineFigureGenerator("Workcell",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.65*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.65*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.35*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.35*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),dt}),go.Shape.defineFigureGenerator("Supermarket",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.33*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.33*nt)),at.add(new go.PathSegment(go.PathSegment.Move,et,.33*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.66*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.66*nt)),at.add(new go.PathSegment(go.PathSegment.Move,et,.66*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),dt}),go.Shape.defineFigureGenerator("TruckShipment",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,0).close());var gt=new go.PathFigure(et,.8*nt,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.6*et,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.6*et,.8*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,.8*nt).close());var mt=.1,Pt=Nt*.1,kt=.2,Tt=.9,Dt=new go.PathFigure((kt-mt)*et,Tt*nt,!0);dt.add(Dt),Dt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt-mt)*nt,(kt-mt)*et,(Tt-Pt)*nt,(kt-Pt)*et,(Tt-mt)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,(kt+mt)*et,Tt*nt,(kt+Pt)*et,(Tt-mt)*nt,(kt+mt)*et,(Tt-Pt)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt+mt)*nt,(kt+mt)*et,(Tt+Pt)*nt,(kt+Pt)*et,(Tt+mt)*nt)),Dt.add(new go.PathSegment(go.PathSegment.Bezier,(kt-mt)*et,Tt*nt,(kt-Pt)*et,(Tt+mt)*nt,(kt-mt)*et,(Tt+Pt)*nt).close()),mt=.1,Pt=Nt*.1,kt=.8,Tt=.9;var $t=new go.PathFigure((kt-mt)*et,Tt*nt,!0);return dt.add($t),$t.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt-mt)*nt,(kt-mt)*et,(Tt-Pt)*nt,(kt-Pt)*et,(Tt-mt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,(kt+mt)*et,Tt*nt,(kt+Pt)*et,(Tt-mt)*nt,(kt+mt)*et,(Tt-Pt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,kt*et,(Tt+mt)*nt,(kt+mt)*et,(Tt+Pt)*nt,(kt+Pt)*et,(Tt+mt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,(kt-mt)*et,Tt*nt,(kt-Pt)*et,(Tt+mt)*nt,(kt-mt)*et,(Tt+Pt)*nt).close()),dt}),go.Shape.defineFigureGenerator("KanbanPost",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.2*et,0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,0)),at.add(new go.PathSegment(go.PathSegment.Move,.5*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,nt)),at.add(new go.PathSegment(go.PathSegment.Move,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,nt)),dt}),go.Shape.defineFigureGenerator("Forklift",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.4*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,0,0));var gt=new go.PathFigure(0,.5*nt,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,0,.8*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.8*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt));var mt=new go.PathFigure(.5*et,.8*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.1*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.1*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.8*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.8*nt));var Pt=new go.PathFigure(.5*et,.7*nt,!1);dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et,.7*nt));var kt=.1,Tt=Nt*.1,Dt=.1,$t=.9,ie=new go.PathFigure((Dt-kt)*et,$t*nt,!0);dt.add(ie),ie.add(new go.PathSegment(go.PathSegment.Bezier,Dt*et,($t-kt)*nt,(Dt-kt)*et,($t-Tt)*nt,(Dt-Tt)*et,($t-kt)*nt)),ie.add(new go.PathSegment(go.PathSegment.Bezier,(Dt+kt)*et,$t*nt,(Dt+Tt)*et,($t-kt)*nt,(Dt+kt)*et,($t-Tt)*nt)),ie.add(new go.PathSegment(go.PathSegment.Bezier,Dt*et,($t+kt)*nt,(Dt+kt)*et,($t+Tt)*nt,(Dt+Tt)*et,($t+kt)*nt)),ie.add(new go.PathSegment(go.PathSegment.Bezier,(Dt-kt)*et,$t*nt,(Dt-Tt)*et,($t+kt)*nt,(Dt-kt)*et,($t+Tt)*nt)),kt=.1,Tt=Nt*.1,Dt=.4,$t=.9;var Yt=new go.PathFigure((Dt-kt)*et,$t*nt,!0);return dt.add(Yt),Yt.add(new go.PathSegment(go.PathSegment.Bezier,Dt*et,($t-kt)*nt,(Dt-kt)*et,($t-Tt)*nt,(Dt-Tt)*et,($t-kt)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(Dt+kt)*et,$t*nt,(Dt+Tt)*et,($t-kt)*nt,(Dt+kt)*et,($t-Tt)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,Dt*et,($t+kt)*nt,(Dt+kt)*et,($t+Tt)*nt,(Dt+Tt)*et,($t+kt)*nt)),Yt.add(new go.PathSegment(go.PathSegment.Bezier,(Dt-kt)*et,$t*nt,(Dt-Tt)*et,($t+kt)*nt,(Dt-kt)*et,($t+Tt)*nt)),dt}),go.Shape.defineFigureGenerator("RailShipment",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.1*et,.4*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.45*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.45*et,.9*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,.9*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,.4*nt).close());var gt=new go.PathFigure(.45*et,.7*nt,!1);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.7*nt));var mt=new go.PathFigure(.55*et,.4*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.9*et,.4*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.9*et,.9*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.9*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.55*et,.4*nt).close());var Dt=.05,$t=Nt*.05,ie=.175,Yt=.95,Pt=new go.PathFigure((ie-Dt)*et,Yt*nt,!0);dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Bezier,ie*et,(Yt-Dt)*nt,(ie-Dt)*et,(Yt-$t)*nt,(ie-$t)*et,(Yt-Dt)*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,(ie+Dt)*et,Yt*nt,(ie+$t)*et,(Yt-Dt)*nt,(ie+Dt)*et,(Yt-$t)*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,ie*et,(Yt+Dt)*nt,(ie+Dt)*et,(Yt+$t)*nt,(ie+$t)*et,(Yt+Dt)*nt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,(ie-Dt)*et,Yt*nt,(ie-$t)*et,(Yt+Dt)*nt,(ie-Dt)*et,(Yt+$t)*nt));var Dt=.05,$t=Nt*.05,ie=.375,Yt=.95,kt=new go.PathFigure((ie-Dt)*et,Yt*nt,!0);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,ie*et,(Yt-Dt)*nt,(ie-Dt)*et,(Yt-$t)*nt,(ie-$t)*et,(Yt-Dt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(ie+Dt)*et,Yt*nt,(ie+$t)*et,(Yt-Dt)*nt,(ie+Dt)*et,(Yt-$t)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,ie*et,(Yt+Dt)*nt,(ie+Dt)*et,(Yt+$t)*nt,(ie+$t)*et,(Yt+Dt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(ie-Dt)*et,Yt*nt,(ie-$t)*et,(Yt+Dt)*nt,(ie-Dt)*et,(Yt+$t)*nt));var Dt=.05,$t=Nt*.05,ie=.625,Yt=.95,Tt=new go.PathFigure((ie-Dt)*et,Yt*nt,!0);dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Bezier,ie*et,(Yt-Dt)*nt,(ie-Dt)*et,(Yt-$t)*nt,(ie-$t)*et,(Yt-Dt)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,(ie+Dt)*et,Yt*nt,(ie+$t)*et,(Yt-Dt)*nt,(ie+Dt)*et,(Yt-$t)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,ie*et,(Yt+Dt)*nt,(ie+Dt)*et,(Yt+$t)*nt,(ie+$t)*et,(Yt+Dt)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,(ie-Dt)*et,Yt*nt,(ie-$t)*et,(Yt+Dt)*nt,(ie-Dt)*et,(Yt+$t)*nt));var Dt=.05,$t=Nt*.05,ie=.825,Yt=.95,fe=new go.PathFigure((ie-Dt)*et,Yt*nt,!0);dt.add(fe),fe.add(new go.PathSegment(go.PathSegment.Bezier,ie*et,(Yt-Dt)*nt,(ie-Dt)*et,(Yt-$t)*nt,(ie-$t)*et,(Yt-Dt)*nt)),fe.add(new go.PathSegment(go.PathSegment.Bezier,(ie+Dt)*et,Yt*nt,(ie+$t)*et,(Yt-Dt)*nt,(ie+Dt)*et,(Yt-$t)*nt)),fe.add(new go.PathSegment(go.PathSegment.Bezier,ie*et,(Yt+Dt)*nt,(ie+Dt)*et,(Yt+$t)*nt,(ie+$t)*et,(Yt+Dt)*nt)),fe.add(new go.PathSegment(go.PathSegment.Bezier,(ie-Dt)*et,Yt*nt,(ie-$t)*et,(Yt+Dt)*nt,(ie-Dt)*et,(Yt+$t)*nt).close());var Zt=new go.PathFigure(0,nt,!1);return dt.add(Zt),Zt.add(new go.PathSegment(go.PathSegment.Line,et,nt).close()),dt}),go.Shape.defineFigureGenerator("Warehouse",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,0).close());var gt=new go.PathFigure(0,.2*nt,!1);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,.2*nt).close());var mt=new go.PathFigure(.15*et,nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.15*et,.5*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.4*et,.5*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.4*et,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.15*et,nt).close());var Pt=.05,kt=Nt*.05,Tt=.35,Dt=.775,$t=new go.PathFigure((Tt-Pt)*et,Dt*nt,!0);return dt.add($t),$t.add(new go.PathSegment(go.PathSegment.Bezier,Tt*et,(Dt-Pt)*nt,(Tt-Pt)*et,(Dt-kt)*nt,(Tt-kt)*et,(Dt-Pt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,(Tt+Pt)*et,Dt*nt,(Tt+kt)*et,(Dt-Pt)*nt,(Tt+Pt)*et,(Dt-kt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,Tt*et,(Dt+Pt)*nt,(Tt+Pt)*et,(Dt+kt)*nt,(Tt+kt)*et,(Dt+Pt)*nt)),$t.add(new go.PathSegment(go.PathSegment.Bezier,(Tt-Pt)*et,Dt*nt,(Tt-kt)*et,(Dt+Pt)*nt,(Tt-Pt)*et,(Dt+kt)*nt).close()),dt}),go.Shape.defineFigureGenerator("ControlCenter",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Move,.1*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,.8*nt).close()),dt}),go.Shape.defineFigureGenerator("Bluetooth",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.75*nt,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.25*nt)),dt}),go.Shape.defineFigureGenerator("Bookmark",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,0,0)),at.add(new go.PathSegment(go.PathSegment.Move,.2*et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.2*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,.4*nt)),dt}),go.Shape.defineFigureGenerator("Bookmark",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),at.add(new go.PathSegment(go.PathSegment.Line,0,0)),at.add(new go.PathSegment(go.PathSegment.Move,.2*et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.2*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.8*et,.4*nt)),dt}),go.Shape.defineFigureGenerator("Globe",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Move,0,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.5*et,0)),at.add(new go.PathSegment(go.PathSegment.Bezier,et,.5*nt,.75*et,0,et,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt,et,.75*nt,.75*et,nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*nt,.25*et,nt,0,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,0,0,.25*nt,.25*et,0)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,nt,.15*et,.25*nt,.15*et,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,0,.85*et,.75*nt,.85*et,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.1675*et,.15*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.8325*et,.15*nt,.35*et,.3*nt,.65*et,.3*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.1675*et,.85*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.8325*et,.85*nt,.35*et,.7*nt,.65*et,.7*nt)),dt}),go.Shape.defineFigureGenerator("Wave",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.25*nt,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Bezier,.3*et,.25*nt,.1*et,0,.2*et,0)),at.add(new go.PathSegment(go.PathSegment.Bezier,.7*et,.25*nt,.425*et,.5*nt,.575*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,et,.25*nt,.8*et,0,.9*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Move,0,.25*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.75*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.3*et,.75*nt,.1*et,.5*nt,.2*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.7*et,.75*nt,.425*et,nt,.575*et,nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,et,.75*nt,.8*et,.5*nt,.9*et,.5*nt)),dt}),go.Shape.defineFigureGenerator("Operator",function(It,et,nt){var dt=new go.Geometry,at=.3,gt=Nt*.3,mt=.5,Pt=.7,kt=new go.PathFigure((mt-at)*et,Pt*nt,!0);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+at)*et,Pt*nt,(mt+gt)*et,(Pt-at)*nt,(mt+at)*et,(Pt-gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-at)*et,Pt*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt));var Tt=new go.PathFigure(0,.7*nt,!1);return dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Bezier,et,.7*nt,0,0,et,0)),dt}),go.Shape.defineFigureGenerator("TripleFanBlades",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.5*et,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.65*nt,.65*et,.3*nt,.65*et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,0,.35*et,.5*nt,.35*et,.3*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.5*et,.65*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,nt,.3*et,.6*nt,.1*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.65*nt,.2*et,nt,.35*et,.95*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.5*et,.65*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,et,nt,.7*et,.6*nt,.9*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.65*nt,.8*et,nt,.65*et,.95*nt)),dt}),go.Shape.defineFigureGenerator("CentrifugalPump",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et,0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.4*et,0)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*nt,0,.075*nt,0,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.4*et,nt,0,nt,.4*et,nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.8*et,.4*nt,.8*et,nt,.85*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,0)),dt}),go.Shape.defineFigureGenerator("Battery",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Move,.4*et,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.4*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,.1*nt));var gt=new go.PathFigure(0,.6*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Move,0,.4*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,et,.4*nt)),dt}),go.Shape.defineFigureGenerator("Delete",function(It,et,nt){var dt=new go.Geometry,at=.5,gt=Nt*.5,mt=.5,Pt=.5,kt=new go.PathFigure((mt-at)*et,Pt*nt,!0);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+at)*et,Pt*nt,(mt+gt)*et,(Pt-at)*nt,(mt+at)*et,(Pt-gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-at)*et,Pt*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt));var Tt=new go.PathFigure(.15*et,.5*nt,!1);return dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Line,.85*et,.5*nt)),dt}),go.Shape.defineFigureGenerator("Flag",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.1*nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Move,0,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.1*nt,.15*et,0,.35*et,0)),at.add(new go.PathSegment(go.PathSegment.Bezier,et,.1*nt,.65*et,.2*nt,.85*et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.5*nt,.85*et,.6*nt,.65*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,.5*nt,.35*et,.4*nt,.15*et,.4*nt).close()),dt}),go.Shape.defineFigureGenerator("Help",function(It,et,nt){var dt=new go.Geometry,at=.5,gt=Nt*.5,mt=.5,Pt=.5,kt=new go.PathFigure((mt-at)*et,Pt*nt,!1);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+at)*et,Pt*nt,(mt+gt)*et,(Pt-at)*nt,(mt+at)*et,(Pt-gt)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),kt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-at)*et,Pt*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt).close()),at=.05,gt=Nt*.05,mt=.5,Pt=.8;var Tt=new go.PathFigure((mt-at)*et,Pt*nt,!1);return dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt-at)*nt,(mt-at)*et,(Pt-gt)*nt,(mt-gt)*et,(Pt-at)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,(mt+at)*et,Pt*nt,(mt+gt)*et,(Pt-at)*nt,(mt+at)*et,(Pt-gt)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,mt*et,(Pt+at)*nt,(mt+at)*et,(Pt+gt)*nt,(mt+gt)*et,(Pt+at)*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,(mt-at)*et,Pt*nt,(mt-gt)*et,(Pt+at)*nt,(mt-at)*et,(Pt+gt)*nt).close()),Tt.add(new go.PathSegment(go.PathSegment.Move,.5*et,.7*nt)),Tt.add(new go.PathSegment(go.PathSegment.Line,.5*et,.5*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,.5*et,.2*nt,.75*et,.475*nt,.75*et,.225*nt)),Tt.add(new go.PathSegment(go.PathSegment.Bezier,.3*et,.35*nt,.4*et,.2*nt,.3*et,.25*nt)),dt}),go.Shape.defineFigureGenerator("Location",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(.5*et,nt,!0).add(new go.PathSegment(go.PathSegment.Line,.75*et,.5*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.5*et,0,.975*et,.025*nt,.5*et,0)).add(new go.PathSegment(go.PathSegment.Bezier,.25*et,.5*nt,.5*et,0,.025*et,.025*nt).close()).add(new go.PathSegment(go.PathSegment.Move,.5*et,.2*nt)).add(new go.PathSegment(go.PathSegment.Arc,270,360,.5*et,.3*nt,.1*et,.1*nt).close()))}),go.Shape.defineFigureGenerator("Lock",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.5*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt));var gt=new go.PathFigure(.2*et,.5*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Move,.2*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.2*et,.3*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,.8*et,.3*nt,.25*et,0,.75*et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.3*nt)),dt}),go.Shape.defineFigureGenerator("Unlocked",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.5*nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,.5*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.5*nt));var gt=new go.PathFigure(.2*et,.5*nt,!1);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Move,.2*et,.5*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.2*et,.3*nt)),gt.add(new go.PathSegment(go.PathSegment.Bezier,.8*et,.3*nt,.25*et,0,.75*et,0)),gt.add(new go.PathSegment(go.PathSegment.Line,.8*et,.35*nt)),dt}),go.Shape.defineFigureGenerator("Gear",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(.9375*et,.56246875*nt,!0).add(new go.PathSegment(go.PathSegment.Line,.9375*et,.4375*nt)).add(new go.PathSegment(go.PathSegment.Line,.80621875*et,.4375*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.763*et,.3316875*nt,.79840625*et,.39915625*nt,.7834375*et,.3635*nt)).add(new go.PathSegment(go.PathSegment.Line,.8566875*et,.23796875*nt)).add(new go.PathSegment(go.PathSegment.Line,.76825*et,.14959375*nt)).add(new go.PathSegment(go.PathSegment.Line,.67596875*et,.24184375*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.5625*et,.19378125*nt,.64228125*et,.2188125*nt,.603875*et,.2021875*nt)).add(new go.PathSegment(go.PathSegment.Line,.5625*et,.0625*nt)).add(new go.PathSegment(go.PathSegment.Line,.4375*et,.0625*nt)).add(new go.PathSegment(go.PathSegment.Line,.4375*et,.19378125*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.32775*et,.239375*nt,.39759375*et,.20190625*nt,.36053125*et,.2176875*nt)).add(new go.PathSegment(go.PathSegment.Line,.2379375*et,.14959375*nt)).add(new go.PathSegment(go.PathSegment.Line,.14953125*et,.2379375*nt)).add(new go.PathSegment(go.PathSegment.Line,.23934375*et,.3278125*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.19378125*et,.4375*nt,.21765625*et,.36059375*nt,.201875*et,.397625*nt)).add(new go.PathSegment(go.PathSegment.Line,.0625*et,.4375*nt)).add(new go.PathSegment(go.PathSegment.Line,.0625*et,.5625*nt)).add(new go.PathSegment(go.PathSegment.Line,.1938125*et,.5625*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.241875*et,.67596875*nt,.20221875*et,.603875*nt,.21884375*et,.64228125*nt)).add(new go.PathSegment(go.PathSegment.Line,.1495625*et,.76825*nt)).add(new go.PathSegment(go.PathSegment.Line,.238*et,.8566875*nt)).add(new go.PathSegment(go.PathSegment.Line,.3316875*et,.76296875*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.43753125*et,.80621875*nt,.36353125*et,.78340625*nt,.3991875*et,.79840625*nt)).add(new go.PathSegment(go.PathSegment.Line,.43753125*et,.9375*nt)).add(new go.PathSegment(go.PathSegment.Line,.5625*et,.9375*nt)).add(new go.PathSegment(go.PathSegment.Line,.5625*et,.80621875*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.67225*et,.760625*nt,.602375*et,.79809375*nt,.63946875*et,.78234375*nt)).add(new go.PathSegment(go.PathSegment.Line,.76828125*et,.8566875*nt)).add(new go.PathSegment(go.PathSegment.Line,.85671875*et,.76825*nt)).add(new go.PathSegment(go.PathSegment.Line,.76065625*et,.67221875*nt)).add(new go.PathSegment(go.PathSegment.Bezier,.80621875*et,.56246875*nt,.78234375*et,.63940625*nt,.798125*et,.602375*nt)).add(new go.PathSegment(go.PathSegment.Line,.9375*et,.56246875*nt).close()).add(new go.PathSegment(go.PathSegment.Move,.5*et,.6*nt)).add(new go.PathSegment(go.PathSegment.Arc,90,360,.5*et,.5*nt,.1*et,.1*nt).close()))}),go.Shape.defineFigureGenerator("Hand",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.5*nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Bezier,.1*et,.3*nt,0,.375*nt,.05*et,.325*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.45*et,.075*nt,.3*et,.225*nt,.4*et,.175*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.525*et,.075*nt,.46*et,.05*nt,.525*et,.05*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.3*et,.4*nt,.525*et,.275*nt,.475*et,.325*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.9*et,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.9*et,.55*nt,et,.4*nt,et,.55*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.425*et,.55*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,.55*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.6*et,.7*nt,.675*et,.55*nt,.675*et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.4*et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.575*et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.575*et,.85*nt,.65*et,.7*nt,.65*et,.85*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.4*et,.85*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.525*et,.85*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.535*et,nt,.61*et,.85*nt,.61*et,nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,0,.9*nt,.435*et,nt,0,nt).close()),dt}),go.Shape.defineFigureGenerator("Map",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,.2*nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.25*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,.25*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt).close()),at.add(new go.PathSegment(go.PathSegment.Move,.25*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.25*et,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Move,.5*et,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt)),at.add(new go.PathSegment(go.PathSegment.Move,.75*et,0)),at.add(new go.PathSegment(go.PathSegment.Line,.75*et,.8*nt)),dt}),go.Shape.defineFigureGenerator("Eject",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et,nt)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt*.7)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt*.7).close());var gt=new go.PathFigure(0,nt*.6,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et,.6*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.5*et,0).close()),dt}),go.Shape.defineFigureGenerator("Pencil",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,.2*et,.1*nt)).add(new go.PathSegment(go.PathSegment.Line,et,.9*nt)).add(new go.PathSegment(go.PathSegment.Line,.9*et,nt)).add(new go.PathSegment(go.PathSegment.Line,.1*et,.2*nt).close()))}),go.Shape.defineFigureGenerator("Building",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*1,nt*1,!1);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt*.85)),at.add(new go.PathSegment(go.PathSegment.Line,.046*et,nt*.85)),at.add(new go.PathSegment(go.PathSegment.Line,.046*et,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt*.3)),at.add(new go.PathSegment(go.PathSegment.Line,.046*et,nt*.3)),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,(1-.046)*et,nt*.3)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt*.3)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,(1-.046)*et,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,(1-.046)*et,nt*.85)),at.add(new go.PathSegment(go.PathSegment.Line,et,nt*.85).close());var gt=new go.PathFigure(.126*et,.85*nt,!1);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,.126*et,.45*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.322*et,.45*nt)),gt.add(new go.PathSegment(go.PathSegment.Line,.322*et,.85*nt).close());var mt=new go.PathFigure(.402*et,.85*nt,!1);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,.402*et,.45*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.598*et,.45*nt)),mt.add(new go.PathSegment(go.PathSegment.Line,.598*et,.85*nt).close());var Pt=new go.PathFigure(.678*et,.85*nt,!1);dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,.678*et,.45*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.874*et,.45*nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,.874*et,.85*nt).close());var kt=new go.PathFigure(.5*et,.1*nt,!1);return dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Line,(.046+.15)*et,.3*nt)),kt.add(new go.PathSegment(go.PathSegment.Line,(1-(.046+.15))*et,.3*nt).close()),dt}),go.Shape.defineFigureGenerator("Staircase",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt*1,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et*.2,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.2,nt*.8)),at.add(new go.PathSegment(go.PathSegment.Line,et*.4,nt*.8)),at.add(new go.PathSegment(go.PathSegment.Line,et*.4,nt*.6)),at.add(new go.PathSegment(go.PathSegment.Line,et*.6,nt*.6)),at.add(new go.PathSegment(go.PathSegment.Line,et*.6,nt*.4)),at.add(new go.PathSegment(go.PathSegment.Line,et*.8,nt*.4)),at.add(new go.PathSegment(go.PathSegment.Line,et*.8,nt*.2)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*.2)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*.15)),at.add(new go.PathSegment(go.PathSegment.Line,et*.75,nt*.15)),at.add(new go.PathSegment(go.PathSegment.Line,et*.75,nt*.35)),at.add(new go.PathSegment(go.PathSegment.Line,et*.55,nt*.35)),at.add(new go.PathSegment(go.PathSegment.Line,et*.55,nt*.55)),at.add(new go.PathSegment(go.PathSegment.Line,et*.35,nt*.55)),at.add(new go.PathSegment(go.PathSegment.Line,et*.35,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.15,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.15,nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt*.95).close()),dt}),go.Shape.defineFigureGenerator("5Bars",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,nt*1,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et*.184,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.184,nt*(1-.184)).close());var gt=new go.PathFigure(et*.204,nt,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et*.204,nt*(1-.184))),gt.add(new go.PathSegment(go.PathSegment.Line,et*.388,nt*(1-.184*2))),gt.add(new go.PathSegment(go.PathSegment.Line,et*.388,nt*1).close());var mt=new go.PathFigure(et*.408,nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et*.408,nt*(1-.184*2))),mt.add(new go.PathSegment(go.PathSegment.Line,et*.592,nt*(1-.184*3))),mt.add(new go.PathSegment(go.PathSegment.Line,et*.592,nt*1).close());var Pt=new go.PathFigure(et*.612,nt,!0);dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.612,nt*(1-.184*3))),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.796,nt*(1-.184*4))),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.796,nt*1).close());var kt=new go.PathFigure(et*.816,nt,!0);return dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Line,et*.816,nt*(1-.184*4))),kt.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*(1-.184*5))),kt.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*1).close()),dt}),go.Shape.defineFigureGenerator("PC",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,0,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.3,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.3,0).close());var gt=new go.PathFigure(et*.055,.07*nt,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et*.245,nt*.07)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.245,nt*.1)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.055,nt*.1).close());var mt=new go.PathFigure(et*.055,.13*nt,!0);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et*.245,nt*.13)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.245,nt*.16)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.055,nt*.16).close());var Pt=new go.PathFigure(et*.055,.18*nt,!0);dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.245,nt*.18)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.245,nt*.21)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.055,nt*.21).close());var kt=new go.PathFigure(et*1,0,!0);return dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Line,et*.4,0)),kt.add(new go.PathSegment(go.PathSegment.Line,et*.4,nt*.65)),kt.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*.65).close()),dt}),go.Shape.defineFigureGenerator("Plane",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(.55*et,nt,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,.5*et,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.4*et,.7*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.1*et,.475*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.35*et,.525*nt,0,.4*nt,.225*et,.45*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.4*et,.475*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.15*et,.35*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.2*et,.325*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,.325*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.85*et,.1*nt)),at.add(new go.PathSegment(go.PathSegment.Bezier,.9*et,.2*nt,.975*et,0,et,.08*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.7*et,.45*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.6*et,.95*nt)),at.add(new go.PathSegment(go.PathSegment.Line,.55*et,nt).close()),dt}),go.Shape.defineFigureGenerator("Key",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*1,nt*.5,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et*.9,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,.4*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,.35*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.45,.35*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.3,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.15,.2*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.35*nt)),at.add(new go.PathSegment(go.PathSegment.Line,0,.65*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.15,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.3,.8*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.45,.65*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,.65*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.6,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.65,.55*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.7,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.75,.55*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.8,.6*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.85,.575*nt)),at.add(new go.PathSegment(go.PathSegment.Line,et*.9,.6*nt).close()),at.add(new go.PathSegment(go.PathSegment.Move,.17*et,.425*nt)),at.add(new go.PathSegment(go.PathSegment.Arc,270,360,.17*et,.5*nt,.075*et,.075*nt).close()),dt}),go.Shape.defineFigureGenerator("FilmTape",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(0,0,!1);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Arc,270,180,et*0,et*.3,et*.055)),at.add(new go.PathSegment(go.PathSegment.Line,0,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.08,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.08,nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*1),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*1),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*2),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*2),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*3),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*3),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*4),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*4),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*5),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*5),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*6),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*6),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*7),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*7),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*8),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*8),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*9),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*9),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*10),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*10),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*11),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*11),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*12),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*12),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*13),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*13),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*14),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*14),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*15),nt*.95)),at.add(new go.PathSegment(go.PathSegment.Line,et*(.08+.056*15),nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*1));var gt=new go.PathFigure(0,0,!1);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*0)),gt.add(new go.PathSegment(go.PathSegment.Arc,270,-180,et*1,et*.3,et*.055)),gt.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*1));var mt=new go.PathFigure(et*.11,nt*.1,!1);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et*(.11+.24133333*1+.028*0),nt*.1)),mt.add(new go.PathSegment(go.PathSegment.Line,et*(.11+.24133333*1+.028*0),nt*.8)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.11,nt*.8).close());var Pt=new go.PathFigure(et*(.11+.24133333*1+.028*1),nt*.1,!1);dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et*(.11+.24133333*2+.028*1),nt*.1)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*(.11+.24133333*2+.028*1),nt*.8)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*(.11+.24133333*1+.028*1),nt*.8).close());var kt=new go.PathFigure(et*(.11+.24133333*2+.028*2),nt*.1,!1);return dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Line,et*(.11+.24133333*3+.028*2),nt*.1)),kt.add(new go.PathSegment(go.PathSegment.Line,et*(.11+.24133333*3+.028*2),nt*.8)),kt.add(new go.PathSegment(go.PathSegment.Line,et*(.11+.24133333*2+.028*2),nt*.8).close()),dt}),go.Shape.defineFigureGenerator("FloppyDisk",function(It,et,nt){var dt=new go.Geometry,at=8,gt=at*Nt,mt=new go.PathFigure(at,0,!1);dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et*.86,0)),mt.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*.14)),mt.add(new go.PathSegment(go.PathSegment.Line,et,nt-at)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et-at,nt,et,nt-gt,et-gt,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,at,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,nt-at,gt,nt,0,nt-gt)),mt.add(new go.PathSegment(go.PathSegment.Line,0,at)),mt.add(new go.PathSegment(go.PathSegment.Bezier,at,0,0,gt,gt,0).close());var Pt=new go.PathFigure(et*.83,0,!1);dt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.83,nt*.3)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.17,nt*.3)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.17,nt*0).close());var kt=new go.PathFigure(et*.83,nt*1,!1);dt.add(kt),kt.add(new go.PathSegment(go.PathSegment.Line,et*.83,nt*.5)),kt.add(new go.PathSegment(go.PathSegment.Line,et*.17,nt*.5)),kt.add(new go.PathSegment(go.PathSegment.Line,et*.17,nt*1).close());var Tt=new go.PathFigure(et*.78,nt*.05,!1);return dt.add(Tt),Tt.add(new go.PathSegment(go.PathSegment.Line,et*.66,nt*.05)),Tt.add(new go.PathSegment(go.PathSegment.Line,et*.66,nt*.25)),Tt.add(new go.PathSegment(go.PathSegment.Line,et*.78,nt*.25).close()),dt}),go.Shape.defineFigureGenerator("SpeechBubble",function(It,et,nt){var dt=It?It.parameter1:NaN;(isNaN(dt)||dt<0)&&(dt=15),dt=Math.min(dt,et/3),dt=Math.min(dt,nt/3);var at=dt*Nt,gt=nt*.8,mt=new go.Geometry,Pt=new go.PathFigure(dt,0,!0);return mt.add(Pt),Pt.add(new go.PathSegment(go.PathSegment.Line,et-dt,0)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,et,dt,et-at,0,et,at)),Pt.add(new go.PathSegment(go.PathSegment.Line,et,gt-dt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,et-dt,gt,et,gt-at,et-at,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.7,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.7,nt)),Pt.add(new go.PathSegment(go.PathSegment.Line,et*.55,gt)),Pt.add(new go.PathSegment(go.PathSegment.Line,dt,gt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,0,gt-dt,at,gt,0,gt-at)),Pt.add(new go.PathSegment(go.PathSegment.Line,0,dt)),Pt.add(new go.PathSegment(go.PathSegment.Bezier,dt,0,0,at,at,0).close()),at>1?(mt.spot1=new go.Spot(0,0,at,at),mt.spot2=new go.Spot(1,.8,-at,-at)):(mt.spot1=go.Spot.TopLeft,mt.spot2=new go.Spot(1,.8)),mt}),go.Shape.defineFigureGenerator("Repeat",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*0,nt*.45,!0);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et*.25,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,et*.3,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,et*.3,nt*.9)),at.add(new go.PathSegment(go.PathSegment.Line,et*.6,nt*.9)),at.add(new go.PathSegment(go.PathSegment.Line,et*.65,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.2,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.2,nt*.45).close());var gt=new go.PathFigure(et*1,nt*.55,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et*.75,nt*1)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.5,nt*.55)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.7,nt*.55)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.7,nt*.1)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.4,nt*.1)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.35,nt*0)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.8,nt*0)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.8,nt*.55).close()),dt}),go.Shape.defineFigureGenerator("Windows",function(It,et,nt){return new go.Geometry().add(new go.PathFigure(0,0,!0).add(new go.PathSegment(go.PathSegment.Line,et,0)).add(new go.PathSegment(go.PathSegment.Line,et,nt)).add(new go.PathSegment(go.PathSegment.Line,0,nt).close()).add(new go.PathSegment(go.PathSegment.Move,.4*et,.4*nt)).add(new go.PathSegment(go.PathSegment.Line,.4*et,.8*nt)).add(new go.PathSegment(go.PathSegment.Line,.9*et,.8*nt)).add(new go.PathSegment(go.PathSegment.Line,.9*et,.4*nt).close()).add(new go.PathSegment(go.PathSegment.Move,.2*et,.1*nt)).add(new go.PathSegment(go.PathSegment.Line,.2*et,.6*nt)).add(new go.PathSegment(go.PathSegment.Line,.7*et,.6*nt)).add(new go.PathSegment(go.PathSegment.Line,.7*et,.1*nt).close()).add(new go.PathSegment(go.PathSegment.Move,.1*et,.6*nt)).add(new go.PathSegment(go.PathSegment.Line,.1*et,.9*nt)).add(new go.PathSegment(go.PathSegment.Line,.5*et,.9*nt)).add(new go.PathSegment(go.PathSegment.Line,.5*et,.6*nt).close()))}),go.Shape.defineFigureGenerator("Terminal",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*0,nt*.1,!1);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*.1)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*.9)),at.add(new go.PathSegment(go.PathSegment.Line,et*0,nt*.9).close());var gt=new go.PathFigure(et*.1,nt*.2,!0);dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et*.1,nt*.25)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.22,nt*.285)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.1,nt*.32)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.1,nt*.37)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.275,nt*.32)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.275,nt*.25).close());var mt=new go.PathFigure(et*.28,nt*.37,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et*.45,nt*.37)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.45,nt*.41)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.28,nt*.41).close()),dt}),go.Shape.defineFigureGenerator("Beaker",function(It,et,nt){var dt=new go.Geometry,at=15,gt=at*Nt,mt=new go.PathFigure(et*.62,nt*.475,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et,nt-at)),mt.add(new go.PathSegment(go.PathSegment.Bezier,et-at,nt,et,nt-gt,et-gt,nt)),mt.add(new go.PathSegment(go.PathSegment.Line,at,nt)),mt.add(new go.PathSegment(go.PathSegment.Bezier,0,nt-at,gt,nt,0,nt-gt)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.38,nt*.475)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.38,nt*.03)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.36,nt*0)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.64,nt*0)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.62,nt*.03).close()),gt>1?(dt.spot1=new go.Spot(0,0,gt,gt),dt.spot2=new go.Spot(1,1,-gt,-gt)):(dt.spot1=go.Spot.TopLeft,dt.spot2=go.Spot.BottomRight),dt}),go.Shape.defineFigureGenerator("Download",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*0,nt*1,!0);dt.add(at);var gt=.1/.3;at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.8,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.66,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.66,nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*.755,nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*.93,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.64,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.61,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.39,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.36,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.07,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.755),nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.66),nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.66),nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.8),nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*0,nt*(1-gt)).close());var mt=new go.PathFigure(et*.4,nt*0,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et*.4,nt*.44)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.26,nt*.44)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.5,nt*.66)),mt.add(new go.PathSegment(go.PathSegment.Line,et*(1-.26),nt*.44)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.6,nt*.44)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.6,nt*0).close()),dt}),go.Shape.defineFigureGenerator("Bin",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*0,nt*1,!0);dt.add(at);var gt=.1/.3;return at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.8,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.66,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.66,nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*.755,nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*.93,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.64,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.61,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.39,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.36,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.07,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.755),nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.66),nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.66),nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.8),nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*0,nt*(1-gt)).close()),dt}),go.Shape.defineFigureGenerator("Upload",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*0,nt*1,!0);dt.add(at);var gt=.1/.3;at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.8,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.66,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.66,nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*.755,nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*.93,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.64,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.61,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.39,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.36,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*.07,nt*(1-gt))),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.755),nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.66),nt*.055)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.66),nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*(1-.8),nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*0,nt*(1-gt)).close());var mt=new go.PathFigure(et*.5,nt*0,!0);return dt.add(mt),mt.add(new go.PathSegment(go.PathSegment.Line,et*.26,nt*.25)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.4,nt*.25)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.4,nt*.63)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.6,nt*.63)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.6,nt*.25)),mt.add(new go.PathSegment(go.PathSegment.Line,et*.74,nt*.25).close()),dt}),go.Shape.defineFigureGenerator("EmptyDrink",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*.15,nt*0,!1);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et*.85,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.7,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.3,nt*1).close()),dt}),go.Shape.defineFigureGenerator("Drink",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*.15,nt*0,!1);dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et*.85,nt*0)),at.add(new go.PathSegment(go.PathSegment.Line,et*.7,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.3,nt*1).close());var gt=new go.PathFigure(et*.235,nt*.28,!0);return dt.add(gt),gt.add(new go.PathSegment(go.PathSegment.Line,et*.765,nt*.28)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.655,nt*.97)),gt.add(new go.PathSegment(go.PathSegment.Line,et*.345,nt*.97).close()),dt}),go.Shape.defineFigureGenerator("4Arrows",function(It,et,nt){var dt=new go.Geometry,at=new go.PathFigure(et*.5,nt*0,!0);return dt.add(at),at.add(new go.PathSegment(go.PathSegment.Line,et*.65,nt*.25)),at.add(new go.PathSegment(go.PathSegment.Line,et*.55,nt*.25)),at.add(new go.PathSegment(go.PathSegment.Line,et*.55,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,et*.75,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,et*.75,nt*.35)),at.add(new go.PathSegment(go.PathSegment.Line,et*1,nt*.5)),at.add(new go.PathSegment(go.PathSegment.Line,et*.75,nt*.65)),at.add(new go.PathSegment(go.PathSegment.Line,et*.75,nt*.55)),at.add(new go.PathSegment(go.PathSegment.Line,et*.55,nt*.55)),at.add(new go.PathSegment(go.PathSegment.Line,et*.55,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.65,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.5,nt*1)),at.add(new go.PathSegment(go.PathSegment.Line,et*.35,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.45,nt*.75)),at.add(new go.PathSegment(go.PathSegment.Line,et*.45,nt*.55)),at.add(new go.PathSegment(go.PathSegment.Line,et*.25,nt*.55)),at.add(new go.PathSegment(go.PathSegment.Line,et*.25,nt*.65)),at.add(new go.PathSegment(go.PathSegment.Line,et*0,nt*.5)),at.add(new go.PathSegment(go.PathSegment.Line,et*.25,nt*.35)),at.add(new go.PathSegment(go.PathSegment.Line,et*.25,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,et*.45,nt*.45)),at.add(new go.PathSegment(go.PathSegment.Line,et*.45,nt*.25)),at.add(new go.PathSegment(go.PathSegment.Line,et*.35,nt*.25).close()),dt}),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")},80727: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 Cn={},cn="5.0",wt={},Ft=null,Ht=!1,oe=!1,ke=null,Vt=!1,qt=null,Nt=null,Oe=0;Oe4?parseFloat(Ne):5};Cn.setHTML5Codebase=function(Ne,Ze){Nt=Ne,$e(Ne,Ze)},Cn.setJavaCodebase=Cn.setJavaCodebaseVersion=Cn.isCompiledInstalled=Cn.setPreCompiledScriptPath=Cn.setPreCompiledResourcePath=function(){},Cn.setHTML5CodebaseVersion=function(Ne,Ze){var rn=parseFloat(Ne);if(rn!==NaN&&rn<5){console.log("The GeoGebra HTML5 codebase version "+rn+" is deprecated. Using version latest instead.");return}qt=Ne,jt(Ne,Ze)},Cn.getHTML5CodebaseVersion=function(){return It},Cn.getParameters=function(){return wt},Cn.setFontsCSSURL=function(Ne){mt=Ne},Cn.setGiacJSURL=function(Ne){},Cn.setJNLPFile=function(Ne){Qt=Ne},Cn.setJNLPBaseDir=function(Ne){},Cn.inject=function(){function Ne(){return window.frameElement&&window.frameElement.getAttribute("data-singleton")}for(var Ze="auto",rn=wt.id,zn,tn=!1,Tn=0;Tn=5)return!0;var Ne=Cn.getAppletObject();return Ne&&typeof Ne.recalculateEnvironments=="function"?(Ne.recalculateEnvironments(),!0):!1},Cn.startAnimation=function(){var Ne=Cn.getAppletObject();return Ne&&typeof Ne.startAnimation=="function"?(Ne.startAnimation(),!0):!1},Cn.stopAnimation=function(){var Ne=Cn.getAppletObject();return Ne&&typeof Ne.stopAnimation=="function"?(Ne.stopAnimation(),!0):!1},Cn.getAppletObject=function(){var Ne=wt.id!==void 0?wt.id:"ggbApplet";return window[Ne]},Cn.resize=function(){};var fe=function(Ne,Ze,rn){var zn=document.createElement("param");zn.setAttribute("name",Ze),zn.setAttribute("value",rn),Ne.appendChild(zn)},Zt=function(Ne){return Ne&&Ne!=="false"},je=function(Ne,Ze,rn){kt(It)<=4.2&&(rn=!0);var zn=!isRenderGGBElementEnabled&&!scriptLoadStarted;(!isRenderGGBElementEnabled&&!scriptLoadStarted||ggbHTML5LoadedCodebaseVersion!==It||ggbHTML5LoadedCodebaseIsWebSimple&&!nt)&&(zn=!0,isRenderGGBElementEnabled=!1,scriptLoadStarted=!1);var tn=document.createElement("div");tn.classList.add("appletParameters","notranslate");var Tn=Ze.width,we=Ze.height;if(Ze.disableAutoScale=Ze.disableAutoScale===void 0?GGBAppletUtils.isFlexibleWorksheetEditor():Ze.disableAutoScale,Ze.width!==void 0)if(kt(It)<=4.4)Zt(Ze.showToolBar)&&(Ze.height-=7),Zt(Ze.showAlgebraInput)&&(Ze.height-=37),Ze.width<605&&Zt(Ze.showToolBar)&&(Ze.width=605,Tn=605);else{var Bn=100;(Zt(Ze.showToolBar)||Zt(Ze.showMenuBar))&&(Ze.hasOwnProperty("customToolBar")&&(Ze.customToolbar=Ze.customToolBar),Bn=Zt(Ze.showMenuBar)?245:155),Tn=5?(Ze.appletOnLoad=function(le){var Me=Ne.querySelector(".ggb_preview");Me&&Me.parentNode.removeChild(Me),window.GGBT_spinner&&window.GGBT_spinner.removeSpinner(Lt),window.GGBT_wsf_view&&$(window).trigger("resize"),Rt(le)},St||Lt.appendChild(Et)):tn.appendChild(Et),Lt.appendChild(tn),St||Ne.appendChild(Lt),setTimeout(function(){Cn.resize()},1)}else{var Bt=document.createElement("div");Bt.className="applet_scaler",Bt.style.position="relative",Bt.style.display="block",Bt.appendChild(tn),Ne.appendChild(Bt),Ze.appletOnLoad=function(le){Cn.resize(),Rt(le)}}function yt(le,Me){Me&&typeof Me.appletOnLoad=="function"&&typeof renderGGBElement=="function"?renderGGBElement(le,Me.appletOnLoad):renderGGBElement(le),xn("GeoGebra HTML5 applet injected and rendered with previously loaded codebase.",Me)}function ae(le,Me){typeof renderGGBElement=="undefined"?(html5AppletsToProcess===null&&(html5AppletsToProcess=[]),html5AppletsToProcess.push({article:le,params:Me}),window.renderGGBElementReady=function(){isRenderGGBElementEnabled=!0,html5AppletsToProcess!==null&&html5AppletsToProcess.length&&(html5AppletsToProcess.forEach(function(nn){yt(nn.article,nn.params)}),html5AppletsToProcess=null)},kt(It)<5&&(le.className+=" geogebraweb")):yt(le,Me)}if(zn){scriptLoadStarted=!0;for(var Pe=0;Pe0?(Jn.remove(),Lt.attr("id","fullscreencontent").show(),jQuery(Rt).append(Lt),window.dispatchEvent(new Event("resize"))):je(Jn,Ze,!1),window.GGBT_wsf_view.launchFullScreen(Rt)}else Re=zn,je(Ne,Ze,!1);if(!window.GGBT_wsf_view)for(we=0;weNe/4*3&&(Jn=Ne/4*3),Rt=Jn/5.8,Bn.setAttribute("src",at),Bn.setAttribute("width",Jn),Bn.setAttribute("height",Rt);var Lt=(Ne-Jn)/2,St=(Ze-Rt)/2;Bn.style.left=Lt+"px",Bn.style.top=St+"px",tn.appendChild(Bn)}}return tn.appendChild(we),tn},Ue=function(Ne){return Ne=Ne.toLowerCase(),Ne==="html5"||Ne==="screenshot"?Ne:"html5"},se=["web","webSimple","web3d","tablet","tablet3d","phone"],jt=function(Ne,Ze){if(It=Ne,Ze){$e(It,!0);return}var rn=!Ht;if(rn){var zn=kt(It);!isNaN(zn)&&zn<4.4&&(rn=!1)}var tn,Tn;window.location.protocol.substr(0,4)==="http"?tn=window.location.protocol:tn="http:";var we=It.indexOf("//");we>0?Tn=It:we===0?Tn=tn+It:Tn="https://www.geogebra.org/apps/5.2.814.0/";for(var Bn in se)if(It.slice(se[Bn].length*-1)===se[Bn]||It.slice((se[Bn].length+1)*-1)===se[Bn]+"/"){$e(Tn,!1);return}!GGBAppletUtils.isFlexibleWorksheetEditor()&&rn&&!Ft.is3D&&!Ft.AV&&!Ft.SV&&!Ft.CV&&!Ft.EV2&&!Ft.CP&&!Ft.PC&&!Ft.DA&&!Ft.FI&&!Ft.PV&&!Zt(wt.showToolBar)&&!Zt(wt.showMenuBar)&&!Zt(wt.showAlgebraInput)&&!Zt(wt.enableRightClick)&&(!wt.appName||wt.appName=="classic")?Tn+="webSimple/":Tn+="web3d/",$e(Tn,!1)},$e=function(Ne,Ze){if(Ne.requirejs){Fe=Ne;return}Ne.slice(-1)!=="/"&&(Ne+="/"),Fe=Ne,Ze===null&&(Ze=Ne.indexOf("http")===-1),ye=Ze,et="web.nocache.js",nt=!1;var rn=Fe.split("/");rn.length>1&&(!Ze&&rn[rn.length-2]==="webSimple"?(et="webSimple.nocache.js",nt=!0):se.indexOf(rn[rn.length-2])>=0&&(et=rn[rn.length-2]+".nocache.js")),rn=Ne.split("/"),It=rn[rn.length-3],It.substr(0,4)==="test"?It=It.substr(4,1)+"."+It.substr(5,1):(It.substr(0,3)==="war"||It.substr(0,4)==="beta")&&(It="5.0");var zn=parseFloat(It);zn!==NaN&&zn<5&&Ne.indexOf("geogebra.org")>=0&&(console.log("The GeoGebra HTML5 codebase version "+zn+" is deprecated. Using version latest instead."),jt("5.0",Ze))},xn=function(Ne,Ze){window.console&&window.console.log&&(!Ze||typeof Ze.showLogging=="undefined"||Ze.showLogging&&Ze.showLogging!=="false")&&console.log(Ne)};wt.material_id!==void 0?$t(En):En();function En(){var Ne=cn;qt!==null?Ne=qt:parseFloat(Ne)<5&&(Ne="5.0"),jt(Ne,!1),Nt!==null&&$e(Nt,ye),Vt=!0}return Cn},GGBAppletUtils=function(){"use strict";function Cn(){return window.GGBT_wsf_edit!==void 0}function cn(Vt,qt){qt!=1?(Vt.style.transformOrigin="0% 0% 0px",Vt.style.webkitTransformOrigin="0% 0% 0px",Vt.style.transform="scale("+qt+","+qt+")",Vt.style.webkitTransform="scale("+qt+","+qt+")",Vt.style.maxWidth="initial",Vt.querySelector(".ggb_preview")!==null&&(Vt.querySelector(".ggb_preview").style.maxWidth="initial"),Vt.querySelectorAll(".ggb_preview img")[0]!==void 0&&(Vt.querySelectorAll(".ggb_preview img")[0].style.maxWidth="initial"),Vt.querySelectorAll(".ggb_preview img")[1]!==void 0&&(Vt.querySelectorAll(".ggb_preview img")[1].style.maxWidth="initial")):(Vt.style.transform="none",Vt.style.webkitTransform="none")}function wt(Vt,qt,Nt,Oe,be,Qt){var Fe=null;if(Qt!=null&&Qt!="")for(var ye=Vt.parentNode;ye!=null;)if((" "+ye.className+" ").indexOf(" "+Qt+" ")>-1){Fe=ye;break}else ye=ye.parentNode;var Re=0,It=0,et=0,nt=0,dt=0,at=0,gt=0;if(Fe)Re=Fe.offsetWidth,It=Math.max(Oe?Fe.offsetWidth:0,Fe.offsetHeight);else{if(window.innerWidth&&document.documentElement.clientWidth?(Re=Math.min(window.innerWidth,document.documentElement.clientWidth),It=Math.min(window.innerHeight,document.documentElement.clientHeight),et=Re):(Re=window.innerWidth,It=window.innerHeight,et=window.innerWidth),Vt){var mt=Vt.getBoundingClientRect();mt.left>0&&mt.left<=Re&&(be===void 0||!be)&&(document.dir==="rtl"?(dt=Re-mt.width-mt.left,at=et<=480?10:30):(at=mt.left,dt=et<=480?10:30),nt=at+dt)}if(Vt&&typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){var Pt=Vt.getBoundingClientRect();window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionRight"?(nt=40,gt=0):window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionTop"&&(nt=0,gt=40)}}return Vt&&((Nt===void 0||!Nt)&&qt>0&&qt+nt1&&(Qt=!0)),qt&&typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()&&(Qt=!0),!(Vt.hasOwnProperty("disableAutoScale")&&Vt.disableAutoScale))be=Ft(Vt,qt,Qt,Nt,Vt.scaleContainerClass);else return Oe;return Qt&&(!Vt.hasOwnProperty("scale")||Oe===1)?be:Math.min(Oe,be)}function oe(Vt){var qt=Math.min(window.innerWidth,document.documentElement.clientWidth),Nt=Math.min(window.innerHeight,document.documentElement.clientHeight),Oe=Vt.getBoundingClientRect(),be=(qt-Oe.width)/2,Qt=(Nt-Oe.height)/2;Qt<0&&(Qt=0),Vt.style.position="relative",window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionRight"?(be<40?Vt.style.left="40px":Vt.style.left=be+"px",Vt.style.top=Qt+"px"):window.GGBT_wsf_view.getCloseBtnPosition()==="closePositionTop"&&(Qt<40?Vt.style.top="40px":Vt.style.top=Qt+"px",Vt.style.left=be+"px")}function ke(Vt,qt){var Nt=Vt.querySelector(".appletParameters");if(Nt){if(typeof window.GGBT_wsf_view=="object"&&window.GGBT_wsf_view.isFullscreen()){if(qt.id!==Nt.getAttribute("data-param-id"))return;window.GGBT_wsf_view.setCloseBtnPosition(Vt)}if(Nt.parentElement&&/fullscreen/.test(Nt.parentElement.className))return;var Oe=Ht(qt,Vt);Cn()&&Nt.setAttribute("data-param-scale",Oe);for(var be=null,Qt=0;Qt=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(Cn){alert(nb+k+ob)}}else if(j==pb&&(k=i.getAttribute(kb),k))try{e=eval(k)}catch(Cn){alert(nb+k+qb)}}}__gwt_getMetaProperty=function(Cn){var cn=c[Cn];return cn==null?null:cn},r=d,webModule.__errFn=e}function B(){function Cn(Vt){var qt=Vt.lastIndexOf(rb);qt==-1&&(qt=Vt.length);var Nt=Vt.indexOf(sb);Nt==-1&&(Nt=Vt.length);var Oe=Vt.lastIndexOf(tb,Math.min(Nt,qt));return Oe>=O?Vt.substring(O,Oe+P):W}function cn(Vt){if(!Vt.match(/^\w+:\/\//)){var qt=o.createElement(ub);qt.src=Vt+vb,Vt=Cn(qt.src)}return Vt}function wt(){var Vt=__gwt_getMetaProperty(wb);return Vt!=null?Vt:W}function Ft(){for(var Vt=o.getElementsByTagName(_),qt=O;qtO?Vt[Vt.length-P].href:W}function oe(){var Vt=o.location;return Vt.href==Vt.protocol+zb+Vt.host+Vt.pathname+Vt.search+Vt.hash}var ke=wt();return ke==W&&(ke=Ft()),ke==W&&(ke=Ht()),ke==W&&oe()&&(ke=Cn(o.location.href)),ke=cn(ke),ke}function C(Cn){return Cn.match(/^\//)||Cn.match(/^[a-zA-Z]+:\/\//)?Cn:webModule.__moduleBase+Cn}function D(){var Cn=[],cn=O,wt=[],Ft=[];function Ht(Vt){var qt=Ft[Vt](),Nt=wt[Vt];if(qt in Nt)return qt;var Oe=[];for(var be in Nt)Oe[Nt[be]]=be;throw r&&r(Vt,Oe,qt),null}if(__gwt_isKnownPropertyValue=function(Vt,qt){return qt in wt[Vt]},webModule.__getPropMap=function(){var Vt={};for(var qt in wt)wt.hasOwnProperty(qt)&&(Vt[qt]=Ht(qt));return Vt},webModule.__computePropValue=Ht,n.__gwt_activeModules[L].bindings=webModule.__getPropMap,p())return C(Bb);var oe;try{oe=Cb;var ke=oe.indexOf(Db);ke!=-1&&(cn=parseInt(oe.substring(ke+P),$),oe=oe.substring(O,ke))}catch(Vt){}return webModule.__softPermutationId=cn,C(oe+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})()},77903:function(Cn,cn,wt){"use strict";wt.d(cn,{Ax:function(){return ke},Ds:function(){return Vt},KI:function(){return Nt},SI:function(){return oe},f1:function(){return Ht}});var Ft=wt(3294);function Ht(Oe){let be=!0;if(Oe.length>0){for(let Qt=0;Qtnew Promise((et,nt)=>{var dt=mt=>{try{gt(It.next(mt))}catch(Pt){nt(Pt)}},at=mt=>{try{gt(It.throw(mt))}catch(Pt){nt(Pt)}},gt=mt=>mt.done?et(mt.value):Promise.resolve(mt.value).then(dt,at);gt((It=It.apply(ye,Re)).next())}),Fe=({data:ye,className:Re,fullWidth:It,style:et={},onClose:nt,onOk:dt,showFullTools:at,noAssociationId:gt})=>{const mt=(0,Ft.useRef)(null),Pt=(0,Ft.useRef)(null),kt=(0,Ft.useRef)(null),Tt=(0,Ft.useRef)(null),[Dt,$t]=(0,Ft.useState)(!1),[ie,Yt]=(0,Ft.useState)("\u6B63\u5728\u52A0\u8F7D\u4E2D");(0,Ft.useEffect)(()=>(kt.current||(kt.current=document.createElement("style"),document.head.appendChild(kt.current)),ye!=null&&ye.visible?(document.body.setAttribute("data-custom","y-hidden"),kt.current.innerHTML=" html { overflow-y: hidden; }",ye!=null&&ye.src&&fe()):(document.body.removeAttribute("data-custom"),kt.current&&(document.head.removeChild(kt.current),kt.current=null)),()=>{document.body.removeAttribute("data-custom"),kt.current&&(document.head.removeChild(kt.current),kt.current=null)}),[ye==null?void 0:ye.visible]);const fe=()=>be(void 0,null,function*(){$t(!0),Yt("\u6B63\u5728\u52A0\u8F7D\u4E2D");const Xe=yield(0,Oe.ZJ)(ye==null?void 0:ye.src);mt.current.src="",mt.current.src=Xe,mt.current.onload=function(){me()},$t(!1),Yt("")}),Zt=Xe=>be(void 0,null,function*(){$t(!0),Yt("\u6B63\u5728\u4FDD\u5B58\u4E2D");const Se=yield(0,Nt.ZP)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:ye.title,file:Xe.dataUrl}});Se!=null&&Se.id&&!gt?(yield(0,Nt.ZP)(`/api/attachments/${ye.id}/add_subitem.json`,{method:"post",body:{subitem_id:Se==null?void 0:Se.id,settings:JSON.stringify(Xe.state)}})).status===0&&dt():Se!=null&&Se.id&&dt(Se),$t(!1),Yt("")}),je=()=>{const Xe=document.querySelector('a[href="https://markerjs.com/"]');Xe&&Xe.parentNode&&(Xe.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(Ie=>{const ze=document.querySelector(Ie.name);ze&&ze.setAttribute("title",Ie.title)})},me=()=>{Pt.current=new qt.hP(mt.current),Pt.current.targetRoot=Tt.current,Pt.current.addEventListener("render",Zt),Pt.current.addEventListener("beforeclose",nt),at&&(Pt.current.availableMarkerTypes=Pt.current.ALL_MARKER_TYPES,Pt.current.uiStyleSettings.redoButtonVisible=!0,Pt.current.uiStyleSettings.notesButtonVisible=!0,Pt.current.uiStyleSettings.zoomButtonVisible=!0,Pt.current.uiStyleSettings.zoomOutButtonVisible=!0,Pt.current.uiStyleSettings.clearButtonVisible=!0),window.markerArea=Pt.current.uiStyleSettings,Pt.current.show(),ye!=null&&ye.snapshotData&&Pt.current.restoreState(ye.snapshotData),setTimeout(()=>{window.scrollTo(0,0),je()},300)};return Ft.createElement(Ft.Fragment,null,(ye==null?void 0:ye.visible)&&Ft.createElement(Vt.Z,{spinning:Dt,tip:ie,style:{position:"absolute",width:"100vw"}},Ft.createElement("div",{ref:Tt,className:ke()(Ht.imageDimensions,Re,It?Ht.fullWidth:""),style:et},Ft.createElement("img",{className:Ht.img,ref:mt}))))}},41588:function(Cn,cn,wt){"use strict";var Ft=wt(59301),Ht=wt(95237),oe=wt(43604),ke=wt(99313),Vt=wt(3113),qt=wt(85149),Nt=wt(88010),Oe=wt(48136),be=wt(59301);const Qt=(0,Ft.forwardRef)(({callback:Fe,showSaveButton:ye,value:Re=""},It)=>{const et=(0,Ft.useRef)(),nt=[{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 "}]}]}],dt=[{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}`}]}]}],at=Pt=>{et.current.setValue(et.current.getValue()+" "+Pt.value+" ")},gt=[{key:"1",label:"\u5FEB\u6377\u6A21\u677F",children:be.createElement(Ht.Z,{className:Nt.Z.lists,gutter:[10,10]},nt.map((Pt,kt)=>be.createElement(oe.Z,{flex:"110px",className:Nt.Z.item},be.createElement("div",null,be.createElement(qt.Z,{value:`$$${Pt.value}$$`}),Pt.name),be.createElement("div",{className:Nt.Z.children},Pt.children.map((Tt,Dt)=>be.createElement("div",{key:Dt},be.createElement("h1",null,Tt.name),be.createElement(Ht.Z,{gutter:[10,10]},Tt.data.map(($t,ie)=>be.createElement(oe.Z,{key:ie,onClick:()=>at($t),className:Nt.Z.diamond},be.createElement(qt.Z,{value:"`$$"+$t.value+"$$`"}))))))))))},{key:"2",label:"\u516C\u5F0F\u6A21\u677F",children:be.createElement(Ht.Z,{className:Nt.Z.lists,gutter:[10,10]},dt.map((Pt,kt)=>be.createElement(oe.Z,{flex:"110px",className:Nt.Z.item},be.createElement("div",null,be.createElement(qt.Z,{value:"`$$"+Pt.value+"$$`"}),Pt.name),be.createElement("div",{className:Nt.Z.children},Pt.children.map((Tt,Dt)=>be.createElement("div",{key:Dt},Tt.name&&be.createElement("h1",null,Tt.name),be.createElement(Ht.Z,{gutter:[10,10]},Tt.data.map(($t,ie)=>be.createElement(oe.Z,{key:ie,onClick:()=>at($t),className:Nt.Z.diamond},be.createElement(qt.Z,{value:"`$$"+$t.value+"$$`"}))))))))))}],mt=()=>{var Pt=document.createElement("div");Pt.innerHTML=et.current.getValue();var kt=Pt.innerText;return Fe&&Fe(kt),kt};return(0,Ft.useImperativeHandle)(It,()=>({getData:mt})),be.createElement("div",{className:Nt.Z.mathWrap},be.createElement(ke.default,{defaultActiveKey:"1",items:gt}),be.createElement("math-field",{locale:"zh_cn",className:Nt.Z.mathField,placeholder:"\u8BF7\u6253\u5F00\u952E\u76D8\uFF0C\u8F93\u5165\u516C\u5F0F",ref:et,style:{width:800,marginTop:30,fontSize:18}},Re||""),ye&&be.createElement("div",{className:Nt.Z.button},be.createElement(Vt.ZP,{size:"large",onClick:mt,style:{zIndex:8,marginTop:10},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668")))});cn.Z=Qt},8797:function(Cn,cn,wt){"use strict";var Ft=wt(59301),Ht=wt(93314),oe=wt(3113),ke=Object.defineProperty,Vt=Object.defineProperties,qt=Object.getOwnPropertyDescriptors,Nt=Object.getOwnPropertySymbols,Oe=Object.prototype.hasOwnProperty,be=Object.prototype.propertyIsEnumerable,Qt=(It,et,nt)=>et in It?ke(It,et,{enumerable:!0,configurable:!0,writable:!0,value:nt}):It[et]=nt,Fe=(It,et)=>{for(var nt in et||(et={}))Oe.call(et,nt)&&Qt(It,nt,et[nt]);if(Nt)for(var nt of Nt(et))be.call(et,nt)&&Qt(It,nt,et[nt]);return It},ye=(It,et)=>Vt(It,qt(et));const Re=({img:It,buttonProps:et={},styles:nt={},customText:dt,ButtonText:at,ButtonClick:gt,Buttonclass:mt,ButtonTwo:Pt,imgStyles:kt,loading:Tt=!1})=>Ft.createElement("section",{className:"tc animated fadeIn",style:Fe(Fe({},{color:"#999",margin:"100px auto",visibility:Tt?"hidden":"visible"}),nt)},Ft.createElement("img",{src:It||Ht,style:ye(Fe({},kt),{pointerEvents:"none",userSelect:"none"})}),Ft.createElement("p",{className:"mt20 font14"},dt||"\u6682\u65F6\u8FD8\u6CA1\u6709\u76F8\u5173\u6570\u636E\u54E6!"),at&&Ft.createElement(oe.ZP,Fe({className:mt,onClick:gt},et),at),Pt&&Pt);cn.Z=Re},23210:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return mt}});var Ft=wt(59301),Ht={wrp:"wrp___dq7YK",bgBlack:"bgBlack___ARIUV",monaco:"monaco___VnZC3",darkBlue:"darkBlue___UprA9",close:"close___LKoWu",embed:"embed___hvpEJ"},oe=wt(3113),ke=wt(70557),Vt=wt(23954),qt=wt(6848),Nt=wt(955),Oe=wt(94941),be=wt(8797),Qt=wt(3294),Fe=wt(19381),ye=wt(59301),Re=Object.defineProperty,It=Object.getOwnPropertySymbols,et=Object.prototype.hasOwnProperty,nt=Object.prototype.propertyIsEnumerable,dt=(Pt,kt,Tt)=>kt in Pt?Re(Pt,kt,{enumerable:!0,configurable:!0,writable:!0,value:Tt}):Pt[kt]=Tt,at=(Pt,kt)=>{for(var Tt in kt||(kt={}))et.call(kt,Tt)&&dt(Pt,Tt,kt[Tt]);if(It)for(var Tt of It(kt))nt.call(kt,Tt)&&dt(Pt,Tt,kt[Tt]);return Pt},gt=(Pt,kt,Tt)=>new Promise((Dt,$t)=>{var ie=Zt=>{try{fe(Tt.next(Zt))}catch(je){$t(je)}},Yt=Zt=>{try{fe(Tt.throw(Zt))}catch(je){$t(je)}},fe=Zt=>Zt.done?Dt(Zt.value):Promise.resolve(Zt.value).then(ie,Yt);fe((Tt=Tt.apply(Pt,kt)).next())}),mt=({editOffice:Pt="view",data:kt,theme:Tt,type:Dt,filename:$t,monacoEditor:ie,className:Yt,style:fe,close:Zt,onClose:je,hasMask:me,disabledDownload:Xe,onImgDimensions:Se,showNodata:Ie,recordInfo:ze})=>{const[Ue,se]=(0,Ft.useState)("https://view.officeapps.live.com/op/view.aspx?src=http://testgs.educoder.net//rails/active_storage/blobs/eyJfcmFpbHMiOnsibWVzc2FnZSI6IkJBaHBCZz09IiwiZXhwIjpudWxsLCJwdXIiOiJibG9iX2lkIn19--03541f6234b93d7ac3b2d84e7eb0e6594a952945/1.ppt"),[jt,$e]=(0,Ft.useState)(""),[xn,En]=(0,Ft.useState)(),Ne=window.ENV==="build"?"/react/build":"",Ze=location.host.startsWith("localhost")?Qt.Z.PROXY_SERVER:Qt.Z.API_SERVER,zn=10*(1024*1024),tn=(0,Ft.useRef)();kt!=null&&kt.startsWith("/api")&&Dt!=="txt"&&(kt=Qt.Z.API_SERVER+kt);const Tn=Rt=>Rt.substring(Rt.lastIndexOf("/")+1).split(".").pop();$t&&ie&&(ie.filename=$t),(0,Ft.useEffect)(()=>{var Rt,Lt;const St=(Lt=(Rt=document.cookie)==null?void 0:Rt.replace(/\s/g,""))==null?void 0:Lt.split(";");St==null||St.map(Et=>{let Bt=Et.split("=");Bt[0]==="_educoder_session"&&$e(Bt[1])})},[]),(0,Ft.useEffect)(()=>{Dt==="office"&&(kt.indexOf("bigfilescdn.")>-1||kt.indexOf("bigfiles1")>-1?En({url:kt,fileType:Tn(kt),model:kt.indexOf("model=edit")?"edit":"view"}):we())},[Dt,kt]);const we=()=>gt(void 0,null,function*(){console.log("data:",kt);let Rt=kt;kt.startsWith("http")||(Rt=location.origin+Rt);let Lt=new URL(Rt).pathname.split("/").pop();const St=yield(0,Oe.gJ)({attachment_id:Lt});St.url=Ze+St.url,En(St)}),Bn=()=>{if(kt.startsWith("http")||kt.startsWith("blob:")){Jn();return}(0,Nt.Sv)($t||"educoder",kt,$t)},Jn=()=>{ze&&(0,Fe.fc)({id:ze==null?void 0:ze.id,watch_type:1,course_id:ze==null?void 0:ze.course_id}),(0,Nt.Nd)($t||"educoder",decodeURIComponent(kt))};return ye.createElement("div",{style:at({},fe||{}),className:`${me&&Ht.bgBlack} ${Dt?Ht.wrp:"hide"}`},Zt&&ye.createElement("div",{className:Ht.close,ref:tn},!!Se&&ye.createElement(qt.Z,{title:"\u70B9\u51FB\u5BF9\u56FE\u7247\u8FDB\u884C\u6279\u6CE8",getPopupContainer:()=>tn.current},ye.createElement("span",{onClick:()=>{je(),Se()}},ye.createElement("i",{className:"icon-yulanpizhu"}))),!Xe&&ye.createElement(qt.Z,{title:"\u70B9\u51FB\u4E0B\u8F7D\u6B64\u6587\u4EF6",getPopupContainer:()=>tn.current},ye.createElement("span",{onClick:Jn},ye.createElement("i",{className:"icon-quxiaozhiding"}))),ye.createElement(qt.Z,{title:"\u5173\u95ED",getPopupContainer:()=>tn.current},ye.createElement("span",{className:"",onClick:je},ye.createElement("i",{className:"icon-guanbi1"})))),ye.createElement("div",{className:`${Ht[Yt]} ${Yt} ${Ht.monaco} ${Dt==="txt"?"show":"hide"}`},Dt==="txt"&&ye.createElement(ye.Fragment,null,ye.createElement(Vt.ZP,at({},ie)))),Dt==="audio"&&ye.createElement("audio",{src:`${(kt==null?void 0:kt.indexOf("http://"))>-1||(kt==null?void 0:kt.indexOf("https://"))>-1?"":"data:audio/mp3;base64,"}${kt}`,autoPlay:!0}),Dt==="video"&&ye.createElement(ye.Fragment,null,(kt==null?void 0:kt.indexOf("http"))>-1?ye.createElement("video",{controls:!0,src:`${kt}`,autoPlay:!0}):ye.createElement("video",{controls:!0,src:`data:video/mp4;base64,${kt}`,autoPlay:!0})),Dt==="office"&&xn&&ye.createElement("iframe",{src:`${Ne}/office.html?key=${xn.key}&url=${btoa(xn.url)}&callbackUrl=${Ze+(xn.callbackUrl||"")}&fileType=${xn.fileType}&title=${xn.title||""}&model=${Pt}&officeServer=${Qt.Z.ONLYOFFICE}&disabledDownload=${!!Xe}`}),Dt==="html"&&ye.createElement("iframe",{src:kt+"&disposition=inline"}),Dt==="pdf"&&ye.createElement("iframe",{src:`${Ne}/js/pdfview/index.html?filename=${$t||"educoder.pdf"}&url=${encodeURIComponent(kt)}&disabledDownload=${!!Xe}`}),Dt==="image"&&ye.createElement("img",{src:`${(kt==null?void 0:kt.indexOf("http://"))>-1||(kt==null?void 0:kt.indexOf("https://"))>-1?"":"data:image/png;base64,"}${kt}`}),(Dt==="other"||Dt==="download")&&ye.createElement(ye.Fragment,null,Ie?ye.createElement(be.Z,{customText:"\u5F53\u524D\u6587\u4EF6\u4E0D\u652F\u6301\u9884\u89C8\uFF0C\u53EF\u70B9\u51FB\u4E0B\u8F7D\u67E5\u770B",ButtonTwo:ye.createElement(oe.ZP,{icon:ye.createElement("i",{className:"iconfont icon-xiazai4 font14"}),type:"primary",size:"middle",onClick:Bn,disabled:Xe},"\u4E0B\u8F7D")}):ye.createElement(oe.ZP,{type:"primary",size:"middle",onClick:Bn,disabled:Xe},ye.createElement(ke.Z,null),"\u70B9\u51FB\u4E0B\u8F7D")))}},85149:function(Cn,cn,wt){"use strict";wt.d(cn,{z:function(){return Dt},Z:function(){return $t}});var Ft=wt(59301),Ht=wt(50304),oe=wt(24768),ke=wt(64018),Vt=wt(40846),qt=wt(3294),Nt=wt(955),Oe=wt(15342),be=wt(1012),Qt=wt(23210),Fe=wt(59301),Re=({html:ie})=>{const Yt=(0,Ft.useRef)(null),fe=(0,Ft.useRef)(null),Zt=`.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 36px !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,Ft.useEffect)(()=>{const je=Yt.current.attachShadow({mode:"open"});fe.current=document.createElement("div"),fe.current.className="markdown-body",fe.current.innerHTML=ie,je.appendChild(fe.current);const me=document.createElement("style");return me.textContent=Zt,je.appendChild(me),()=>{je.innerHTML=""}},[]),(0,Ft.useEffect)(()=>{fe.current&&(fe.current.innerHTML=ie)},[ie]),Fe.createElement("div",{ref:Yt})},It=Object.defineProperty,et=Object.getOwnPropertySymbols,nt=Object.prototype.hasOwnProperty,dt=Object.prototype.propertyIsEnumerable,at=(ie,Yt,fe)=>Yt in ie?It(ie,Yt,{enumerable:!0,configurable:!0,writable:!0,value:fe}):ie[Yt]=fe,gt=(ie,Yt)=>{for(var fe in Yt||(Yt={}))nt.call(Yt,fe)&&at(ie,fe,Yt[fe]);if(et)for(var fe of et(Yt))dt.call(Yt,fe)&&at(ie,fe,Yt[fe]);return ie};const mt="@\u2581\u2581@",Pt="@\u2581@",kt=/]*>/g;function Tt(ie){let Yt=document.createElement("div");return Yt.innerHTML=ie,Yt.childNodes.length===0?"":Yt.childNodes[0].nodeValue}const Dt=(ie,Yt)=>{ie=ie||"";const fe=/(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?\)|(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,Zt=/\"(?:https?:\/\/[^\/]+)?\/api\/attachments\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,je=/\(\s+(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?|\"(?:https?:\/\/[^\/]+)?\/files\/uploads\/([A-Za-z0-9+/=]+)(\?.*?)?\//g,me=/(?:https?:\/\/[^\/]+)?\/attachments\/download\/([A-Za-z0-9+/=]+)(\?.*?)?\//g;return Yt?ie.replaceAll("https://www.educoder.net","").replaceAll("https://www-cdn.educoder.net","").replaceAll("//api/attachments","/api/attachments").replace(fe,(Xe,Se,Ie,ze,Ue,se,jt)=>{const $e=Se||ze||se,xn=Ie||Ue||jt||"?";return qt.Z.API_SERVER+"/api/attachments/"+$e+xn+"&t="+(0,Nt.Jn)($e,Date.now())+(Xe.indexOf(")")>-1?")":"&")}).replaceAll('src="(','src="').replaceAll("src='(",'src="'):(ie=ie.replace(me,(Xe,Se,Ie,ze,Ue,se,jt)=>{const $e=Se||ze||se,xn=Ie||Ue||jt||"?";return qt.Z.API_SERVER+"/attachments/download/"+$e+xn+"&t="+(0,Nt.Jn)($e,Date.now())+(Xe.indexOf(")")>-1?")":"&")}).replace(fe,(Xe,Se,Ie,ze,Ue,se,jt)=>{const $e=Se||ze||se,xn=Ie||Ue||jt||"?";return qt.Z.API_SERVER+"/api/attachments/"+$e+xn+"&t="+(0,Nt.Jn)($e,Date.now())+(Xe.indexOf(")")>-1?")":"&")}).replace(Zt,(Xe,Se,Ie,ze,Ue)=>{const se=Se||ze,jt=Ie||Ue||"";return'"'+qt.Z.API_SERVER+"/api/attachments/"+se+jt+se+jt+"&t="+(0,Nt.Jn)(se,Date.now())}).replace(je,(Xe,Se,Ie,ze,Ue)=>{const se=Se||ze,jt=Ie||Ue||"";return"("+qt.Z.API_SERVER+"/files/uploads/"+se+jt+se+jt+"&t="+(0,Nt.Jn)(se,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,` `),ie)};var $t=({value:ie="",className:Yt,showTextOnly:fe,showLines:Zt,style:je={},stylesPrev:me={},highlightKeywords:Xe,showProgramFill:Se,isProgramFill:Ie,disabledFill:ze=!1,programFillValue:Ue,onFillChange:se=xn=>{},onFillBlur:jt=()=>{},onFillFocus:$e=()=>{}})=>{let xn=String(ie);const[En,Ne]=(0,Ft.useState)(""),[Ze,rn]=(0,Ft.useState)("office"),[zn,tn]=(0,Ft.useState)([]),Tn=(0,Ft.useRef)("a"+(0,be.Z)()),we={},Bn=(ge,pe,le)=>{const Me=document.createElement(ge===Pt?"input":"textarea");Me.style.width="100%",Me.style.height=ge===Pt?"40px":"151px",Me.rows=5,Me.spellcheck=!1,Me.name="edu-program-fill",Me.placeholder="\u8BF7\u8F93\u5165",Me.dataset.id=pe;const nn=Object.keys(we).length;return we[nn]=Me,`${Me.outerHTML}`};function Jn(ge){return ge=ge.replace(/!\[.*?\]\(.*?\)/g,""),ge=ge.replace(/\[.*?\]\(.*?\)/g,""),ge=ge.replace(new RegExp("","gs"),""),ge=ge.replace(//g,""),ge=ge.replace(//g,""),ge=ge.replace(new RegExp(".*?<\\/video>","gs"),""),ge=ge.replace(new RegExp(".*?<\\/audio>","gs"),""),ge=ge.replace(new RegExp(".*?<\\/style>","gs"),""),ge=ge.replace(new RegExp(".*?<\\/script>","gs"),""),ge}const Rt=ge=>ge.replace(/([\s\S]+?)<\/style>/gim,function(pe,le){let Me=le.replace(/(\n|\r)/g,"").split("}"),nn=[];return Me.map(qe=>{qe!=""&&nn.push(`.${Tn.current} ${qe}`)}),``}),Lt=(0,Ft.useMemo)(()=>{try{const Me=/\(\s+\/api\/attachments\/|\(\/api\/attachments\//g,nn=/\"\/api\/attachments\/|\"\/attachments\/download\//g,qe=/\(\s+\/files\/uploads\/|\"\/files\/uploads\//g,Ge=/\(\/attachments\/download\//g;xn=xn.replace(Ge,"("+qt.Z.API_SERVER+"/attachments/download/").replace(Me,"("+qt.Z.API_SERVER+"/api/attachments/").replace(nn,'"'+qt.Z.API_SERVER+"/api/attachments/").replace(qe,'"'+qt.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(Me){}if(Se){let Me=-1;return xn=xn.replaceAll("<","<").replaceAll(">",">").replace(/(@▁▁@|@▁@)/g,function(nn,qe,Ge){var yn;return++Me,Bn(nn,Me,(yn=Ue==null?void 0:Ue[Me])==null?void 0:yn.value.replaceAll("<","<").replaceAll(">",">"))}),`
${Rt(xn||"")}
`}let ge=Rt(xn);ge=(0,oe.ZP)(ge);const pe=(0,oe.ez)();xn.match(/\[TOC\]/)&&(ge=ge.replace("

[TOC]

",(0,oe.Qv)()),(0,oe.Iy)()),ge=ge.replace(/(__special_katext_id_\d+__)/g,(Me,nn)=>{const{type:qe,expression:Ge}=pe[nn];return(0,Oe.renderToString)(Tt(Ge)||"",{displayMode:qe==="block",throwOnError:!1,output:"html"})}),ge=ge.replace(/▁/g,"\u2581\u2581\u2581\u2581\u2581"),(0,oe.AL)();const le=document.createElement("div");if(le.innerHTML=ge,fe)return le.innerText;if(Xe){const Me=Xe.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return yt(le,Me),le.innerHTML}return setTimeout(()=>ne(),500),le.innerHTML},[xn,Xe]);(0,Ft.useEffect)(()=>{ae.current&&ae.current.querySelectorAll(["input","textarea"]).forEach(pe=>{pe.oninput=St,pe.onblur=Et,pe.onfocus=Bt})},[zn]),(0,Ft.useEffect)(()=>{var ge,pe,le,Me,nn;if(Ue!=null&&Ue.length)try{const qe=ae.current.querySelectorAll(".edu-program-fill-score"),Ge=ae.current.querySelectorAll('[name="edu-program-fill"]');for(const[yn,wn]of Ge.entries())wn.value=((ge=Ue==null?void 0:Ue[yn])==null?void 0:ge.value)||"",((pe=Ue==null?void 0:Ue[yn])==null?void 0:pe.type)==="warning"?wn.className="program-fill-warning":((le=Ue==null?void 0:Ue[yn])==null?void 0:le.type)==="success"?wn.className="program-fill-success":wn.className="";for(const[yn,wn]of qe.entries())wn.innerHTML=(Me=Ue==null?void 0:Ue[yn])!=null&&Me.score?`${(nn=Ue==null?void 0:Ue[yn])==null?void 0:nn.score}\u5206`:"";tn(Ue)}catch(qe){console.log(qe,"error")}},[Ue]);const St=ge=>{zn[ge.target.dataset.id]=zn[ge.target.dataset.id]||{},zn[ge.target.dataset.id].value=ge.target.value,tn([...zn]),se(zn,ge.target.dataset.id)},Et=ge=>{zn[ge.target.dataset.id]=zn[ge.target.dataset.id]||{},zn[ge.target.dataset.id].value=ge.target.value,tn([...zn]),jt(zn,ge.target.dataset.id)},Bt=ge=>{zn[ge.target.dataset.id]=zn[ge.target.dataset.id]||{},zn[ge.target.dataset.id].value=ge.target.value,tn([...zn]),$e(zn,ge.target.dataset.id)};function yt(ge,pe){return ge.childNodes.forEach(le=>{var Me;if(le.childNodes.length>0)yt(le,pe);else if(le.nodeName!=="IMG")if(le.innerHTML)le.innerHTML=(Me=le.innerHTML)==null?void 0:Me.replace(new RegExp(pe,"gi"),'$&');else{const nn=document.createElement("span");nn.innerHTML=le.textContent.replace(new RegExp(pe,"gi"),'$&'),le.replaceWith(nn)}})}const ae=(0,Ft.useRef)();oe.jb.WebkitLineClamp=Zt,Zt&&(je=gt(gt({},je),oe.jb));function Pe(ge){let pe=ge.target;if(pe.tagName.toUpperCase()==="A"){let le=pe.getAttribute("href");if(le.indexOf("office")>-1)ge.preventDefault(),Ne(le),rn("office");else if(le.indexOf("application/pdf")>-1)ge.preventDefault(),Ne(le),rn("pdf");else if(le.indexOf("text/html")>-1)ge.preventDefault(),Ne(le),rn("html");else if(le.startsWith("#")){ge.preventDefault();let Me=document.getElementById(le.replace("#",""));Me&&Me.scrollIntoView(!0)}}}const ne=()=>{var ge;const pe=(ge=ae.current)==null?void 0:ge.querySelectorAll("video");pe==null||pe.forEach(le=>{if(le.oncontextmenu=()=>!1,le.src.indexOf(".m3u8")>-1&&!le.canPlayType("application/vnd.apple.mpegurl")){if(Vt.ZP.isSupported()){var Me=new Vt.ZP;Me.loadSource(le.src),Me.attachMedia(le)}}})};(0,Ft.useEffect)(()=>{if(ae.current&&Lt&&Lt.match(kt)&&window.PR.prettyPrint(),ae.current)return ae.current.addEventListener("click",Pe),()=>{var ge;(ge=ae.current)==null||ge.removeEventListener("click",Pe),(0,oe.AL)(),(0,oe.Iy)()}},[Lt,ae.current,Pe]),(0,Ft.useEffect)(()=>{var ge;const pe=le=>{le.preventDefault(),le.clipboardData.setData("text",window.getSelection().toString())};return(ge=ae.current)==null||ge.addEventListener("copy",pe),()=>{var le;(le=ae.current)==null||le.removeEventListener("copy",pe)}},[ae.current]);const _t=ge=>//i.test(ge||"");return Ft.createElement(Ft.Fragment,null,fe&&Ft.createElement("div",{ref:ae},Lt),!fe&&!_t(Lt)&&Ft.createElement("div",{ref:ae,style:gt({},je),className:`${Yt||""} ${ze?"disabled-fill":""} markdown-body ${Tn.current}`,dangerouslySetInnerHTML:{__html:Lt}}),!fe&&_t(Lt)&&Ft.createElement(Re,{html:Lt}),Ft.createElement(Qt.Z,{close:!0,data:En,type:En!=null&&En.length?Ze:"",style:gt({},me),onClose:()=>Ne("")}))}},97692:function(Cn,cn,wt){"use strict";wt.d(cn,{h:function(){return Pt}});var Ft=wt(59301),Ht=wt(57809),oe=wt(78241),ke=wt(3113),Vt=wt(89780),qt=wt.n(Vt),Nt=wt(37036),Oe=wt(95625),be=Object.defineProperty,Qt=Object.defineProperties,Fe=Object.getOwnPropertyDescriptors,ye=Object.getOwnPropertySymbols,Re=Object.prototype.hasOwnProperty,It=Object.prototype.propertyIsEnumerable,et=(kt,Tt,Dt)=>Tt in kt?be(kt,Tt,{enumerable:!0,configurable:!0,writable:!0,value:Dt}):kt[Tt]=Dt,nt=(kt,Tt)=>{for(var Dt in Tt||(Tt={}))Re.call(Tt,Dt)&&et(kt,Dt,Tt[Dt]);if(ye)for(var Dt of ye(Tt))It.call(Tt,Dt)&&et(kt,Dt,Tt[Dt]);return kt},dt=(kt,Tt)=>Qt(kt,Fe(Tt));const at=Ht.default.Option,gt={labelCol:{span:4},wrapperCol:{span:20}},mt={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"]};cn.Z=({callback:kt,onCancel:Tt})=>{const[Dt,$t]=(0,Ft.useState)("python");function ie(fe){$t(mt[fe][1])}function Yt(fe){kt(fe)}return Ft.createElement(oe.default,dt(nt({},gt),{className:"code-block-panel",initialValues:{language:"python",content:""},onFinish:Yt,style:{width:500}}),Ft.createElement(oe.default.Item,{label:"\u4EE3\u7801\u8BED\u8A00",name:"language"},Ft.createElement(Ht.default,{getPopupContainer:fe=>fe.parentNode,onChange:ie},Object.keys(mt).map(fe=>Ft.createElement(at,{key:fe,value:fe},mt[fe][0])))),Ft.createElement(oe.default.Item,{label:"\u4EE3\u7801\u5185\u5BB9",name:"content",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u4EE3\u7801\u5185\u5BB9"}]},Ft.createElement(Pt,{mode:Dt})),Ft.createElement("div",{className:"flex-container flex-end"},Ft.createElement(ke.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),Ft.createElement(ke.ZP,{type:"ghost",onClick:Tt},"\u53D6\u6D88")))};function Pt({value:kt,onChange:Tt,mode:Dt,options:$t={}}){const ie=(0,Ft.useRef)(),[Yt,fe]=(0,Ft.useState)();return(0,Ft.useEffect)(()=>{if(Yt){let Zt=function(je){const me=je.getValue();Tt&&Tt(me)};return Yt.on("change",Zt),()=>{Yt.off("change",Zt)}}},[Yt,Tt]),(0,Ft.useEffect)(()=>{Yt&&Yt.setOption("mode",Dt)},[Yt,Dt]),(0,Ft.useEffect)(()=>{Yt&&(kt!==Yt.getValue()||kt==="")&&setTimeout(()=>{Yt.setValue(kt||"")},300)},[Yt,kt]),(0,Ft.useEffect)(()=>{if(ie.current&&!Yt){const Zt=qt().fromTextArea(ie.current,nt({mode:Dt,lineNumbers:!0,lineWrapping:!0,autoCloseBrackets:!0,tabSize:4,autofocus:!0,autoCloseTags:!0,matchBrackets:!0,styleActiveLine:!0},$t));fe(Zt)}},[ie.current,Yt]),Ft.createElement("div",{className:"my-codemirror-container"},Ft.createElement("textarea",{ref:ie}))}},12290:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return nr}});var Ft=wt(59301),Ht=wt(89780),oe=wt.n(Ht),ke=wt(76374),Vt=wt(37036),qt=wt(6313),Nt=wt(25717),Oe=wt(99498),be=wt(25419),Qt=wt(67549),Fe=wt(85149),ye=({value:_e="",className:We,showTextOnly:Jt,showLines:on,style:Mn={}})=>{const Le=(0,Ft.useMemo)(()=>"",[_e]);return Ft.createElement(Ft.Fragment,null,Ft.createElement("div",{dangerouslySetInnerHTML:{__html:Le}}))},Re=wt(59301),It=Object.defineProperty,et=Object.defineProperties,nt=Object.getOwnPropertyDescriptors,dt=Object.getOwnPropertySymbols,at=Object.prototype.hasOwnProperty,gt=Object.prototype.propertyIsEnumerable,mt=(_e,We,Jt)=>We in _e?It(_e,We,{enumerable:!0,configurable:!0,writable:!0,value:Jt}):_e[We]=Jt,Pt=(_e,We)=>{for(var Jt in We||(We={}))at.call(We,Jt)&&mt(_e,Jt,We[Jt]);if(dt)for(var Jt of dt(We))gt.call(We,Jt)&&mt(_e,Jt,We[Jt]);return _e},kt=(_e,We)=>et(_e,nt(We));let Tt=[{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\u56FE\u50CF",icon:"iconfont icon-shuxuetuxiang2",actionName:"maths-latex"},{title:"\u591A\u884C\u516C\u5F0F",icon:"iconfont icon-jisuan1",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 Dt({onActionCallback:_e,title:We,icon:Jt,actionName:on,className:Mn="",children:Le}){function ue(){_e(on)}return Re.createElement("a",{title:We,className:Mn,onClick:ue},Re.createElement("i",{className:`${Jt}`}),Le)}var $t=({watch:_e,showNullButton:We,showNullProgramButton:Jt,onActionCallback:on,fullScreen:Mn,insertTemp:Le,hidetoolBar:ue,extraUse:Je})=>{const gn=[...Tt,{title:`${_e?"\u5173\u95ED\u5B9E\u65F6\u9884\u89C8":"\u5F00\u542F\u5B9E\u65F6\u9884\u89C8"}`,icon:`${_e?"md-iconfont icon-eye-slash":"md-iconfont icon-eye"}`,actionName:"trigger-watch"}];return Re.createElement("ul",{className:"markdown-toolbar-container"},!ue&&gn.map((Xn,Gn)=>Re.createElement("li",{key:Gn},Xn.actionName?Re.createElement(Dt,kt(Pt({},Xn),{onActionCallback:on})):Re.createElement("span",{className:"v-line"}))),We?Re.createElement("li",null,Re.createElement(Dt,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-null-ch",onActionCallback:on},Re.createElement("span",{className:"fill-tip"},"\u70B9\u51FB\u63D2\u5165\b\u586B\u7A7A\u9879"))):null,Jt?Re.createElement(Re.Fragment,null,Re.createElement("li",null,Re.createElement(Dt,{icon:"md-iconfont icon-edit insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-signal",onActionCallback:on},Re.createElement("span",{className:"fill-tip"},"+\u5355\u884C\u586B\u7A7A\u9879"))),Re.createElement("li",null,Re.createElement(Dt,{icon:"md-iconfont icon-uniE900 insert-blank",className:"btn-null",title:"\u589E\u52A0\u586B\u7A7A",actionName:"add-multiple",onActionCallback:on},Re.createElement("span",{className:"fill-tip"},"+\u591A\u884C\u586B\u7A7A\u9879")))):null,Le&&Re.createElement("li",null,Re.createElement(Dt,{icon:"md-iconfont icon-edit",className:"btn-null",title:"\u63D2\u5165\u6A21\u677F",actionName:`inster-template-${Le}`,onActionCallback:on},Re.createElement("span",{className:"fill-tip"},"\u63D2\u5165\u6A21\u677F"))),Je&&Re.createElement("li",null,Je),Re.createElement("li",{className:"btn-full-screen"},Re.createElement(Dt,{icon:`${Mn?"md-iconfont icon-shrink":"md-iconfont icon-enlarge"}`,title:Mn?"\u5173\u95ED\u5168\u5C4F":"\u5F00\u542F\u5168\u5C4F",actionName:"trigger-full-screen",onActionCallback:on})))},ie=wt(79346),Yt=wt(78241),fe=wt(92832),Zt=wt(3113),je=Object.defineProperty,me=Object.defineProperties,Xe=Object.getOwnPropertyDescriptors,Se=Object.getOwnPropertySymbols,Ie=Object.prototype.hasOwnProperty,ze=Object.prototype.propertyIsEnumerable,Ue=(_e,We,Jt)=>We in _e?je(_e,We,{enumerable:!0,configurable:!0,writable:!0,value:Jt}):_e[We]=Jt,se=(_e,We)=>{for(var Jt in We||(We={}))Ie.call(We,Jt)&&Ue(_e,Jt,We[Jt]);if(Se)for(var Jt of Se(We))ze.call(We,Jt)&&Ue(_e,Jt,We[Jt]);return _e},jt=(_e,We)=>me(_e,Xe(We));const $e={labelCol:{span:4},wrapperCol:{span:20}};var xn=({callback:_e,onCancel:We})=>{function Jt(on){_e(on)}return Ft.createElement(Yt.default,jt(se({},$e),{initialValues:{link:"http://",title:""},className:"link-panel",onFinish:Jt,style:{width:500}}),Ft.createElement(Yt.default.Item,{label:"\u94FE\u63A5\u5730\u5740",name:"link",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u5730\u5740"}]},Ft.createElement(fe.default,null)),Ft.createElement(Yt.default.Item,{label:"\u94FE\u63A5\u6807\u9898",name:"title",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u94FE\u63A5\u6807\u9898"}]},Ft.createElement(fe.default,null)),Ft.createElement("div",{className:"flex-container flex-end"},Ft.createElement(Zt.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),Ft.createElement(Zt.ZP,{type:"ghost",onClick:We},"\u53D6\u6D88")))},En=wt(97692),Ne=wt(28451),Ze=wt(43418),rn=wt(95237),zn=wt(73524),tn=wt(59301),Tn=({callback:_e,onCancel:We})=>{const Jt=document.createElement("canvas"),on=Jt.getContext("2d");Jt.width=1e3,Jt.height=800,on.fillStyle="#ffffff",on.fillRect(0,0,Jt.width,Jt.height);const Mn=Jt.toDataURL("image/png");return tn.createElement(Ze.default,{open:!0,width:"100vw",style:{height:"100vh",top:0},footer:null,title:null,closable:!1},tn.createElement(rn.Z,{style:{height:"100vh"}},tn.createElement(zn.Z,{fullWidth:!0,noAssociationId:!0,showFullTools:!0,data:{src:Mn,visible:!0,title:String(Date.now())},onOk:Le=>{_e({src:Le.url})},onClose:We})))},we=wt(12378);function Bn(){go.CommandHandler.call(this),this._arrowKeyBehavior="move",this._pasteOffset=new go.Point(10,10),this._lastPasteOffset=new go.Point(0,0)}go.Diagram.inherit(Bn,go.CommandHandler),Bn.prototype.canAlignSelection=function(){var _e=this.diagram;return!(_e===null||_e.isReadOnly||_e.isModelReadOnly||_e.selection.count<2)},Bn.prototype.alignLeft=function(){var _e=this.diagram;_e.startTransaction("aligning left");var We=1/0;_e.selection.each(function(Jt){Jt instanceof go.Link||(We=Math.min(Jt.position.x,We))}),_e.selection.each(function(Jt){Jt instanceof go.Link||Jt.move(new go.Point(We,Jt.position.y))}),_e.commitTransaction("aligning left")},Bn.prototype.alignRight=function(){var _e=this.diagram;_e.startTransaction("aligning right");var We=-1/0;_e.selection.each(function(Jt){if(!(Jt instanceof go.Link)){var on=Jt.actualBounds.x+Jt.actualBounds.width;We=Math.max(on,We)}}),_e.selection.each(function(Jt){Jt instanceof go.Link||Jt.move(new go.Point(We-Jt.actualBounds.width,Jt.position.y))}),_e.commitTransaction("aligning right")},Bn.prototype.alignTop=function(){var _e=this.diagram;_e.startTransaction("alignTop");var We=1/0;_e.selection.each(function(Jt){Jt instanceof go.Link||(We=Math.min(Jt.position.y,We))}),_e.selection.each(function(Jt){Jt instanceof go.Link||Jt.move(new go.Point(Jt.position.x,We))}),_e.commitTransaction("alignTop")},Bn.prototype.alignBottom=function(){var _e=this.diagram;_e.startTransaction("aligning bottom");var We=-1/0;_e.selection.each(function(Jt){if(!(Jt instanceof go.Link)){var on=Jt.actualBounds.y+Jt.actualBounds.height;We=Math.max(on,We)}}),_e.selection.each(function(Jt){Jt instanceof go.Link||Jt.move(new go.Point(Jt.actualBounds.x,We-Jt.actualBounds.height))}),_e.commitTransaction("aligning bottom")},Bn.prototype.alignCenterX=function(){var _e=this.diagram,We=_e.selection.first();if(We){_e.startTransaction("aligning Center X");var Jt=We.actualBounds.x+We.actualBounds.width/2;_e.selection.each(function(on){on instanceof go.Link||on.move(new go.Point(Jt-on.actualBounds.width/2,on.actualBounds.y))}),_e.commitTransaction("aligning Center X")}},Bn.prototype.alignCenterY=function(){var _e=this.diagram,We=_e.selection.first();if(We){_e.startTransaction("aligning Center Y");var Jt=We.actualBounds.y+We.actualBounds.height/2;_e.selection.each(function(on){on instanceof go.Link||on.move(new go.Point(on.actualBounds.x,Jt-on.actualBounds.height/2))}),_e.commitTransaction("aligning Center Y")}},Bn.prototype.alignColumn=function(_e){var We=this.diagram;We.startTransaction("align Column"),_e===void 0&&(_e=0),_e=parseFloat(_e);var Jt=new Array;We.selection.each(function(Je){Je instanceof go.Link||Jt.push(Je)});for(var on=0;on0){for(var Je=Le.elt(ue-1);Je!==null&&Je.isTreeExpanded&&!Je.isTreeLeaf;){var gn=this._sortTreeChildrenByY(Je);Je=gn.last()}Je!==null&&_e.select(Je)}else _e.select(Mn)}}else if(Jt.key==="Down")if(We.isTreeExpanded&&!We.isTreeLeaf){var on=this._sortTreeChildrenByY(We).first();on!==null&&_e.select(on)}else for(;We!==null;){var Mn=We.findTreeParentNode();if(Mn===null)break;var Le=this._sortTreeChildrenByY(Mn),ue=Le.indexOf(We);if(ueLe.y?1:Mn.xLe.x?1:0}),We},Bn.prototype.copyToClipboard=function(_e){go.CommandHandler.prototype.copyToClipboard.call(this,_e),this._lastPasteOffset.set(this.pasteOffset)},Bn.prototype.pasteFromClipboard=function(){var _e=go.CommandHandler.prototype.pasteFromClipboard.call(this);return this.diagram.moveParts(_e,this._lastPasteOffset),this._lastPasteOffset.add(this.pasteOffset),_e},Object.defineProperty(Bn.prototype,"arrowKeyBehavior",{get:function(){return this._arrowKeyBehavior},set:function(_e){if(_e!=="move"&&_e!=="select"&&_e!=="scroll"&&_e!=="tree"&&_e!=="none")throw new Error('DrawCommandHandler.arrowKeyBehavior must be either "move", "select", "scroll", "tree", or "none", not: '+_e);this._arrowKeyBehavior=_e}}),Object.defineProperty(Bn.prototype,"pasteOffset",{get:function(){return this._pasteOffset},set:function(_e){if(!(_e instanceof go.Point))throw new Error("DrawCommandHandler.pasteOffset must be a Point, not: "+_e);this._pasteOffset.set(_e)}});var Jn=Bn,Rt=wt(74413),Lt=wt(43604),St=wt(99064),Et={myPaletteDiv:"myPaletteDiv___Xjz2I",flowChartWrp:"flowChartWrp____f45r",maxH60:"maxH60___Pd4Re"},Bt=wt(24065),yt=wt(59301),ae=(_e,We,Jt)=>new Promise((on,Mn)=>{var Le=gn=>{try{Je(Jt.next(gn))}catch(Xn){Mn(Xn)}},ue=gn=>{try{Je(Jt.throw(gn))}catch(Xn){Mn(Xn)}},Je=gn=>gn.done?on(gn.value):Promise.resolve(gn.value).then(Le,ue);Je((Jt=Jt.apply(_e,We)).next())});function Pe({onCancel:_e,callback:We}){let Jt=(0,Ft.useRef)(),on=(0,Ft.useRef)(),Mn=(0,Ft.useRef)(),Le=(0,Ft.useRef)(!1);const ue=(0,Ft.useRef)(!1),[Je,gn]=(0,Ft.useState)(0);function Xn(){const ce=we.bx.make,vn={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"};Jt.current=new we.S0(on.current,{padding:20,grid:ce(we.s_,"Grid",ce(we.bn,"LineH",{stroke:"lightgray",strokeWidth:.5}),ce(we.bn,"LineV",{stroke:"lightgray",strokeWidth:.5})),"draggingTool.isGridSnapEnabled":!0,handlesDragDropForTopLevelParts:!0,mouseDrop:Hn=>{var di=Hn.diagram.commandHandler.addTopLevelParts(Hn.diagram.selection,!0);di||Hn.diagram.currentTool.doCancel()},commandHandler:ce(Jn),"clickCreatingTool.archetypeNodeData":{text:"\u672A\u547D\u540D",fill:null,stroke:null,borderColor:"rgba(0,0,0,0)"},PartCreated:Hn=>{var di=Hn.subject;di.location=di.location.copy().snapToGridPoint(Hn.diagram.grid.gridOrigin,Hn.diagram.grid.gridCellSize),setTimeout(()=>{Hn.diagram.commandHandler.editTextBlock()},20)},"commandHandler.archetypeGroupData":{isGroup:!0,text:"NEW GROUP"},SelectionGrouped:Hn=>{var di=Hn.subject;setTimeout(()=>{Hn.diagram.commandHandler.editTextBlock()})},LinkRelinked:Hn=>{var di=Hn.parameter.part;di.invalidateConnectedLinks();var bi=Hn.subject;Hn.diagram.toolManager.linkingTool.isForwards?bi.toNode.invalidateConnectedLinks():bi.fromNode.invalidateConnectedLinks()},"undoManager.isEnabled":!0}),Jt.current.nodeTemplate=ce(we.NB,"Auto",{locationSpot:we.z6.Center,locationObjectName:"SHAPE",desiredSize:new we.$u(120,60),minSize:new we.$u(40,40),resizable:!0,resizeCellSize:new we.$u(10,10),rotatable:!0},new we.KX("location","loc",we.E9.parse).makeTwoWay(we.E9.stringify),new we.KX("desiredSize","size",we.$u.parse).makeTwoWay(we.$u.stringify),ce(we.bn,{name:"SHAPE",fill:vn.white,cursor:"pointer",portId:"",fromLinkable:!0,toLinkable:!0,fromLinkableDuplicates:!0,toLinkableDuplicates:!0,fromSpot:we.z6.AllSides,toSpot:we.z6.AllSides},new we.KX("figure"),new we.KX("fill"),new we.KX("stroke","borderColor"),new we.KX("strokeWidth","thickness"),new we.KX("strokeDashArray","dash")),ce(we.bn,{width:100,height:20,strokeWidth:0,fill:"transparent"}),ce(we.al,{margin:1,textAlign:"center",overflow:we.al.OverflowEllipsis,editable:!0},new we.KX("text").makeTwoWay(),new we.KX("stroke","color"))),Jt.current.nodeTemplate.toolTip=ce("ToolTip",ce(we.s_,"Vertical",{maxSize:new we.$u(200,NaN)},ce(we.al,{font:"bold 10pt sans-serif",textAlign:"center"},new we.KX("text")),ce(we.al,{font:"10pt sans-serif",textAlign:"center"},new we.KX("text","details"))));function An(Hn,di){var bi=(yi,Qi)=>{yi.handled=!0,yi.diagram.model.commit(co=>{var Ri=Qi.part.adornedPart,Hi=new we.E9().setRectSpot(Ri.actualBounds,Hn);Hi.subtract(Ri.location),Hi.scale(2,2),Hi.x+=Math.sign(Hi.x)*130,Hi.y+=Math.sign(Hi.y)*130,Hi.add(Ri.location),Hi.snapToGridPoint(yi.diagram.grid.gridOrigin,yi.diagram.grid.gridCellSize);var fo=co.copyNodeData(Ri.data);co.setGroupKeyForNodeData(fo,co.getGroupKeyForNodeData(Ri.data)),co.addNodeData(fo);var mn={from:Ri.key,to:co.getKeyForNodeData(fo)};co.addLinkData(mn);var Uo=yi.diagram.findNodeForData(fo);Uo.location=Hi,yi.diagram.select(Uo),setTimeout(()=>{yi.diagram.commandHandler.editTextBlock()},20)})};return ce(we.bn,{figure:di,alignment:Hn,alignmentFocus:Hn.opposite(),width:Hn.equals(we.z6.Top)||Hn.equals(we.z6.Bottom)?25:18,height:Hn.equals(we.z6.Top)||Hn.equals(we.z6.Bottom)?18:25,fill:"orange",stroke:vn.white,strokeWidth:4,mouseEnter:(yi,Qi)=>Qi.fill="dodgerblue",mouseLeave:(yi,Qi)=>Qi.fill="orange",isActionable:!0,click:bi,contextClick:bi})}function xi(Hn){return ce(we.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:(di,bi)=>bi.fill="dodgerblue",mouseLeave:(di,bi)=>bi.fill="orange",click:(di,bi)=>{di.diagram.commandHandler.showContextMenu(bi.part.adornedPart)}},Hn||{})}Jt.current.nodeTemplate.selectionAdornmentTemplate=ce(we.uz,"Spot",ce(we.Vm,{padding:10}),An(we.z6.Top,"TriangleUp"),An(we.z6.Left,"TriangleLeft"),An(we.z6.Right,"TriangleRight"),An(we.z6.Bottom,"TriangleDown"),xi({alignment:new we.z6(.75,0)}));function Ae(Hn,di){return(bi,yi)=>{bi.handled=!0,bi.diagram.model.commit(Qi=>{Qi.set(yi.part.adornedPart.data,Hn,di)})}}function en(Hn,di){return di||(di="color"),ce(we.bn,{width:16,height:16,stroke:"lightgray",fill:Hn,margin:1,background:"transparent",mouseEnter:(bi,yi)=>yi.stroke="dodgerblue",mouseLeave:(bi,yi)=>yi.stroke="lightgray",click:Ae(di,Hn),contextClick:Ae(di,Hn)})}function ui(){return[ce("ContextMenuButton",ce(we.s_,"Horizontal",en(vn.white,"fill"),en(vn.beige,"fill"),en(vn.extralightblue,"fill"),en(vn.extralightred,"fill"))),ce("ContextMenuButton",ce(we.s_,"Horizontal",en(vn.lightgray,"fill"),en(vn.lightgreen,"fill"),en(vn.lightblue,"fill"),en(vn.lightred,"fill")))]}function oi(){return[ce("ContextMenuButton",ce(we.s_,"Horizontal",en(vn.black),en(vn.green),en(vn.blue),en(vn.red))),ce("ContextMenuButton",ce(we.s_,"Horizontal",en(vn.white),en(vn.magenta),en(vn.purple),en(vn.orange)))]}function Si(Hn,di){return di||(di="thickness"),ce(we.bn,"LineH",{width:16,height:16,strokeWidth:Hn,margin:1,background:"transparent",mouseEnter:(bi,yi)=>yi.background="dodgerblue",mouseLeave:(bi,yi)=>yi.background="transparent",click:Ae(di,Hn),contextClick:Ae(di,Hn)})}function Zn(Hn,di){return di||(di="dash"),ce(we.bn,"LineH",{width:24,height:16,strokeWidth:2,strokeDashArray:Hn,margin:1,background:"transparent",mouseEnter:(bi,yi)=>yi.background="dodgerblue",mouseLeave:(bi,yi)=>yi.background="transparent",click:Ae(di,Hn),contextClick:Ae(di,Hn)})}function hi(){return[ce("ContextMenuButton",ce(we.s_,"Horizontal",Si(1),Si(2),Si(3),Si(4))),ce("ContextMenuButton",ce(we.s_,"Horizontal",Zn(null),Zn([2,4]),Zn([4,4])))]}function Qn(Hn,di){return di||(di="figure"),ce(we.bn,{width:32,height:32,scale:.5,fill:"lightgray",figure:Hn,margin:1,background:"transparent",mouseEnter:(bi,yi)=>yi.fill="dodgerblue",mouseLeave:(bi,yi)=>yi.fill="lightgray",click:Ae(di,Hn),contextClick:Ae(di,Hn)})}Jt.current.nodeTemplate.contextMenu=ce("ContextMenu",ce("ContextMenuButton",ce(we.s_,"Horizontal",Qn("Rectangle"),Qn("RoundedRectangle"),Qn("Ellipse"),Qn("Diamond"))),ce("ContextMenuButton",ce(we.s_,"Horizontal",Qn("Parallelogram2"),Qn("ManualOperation"),Qn("Procedure"),Qn("Cylinder1"))),ce("ContextMenuButton",ce(we.s_,"Horizontal",Qn("Terminator"),Qn("CreateRequest"),Qn("Document"),Qn("TriangleDown"))),ui(),oi(),hi()),Jt.current.groupTemplate=ce(we.ZA,"Spot",{layerName:"Background",ungroupable:!0,locationSpot:we.z6.Center,selectionObjectName:"BODY",computesBoundsAfterDrag:!0,handlesDragDropForMembers:!0,mouseDrop:(Hn,di)=>{var bi=di.addMembers(di.diagram.selection,!0);bi||di.diagram.currentTool.doCancel()},avoidable:!1},new we.KX("location","loc",we.E9.parse).makeTwoWay(we.E9.stringify),ce(we.s_,"Auto",{name:"BODY"},ce(we.bn,{parameter1:10,fill:vn.white,strokeWidth:2,cursor:"pointer",fromLinkable:!0,toLinkable:!0,fromLinkableDuplicates:!0,toLinkableDuplicates:!0,fromSpot:we.z6.AllSides,toSpot:we.z6.AllSides},new we.KX("fill"),new we.KX("stroke","color"),new we.KX("strokeWidth","thickness"),new we.KX("strokeDashArray","dash")),ce(we.Vm,{background:"transparent",margin:20})),ce(we.al,{alignment:we.z6.Top,alignmentFocus:we.z6.Bottom,font:"bold 12pt sans-serif",editable:!0},new we.KX("text"),new we.KX("stroke","color"))),Jt.current.groupTemplate.selectionAdornmentTemplate=ce(we.uz,"Spot",ce(we.s_,"Auto",ce(we.bn,{fill:null,stroke:"dodgerblue",strokeWidth:3}),ce(we.Vm,{margin:1.5})),xi({alignment:we.z6.TopRight,alignmentFocus:we.z6.BottomRight})),Jt.current.groupTemplate.contextMenu=ce("ContextMenu",ui(),oi(),hi()),Jt.current.linkTemplate=ce(we.rU,{layerName:"Foreground",routing:we.rU.AvoidsNodes,corner:10,fromShortLength:10,toShortLength:15,relinkableFrom:!0,relinkableTo:!0,reshapable:!0,resegmentable:!0},new we.KX("fromSpot","fromSpot",we.z6.parse),new we.KX("toSpot","toSpot",we.z6.parse),new we.KX("fromShortLength","dir",Hn=>Hn>=1?10:0),new we.KX("toShortLength","dir",Hn=>Hn>=1?10:0),new we.KX("points").makeTwoWay(),ce(we.bn,{strokeWidth:2},new we.KX("stroke","color"),new we.KX("strokeWidth","thickness"),new we.KX("strokeDashArray","dash")),ce(we.bn,{segmentIndex:0,segmentOffset:new we.E9(15,0),segmentOrientation:we.rU.OrientAlong,alignmentFocus:we.z6.Right,figure:"circle",width:10,strokeWidth:0},new we.KX("fill","color"),new we.KX("visible","dir",Hn=>Hn===1)),ce(we.bn,{segmentIndex:-1,segmentOffset:new we.E9(-10,6),segmentOrientation:we.rU.OrientPlus90,alignmentFocus:we.z6.Right,figure:"triangle",width:12,height:12,strokeWidth:0},new we.KX("fill","color"),new we.KX("visible","dir",Hn=>Hn>=1),new we.KX("width","thickness",Hn=>7+3*Hn),new we.KX("height","thickness",Hn=>7+3*Hn),new we.KX("segmentOffset","thickness",Hn=>new we.E9(-15,4+1.5*Hn))),ce(we.bn,{segmentIndex:0,segmentOffset:new we.E9(15,-6),segmentOrientation:we.rU.OrientMinus90,alignmentFocus:we.z6.Right,figure:"triangle",width:12,height:12,strokeWidth:0},new we.KX("fill","color"),new we.KX("visible","dir",Hn=>Hn===2),new we.KX("width","thickness",Hn=>7+3*Hn),new we.KX("height","thickness",Hn=>7+3*Hn),new we.KX("segmentOffset","thickness",Hn=>new we.E9(-15,4+1.5*Hn))),ce(we.al,{alignmentFocus:new we.z6(0,1,-4,0),editable:!0},new we.KX("text").makeTwoWay(),new we.KX("stroke","color"))),Jt.current.linkTemplate.selectionAdornmentTemplate=ce(we.uz,ce(we.bn,{isPanelMain:!0,stroke:"transparent",strokeWidth:6,pathPattern:Ci(2)},new we.KX("pathPattern","thickness",Ci)),xi({alignmentFocus:new we.z6(0,0,-6,-4)}));function Ci(Hn){return ce(we.bn,{stroke:"dodgerblue",strokeWidth:2,strokeCap:"square",geometryString:"M0 0 M4 2 H3 M4 "+(Hn+4).toString()+" H3"})}function so(Hn){var di="M0 0 M8 16 M0 8 L16 8 M12 11 L16 8 L12 5";return Hn===0?di="M0 0 M16 16 M0 8 L16 8":Hn===2&&(di="M0 0 M16 16 M0 8 L16 8 M12 11 L16 8 L12 5 M4 11 L0 8 L4 5"),ce(we.bn,{geometryString:di,margin:2,background:"transparent",mouseEnter:(bi,yi)=>yi.background="dodgerblue",mouseLeave:(bi,yi)=>yi.background="transparent",click:Ae("dir",Hn),contextClick:Ae("dir",Hn)})}function wo(Hn){var di=(bi,yi)=>{bi.handled=!0,bi.diagram.model.commit(Qi=>{var co=yi.part.adornedPart;Qi.set(co.data,Hn?"toSpot":"fromSpot",we.z6.stringify(we.z6.AllSides)),(Hn?co.toNode:co.fromNode).invalidateConnectedLinks()})};return ce(we.bn,{width:12,height:12,fill:"transparent",mouseEnter:(bi,yi)=>yi.background="dodgerblue",mouseLeave:(bi,yi)=>yi.background="transparent",click:di,contextClick:di})}function sn(Hn,di){var bi=0,yi=we.z6.RightSide;Hn.equals(we.z6.Top)?(bi=270,yi=we.z6.TopSide):Hn.equals(we.z6.Left)?(bi=180,yi=we.z6.LeftSide):Hn.equals(we.z6.Bottom)&&(bi=90,yi=we.z6.BottomSide),di||(bi-=180);var Qi=(co,Ri)=>{co.handled=!0,co.diagram.model.commit(Hi=>{var fo=Ri.part.adornedPart;Hi.set(fo.data,di?"toSpot":"fromSpot",we.z6.stringify(yi)),(di?fo.toNode:fo.fromNode).invalidateConnectedLinks()})};return ce(we.bn,{alignment:Hn,alignmentFocus:Hn.opposite(),geometryString:"M0 0 M12 12 M12 6 L1 6 L4 4 M1 6 L4 8",angle:bi,background:"transparent",mouseEnter:(co,Ri)=>Ri.background="dodgerblue",mouseLeave:(co,Ri)=>Ri.background="transparent",click:Qi,contextClick:Qi})}Jt.current.linkTemplate.contextMenu=ce("ContextMenu",oi(),hi(),ce("ContextMenuButton",ce(we.s_,"Horizontal",so(0),so(1),so(2))),ce("ContextMenuButton",ce(we.s_,"Horizontal",ce(we.s_,"Spot",wo(!1),sn(we.z6.Top,!1),sn(we.z6.Left,!1),sn(we.z6.Right,!1),sn(we.z6.Bottom,!1)),ce(we.s_,"Spot",{margin:new we.Zt(0,0,0,2)},wo(!0),sn(we.z6.Top,!0),sn(we.z6.Left,!0),sn(we.z6.Right,!0),sn(we.z6.Bottom,!0)))));const Bo=`{ "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 Vo=["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 io(Hn){return console.log("shapeName:",Hn),Vo.indexOf(Hn)>=0}var Qe=new we.YI(Mn.current,{maxSelectionCount:1,linkTemplate:ce(we.rU,{locationSpot:we.z6.Center,selectionAdornmentTemplate:ce(we.uz,"Link",{locationSpot:we.z6.Center},ce(we.bn,{isPanelMain:!0,fill:null,stroke:"deepskyblue",strokeWidth:0}),ce(we.bn,{toArrow:"Standard",stroke:null}))},{routing:we.rU.AvoidsNodes,curve:we.rU.JumpOver,corner:5,toShortLength:4},new we.KX("points"),ce(we.bn,{isPanelMain:!0,strokeWidth:2}),ce(we.bn,{toArrow:"Standard",stroke:null})),model:new we.FJ([{text:"\u672A\u547D\u540D",size:"100 100",fill:null,stroke:"#000"},...we.bn.getFigureGenerators().toArray().map(Hn=>({text:"\u672A\u547D\u540D",size:"100 100",figure:Hn.key,fill:"white",stroke:"#666",borderColor:"#000"}))])});return Jt.current.addDiagramListener("TextEdited",function(Hn){var di;const bi=Hn.subject.part;var yi=(di=document.activeElement)==null?void 0:di.value;typeof yi=="string"&&yi.trim()===""&&Jt.current.model.commit(function(Qi){Qi.set(bi.data,"text","\u672A\u547D\u540D"),Jt.current.commandHandler.stopCommand()},"increment")}),Qe.nodeTemplate=ce(we.NB,"Auto",{locationSpot:we.z6.Center},new we.KX("location","location",we.E9.parse).makeTwoWay(we.E9.stringify),ce(we.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 we.KX("stroke").makeTwoWay(),new we.KX("fill").makeTwoWay(),new we.KX("figure")),ce(we.al,{margin:new we.Zt(5,5,3,5),font:"10pt sans-serif",minSize:new we.$u(16,16),maxSize:new we.$u(10,NaN),textAlign:"center",editable:!0},new we.KX("key").makeTwoWay())),setTimeout(()=>{Jt.current.grid=ce(we.s_,"Grid",ce(we.bn,"LineH",{stroke:"lightgray",strokeWidth:.5}),ce(we.bn,"LineV",{stroke:"lightgray",strokeWidth:.5})),Jt.current.grid.visible=!0,Jt.current.grid.gridCellStroke="darkgray",Jt.current.grid.gridCellStrokeWidth=1},300),window.myDiagrams=Jt.current,Jt.current}const Gn=()=>ae(this,null,function*(){var ce,vn=Jt.current.makeImage();const An=yield(0,St.ZP)("/api/attachments.json",{method:"post",body:{file_type:"base64",original_filename:Date.now(),file:vn.src,file_data:JSON.stringify({login:(ce=(0,Bt.eY)())==null?void 0:ce.login,data:JSON.parse(Jt.current.model.toJson())})}});We({src:An.url})});return(0,Ft.useEffect)(()=>(setTimeout(()=>{Xn()},500),gn(Je+1),()=>{Jt.current=null}),[]),yt.createElement("div",{ref:ue,className:Le.current?`${Et.maxH60} body-overflow-initial`:"body-overflow-initial"},yt.createElement(Ze.default,{width:1200,icon:null,footer:null,closable:!0,visible:!!Je,destroyOnClose:!0,maskClosable:!1,rootClassName:"zIndex-9999",title:yt.createElement(rn.Z,null,yt.createElement(Lt.Z,{flex:1},"\u63D2\u5165\u6D41\u7A0B\u56FE"),yt.createElement(Lt.Z,{onClick:()=>{var ce,vn,An=Jt.current.selection.first();if(Le.current=!Le.current,document.activeElement&&An){let xi=(vn=(ce=document.activeElement)==null?void 0:ce.value)==null?void 0:vn.trim();typeof xi=="string"&&Jt.current.model.commit(function(Ae){Ae.set(An.data,"text",xi||"\u672A\u547D\u540D"),Jt.current.commandHandler.stopCommand()},"increment")}gn(Je+1)}},yt.createElement("span",{className:"current c-blue mr30",style:{fontWeight:400}},"\u5C55\u5F00/\u6536\u8D77"))),onCancel:_e},yt.createElement("div",{style:{width:"100%",height:"80vh",overflow:"hidden",position:"relative"},className:Et.flowChartWrp},yt.createElement("div",{style:{display:"flex",height:"100%"}},yt.createElement("div",{style:{width:"300px",height:"100%"}},yt.createElement("div",{style:{background:"#fff",position:"relative",zIndex:12,fontSize:16,color:"#3061d0"}},"\u56FE\u5F62\u5E93"),yt.createElement("div",{style:{height:"calc(100% - 50px)"},className:Et.myPaletteDiv,ref:Mn})),yt.createElement("div",{style:{flex:1,position:"relative"}},yt.createElement("div",{ref:on,style:{height:"80vh"}}))),yt.createElement("div",{className:"tr"},yt.createElement(Zt.ZP,{size:"large",onClick:Gn,style:{position:"absolute",right:0,bottom:0,zIndex:8},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668")))))}var ne=Pe,_t=wt(5112),ge=wt(5871);const pe=_t.ZP.Group,le={margin:"0 8px"};var Me=({callback:_e,onCancel:We})=>{function Jt(on){_e(on)}return Ft.createElement(Yt.default,{className:"add-table-panel",initialValues:{row:3,col:2,align:"default"},onFinish:Jt},Ft.createElement("div",{className:"flex-container",style:{alignItems:"baseline"}},Ft.createElement("span",{style:le},"\u5355\u5143\u683C\u6570\uFF1A"),Ft.createElement("span",{style:le},"\u884C\u6570"),Ft.createElement(Yt.default.Item,{name:"row",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u884C\u6570"}]},Ft.createElement(ge.Z,null)),Ft.createElement("span",{style:le},"\u5217\u6570"),Ft.createElement(Yt.default.Item,{name:"col",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u5217\u6570"}]},Ft.createElement(ge.Z,null))),Ft.createElement("div",{className:"flex-container",style:{marginTop:12,alignItems:"baseline"}},Ft.createElement("span",{style:le},"\u5BF9\u9F50\u65B9\u5F0F\uFF1A"),Ft.createElement(Yt.default.Item,{name:"align"},Ft.createElement(pe,null,Ft.createElement(_t.ZP,{value:"default"},Ft.createElement("i",{className:"fa fa-align-justify"})),Ft.createElement(_t.ZP,{value:"left"},Ft.createElement("i",{className:"fa fa-align-left"})),Ft.createElement(_t.ZP,{value:"center"},Ft.createElement("i",{className:"fa fa-align-center"})),Ft.createElement(_t.ZP,{value:"right"},Ft.createElement("i",{className:"fa fa-align-right"}))))),Ft.createElement("div",{className:"flex-container flex-end"},Ft.createElement(Zt.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),Ft.createElement(Zt.ZP,{type:"ghost",onClick:We},"\u53D6\u6D88")))},nn=wt(78673),qe=wt(80727),Ge=wt.n(qe),wn=(0,Ft.forwardRef)(({use3d:_e,width:We,height:Jt,callback:on,showSaveButton:Mn},Le)=>{const ue=(0,Ft.useRef)(),Je=(0,Ft.useRef)(),[gn,Xn]=(0,Ft.useState)(!1),Gn=(0,Ft.useRef)({id:ue,appName:"graphing",width:We||1e3,height:Jt||600,showToolBar:!0,showMenuBar:!0,allowStyleBar:!0,showAlgebraInput:!0,enableLabelDrags:!1,enableShiftDragZoom:!0,showToolBarHelp:!1,errorDialogsActive:!0,showTutorialLink:!0,showLogging:!0,useBrowserForJS:!1});(0,Ft.useEffect)(()=>{Je.current=new(Ge())(Gn.current,!0),window.onload=function(){Je.current.inject("applet_container")}},[]);const ce=()=>{var vn=window.ggbApplet.getPNGBase64(1,!0,72);return on&&on(vn),vn};return(0,Ft.useEffect)(()=>{Gn.current.appName=gn?"3D":"graphing",Je.current.inject("applet_container")},[gn]),(0,Ft.useEffect)(()=>{Xn(_e)},[_e]),(0,Ft.useImperativeHandle)(Le,()=>({getImgData:ce})),Ft.createElement(Ft.Fragment,null,Ft.createElement("div",{style:{width:"100%",height:"100%"},id:"applet_container",ref:ue}),Ft.createElement(rn.Z,{align:"middle"},Ft.createElement(Lt.Z,{flex:1},Ft.createElement(nn.Z,{size:"default",checkedChildren:"\u5173\u95ED3D\u56FE\u50CF",unCheckedChildren:"\u5F00\u542F3D\u56FE\u50CF",checked:gn,onChange:vn=>Xn(vn)})),Ft.createElement(Lt.Z,null,Ft.createElement(Zt.ZP,{size:"large",onClick:ce,style:{zIndex:8,marginTop:10},type:"primary"},"\u4FDD\u5B58\u5230\u7F16\u8F91\u5668"))))}),pn=wt(41588),Yn=wt(8591);const ni="link",Un="upload-image",gi="add-flowchart",mi="draw-image",$i="add-flowchart",Mi="code-block",eo="add-table",Io="------------",Ao={default:Io,left:`:${Io}`,center:`:${Io}:`,right:`${Io}:`};var $n=wt(58856);function Kn(){}let jn=0;const ii=1e4,Vi="\u2581",wi="@\u2581\u2581@",bt="@\u2581@",no=` **\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`,Ni=["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 ho(_e){return/^\d+$/.test(_e)?`${_e}px`:_e}const ar=navigator.platform.toUpperCase().indexOf("MAC")>=0?"Cmd":"Ctrl",sr={[ar+"-B"]:"bold",[ar+"-I"]:"italic"},Fo={[ni]:"\u6DFB\u52A0\u94FE\u63A5",[Mi]:"\u6DFB\u52A0\u4EE3\u7801\u5757",[Un]:"\u6DFB\u52A0\u56FE\u7247",[mi]:"\u6DFB\u52A0\u753B\u56FE",[gi]:"\u63D2\u5165\u6D41\u7A0B\u56FE",[eo]:"\u6DFB\u52A0\u8868\u683C","maths-latex":"\u6570\u5B66\u56FE\u50CF","inline-latex":"LATEX\u516C\u5F0F"};var nr=({defaultValue:_e="",onChange:We,width:Jt="100%",height:on=400,miniToolbar:Mn=!1,isFocus:Le=!1,watch:ue,insertTemp:Je,mode:gn="markdown",id:Xn="markdown-editor-id",showResizeBar:Gn=!1,noStorage:ce=!1,showNullButton:vn=!1,showNullProgramButton:An=!1,hidetoolBar:xi=!1,fullScreen:Ae=!1,onBlur:en,onCMBeforeChange:ui,onFullScreen:oi,className:Si="",disablePaste:Zn=!1,disabled:hi=!1,disabledFill:Qn=!1,placeholder:Ci="",values:so="",extraUse:wo})=>{const[sn,Bo]=(0,Ft.useState)(null),[Vo,io]=(0,Ft.useState)(_e),[Qe,Hn]=(0,Ft.useState)(ue),[di,bi]=(0,Ft.useState)(Ae),[yi,Qi]=(0,Ft.useState)(""),[co,Ri]=(0,Ft.useState)(0),[Hi,fo]=(0,Ft.useState)(on),[mn,Uo]=(0,Ft.useState)(!1),[un,Po]=(0,Ft.useState)(0),[kr,$o]=(0,Ft.useState)(0),Hr=(0,Ft.useRef)(),xr=(0,Ft.useRef)(),Wi=(0,Ft.useRef)(),Ui=(0,Ft.useRef)();(0,Ft.useEffect)(()=>{const qi=window.scrollY||window.pageYOffset;io(so),sn==null||sn.setValue(so),window.scrollTo(0,qi)},[so]),(0,Ft.useEffect)(()=>{oi==null||oi(di)},[di]),(0,Ft.useEffect)(()=>{if(Hr.current){let qi=function(Nn,Zi){var Xo;if(Zn){Zi.preventDefault();return}const zr=Zi.clipboardData;if(zr){const Ir=zr.types.toString(),Vr=zr.items;if(Ir==="Files"||zr.types.indexOf("Files")>-1){if(Zi.preventDefault(),gn=="stex")return;try{let Ns=Vr[1];((Xo=Vr[0])==null?void 0:Xo.kind)==="file"&&(Ns=Vr[0]);const Jr=Ns.getAsFile(),ga=Jr.name.split(".").pop();(0,Ne.I)(Jr,Qs=>{var Ea,Ye,Ws;Qs.id?((Ea=Jr==null?void 0:Jr.type)==null?void 0:Ea.indexOf("image"))>-1?Ai.replaceSelection(``):((Ye=Jr==null?void 0:Jr.type)==null?void 0:Ye.indexOf("video"))>-1?Ai.replaceSelection(``):((Ws=Jr==null?void 0:Jr.type)==null?void 0:Ws.indexOf("pdf"))>-1?Ai.replaceSelection(`${Jr.name}`):Ni.includes(ga)?Ai.replaceSelection(`${Jr.name}`):Ai.replaceSelection(`[${Jr.name}](/api/attachments/${Qs.id}?type=${Qs.content_type})`):(Qs==null?void 0:Qs.status)===401&&(document.location.href="/user/login")})}catch(Ns){Yn.ZP.warning("\u8BF7\u4F7F\u7528chrome\u6D4F\u89C8\u5668\u7C98\u8D34")}return!0}else return!0}return!0};const Ai=oe().fromTextArea(Hr.current,{mode:gn,lineNumbers:!Mn,lineWrapping:!0,value:_e,autoCloseTags:!0,autoCloseBrackets:!0});return Ai.on("keyup",function(Nn,Zi){Zi.keyCode===8&&(Nn.getValue()==""?Ai.setOption("placeholder",Ci):Ai.setOption("placeholder",null))}),Ai.on("keydown",function(Nn,Zi){if(Zi.keyCode===8){var Xo=Yo(Nn);Xo&&Zi.preventDefault()}}),Le&&Ai.focus(),Ai.on("paste",qi),hi&&Ai.on("beforeChange",function(Nn,Zi){(Zi.origin==="paste"||Zi.origin==="+input")&&Zi.cancel()}),Bo(Ai),()=>{Ai.off("paste",qi)}}},[]);const ko=(0,Ft.useCallback)(()=>{if(xr.current)try{}catch(qi){console.log(qi,"---- to set md editor body height")}},[Hi,xr,di]);(0,Ft.useEffect)(()=>{function qi(){let Ai=new ke.Z(Nn=>{for(let Zi of Nn)(Zi.target.offsetHeight>0||Zi.target.offsetWidth>0)&&(ko(),sn.setSize("100%","100%"),sn.refresh())});return Ai.observe(Hr.current.parentElement),Ai}if(sn){const Ai=qi();return()=>{var Nn,Zi;(Nn=Hr.current)!=null&&Nn.parentElement&&Ai.unobserve((Zi=Hr.current)==null?void 0:Zi.parentElement)}}},[sn,ko]),(0,Ft.useEffect)(()=>{if(sn){let qi=[];for(const[Ai,Nn]of Object.entries(sr)){let Zi={[Ai]:()=>{ri(Nn)}};qi.push(Zi),sn.addKeyMap(Zi)}return()=>{for(let Ai of qi)sn.removeKeyMap(Ai)}}},[sn]),(0,Ft.useEffect)(()=>{Ae!==di&&bi(Ae)},[Ae]),(0,$n.Z)(()=>{if(!ce&&co>0){let qi=new Date().getTime(),Ai=window.sessionStorage.getItem(Xn);qi>=co+ii&&(!Ai||Ai!==Vo)&&(window.sessionStorage.setItem(Xn,Vo),Uo(!0))}},ii),(0,Ft.useEffect)(()=>{Hn(ue)},[sn,ue]),(0,Ft.useEffect)(()=>{sn&&Le&&sn.focus()},[sn,Le]),(0,Ft.useEffect)(()=>{if(Qe&&sn){let qi=function(Nn){let Zi=Nn.target;if(Ui.current){let Xo=Zi.scrollTop/Zi.scrollHeight;Ui.current.scrollTop=Ui.current.scrollHeight*Xo}};const Ai=sn.getScrollerElement();return Ai.addEventListener("scroll",qi),()=>{Ai.removeEventListener("scroll",qi)}}},[sn,Qe]),(0,Ft.useEffect)(()=>{if(sn&&ui){let qi=function(Ai,Nn){ui(Ai,Nn)};return sn.on("beforeChange",qi),()=>{sn.off("beforeChange",qi)}}},[sn,ui]),(0,Ft.useEffect)(()=>{if(sn&&en){let qi=function(){en(sn.getValue())};return sn.on("blur",qi),()=>{sn.off("blur",qi)}}},[sn,en]);function Yo(qi,Ai){var Nn=qi.getDoc(),Zi=Nn.getCursor(),Xo=Nn.getLine(Zi.line),zr=Xo.charAt(Zi.ch-1),Ir=Xo.lastIndexOf("@\u2581@",Zi.ch),Vr=Xo.lastIndexOf("@\u2581\u2581@",Zi.ch),Ns=Ir>Vr?Ir:Vr,Jr=Ir>Vr?3:4;if(wi.indexOf(zr)===-1)return null;if(console.log("change1:",Ai,qi,Xo,Zi,Ns,Ir,Vr,zr),Ns>=0&&Zi.ch-Ns<5){var ga=Ns+Jr;return Nn.replaceRange("",{line:Zi.line,ch:Ns},{line:Zi.line,ch:ga}),{line:Zi.line,ch:ga}}return null}(0,Ft.useEffect)(()=>{if(sn){let qi=function(Ai,Nn){const Zi=Ai.getValue();io(Zi),Ri(new Date().getTime()),Ai.getScrollerElement().dispatchEvent(new CustomEvent("scroll")),We&&(An?We(Zi,to(Zi)):We(Zi))};return sn.on("change",qi),()=>{sn.off("change",qi)}}},[sn,We]),(0,Ft.useEffect)(()=>{if(sn)if(_e==null)sn.setValue(""),io("");else{const qi=window.scrollY||window.pageYOffset;_e!==sn.getValue()&&(sn.setValue(_e),io(_e),sn.setCursor(hi?1:sn.lineCount(),0),window.scrollTo(0,qi))}},[sn,_e]);const ri=(0,Ft.useCallback)(qi=>{const Ai=sn.getCursor(),Nn=sn.getSelection();let Zi=Nn.split(` `);switch(qi){case"bold":return sn.replaceSelection("**"+Nn+"**"),Nn===""&&sn.setCursor(Ai.line,Ai.ch+2),sn.focus();case"italic":return sn.replaceSelection("*"+Nn+"*"),Nn===""&&sn.setCursor(Ai.line,Ai.ch+1),sn.focus();case"code":return sn.replaceSelection("`"+Nn+"`"),Nn===""&&sn.setCursor(Ai.line,Ai.ch+1),sn.focus();case"inline-latex":return Qi("inline-latex"),sn.focus();case"latex":return sn.replaceSelection("```latex\n"+Nn+"\n```"),sn.setCursor(Ai.line+1,Nn.length+1),sn.focus();case"line-break":return sn.replaceSelection(`
`),sn.focus();case"list-ul":return Nn===""?sn.replaceSelection("- "+Nn):sn.replaceSelection(Zi.map(Xo=>Xo===""?"":`- ${Xo}`).join(` `)),sn.focus();case"list-ol":return Nn===""?sn.replaceSelection("1. "+Nn):sn.replaceSelection(Zi.map((Xo,zr)=>Xo===""?"":`${zr+1}. ${Xo}`).join(` `)),sn.focus();case"add-null-ch":return Nn===""&&sn.setCursor(Ai.line,Ai.ch),sn.replaceSelection(Vi),sn.focus();case"add-signal":return Nn===""&&sn.setCursor(Ai.line,Ai.ch),sn.replaceSelection(bt),sn.focus();case"add-multiple":return Nn===""&&sn.setCursor(Ai.line,Ai.ch),sn.replaceSelection(wi),sn.focus();case"inster-template-1":return Nn===""&&sn.setCursor(Ai.line,Ai.ch),sn.replaceSelection(no),sn.focus();case"eraser":return sn.setValue(""),sn.focus();case"trigger-watch":return Hn(!Qe),sn.focus();case"trigger-full-screen":return bi(!di),sn.focus();case ni:Qi(ni);return;case Mi:Qi(Mi);return;case Un:Qi(Un);return;case mi:Qi(mi);return;case"maths-latex":Qi("maths-latex");return;case gi:Qi(gi);return;case eo:Qi(eo);return;default:throw new Error}},[sn,Qe,di]),Gt=(0,Ft.useCallback)((qi,Ai)=>{var Nn,Zi,Xo,zr,Ir,Vr;switch(Qi(""),yi){case ni:const{title:Ea,link:Ye}=qi;return sn.replaceSelection(`[${Ea}](${Ye})`),sn.focus();case Mi:const{language:Ws,content:gh}=qi;return sn.replaceSelection(["```"+Ws,gh,"```"].join(` `)),sn.focus();case"maths-latex":for(var Ns=atob(qi),Jr=new Uint8Array(Ns.length),ga=0;ga{lo.id?sn.replaceSelection(`![,](/api/attachments/${lo.id}?type=${lo.content_type})`):(lo==null?void 0:lo.status)===401&&(document.location.href="/user/login")});break;case"inline-latex":sn.replaceSelection("`$$"+qi+"$$`");break;case Un:case mi:case $i:const{src:kl,alt:uu}=qi,ts=Ai,th=(Xo=(Zi=(Nn=ts==null?void 0:ts.name)==null?void 0:Nn.split("."))==null?void 0:Zi.pop)==null?void 0:Xo.call(Zi);return((zr=ts==null?void 0:ts.type)==null?void 0:zr.indexOf("image"))>-1||!(ts!=null&&ts.type)?ts!=null&&ts.align||ts!=null&&ts.width?sn.replaceSelection(`

${uu||

`):sn.replaceSelection(`${uu||`):((Ir=ts==null?void 0:ts.type)==null?void 0:Ir.indexOf("video"))>-1?sn.replaceSelection(``):((Vr=ts==null?void 0:ts.type)==null?void 0:Vr.indexOf("pdf"))>-1?sn.replaceSelection(`${ts.name}`):Ni.includes(th)?sn.replaceSelection(`${ts.name}`):sn.replaceSelection(`[${ts.name}](${kl})`),sn.focus();case eo:const{row:eh,col:Gr,align:Ts}=qi;let Ul=` `;for(let lo=0;lo{switch(yi){case ni:return Ft.createElement(xn,{callback:Gt,onCancel:Sr});case Mi:return Ft.createElement(En.Z,{callback:Gt,onCancel:Sr});case Un:return Ft.createElement(Ne.Z,{callback:Gt,onCancel:Sr});case gi:return Ft.createElement(ne,{callback:Gt,onCancel:Sr});case eo:return Ft.createElement(Me,{callback:Gt,onCancel:Sr});case"maths-latex":return Ft.createElement(wn,{showSaveButton:!0,callback:Gt});case"inline-latex":return Ft.createElement(pn.Z,{showSaveButton:!0,callback:Gt});default:return null}},[yi]);function Sr(){Qi("")}(0,Ft.useEffect)(()=>{if(Wi.current){let qi=function(Ir){Xo=!0,zr=Ir.pageY},Ai=function(){Xo=!1},Nn=function(Ir){if(Xo){let Vr=Ir.pageY-zr;Vr<0&&(Vr=0),Vr>300&&(Vr=300);let Ns=on+Vr+"px";fo(Ns)}},Zi=Wi.current,Xo=!1,zr=0;return Zi.addEventListener("mousedown",qi),document.addEventListener("mousemove",Nn),document.addEventListener("mouseup",Ai),()=>{Zi.removeEventListener("mousedown",qi),document.removeEventListener("mousemove",Nn),document.removeEventListener("mouseup",Ai)}}},[sn,Wi]),(0,Ft.useEffect)(()=>{fo(on)},[on]);const ps=ho(Jt),ms=ho(Hi),ks={width:ps,height:ms},po=(0,Ft.useMemo)(()=>{if(co){let qi=new Date(co),Ai=qi.getHours(),Nn=qi.getMinutes(),Zi=qi.getSeconds();return Ai=Ai<10?"0"+Ai:Ai,Nn=Nn<10?"0"+Nn:Nn,Zi=Zi<10?"0"+Zi:Zi,`${Ai}:${Nn}:${Zi}`}return 0},[co]),to=qi=>{const Ai=[];if(An){let Nn=-1;qi=qi.replace(/(@▁▁@|@▁@)/g,function(Zi,Xo,zr){Ai.push({multiLine:Zi!==bt})})}return Ai};function Ko(){window.sessionStorage.removeItem(Xn),Uo(!1),Ri(0)}function ao(){Uo(!1),Ri(0),sn.setValue(window.sessionStorage.getItem(Xn))}(0,Ft.useEffect)(()=>{Fo[yi]&&yi!==mi&&yi!==gi&&setTimeout(()=>{const qi=document.getElementsByClassName("markdown-popup-form")[0],Ai=window.innerWidth/2-qi.offsetWidth/2,Nn=window.innerHeight/2-qi.offsetHeight/2;Po(Ai),$o(Nn)},0)},[yi]);const lr=qi=>{qi.preventDefault();const Ai=qi.clientX-un,Nn=qi.clientY-kr;document.body.onmousemove=Zi=>{let Xo=Zi.clientX-Ai,zr=Zi.clientY-Nn;const Ir=document.getElementsByClassName("markdown-popup-form")[0],Vr=window.innerWidth-Ir.offsetWidth,Ns=window.innerHeight-Ir.offsetHeight;Xo=Math.max(0,Math.min(Xo,Vr)),zr=Math.max(0,Math.min(zr,Ns)),Ys(Zi.clientX,Zi.clientY,Ai,Nn)&&(Po(Xo),$o(zr))},document.body.onmouseup=function(){document.body.onmousemove=null}},Ys=(qi,Ai,Nn,Zi)=>{const Xo=document.body.clientHeight,zr=document.body.clientWidth;return qi<20&&Nn>qi||qi>zr-20&&NnAi||Ai>Xo-20&&ZiYt in ie?Fe(ie,Yt,{enumerable:!0,configurable:!0,writable:!0,value:fe}):ie[Yt]=fe,at=(ie,Yt)=>{for(var fe in Yt||(Yt={}))et.call(Yt,fe)&&dt(ie,fe,Yt[fe]);if(It)for(var fe of It(Yt))nt.call(Yt,fe)&&dt(ie,fe,Yt[fe]);return ie},gt=(ie,Yt)=>ye(ie,Re(Yt));const{useForm:mt}=Ft.default,Pt={width:280,marginRight:10},kt={labelCol:{span:5},wrapperCol:{span:19}};var Tt=({callback:ie,onCancel:Yt})=>{const[fe]=mt();let Zt=(0,be.useRef)();function je(Se){Zt.current.width=fe.getFieldValue("width"),Zt.current.align=fe.getFieldValue("align"),ie(Se,Zt.current)}function me(Se,Ie){if(Se.status===-1){Ht.ZP.error(Se.message);return}fe.setFieldsValue({src:`/api/attachments/${Se.id}`,type:Ie.type})}function Xe(Se){let Ie=Se.target.files[0];Zt.current=Ie,$t(Ie,me)}return Qt.createElement(Ft.default,gt(at({form:fe},kt),{className:"upload-image-panel",onFinish:je,style:{width:470,overflow:"hidden"}}),Qt.createElement(Ft.default.Item,{label:"\u56FE\u7247\u5730\u5740",required:!0},Qt.createElement("div",{className:"flex-container"},Qt.createElement(Ft.default.Item,{noStyle:!0,name:"src",rules:[{required:!0,message:"\u8BF7\u8F93\u5165\u56FE\u7247\u5730\u5740"}]},Qt.createElement(oe.default,{style:Pt})),Qt.createElement(Dt,{onFileChange:Xe}))),Qt.createElement(Ft.default.Item,{label:"\u56FE\u7247\u63CF\u8FF0",name:"alt"},Qt.createElement(oe.default,{style:{width:264}})),Qt.createElement(Ft.default.Item,{label:"\u56FE\u7247\u5BBD\u5EA6",name:"width"},Qt.createElement(ke.Z,null,Qt.createElement(Ft.default.Item,{name:"width",style:{margin:0}},Qt.createElement(Vt.Z,{style:{width:264}})),Qt.createElement("span",{className:"ml8"},"%"))),Qt.createElement(Ft.default.Item,{label:"\u5BF9\u9F50\u65B9\u5F0F",name:"align"},Qt.createElement(qt.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"}]})),Qt.createElement("aside",null,Qt.createElement(Ft.default.Item,{style:{textAlign:"right",position:"relative",right:-98}},Qt.createElement(Nt.ZP,{type:"primary",htmlType:"submit",style:{marginRight:10}},"\u786E\u5B9A"),Qt.createElement(Nt.ZP,{type:"default",onClick:Yt},"\u53D6\u6D88"))))};function Dt({onFileChange:ie}){return Qt.createElement("label",{className:"upload-button",style:{cursor:"pointer"}},"\u672C\u5730\u4E0A\u4F20",Qt.createElement("input",{type:"file",onChange:ie}))}function $t(ie,Yt){if(!ie)throw new String("\u6CA1\u6709\u6587\u4EF6");let fe=new FormData;fe.append("editormd-image-file",ie),fe.append("file_param_name","editormd-image-file"),fe.append("byxhr","true");var Zt=new window.XMLHttpRequest;Zt.withCredentials=!0,Zt.addEventListener("load",function(je){Yt(JSON.parse(je.target.responseText),ie)},!1),Zt.addEventListener("error",function(je){console.error(je)},!1),Zt.open("POST",`${Oe.KI}/api/attachments.json`),Zt.send(fe)}},79346:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return oe}});var Ft=wt(59301),Ht=wt(4676);class oe extends Ft.Component{constructor(Vt){super(Vt);const qt=window.document;this.node=qt.createElement("div"),qt.body.appendChild(this.node)}render(){const{children:Vt}=this.props;return(0,Ht.createPortal)(Vt,this.node)}componentWillUnmount(){window.document.body.removeChild(this.node)}}},23954:function(Cn,cn,wt){"use strict";wt.d(cn,{SV:function(){return ae},ZP:function(){return yt}});var Ft=wt(59301),Ht=wt(76374);const oe={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"]},ke={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"]},Vt={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 ",content:["#include "].join(` `)},{label:"include ",content:["#include "].join(` `)},{label:"include ",content:["#include "].join(` `)},{label:"include ",content:["#include "].join(` `)},{label:"include ",content:["#include "].join(` `)},{label:"include ",content:["#include "].join(` `)},{label:"include ",content:["#include "].join(` `)},{label:"include ",content:["#include "].join(` `)},{label:"include ",content:["#include "].join(` `)}]},qt={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(` `)}]},Nt={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 Oe=wt(53184),be=wt.n(Oe),Qt=Object.defineProperty,Fe=Object.defineProperties,ye=Object.getOwnPropertyDescriptors,Re=Object.getOwnPropertySymbols,It=Object.prototype.hasOwnProperty,et=Object.prototype.propertyIsEnumerable,nt=(Pe,ne,_t)=>ne in Pe?Qt(Pe,ne,{enumerable:!0,configurable:!0,writable:!0,value:_t}):Pe[ne]=_t,dt=(Pe,ne)=>{for(var _t in ne||(ne={}))It.call(ne,_t)&&nt(Pe,_t,ne[_t]);if(Re)for(var _t of Re(ne))et.call(ne,_t)&&nt(Pe,_t,ne[_t]);return Pe},at=(Pe,ne)=>Fe(Pe,ye(ne)),gt=(Pe,ne,_t)=>new Promise((ge,pe)=>{var le=qe=>{try{nn(_t.next(qe))}catch(Ge){pe(Ge)}},Me=qe=>{try{nn(_t.throw(qe))}catch(Ge){pe(Ge)}},nn=qe=>qe.done?ge(qe.value):Promise.resolve(qe.value).then(le,Me);nn((_t=_t.apply(Pe,ne)).next())});const mt={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"]}},Pt=(Pe,ne)=>ne.map(_t=>({label:_t,kind:Pe.languages.CompletionItemKind.Keyword,insertText:_t})),kt=Pe=>Object.keys(mt.tables).map(ne=>({label:ne,kind:Pe.languages.CompletionItemKind.Variable,insertText:ne})),Tt=(Pe,ne)=>{const _t=mt.tables[Pe];return _t?_t.map(ge=>({label:ge,kind:ne.languages.CompletionItemKind.Field,insertText:ge})):[]};function Dt(Pe,ne,_t,ge,pe){let le=ne.getWordUntilPosition(_t),Me={startLineNumber:_t.lineNumber,endLineNumber:_t.lineNumber,startColumn:le.startColumn,endColumn:le.endColumn},nn=ge.map(qe=>({label:qe,kind:Pe.languages.CompletionItemKind.Keyword,insertText:qe,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:Me}));return pe.map(qe=>{nn.push(at(dt({},qe),{range:Me}))}),nn}var $t=Pe=>{mt.languages.map(pe=>(Pe.languages.registerDocumentFormattingEditProvider(pe,{provideDocumentFormattingEdits(le,Me,nn){return gt(this,null,function*(){const qe=be()(le.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:le.getFullModelRange(),text:qe}]})}}),pe));const ne=Vt.quickKey.map(pe=>({label:pe.label,kind:Pe.languages.CompletionItemKind.Method,insertText:pe.content,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet})),_t=qt.quickKey.map(pe=>({label:pe.label,kind:Pe.languages.CompletionItemKind.Method,insertText:pe.content,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet})),ge=ke.quickKey.map(pe=>({label:pe.label,kind:Pe.languages.CompletionItemKind.Method,insertText:pe.content,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet}));Pe.languages.registerCompletionItemProvider("cpp",{provideCompletionItems:function(pe,le){var Me=pe.getWordUntilPosition(le),nn={startLineNumber:le.lineNumber,endLineNumber:le.lineNumber,startColumn:Me.startColumn,endColumn:Me.endColumn},qe=pe.getLineContent(le.lineNumber).substring(Me.startColumn-2,Me.endColumn);return{suggestions:[...Vt.keywords.map(Ge=>({label:Ge,kind:Pe.languages.CompletionItemKind.Function,documentation:Ge,insertText:Ge,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn})),...Vt.quickKey.map(Ge=>({label:Ge.label,kind:Pe.languages.CompletionItemKind.Function,documentation:Ge.content,insertText:qe.startsWith("#")?Ge.content.replace(/#/,""):Ge.content,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn}))]}}}),Pe.languages.registerCompletionItemProvider("c",{provideCompletionItems:function(pe,le){var Me=pe.getWordUntilPosition(le),nn={startLineNumber:le.lineNumber,endLineNumber:le.lineNumber,startColumn:Me.startColumn,endColumn:Me.endColumn};return{suggestions:[...oe.keywords.map(qe=>({label:qe,kind:Pe.languages.CompletionItemKind.Function,documentation:qe,insertText:qe,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn}))]}}}),Pe.languages.registerCompletionItemProvider("java",{provideCompletionItems:function(pe,le){var Me=pe.getWordUntilPosition(le),nn={startLineNumber:le.lineNumber,endLineNumber:le.lineNumber,startColumn:Me.startColumn,endColumn:Me.endColumn},qe=pe.getLineContent(le.lineNumber).substring(Me.startColumn-2,Me.endColumn);return{suggestions:[...ke.keywords.map(Ge=>({label:Ge,kind:Pe.languages.CompletionItemKind.Function,documentation:Ge,insertText:Ge,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn})),...ke.quickKey.map(Ge=>({label:Ge.label,kind:Pe.languages.CompletionItemKind.Function,documentation:Ge.content,insertText:qe.startsWith("#")?Ge.content.replace(/#/,""):Ge.content,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn}))]}}}),Pe.languages.registerCompletionItemProvider("scala",{provideCompletionItems:function(pe,le){var Me=pe.getWordUntilPosition(le),nn={startLineNumber:le.lineNumber,endLineNumber:le.lineNumber,startColumn:Me.startColumn,endColumn:Me.endColumn},qe=pe.getLineContent(le.lineNumber).substring(Me.startColumn-2,Me.endColumn);return{suggestions:[...Nt.keywords.map(Ge=>({label:Ge,kind:Pe.languages.CompletionItemKind.Function,documentation:Ge,insertText:Ge,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn})),...Nt.quickKey.map(Ge=>({label:Ge.label,kind:Pe.languages.CompletionItemKind.Function,documentation:Ge.content,insertText:qe.startsWith("#")?Ge.content.replace(/#/,""):Ge.content,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn}))]}}}),Pe.languages.registerCompletionItemProvider("python",{provideCompletionItems:function(pe,le){var Me=pe.getWordUntilPosition(le),nn={startLineNumber:le.lineNumber,endLineNumber:le.lineNumber,startColumn:Me.startColumn,endColumn:Me.endColumn},qe=pe.getLineContent(le.lineNumber).substring(Me.startColumn-2,Me.endColumn);return{suggestions:[...qt.keywords.map(Ge=>({label:Ge,kind:Pe.languages.CompletionItemKind.Function,documentation:Ge,insertText:Ge,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn})),...qt.quickKey.map(Ge=>({label:Ge.label,kind:Pe.languages.CompletionItemKind.Function,documentation:Ge.content,insertText:qe.startsWith("#")?Ge.content.replace(/#/,""):Ge.content,insertTextRules:Pe.languages.CompletionItemInsertTextRule.InsertAsSnippet,range:nn}))]}}})};const ie="\u8BE5\u4EFB\u52A1\u5173\u5361\u8BBE\u7F6E\u4E86\u7981\u6B62\u590D\u5236\u7C98\u8D34\uFF0C\u8BF7\u624B\u52A8\u8F93\u5165\u4EE3\u7801\u3002";var Yt=Object.defineProperty,fe=(Pe,ne,_t)=>ne in Pe?Yt(Pe,ne,{enumerable:!0,configurable:!0,writable:!0,value:_t}):Pe[ne]=_t,Zt=(Pe,ne,_t)=>fe(Pe,typeof ne!="symbol"?ne+"":ne,_t);const je=class px{constructor(ne,_t,ge){this.placeholder=ne,this.editor=_t,this.monaco=ge,_t.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)}};Zt(je,"ID","editor.widget.placeholderHint");var Xe=je,Se=wt(96236),Ie=wt(8591),ze=wt(6848),Ue=wt(89392),se=wt(34604),jt=wt(56102),$e=Object.defineProperty,xn=Object.defineProperties,En=Object.getOwnPropertyDescriptors,Ne=Object.getOwnPropertySymbols,Ze=Object.prototype.hasOwnProperty,rn=Object.prototype.propertyIsEnumerable,zn=(Pe,ne,_t)=>ne in Pe?$e(Pe,ne,{enumerable:!0,configurable:!0,writable:!0,value:_t}):Pe[ne]=_t,tn=(Pe,ne)=>{for(var _t in ne||(ne={}))Ze.call(ne,_t)&&zn(Pe,_t,ne[_t]);if(Ne)for(var _t of Ne(ne))rn.call(ne,_t)&&zn(Pe,_t,ne[_t]);return Pe},Tn=(Pe,ne)=>xn(Pe,En(ne)),we=(Pe,ne)=>{var _t={};for(var ge in Pe)Ze.call(Pe,ge)&&ne.indexOf(ge)<0&&(_t[ge]=Pe[ge]);if(Pe!=null&&Ne)for(var ge of Ne(Pe))ne.indexOf(ge)<0&&rn.call(Pe,ge)&&(_t[ge]=Pe[ge]);return _t},Bn=(Pe,ne,_t)=>new Promise((ge,pe)=>{var le=qe=>{try{nn(_t.next(qe))}catch(Ge){pe(Ge)}},Me=qe=>{try{nn(_t.throw(qe))}catch(Ge){pe(Ge)}},nn=qe=>qe.done?ge(qe.value):Promise.resolve(qe.value).then(le,Me);nn((_t=_t.apply(Pe,ne)).next())});function Jn(Pe){return/^\d+$/.test(Pe)?`${Pe}px`:Pe}function Rt(){}let Lt=!1;const St={"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 Et(Pe=[]){let ne=Pe;if(Array.isArray(Pe)){for(let _t=0;_t{var ne=Pe,{width:_t="100%",height:ge="100%",value:pe,language:le="javascript",style:Me={},options:nn={},overrideServices:qe={},theme:Ge="vs-dark",onEditBlur:yn,isCopy:wn=!1,onSave:pn,autoHeight:Yn=!1,forbidCopy:ni=!1,onChange:Un=Rt,editorDidMount:gi=Rt,onFocus:mi=Rt,onBreakPoint:$i=Rt,breakPointValue:Mi=[],filename:eo="educoder.txt",errorLine:Io,errorContent:Ao="",highlightLine:$n,openBreakPoint:Kn=!1,placeholder:jn=""}=ne,ii=we(ne,["width","height","value","language","style","options","overrideServices","theme","onEditBlur","isCopy","onSave","autoHeight","forbidCopy","onChange","editorDidMount","onFocus","onBreakPoint","breakPointValue","filename","errorLine","errorContent","highlightLine","openBreakPoint","placeholder"]);const Vi=(0,Ft.useRef)(),wi=(0,Ft.useRef)({}),bt=(0,Ft.useRef)(),no=(0,Ft.useRef)(),Ni=(0,Ft.useRef)([]),ho=(0,Ft.useRef)(!1),pr=(0,Ft.useRef)(),ar=(0,Ft.useRef)(),sr=(0,Ft.useRef)(!1),[Fo,nr]=(0,Ft.useState)(!1);function _e(){let Ae;return Vi.current&&(Ae=new Ht.Z(en=>{for(let ui of en)(ui.target.offsetHeight>0||ui.target.offsetWidth>0)&&wi.current.instance.layout()}),Ae.observe(Vi.current)),Ae}function We(){Ie.ZP.warning({content:decodeURIComponent(ie),key:"monaco-editor-tip"})}const Jt=()=>{let Ae=wi.current.instance;if(pe!=null&&Ae&&Fo){const en=Ae.getModel();en&&pe!==en.getValue()&&(Lt=!0,en.setValue(pe),Ae.layout(),Lt=!1)}};(0,Ft.useEffect)(()=>{const Ae=se.Z.subscribe("formatDocument",en=>{var ui;let oi=wi.current.instance;(ui=oi==null?void 0:oi.getAction)==null||ui.call(oi,"editor.action.formatDocument").run()});return window.updateMonacoValue=en=>{Un(en)},Ae},[]),(0,Ft.useEffect)(()=>{var Ae;let en=wi.current.instance;no.current&&clearTimeout(no.current),no.current=setTimeout(()=>{Jt()},500),pe&&(pe!=null&&pe.length)&&((Ae=en==null?void 0:en.updateOptions)==null||Ae.call(en,{lineNumbersMinChars:Math.max(Math.floor(Math.log10(pe.split(/\r\n|\r|\n/g).length))+3,5)}))},[pe,Fo,wi.current]),(0,Ft.useEffect)(()=>{if(Io&&wi.current&&wi.current.instance){let en=wi.current.instance;en.changeViewZones(function(ui){var oi=document.createElement("div");oi.style.padding="10px 20px",oi.style.width="calc(100% - 20px)",oi.className="my-error-line-wrp",oi.innerHTML=Ao,ui.addZone({afterLineNumber:Io||11,heightInLines:3,domNode:oi})});var Ae={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}};en.addOverlayWidget(Ae),en.revealPositionInCenter({lineNumber:20,column:1})}},[Io,wi.current,Fo]);const on=(Ae="",en)=>{if(!Ae||Ae.trim()==="")return!0;const oi=wi.current.instance.getModel().getLineTokens(en);let Si=!1;for(let Zn=0;Zn<2;Zn++)oi.getStandardTokenType(Zn)===1&&(Si=!0);return Si};(0,Ft.useEffect)(()=>{var Ae;const en=(Ae=wi.current)==null?void 0:Ae.instance;if(en&&Fo&&ni){const ui=en.onDidBlurEditorWidget(()=>{sr.current=!1}),oi=en.onDidFocusEditorText(()=>{sr.current=!0});return()=>{ui.dispose(),oi.dispose()}}},[wi.current,Fo,ni]),(0,Ft.useEffect)(()=>{var Ae;if((Ae=wi.current)!=null&&Ae.instance&&Fo&&Kn){let en=wi.current.instance,ui=en.getModel();if(!ui)return;(()=>{var io;let Qe=[],Hn=[];const di=ui.getAllDecorations();for(let yi of di)yi.options.className==="highlighted-line"&&(Qe.push((io=yi==null?void 0:yi.range)==null?void 0:io.startLineNumber),Hn.push(yi==null?void 0:yi.id));if($n===Qe[0])return;ui.deltaDecorations(Hn,[]);const bi=ui.getLineCount();$n&&$n<=bi&&(en.deltaDecorations([],[{range:new Bt.Range($n,1,$n,ui.getLineMaxColumn($n)),options:{isWholeLine:!0,className:"highlighted-line"}}]),en.revealLineInCenter($n))})();const Si=(io=!1)=>{var Qe;let Hn=[],di=[];const bi=ui.getAllDecorations();for(let yi of bi)yi.options.linesDecorationsClassName==="breakpoints-select"&&(Hn.push((Qe=yi==null?void 0:yi.range)==null?void 0:Qe.startLineNumber),di.push(yi==null?void 0:yi.id));if(io)return{lines:Hn,ids:di};$i(Hn)},Zn=io=>Bn(void 0,null,function*(){let Qe={range:new Bt.Range(io,1,io,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-select"}};yield ui.deltaDecorations([],[Qe]),Si()}),hi=io=>Bn(void 0,null,function*(){let Qe=[];const Hn=en.getLineDecorations(io);for(let di of Hn)di.options.linesDecorationsClassName==="breakpoints-select"&&Qe.push(di.id);yield ui.deltaDecorations(Qe,[]),Si()}),Qn=io=>{let Qe=en.getLineDecorations(io);for(let Hn of Qe)if(Hn.options.linesDecorationsClassName==="breakpoints-select")return!0;return!1};if(!(0,Ue.isEqual)(Mi,Si(!0).lines)){ui.deltaDecorations(Si(!0).ids,[]);const io=Mi.map(Qe=>({range:new Bt.Range(Qe,1,Qe,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-select"}}));ui.deltaDecorations([],io)}const Ci=en.onDidChangeModelContent(io=>{let Qe=en.getPosition();if(Qe){let Hn=Qe.lineNumber;clearTimeout(ar.current),ar.current=setTimeout(()=>{on(ui.getLineContent(Hn),Hn)?hi(Hn):Qn(Hn)?(hi(Hn),Zn(Hn)):Si()},100)}}),so=en.onMouseDown(io=>{var Qe,Hn,di;if(io.target.detail&&((di=(Hn=(Qe=io.target)==null?void 0:Qe.element)==null?void 0:Hn.className)!=null&&di.includes("line-numbers"))){let bi=io.target.position.lineNumber;if(on(ui.getLineContent(bi),bi))return;Qn(bi)?hi(bi):Zn(bi)}}),wo=io=>{let Qe={range:new Bt.Range(io,1,io,1),options:{isWholeLine:!1,linesDecorationsClassName:"breakpoints-fake"}};Ni.current=en.deltaDecorations(Ni.current,[Qe])},sn=()=>{Ni.current=en.deltaDecorations(Ni.current,[])},Bo=en.onMouseMove(io=>{var Qe,Hn,di;if(sn(),io.target.detail&&((di=(Hn=(Qe=io.target)==null?void 0:Qe.element)==null?void 0:Hn.className)!=null&&di.includes("line-numbers"))){let bi=io.target.position.lineNumber;if(on(ui.getLineContent(bi),bi))return;wo(bi)}}),Vo=en.onMouseLeave(()=>{sn()});return()=>{Ci.dispose(),so.dispose(),Bo.dispose(),Vo.dispose()}}},[wi.current,Fo,Mi,$n,Kn,le]),(0,Ft.useEffect)(()=>{var Ae;(Ae=wi.current)!=null&&Ae.instance&&Kn&&wi.current.instance.setPosition({lineNumber:0,column:0})},[$n]);function Mn(){let Ae=wi.current.instance;if(Ae){const en=Ae.getSelection(),ui=wi.current.pastePos||{},oi=new Bt.Range(ui.startLineNumber||en.endLineNumber,ui.startColumn||en.endColumn,ui.endLineNumber||en.endLineNumber,ui.endColumn||en.endColumn);setTimeout(()=>{Ae.executeEdits("",[{range:oi,text:""}])},300)}}function Le(Ae){(window.navigator.platform.match("Mac")?Ae.metaKey:Ae.ctrlKey)&&Ae.keyCode==83&&(Ae.preventDefault(),pn())}const ue=()=>{if(Yn&&wi.current.instance){const Ae=wi.current.instance.getContentHeight();An(Ae{if(!sr.current)return;const{keyCode:en,ctrlKey:ui,metaKey:oi,target:Si,type:Zn}=Ae;return(Zn==="paste"||(en===67||en===86)&&(oi||ui))&&Si.nodeName==="TEXTAREA"&&(We(),Ae.preventDefault()),!1};function Xn(Ae,en){var ui=window.URL||window.webkitURL||window,oi=new Blob([en]),Si=document.createElementNS("http://www.w3.org/1999/xhtml","a");Si.href=ui.createObjectURL(oi),Si.download=Ae,Je(Si)}(0,Ft.useEffect)(()=>{ue()},[ue]),(0,Ft.useEffect)(()=>{Vi.current&&!Fo&&Promise.all([wt.e(8909),wt.e(3267)]).then(wt.bind(wt,71448)).then(Ae=>{try{Bt=Ae,wi.current.instance=Bt.editor.create(Vi.current,{value:pe,language:Et(le),theme:Ge,requireConfig:{"vs/nls":{availableLanguages:{"*":"zh-cn"}}},wordWrap:!0,autoIndent:!0,contextmenu:!0,formatOnType:!0},qe);const en=wi.current.instance;let Si=[...Se.BH._menuItems].find(Ci=>Ci[0]._debugName=="EditorContext")[1],Zn=["editor.action.clipboardCopyWithSyntaxHighlightingAction","editor.action.quickCommand","editor.action.clipboardCopyAction","editor.action.clipboardPasteAction","editor.action.clipboardCutAction"],hi=(Ci,so)=>{var wo,sn;let Bo=Ci._first;do so.includes((sn=(wo=Bo.element)==null?void 0:wo.command)==null?void 0:sn.id)&&Ci._remove(Bo);while(Bo=Bo.next)};if(gi(en,Bt),setTimeout(()=>{ue(),wi.current.instance.addAction({id:"d123123",label:"Download File",contextMenuGroupId:"9_cutcopypaste",run:()=>{Xn(eo||"educoder.txt",en.getValue())}})},500),wi.current.subscription=en.onDidChangeModelContent(Ci=>{ho.current?clearTimeout(pr.current):(ue(),Un(en.getValue(),Ci)),pr.current=setTimeout(()=>{ho.current=!1},500)}),window.Monaco||$t(Bt,Et(le)),ni&&(hi(Si,Zn),Vi.current.classList.add("noCopyPaste"),window.removeEventListener("keydown",gn),window.removeEventListener("paste",gn),window.addEventListener("keydown",gn),window.addEventListener("paste",gn)),window.Monaco=Bt,yn&&en.onDidBlurEditorWidget(()=>{yn(en.getValue())}),mi&&en.onDidFocusEditorText(()=>{mi(en.getValue())}),ni)try{en.onDidPaste(Ci=>{const so=en.getSelection(),wo=wi.current.pastePos||{},sn=new Bt.Range(wo.startLineNumber||so.endLineNumber,wo.startColumn||so.endColumn,wo.endLineNumber||so.endLineNumber,wo.endColumn||so.endColumn);en.executeEdits("",[{range:Ci.range,text:""}])})}catch(Ci){}let Qn=_e();return jn&&typeof jn=="string"&&new Xe(jn,en,Bt),nr(!0),()=>{const Ci=wi.current.instance;Ci.dispose();const so=Ci.getModel();so&&so.dispose(),wi.current.subscription&&wi.current.subscription.dispose(),Qn.unobserve(Vi.current)}}catch(en){}})},[]),(0,Ft.useEffect)(()=>{if(wi.current.instance&&Fo)return document.addEventListener("keydown",Le,!1),()=>{document.removeEventListener("keydown",Le)}},[pn,Fo]),(0,Ft.useEffect)(()=>{let Ae=wi.current.instance;if(Ae&&Fo){let en=Et(le);Bt.editor.setModelLanguage(Ae.getModel(),en)}},[le,Fo]),(0,Ft.useEffect)(()=>{wi.current.instance&&Fo&&Bt.editor.setTheme(Ge)},[Ge,Fo]),(0,Ft.useEffect)(()=>{let Ae=wi.current.instance;bt.current=nn,Ae&&Fo&&(Ae.updateOptions(tn({},nn)),setTimeout(()=>{Ae.getModel().updateOptions(tn({},nn))},200))},[JSON.stringify(nn),Fo]),(0,Ft.useEffect)(()=>{let Ae=wi.current.instance;Ae&&Fo&&Ae.layout()},[_t,ge,Fo]);const[Gn,ce]=(0,Ft.useState)(Jn(_t)),[vn,An]=(0,Ft.useState)(Jn(ge)),xi=Tn(tn({},Me),{width:Gn,height:vn,position:"relative"});return Ft.createElement("div",{className:"my-monaco-editor",ref:Vi,style:xi},wn&&Ft.createElement(jt.CopyToClipboard,{text:pe,onCopy:()=>Ie.ZP.success("\u590D\u5236\u6210\u529F")},Ft.createElement(ze.Z,{title:"\u590D\u5236\u4EE3\u7801"},Ft.createElement("div",{style:{position:"absolute",top:0,right:10,cursor:"pointer",zIndex:10,color:"#165DFF"}},Ft.createElement("i",{className:"iconfont icon-fuzhi8",style:{fontSize:14}})," \u590D\u5236\u4EE3\u7801"))))};function ae({width:Pe="100%",height:ne="100%",original:_t,modified:ge,language:pe,options:le={}}){const Me=(0,Ft.useRef)(),[nn,qe]=(0,Ft.useState)(null);function Ge(Yn){let ni;return Me.current&&(ni=new Ht.Z(Un=>{for(let gi of Un)(gi.target.offsetHeight>0||gi.target.offsetWidth>0)&&Yn.layout()}),ni.observe(Me.current)),ni}(0,Ft.useEffect)(()=>(Me.current&&Promise.all([wt.e(8909),wt.e(9404)]).then(wt.bind(wt,2550)).then(Yn=>{Bt=Yn;const ni=Bt.editor.createDiffEditor(Me.current,Tn(tn({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},le),{wordWrap:!0}));qe(ni);let Un=Ge(ni);return()=>{ni.dispose();const gi=ni.getModel();gi&&gi.dispose(),Un.unobserve(Me.current)}}),()=>{window.removeEventListener("keydown",checkPaste),window.removeEventListener("paste",checkPaste)}),[]),(0,Ft.useEffect)(()=>{nn&&nn.setModel({original:Bt.editor.createModel(_t,pe),modified:Bt.editor.createModel(ge,pe)})},[_t,ge,pe,nn]);const yn=Jn(Pe),wn=Jn(ne),pn={width:yn,height:wn};return Ft.createElement("div",{className:"my-diff-editor",ref:Me,style:pn})}},58856:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Ht}});var Ft=wt(59301);function Ht(oe,ke){const Vt=(0,Ft.useRef)();(0,Ft.useEffect)(()=>{Vt.current=oe}),(0,Ft.useEffect)(()=>{function qt(){Vt.current()}if(ke!==null){let Nt=setInterval(qt,ke);return()=>clearInterval(Nt)}},[ke])}},19116:function(Cn,cn,wt){"use strict";wt.r(cn),wt.d(cn,{default:function(){return Ao}});var Ft=wt(59301),Ht=wt(89070),oe=wt(66104),ke=wt(99313),Vt=wt(27812),qt=wt(955),Nt=wt(12290),Oe=wt(3294),be=wt(85149),Qt=wt(43418),Fe=wt(8591),ye=Object.defineProperty,Re=Object.getOwnPropertySymbols,It=Object.prototype.hasOwnProperty,et=Object.prototype.propertyIsEnumerable,nt=($n,Kn,jn)=>Kn in $n?ye($n,Kn,{enumerable:!0,configurable:!0,writable:!0,value:jn}):$n[Kn]=jn,dt=($n,Kn)=>{for(var jn in Kn||(Kn={}))It.call(Kn,jn)&&nt($n,jn,Kn[jn]);if(Re)for(var jn of Re(Kn))et.call(Kn,jn)&&nt($n,jn,Kn[jn]);return $n},at=($n,Kn,jn)=>new Promise((ii,Vi)=>{var wi=Ni=>{try{no(jn.next(Ni))}catch(ho){Vi(ho)}},bt=Ni=>{try{no(jn.throw(Ni))}catch(ho){Vi(ho)}},no=Ni=>Ni.done?ii(Ni.value):Promise.resolve(Ni.value).then(wi,bt);no((jn=jn.apply($n,Kn)).next())});const gt=({shixunHomeworks:$n,dispatch:Kn})=>{const jn=(0,Ht.useParams)();return Ft.createElement(Qt.default,{centered:!0,title:"\u63D0\u793A",open:$n.actionTabs.key==="\u5220\u9664",okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",onOk:()=>at(void 0,null,function*(){(yield Kn({type:"shixunHomeworks/deleteReply",payload:{object_id:$n.actionTabs.selectArr.id,object_type:"journals_for_message"}})).status===0&&(Fe.ZP.success("\u5220\u9664\u6210\u529F"),Kn({type:"shixunHomeworks/setActionTabs",payload:{}}),Kn({type:"shixunHomeworks/getReplyList",payload:dt({},$n.actionTabs.params)}))}),onCancel:()=>{Kn({type:"shixunHomeworks/setActionTabs",payload:{}})}},Ft.createElement("p",null,"\u786E\u5B9A\u8981\u5220\u9664\u8BE5\u6761\u56DE\u590D\u5417\uFF1F"))};var mt=(0,Ht.connect)(({shixunHomeworks:$n})=>({shixunHomeworks:$n}))(gt),Pt=wt(61186),kt=wt.n(Pt),Tt=wt(95237),Dt=wt(43604),$t=wt(92832),ie=wt(3113),Yt=wt(6848),fe=wt(58421),Zt=wt(26227),je=wt(63524),me={flex_box_center:"flex_box_center___rwkot",flex_space_between:"flex_space_between___CV5Yi",flex_box_vertical_center:"flex_box_vertical_center___meeO5",flex_box_center_end:"flex_box_center_end___RXqc0",flex_box_column:"flex_box_column___HwZxi",listItem:"listItem___Cb1Ly",description:"description___UqYVS",liked:"liked___xlDpa",likedActive:"likedActive___GqNt1",reply:"reply___R3gEt",replyList:"replyList___AA3m5",comment:"comment___JuJKy"},Xe=Object.defineProperty,Se=Object.getOwnPropertySymbols,Ie=Object.prototype.hasOwnProperty,ze=Object.prototype.propertyIsEnumerable,Ue=($n,Kn,jn)=>Kn in $n?Xe($n,Kn,{enumerable:!0,configurable:!0,writable:!0,value:jn}):$n[Kn]=jn,se=($n,Kn)=>{for(var jn in Kn||(Kn={}))Ie.call(Kn,jn)&&Ue($n,jn,Kn[jn]);if(Se)for(var jn of Se(Kn))ze.call(Kn,jn)&&Ue($n,jn,Kn[jn]);return $n},jt=($n,Kn,jn)=>new Promise((ii,Vi)=>{var wi=Ni=>{try{no(jn.next(Ni))}catch(ho){Vi(ho)}},bt=Ni=>{try{no(jn.throw(Ni))}catch(ho){Vi(ho)}},no=Ni=>Ni.done?ii(Ni.value):Promise.resolve(Ni.value).then(wi,bt);no((jn=jn.apply($n,Kn)).next())});kt().locale("ZH-cn");const $e=({graduation:$n,classroomList:Kn,globalSetting:jn,loading:ii,dispatch:Vi})=>{const[wi,bt]=(0,Ft.useState)(se({},(0,Ht.useParams)())),[no,Ni]=(0,Ft.useState)(!1),[ho,pr]=(0,Ft.useState)(-1),[ar,sr]=(0,Ft.useState)(""),{detail:Fo}=$n,{detailLeftMenus:nr}=Kn,{graduationDetail:_e,replyList:We,workDetail:Jt}=$n,on={1:"\u8BBE\u8BA1",2:"\u8BBA\u6587",3:"\u521B\u4F5C"},Mn={1:"\u751F\u4EA7/\u793E\u4F1A\u5B9E\u9645",2:"\u7ED3\u5408\u79D1\u7814",3:"\u5176\u5B83"},Le={1:"\u771F\u9898",2:"\u6A21\u62DF\u9898"},ue={1:"\u7EB5\u5411\u8BFE\u9898",2:"\u6A2A\u5411\u8BFE\u9898",3:"\u81EA\u9009"},Je={1:"\u65B0\u9898",2:"\u5F80\u5C4A\u9898\uFF0C\u6709\u65B0\u8981\u6C42",3:"\u5F80\u5C4A\u9898\uFF0C\u65E0\u65B0\u8981\u6C42"};return wi.page_size=10,(0,Ft.useEffect)(()=>{Vi({type:"graduation/getReplyList",payload:se({},wi)}),Vi({type:"graduation/getTopisDetail",payload:se({},wi)})},[wi.categoryId]),Ft.createElement("section",{className:me.bg},Ft.createElement("section",{className:" edu-container"},Ft.createElement("aside",{className:[me.desc,"c-black","font14","bg-white"].join(" ")},Ft.createElement("h1",{className:me.description},Fo.description),Ft.createElement("div",{className:"mt30"},Ft.createElement("ul",{className:me.listItem},Ft.createElement("li",null,Ft.createElement("span",{className:"c-light-black"},"\u8BFE\u9898\u7C7B\u578B\uFF1A"),Ft.createElement("span",null,on[Fo==null?void 0:Fo.topic_type]||"--")),Ft.createElement("li",null,Ft.createElement("span",{className:"c-light-black"},"\u8BFE\u9898\u6765\u6E90\uFF1A"),Ft.createElement("span",null,Mn[Fo==null?void 0:Fo.topic_source]||"--")),Ft.createElement("li",null,Ft.createElement("span",{className:"c-light-black"},"\u8BFE\u9898\u6027\u8D281\uFF1A"),Ft.createElement("span",null,Le[Fo==null?void 0:Fo.topic_property_first]||"--")),Ft.createElement("li",null,Ft.createElement("span",{className:"c-light-black"},"\u8BFE\u9898\u6027\u8D282\uFF1A"),Ft.createElement("span",null,ue[Fo==null?void 0:Fo.topic_property_second]||"--")),Ft.createElement("li",null,Ft.createElement("span",{className:"c-light-black"},"\u8BFE\u9898\u91CD\u590D\u60C5\u51B5\uFF1A"),Ft.createElement("span",null,Je[Fo==null?void 0:Fo.topic_repeat]||"--")),Ft.createElement("li",null,Ft.createElement("span",{className:"c-light-black"},"\u8C03\u7814\u6216\u5B9E\u4E60\u5730\u70B9\uFF1A"),Ft.createElement("span",null,Fo.city||"--")),Ft.createElement("li",{className:"fl with50"},Ft.createElement("span",{className:"c-light-black"},"\u8BFE\u9898\u6765\u6E90\u5355\u4F4D\uFF1A"),Ft.createElement("span",null,Fo.source_unit||"--"))))),Ft.createElement("aside",{className:[me.reply,"bg-white","mt20"].join(" ")},no&&Ft.createElement(Nt.Z,{onChange:gn=>{sr(gn)},height:200,isFocus:!0,watch:!0}),Ft.createElement(Tt.Z,{onClick:()=>{Ni(!0)}},Ft.createElement(Dt.Z,{flex:"1"},!no&&Ft.createElement($t.default,{size:"middle",className:"current",placeholder:"\u8BF4\u70B9\u4EC0\u4E48",disabled:!0})),Ft.createElement(Dt.Z,null,Ft.createElement(ie.ZP,{type:"primary",size:"middle",onClick:()=>jt(void 0,null,function*(){ar===""?Fe.ZP.error("\u8BF7\u8F93\u5165\u5185\u5BB9"):(yield Vi({type:"graduation/createReply",payload:{journals_for_message:{jour_id:wi.categoryId,jour_type:"HomeworkCommon",reply_id:1,notes:ar}}})).status===0&&(Fe.ZP.success("\u53D1\u5E03\u6210\u529F"),Vi({type:"graduation/getReplyList",payload:se({},wi)}),Ni(!1))})},"\u53D1\u8868")))),(We==null?void 0:We.comments)&&We.comments!=""&&Ft.createElement("aside",{className:[me.replyList,"bg-white"].join(" ")},We==null?void 0:We.comments.map(function(gn,Xn){var Gn,ce;return Ft.createElement(Tt.Z,{gutter:[12,12],key:Xn},Ft.createElement(Dt.Z,{flex:"40px"},Ft.createElement("img",{width:"40",src:`${Oe.Z.IMG_SERVER}/images/${(Gn=gn==null?void 0:gn.author)==null?void 0:Gn.image_url}`})),Ft.createElement(Dt.Z,{flex:"1"},Ft.createElement(Tt.Z,{align:"middle"},Ft.createElement(Dt.Z,{span:24},Ft.createElement("span",{className:"c-light-black"},(ce=gn==null?void 0:gn.author)==null?void 0:ce.name),Ft.createElement("span",{className:"c-light-black ml10"},kt()(gn==null?void 0:gn.created_on).fromNow()," \u53D1\u5E03")),Ft.createElement(Dt.Z,{span:24},Ft.createElement(be.Z,{value:gn.content})),gn.children&&Ft.createElement("aside",{className:me.comment},gn.children.map(function(vn,An){return Ft.createElement(Tt.Z,{key:An},Ft.createElement(Dt.Z,{span:24},Ft.createElement(Tt.Z,null,Ft.createElement(Dt.Z,{flex:"1"},vn.author.name,Ft.createElement("span",{className:"c-light-black ml10"},kt()(vn==null?void 0:vn.created_on).fromNow())),Ft.createElement(Dt.Z,null,Ft.createElement(Yt.Z,{title:"\u5220\u9664"},Ft.createElement(Zt.Z,{className:"current",onClick:()=>{Vi({type:"graduation/setActionTabs",payload:{key:"\u5220\u9664",params:wi,selectArr:gn}})}}))))),Ft.createElement(Dt.Z,null,Ft.createElement("strong",null,Ft.createElement(be.Z,{value:vn.content}))))})),Ft.createElement(Dt.Z,{span:24,className:"mt5 c-light-black"},ho===Xn&&Ft.createElement("aside",null,Ft.createElement(Nt.Z,{onChange:vn=>{sr(vn)},height:150,isFocus:!0}),Ft.createElement(Tt.Z,null,Ft.createElement(Dt.Z,{span:24,className:"tr"},Ft.createElement(ie.ZP,{type:"primary",size:"middle",onClick:()=>jt(this,null,function*(){ar===""?Fe.ZP.error("\u8BF7\u8F93\u5165\u5185\u5BB9"):(yield Vi({type:"graduation/createReply",payload:{journals_for_message:{jour_id:wi.categoryId,jour_type:"HomeworkCommon",m_parent_id:gn.id,reply_id:1,notes:ar}}}),Vi({type:"graduation/getReplyList",payload:se({},wi)}),Fe.ZP.success("\u53D1\u5E03\u6210\u529F"),pr(-1))})},"\u53D1\u8868")))),ho!==Xn&&Ft.createElement("div",{className:"tr"},Ft.createElement("span",{className:"iconfont icon-huifu1 mr5 ml30",onClick:()=>pr(Xn)}),gn.liked&&Ft.createElement("span",{className:"c-orange"},Ft.createElement(je.Z,{className:"mr5 ml30",onClick:()=>jt(this,null,function*(){yield Vi({type:"graduation/replyUnLike",payload:{object_id:gn.id,object_type:"message"}}),Vi({type:"graduation/getReplyList",payload:se({},wi)})})}),gn.praises_count),!gn.liked&&Ft.createElement("span",null,Ft.createElement(je.Z,{className:"mr5 ml30",onClick:()=>jt(this,null,function*(){yield Vi({type:"graduation/replyLike",payload:{object_id:gn.id,object_type:"message"}}),Vi({type:"graduation/getReplyList",payload:se({},wi)})})}),gn.praises_count))))))}))),Ft.createElement("aside",{className:"tc mt30 pb30"},Ft.createElement(fe.Z,{defaultCurrent:1,total:We==null?void 0:We.total_count,hideOnSinglePage:!0,current:wi.page||1,onChange:gn=>{wi.page=gn,Vi({type:"graduation/getReplyList",payload:se({},wi)})}})),Ft.createElement(mt,null))};var xn=(0,Ht.connect)(({graduation:$n,classroomList:Kn,loading:jn,globalSetting:ii})=>({graduation:$n,globalSetting:ii,classroomList:Kn,loading:jn.effects}))($e),En=wt(78241),Ne=wt(1710),Ze=Object.defineProperty,rn=Object.getOwnPropertySymbols,zn=Object.prototype.hasOwnProperty,tn=Object.prototype.propertyIsEnumerable,Tn=($n,Kn,jn)=>Kn in $n?Ze($n,Kn,{enumerable:!0,configurable:!0,writable:!0,value:jn}):$n[Kn]=jn,we=($n,Kn)=>{for(var jn in Kn||(Kn={}))zn.call(Kn,jn)&&Tn($n,jn,Kn[jn]);if(rn)for(var jn of rn(Kn))tn.call(Kn,jn)&&Tn($n,jn,Kn[jn]);return $n},Bn=($n,Kn)=>{var jn={};for(var ii in $n)zn.call($n,ii)&&Kn.indexOf(ii)<0&&(jn[ii]=$n[ii]);if($n!=null&&rn)for(var ii of rn($n))Kn.indexOf(ii)<0&&tn.call($n,ii)&&(jn[ii]=$n[ii]);return jn},Jn=($n,Kn,jn)=>new Promise((ii,Vi)=>{var wi=Ni=>{try{no(jn.next(Ni))}catch(ho){Vi(ho)}},bt=Ni=>{try{no(jn.throw(Ni))}catch(ho){Vi(ho)}},no=Ni=>Ni.done?ii(Ni.value):Promise.resolve(Ni.value).then(wi,bt);no((jn=jn.apply($n,Kn)).next())});const Rt=$n=>{var Kn=$n,{graduation:jn,dispatch:ii}=Kn,Vi=Bn(Kn,["graduation","dispatch"]);const wi=(0,Ht.useParams)();return Ft.createElement(Qt.default,{centered:!0,title:"\u63D0\u793A",open:jn.actionTabs.key==="\u62D2\u7EDD",okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",onOk:()=>Jn(void 0,null,function*(){(yield ii({type:"graduation/refuseTopic",payload:we({student_graduation_topic:jn.actionTabs.selectArrs.id},wi)})).status===0&&(Fe.ZP.success("\u62D2\u7EDD\u6210\u529F"),ii({type:"graduation/setActionTabs",payload:{}}),ii({type:"graduation/getTopisDetailList",payload:we({},jn.actionTabs.params)}))}),onCancel:()=>{ii({type:"graduation/setActionTabs",payload:{}})}},Ft.createElement("p",null,"\u662F\u5426\u786E\u8BA4\u62D2\u7EDD\u5B66\u751F\u9009\u9898?"))};var Lt=(0,Ht.connect)(({graduation:$n})=>({graduation:$n}))(Rt),St=wt(57809),Et=Object.defineProperty,Bt=Object.getOwnPropertySymbols,yt=Object.prototype.hasOwnProperty,ae=Object.prototype.propertyIsEnumerable,Pe=($n,Kn,jn)=>Kn in $n?Et($n,Kn,{enumerable:!0,configurable:!0,writable:!0,value:jn}):$n[Kn]=jn,ne=($n,Kn)=>{for(var jn in Kn||(Kn={}))yt.call(Kn,jn)&&Pe($n,jn,Kn[jn]);if(Bt)for(var jn of Bt(Kn))ae.call(Kn,jn)&&Pe($n,jn,Kn[jn]);return $n},_t=($n,Kn)=>{var jn={};for(var ii in $n)yt.call($n,ii)&&Kn.indexOf(ii)<0&&(jn[ii]=$n[ii]);if($n!=null&&Bt)for(var ii of Bt($n))Kn.indexOf(ii)<0&&ae.call($n,ii)&&(jn[ii]=$n[ii]);return jn},ge=($n,Kn,jn)=>new Promise((ii,Vi)=>{var wi=Ni=>{try{no(jn.next(Ni))}catch(ho){Vi(ho)}},bt=Ni=>{try{no(jn.throw(Ni))}catch(ho){Vi(ho)}},no=Ni=>Ni.done?ii(Ni.value):Promise.resolve(Ni.value).then(wi,bt);no((jn=jn.apply($n,Kn)).next())});const pe=$n=>{var Kn=$n,{graduation:jn,dispatch:ii}=Kn,Vi=_t(Kn,["graduation","dispatch"]),wi;const bt=(0,Ht.useParams)(),{detailList:no}=jn,[Ni]=En.default.useForm();return Ft.createElement(Qt.default,{centered:!0,title:"\u540C\u610F\u9009\u9898",open:jn.actionTabs.key==="\u540C\u610F",okText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",onOk:()=>ge(void 0,null,function*(){var ho;yield Ni.validateFields();const pr=Ni.getFieldsValue();(yield ii({type:"graduation/agreeTopic",payload:ne({group_id:pr.group_id,course_group_name:(ho=no==null?void 0:no.group_list)==null?void 0:ho.filter(sr=>sr.group_id==pr.group_id)[0].group_name,student_graduation_topic:jn.actionTabs.selectArrs.id},bt)})).status===0&&(Fe.ZP.success("\u540C\u610F\u6210\u529F"),ii({type:"graduation/setActionTabs",payload:{}}),ii({type:"graduation/getTopisDetailList",payload:ne({},jn.actionTabs.params)}))}),onCancel:()=>{ii({type:"graduation/setActionTabs",payload:{}})}},Ft.createElement("p",null,"\u786E\u8BA4\u540C\u610F\u5B66\u751F\u7684\u9009\u9898\uFF0C\u5C06\u5B66\u751F\u52A0\u5165\u6211\u7684\u5206\u73ED"),Ft.createElement(En.default,{form:Ni},Ft.createElement(En.default.Item,{name:"group_id",label:"\u9009\u62E9\uFF1A",rules:[{required:!0,message:"\u8BF7\u9009\u62E9\u5206\u73ED"}]},Ft.createElement(St.default,{placeholder:"\u8BF7\u9009\u62E9\u5206\u73ED",size:"middle"},(wi=no==null?void 0:no.group_list)==null?void 0:wi.map(function(ho,pr){return Ft.createElement(St.default.Option,{value:ho.group_id},ho.group_name)})))))};var le=(0,Ht.connect)(({graduation:$n})=>({graduation:$n}))(pe),Me=Object.defineProperty,nn=Object.getOwnPropertySymbols,qe=Object.prototype.hasOwnProperty,Ge=Object.prototype.propertyIsEnumerable,yn=($n,Kn,jn)=>Kn in $n?Me($n,Kn,{enumerable:!0,configurable:!0,writable:!0,value:jn}):$n[Kn]=jn,wn=($n,Kn)=>{for(var jn in Kn||(Kn={}))qe.call(Kn,jn)&&yn($n,jn,Kn[jn]);if(nn)for(var jn of nn(Kn))Ge.call(Kn,jn)&&yn($n,jn,Kn[jn]);return $n};const pn=({graduation:$n,loading:Kn,dispatch:jn})=>{const[ii,Vi]=(0,Ft.useState)(wn({},(0,Ht.useParams)())),wi=(0,Ht.useLocation)(),{detailList:bt}=$n,[no,Ni]=(0,Ft.useState)({}),[ho]=En.default.useForm(),pr=(sr,Fo)=>{ii.page=sr,ii.limit=20,jn({type:"graduation/getTopisDetailList",payload:wn({},ii)})},ar=[{title:"\u5E8F\u53F7",dataIndex:"name",width:200,align:"center",render:(sr,Fo,nr)=>nr+1},{title:"\u59D3\u540D",dataIndex:"student_name"},{title:"\u5B66\u53F7",dataIndex:"student_id"},{title:"\u5206\u73ED",dataIndex:"class_group_name"},{title:"\u9009\u9898\u65F6\u95F4",dataIndex:"selected_time"},{title:"\u786E\u8BA4\u7ED3\u679C",dataIndex:"result",render:sr=>sr==="\u5DF2\u62D2\u7EDD"?Ft.createElement("span",{className:"c-orange"},"\u5DF2\u62D2\u7EDD"):sr},{title:"\u64CD\u4F5C",dataInex:"action",render:(sr,Fo)=>Ft.createElement("div",null,(Fo.result==="\u5F85\u786E\u8BA4"||Fo.result==="\u5DF2\u540C\u610F")&&Ft.createElement("span",{className:"current",onClick:()=>{jn({type:"graduation/setActionTabs",payload:{key:"\u62D2\u7EDD",selectArrs:Fo,params:ii}})}},"\u62D2\u7EDD"),Fo.result==="\u5F85\u786E\u8BA4"&&Ft.createElement("span",{className:"current ml20 c-blue",onClick:()=>{jn({type:"graduation/setActionTabs",payload:{key:"\u540C\u610F",selectArrs:Fo,params:ii}})}},"\u540C\u610F"))}];return Ft.createElement(Ft.Fragment,null,Ft.createElement("section",{className:"minH500 bg-white "},Ft.createElement(Ne.default,{loading:Kn["graduation/getTopisDetailList"],pagination:!1,dataSource:bt.users_list,columns:ar}),Ft.createElement(Lt,null),Ft.createElement(le,null)),Ft.createElement("aside",{className:"tc mb50 mt30"},Ft.createElement(fe.Z,{hideOnSinglePage:!0,showSizeChanger:!1,onChange:pr,defaultCurrent:ii.page||1,current:ii.page||1,defaultPageSize:15,total:$n.users_count})))};var Yn=(0,Ht.connect)(({graduation:$n,loading:Kn})=>({graduation:$n,loading:Kn.effects}))(pn),ni={flex_box_center:"flex_box_center___D_8YV",flex_space_between:"flex_space_between___DI3Lx",flex_box_vertical_center:"flex_box_vertical_center___HQIdb",flex_box_center_end:"flex_box_center_end___jBPdg",flex_box_column:"flex_box_column___oBJ_R",title:"title___vQC28",menuTabs:"menuTabs___ZWqcp",rightMenu:"rightMenu___JdFEE",shixunDetail:"shixunDetail___rsPHS"},Un=Object.defineProperty,gi=Object.getOwnPropertySymbols,mi=Object.prototype.hasOwnProperty,$i=Object.prototype.propertyIsEnumerable,Mi=($n,Kn,jn)=>Kn in $n?Un($n,Kn,{enumerable:!0,configurable:!0,writable:!0,value:jn}):$n[Kn]=jn,eo=($n,Kn)=>{for(var jn in Kn||(Kn={}))mi.call(Kn,jn)&&Mi($n,jn,Kn[jn]);if(gi)for(var jn of gi(Kn))$i.call(Kn,jn)&&Mi($n,jn,Kn[jn]);return $n};const Io=({graduation:$n,globalSetting:Kn,loading:jn,dispatch:ii})=>{const Vi=(0,Ht.useParams)(),wi=(0,Ht.useLocation)(),[bt]=(0,Ht.useSearchParams)(),[no,Ni]=(0,Ft.useState)([]),[ho,pr]=(0,Ft.useState)(bt.get("tabs")||0),{detailList:ar}=$n;let sr;Vi.category=bt.get("category_id"),(0,Ft.useEffect)(()=>{ii({type:"graduation/getTopisDetailList",payload:eo({},Vi)})},[Vi.coursesId]);const Fo=[{name:"\u9009\u9898\u5217\u8868",id:0,compontent:Ft.createElement(Yn,null)},{name:"\u9009\u9898\u63CF\u8FF0",id:1,compontent:Ft.createElement(xn,null)}];return Ft.createElement("section",null,Ft.createElement("div",{className:"edu-container"},ar.course_name&&Ft.createElement("section",{className:"animated fadeIn"},Ft.createElement("aside",{className:"mt10"},Ft.createElement(oe.Z,{separator:">"},Ft.createElement(oe.Z.Item,null,Ft.createElement(Ht.Link,{to:`/classrooms/${ar.course_id}/shixun_homework`},ar.course_name)),Ft.createElement(oe.Z.Item,null,Ft.createElement(Ht.Link,{to:`/classrooms/${ar.course_id}/graduation_topics/${ar.graduation_id}`},"\u6BD5\u8BBE\u9009\u9898")),Ft.createElement(oe.Z.Item,null,"\u9009\u9898\u8BE6\u60C5"))),Ft.createElement("aside",{className:[ni.title,"mt20"].join(" ")},Ft.createElement(Ht.Link,{to:`/classrooms/${ar.course_id}/graduation_topics/${ar.graduation_id}`},Ft.createElement(Vt.Z,{className:"font16 c-black"})),Ft.createElement("strong",{className:"font20 ml5"},ar.graduation_topic_name),Ft.createElement(qt.VV,{status:[ar.status_name]}))),Ft.createElement("aside",{className:"mt30 relative"},Ft.createElement("aside",{className:ni.rightMenu},Ft.createElement(Ht.Link,{className:ni.shixunDetail,to:`/classrooms/${Vi.coursesId}/graduation_topics/${Vi.categoryId}/edit`},Ft.createElement("span",{className:"iconfont icon-shixunxiangqing"}),"\u7F16\u8F91\u9009\u9898")),Ft.createElement(ke.default,{defaultActiveKey:ho,className:ni.menuTabs},Fo.map((nr,_e)=>Ft.createElement(ke.default.TabPane,{tab:nr.name,key:nr.id},nr.compontent))))))};var Ao=(0,Ht.connect)(({graduation:$n,loading:Kn,globalSetting:jn})=>({graduation:$n,globalSetting:jn,loading:Kn.effects}))(Io)},24768:function(Cn,cn,wt){"use strict";wt.d(cn,{AL:function(){return Pt},Iy:function(){return Fe},Qv:function(){return It},ez:function(){return mt},jb:function(){return ye}});var Ft=wt(32834),Ht=wt.n(Ft),oe=wt(11690),ke=wt.n(oe);let Vt=1;function qt(ie,Yt){const fe=ie.match(/^(\s+)(?:```)/);if(fe===null)return Yt;const Zt=fe[1];return Yt.split(` `).map(je=>{const me=je.match(/^\s+/);if(me===null)return je;const[Xe]=me;return Xe.length>=Zt.length?je.slice(Zt.length):je}).join(` `)}let Nt=[],Oe=["
    "];const be=new(Ht()).Renderer,Qt=/^ *(#{1,6}) *([^\n]+?) *(?:#+ *)?(?:\n+|$)/;function Fe(){Nt.length=0,Oe=["
      "]}const ye={overflow:"hidden",WebkitBoxOrient:"vertical",display:"-webkit-box",WebkitLineClamp:2};function Re(ie,Yt,fe,Zt){if(Yt>=ie.length||ie[Yt].level<=fe)return Yt;var je=ie[Yt];Zt.push("
    • "+je.text+""),Yt++;var me=[];return Yt=Re(ie,Yt,je.level,me),me.length>0&&(Zt.push("
        "),me.forEach(function(Xe){Zt.push(Xe)}),Zt.push("
      ")),Zt.push("
    • "),Yt=Re(ie,Yt,fe,Zt),Yt}function It(){return Re(Nt,0,0,Oe),Oe.push("
    "),Oe.join("")}const et={heading(ie){const Yt=Qt.exec(ie);if(Vt+=1,Yt)return{type:"heading",raw:Yt[0],depth:Yt[1].length,text:Yt[2]}},fences(ie){const Yt=this.rules.block.fences.exec(ie);if(Yt){const fe=Yt[0];let Zt=qt(fe,Yt[3]||"");const je=Yt[2]?Yt[2].trim():Yt[2];if(["latex","katex","math"].indexOf(je)>=0){const me=at(),Xe=Zt;Zt=me,gt[me]={type:"block",expression:Xe}}return{type:"code",raw:fe,lang:je,text:Zt}}}},nt=/(?:\${2})([^\n`]+?)(?:\${2})/gi;let dt=0;const at=()=>`__special_katext_id_${dt++}__`;let gt={};function mt(){return gt}function Pt(){dt=0,gt={}}function kt(ie){return ie=ie.replace(nt,(Yt,fe)=>{const Zt=at();return gt[Zt]={type:"inline",expression:fe},Zt}),ie}const Tt=be.listitem;be.listitem=function(ie){return Tt(kt(ie))};const Dt=be.paragraph;be.paragraph=function(ie){return Dt(kt(ie))};const $t=be.tablecell;be.tablecell=function(ie,Yt){return $t(kt(ie),Yt)},be.code=function(ie,Yt,fe){const Zt=(Yt||"").match(/\S*/)[0];return Zt?["latex","katex","math"].indexOf(Zt)>=0?`

    ${ie}

    `:`
    ${fe?ie:(0,oe.escape)(ie,!0)}
    `:'
    '+(fe?ie:(0,oe.escape)(ie,!0))+"
    "},be.heading=function(ie,Yt,fe){let Zt=this.options.headerPrefix+fe.toLowerCase().replace(/[^\w\\u4e00-\\u9fa5]]+/g,"-");return Nt.push({anchor:Zt,level:Yt,text:ie}),"'+ie+""},Ht().setOptions({silent:!0,gfm:!0,pedantic:!1}),Ht().use({tokenizer:et,renderer:be}),cn.ZP=Ht()},50371:function(Cn,cn){"use strict";function wt(){const Ft=Object.assign({},arguments.length<=0?void 0:arguments[0]);for(let Ht=1;Ht{const Vt=oe[ke];Vt!==void 0&&(Ft[ke]=Vt)})}return Ft}cn.Z=wt},13845:function(Cn,cn,wt){"use strict";wt.d(cn,{F:function(){return Ft},Z:function(){return Ht}});function Ft(oe){return oe!=null&&oe===oe.window}function Ht(oe,ke){var Vt,qt;if(typeof window=="undefined")return 0;const Nt=ke?"scrollTop":"scrollLeft";let Oe=0;return Ft(oe)?Oe=oe[ke?"pageYOffset":"pageXOffset"]:oe instanceof Document?Oe=oe.documentElement[Nt]:(oe instanceof HTMLElement||oe)&&(Oe=oe[Nt]),oe&&!Ft(oe)&&typeof Oe!="number"&&(Oe=(qt=((Vt=oe.ownerDocument)!==null&&Vt!==void 0?Vt:oe).documentElement)===null||qt===void 0?void 0:qt[Nt]),Oe}},56762:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Ht}});var Ft=wt(59301);function Ht(){const[,oe]=Ft.useReducer(ke=>ke+1,0);return oe}},68031:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return ke}});var Ft=wt(16089);function Ht(Vt,qt,Nt,Oe){const be=Nt-qt;return Vt/=Oe/2,Vt<1?be/2*Vt*Vt*Vt+qt:be/2*((Vt-=2)*Vt*Vt+2)+qt}var oe=wt(13845);function ke(Vt){let qt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{getContainer:Nt=()=>window,callback:Oe,duration:be=450}=qt,Qt=Nt(),Fe=(0,oe.Z)(Qt,!0),ye=Date.now(),Re=()=>{const et=Date.now()-ye,nt=Ht(et>be?be:et,Fe,Vt,be);(0,oe.F)(Qt)?Qt.scrollTo(window.pageXOffset,nt):Qt instanceof Document||Qt.constructor.name==="HTMLDocument"?Qt.documentElement.scrollTop=nt:Qt.scrollTop=nt,et{let{children:Ie}=Se;const{getPrefixCls:ze}=Vt.useContext(Nt.E_),Ue=ze("breadcrumb");return Vt.createElement("li",{className:`${Ue}-separator`,"aria-hidden":"true"},Ie===""?Ie:Ie||"/")};Qt.__ANT_BREADCRUMB_SEPARATOR=!0;var Fe=Qt,ye=function(Se,Ie){var ze={};for(var Ue in Se)Object.prototype.hasOwnProperty.call(Se,Ue)&&Ie.indexOf(Ue)<0&&(ze[Ue]=Se[Ue]);if(Se!=null&&typeof Object.getOwnPropertySymbols=="function")for(var se=0,Ue=Object.getOwnPropertySymbols(Se);seIe[se]||Ue)}function It(Se,Ie,ze,Ue){if(ze==null)return null;const{className:se,onClick:jt}=Ie,$e=ye(Ie,["className","onClick"]),xn=Object.assign(Object.assign({},(0,ke.Z)($e,{data:!0,aria:!0})),{onClick:jt});return Ue!==void 0?Vt.createElement("a",Object.assign({},xn,{className:Ht()(`${Se}-link`,se),href:Ue}),ze):Vt.createElement("span",Object.assign({},xn,{className:Ht()(`${Se}-link`,se)}),ze)}function et(Se,Ie){return(Ue,se,jt,$e,xn)=>{if(Ie)return Ie(Ue,se,jt,$e);const En=Re(Ue,se);return It(Se,Ue,En,xn)}}var nt=function(Se,Ie){var ze={};for(var Ue in Se)Object.prototype.hasOwnProperty.call(Se,Ue)&&Ie.indexOf(Ue)<0&&(ze[Ue]=Se[Ue]);if(Se!=null&&typeof Object.getOwnPropertySymbols=="function")for(var se=0,Ue=Object.getOwnPropertySymbols(Se);se{const{prefixCls:Ie,separator:ze="/",children:Ue,menu:se,overlay:jt,dropdownProps:$e,href:xn}=Se,Ne=(Ze=>{if(se||jt){const rn=Object.assign({},$e);if(se){const zn=se||{},{items:tn}=zn,Tn=nt(zn,["items"]);rn.menu=Object.assign(Object.assign({},Tn),{items:tn==null?void 0:tn.map((we,Bn)=>{var{key:Jn,title:Rt,label:Lt,path:St}=we,Et=nt(we,["key","title","label","path"]);let Bt=Lt!=null?Lt:Rt;return St&&(Bt=Vt.createElement("a",{href:`${xn}${St}`},Bt)),Object.assign(Object.assign({},Et),{key:Jn!=null?Jn:Bn,label:Bt})})})}else jt&&(rn.overlay=jt);return Vt.createElement(be.Z,Object.assign({placement:"bottom"},rn),Vt.createElement("span",{className:`${Ie}-overlay-link`},Ze,Vt.createElement(Oe.Z,null)))}return Ze})(Ue);return Ne!=null?Vt.createElement(Vt.Fragment,null,Vt.createElement("li",null,Ne),ze&&Vt.createElement(Fe,null,ze)):null},at=Se=>{const{prefixCls:Ie,children:ze,href:Ue}=Se,se=nt(Se,["prefixCls","children","href"]),{getPrefixCls:jt}=Vt.useContext(Nt.E_),$e=jt("breadcrumb",Ie);return Vt.createElement(dt,Object.assign({},se,{prefixCls:$e}),It($e,se,ze,Ue))};at.__ANT_BREADCRUMB_ITEM=!0;var gt=at,mt=wt(17313),Pt=wt(83116),kt=wt(37613);const Tt=Se=>{const{componentCls:Ie,iconCls:ze}=Se;return{[Ie]:Object.assign(Object.assign({},(0,mt.Wf)(Se)),{color:Se.itemColor,fontSize:Se.fontSize,[ze]:{fontSize:Se.iconFontSize},ol:{display:"flex",flexWrap:"wrap",margin:0,padding:0,listStyle:"none"},a:Object.assign({color:Se.linkColor,transition:`color ${Se.motionDurationMid}`,padding:`0 ${Se.paddingXXS}px`,borderRadius:Se.borderRadiusSM,height:Se.lineHeight*Se.fontSize,display:"inline-block",marginInline:-Se.marginXXS,"&:hover":{color:Se.linkHoverColor,backgroundColor:Se.colorBgTextHover}},(0,mt.Qy)(Se)),"li:last-child":{color:Se.lastItemColor},[`${Ie}-separator`]:{marginInline:Se.separatorMargin,color:Se.separatorColor},[`${Ie}-link`]:{[` > ${ze} + span, > ${ze} + a `]:{marginInlineStart:Se.marginXXS}},[`${Ie}-overlay-link`]:{borderRadius:Se.borderRadiusSM,height:Se.lineHeight*Se.fontSize,display:"inline-block",padding:`0 ${Se.paddingXXS}px`,marginInline:-Se.marginXXS,[`> ${ze}`]:{marginInlineStart:Se.marginXXS,fontSize:Se.fontSizeIcon},"&:hover":{color:Se.linkHoverColor,backgroundColor:Se.colorBgTextHover,a:{color:Se.linkHoverColor}},a:{"&:hover":{backgroundColor:"transparent"}}},[`&${Se.componentCls}-rtl`]:{direction:"rtl"}})}};var Dt=(0,Pt.Z)("Breadcrumb",Se=>{const Ie=(0,kt.TS)(Se,{});return[Tt(Ie)]},Se=>({itemColor:Se.colorTextDescription,lastItemColor:Se.colorText,iconFontSize:Se.fontSize,linkColor:Se.colorTextDescription,linkHoverColor:Se.colorText,separatorColor:Se.colorTextDescription,separatorMargin:Se.marginXS})),$t=function(Se,Ie){var ze={};for(var Ue in Se)Object.prototype.hasOwnProperty.call(Se,Ue)&&Ie.indexOf(Ue)<0&&(ze[Ue]=Se[Ue]);if(Se!=null&&typeof Object.getOwnPropertySymbols=="function")for(var se=0,Ue=Object.getOwnPropertySymbols(Se);se{var{breadcrumbName:$e}=jt,xn=$t(jt,["breadcrumbName"]);return Object.assign(Object.assign({},xn),{title:$e})})}),se}function Yt(Se,Ie){return(0,Vt.useMemo)(()=>Se||(Ie?Ie.map(ie):null),[Se,Ie])}var fe=function(Se,Ie){var ze={};for(var Ue in Se)Object.prototype.hasOwnProperty.call(Se,Ue)&&Ie.indexOf(Ue)<0&&(ze[Ue]=Se[Ue]);if(Se!=null&&typeof Object.getOwnPropertySymbols=="function")for(var se=0,Ue=Object.getOwnPropertySymbols(Se);se{if(Ie===void 0)return Ie;let ze=(Ie||"").replace(/^\//,"");return Object.keys(Se).forEach(Ue=>{ze=ze.replace(`:${Ue}`,Se[Ue])}),ze},je=Se=>{const{prefixCls:Ie,separator:ze="/",style:Ue,className:se,rootClassName:jt,routes:$e,items:xn,children:En,itemRender:Ne,params:Ze={}}=Se,rn=fe(Se,["prefixCls","separator","style","className","rootClassName","routes","items","children","itemRender","params"]),{getPrefixCls:zn,direction:tn,breadcrumb:Tn}=Vt.useContext(Nt.E_);let we;const Bn=zn("breadcrumb",Ie),[Jn,Rt]=Dt(Bn),Lt=Yt(xn,$e),St=et(Bn,Ne);if(Lt&&Lt.length>0){const yt=[],ae=xn||$e;we=Lt.map((Pe,ne)=>{const{path:_t,key:ge,type:pe,menu:le,overlay:Me,onClick:nn,className:qe,separator:Ge,dropdownProps:yn}=Pe,wn=Zt(Ze,_t);wn!==void 0&&yt.push(wn);const pn=ge!=null?ge:ne;if(pe==="separator")return Vt.createElement(Fe,{key:pn},Ge);const Yn={},ni=ne===Lt.length-1;le?Yn.menu=le:Me&&(Yn.overlay=Me);let{href:Un}=Pe;return yt.length&&wn!==void 0&&(Un=`#/${yt.join("/")}`),Vt.createElement(dt,Object.assign({key:pn},Yn,(0,ke.Z)(Pe,{data:!0,aria:!0}),{className:qe,dropdownProps:yn,href:Un,separator:ni?"":ze,onClick:nn,prefixCls:Bn}),St(Pe,Ze,ae,yt,Un))})}else if(En){const yt=(0,oe.Z)(En).length;we=(0,oe.Z)(En).map((ae,Pe)=>{if(!ae)return ae;const ne=Pe===yt-1;return(0,qt.Tm)(ae,{separator:ne?"":ze,key:Pe})})}const Et=Ht()(Bn,Tn==null?void 0:Tn.className,{[`${Bn}-rtl`]:tn==="rtl"},se,jt,Rt),Bt=Object.assign(Object.assign({},Tn==null?void 0:Tn.style),Ue);return Jn(Vt.createElement("nav",Object.assign({className:Et,style:Bt},rn),Vt.createElement("ol",null,we)))};je.Item=gt,je.Separator=Fe;var me=je,Xe=me},24905:function(Cn,cn,wt){"use strict";wt.d(cn,{default:function(){return Dt}});var Ft=wt(92310),Ht=wt.n(Ft),oe=wt(5630),ke=wt(59301),Vt=wt(36355),qt=wt(1684),Nt=wt(32441),be=ke.createContext(null),Qt=wt(98447),Fe=wt(14088),ye=wt(4572),Re=function($t,ie){var Yt={};for(var fe in $t)Object.prototype.hasOwnProperty.call($t,fe)&&ie.indexOf(fe)<0&&(Yt[fe]=$t[fe]);if($t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Zt=0,fe=Object.getOwnPropertySymbols($t);Zt{var Yt;const{prefixCls:fe,className:Zt,rootClassName:je,children:me,indeterminate:Xe=!1,style:Se,onMouseEnter:Ie,onMouseLeave:ze,skipGroup:Ue=!1,disabled:se}=$t,jt=Re($t,["prefixCls","className","rootClassName","children","indeterminate","style","onMouseEnter","onMouseLeave","skipGroup","disabled"]),{getPrefixCls:$e,direction:xn,checkbox:En}=ke.useContext(Vt.E_),Ne=ke.useContext(be),{isFormItemInput:Ze}=ke.useContext(Nt.aM),rn=ke.useContext(qt.Z),zn=(Yt=(Ne==null?void 0:Ne.disabled)||se)!==null&&Yt!==void 0?Yt:rn,tn=ke.useRef(jt.value);ke.useEffect(()=>{Ne==null||Ne.registerValue(jt.value)},[]),ke.useEffect(()=>{if(!Ue)return jt.value!==tn.current&&(Ne==null||Ne.cancelValue(tn.current),Ne==null||Ne.registerValue(jt.value),tn.current=jt.value),()=>Ne==null?void 0:Ne.cancelValue(jt.value)},[jt.value]);const Tn=$e("checkbox",fe),[we,Bn]=(0,Qt.ZP)(Tn),Jn=Object.assign({},jt);Ne&&!Ue&&(Jn.onChange=function(){jt.onChange&&jt.onChange.apply(jt,arguments),Ne.toggleOption&&Ne.toggleOption({label:me,value:jt.value})},Jn.name=Ne.name,Jn.checked=Ne.value.includes(jt.value));const Rt=Ht()(`${Tn}-wrapper`,{[`${Tn}-rtl`]:xn==="rtl",[`${Tn}-wrapper-checked`]:Jn.checked,[`${Tn}-wrapper-disabled`]:zn,[`${Tn}-wrapper-in-form-item`]:Ze},En==null?void 0:En.className,Zt,je,Bn),Lt=Ht()({[`${Tn}-indeterminate`]:Xe},ye.A,Bn),St=Xe?"mixed":void 0;return we(ke.createElement(Fe.Z,{component:"Checkbox",disabled:zn},ke.createElement("label",{className:Rt,style:Object.assign(Object.assign({},En==null?void 0:En.style),Se),onMouseEnter:Ie,onMouseLeave:ze},ke.createElement(oe.Z,Object.assign({"aria-checked":St},Jn,{prefixCls:Tn,className:Lt,disabled:zn,ref:ie})),me!==void 0&&ke.createElement("span",null,me))))};var nt=ke.forwardRef(It),dt=wt(19127),at=wt(2738),gt=function($t,ie){var Yt={};for(var fe in $t)Object.prototype.hasOwnProperty.call($t,fe)&&ie.indexOf(fe)<0&&(Yt[fe]=$t[fe]);if($t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Zt=0,fe=Object.getOwnPropertySymbols($t);Zt{const{defaultValue:Yt,children:fe,options:Zt=[],prefixCls:je,className:me,rootClassName:Xe,style:Se,onChange:Ie}=$t,ze=gt($t,["defaultValue","children","options","prefixCls","className","rootClassName","style","onChange"]),{getPrefixCls:Ue,direction:se}=ke.useContext(Vt.E_),[jt,$e]=ke.useState(ze.value||Yt||[]),[xn,En]=ke.useState([]);ke.useEffect(()=>{"value"in ze&&$e(ze.value||[])},[ze.value]);const Ne=ke.useMemo(()=>Zt.map(Et=>typeof Et=="string"||typeof Et=="number"?{label:Et,value:Et}:Et),[Zt]),Ze=Et=>{En(Bt=>Bt.filter(yt=>yt!==Et))},rn=Et=>{En(Bt=>[].concat((0,dt.Z)(Bt),[Et]))},zn=Et=>{const Bt=jt.indexOf(Et.value),yt=(0,dt.Z)(jt);Bt===-1?yt.push(Et.value):yt.splice(Bt,1),"value"in ze||$e(yt),Ie==null||Ie(yt.filter(ae=>xn.includes(ae)).sort((ae,Pe)=>{const ne=Ne.findIndex(ge=>ge.value===ae),_t=Ne.findIndex(ge=>ge.value===Pe);return ne-_t}))},tn=Ue("checkbox",je),Tn=`${tn}-group`,[we,Bn]=(0,Qt.ZP)(tn),Jn=(0,at.Z)(ze,["value","disabled"]),Rt=Zt.length?Ne.map(Et=>ke.createElement(nt,{prefixCls:tn,key:Et.value.toString(),disabled:"disabled"in Et?Et.disabled:ze.disabled,value:Et.value,checked:jt.includes(Et.value),onChange:Et.onChange,className:`${Tn}-item`,style:Et.style,title:Et.title},Et.label)):fe,Lt={toggleOption:zn,value:jt,disabled:ze.disabled,name:ze.name,registerValue:rn,cancelValue:Ze},St=Ht()(Tn,{[`${Tn}-rtl`]:se==="rtl"},me,Xe,Bn);return we(ke.createElement("div",Object.assign({className:St,style:Se},Jn,{ref:ie}),ke.createElement(be.Provider,{value:Lt},Rt)))},Pt=ke.forwardRef(mt);var kt=ke.memo(Pt);const Tt=nt;Tt.Group=kt,Tt.__ANT_CHECKBOX=!0;var Dt=Tt},98447:function(Cn,cn,wt){"use strict";wt.d(cn,{C2:function(){return Vt}});var Ft=wt(17313),Ht=wt(37613),oe=wt(83116);const ke=qt=>{const{checkboxCls:Nt}=qt,Oe=`${Nt}-wrapper`;return[{[`${Nt}-group`]:Object.assign(Object.assign({},(0,Ft.Wf)(qt)),{display:"inline-flex",flexWrap:"wrap",columnGap:qt.marginXS,[`> ${qt.antCls}-row`]:{flex:1}}),[Oe]:Object.assign(Object.assign({},(0,Ft.Wf)(qt)),{display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${Oe}`]:{marginInlineStart:0},[`&${Oe}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}}),[Nt]:Object.assign(Object.assign({},(0,Ft.Wf)(qt)),{position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",borderRadius:qt.borderRadiusSM,alignSelf:"center",[`${Nt}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0,margin:0,[`&:focus-visible + ${Nt}-inner`]:Object.assign({},(0,Ft.oN)(qt))},[`${Nt}-inner`]:{boxSizing:"border-box",position:"relative",top:0,insetInlineStart:0,display:"block",width:qt.checkboxSize,height:qt.checkboxSize,direction:"ltr",backgroundColor:qt.colorBgContainer,border:`${qt.lineWidth}px ${qt.lineType} ${qt.colorBorder}`,borderRadius:qt.borderRadiusSM,borderCollapse:"separate",transition:`all ${qt.motionDurationSlow}`,"&:after":{boxSizing:"border-box",position:"absolute",top:"50%",insetInlineStart:"21.5%",display:"table",width:qt.checkboxSize/14*5,height:qt.checkboxSize/14*8,border:`${qt.lineWidthBold}px solid ${qt.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${qt.motionDurationFast} ${qt.motionEaseInBack}, opacity ${qt.motionDurationFast}`}},"& + span":{paddingInlineStart:qt.paddingXS,paddingInlineEnd:qt.paddingXS}})},{[` ${Oe}:not(${Oe}-disabled), ${Nt}:not(${Nt}-disabled) `]:{[`&:hover ${Nt}-inner`]:{borderColor:qt.colorPrimary}},[`${Oe}:not(${Oe}-disabled)`]:{[`&:hover ${Nt}-checked:not(${Nt}-disabled) ${Nt}-inner`]:{backgroundColor:qt.colorPrimaryHover,borderColor:"transparent"},[`&:hover ${Nt}-checked:not(${Nt}-disabled):after`]:{borderColor:qt.colorPrimaryHover}}},{[`${Nt}-checked`]:{[`${Nt}-inner`]:{backgroundColor:qt.colorPrimary,borderColor:qt.colorPrimary,"&:after":{opacity:1,transform:"rotate(45deg) scale(1) translate(-50%,-50%)",transition:`all ${qt.motionDurationMid} ${qt.motionEaseOutBack} ${qt.motionDurationFast}`}}},[` ${Oe}-checked:not(${Oe}-disabled), ${Nt}-checked:not(${Nt}-disabled) `]:{[`&:hover ${Nt}-inner`]:{backgroundColor:qt.colorPrimaryHover,borderColor:"transparent"}}},{[Nt]:{"&-indeterminate":{[`${Nt}-inner`]:{backgroundColor:qt.colorBgContainer,borderColor:qt.colorBorder,"&:after":{top:"50%",insetInlineStart:"50%",width:qt.fontSizeLG/2,height:qt.fontSizeLG/2,backgroundColor:qt.colorPrimary,border:0,transform:"translate(-50%, -50%) scale(1)",opacity:1,content:'""'}}}}},{[`${Oe}-disabled`]:{cursor:"not-allowed"},[`${Nt}-disabled`]:{[`&, ${Nt}-input`]:{cursor:"not-allowed",pointerEvents:"none"},[`${Nt}-inner`]:{background:qt.colorBgContainerDisabled,borderColor:qt.colorBorder,"&:after":{borderColor:qt.colorTextDisabled}},"&:after":{display:"none"},"& + span":{color:qt.colorTextDisabled},[`&${Nt}-indeterminate ${Nt}-inner::after`]:{background:qt.colorTextDisabled}}}]};function Vt(qt,Nt){const Oe=(0,Ht.TS)(Nt,{checkboxCls:`.${qt}`,checkboxSize:Nt.controlInteractiveSize});return[ke(Oe)]}cn.ZP=(0,oe.Z)("Checkbox",(qt,Nt)=>{let{prefixCls:Oe}=Nt;return[Vt(Oe,qt)]})},93891:function(Cn,cn,wt){"use strict";var Ft=wt(59301),Ht=wt(36355),oe=wt(64165);const ke=Vt=>{const{componentName:qt}=Vt,{getPrefixCls:Nt}=(0,Ft.useContext)(Ht.E_),Oe=Nt("empty");switch(qt){case"Table":case"List":return Ft.createElement(oe.Z,{image:oe.Z.PRESENTED_IMAGE_SIMPLE});case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":return Ft.createElement(oe.Z,{image:oe.Z.PRESENTED_IMAGE_SIMPLE,className:`${Oe}-small`});default:return Ft.createElement(oe.Z,null)}};cn.Z=ke},91857:function(Cn,cn,wt){"use strict";var Ft=wt(59301),Ht=wt(38819),oe=wt(92310),ke=wt.n(oe),Vt=wt(31561),qt=wt(70425),Nt=wt(18929),Oe=wt(2738),be=wt(79676),Qt=wt(53487),Fe=wt(92343),ye=wt(36355),Re=wt(20834),It=wt(40875),et=wt(88088),nt=wt(47211);const dt=null,at=kt=>{const{menu:Tt,arrow:Dt,prefixCls:$t,children:ie,trigger:Yt,disabled:fe,dropdownRender:Zt,getPopupContainer:je,overlayClassName:me,rootClassName:Xe,open:Se,onOpenChange:Ie,visible:ze,onVisibleChange:Ue,mouseEnterDelay:se=.15,mouseLeaveDelay:jt=.1,autoAdjustOverflow:$e=!0,placement:xn="",overlay:En,transitionName:Ne}=kt,{getPopupContainer:Ze,getPrefixCls:rn,direction:zn}=Ft.useContext(ye.E_),tn=Ft.useMemo(()=>{const le=rn();return Ne!==void 0?Ne:xn.includes("top")?`${le}-slide-down`:`${le}-slide-up`},[rn,xn,Ne]),Tn=Ft.useMemo(()=>xn?xn.includes("Center")?xn.slice(0,xn.indexOf("Center")):xn:zn==="rtl"?"bottomRight":"bottomLeft",[xn,zn]),we=rn("dropdown",$t),[Bn,Jn]=(0,nt.Z)(we),[,Rt]=(0,et.Z)(),Lt=Ft.Children.only(ie),St=(0,Fe.Tm)(Lt,{className:ke()(`${we}-trigger`,{[`${we}-rtl`]:zn==="rtl"},Lt.props.className),disabled:fe}),Et=fe?[]:Yt;let Bt;Et&&Et.includes("contextMenu")&&(Bt=!0);const[yt,ae]=(0,Nt.Z)(!1,{value:Se!=null?Se:ze}),Pe=(0,qt.useEvent)(le=>{Ie==null||Ie(le),Ue==null||Ue(le),ae(le)}),ne=ke()(me,Xe,Jn,{[`${we}-rtl`]:zn==="rtl"}),_t=(0,be.Z)({arrowPointAtCenter:typeof Dt=="object"&&Dt.pointAtCenter,autoAdjustOverflow:$e,offset:Rt.marginXXS,arrowWidth:Dt?Rt.sizePopupArrow:0,borderRadius:Rt.borderRadius}),ge=Ft.useCallback(()=>{ae(!1)},[]),pe=()=>{let le;return Tt!=null&&Tt.items?le=Ft.createElement(Re.default,Object.assign({},Tt)):typeof En=="function"?le=En():le=En,Zt&&(le=Zt(le)),le=Ft.Children.only(typeof le=="string"?Ft.createElement("span",null,le):le),Ft.createElement(It.J,{prefixCls:`${we}-menu`,expandIcon:Ft.createElement("span",{className:`${we}-menu-submenu-arrow`},Ft.createElement(Ht.Z,{className:`${we}-menu-submenu-arrow-icon`})),mode:"vertical",selectable:!1,onClick:ge,validator:Me=>{let{mode:nn}=Me}},le)};return Bn(Ft.createElement(Vt.Z,Object.assign({alignPoint:Bt},(0,Oe.Z)(kt,["rootClassName"]),{mouseEnterDelay:se,mouseLeaveDelay:jt,visible:yt,builtinPlacements:_t,arrow:!!Dt,overlayClassName:ne,prefixCls:we,getPopupContainer:je||Ze,transitionName:tn,trigger:Et,overlay:pe,placement:Tn,onVisibleChange:Pe}),St))};function gt(kt){return Object.assign(Object.assign({},kt),{align:{overflow:{adjustX:!1,adjustY:!1}}})}const mt=(0,Qt.Z)(at,"dropdown",kt=>kt,gt),Pt=kt=>Ft.createElement(mt,Object.assign({},kt),Ft.createElement("span",null));at._InternalPanelDoNotUseOrYouWillBeFired=Pt,cn.Z=at},38854:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return et}});var Ft=wt(91857),Ht=wt(92310),oe=wt.n(Ht),ke=wt(59301),Vt=wt(18785),qt=wt(3113),Nt=wt(36355),Oe=wt(81327),be=wt(33234),Qt=wt(47211),Fe=function(nt,dt){var at={};for(var gt in nt)Object.prototype.hasOwnProperty.call(nt,gt)&&dt.indexOf(gt)<0&&(at[gt]=nt[gt]);if(nt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var mt=0,gt=Object.getOwnPropertySymbols(nt);mt{const{getPopupContainer:dt,getPrefixCls:at,direction:gt}=ke.useContext(Nt.E_),{prefixCls:mt,type:Pt="default",danger:kt,disabled:Tt,loading:Dt,onClick:$t,htmlType:ie,children:Yt,className:fe,menu:Zt,arrow:je,autoFocus:me,overlay:Xe,trigger:Se,align:Ie,open:ze,onOpenChange:Ue,placement:se,getPopupContainer:jt,href:$e,icon:xn=ke.createElement(Vt.Z,null),title:En,buttonsRender:Ne=pe=>pe,mouseEnterDelay:Ze,mouseLeaveDelay:rn,overlayClassName:zn,overlayStyle:tn,destroyPopupOnHide:Tn,dropdownRender:we}=nt,Bn=Fe(nt,["prefixCls","type","danger","disabled","loading","onClick","htmlType","children","className","menu","arrow","autoFocus","overlay","trigger","align","open","onOpenChange","placement","getPopupContainer","href","icon","title","buttonsRender","mouseEnterDelay","mouseLeaveDelay","overlayClassName","overlayStyle","destroyPopupOnHide","dropdownRender"]),Jn=at("dropdown",mt),Rt=`${Jn}-button`,[Lt,St]=(0,Qt.Z)(Jn),Et={menu:Zt,arrow:je,autoFocus:me,align:Ie,disabled:Tt,trigger:Tt?[]:Se,onOpenChange:Ue,getPopupContainer:jt||dt,mouseEnterDelay:Ze,mouseLeaveDelay:rn,overlayClassName:zn,overlayStyle:tn,destroyPopupOnHide:Tn,dropdownRender:we},{compactSize:Bt,compactItemClassnames:yt}=(0,be.ri)(Jn,gt),ae=oe()(Rt,yt,fe,St);"overlay"in nt&&(Et.overlay=Xe),"open"in nt&&(Et.open=ze),"placement"in nt?Et.placement=se:Et.placement=gt==="rtl"?"bottomLeft":"bottomRight";const Pe=ke.createElement(qt.ZP,{type:Pt,danger:kt,disabled:Tt,loading:Dt,onClick:$t,htmlType:ie,href:$e,title:En},Yt),ne=ke.createElement(qt.ZP,{type:Pt,danger:kt,icon:xn}),[_t,ge]=Ne([Pe,ne]);return Lt(ke.createElement(Oe.Z.Compact,Object.assign({className:ae,size:Bt,block:!0},Bn),_t,ke.createElement(Ft.Z,Object.assign({},Et),ge)))};ye.__ANT_BUTTON=!0;var Re=ye;const It=Ft.Z;It.Button=Re;var et=It},47211:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Fe}});var Ft=wt(17313),Ht=wt(13826),oe=wt(92899),ke=wt(29878),Vt=wt(19447),qt=wt(83116),Nt=wt(37613),be=ye=>{const{componentCls:Re,menuCls:It,colorError:et,colorTextLightSolid:nt}=ye,dt=`${It}-item`;return{[`${Re}, ${Re}-menu-submenu`]:{[`${It} ${dt}`]:{[`&${dt}-danger:not(${dt}-disabled)`]:{color:et,"&:hover":{color:nt,backgroundColor:et}}}}}};const Qt=ye=>{const{componentCls:Re,menuCls:It,zIndexPopup:et,dropdownArrowDistance:nt,sizePopupArrow:dt,antCls:at,iconCls:gt,motionDurationMid:mt,dropdownPaddingVertical:Pt,fontSize:kt,dropdownEdgeChildPadding:Tt,colorTextDisabled:Dt,fontSizeIcon:$t,controlPaddingHorizontal:ie,colorBgElevated:Yt}=ye;return[{[Re]:Object.assign(Object.assign({},(0,Ft.Wf)(ye)),{position:"absolute",top:-9999,left:{_skip_check_:!0,value:-9999},zIndex:et,display:"block","&::before":{position:"absolute",insetBlock:-nt+dt/2,zIndex:-9999,opacity:1e-4,content:'""'},[`&-trigger${at}-btn`]:{[`& > ${gt}-down, & > ${at}-btn-icon > ${gt}-down`]:{fontSize:$t}},[`${Re}-wrap`]:{position:"relative",[`${at}-btn > ${gt}-down`]:{fontSize:$t},[`${gt}-down::before`]:{transition:`transform ${mt}`}},[`${Re}-wrap-open`]:{[`${gt}-down::before`]:{transform:"rotate(180deg)"}},"\n &-hidden,\n &-menu-hidden,\n &-menu-submenu-hidden\n ":{display:"none"},[`&${at}-slide-down-enter${at}-slide-down-enter-active${Re}-placement-bottomLeft, &${at}-slide-down-appear${at}-slide-down-appear-active${Re}-placement-bottomLeft, &${at}-slide-down-enter${at}-slide-down-enter-active${Re}-placement-bottom, &${at}-slide-down-appear${at}-slide-down-appear-active${Re}-placement-bottom, &${at}-slide-down-enter${at}-slide-down-enter-active${Re}-placement-bottomRight, &${at}-slide-down-appear${at}-slide-down-appear-active${Re}-placement-bottomRight`]:{animationName:Ht.fJ},[`&${at}-slide-up-enter${at}-slide-up-enter-active${Re}-placement-topLeft, &${at}-slide-up-appear${at}-slide-up-appear-active${Re}-placement-topLeft, &${at}-slide-up-enter${at}-slide-up-enter-active${Re}-placement-top, &${at}-slide-up-appear${at}-slide-up-appear-active${Re}-placement-top, &${at}-slide-up-enter${at}-slide-up-enter-active${Re}-placement-topRight, &${at}-slide-up-appear${at}-slide-up-appear-active${Re}-placement-topRight`]:{animationName:Ht.Qt},[`&${at}-slide-down-leave${at}-slide-down-leave-active${Re}-placement-bottomLeft, &${at}-slide-down-leave${at}-slide-down-leave-active${Re}-placement-bottom, &${at}-slide-down-leave${at}-slide-down-leave-active${Re}-placement-bottomRight`]:{animationName:Ht.Uw},[`&${at}-slide-up-leave${at}-slide-up-leave-active${Re}-placement-topLeft, &${at}-slide-up-leave${at}-slide-up-leave-active${Re}-placement-top, &${at}-slide-up-leave${at}-slide-up-leave-active${Re}-placement-topRight`]:{animationName:Ht.ly}})},(0,Vt.ZP)(ye,{colorBg:Yt,limitVerticalRadius:!0,arrowPlacement:{top:!0,bottom:!0}}),{[`${Re} ${It}`]:{position:"relative",margin:0},[`${It}-submenu-popup`]:{position:"absolute",zIndex:et,background:"transparent",boxShadow:"none",transformOrigin:"0 0","ul, li":{listStyle:"none",margin:0}},[`${Re}, ${Re}-menu-submenu`]:{[It]:Object.assign(Object.assign({padding:Tt,listStyleType:"none",backgroundColor:Yt,backgroundClip:"padding-box",borderRadius:ye.borderRadiusLG,outline:"none",boxShadow:ye.boxShadowSecondary},(0,Ft.Qy)(ye)),{[`${It}-item-group-title`]:{padding:`${Pt}px ${ie}px`,color:ye.colorTextDescription,transition:`all ${mt}`},[`${It}-item`]:{position:"relative",display:"flex",alignItems:"center"},[`${It}-item-icon`]:{minWidth:kt,marginInlineEnd:ye.marginXS,fontSize:ye.fontSizeSM},[`${It}-title-content`]:{flex:"auto","> a":{color:"inherit",transition:`all ${mt}`,"&:hover":{color:"inherit"},"&::after":{position:"absolute",inset:0,content:'""'}}},[`${It}-item, ${It}-submenu-title`]:Object.assign(Object.assign({clear:"both",margin:0,padding:`${Pt}px ${ie}px`,color:ye.colorText,fontWeight:"normal",fontSize:kt,lineHeight:ye.lineHeight,cursor:"pointer",transition:`all ${mt}`,borderRadius:ye.borderRadiusSM,"&:hover, &-active":{backgroundColor:ye.controlItemBgHover}},(0,Ft.Qy)(ye)),{"&-selected":{color:ye.colorPrimary,backgroundColor:ye.controlItemBgActive,"&:hover, &-active":{backgroundColor:ye.controlItemBgActiveHover}},"&-disabled":{color:Dt,cursor:"not-allowed","&:hover":{color:Dt,backgroundColor:Yt,cursor:"not-allowed"},a:{pointerEvents:"none"}},"&-divider":{height:1,margin:`${ye.marginXXS}px 0`,overflow:"hidden",lineHeight:0,backgroundColor:ye.colorSplit},[`${Re}-menu-submenu-expand-icon`]:{position:"absolute",insetInlineEnd:ye.paddingXS,[`${Re}-menu-submenu-arrow-icon`]:{marginInlineEnd:"0 !important",color:ye.colorTextDescription,fontSize:$t,fontStyle:"normal"}}}),[`${It}-item-group-list`]:{margin:`0 ${ye.marginXS}px`,padding:0,listStyle:"none"},[`${It}-submenu-title`]:{paddingInlineEnd:ie+ye.fontSizeSM},[`${It}-submenu-vertical`]:{position:"relative"},[`${It}-submenu${It}-submenu-disabled ${Re}-menu-submenu-title`]:{[`&, ${Re}-menu-submenu-arrow-icon`]:{color:Dt,backgroundColor:Yt,cursor:"not-allowed"}},[`${It}-submenu-selected ${Re}-menu-submenu-title`]:{color:ye.colorPrimary}})}},[(0,Ht.oN)(ye,"slide-up"),(0,Ht.oN)(ye,"slide-down"),(0,oe.Fm)(ye,"move-up"),(0,oe.Fm)(ye,"move-down"),(0,ke._y)(ye,"zoom-big")]]};var Fe=(0,qt.Z)("Dropdown",(ye,Re)=>{let{rootPrefixCls:It}=Re;const{marginXXS:et,sizePopupArrow:nt,controlHeight:dt,fontSize:at,lineHeight:gt,paddingXXS:mt,componentCls:Pt,borderRadiusLG:kt}=ye,Tt=(dt-at*gt)/2,{dropdownArrowOffset:Dt}=(0,Vt.fS)({contentRadius:kt}),$t=(0,Nt.TS)(ye,{menuCls:`${Pt}-menu`,rootPrefixCls:It,dropdownArrowDistance:nt/2+et,dropdownArrowOffset:Dt,dropdownPaddingVertical:Tt,dropdownEdgeChildPadding:mt});return[Qt($t),be($t)]},ye=>({zIndexPopup:ye.zIndexPopupBase+50}))},64165:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return mt}});var Ft=wt(92310),Ht=wt.n(Ft),oe=wt(59301),ke=wt(36355),Vt=wt(9763),qt=wt(64993),Nt=wt(88088),be=()=>{const[,Pt]=(0,Nt.Z)(),Tt=new qt.C(Pt.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return oe.createElement("svg",{style:Tt,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},oe.createElement("g",{fill:"none",fillRule:"evenodd"},oe.createElement("g",{transform:"translate(24 31.67)"},oe.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.797",cy:"106.89",rx:"67.797",ry:"12.668"}),oe.createElement("path",{d:"M122.034 69.674L98.109 40.229c-1.148-1.386-2.826-2.225-4.593-2.225h-51.44c-1.766 0-3.444.839-4.592 2.225L13.56 69.674v15.383h108.475V69.674z",fill:"#AEB8C2"}),oe.createElement("path",{d:"M101.537 86.214L80.63 61.102c-1.001-1.207-2.507-1.867-4.048-1.867H31.724c-1.54 0-3.047.66-4.048 1.867L6.769 86.214v13.792h94.768V86.214z",fill:"url(#linearGradient-1)",transform:"translate(13.56)"}),oe.createElement("path",{d:"M33.83 0h67.933a4 4 0 0 1 4 4v93.344a4 4 0 0 1-4 4H33.83a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4z",fill:"#F5F5F7"}),oe.createElement("path",{d:"M42.678 9.953h50.237a2 2 0 0 1 2 2V36.91a2 2 0 0 1-2 2H42.678a2 2 0 0 1-2-2V11.953a2 2 0 0 1 2-2zM42.94 49.767h49.713a2.262 2.262 0 1 1 0 4.524H42.94a2.262 2.262 0 0 1 0-4.524zM42.94 61.53h49.713a2.262 2.262 0 1 1 0 4.525H42.94a2.262 2.262 0 0 1 0-4.525zM121.813 105.032c-.775 3.071-3.497 5.36-6.735 5.36H20.515c-3.238 0-5.96-2.29-6.734-5.36a7.309 7.309 0 0 1-.222-1.79V69.675h26.318c2.907 0 5.25 2.448 5.25 5.42v.04c0 2.971 2.37 5.37 5.277 5.37h34.785c2.907 0 5.277-2.421 5.277-5.393V75.1c0-2.972 2.343-5.426 5.25-5.426h26.318v33.569c0 .617-.077 1.216-.221 1.789z",fill:"#DCE0E6"})),oe.createElement("path",{d:"M149.121 33.292l-6.83 2.65a1 1 0 0 1-1.317-1.23l1.937-6.207c-2.589-2.944-4.109-6.534-4.109-10.408C138.802 8.102 148.92 0 161.402 0 173.881 0 184 8.102 184 18.097c0 9.995-10.118 18.097-22.599 18.097-4.528 0-8.744-1.066-12.28-2.902z",fill:"#DCE0E6"}),oe.createElement("g",{transform:"translate(149.65 15.383)",fill:"#FFF"},oe.createElement("ellipse",{cx:"20.654",cy:"3.167",rx:"2.849",ry:"2.815"}),oe.createElement("path",{d:"M5.698 5.63H0L2.898.704zM9.259.704h4.985V5.63H9.259z"}))))},Fe=()=>{const[,Pt]=(0,Nt.Z)(),{colorFill:kt,colorFillTertiary:Tt,colorFillQuaternary:Dt,colorBgContainer:$t}=Pt,{borderColor:ie,shadowColor:Yt,contentColor:fe}=(0,oe.useMemo)(()=>({borderColor:new qt.C(kt).onBackground($t).toHexShortString(),shadowColor:new qt.C(Tt).onBackground($t).toHexShortString(),contentColor:new qt.C(Dt).onBackground($t).toHexShortString()}),[kt,Tt,Dt,$t]);return oe.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},oe.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},oe.createElement("ellipse",{fill:Yt,cx:"32",cy:"33",rx:"32",ry:"7"}),oe.createElement("g",{fillRule:"nonzero",stroke:ie},oe.createElement("path",{d:"M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z"}),oe.createElement("path",{d:"M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z",fill:fe}))))},ye=wt(83116),Re=wt(37613);const It=Pt=>{const{componentCls:kt,margin:Tt,marginXS:Dt,marginXL:$t,fontSize:ie,lineHeight:Yt}=Pt;return{[kt]:{marginInline:Dt,fontSize:ie,lineHeight:Yt,textAlign:"center",[`${kt}-image`]:{height:Pt.emptyImgHeight,marginBottom:Dt,opacity:Pt.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},[`${kt}-description`]:{color:Pt.colorText},[`${kt}-footer`]:{marginTop:Tt},"&-normal":{marginBlock:$t,color:Pt.colorTextDisabled,[`${kt}-description`]:{color:Pt.colorTextDisabled},[`${kt}-image`]:{height:Pt.emptyImgHeightMD}},"&-small":{marginBlock:Dt,color:Pt.colorTextDisabled,[`${kt}-image`]:{height:Pt.emptyImgHeightSM}}}}};var et=(0,ye.Z)("Empty",Pt=>{const{componentCls:kt,controlHeightLG:Tt}=Pt,Dt=(0,Re.TS)(Pt,{emptyImgCls:`${kt}-img`,emptyImgHeight:Tt*2.5,emptyImgHeightMD:Tt,emptyImgHeightSM:Tt*.875});return[It(Dt)]}),nt=function(Pt,kt){var Tt={};for(var Dt in Pt)Object.prototype.hasOwnProperty.call(Pt,Dt)&&kt.indexOf(Dt)<0&&(Tt[Dt]=Pt[Dt]);if(Pt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var $t=0,Dt=Object.getOwnPropertySymbols(Pt);$t{var{className:kt,rootClassName:Tt,prefixCls:Dt,image:$t=dt,description:ie,children:Yt,imageStyle:fe,style:Zt}=Pt,je=nt(Pt,["className","rootClassName","prefixCls","image","description","children","imageStyle","style"]);const{getPrefixCls:me,direction:Xe,empty:Se}=oe.useContext(ke.E_),Ie=me("empty",Dt),[ze,Ue]=et(Ie),[se]=(0,Vt.Z)("Empty"),jt=typeof ie!="undefined"?ie:se==null?void 0:se.description,$e=typeof jt=="string"?jt:"empty";let xn=null;return typeof $t=="string"?xn=oe.createElement("img",{alt:$e,src:$t}):xn=$t,ze(oe.createElement("div",Object.assign({className:Ht()(Ue,Ie,Se==null?void 0:Se.className,{[`${Ie}-normal`]:$t===at,[`${Ie}-rtl`]:Xe==="rtl"},kt,Tt),style:Object.assign(Object.assign({},Se==null?void 0:Se.style),Zt)},je),oe.createElement("div",{className:`${Ie}-image`,style:fe},xn),jt&&oe.createElement("div",{className:`${Ie}-description`},jt),Yt&&oe.createElement("div",{className:`${Ie}-footer`},Yt)))};gt.PRESENTED_IMAGE_DEFAULT=dt,gt.PRESENTED_IMAGE_SIMPLE=at;var mt=gt},78241:function(Cn,cn,wt){"use strict";wt.d(cn,{default:function(){return We}});var Ft=wt(19127),Ht=wt(92310),oe=wt.n(Ht),ke=wt(77900),Vt=wt(59301),qt=wt(62892),Nt=wt(32441);function Oe(Jt){const[on,Mn]=Vt.useState(Jt);return Vt.useEffect(()=>{const Le=setTimeout(()=>{Mn(Jt)},Jt.length?0:10);return()=>{clearTimeout(Le)}},[Jt]),on}var be=wt(17313),Qt=wt(29878),Fe=wt(8378),ye=wt(37613),Re=wt(83116),et=Jt=>{const{componentCls:on}=Jt,Mn=`${on}-show-help`,Le=`${on}-show-help-item`;return{[Mn]:{transition:`opacity ${Jt.motionDurationSlow} ${Jt.motionEaseInOut}`,"&-appear, &-enter":{opacity:0,"&-active":{opacity:1}},"&-leave":{opacity:1,"&-active":{opacity:0}},[Le]:{overflow:"hidden",transition:`height ${Jt.motionDurationSlow} ${Jt.motionEaseInOut}, opacity ${Jt.motionDurationSlow} ${Jt.motionEaseInOut}, transform ${Jt.motionDurationSlow} ${Jt.motionEaseInOut} !important`,[`&${Le}-appear, &${Le}-enter`]:{transform:"translateY(-5px)",opacity:0,"&-active":{transform:"translateY(0)",opacity:1}},[`&${Le}-leave-active`]:{transform:"translateY(-5px)"}}}}};const nt=Jt=>({legend:{display:"block",width:"100%",marginBottom:Jt.marginLG,padding:0,color:Jt.colorTextDescription,fontSize:Jt.fontSizeLG,lineHeight:"inherit",border:0,borderBottom:`${Jt.lineWidth}px ${Jt.lineType} ${Jt.colorBorder}`},label:{fontSize:Jt.fontSize},'input[type="search"]':{boxSizing:"border-box"},'input[type="radio"], input[type="checkbox"]':{lineHeight:"normal"},'input[type="file"]':{display:"block"},'input[type="range"]':{display:"block",width:"100%"},"select[multiple], select[size]":{height:"auto"},"input[type='file']:focus,\n input[type='radio']:focus,\n input[type='checkbox']:focus":{outline:0,boxShadow:`0 0 0 ${Jt.controlOutlineWidth}px ${Jt.controlOutline}`},output:{display:"block",paddingTop:15,color:Jt.colorText,fontSize:Jt.fontSize,lineHeight:Jt.lineHeight}}),dt=(Jt,on)=>{const{formItemCls:Mn}=Jt;return{[Mn]:{[`${Mn}-label > label`]:{height:on},[`${Mn}-control-input`]:{minHeight:on}}}},at=Jt=>{const{componentCls:on}=Jt;return{[Jt.componentCls]:Object.assign(Object.assign(Object.assign({},(0,be.Wf)(Jt)),nt(Jt)),{[`${on}-text`]:{display:"inline-block",paddingInlineEnd:Jt.paddingSM},"&-small":Object.assign({},dt(Jt,Jt.controlHeightSM)),"&-large":Object.assign({},dt(Jt,Jt.controlHeightLG))})}},gt=Jt=>{const{formItemCls:on,iconCls:Mn,componentCls:Le,rootPrefixCls:ue,labelRequiredMarkColor:Je,labelColor:gn,labelFontSize:Xn,labelHeight:Gn,labelColonMarginInlineStart:ce,labelColonMarginInlineEnd:vn,itemMarginBottom:An}=Jt;return{[on]:Object.assign(Object.assign({},(0,be.Wf)(Jt)),{marginBottom:An,verticalAlign:"top","&-with-help":{transition:"none"},[`&-hidden, &-hidden.${ue}-row`]:{display:"none"},"&-has-warning":{[`${on}-split`]:{color:Jt.colorError}},"&-has-error":{[`${on}-split`]:{color:Jt.colorWarning}},[`${on}-label`]:{flexGrow:0,overflow:"hidden",whiteSpace:"nowrap",textAlign:"end",verticalAlign:"middle","&-left":{textAlign:"start"},"&-wrap":{overflow:"unset",lineHeight:`${Jt.lineHeight} - 0.25em`,whiteSpace:"unset"},"> label":{position:"relative",display:"inline-flex",alignItems:"center",maxWidth:"100%",height:Gn,color:gn,fontSize:Xn,[`> ${Mn}`]:{fontSize:Jt.fontSize,verticalAlign:"top"},[`&${on}-required:not(${on}-required-mark-optional)::before`]:{display:"inline-block",marginInlineEnd:Jt.marginXXS,color:Je,fontSize:Jt.fontSize,fontFamily:"SimSun, sans-serif",lineHeight:1,content:'"*"',[`${Le}-hide-required-mark &`]:{display:"none"}},[`${on}-optional`]:{display:"inline-block",marginInlineStart:Jt.marginXXS,color:Jt.colorTextDescription,[`${Le}-hide-required-mark &`]:{display:"none"}},[`${on}-tooltip`]:{color:Jt.colorTextDescription,cursor:"help",writingMode:"horizontal-tb",marginInlineStart:Jt.marginXXS},"&::after":{content:'":"',position:"relative",marginBlock:0,marginInlineStart:ce,marginInlineEnd:vn},[`&${on}-no-colon::after`]:{content:'"\\a0"'}}},[`${on}-control`]:{"--ant-display":"flex",flexDirection:"column",flexGrow:1,[`&:first-child:not([class^="'${ue}-col-'"]):not([class*="' ${ue}-col-'"])`]:{width:"100%"},"&-input":{position:"relative",display:"flex",alignItems:"center",minHeight:Jt.controlHeight,"&-content":{flex:"auto",maxWidth:"100%"}}},[on]:{"&-explain, &-extra":{clear:"both",color:Jt.colorTextDescription,fontSize:Jt.fontSize,lineHeight:Jt.lineHeight},"&-explain-connected":{width:"100%"},"&-extra":{minHeight:Jt.controlHeightSM,transition:`color ${Jt.motionDurationMid} ${Jt.motionEaseOut}`},"&-explain":{"&-error":{color:Jt.colorError},"&-warning":{color:Jt.colorWarning}}},[`&-with-help ${on}-explain`]:{height:"auto",opacity:1},[`${on}-feedback-icon`]:{fontSize:Jt.fontSize,textAlign:"center",visibility:"visible",animationName:Qt.kr,animationDuration:Jt.motionDurationMid,animationTimingFunction:Jt.motionEaseOutBack,pointerEvents:"none","&-success":{color:Jt.colorSuccess},"&-error":{color:Jt.colorError},"&-warning":{color:Jt.colorWarning},"&-validating":{color:Jt.colorPrimary}}})}},mt=Jt=>{const{componentCls:on,formItemCls:Mn}=Jt;return{[`${on}-horizontal`]:{[`${Mn}-label`]:{flexGrow:0},[`${Mn}-control`]:{flex:"1 1 0",minWidth:0},[`${Mn}-label[class$='-24'], ${Mn}-label[class*='-24 ']`]:{[`& + ${Mn}-control`]:{minWidth:"unset"}}}}},Pt=Jt=>{const{componentCls:on,formItemCls:Mn}=Jt;return{[`${on}-inline`]:{display:"flex",flexWrap:"wrap",[Mn]:{flex:"none",marginInlineEnd:Jt.margin,marginBottom:0,"&-row":{flexWrap:"nowrap"},[`> ${Mn}-label, > ${Mn}-control`]:{display:"inline-block",verticalAlign:"top"},[`> ${Mn}-label`]:{flex:"none"},[`${on}-text`]:{display:"inline-block"},[`${Mn}-has-feedback`]:{display:"inline-block"}}}}},kt=Jt=>({padding:Jt.verticalLabelPadding,margin:Jt.verticalLabelMargin,whiteSpace:"initial",textAlign:"start","> label":{margin:0,"&::after":{visibility:"hidden"}}}),Tt=Jt=>{const{componentCls:on,formItemCls:Mn,rootPrefixCls:Le}=Jt;return{[`${Mn} ${Mn}-label`]:kt(Jt),[on]:{[Mn]:{flexWrap:"wrap",[`${Mn}-label, ${Mn}-control`]:{[`&:not([class*=" ${Le}-col-xs"])`]:{flex:"0 0 100%",maxWidth:"100%"}}}}}},Dt=Jt=>{const{componentCls:on,formItemCls:Mn,rootPrefixCls:Le}=Jt;return{[`${on}-vertical`]:{[Mn]:{"&-row":{flexDirection:"column"},"&-label > label":{height:"auto"},[`${on}-item-control`]:{width:"100%"}}},[`${on}-vertical ${Mn}-label, .${Le}-col-24${Mn}-label, .${Le}-col-xl-24${Mn}-label`]:kt(Jt),[`@media (max-width: ${Jt.screenXSMax}px)`]:[Tt(Jt),{[on]:{[`.${Le}-col-xs-24${Mn}-label`]:kt(Jt)}}],[`@media (max-width: ${Jt.screenSMMax}px)`]:{[on]:{[`.${Le}-col-sm-24${Mn}-label`]:kt(Jt)}},[`@media (max-width: ${Jt.screenMDMax}px)`]:{[on]:{[`.${Le}-col-md-24${Mn}-label`]:kt(Jt)}},[`@media (max-width: ${Jt.screenLGMax}px)`]:{[on]:{[`.${Le}-col-lg-24${Mn}-label`]:kt(Jt)}}}},$t=(Jt,on)=>(0,ye.TS)(Jt,{formItemCls:`${Jt.componentCls}-item`,rootPrefixCls:on});var ie=(0,Re.Z)("Form",(Jt,on)=>{let{rootPrefixCls:Mn}=on;const Le=$t(Jt,Mn);return[at(Le),gt(Le),et(Le),mt(Le),Pt(Le),Dt(Le),(0,Fe.Z)(Le),Qt.kr]},Jt=>({labelRequiredMarkColor:Jt.colorError,labelColor:Jt.colorTextHeading,labelFontSize:Jt.fontSize,labelHeight:Jt.controlHeight,labelColonMarginInlineStart:Jt.marginXXS/2,labelColonMarginInlineEnd:Jt.marginXS,itemMarginBottom:Jt.marginLG,verticalLabelPadding:`0 0 ${Jt.paddingXS}px`,verticalLabelMargin:0}),{order:-1e3});const Yt=[];function fe(Jt,on,Mn){let Le=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0;return{key:typeof Jt=="string"?Jt:`${on}-${Le}`,error:Jt,errorStatus:Mn}}var je=Jt=>{let{help:on,helpStatus:Mn,errors:Le=Yt,warnings:ue=Yt,className:Je,fieldId:gn,onVisibleChanged:Xn}=Jt;const{prefixCls:Gn}=Vt.useContext(Nt.Rk),ce=`${Gn}-item-explain`,[,vn]=ie(Gn),An=(0,Vt.useMemo)(()=>(0,qt.Z)(Gn),[Gn]),xi=Oe(Le),Ae=Oe(ue),en=Vt.useMemo(()=>on!=null?[fe(on,"help",Mn)]:[].concat((0,Ft.Z)(xi.map((oi,Si)=>fe(oi,"error","error",Si))),(0,Ft.Z)(Ae.map((oi,Si)=>fe(oi,"warning","warning",Si)))),[on,Mn,xi,Ae]),ui={};return gn&&(ui.id=`${gn}_help`),Vt.createElement(ke.default,{motionDeadline:An.motionDeadline,motionName:`${Gn}-show-help`,visible:!!en.length,onVisibleChanged:Xn},oi=>{const{className:Si,style:Zn}=oi;return Vt.createElement("div",Object.assign({},ui,{className:oe()(ce,Si,Je,vn),style:Zn,role:"alert"}),Vt.createElement(ke.CSSMotionList,Object.assign({keys:en},(0,qt.Z)(Gn),{motionName:`${Gn}-show-help-item`,component:!1}),hi=>{const{key:Qn,error:Ci,errorStatus:so,className:wo,style:sn}=hi;return Vt.createElement("div",{key:Qn,className:oe()(wo,{[`${ce}-${so}`]:so}),style:sn},Ci)}))})},me=wt(95013),Xe=wt(36355),Se=wt(1684),Ie=wt(52946),ze=wt(19716),Ue=wt(16722);const se=["parentNode"],jt="form_item";function $e(Jt){return Jt===void 0||Jt===!1?[]:Array.isArray(Jt)?Jt:[Jt]}function xn(Jt,on){if(!Jt.length)return;const Mn=Jt.join("_");return on?`${on}_${Mn}`:se.includes(Mn)?`${jt}_${Mn}`:Mn}function En(Jt,on,Mn,Le,ue,Je){let gn=Le;return Je!==void 0?gn=Je:Mn.validating?gn="validating":Jt.length?gn="error":on.length?gn="warning":(Mn.touched||ue&&Mn.validated)&&(gn="success"),gn}function Ne(Jt){return $e(Jt).join("_")}function Ze(Jt){const[on]=(0,me.useForm)(),Mn=Vt.useRef({}),Le=Vt.useMemo(()=>Jt!=null?Jt:Object.assign(Object.assign({},on),{__INTERNAL__:{itemRef:ue=>Je=>{const gn=Ne(ue);Je?Mn.current[gn]=Je:delete Mn.current[gn]}},scrollToField:function(ue){let Je=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const gn=$e(ue),Xn=xn(gn,Le.__INTERNAL__.name),Gn=Xn?document.getElementById(Xn):null;Gn&&(0,Ue.Z)(Gn,Object.assign({scrollMode:"if-needed",block:"nearest"},Je))},getFieldInstance:ue=>{const Je=Ne(ue);return Mn.current[Je]}}),[Jt,on]);return[Le]}var rn=wt(28726),zn=function(Jt,on){var Mn={};for(var Le in Jt)Object.prototype.hasOwnProperty.call(Jt,Le)&&on.indexOf(Le)<0&&(Mn[Le]=Jt[Le]);if(Jt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ue=0,Le=Object.getOwnPropertySymbols(Jt);ue{const Mn=Vt.useContext(Se.Z),{getPrefixCls:Le,direction:ue,form:Je}=Vt.useContext(Xe.E_),{prefixCls:gn,className:Xn,rootClassName:Gn,size:ce,disabled:vn=Mn,form:An,colon:xi,labelAlign:Ae,labelWrap:en,labelCol:ui,wrapperCol:oi,hideRequiredMark:Si,layout:Zn="horizontal",scrollToFirstError:hi,requiredMark:Qn,onFinishFailed:Ci,name:so,style:wo,feedbackIcons:sn}=Jt,Bo=zn(Jt,["prefixCls","className","rootClassName","size","disabled","form","colon","labelAlign","labelWrap","labelCol","wrapperCol","hideRequiredMark","layout","scrollToFirstError","requiredMark","onFinishFailed","name","style","feedbackIcons"]),Vo=(0,ze.Z)(ce),io=Vt.useContext(rn.Z),Qe=(0,Vt.useMemo)(()=>Qn!==void 0?Qn:Je&&Je.requiredMark!==void 0?Je.requiredMark:!Si,[Si,Qn,Je]),Hn=xi!=null?xi:Je==null?void 0:Je.colon,di=Le("form",gn),[bi,yi]=ie(di),Qi=oe()(di,`${di}-${Zn}`,{[`${di}-hide-required-mark`]:Qe===!1,[`${di}-rtl`]:ue==="rtl",[`${di}-${Vo}`]:Vo},yi,Je==null?void 0:Je.className,Xn,Gn),[co]=Ze(An),{__INTERNAL__:Ri}=co;Ri.name=so;const Hi=(0,Vt.useMemo)(()=>({name:so,labelAlign:Ae,labelCol:ui,labelWrap:en,wrapperCol:oi,vertical:Zn==="vertical",colon:Hn,requiredMark:Qe,itemRef:Ri.itemRef,form:co,feedbackIcons:sn}),[so,Ae,ui,oi,Zn,Hn,Qe,co,sn]);Vt.useImperativeHandle(on,()=>co);const fo=(Uo,un)=>{if(Uo){let Po={block:"nearest"};typeof Uo=="object"&&(Po=Uo),co.scrollToField(un,Po)}},mn=Uo=>{if(Ci==null||Ci(Uo),Uo.errorFields.length){const un=Uo.errorFields[0].name;if(hi!==void 0){fo(hi,un);return}Je&&Je.scrollToFirstError!==void 0&&fo(Je.scrollToFirstError,un)}};return bi(Vt.createElement(Se.n,{disabled:vn},Vt.createElement(Ie.q,{size:Vo},Vt.createElement(Nt.RV,Object.assign({},{validateMessages:io}),Vt.createElement(Nt.q3.Provider,{value:Hi},Vt.createElement(me.default,Object.assign({id:so},Bo,{name:so,onFinishFailed:mn,form:co,style:Object.assign(Object.assign({},Je==null?void 0:Je.style),wo),className:Qi})))))))};var we=Vt.forwardRef(tn),Bn=wt(41799),Jn=wt(8654),Rt=wt(92343),Lt=wt(11592);function St(Jt){if(typeof Jt=="function")return Jt;const on=(0,Lt.Z)(Jt);return on.length<=1?on[0]:on}const Et=()=>{const{status:Jt,errors:on=[],warnings:Mn=[]}=(0,Vt.useContext)(Nt.aM);return{status:Jt,errors:on,warnings:Mn}};Et.Context=Nt.aM;var Bt=Et,yt=wt(16089);function ae(Jt){const[on,Mn]=Vt.useState(Jt),Le=(0,Vt.useRef)(null),ue=(0,Vt.useRef)([]),Je=(0,Vt.useRef)(!1);Vt.useEffect(()=>(Je.current=!1,()=>{Je.current=!0,yt.Z.cancel(Le.current),Le.current=null}),[]);function gn(Xn){Je.current||(Le.current===null&&(ue.current=[],Le.current=(0,yt.Z)(()=>{Le.current=null,Mn(Gn=>{let ce=Gn;return ue.current.forEach(vn=>{ce=vn(ce)}),ce})})),ue.current.push(Xn))}return[on,gn]}function Pe(){const{itemRef:Jt}=Vt.useContext(Nt.q3),on=Vt.useRef({});function Mn(Le,ue){const Je=ue&&typeof ue=="object"&&ue.ref,gn=Le.join("_");return(on.current.name!==gn||on.current.originRef!==Je)&&(on.current.name=gn,on.current.originRef=Je,on.current.ref=(0,Jn.sQ)(Jt(Le),Je)),on.current.ref}return Mn}var ne=wt(29194),_t=wt(34280),ge=wt(2738),pe=wt(27382),le=wt(37028);const Me=Jt=>{const{formItemCls:on}=Jt;return{"@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none)":{[`${on}-control`]:{display:"flex"}}}};var nn=(0,Re.b)(["Form","item-item"],(Jt,on)=>{let{rootPrefixCls:Mn}=on;const Le=$t(Jt,Mn);return[Me(Le)]}),Ge=Jt=>{const{prefixCls:on,status:Mn,wrapperCol:Le,children:ue,errors:Je,warnings:gn,_internalItemRender:Xn,extra:Gn,help:ce,fieldId:vn,marginBottom:An,onErrorVisibleChanged:xi}=Jt,Ae=`${on}-item`,en=Vt.useContext(Nt.q3),ui=Le||en.wrapperCol||{},oi=oe()(`${Ae}-control`,ui.className),Si=Vt.useMemo(()=>Object.assign({},en),[en]);delete Si.labelCol,delete Si.wrapperCol;const Zn=Vt.createElement("div",{className:`${Ae}-control-input`},Vt.createElement("div",{className:`${Ae}-control-input-content`},ue)),hi=Vt.useMemo(()=>({prefixCls:on,status:Mn}),[on,Mn]),Qn=An!==null||Je.length||gn.length?Vt.createElement("div",{style:{display:"flex",flexWrap:"nowrap"}},Vt.createElement(Nt.Rk.Provider,{value:hi},Vt.createElement(je,{fieldId:vn,errors:Je,warnings:gn,help:ce,helpStatus:Mn,className:`${Ae}-explain-connected`,onVisibleChanged:xi})),!!An&&Vt.createElement("div",{style:{width:0,height:An}})):null,Ci={};vn&&(Ci.id=`${vn}_extra`);const so=Gn?Vt.createElement("div",Object.assign({},Ci,{className:`${Ae}-extra`}),Gn):null,wo=Xn&&Xn.mark==="pro_table_render"&&Xn.render?Xn.render(Jt,{input:Zn,errorList:Qn,extra:so}):Vt.createElement(Vt.Fragment,null,Zn,Qn,so);return Vt.createElement(Nt.q3.Provider,{value:Si},Vt.createElement(le.Z,Object.assign({},ui,{className:oi}),wo),Vt.createElement(nn,{prefixCls:on}))},yn=wt(61485),wn=wt(31724),pn=wt(9763),Yn=wt(6848),ni=function(Jt,on){var Mn={};for(var Le in Jt)Object.prototype.hasOwnProperty.call(Jt,Le)&&on.indexOf(Le)<0&&(Mn[Le]=Jt[Le]);if(Jt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ue=0,Le=Object.getOwnPropertySymbols(Jt);ue{let{prefixCls:on,label:Mn,htmlFor:Le,labelCol:ue,labelAlign:Je,colon:gn,required:Xn,requiredMark:Gn,tooltip:ce}=Jt;var vn;const[An]=(0,pn.Z)("Form"),{vertical:xi,labelAlign:Ae,labelCol:en,labelWrap:ui,colon:oi}=Vt.useContext(Nt.q3);if(!Mn)return null;const Si=ue||en||{},Zn=Je||Ae,hi=`${on}-item-label`,Qn=oe()(hi,Zn==="left"&&`${hi}-left`,Si.className,{[`${hi}-wrap`]:!!ui});let Ci=Mn;const so=gn===!0||oi!==!1&&gn!==!1;so&&!xi&&typeof Mn=="string"&&Mn.trim()!==""&&(Ci=Mn.replace(/[:|:]\s*$/,""));const sn=Un(ce);if(sn){const{icon:Qe=Vt.createElement(yn.Z,null)}=sn,Hn=ni(sn,["icon"]),di=Vt.createElement(Yn.Z,Object.assign({},Hn),Vt.cloneElement(Qe,{className:`${on}-item-tooltip`,title:""}));Ci=Vt.createElement(Vt.Fragment,null,Ci,di)}const Bo=Gn==="optional",Vo=typeof Gn=="function";Vo?Ci=Gn(Ci,{required:!!Xn}):Bo&&!Xn&&(Ci=Vt.createElement(Vt.Fragment,null,Ci,Vt.createElement("span",{className:`${on}-item-optional`,title:""},(An==null?void 0:An.optional)||((vn=wn.Z.Form)===null||vn===void 0?void 0:vn.optional))));const io=oe()({[`${on}-item-required`]:Xn,[`${on}-item-required-mark-optional`]:Bo||Vo,[`${on}-item-no-colon`]:!so});return Vt.createElement(le.Z,Object.assign({},Si,{className:Qn}),Vt.createElement("label",{htmlFor:Le,className:io,title:typeof Mn=="string"?Mn:""},Ci))},$i=wt(29679),Mi=wt(19248),eo=wt(96512),Io=wt(58617);const Ao={success:$i.Z,warning:eo.Z,error:Mi.Z,validating:Io.Z};function $n(Jt){let{children:on,errors:Mn,warnings:Le,hasFeedback:ue,validateStatus:Je,prefixCls:gn,meta:Xn,noStyle:Gn}=Jt;const ce=`${gn}-item`,{feedbackIcons:vn}=Vt.useContext(Nt.q3),An=En(Mn,Le,Xn,null,!!ue,Je),{isFormItemInput:xi,status:Ae}=Vt.useContext(Nt.aM),en=Vt.useMemo(()=>{var ui;let oi;if(ue){const hi=ue!==!0&&ue.icons||vn,Qn=An&&((ui=hi==null?void 0:hi({status:An,errors:Mn,warnings:Le}))===null||ui===void 0?void 0:ui[An]),Ci=An&&Ao[An];oi=Qn!==!1&&Ci?Vt.createElement("span",{className:oe()(`${ce}-feedback-icon`,`${ce}-feedback-icon-${An}`)},Qn||Vt.createElement(Ci,null)):null}let Si=!0,Zn=An||"";return Gn&&(Si=xi,Zn=(An!=null?An:Ae)||""),{status:Zn,errors:Mn,warnings:Le,hasFeedback:!!ue,feedbackIcon:oi,isFormItemInput:Si}},[An,ue,Gn,xi,Ae]);return Vt.createElement(Nt.aM.Provider,{value:en},on)}var Kn=function(Jt,on){var Mn={};for(var Le in Jt)Object.prototype.hasOwnProperty.call(Jt,Le)&&on.indexOf(Le)<0&&(Mn[Le]=Jt[Le]);if(Jt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ue=0,Le=Object.getOwnPropertySymbols(Jt);ue{if(sn&&Qn.current){const yi=getComputedStyle(Qn.current);io(parseInt(yi.marginBottom,10))}},[sn,Bo]);const Qe=yi=>{yi||io(null)},di=function(){let yi=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;const Qi=yi?Ci:ce.errors,co=yi?so:ce.warnings;return En(Qi,co,ce,"",!!vn,Gn)}(),bi=oe()(Zn,Mn,Le,{[`${Zn}-with-help`]:wo||Ci.length||so.length,[`${Zn}-has-feedback`]:di&&vn,[`${Zn}-has-success`]:di==="success",[`${Zn}-has-warning`]:di==="warning",[`${Zn}-has-error`]:di==="error",[`${Zn}-is-validating`]:di==="validating",[`${Zn}-hidden`]:An});return Vt.createElement("div",{className:bi,style:ue,ref:Qn},Vt.createElement(pe.Z,Object.assign({className:`${Zn}-row`},(0,ge.Z)(Si,["_internalItemRender","colon","dependencies","extra","fieldKey","getValueFromEvent","getValueProps","htmlFor","id","initialValue","isListField","label","labelAlign","labelCol","labelWrap","messageVariables","name","normalize","noStyle","preserve","requiredMark","rules","shouldUpdate","trigger","tooltip","validateFirst","validateTrigger","valuePropName","wrapperCol","validateDebounce"])),Vt.createElement(mi,Object.assign({htmlFor:Ae},Jt,{requiredMark:hi,required:en!=null?en:ui,prefixCls:on})),Vt.createElement(Ge,Object.assign({},Jt,ce,{errors:Ci,warnings:so,prefixCls:on,status:di,help:Je,marginBottom:Vo,onErrorVisibleChanged:Qe}),Vt.createElement(Nt.qI.Provider,{value:oi},Vt.createElement($n,{prefixCls:on,meta:ce,errors:ce.errors,warnings:ce.warnings,hasFeedback:vn,validateStatus:di},xi)))),!!Vo&&Vt.createElement("div",{className:`${Zn}-margin-offset`,style:{marginBottom:-Vo}}))}const ii="__SPLIT__",Vi=null,wi=Vt.memo(Jt=>{let{children:on}=Jt;return on},(Jt,on)=>Jt.value===on.value&&Jt.update===on.update&&Jt.childProps.length===on.childProps.length&&Jt.childProps.every((Mn,Le)=>Mn===on.childProps[Le]));function bt(Jt){return Jt!=null}function no(){return{errors:[],warnings:[],touched:!1,validating:!1,name:[],validated:!1}}function Ni(Jt){const{name:on,noStyle:Mn,className:Le,dependencies:ue,prefixCls:Je,shouldUpdate:gn,rules:Xn,children:Gn,required:ce,label:vn,messageVariables:An,trigger:xi="onChange",validateTrigger:Ae,hidden:en,help:ui}=Jt,{getPrefixCls:oi}=Vt.useContext(Xe.E_),{name:Si}=Vt.useContext(Nt.q3),Zn=St(Gn),hi=typeof Zn=="function",Qn=Vt.useContext(Nt.qI),{validateTrigger:Ci}=Vt.useContext(me.FieldContext),so=Ae!==void 0?Ae:Ci,wo=bt(on),sn=oi("form",Je),[Bo,Vo]=ie(sn),io=Vt.useContext(me.ListContext),Qe=Vt.useRef(),[Hn,di]=ae({}),[bi,yi]=(0,Bn.Z)(()=>no()),Qi=un=>{const Po=io==null?void 0:io.getKey(un.name);if(yi(un.destroy?no():un,!0),Mn&&ui!==!1&&Qn){let kr=un.name;if(un.destroy)kr=Qe.current||kr;else if(Po!==void 0){const[$o,Hr]=Po;kr=[$o].concat((0,Ft.Z)(Hr)),Qe.current=kr}Qn(un,kr)}},co=(un,Po)=>{di(kr=>{const $o=Object.assign({},kr),xr=[].concat((0,Ft.Z)(un.name.slice(0,-1)),(0,Ft.Z)(Po)).join(ii);return un.destroy?delete $o[xr]:$o[xr]=un,$o})},[Ri,Hi]=Vt.useMemo(()=>{const un=(0,Ft.Z)(bi.errors),Po=(0,Ft.Z)(bi.warnings);return Object.values(Hn).forEach(kr=>{un.push.apply(un,(0,Ft.Z)(kr.errors||[])),Po.push.apply(Po,(0,Ft.Z)(kr.warnings||[]))}),[un,Po]},[Hn,bi.errors,bi.warnings]),fo=Pe();function mn(un,Po,kr){return Mn&&!en?Vt.createElement($n,{prefixCls:sn,hasFeedback:Jt.hasFeedback,validateStatus:Jt.validateStatus,meta:bi,errors:Ri,warnings:Hi,noStyle:!0},un):Vt.createElement(jn,Object.assign({key:"row"},Jt,{className:oe()(Le,Vo),prefixCls:sn,fieldId:Po,isRequired:kr,errors:Ri,warnings:Hi,meta:bi,onSubItemMetaChange:co}),un)}if(!wo&&!hi&&!ue)return Bo(mn(Zn));let Uo={};return typeof vn=="string"?Uo.label=vn:on&&(Uo.label=String(on)),An&&(Uo=Object.assign(Object.assign({},Uo),An)),Bo(Vt.createElement(me.Field,Object.assign({},Jt,{messageVariables:Uo,trigger:xi,validateTrigger:so,onMetaChange:Qi}),(un,Po,kr)=>{const $o=$e(on).length&&Po?Po.name:[],Hr=xn($o,Si),xr=ce!==void 0?ce:!!(Xn&&Xn.some(ko=>{if(ko&&typeof ko=="object"&&ko.required&&!ko.warningOnly)return!0;if(typeof ko=="function"){const Yo=ko(kr);return Yo&&Yo.required&&!Yo.warningOnly}return!1})),Wi=Object.assign({},un);let Ui=null;if(Array.isArray(Zn)&&wo)Ui=Zn;else if(!(hi&&(!(gn||ue)||wo))){if(!(ue&&!hi&&!wo))if((0,Rt.l$)(Zn)){const ko=Object.assign(Object.assign({},Zn.props),Wi);if(ko.id||(ko.id=Hr),ui||Ri.length>0||Hi.length>0||Jt.extra){const Gt=[];(ui||Ri.length>0)&&Gt.push(`${Hr}_help`),Jt.extra&&Gt.push(`${Hr}_extra`),ko["aria-describedby"]=Gt.join(" ")}Ri.length>0&&(ko["aria-invalid"]="true"),xr&&(ko["aria-required"]="true"),(0,Jn.Yr)(Zn)&&(ko.ref=fo($o,Zn)),new Set([].concat((0,Ft.Z)($e(xi)),(0,Ft.Z)($e(so)))).forEach(Gt=>{ko[Gt]=function(){for(var qo,Sr,ps,ms,ks,po=arguments.length,to=new Array(po),Ko=0;Ko{var{prefixCls:on,children:Mn}=Jt,Le=ar(Jt,["prefixCls","children"]);const{getPrefixCls:ue}=Vt.useContext(Xe.E_),Je=ue("form",on),gn=Vt.useMemo(()=>({prefixCls:Je,status:"error"}),[Je]);return Vt.createElement(me.List,Object.assign({},Le),(Xn,Gn,ce)=>Vt.createElement(Nt.Rk.Provider,{value:gn},Mn(Xn.map(vn=>Object.assign(Object.assign({},vn),{fieldKey:vn.key})),Gn,{errors:ce.errors,warnings:ce.warnings})))};function nr(){const{form:Jt}=(0,Vt.useContext)(Nt.q3);return Jt}const _e=we;_e.Item=pr,_e.List=Fo,_e.ErrorList=je,_e.useForm=Ze,_e.useFormInstance=nr,_e.useWatch=me.useWatch,_e.Provider=Nt.RV,_e.create=()=>{};var We=_e},8628:function(Cn,cn,wt){"use strict";var Ft=wt(59301),Ht=wt(34280),oe=wt(56762),ke=wt(69507);function Vt(){let qt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;const Nt=(0,Ft.useRef)({}),Oe=(0,oe.Z)(),be=(0,ke.ZP)();return(0,Ht.Z)(()=>{const Qt=be.subscribe(Fe=>{Nt.current=Fe,qt&&Oe()});return()=>be.unsubscribe(Qt)},[]),Nt.current}cn.Z=Vt},9432:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return gt},n:function(){return dt}});var Ft=wt(19248),Ht=wt(92310),oe=wt.n(Ht),ke=wt(93681),Vt=wt(8654),qt=wt(59301),Nt=wt(19080),Oe=wt(36355),be=wt(1684),Qt=wt(19716),Fe=wt(32441),ye=wt(33234),Re=wt(59412),It=wt(9937);function et(mt){return!!(mt.prefix||mt.suffix||mt.allowClear)}var nt=function(mt,Pt){var kt={};for(var Tt in mt)Object.prototype.hasOwnProperty.call(mt,Tt)&&Pt.indexOf(Tt)<0&&(kt[Tt]=mt[Tt]);if(mt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Dt=0,Tt=Object.getOwnPropertySymbols(mt);Dt{var kt;const{prefixCls:Tt,bordered:Dt=!0,status:$t,size:ie,disabled:Yt,onBlur:fe,onFocus:Zt,suffix:je,allowClear:me,addonAfter:Xe,addonBefore:Se,className:Ie,style:ze,styles:Ue,rootClassName:se,onChange:jt,classNames:$e}=mt,xn=nt(mt,["prefixCls","bordered","status","size","disabled","onBlur","onFocus","suffix","allowClear","addonAfter","addonBefore","className","style","styles","rootClassName","onChange","classNames"]),{getPrefixCls:En,direction:Ne,input:Ze}=qt.useContext(Oe.E_),rn=En("input",Tt),zn=(0,qt.useRef)(null),[tn,Tn]=(0,It.ZP)(rn),{compactSize:we,compactItemClassnames:Bn}=(0,ye.ri)(rn,Ne),Jn=(0,Qt.Z)(nn=>{var qe;return(qe=ie!=null?ie:we)!==null&&qe!==void 0?qe:nn}),Rt=qt.useContext(be.Z),Lt=Yt!=null?Yt:Rt,{status:St,hasFeedback:Et,feedbackIcon:Bt}=(0,qt.useContext)(Fe.aM),yt=(0,Nt.F)(St,$t),ae=et(mt)||!!Et,Pe=(0,qt.useRef)(ae);(0,qt.useEffect)(()=>{var nn;ae&&Pe.current,Pe.current=ae},[ae]);const ne=(0,Re.Z)(zn,!0),_t=nn=>{ne(),fe==null||fe(nn)},ge=nn=>{ne(),Zt==null||Zt(nn)},pe=nn=>{ne(),jt==null||jt(nn)},le=(Et||je)&&qt.createElement(qt.Fragment,null,je,Et&&Bt);let Me;return typeof me=="object"&&(me!=null&&me.clearIcon)?Me=me:me&&(Me={clearIcon:qt.createElement(Ft.Z,null)}),tn(qt.createElement(ke.default,Object.assign({ref:(0,Vt.sQ)(Pt,zn),prefixCls:rn,autoComplete:Ze==null?void 0:Ze.autoComplete},xn,{disabled:Lt,onBlur:_t,onFocus:ge,style:Object.assign(Object.assign({},Ze==null?void 0:Ze.style),ze),styles:Object.assign(Object.assign({},Ze==null?void 0:Ze.styles),Ue),suffix:le,allowClear:Me,className:oe()(Ie,se,Bn,Ze==null?void 0:Ze.className),onChange:pe,addonAfter:Xe&&qt.createElement(ye.BR,null,qt.createElement(Fe.Ux,{override:!0,status:!0},Xe)),addonBefore:Se&&qt.createElement(ye.BR,null,qt.createElement(Fe.Ux,{override:!0,status:!0},Se)),classNames:Object.assign(Object.assign(Object.assign({},$e),Ze==null?void 0:Ze.classNames),{input:oe()({[`${rn}-sm`]:Jn==="small",[`${rn}-lg`]:Jn==="large",[`${rn}-rtl`]:Ne==="rtl",[`${rn}-borderless`]:!Dt},!ae&&(0,Nt.Z)(rn,yt),$e==null?void 0:$e.input,(kt=Ze==null?void 0:Ze.classNames)===null||kt===void 0?void 0:kt.input,Tn)}),classes:{affixWrapper:oe()({[`${rn}-affix-wrapper-sm`]:Jn==="small",[`${rn}-affix-wrapper-lg`]:Jn==="large",[`${rn}-affix-wrapper-rtl`]:Ne==="rtl",[`${rn}-affix-wrapper-borderless`]:!Dt},(0,Nt.Z)(`${rn}-affix-wrapper`,yt,Et),Tn),wrapper:oe()({[`${rn}-group-rtl`]:Ne==="rtl"},Tn),group:oe()({[`${rn}-group-wrapper-sm`]:Jn==="small",[`${rn}-group-wrapper-lg`]:Jn==="large",[`${rn}-group-wrapper-rtl`]:Ne==="rtl",[`${rn}-group-wrapper-disabled`]:Lt},(0,Nt.Z)(`${rn}-group-wrapper`,yt,Et),Tn)}})))})},1643:function(Cn,cn,wt){"use strict";var Ft=wt(19248),Ht=wt(92310),oe=wt.n(Ht),ke=wt(9296),Vt=wt(59301),qt=wt(19080),Nt=wt(36355),Oe=wt(1684),be=wt(19716),Qt=wt(32441),Fe=wt(9432),ye=wt(9937),Re=function(et,nt){var dt={};for(var at in et)Object.prototype.hasOwnProperty.call(et,at)&&nt.indexOf(at)<0&&(dt[at]=et[at]);if(et!=null&&typeof Object.getOwnPropertySymbols=="function")for(var gt=0,at=Object.getOwnPropertySymbols(et);gt{const{prefixCls:dt,bordered:at=!0,size:gt,disabled:mt,status:Pt,allowClear:kt,showCount:Tt,classNames:Dt,rootClassName:$t,className:ie}=et,Yt=Re(et,["prefixCls","bordered","size","disabled","status","allowClear","showCount","classNames","rootClassName","className"]),{getPrefixCls:fe,direction:Zt}=Vt.useContext(Nt.E_),je=(0,be.Z)(gt),me=Vt.useContext(Oe.Z),Xe=mt!=null?mt:me,{status:Se,hasFeedback:Ie,feedbackIcon:ze}=Vt.useContext(Qt.aM),Ue=(0,qt.F)(Se,Pt),se=Vt.useRef(null);Vt.useImperativeHandle(nt,()=>{var Ne;return{resizableTextArea:(Ne=se.current)===null||Ne===void 0?void 0:Ne.resizableTextArea,focus:Ze=>{var rn,zn;(0,Fe.n)((zn=(rn=se.current)===null||rn===void 0?void 0:rn.resizableTextArea)===null||zn===void 0?void 0:zn.textArea,Ze)},blur:()=>{var Ze;return(Ze=se.current)===null||Ze===void 0?void 0:Ze.blur()}}});const jt=fe("input",dt);let $e;typeof kt=="object"&&(kt!=null&&kt.clearIcon)?$e=kt:kt&&($e={clearIcon:Vt.createElement(Ft.Z,null)});const[xn,En]=(0,ye.ZP)(jt);return xn(Vt.createElement(ke.default,Object.assign({},Yt,{disabled:Xe,allowClear:$e,className:oe()(ie,$t),classes:{affixWrapper:oe()(`${jt}-textarea-affix-wrapper`,{[`${jt}-affix-wrapper-rtl`]:Zt==="rtl",[`${jt}-affix-wrapper-borderless`]:!at,[`${jt}-affix-wrapper-sm`]:je==="small",[`${jt}-affix-wrapper-lg`]:je==="large",[`${jt}-textarea-show-count`]:Tt},(0,qt.Z)(`${jt}-affix-wrapper`,Ue),En)},classNames:Object.assign(Object.assign({},Dt),{textarea:oe()({[`${jt}-borderless`]:!at,[`${jt}-sm`]:je==="small",[`${jt}-lg`]:je==="large"},(0,qt.Z)(jt,Ue),En,Dt==null?void 0:Dt.textarea)}),prefixCls:jt,suffix:Ie&&Vt.createElement("span",{className:`${jt}-textarea-suffix`},ze),showCount:Tt,ref:se})))});cn.Z=It},59412:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Ht}});var Ft=wt(59301);function Ht(oe,ke){const Vt=(0,Ft.useRef)([]),qt=()=>{Vt.current.push(setTimeout(()=>{var Nt,Oe,be,Qt;!((Nt=oe.current)===null||Nt===void 0)&&Nt.input&&((Oe=oe.current)===null||Oe===void 0?void 0:Oe.input.getAttribute("type"))==="password"&&(!((be=oe.current)===null||be===void 0)&&be.input.hasAttribute("value"))&&((Qt=oe.current)===null||Qt===void 0||Qt.input.removeAttribute("value"))}))};return(0,Ft.useEffect)(()=>(ke&&qt(),()=>Vt.current.forEach(Nt=>{Nt&&clearTimeout(Nt)})),[]),qt}},92832:function(Cn,cn,wt){"use strict";wt.d(cn,{default:function(){return je}});var Ft=wt(92310),Ht=wt.n(Ft),oe=wt(59301),ke=wt(36355),Vt=wt(32441),qt=wt(9937),Oe=me=>{const{getPrefixCls:Xe,direction:Se}=(0,oe.useContext)(ke.E_),{prefixCls:Ie,className:ze}=me,Ue=Xe("input-group",Ie),se=Xe("input"),[jt,$e]=(0,qt.ZP)(se),xn=Ht()(Ue,{[`${Ue}-lg`]:me.size==="large",[`${Ue}-sm`]:me.size==="small",[`${Ue}-compact`]:me.compact,[`${Ue}-rtl`]:Se==="rtl"},$e,ze),En=(0,oe.useContext)(Vt.aM),Ne=(0,oe.useMemo)(()=>Object.assign(Object.assign({},En),{isFormItemInput:!1}),[En]);return jt(oe.createElement("span",{className:xn,style:me.style,onMouseEnter:me.onMouseEnter,onMouseLeave:me.onMouseLeave,onFocus:me.onFocus,onBlur:me.onBlur},oe.createElement(Vt.aM.Provider,{value:Ne},me.children)))},be=wt(9432),Qt=wt(73331),Fe=wt(15277),ye=wt(2738),Re=wt(8654),It=wt(59412),et=function(me,Xe){var Se={};for(var Ie in me)Object.prototype.hasOwnProperty.call(me,Ie)&&Xe.indexOf(Ie)<0&&(Se[Ie]=me[Ie]);if(me!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ze=0,Ie=Object.getOwnPropertySymbols(me);zeme?oe.createElement(Fe.Z,null):oe.createElement(Qt.Z,null),dt={click:"onClick",hover:"onMouseOver"};var gt=oe.forwardRef((me,Xe)=>{const{visibilityToggle:Se=!0}=me,Ie=typeof Se=="object"&&Se.visible!==void 0,[ze,Ue]=(0,oe.useState)(()=>Ie?Se.visible:!1),se=(0,oe.useRef)(null);oe.useEffect(()=>{Ie&&Ue(Se.visible)},[Ie,Se]);const jt=(0,It.Z)(se),$e=()=>{const{disabled:Lt}=me;Lt||(ze&&jt(),Ue(St=>{var Et;const Bt=!St;return typeof Se=="object"&&((Et=Se.onVisibleChange)===null||Et===void 0||Et.call(Se,Bt)),Bt}))},xn=Lt=>{const{action:St="click",iconRender:Et=nt}=me,Bt=dt[St]||"",yt=Et(ze),ae={[Bt]:$e,className:`${Lt}-icon`,key:"passwordIcon",onMouseDown:Pe=>{Pe.preventDefault()},onMouseUp:Pe=>{Pe.preventDefault()}};return oe.cloneElement(oe.isValidElement(yt)?yt:oe.createElement("span",null,yt),ae)},{className:En,prefixCls:Ne,inputPrefixCls:Ze,size:rn}=me,zn=et(me,["className","prefixCls","inputPrefixCls","size"]),{getPrefixCls:tn}=oe.useContext(ke.E_),Tn=tn("input",Ze),we=tn("input-password",Ne),Bn=Se&&xn(we),Jn=Ht()(we,En,{[`${we}-${rn}`]:!!rn}),Rt=Object.assign(Object.assign({},(0,ye.Z)(zn,["suffix","iconRender","visibilityToggle"])),{type:ze?"text":"password",className:Jn,prefixCls:Tn,suffix:Bn});return rn&&(Rt.size=rn),oe.createElement(be.Z,Object.assign({ref:(0,Re.sQ)(Xe,se)},Rt))}),mt=wt(47472),Pt=wt(92343),kt=wt(3113),Tt=wt(19716),Dt=wt(33234),$t=function(me,Xe){var Se={};for(var Ie in me)Object.prototype.hasOwnProperty.call(me,Ie)&&Xe.indexOf(Ie)<0&&(Se[Ie]=me[Ie]);if(me!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ze=0,Ie=Object.getOwnPropertySymbols(me);ze{const{prefixCls:Se,inputPrefixCls:Ie,className:ze,size:Ue,suffix:se,enterButton:jt=!1,addonAfter:$e,loading:xn,disabled:En,onSearch:Ne,onChange:Ze,onCompositionStart:rn,onCompositionEnd:zn}=me,tn=$t(me,["prefixCls","inputPrefixCls","className","size","suffix","enterButton","addonAfter","loading","disabled","onSearch","onChange","onCompositionStart","onCompositionEnd"]),{getPrefixCls:Tn,direction:we}=oe.useContext(ke.E_),Bn=oe.useRef(!1),Jn=Tn("input-search",Se),Rt=Tn("input",Ie),{compactSize:Lt}=(0,Dt.ri)(Jn,we),St=(0,Tt.Z)(Ge=>{var yn;return(yn=Ue!=null?Ue:Lt)!==null&&yn!==void 0?yn:Ge}),Et=oe.useRef(null),Bt=Ge=>{Ge&&Ge.target&&Ge.type==="click"&&Ne&&Ne(Ge.target.value,Ge,{source:"clear"}),Ze&&Ze(Ge)},yt=Ge=>{var yn;document.activeElement===((yn=Et.current)===null||yn===void 0?void 0:yn.input)&&Ge.preventDefault()},ae=Ge=>{var yn,wn;Ne&&Ne((wn=(yn=Et.current)===null||yn===void 0?void 0:yn.input)===null||wn===void 0?void 0:wn.value,Ge,{source:"input"})},Pe=Ge=>{Bn.current||xn||ae(Ge)},ne=typeof jt=="boolean"?oe.createElement(mt.Z,null):null,_t=`${Jn}-button`;let ge;const pe=jt||{},le=pe.type&&pe.type.__ANT_BUTTON===!0;le||pe.type==="button"?ge=(0,Pt.Tm)(pe,Object.assign({onMouseDown:yt,onClick:Ge=>{var yn,wn;(wn=(yn=pe==null?void 0:pe.props)===null||yn===void 0?void 0:yn.onClick)===null||wn===void 0||wn.call(yn,Ge),ae(Ge)},key:"enterButton"},le?{className:_t,size:St}:{})):ge=oe.createElement(kt.ZP,{className:_t,type:jt?"primary":void 0,size:St,disabled:En,key:"enterButton",onMouseDown:yt,onClick:ae,loading:xn,icon:ne},jt),$e&&(ge=[ge,(0,Pt.Tm)($e,{key:"addonAfter"})]);const Me=Ht()(Jn,{[`${Jn}-rtl`]:we==="rtl",[`${Jn}-${St}`]:!!St,[`${Jn}-with-button`]:!!jt},ze),nn=Ge=>{Bn.current=!0,rn==null||rn(Ge)},qe=Ge=>{Bn.current=!1,zn==null||zn(Ge)};return oe.createElement(be.Z,Object.assign({ref:(0,Re.sQ)(Et,Xe),onPressEnter:Pe},tn,{size:St,onCompositionStart:nn,onCompositionEnd:qe,prefixCls:Rt,addonAfter:ge,suffix:se,onChange:Bt,className:Me,disabled:En}))}),fe=wt(1643);const Zt=be.Z;Zt.Group=Oe,Zt.Search=Yt,Zt.TextArea=fe.Z,Zt.Password=gt;var je=Zt},45818:function(Cn,cn,wt){"use strict";wt.d(cn,{D:function(){return mt},Z:function(){return Tt}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 192H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM104 228a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"bars",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function($t,ie){return Ht.createElement(Vt.Z,(0,Ft.Z)({},$t,{ref:ie,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt,be=wt(33853),Qt=wt(38819),Fe=wt(92310),ye=wt.n(Fe),Re=wt(2738),et=Dt=>!isNaN(parseFloat(Dt))&&isFinite(Dt),nt=wt(36355),dt=wt(84966),at=function(Dt,$t){var ie={};for(var Yt in Dt)Object.prototype.hasOwnProperty.call(Dt,Yt)&&$t.indexOf(Yt)<0&&(ie[Yt]=Dt[Yt]);if(Dt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var fe=0,Yt=Object.getOwnPropertySymbols(Dt);fe{let Dt=0;return function(){let $t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return Dt+=1,`${$t}${Dt}`}})();var Tt=Ht.forwardRef((Dt,$t)=>{const{prefixCls:ie,className:Yt,trigger:fe,children:Zt,defaultCollapsed:je=!1,theme:me="dark",style:Xe={},collapsible:Se=!1,reverseArrow:Ie=!1,width:ze=200,collapsedWidth:Ue=80,zeroWidthTriggerStyle:se,breakpoint:jt,onCollapse:$e,onBreakpoint:xn}=Dt,En=at(Dt,["prefixCls","className","trigger","children","defaultCollapsed","theme","style","collapsible","reverseArrow","width","collapsedWidth","zeroWidthTriggerStyle","breakpoint","onCollapse","onBreakpoint"]),{siderHook:Ne}=(0,Ht.useContext)(dt.Gs),[Ze,rn]=(0,Ht.useState)("collapsed"in Dt?Dt.collapsed:je),[zn,tn]=(0,Ht.useState)(!1);(0,Ht.useEffect)(()=>{"collapsed"in Dt&&rn(Dt.collapsed)},[Dt.collapsed]);const Tn=(St,Et)=>{"collapsed"in Dt||rn(St),$e==null||$e(St,Et)},we=(0,Ht.useRef)();we.current=St=>{tn(St.matches),xn==null||xn(St.matches),Ze!==St.matches&&Tn(St.matches,"responsive")},(0,Ht.useEffect)(()=>{function St(Bt){return we.current(Bt)}let Et;if(typeof window!="undefined"){const{matchMedia:Bt}=window;if(Bt&&jt&&jt in gt){Et=Bt(`(max-width: ${gt[jt]})`);try{Et.addEventListener("change",St)}catch(yt){Et.addListener(St)}St(Et)}}return()=>{try{Et==null||Et.removeEventListener("change",St)}catch(Bt){Et==null||Et.removeListener(St)}}},[jt]),(0,Ht.useEffect)(()=>{const St=Pt("ant-sider-");return Ne.addSider(St),()=>Ne.removeSider(St)},[]);const Bn=()=>{Tn(!Ze,"clickTrigger")},{getPrefixCls:Jn}=(0,Ht.useContext)(nt.E_),Rt=()=>{const St=Jn("layout-sider",ie),Et=(0,Re.Z)(En,["collapsed"]),Bt=Ze?Ue:ze,yt=et(Bt)?`${Bt}px`:String(Bt),ae=parseFloat(String(Ue||0))===0?Ht.createElement("span",{onClick:Bn,className:ye()(`${St}-zero-width-trigger`,`${St}-zero-width-trigger-${Ie?"right":"left"}`),style:se},fe||Ht.createElement(Oe,null)):null,_t={expanded:Ie?Ht.createElement(Qt.Z,null):Ht.createElement(be.Z,null),collapsed:Ie?Ht.createElement(be.Z,null):Ht.createElement(Qt.Z,null)}[Ze?"collapsed":"expanded"],ge=fe!==null?ae||Ht.createElement("div",{className:`${St}-trigger`,onClick:Bn,style:{width:yt}},fe||_t):null,pe=Object.assign(Object.assign({},Xe),{flex:`0 0 ${yt}`,maxWidth:yt,minWidth:yt,width:yt}),le=ye()(St,`${St}-${me}`,{[`${St}-collapsed`]:!!Ze,[`${St}-has-trigger`]:Se&&fe!==null&&!ae,[`${St}-below`]:!!zn,[`${St}-zero-width`]:parseFloat(yt)===0},Yt);return Ht.createElement("aside",Object.assign({className:le},Et,{style:pe,ref:$t}),Ht.createElement("div",{className:`${St}-children`},Zt),Se||zn&&ae?ge:null)},Lt=Ht.useMemo(()=>({siderCollapsed:Ze}),[Ze]);return Ht.createElement(mt.Provider,{value:Lt},Rt())})},84966:function(Cn,cn,wt){"use strict";wt.d(cn,{VY:function(){return mt},$_:function(){return gt},h4:function(){return at},Gs:function(){return Re},ZP:function(){return Pt}});var Ft=wt(19127),Ht=wt(92310),oe=wt.n(Ht),ke=wt(2738),Vt=wt(59301),qt=wt(36355),Nt=wt(83116),be=kt=>{const{componentCls:Tt,bodyBg:Dt,lightSiderBg:$t,lightTriggerBg:ie,lightTriggerColor:Yt}=kt;return{[`${Tt}-sider-light`]:{background:$t,[`${Tt}-sider-trigger`]:{color:Yt,background:ie},[`${Tt}-sider-zero-width-trigger`]:{color:Yt,background:ie,border:`1px solid ${Dt}`,borderInlineStart:0}}}};const Qt=kt=>{const{antCls:Tt,componentCls:Dt,colorText:$t,triggerColor:ie,footerBg:Yt,triggerBg:fe,headerHeight:Zt,headerPadding:je,headerColor:me,footerPadding:Xe,triggerHeight:Se,zeroTriggerHeight:Ie,zeroTriggerWidth:ze,motionDurationMid:Ue,motionDurationSlow:se,fontSize:jt,borderRadius:$e,bodyBg:xn,headerBg:En,siderBg:Ne}=kt;return{[Dt]:Object.assign(Object.assign({display:"flex",flex:"auto",flexDirection:"column",minHeight:0,background:xn,"&, *":{boxSizing:"border-box"},[`&${Dt}-has-sider`]:{flexDirection:"row",[`> ${Dt}, > ${Dt}-content`]:{width:0}},[`${Dt}-header, &${Dt}-footer`]:{flex:"0 0 auto"},[`${Dt}-sider`]:{position:"relative",minWidth:0,background:Ne,transition:`all ${Ue}, background 0s`,"&-children":{height:"100%",marginTop:-.1,paddingTop:.1,[`${Tt}-menu${Tt}-menu-inline-collapsed`]:{width:"auto"}},"&-has-trigger":{paddingBottom:Se},"&-right":{order:1},"&-trigger":{position:"fixed",bottom:0,zIndex:1,height:Se,color:ie,lineHeight:`${Se}px`,textAlign:"center",background:fe,cursor:"pointer",transition:`all ${Ue}`},"&-zero-width":{"> *":{overflow:"hidden"},"&-trigger":{position:"absolute",top:Zt,insetInlineEnd:-ze,zIndex:1,width:ze,height:Ie,color:ie,fontSize:kt.fontSizeXL,display:"flex",alignItems:"center",justifyContent:"center",background:Ne,borderStartStartRadius:0,borderStartEndRadius:$e,borderEndEndRadius:$e,borderEndStartRadius:0,cursor:"pointer",transition:`background ${se} ease`,"&::after":{position:"absolute",inset:0,background:"transparent",transition:`all ${se}`,content:'""'},"&:hover::after":{background:"rgba(255, 255, 255, 0.2)"},"&-right":{insetInlineStart:-ze,borderStartStartRadius:$e,borderStartEndRadius:0,borderEndEndRadius:0,borderEndStartRadius:$e}}}}},be(kt)),{"&-rtl":{direction:"rtl"}}),[`${Dt}-header`]:{height:Zt,padding:je,color:me,lineHeight:`${Zt}px`,background:En,[`${Tt}-menu`]:{lineHeight:"inherit"}},[`${Dt}-footer`]:{padding:Xe,color:$t,fontSize:jt,background:Yt},[`${Dt}-content`]:{flex:"auto",minHeight:0}}};var Fe=(0,Nt.Z)("Layout",kt=>[Qt(kt)],kt=>{const{colorBgLayout:Tt,controlHeight:Dt,controlHeightLG:$t,colorText:ie,controlHeightSM:Yt,marginXXS:fe,colorTextLightSolid:Zt,colorBgContainer:je}=kt,me=$t*1.25;return{colorBgHeader:"#001529",colorBgBody:Tt,colorBgTrigger:"#002140",bodyBg:Tt,headerBg:"#001529",headerHeight:Dt*2,headerPadding:`0 ${me}px`,headerColor:ie,footerPadding:`${Yt}px ${me}px`,footerBg:Tt,siderBg:"#001529",triggerHeight:$t+fe*2,triggerBg:"#002140",triggerColor:Zt,zeroTriggerWidth:$t,zeroTriggerHeight:$t,lightSiderBg:je,lightTriggerBg:je,lightTriggerColor:ie}},{deprecatedTokens:[["colorBgBody","bodyBg"],["colorBgHeader","headerBg"],["colorBgTrigger","triggerBg"]]}),ye=function(kt,Tt){var Dt={};for(var $t in kt)Object.prototype.hasOwnProperty.call(kt,$t)&&Tt.indexOf($t)<0&&(Dt[$t]=kt[$t]);if(kt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ie=0,$t=Object.getOwnPropertySymbols(kt);ie<$t.length;ie++)Tt.indexOf($t[ie])<0&&Object.prototype.propertyIsEnumerable.call(kt,$t[ie])&&(Dt[$t[ie]]=kt[$t[ie]]);return Dt};const Re=Vt.createContext({siderHook:{addSider:()=>null,removeSider:()=>null}});function It(kt){let{suffixCls:Tt,tagName:Dt,displayName:$t}=kt;return ie=>Vt.forwardRef((fe,Zt)=>Vt.createElement(ie,Object.assign({ref:Zt,suffixCls:Tt,tagName:Dt},fe)))}const et=Vt.forwardRef((kt,Tt)=>{const{prefixCls:Dt,suffixCls:$t,className:ie,tagName:Yt}=kt,fe=ye(kt,["prefixCls","suffixCls","className","tagName"]),{getPrefixCls:Zt}=Vt.useContext(qt.E_),je=Zt("layout",Dt),[me,Xe]=Fe(je),Se=$t?`${je}-${$t}`:je;return me(Vt.createElement(Yt,Object.assign({className:oe()(Dt||Se,ie,Xe),ref:Tt},fe)))}),nt=Vt.forwardRef((kt,Tt)=>{const{direction:Dt}=Vt.useContext(qt.E_),[$t,ie]=Vt.useState([]),{prefixCls:Yt,className:fe,rootClassName:Zt,children:je,hasSider:me,tagName:Xe,style:Se}=kt,Ie=ye(kt,["prefixCls","className","rootClassName","children","hasSider","tagName","style"]),ze=(0,ke.Z)(Ie,["suffixCls"]),{getPrefixCls:Ue,layout:se}=Vt.useContext(qt.E_),jt=Ue("layout",Yt),[$e,xn]=Fe(jt),En=oe()(jt,{[`${jt}-has-sider`]:typeof me=="boolean"?me:$t.length>0,[`${jt}-rtl`]:Dt==="rtl"},se==null?void 0:se.className,fe,Zt,xn),Ne=Vt.useMemo(()=>({siderHook:{addSider:Ze=>{ie(rn=>[].concat((0,Ft.Z)(rn),[Ze]))},removeSider:Ze=>{ie(rn=>rn.filter(zn=>zn!==Ze))}}}),[]);return $e(Vt.createElement(Re.Provider,{value:Ne},Vt.createElement(Xe,Object.assign({ref:Tt,className:En,style:Object.assign(Object.assign({},se==null?void 0:se.style),Se)},ze),je)))}),dt=It({tagName:"div",displayName:"Layout"})(nt),at=It({suffixCls:"header",tagName:"header",displayName:"Header"})(et),gt=It({suffixCls:"footer",tagName:"footer",displayName:"Footer"})(et),mt=It({suffixCls:"content",tagName:"main",displayName:"Content"})(et);var Pt=dt},40875:function(Cn,cn,wt){"use strict";wt.d(cn,{J:function(){return qt}});var Ft=wt(59301),Ht=wt(33234),oe=wt(70425),ke=function(Nt,Oe){var be={};for(var Qt in Nt)Object.prototype.hasOwnProperty.call(Nt,Qt)&&Oe.indexOf(Qt)<0&&(be[Qt]=Nt[Qt]);if(Nt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Fe=0,Qt=Object.getOwnPropertySymbols(Nt);Fe{const{children:be}=Nt,Qt=ke(Nt,["children"]),Fe=Ft.useContext(Vt),ye=Ft.useMemo(()=>Object.assign(Object.assign({},Fe),Qt),[Fe,Qt.prefixCls,Qt.mode,Qt.selectable]);return Ft.createElement(Vt.Provider,{value:ye},Ft.createElement(Ht.BR,null,(0,oe.supportNodeRef)(be)?Ft.cloneElement(be,{ref:Oe}):be))});cn.Z=Vt},20834:function(Cn,cn,wt){"use strict";wt.d(cn,{default:function(){return Lt}});var Ft=wt(15285),Ht=wt(59301),oe=wt(45818),ke=wt(92310),Vt=wt.n(ke),qt=wt(36355),Nt=function(St,Et){var Bt={};for(var yt in St)Object.prototype.hasOwnProperty.call(St,yt)&&Et.indexOf(yt)<0&&(Bt[yt]=St[yt]);if(St!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ae=0,yt=Object.getOwnPropertySymbols(St);ae{const{prefixCls:Et,className:Bt,dashed:yt}=St,ae=Nt(St,["prefixCls","className","dashed"]),{getPrefixCls:Pe}=Ht.useContext(qt.E_),ne=Pe("menu",Et),_t=Vt()({[`${ne}-item-divider-dashed`]:!!yt},Bt);return Ht.createElement(Ft.iz,Object.assign({className:_t},ae))},Qt=wt(11592),Fe=wt(2738),ye=wt(6848),Re=wt(92343),et=(0,Ht.createContext)({prefixCls:"",firstLevel:!0,inlineCollapsed:!1}),dt=St=>{var Et;const{className:Bt,children:yt,icon:ae,title:Pe,danger:ne}=St,{prefixCls:_t,firstLevel:ge,direction:pe,disableMenuItemTitleTooltip:le,inlineCollapsed:Me}=Ht.useContext(et),nn=Yn=>{const ni=Ht.createElement("span",{className:`${_t}-title-content`},yt);return(!ae||(0,Re.l$)(yt)&&yt.type==="span")&&yt&&Yn&&ge&&typeof yt=="string"?Ht.createElement("div",{className:`${_t}-inline-collapsed-noicon`},yt.charAt(0)):ni},{siderCollapsed:qe}=Ht.useContext(oe.D);let Ge=Pe;typeof Pe=="undefined"?Ge=ge?yt:"":Pe===!1&&(Ge="");const yn={title:Ge};!qe&&!Me&&(yn.title=null,yn.open=!1);const wn=(0,Qt.Z)(yt).length;let pn=Ht.createElement(Ft.ck,Object.assign({},(0,Fe.Z)(St,["title","icon","danger"]),{className:Vt()({[`${_t}-item-danger`]:ne,[`${_t}-item-only-child`]:(ae?wn+1:wn)===1},Bt),title:typeof Pe=="string"?Pe:void 0}),(0,Re.Tm)(ae,{className:Vt()((0,Re.l$)(ae)?(Et=ae.props)===null||Et===void 0?void 0:Et.className:"",`${_t}-item-icon`)}),nn(Me));return le||(pn=Ht.createElement(ye.Z,Object.assign({},yn,{placement:pe==="rtl"?"left":"right",overlayClassName:`${_t}-inline-collapsed-tooltip`}),pn)),pn},gt=St=>{var Et;const{popupClassName:Bt,icon:yt,title:ae,theme:Pe}=St,ne=Ht.useContext(et),{prefixCls:_t,inlineCollapsed:ge,theme:pe}=ne,le=(0,Ft.Xl)();let Me;if(!yt)Me=ge&&!le.length&&ae&&typeof ae=="string"?Ht.createElement("div",{className:`${_t}-inline-collapsed-noicon`},ae.charAt(0)):Ht.createElement("span",{className:`${_t}-title-content`},ae);else{const qe=(0,Re.l$)(ae)&&ae.type==="span";Me=Ht.createElement(Ht.Fragment,null,(0,Re.Tm)(yt,{className:Vt()((0,Re.l$)(yt)?(Et=yt.props)===null||Et===void 0?void 0:Et.className:"",`${_t}-item-icon`)}),qe?ae:Ht.createElement("span",{className:`${_t}-title-content`},ae))}const nn=Ht.useMemo(()=>Object.assign(Object.assign({},ne),{firstLevel:!1}),[ne]);return Ht.createElement(et.Provider,{value:nn},Ht.createElement(Ft.Wd,Object.assign({},(0,Fe.Z)(St,["icon"]),{title:Me,popupClassName:Vt()(_t,Bt,`${_t}-${Pe||pe}`)})))},mt=wt(18785),Pt=wt(70425),kt=wt(62892),Tt=wt(40875),Dt=function(St,Et){var Bt={};for(var yt in St)Object.prototype.hasOwnProperty.call(St,yt)&&Et.indexOf(yt)<0&&(Bt[yt]=St[yt]);if(St!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ae=0,yt=Object.getOwnPropertySymbols(St);ae{if(Et&&typeof Et=="object"){const yt=Et,{label:ae,children:Pe,key:ne,type:_t}=yt,ge=Dt(yt,["label","children","key","type"]),pe=ne!=null?ne:`tmp-${Bt}`;return Pe||_t==="group"?_t==="group"?Ht.createElement(Ft.BW,Object.assign({key:pe},ge,{title:ae}),$t(Pe)):Ht.createElement(gt,Object.assign({key:pe},ge,{title:ae}),$t(Pe)):_t==="divider"?Ht.createElement(be,Object.assign({key:pe},ge)):Ht.createElement(dt,Object.assign({key:pe},ge),ae)}return null}).filter(Et=>Et)}function ie(St){return Ht.useMemo(()=>St&&$t(St),[St])}var Yt=wt(64993),fe=wt(17313),Zt=wt(8378),je=wt(13826),me=wt(29878),Xe=wt(83116),Se=wt(37613),ze=St=>{const{componentCls:Et,motionDurationSlow:Bt,horizontalLineHeight:yt,colorSplit:ae,lineWidth:Pe,lineType:ne,itemPaddingInline:_t}=St;return{[`${Et}-horizontal`]:{lineHeight:yt,border:0,borderBottom:`${Pe}px ${ne} ${ae}`,boxShadow:"none","&::after":{display:"block",clear:"both",height:0,content:'"\\20"'},[`${Et}-item, ${Et}-submenu`]:{position:"relative",display:"inline-block",verticalAlign:"bottom",paddingInline:_t},[`> ${Et}-item:hover, > ${Et}-item-active, > ${Et}-submenu ${Et}-submenu-title:hover`]:{backgroundColor:"transparent"},[`${Et}-item, ${Et}-submenu-title`]:{transition:[`border-color ${Bt}`,`background ${Bt}`].join(",")},[`${Et}-submenu-arrow`]:{display:"none"}}}},se=St=>{let{componentCls:Et,menuArrowOffset:Bt}=St;return{[`${Et}-rtl`]:{direction:"rtl"},[`${Et}-submenu-rtl`]:{transformOrigin:"100% 0"},[`${Et}-rtl${Et}-vertical, ${Et}-submenu-rtl ${Et}-vertical`]:{[`${Et}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateY(-${Bt})`},"&::after":{transform:`rotate(45deg) translateY(${Bt})`}}}}};const jt=St=>Object.assign({},(0,fe.oN)(St));var xn=(St,Et)=>{const{componentCls:Bt,itemColor:yt,itemSelectedColor:ae,groupTitleColor:Pe,itemBg:ne,subMenuItemBg:_t,itemSelectedBg:ge,activeBarHeight:pe,activeBarWidth:le,activeBarBorderWidth:Me,motionDurationSlow:nn,motionEaseInOut:qe,motionEaseOut:Ge,itemPaddingInline:yn,motionDurationMid:wn,itemHoverColor:pn,lineType:Yn,colorSplit:ni,itemDisabledColor:Un,dangerItemColor:gi,dangerItemHoverColor:mi,dangerItemSelectedColor:$i,dangerItemActiveBg:Mi,dangerItemSelectedBg:eo,itemHoverBg:Io,itemActiveBg:Ao,menuSubMenuBg:$n,horizontalItemSelectedColor:Kn,horizontalItemSelectedBg:jn,horizontalItemBorderRadius:ii,horizontalItemHoverBg:Vi,popupBg:wi}=St;return{[`${Bt}-${Et}, ${Bt}-${Et} > ${Bt}`]:{color:yt,background:ne,[`&${Bt}-root:focus-visible`]:Object.assign({},jt(St)),[`${Bt}-item-group-title`]:{color:Pe},[`${Bt}-submenu-selected`]:{[`> ${Bt}-submenu-title`]:{color:ae}},[`${Bt}-item-disabled, ${Bt}-submenu-disabled`]:{color:`${Un} !important`},[`${Bt}-item:not(${Bt}-item-selected):not(${Bt}-submenu-selected)`]:{[`&:hover, > ${Bt}-submenu-title:hover`]:{color:pn}},[`&:not(${Bt}-horizontal)`]:{[`${Bt}-item:not(${Bt}-item-selected)`]:{"&:hover":{backgroundColor:Io},"&:active":{backgroundColor:Ao}},[`${Bt}-submenu-title`]:{"&:hover":{backgroundColor:Io},"&:active":{backgroundColor:Ao}}},[`${Bt}-item-danger`]:{color:gi,[`&${Bt}-item:hover`]:{[`&:not(${Bt}-item-selected):not(${Bt}-submenu-selected)`]:{color:mi}},[`&${Bt}-item:active`]:{background:Mi}},[`${Bt}-item a`]:{"&, &:hover":{color:"inherit"}},[`${Bt}-item-selected`]:{color:ae,[`&${Bt}-item-danger`]:{color:$i},"a, a:hover":{color:"inherit"}},[`& ${Bt}-item-selected`]:{backgroundColor:ge,[`&${Bt}-item-danger`]:{backgroundColor:eo}},[`${Bt}-item, ${Bt}-submenu-title`]:{[`&:not(${Bt}-item-disabled):focus-visible`]:Object.assign({},jt(St))},[`&${Bt}-submenu > ${Bt}`]:{backgroundColor:$n},[`&${Bt}-popup > ${Bt}`]:{backgroundColor:wi},[`&${Bt}-horizontal`]:Object.assign(Object.assign({},Et==="dark"?{borderBottom:0}:{}),{[`> ${Bt}-item, > ${Bt}-submenu`]:{top:Me,marginTop:-Me,marginBottom:0,borderRadius:ii,"&::after":{position:"absolute",insetInline:yn,bottom:0,borderBottom:`${pe}px solid transparent`,transition:`border-color ${nn} ${qe}`,content:'""'},"&:hover, &-active, &-open":{background:Vi,"&::after":{borderBottomWidth:pe,borderBottomColor:Kn}},"&-selected":{color:Kn,backgroundColor:jn,"&:hover":{backgroundColor:jn},"&::after":{borderBottomWidth:pe,borderBottomColor:Kn}}}}),[`&${Bt}-root`]:{[`&${Bt}-inline, &${Bt}-vertical`]:{borderInlineEnd:`${Me}px ${Yn} ${ni}`}},[`&${Bt}-inline`]:{[`${Bt}-sub${Bt}-inline`]:{background:_t},[`${Bt}-item, ${Bt}-submenu-title`]:Me&&le?{width:`calc(100% + ${Me}px)`}:{},[`${Bt}-item`]:{position:"relative","&::after":{position:"absolute",insetBlock:0,insetInlineEnd:0,borderInlineEnd:`${le}px solid ${ae}`,transform:"scaleY(0.0001)",opacity:0,transition:[`transform ${wn} ${Ge}`,`opacity ${wn} ${Ge}`].join(","),content:'""'},[`&${Bt}-item-danger`]:{"&::after":{borderInlineEndColor:$i}}},[`${Bt}-selected, ${Bt}-item-selected`]:{"&::after":{transform:"scaleY(1)",opacity:1,transition:[`transform ${wn} ${qe}`,`opacity ${wn} ${qe}`].join(",")}}}}}};const En=St=>{const{componentCls:Et,itemHeight:Bt,itemMarginInline:yt,padding:ae,menuArrowSize:Pe,marginXS:ne,itemMarginBlock:_t}=St,ge=ae+Pe+ne;return{[`${Et}-item`]:{position:"relative",overflow:"hidden"},[`${Et}-item, ${Et}-submenu-title`]:{height:Bt,lineHeight:`${Bt}px`,paddingInline:ae,overflow:"hidden",textOverflow:"ellipsis",marginInline:yt,marginBlock:_t,width:`calc(100% - ${yt*2}px)`},[`> ${Et}-item, > ${Et}-submenu > ${Et}-submenu-title`]:{height:Bt,lineHeight:`${Bt}px`},[`${Et}-item-group-list ${Et}-submenu-title, ${Et}-submenu-title`]:{paddingInlineEnd:ge}}};var Ze=St=>{const{componentCls:Et,iconCls:Bt,itemHeight:yt,colorTextLightSolid:ae,dropdownWidth:Pe,controlHeightLG:ne,motionDurationMid:_t,motionEaseOut:ge,paddingXL:pe,itemMarginInline:le,fontSizeLG:Me,motionDurationSlow:nn,paddingXS:qe,boxShadowSecondary:Ge,collapsedWidth:yn,collapsedIconSize:wn}=St,pn={height:yt,lineHeight:`${yt}px`,listStylePosition:"inside",listStyleType:"disc"};return[{[Et]:{"&-inline, &-vertical":Object.assign({[`&${Et}-root`]:{boxShadow:"none"}},En(St))},[`${Et}-submenu-popup`]:{[`${Et}-vertical`]:Object.assign(Object.assign({},En(St)),{boxShadow:Ge})}},{[`${Et}-submenu-popup ${Et}-vertical${Et}-sub`]:{minWidth:Pe,maxHeight:`calc(100vh - ${ne*2.5}px)`,padding:"0",overflow:"hidden",borderInlineEnd:0,"&:not([class*='-active'])":{overflowX:"hidden",overflowY:"auto"}}},{[`${Et}-inline`]:{width:"100%",[`&${Et}-root`]:{[`${Et}-item, ${Et}-submenu-title`]:{display:"flex",alignItems:"center",transition:[`border-color ${nn}`,`background ${nn}`,`padding ${_t} ${ge}`].join(","),[`> ${Et}-title-content`]:{flex:"auto",minWidth:0,overflow:"hidden",textOverflow:"ellipsis"},"> *":{flex:"none"}}},[`${Et}-sub${Et}-inline`]:{padding:0,border:0,borderRadius:0,boxShadow:"none",[`& > ${Et}-submenu > ${Et}-submenu-title`]:pn,[`& ${Et}-item-group-title`]:{paddingInlineStart:pe}},[`${Et}-item`]:pn}},{[`${Et}-inline-collapsed`]:{width:yn,[`&${Et}-root`]:{[`${Et}-item, ${Et}-submenu ${Et}-submenu-title`]:{[`> ${Et}-inline-collapsed-noicon`]:{fontSize:Me,textAlign:"center"}}},[`> ${Et}-item, > ${Et}-item-group > ${Et}-item-group-list > ${Et}-item, > ${Et}-item-group > ${Et}-item-group-list > ${Et}-submenu > ${Et}-submenu-title, > ${Et}-submenu > ${Et}-submenu-title`]:{insetInlineStart:0,paddingInline:`calc(50% - ${Me/2}px - ${le}px)`,textOverflow:"clip",[` ${Et}-submenu-arrow, ${Et}-submenu-expand-icon `]:{opacity:0},[`${Et}-item-icon, ${Bt}`]:{margin:0,fontSize:wn,lineHeight:`${yt}px`,"+ span":{display:"inline-block",opacity:0}}},[`${Et}-item-icon, ${Bt}`]:{display:"inline-block"},"&-tooltip":{pointerEvents:"none",[`${Et}-item-icon, ${Bt}`]:{display:"none"},"a, a:hover":{color:ae}},[`${Et}-item-group-title`]:Object.assign(Object.assign({},fe.vS),{paddingInline:qe})}}]};const rn=St=>{const{componentCls:Et,motionDurationSlow:Bt,motionDurationMid:yt,motionEaseInOut:ae,motionEaseOut:Pe,iconCls:ne,iconSize:_t,iconMarginInlineEnd:ge}=St;return{[`${Et}-item, ${Et}-submenu-title`]:{position:"relative",display:"block",margin:0,whiteSpace:"nowrap",cursor:"pointer",transition:[`border-color ${Bt}`,`background ${Bt}`,`padding ${Bt} ${ae}`].join(","),[`${Et}-item-icon, ${ne}`]:{minWidth:_t,fontSize:_t,transition:[`font-size ${yt} ${Pe}`,`margin ${Bt} ${ae}`,`color ${Bt}`].join(","),"+ span":{marginInlineStart:ge,opacity:1,transition:[`opacity ${Bt} ${ae}`,`margin ${Bt}`,`color ${Bt}`].join(",")}},[`${Et}-item-icon`]:Object.assign({},(0,fe.Ro)()),[`&${Et}-item-only-child`]:{[`> ${ne}, > ${Et}-item-icon`]:{marginInlineEnd:0}}},[`${Et}-item-disabled, ${Et}-submenu-disabled`]:{background:"none !important",cursor:"not-allowed","&::after":{borderColor:"transparent !important"},a:{color:"inherit !important"},[`> ${Et}-submenu-title`]:{color:"inherit !important",cursor:"not-allowed"}}}},zn=St=>{const{componentCls:Et,motionDurationSlow:Bt,motionEaseInOut:yt,borderRadius:ae,menuArrowSize:Pe,menuArrowOffset:ne}=St;return{[`${Et}-submenu`]:{"&-expand-icon, &-arrow":{position:"absolute",top:"50%",insetInlineEnd:St.margin,width:Pe,color:"currentcolor",transform:"translateY(-50%)",transition:`transform ${Bt} ${yt}, opacity ${Bt}`},"&-arrow":{"&::before, &::after":{position:"absolute",width:Pe*.6,height:Pe*.15,backgroundColor:"currentcolor",borderRadius:ae,transition:[`background ${Bt} ${yt}`,`transform ${Bt} ${yt}`,`top ${Bt} ${yt}`,`color ${Bt} ${yt}`].join(","),content:'""'},"&::before":{transform:`rotate(45deg) translateY(-${ne})`},"&::after":{transform:`rotate(-45deg) translateY(${ne})`}}}}},tn=St=>{const{antCls:Et,componentCls:Bt,fontSize:yt,motionDurationSlow:ae,motionDurationMid:Pe,motionEaseInOut:ne,paddingXS:_t,padding:ge,colorSplit:pe,lineWidth:le,zIndexPopup:Me,borderRadiusLG:nn,subMenuItemBorderRadius:qe,menuArrowSize:Ge,menuArrowOffset:yn,lineType:wn,menuPanelMaskInset:pn,groupTitleLineHeight:Yn,groupTitleFontSize:ni}=St;return[{"":{[`${Bt}`]:Object.assign(Object.assign({},(0,fe.dF)()),{"&-hidden":{display:"none"}})},[`${Bt}-submenu-hidden`]:{display:"none"}},{[Bt]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},(0,fe.Wf)(St)),(0,fe.dF)()),{marginBottom:0,paddingInlineStart:0,fontSize:yt,lineHeight:0,listStyle:"none",outline:"none",transition:`width ${ae} cubic-bezier(0.2, 0, 0, 1) 0s`,"ul, ol":{margin:0,padding:0,listStyle:"none"},"&-overflow":{display:"flex",[`${Bt}-item`]:{flex:"none"}},[`${Bt}-item, ${Bt}-submenu, ${Bt}-submenu-title`]:{borderRadius:St.itemBorderRadius},[`${Bt}-item-group-title`]:{padding:`${_t}px ${ge}px`,fontSize:ni,lineHeight:Yn,transition:`all ${ae}`},[`&-horizontal ${Bt}-submenu`]:{transition:[`border-color ${ae} ${ne}`,`background ${ae} ${ne}`].join(",")},[`${Bt}-submenu, ${Bt}-submenu-inline`]:{transition:[`border-color ${ae} ${ne}`,`background ${ae} ${ne}`,`padding ${Pe} ${ne}`].join(",")},[`${Bt}-submenu ${Bt}-sub`]:{cursor:"initial",transition:[`background ${ae} ${ne}`,`padding ${ae} ${ne}`].join(",")},[`${Bt}-title-content`]:{transition:`color ${ae}`},[`${Bt}-item a`]:{"&::before":{position:"absolute",inset:0,backgroundColor:"transparent",content:'""'}},[`${Bt}-item-divider`]:{overflow:"hidden",lineHeight:0,borderColor:pe,borderStyle:wn,borderWidth:0,borderTopWidth:le,marginBlock:le,padding:0,"&-dashed":{borderStyle:"dashed"}}}),rn(St)),{[`${Bt}-item-group`]:{[`${Bt}-item-group-list`]:{margin:0,padding:0,[`${Bt}-item, ${Bt}-submenu-title`]:{paddingInline:`${yt*2}px ${ge}px`}}},"&-submenu":{"&-popup":{position:"absolute",zIndex:Me,borderRadius:nn,boxShadow:"none",transformOrigin:"0 0",[`&${Bt}-submenu`]:{background:"transparent"},"&::before":{position:"absolute",inset:`${pn}px 0 0`,zIndex:-1,width:"100%",height:"100%",opacity:0,content:'""'}},"&-placement-rightTop::before":{top:0,insetInlineStart:pn},"\n &-placement-leftTop,\n &-placement-bottomRight,\n ":{transformOrigin:"100% 0"},"\n &-placement-leftBottom,\n &-placement-topRight,\n ":{transformOrigin:"100% 100%"},"\n &-placement-rightBottom,\n &-placement-topLeft,\n ":{transformOrigin:"0 100%"},"\n &-placement-bottomLeft,\n &-placement-rightTop,\n ":{transformOrigin:"0 0"},"\n &-placement-leftTop,\n &-placement-leftBottom\n ":{paddingInlineEnd:St.paddingXS},"\n &-placement-rightTop,\n &-placement-rightBottom\n ":{paddingInlineStart:St.paddingXS},"\n &-placement-topRight,\n &-placement-topLeft\n ":{paddingBottom:St.paddingXS},"\n &-placement-bottomRight,\n &-placement-bottomLeft\n ":{paddingTop:St.paddingXS},[`> ${Bt}`]:Object.assign(Object.assign(Object.assign({borderRadius:nn},rn(St)),zn(St)),{[`${Bt}-item, ${Bt}-submenu > ${Bt}-submenu-title`]:{borderRadius:qe},[`${Bt}-submenu-title::after`]:{transition:`transform ${ae} ${ne}`}})}}),zn(St)),{[`&-inline-collapsed ${Bt}-submenu-arrow, &-inline ${Bt}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateX(${yn})`},"&::after":{transform:`rotate(45deg) translateX(-${yn})`}},[`${Bt}-submenu-open${Bt}-submenu-inline > ${Bt}-submenu-title > ${Bt}-submenu-arrow`]:{transform:`translateY(-${Ge*.2}px)`,"&::after":{transform:`rotate(-45deg) translateX(-${yn})`},"&::before":{transform:`rotate(45deg) translateX(${yn})`}}})},{[`${Et}-layout-header`]:{[Bt]:{lineHeight:"inherit"}}}]};var Tn=(St,Et)=>(0,Xe.Z)("Menu",yt=>{if(Et===!1)return[];const{colorBgElevated:ae,colorPrimary:Pe,colorTextLightSolid:ne,controlHeightLG:_t,fontSize:ge,darkItemColor:pe,darkDangerItemColor:le,darkItemBg:Me,darkSubMenuItemBg:nn,darkItemSelectedColor:qe,darkItemSelectedBg:Ge,darkDangerItemSelectedBg:yn,darkItemHoverBg:wn,darkGroupTitleColor:pn,darkItemHoverColor:Yn,darkItemDisabledColor:ni,darkDangerItemHoverColor:Un,darkDangerItemSelectedColor:gi,darkDangerItemActiveBg:mi}=yt,$i=ge/7*5,Mi=(0,Se.TS)(yt,{menuArrowSize:$i,menuHorizontalHeight:_t*1.15,menuArrowOffset:`${$i*.25}px`,menuPanelMaskInset:-7,menuSubMenuBg:ae}),eo=(0,Se.TS)(Mi,{itemColor:pe,itemHoverColor:Yn,groupTitleColor:pn,itemSelectedColor:qe,itemBg:Me,popupBg:Me,subMenuItemBg:nn,itemActiveBg:"transparent",itemSelectedBg:Ge,activeBarHeight:0,activeBarBorderWidth:0,itemHoverBg:wn,itemDisabledColor:ni,dangerItemColor:le,dangerItemHoverColor:Un,dangerItemSelectedColor:gi,dangerItemActiveBg:mi,dangerItemSelectedBg:yn,menuSubMenuBg:nn,horizontalItemSelectedColor:ne,horizontalItemSelectedBg:Pe});return[tn(Mi),ze(Mi),Ze(Mi),xn(Mi,"light"),xn(eo,"dark"),se(Mi),(0,Zt.Z)(Mi),(0,je.oN)(Mi,"slide-up"),(0,je.oN)(Mi,"slide-down"),(0,me._y)(Mi,"zoom-big")]},yt=>{const{colorPrimary:ae,colorError:Pe,colorTextDisabled:ne,colorErrorBg:_t,colorText:ge,colorTextDescription:pe,colorBgContainer:le,colorFillAlter:Me,colorFillContent:nn,lineWidth:qe,lineWidthBold:Ge,controlItemBgActive:yn,colorBgTextHover:wn,controlHeightLG:pn,lineHeight:Yn,colorBgElevated:ni,marginXXS:Un,padding:gi,fontSize:mi,controlHeightSM:$i,fontSizeLG:Mi,colorTextLightSolid:eo,colorErrorHover:Io}=yt,Ao=new Yt.C(eo).setAlpha(.65).toRgbString();return{dropdownWidth:160,zIndexPopup:yt.zIndexPopupBase+50,radiusItem:yt.borderRadiusLG,itemBorderRadius:yt.borderRadiusLG,radiusSubMenuItem:yt.borderRadiusSM,subMenuItemBorderRadius:yt.borderRadiusSM,colorItemText:ge,itemColor:ge,colorItemTextHover:ge,itemHoverColor:ge,colorItemTextHoverHorizontal:ae,horizontalItemHoverColor:ae,colorGroupTitle:pe,groupTitleColor:pe,colorItemTextSelected:ae,itemSelectedColor:ae,colorItemTextSelectedHorizontal:ae,horizontalItemSelectedColor:ae,colorItemBg:le,itemBg:le,colorItemBgHover:wn,itemHoverBg:wn,colorItemBgActive:nn,itemActiveBg:yn,colorSubItemBg:Me,subMenuItemBg:Me,colorItemBgSelected:yn,itemSelectedBg:yn,colorItemBgSelectedHorizontal:"transparent",horizontalItemSelectedBg:"transparent",colorActiveBarWidth:0,activeBarWidth:0,colorActiveBarHeight:Ge,activeBarHeight:Ge,colorActiveBarBorderSize:qe,activeBarBorderWidth:qe,colorItemTextDisabled:ne,itemDisabledColor:ne,colorDangerItemText:Pe,dangerItemColor:Pe,colorDangerItemTextHover:Pe,dangerItemHoverColor:Pe,colorDangerItemTextSelected:Pe,dangerItemSelectedColor:Pe,colorDangerItemBgActive:_t,dangerItemActiveBg:_t,colorDangerItemBgSelected:_t,dangerItemSelectedBg:_t,itemMarginInline:yt.marginXXS,horizontalItemBorderRadius:0,horizontalItemHoverBg:"transparent",itemHeight:pn,groupTitleLineHeight:Yn,collapsedWidth:pn*2,popupBg:ni,itemMarginBlock:Un,itemPaddingInline:gi,horizontalLineHeight:`${pn*1.15}px`,iconSize:mi,iconMarginInlineEnd:$i-mi,collapsedIconSize:Mi,groupTitleFontSize:mi,darkItemDisabledColor:new Yt.C(eo).setAlpha(.25).toRgbString(),darkItemColor:Ao,darkDangerItemColor:Pe,darkItemBg:"#001529",darkSubMenuItemBg:"#000c17",darkItemSelectedColor:eo,darkItemSelectedBg:ae,darkDangerItemSelectedBg:Pe,darkItemHoverBg:"transparent",darkGroupTitleColor:Ao,darkItemHoverColor:eo,darkDangerItemHoverColor:Io,darkDangerItemSelectedColor:eo,darkDangerItemActiveBg:Pe}},{deprecatedTokens:[["colorGroupTitle","groupTitleColor"],["radiusItem","itemBorderRadius"],["radiusSubMenuItem","subMenuItemBorderRadius"],["colorItemText","itemColor"],["colorItemTextHover","itemHoverColor"],["colorItemTextHoverHorizontal","horizontalItemHoverColor"],["colorItemTextSelected","itemSelectedColor"],["colorItemTextSelectedHorizontal","horizontalItemSelectedColor"],["colorItemTextDisabled","itemDisabledColor"],["colorDangerItemText","dangerItemColor"],["colorDangerItemTextHover","dangerItemHoverColor"],["colorDangerItemTextSelected","dangerItemSelectedColor"],["colorDangerItemBgActive","dangerItemActiveBg"],["colorDangerItemBgSelected","dangerItemSelectedBg"],["colorItemBg","itemBg"],["colorItemBgHover","itemHoverBg"],["colorSubItemBg","subMenuItemBg"],["colorItemBgActive","itemActiveBg"],["colorItemBgSelectedHorizontal","horizontalItemSelectedBg"],["colorActiveBarWidth","activeBarWidth"],["colorActiveBarHeight","activeBarHeight"],["colorActiveBarBorderSize","activeBarBorderWidth"],["colorItemBgSelected","itemSelectedBg"]]})(St),we=function(St,Et){var Bt={};for(var yt in St)Object.prototype.hasOwnProperty.call(St,yt)&&Et.indexOf(yt)<0&&(Bt[yt]=St[yt]);if(St!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ae=0,yt=Object.getOwnPropertySymbols(St);ae{var Bt,yt;const ae=Ht.useContext(Tt.Z),Pe=ae||{},{getPrefixCls:ne,getPopupContainer:_t,direction:ge,menu:pe}=Ht.useContext(qt.E_),le=ne(),{prefixCls:Me,className:nn,style:qe,theme:Ge="light",expandIcon:yn,_internalDisableMenuItemTitleTooltip:wn,inlineCollapsed:pn,siderCollapsed:Yn,items:ni,children:Un,rootClassName:gi,mode:mi,selectable:$i,onClick:Mi,overflowedIndicatorPopupClassName:eo}=St,Io=we(St,["prefixCls","className","style","theme","expandIcon","_internalDisableMenuItemTitleTooltip","inlineCollapsed","siderCollapsed","items","children","rootClassName","mode","selectable","onClick","overflowedIndicatorPopupClassName"]),Ao=(0,Fe.Z)(Io,["collapsedWidth"]),$n=ie(ni)||Un;(Bt=Pe.validator)===null||Bt===void 0||Bt.call(Pe,{mode:mi});const Kn=(0,Pt.useEvent)(function(){var sr;Mi==null||Mi.apply(void 0,arguments),(sr=Pe.onClick)===null||sr===void 0||sr.call(Pe)}),jn=Pe.mode||mi,ii=$i!=null?$i:Pe.selectable,Vi=Ht.useMemo(()=>Yn!==void 0?Yn:pn,[pn,Yn]),wi={horizontal:{motionName:`${le}-slide-up`},inline:(0,kt.Z)(le),other:{motionName:`${le}-zoom-big`}},bt=ne("menu",Me||Pe.prefixCls),[no,Ni]=Tn(bt,!ae),ho=Vt()(`${bt}-${Ge}`,pe==null?void 0:pe.className,nn);let pr;if(typeof yn=="function")pr=yn;else if(yn===null||yn===!1)pr=null;else if(Pe.expandIcon===null||Pe.expandIcon===!1)pr=null;else{const sr=yn!=null?yn:Pe.expandIcon;pr=(0,Re.Tm)(sr,{className:Vt()(`${bt}-submenu-expand-icon`,(0,Re.l$)(sr)?(yt=sr.props)===null||yt===void 0?void 0:yt.className:"")})}const ar=Ht.useMemo(()=>({prefixCls:bt,inlineCollapsed:Vi||!1,direction:ge,firstLevel:!0,theme:Ge,mode:jn,disableMenuItemTitleTooltip:wn}),[bt,Vi,ge,wn,Ge]);return no(Ht.createElement(Tt.Z.Provider,{value:null},Ht.createElement(et.Provider,{value:ar},Ht.createElement(Ft.ZP,Object.assign({getPopupContainer:_t,overflowedIndicator:Ht.createElement(mt.Z,null),overflowedIndicatorPopupClassName:Vt()(bt,`${bt}-${Ge}`,eo),mode:jn,selectable:ii,onClick:Kn},Ao,{inlineCollapsed:Vi,style:Object.assign(Object.assign({},pe==null?void 0:pe.style),qe),className:ho,prefixCls:bt,direction:ge,defaultMotions:wi,expandIcon:pr,ref:Et,rootClassName:Vt()(gi,Ni)}),$n))))});const Rt=(0,Ht.forwardRef)((St,Et)=>{const Bt=(0,Ht.useRef)(null),yt=Ht.useContext(oe.D);return(0,Ht.useImperativeHandle)(Et,()=>({menu:Bt.current,focus:ae=>{var Pe;(Pe=Bt.current)===null||Pe===void 0||Pe.focus(ae)}})),Ht.createElement(Jn,Object.assign({ref:Bt},St,yt))});Rt.Item=dt,Rt.SubMenu=gt,Rt.Divider=be,Rt.ItemGroup=Ft.BW;var Lt=Rt},58421:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Pe}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M272.9 512l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L186.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H532c6.7 0 10.4-7.7 6.3-12.9L272.9 512zm304 0l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L490.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H836c6.7 0 10.4-7.7 6.3-12.9L576.9 512z"}}]},name:"double-left",theme:"outlined"},ke=oe,Vt=wt(7657),qt=function(_t,ge){return Ht.createElement(Vt.Z,(0,Ft.Z)({},_t,{ref:ge,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt,be=wt(49198),Qt=wt(33853),Fe=wt(38819),ye=wt(92310),Re=wt.n(ye),It=wt(90493),et=wt(44127),nt=wt(52884),dt=wt(95727),at=wt(65711),gt=wt(85745),mt=wt(26112),Pt={ZERO:48,NINE:57,NUMPAD_ZERO:96,NUMPAD_NINE:105,BACKSPACE:8,DELETE:46,ENTER:13,ARROW_UP:38,ARROW_DOWN:40},kt=Pt,Tt=wt(91735),Dt=function(ne){(0,at.Z)(ge,ne);var _t=(0,gt.Z)(ge);function ge(){var pe;(0,nt.Z)(this,ge);for(var le=arguments.length,Me=new Array(le),nn=0;nn=0||qe.relatedTarget.className.indexOf("".concat(pn,"-item"))>=0))&&wn(pe.getValidValue()))},pe.go=function(qe){var Ge=pe.state.goInputText;Ge!==""&&(qe.keyCode===kt.ENTER||qe.type==="click")&&(pe.setState({goInputText:""}),pe.props.quickGo(pe.getValidValue()))},pe}return(0,dt.Z)(ge,[{key:"getPageSizeOptions",value:function(){var le=this.props,Me=le.pageSize,nn=le.pageSizeOptions;return nn.some(function(qe){return qe.toString()===Me.toString()})?nn:nn.concat([Me.toString()]).sort(function(qe,Ge){var yn=Number.isNaN(Number(qe))?0:Number(qe),wn=Number.isNaN(Number(Ge))?0:Number(Ge);return yn-wn})}},{key:"render",value:function(){var le=this,Me=this.props,nn=Me.pageSize,qe=Me.locale,Ge=Me.rootPrefixCls,yn=Me.changeSize,wn=Me.quickGo,pn=Me.goButton,Yn=Me.selectComponentClass,ni=Me.buildOptionText,Un=Me.selectPrefixCls,gi=Me.disabled,mi=this.state.goInputText,$i="".concat(Ge,"-options"),Mi=Yn,eo=null,Io=null,Ao=null;if(!yn&&!wn)return null;var $n=this.getPageSizeOptions();if(yn&&Mi){var Kn=$n.map(function(jn,ii){return Ht.createElement(Mi.Option,{key:ii,value:jn.toString()},(ni||le.buildOptionText)(jn))});eo=Ht.createElement(Mi,{disabled:gi,prefixCls:Un,showSearch:!1,className:"".concat($i,"-size-changer"),optionLabelProp:"children",popupMatchSelectWidth:!1,value:(nn||$n[0]).toString(),onChange:this.changeSize,getPopupContainer:function(ii){return ii.parentNode},"aria-label":qe.page_size,defaultOpen:!1},Kn)}return wn&&(pn&&(Ao=typeof pn=="boolean"?Ht.createElement("button",{type:"button",onClick:this.go,onKeyUp:this.go,disabled:gi,className:"".concat($i,"-quick-jumper-button")},qe.jump_to_confirm):Ht.createElement("span",{onClick:this.go,onKeyUp:this.go},pn)),Io=Ht.createElement("div",{className:"".concat($i,"-quick-jumper")},qe.jump_to,Ht.createElement("input",{disabled:gi,type:"text",value:mi,onChange:this.handleChange,onKeyUp:this.go,onBlur:this.handleBlur,"aria-label":qe.page}),qe.page,Ao)),Ht.createElement("li",{className:"".concat($i)},eo,Io)}}]),ge}(Ht.Component);Dt.defaultProps={pageSizeOptions:["10","20","50","100"]};var $t=Dt,ie=function(_t){var ge,pe=_t.rootPrefixCls,le=_t.page,Me=_t.active,nn=_t.className,qe=_t.showTitle,Ge=_t.onClick,yn=_t.onKeyPress,wn=_t.itemRender,pn="".concat(pe,"-item"),Yn=Re()(pn,"".concat(pn,"-").concat(le),(ge={},(0,It.Z)(ge,"".concat(pn,"-active"),Me),(0,It.Z)(ge,"".concat(pn,"-disabled"),!le),(0,It.Z)(ge,_t.className,nn),ge)),ni=function(){Ge(le)},Un=function($i){yn($i,Ge,le)},gi=wn(le,"page",Ht.createElement("a",{rel:"nofollow"},le));return gi?Ht.createElement("li",{title:qe?le.toString():null,className:Yn,onClick:ni,onKeyPress:Un,tabIndex:0},gi):null},Yt=ie;function fe(){}function Zt(ne){var _t=Number(ne);return typeof _t=="number"&&!Number.isNaN(_t)&&isFinite(_t)&&Math.floor(_t)===_t}var je=function(_t,ge,pe){return pe};function me(ne,_t,ge){var pe=typeof ne=="undefined"?_t.pageSize:ne;return Math.floor((ge.total-1)/pe)+1}var Xe=function(ne){(0,at.Z)(ge,ne);var _t=(0,gt.Z)(ge);function ge(pe){var le;(0,nt.Z)(this,ge),le=_t.call(this,pe),le.paginationNode=Ht.createRef(),le.getJumpPrevPage=function(){return Math.max(1,le.state.current-(le.props.showLessItems?3:5))},le.getJumpNextPage=function(){return Math.min(me(void 0,le.state,le.props),le.state.current+(le.props.showLessItems?3:5))},le.getItemIcon=function(yn,wn){var pn=le.props.prefixCls,Yn=yn||Ht.createElement("button",{type:"button","aria-label":wn,className:"".concat(pn,"-item-link")});return typeof yn=="function"&&(Yn=Ht.createElement(yn,(0,et.Z)({},le.props))),Yn},le.isValid=function(yn){var wn=le.props.total;return Zt(yn)&&yn!==le.state.current&&Zt(wn)&&wn>0},le.shouldDisplayQuickJumper=function(){var yn=le.props,wn=yn.showQuickJumper,pn=yn.total,Yn=le.state.pageSize;return pn<=Yn?!1:wn},le.handleKeyDown=function(yn){(yn.keyCode===kt.ARROW_UP||yn.keyCode===kt.ARROW_DOWN)&&yn.preventDefault()},le.handleKeyUp=function(yn){var wn=le.getValidValue(yn),pn=le.state.currentInputValue;wn!==pn&&le.setState({currentInputValue:wn}),yn.keyCode===kt.ENTER?le.handleChange(wn):yn.keyCode===kt.ARROW_UP?le.handleChange(wn-1):yn.keyCode===kt.ARROW_DOWN&&le.handleChange(wn+1)},le.handleBlur=function(yn){var wn=le.getValidValue(yn);le.handleChange(wn)},le.changePageSize=function(yn){var wn=le.state.current,pn=me(yn,le.state,le.props);wn=wn>pn?pn:wn,pn===0&&(wn=le.state.current),typeof yn=="number"&&("pageSize"in le.props||le.setState({pageSize:yn}),"current"in le.props||le.setState({current:wn,currentInputValue:wn})),le.props.onShowSizeChange(wn,yn),"onChange"in le.props&&le.props.onChange&&le.props.onChange(wn,yn)},le.handleChange=function(yn){var wn=le.props,pn=wn.disabled,Yn=wn.onChange,ni=le.state,Un=ni.pageSize,gi=ni.current,mi=ni.currentInputValue;if(le.isValid(yn)&&!pn){var $i=me(void 0,le.state,le.props),Mi=yn;return yn>$i?Mi=$i:yn<1&&(Mi=1),"current"in le.props||le.setState({current:Mi}),Mi!==mi&&le.setState({currentInputValue:Mi}),Yn(Mi,Un),Mi}return gi},le.prev=function(){le.hasPrev()&&le.handleChange(le.state.current-1)},le.next=function(){le.hasNext()&&le.handleChange(le.state.current+1)},le.jumpPrev=function(){le.handleChange(le.getJumpPrevPage())},le.jumpNext=function(){le.handleChange(le.getJumpNextPage())},le.hasPrev=function(){return le.state.current>1},le.hasNext=function(){return le.state.current2?pn-2:0),ni=2;ni=nn?Ge=nn:Ge=Number(Me),Ge}},{key:"getShowSizeChanger",value:function(){var le=this.props,Me=le.showSizeChanger,nn=le.total,qe=le.totalBoundaryShowSizeChanger;return typeof Me!="undefined"?Me:nn>qe}},{key:"render",value:function(){var le=this.props,Me=le.prefixCls,nn=le.className,qe=le.style,Ge=le.disabled,yn=le.hideOnSinglePage,wn=le.total,pn=le.locale,Yn=le.showQuickJumper,ni=le.showLessItems,Un=le.showTitle,gi=le.showTotal,mi=le.simple,$i=le.itemRender,Mi=le.showPrevNextJumpers,eo=le.jumpPrevIcon,Io=le.jumpNextIcon,Ao=le.selectComponentClass,$n=le.selectPrefixCls,Kn=le.pageSizeOptions,jn=this.state,ii=jn.current,Vi=jn.pageSize,wi=jn.currentInputValue;if(yn===!0&&wn<=Vi)return null;var bt=me(void 0,this.state,this.props),no=[],Ni=null,ho=null,pr=null,ar=null,sr=null,Fo=Yn&&Yn.goButton,nr=ni?1:2,_e=ii-1>0?ii-1:0,We=ii+1wn?wn:ii*Vi]));if(mi){Fo&&(typeof Fo=="boolean"?sr=Ht.createElement("button",{type:"button",onClick:this.handleGoTO,onKeyUp:this.handleGoTO},pn.jump_to_confirm):sr=Ht.createElement("span",{onClick:this.handleGoTO,onKeyUp:this.handleGoTO},Fo),sr=Ht.createElement("li",{title:Un?"".concat(pn.jump_to).concat(ii,"/").concat(bt):null,className:"".concat(Me,"-simple-pager")},sr));var Mn=this.renderPrev(_e);return Ht.createElement("ul",(0,Ft.Z)({className:Re()(Me,"".concat(Me,"-simple"),(0,It.Z)({},"".concat(Me,"-disabled"),Ge),nn),style:qe,ref:this.paginationNode},Jt),on,Mn?Ht.createElement("li",{title:Un?pn.prev_page:null,onClick:this.prev,tabIndex:this.hasPrev()?0:null,onKeyPress:this.runIfEnterPrev,className:Re()("".concat(Me,"-prev"),(0,It.Z)({},"".concat(Me,"-disabled"),!this.hasPrev())),"aria-disabled":!this.hasPrev()},Mn):null,Ht.createElement("li",{title:Un?"".concat(ii,"/").concat(bt):null,className:"".concat(Me,"-simple-pager")},Ht.createElement("input",{type:"text",value:wi,disabled:Ge,onKeyDown:this.handleKeyDown,onKeyUp:this.handleKeyUp,onChange:this.handleKeyUp,onBlur:this.handleBlur,size:3}),Ht.createElement("span",{className:"".concat(Me,"-slash")},"/"),bt),Ht.createElement("li",{title:Un?pn.next_page:null,onClick:this.next,tabIndex:this.hasPrev()?0:null,onKeyPress:this.runIfEnterNext,className:Re()("".concat(Me,"-next"),(0,It.Z)({},"".concat(Me,"-disabled"),!this.hasNext())),"aria-disabled":!this.hasNext()},this.renderNext(We)),sr)}if(bt<=3+nr*2){var Le={locale:pn,rootPrefixCls:Me,onClick:this.handleChange,onKeyPress:this.runIfEnter,showTitle:Un,itemRender:$i};bt||no.push(Ht.createElement(Yt,(0,Ft.Z)({},Le,{key:"noPager",page:1,className:"".concat(Me,"-item-disabled")})));for(var ue=1;ue<=bt;ue+=1){var Je=ii===ue;no.push(Ht.createElement(Yt,(0,Ft.Z)({},Le,{key:ue,page:ue,active:Je})))}}else{var gn=ni?pn.prev_3:pn.prev_5,Xn=ni?pn.next_3:pn.next_5,Gn=$i(this.getJumpPrevPage(),"jump-prev",this.getItemIcon(eo,"prev page")),ce=$i(this.getJumpNextPage(),"jump-next",this.getItemIcon(Io,"next page"));Mi&&(Ni=Gn?Ht.createElement("li",{title:Un?gn:null,key:"prev",onClick:this.jumpPrev,tabIndex:0,onKeyPress:this.runIfEnterJumpPrev,className:Re()("".concat(Me,"-jump-prev"),(0,It.Z)({},"".concat(Me,"-jump-prev-custom-icon"),!!eo))},Gn):null,ho=ce?Ht.createElement("li",{title:Un?Xn:null,key:"next",tabIndex:0,onClick:this.jumpNext,onKeyPress:this.runIfEnterJumpNext,className:Re()("".concat(Me,"-jump-next"),(0,It.Z)({},"".concat(Me,"-jump-next-custom-icon"),!!Io))},ce):null),ar=Ht.createElement(Yt,{locale:pn,last:!0,rootPrefixCls:Me,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:bt,page:bt,active:!1,showTitle:Un,itemRender:$i}),pr=Ht.createElement(Yt,{locale:pn,rootPrefixCls:Me,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:1,page:1,active:!1,showTitle:Un,itemRender:$i});var vn=Math.max(1,ii-nr),An=Math.min(ii+nr,bt);ii-1<=nr&&(An=1+nr*2),bt-ii<=nr&&(vn=bt-nr*2);for(var xi=vn;xi<=An;xi+=1){var Ae=ii===xi;no.push(Ht.createElement(Yt,{locale:pn,rootPrefixCls:Me,onClick:this.handleChange,onKeyPress:this.runIfEnter,key:xi,page:xi,active:Ae,showTitle:Un,itemRender:$i}))}ii-1>=nr*2&&ii!==3&&(no[0]=(0,Ht.cloneElement)(no[0],{className:"".concat(Me,"-item-after-jump-prev")}),no.unshift(Ni)),bt-ii>=nr*2&&ii!==bt-2&&(no[no.length-1]=(0,Ht.cloneElement)(no[no.length-1],{className:"".concat(Me,"-item-before-jump-next")}),no.push(ho)),vn!==1&&no.unshift(pr),An!==bt&&no.push(ar)}var en=!this.hasPrev()||!bt,ui=!this.hasNext()||!bt,oi=this.renderPrev(_e),Si=this.renderNext(We);return Ht.createElement("ul",(0,Ft.Z)({className:Re()(Me,nn,(0,It.Z)({},"".concat(Me,"-disabled"),Ge)),style:qe,ref:this.paginationNode},Jt),on,oi?Ht.createElement("li",{title:Un?pn.prev_page:null,onClick:this.prev,tabIndex:en?null:0,onKeyPress:this.runIfEnterPrev,className:Re()("".concat(Me,"-prev"),(0,It.Z)({},"".concat(Me,"-disabled"),en)),"aria-disabled":en},oi):null,no,Si?Ht.createElement("li",{title:Un?pn.next_page:null,onClick:this.next,tabIndex:ui?null:0,onKeyPress:this.runIfEnterNext,className:Re()("".concat(Me,"-next"),(0,It.Z)({},"".concat(Me,"-disabled"),ui)),"aria-disabled":ui},Si):null,Ht.createElement($t,{disabled:Ge,locale:pn,rootPrefixCls:Me,selectComponentClass:Ao,selectPrefixCls:$n,changeSize:this.getShowSizeChanger()?this.changePageSize:null,current:ii,pageSize:Vi,pageSizeOptions:Kn,quickGo:this.shouldDisplayQuickJumper()?this.handleChange:null,goButton:Fo}))}}],[{key:"getDerivedStateFromProps",value:function(le,Me){var nn={};if("current"in le&&(nn.current=le.current,le.current!==Me.current&&(nn.currentInputValue=nn.current)),"pageSize"in le&&le.pageSize!==Me.pageSize){var qe=Me.current,Ge=me(le.pageSize,Me,le);qe=qe>Ge?Ge:qe,"current"in le||(nn.current=qe,nn.currentInputValue=qe),nn.pageSize=le.pageSize}return nn}}]),ge}(Ht.Component);Xe.defaultProps={defaultCurrent:1,total:0,defaultPageSize:10,onChange:fe,className:"",selectPrefixCls:"rc-select",prefixCls:"rc-pagination",selectComponentClass:null,hideOnSinglePage:!1,showPrevNextJumpers:!0,showQuickJumper:!1,showLessItems:!1,showTitle:!0,onShowSizeChange:fe,locale:Tt.Z,style:{},itemRender:je,totalBoundaryShowSizeChanger:50};var Se=Xe,Ie=wt(22075),ze=wt(36355),Ue=wt(19716),se=wt(8628),jt=wt(9763),$e=wt(57809);const xn=ne=>Ht.createElement($e.default,Object.assign({},ne,{showSearch:!0,size:"small"})),En=ne=>Ht.createElement($e.default,Object.assign({},ne,{showSearch:!0,size:"middle"}));xn.Option=$e.default.Option,En.Option=$e.default.Option;var Ne=wt(9937),Ze=wt(17313),rn=wt(83116),zn=wt(37613);const tn=ne=>{const{componentCls:_t}=ne;return{[`${_t}-disabled`]:{"&, &:hover":{cursor:"not-allowed",[`${_t}-item-link`]:{color:ne.colorTextDisabled,cursor:"not-allowed"}},"&:focus-visible":{cursor:"not-allowed",[`${_t}-item-link`]:{color:ne.colorTextDisabled,cursor:"not-allowed"}}},[`&${_t}-disabled`]:{cursor:"not-allowed",[`${_t}-item`]:{cursor:"not-allowed","&:hover, &:active":{backgroundColor:"transparent"},a:{color:ne.colorTextDisabled,backgroundColor:"transparent",border:"none",cursor:"not-allowed"},"&-active":{borderColor:ne.colorBorder,backgroundColor:ne.itemActiveBgDisabled,"&:hover, &:active":{backgroundColor:ne.itemActiveBgDisabled},a:{color:ne.itemActiveColorDisabled}}},[`${_t}-item-link`]:{color:ne.colorTextDisabled,cursor:"not-allowed","&:hover, &:active":{backgroundColor:"transparent"},[`${_t}-simple&`]:{backgroundColor:"transparent","&:hover, &:active":{backgroundColor:"transparent"}}},[`${_t}-simple-pager`]:{color:ne.colorTextDisabled},[`${_t}-jump-prev, ${_t}-jump-next`]:{[`${_t}-item-link-icon`]:{opacity:0},[`${_t}-item-ellipsis`]:{opacity:1}}},[`&${_t}-simple`]:{[`${_t}-prev, ${_t}-next`]:{[`&${_t}-disabled ${_t}-item-link`]:{"&:hover, &:active":{backgroundColor:"transparent"}}}}}},Tn=ne=>{const{componentCls:_t}=ne;return{[`&${_t}-mini ${_t}-total-text, &${_t}-mini ${_t}-simple-pager`]:{height:ne.itemSizeSM,lineHeight:`${ne.itemSizeSM}px`},[`&${_t}-mini ${_t}-item`]:{minWidth:ne.itemSizeSM,height:ne.itemSizeSM,margin:0,lineHeight:`${ne.itemSizeSM-2}px`},[`&${_t}-mini:not(${_t}-disabled) ${_t}-item:not(${_t}-item-active)`]:{backgroundColor:"transparent",borderColor:"transparent","&:hover":{backgroundColor:ne.colorBgTextHover},"&:active":{backgroundColor:ne.colorBgTextActive}},[`&${_t}-mini ${_t}-prev, &${_t}-mini ${_t}-next`]:{minWidth:ne.itemSizeSM,height:ne.itemSizeSM,margin:0,lineHeight:`${ne.itemSizeSM}px`},[`&${_t}-mini:not(${_t}-disabled)`]:{[`${_t}-prev, ${_t}-next`]:{[`&:hover ${_t}-item-link`]:{backgroundColor:ne.colorBgTextHover},[`&:active ${_t}-item-link`]:{backgroundColor:ne.colorBgTextActive},[`&${_t}-disabled:hover ${_t}-item-link`]:{backgroundColor:"transparent"}}},[` &${_t}-mini ${_t}-prev ${_t}-item-link, &${_t}-mini ${_t}-next ${_t}-item-link `]:{backgroundColor:"transparent",borderColor:"transparent","&::after":{height:ne.itemSizeSM,lineHeight:`${ne.itemSizeSM}px`}},[`&${_t}-mini ${_t}-jump-prev, &${_t}-mini ${_t}-jump-next`]:{height:ne.itemSizeSM,marginInlineEnd:0,lineHeight:`${ne.itemSizeSM}px`},[`&${_t}-mini ${_t}-options`]:{marginInlineStart:ne.paginationMiniOptionsMarginInlineStart,"&-size-changer":{top:ne.miniOptionsSizeChangerTop},"&-quick-jumper":{height:ne.itemSizeSM,lineHeight:`${ne.itemSizeSM}px`,input:Object.assign(Object.assign({},(0,Ne.x0)(ne)),{width:ne.paginationMiniQuickJumperInputWidth,height:ne.controlHeightSM})}}}},we=ne=>{const{componentCls:_t}=ne;return{[` &${_t}-simple ${_t}-prev, &${_t}-simple ${_t}-next `]:{height:ne.itemSizeSM,lineHeight:`${ne.itemSizeSM}px`,verticalAlign:"top",[`${_t}-item-link`]:{height:ne.itemSizeSM,backgroundColor:"transparent",border:0,"&:hover":{backgroundColor:ne.colorBgTextHover},"&:active":{backgroundColor:ne.colorBgTextActive},"&::after":{height:ne.itemSizeSM,lineHeight:`${ne.itemSizeSM}px`}}},[`&${_t}-simple ${_t}-simple-pager`]:{display:"inline-block",height:ne.itemSizeSM,marginInlineEnd:ne.marginXS,input:{boxSizing:"border-box",height:"100%",marginInlineEnd:ne.marginXS,padding:`0 ${ne.paginationItemPaddingInline}px`,textAlign:"center",backgroundColor:ne.itemInputBg,border:`${ne.lineWidth}px ${ne.lineType} ${ne.colorBorder}`,borderRadius:ne.borderRadius,outline:"none",transition:`border-color ${ne.motionDurationMid}`,color:"inherit","&:hover":{borderColor:ne.colorPrimary},"&:focus":{borderColor:ne.colorPrimaryHover,boxShadow:`${ne.inputOutlineOffset}px 0 ${ne.controlOutlineWidth}px ${ne.controlOutline}`},"&[disabled]":{color:ne.colorTextDisabled,backgroundColor:ne.colorBgContainerDisabled,borderColor:ne.colorBorder,cursor:"not-allowed"}}}}},Bn=ne=>{const{componentCls:_t}=ne;return{[`${_t}-jump-prev, ${_t}-jump-next`]:{outline:0,[`${_t}-item-container`]:{position:"relative",[`${_t}-item-link-icon`]:{color:ne.colorPrimary,fontSize:ne.fontSizeSM,opacity:0,transition:`all ${ne.motionDurationMid}`,"&-svg":{top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,margin:"auto"}},[`${_t}-item-ellipsis`]:{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,display:"block",margin:"auto",color:ne.colorTextDisabled,fontFamily:"Arial, Helvetica, sans-serif",letterSpacing:ne.paginationEllipsisLetterSpacing,textAlign:"center",textIndent:ne.paginationEllipsisTextIndent,opacity:1,transition:`all ${ne.motionDurationMid}`}},"&:hover":{[`${_t}-item-link-icon`]:{opacity:1},[`${_t}-item-ellipsis`]:{opacity:0}}},[` ${_t}-prev, ${_t}-jump-prev, ${_t}-jump-next `]:{marginInlineEnd:ne.marginXS},[` ${_t}-prev, ${_t}-next, ${_t}-jump-prev, ${_t}-jump-next `]:{display:"inline-block",minWidth:ne.itemSize,height:ne.itemSize,color:ne.colorText,fontFamily:ne.fontFamily,lineHeight:`${ne.itemSize}px`,textAlign:"center",verticalAlign:"middle",listStyle:"none",borderRadius:ne.borderRadius,cursor:"pointer",transition:`all ${ne.motionDurationMid}`},[`${_t}-prev, ${_t}-next`]:{fontFamily:"Arial, Helvetica, sans-serif",outline:0,button:{color:ne.colorText,cursor:"pointer",userSelect:"none"},[`${_t}-item-link`]:{display:"block",width:"100%",height:"100%",padding:0,fontSize:ne.fontSizeSM,textAlign:"center",backgroundColor:"transparent",border:`${ne.lineWidth}px ${ne.lineType} transparent`,borderRadius:ne.borderRadius,outline:"none",transition:`all ${ne.motionDurationMid}`},[`&:hover ${_t}-item-link`]:{backgroundColor:ne.colorBgTextHover},[`&:active ${_t}-item-link`]:{backgroundColor:ne.colorBgTextActive},[`&${_t}-disabled:hover`]:{[`${_t}-item-link`]:{backgroundColor:"transparent"}}},[`${_t}-slash`]:{marginInlineEnd:ne.paginationSlashMarginInlineEnd,marginInlineStart:ne.paginationSlashMarginInlineStart},[`${_t}-options`]:{display:"inline-block",marginInlineStart:ne.margin,verticalAlign:"middle","&-size-changer.-select":{display:"inline-block",width:"auto"},"&-quick-jumper":{display:"inline-block",height:ne.controlHeight,marginInlineStart:ne.marginXS,lineHeight:`${ne.controlHeight}px`,verticalAlign:"top",input:Object.assign(Object.assign({},(0,Ne.ik)(ne)),{width:ne.controlHeightLG*1.25,height:ne.controlHeight,boxSizing:"border-box",margin:0,marginInlineStart:ne.marginXS,marginInlineEnd:ne.marginXS})}}}},Jn=ne=>{const{componentCls:_t}=ne;return{[`${_t}-item`]:{display:"inline-block",minWidth:ne.itemSize,height:ne.itemSize,marginInlineEnd:ne.marginXS,fontFamily:ne.fontFamily,lineHeight:`${ne.itemSize-2}px`,textAlign:"center",verticalAlign:"middle",listStyle:"none",backgroundColor:"transparent",border:`${ne.lineWidth}px ${ne.lineType} transparent`,borderRadius:ne.borderRadius,outline:0,cursor:"pointer",userSelect:"none",a:{display:"block",padding:`0 ${ne.paginationItemPaddingInline}px`,color:ne.colorText,"&:hover":{textDecoration:"none"}},[`&:not(${_t}-item-active)`]:{"&:hover":{transition:`all ${ne.motionDurationMid}`,backgroundColor:ne.colorBgTextHover},"&:active":{backgroundColor:ne.colorBgTextActive}},"&-active":{fontWeight:ne.fontWeightStrong,backgroundColor:ne.itemActiveBg,borderColor:ne.colorPrimary,a:{color:ne.colorPrimary},"&:hover":{borderColor:ne.colorPrimaryHover},"&:hover a":{color:ne.colorPrimaryHover}}}}},Rt=ne=>{const{componentCls:_t}=ne;return{[_t]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},(0,Ze.Wf)(ne)),{"ul, ol":{margin:0,padding:0,listStyle:"none"},"&::after":{display:"block",clear:"both",height:0,overflow:"hidden",visibility:"hidden",content:'""'},[`${_t}-total-text`]:{display:"inline-block",height:ne.itemSize,marginInlineEnd:ne.marginXS,lineHeight:`${ne.itemSize-2}px`,verticalAlign:"middle"}}),Jn(ne)),Bn(ne)),we(ne)),Tn(ne)),tn(ne)),{[`@media only screen and (max-width: ${ne.screenLG}px)`]:{[`${_t}-item`]:{"&-after-jump-prev, &-before-jump-next":{display:"none"}}},[`@media only screen and (max-width: ${ne.screenSM}px)`]:{[`${_t}-options`]:{display:"none"}}}),[`&${ne.componentCls}-rtl`]:{direction:"rtl"}}},Lt=ne=>{const{componentCls:_t}=ne;return{[`${_t}${_t}-disabled:not(${_t}-mini)`]:{"&, &:hover":{[`${_t}-item-link`]:{borderColor:ne.colorBorder}},"&:focus-visible":{[`${_t}-item-link`]:{borderColor:ne.colorBorder}},[`${_t}-item, ${_t}-item-link`]:{backgroundColor:ne.colorBgContainerDisabled,borderColor:ne.colorBorder,[`&:hover:not(${_t}-item-active)`]:{backgroundColor:ne.colorBgContainerDisabled,borderColor:ne.colorBorder,a:{color:ne.colorTextDisabled}},[`&${_t}-item-active`]:{backgroundColor:ne.itemActiveBgDisabled}},[`${_t}-prev, ${_t}-next`]:{"&:hover button":{backgroundColor:ne.colorBgContainerDisabled,borderColor:ne.colorBorder,color:ne.colorTextDisabled},[`${_t}-item-link`]:{backgroundColor:ne.colorBgContainerDisabled,borderColor:ne.colorBorder}}},[`${_t}:not(${_t}-mini)`]:{[`${_t}-prev, ${_t}-next`]:{"&:hover button":{borderColor:ne.colorPrimaryHover,backgroundColor:ne.itemBg},[`${_t}-item-link`]:{backgroundColor:ne.itemLinkBg,borderColor:ne.colorBorder},[`&:hover ${_t}-item-link`]:{borderColor:ne.colorPrimary,backgroundColor:ne.itemBg,color:ne.colorPrimary},[`&${_t}-disabled`]:{[`${_t}-item-link`]:{borderColor:ne.colorBorder,color:ne.colorTextDisabled}}},[`${_t}-item`]:{backgroundColor:ne.itemBg,border:`${ne.lineWidth}px ${ne.lineType} ${ne.colorBorder}`,[`&:hover:not(${_t}-item-active)`]:{borderColor:ne.colorPrimary,backgroundColor:ne.itemBg,a:{color:ne.colorPrimary}},"&-active":{borderColor:ne.colorPrimary}}}}},St=ne=>{const{componentCls:_t}=ne;return{[`${_t}:not(${_t}-disabled)`]:{[`${_t}-item`]:Object.assign({},(0,Ze.Qy)(ne)),[`${_t}-jump-prev, ${_t}-jump-next`]:{"&:focus-visible":Object.assign({[`${_t}-item-link-icon`]:{opacity:1},[`${_t}-item-ellipsis`]:{opacity:0}},(0,Ze.oN)(ne))},[`${_t}-prev, ${_t}-next`]:{[`&:focus-visible ${_t}-item-link`]:Object.assign({},(0,Ze.oN)(ne))}}}};var Et=(0,rn.Z)("Pagination",ne=>{const _t=(0,zn.TS)(ne,{inputOutlineOffset:0,paginationMiniOptionsMarginInlineStart:ne.marginXXS/2,paginationMiniQuickJumperInputWidth:ne.controlHeightLG*1.1,paginationItemPaddingInline:ne.marginXXS*1.5,paginationEllipsisLetterSpacing:ne.marginXXS/2,paginationSlashMarginInlineStart:ne.marginXXS,paginationSlashMarginInlineEnd:ne.marginSM,paginationEllipsisTextIndent:"0.13em"},(0,Ne.e5)(ne),(0,Ne.TM)(ne));return[Rt(_t),St(_t),ne.wireframe&&Lt(_t)]},ne=>({itemBg:ne.colorBgContainer,itemSize:ne.controlHeight,itemSizeSM:ne.controlHeightSM,itemActiveBg:ne.colorBgContainer,itemLinkBg:ne.colorBgContainer,itemActiveColorDisabled:ne.colorTextDisabled,itemActiveBgDisabled:ne.controlItemBgActiveDisabled,itemInputBg:ne.colorBgContainer,miniOptionsSizeChangerTop:0})),Bt=function(ne,_t){var ge={};for(var pe in ne)Object.prototype.hasOwnProperty.call(ne,pe)&&_t.indexOf(pe)<0&&(ge[pe]=ne[pe]);if(ne!=null&&typeof Object.getOwnPropertySymbols=="function")for(var le=0,pe=Object.getOwnPropertySymbols(ne);le{const{prefixCls:_t,selectPrefixCls:ge,className:pe,rootClassName:le,style:Me,size:nn,locale:qe,selectComponentClass:Ge,responsive:yn,showSizeChanger:wn}=ne,pn=Bt(ne,["prefixCls","selectPrefixCls","className","rootClassName","style","size","locale","selectComponentClass","responsive","showSizeChanger"]),{xs:Yn}=(0,se.Z)(yn),{getPrefixCls:ni,direction:Un,pagination:gi={}}=Ht.useContext(ze.E_),mi=ni("pagination",_t),[$i,Mi]=Et(mi),eo=wn!=null?wn:gi.showSizeChanger,Io=Ht.useMemo(()=>{const bt=Ht.createElement("span",{className:`${mi}-item-ellipsis`},"\u2022\u2022\u2022"),no=Ht.createElement("button",{className:`${mi}-item-link`,type:"button",tabIndex:-1},Un==="rtl"?Ht.createElement(Fe.Z,null):Ht.createElement(Qt.Z,null)),Ni=Ht.createElement("button",{className:`${mi}-item-link`,type:"button",tabIndex:-1},Un==="rtl"?Ht.createElement(Qt.Z,null):Ht.createElement(Fe.Z,null)),ho=Ht.createElement("a",{className:`${mi}-item-link`},Ht.createElement("div",{className:`${mi}-item-container`},Un==="rtl"?Ht.createElement(be.Z,{className:`${mi}-item-link-icon`}):Ht.createElement(Oe,{className:`${mi}-item-link-icon`}),bt)),pr=Ht.createElement("a",{className:`${mi}-item-link`},Ht.createElement("div",{className:`${mi}-item-container`},Un==="rtl"?Ht.createElement(Oe,{className:`${mi}-item-link-icon`}):Ht.createElement(be.Z,{className:`${mi}-item-link-icon`}),bt));return{prevIcon:no,nextIcon:Ni,jumpPrevIcon:ho,jumpNextIcon:pr}},[Un,mi]),[Ao]=(0,jt.Z)("Pagination",Ie.Z),$n=Object.assign(Object.assign({},Ao),qe),Kn=(0,Ue.Z)(nn),jn=Kn==="small"||!!(Yn&&!Kn&&yn),ii=ni("select",ge),Vi=Re()({[`${mi}-mini`]:jn,[`${mi}-rtl`]:Un==="rtl"},gi==null?void 0:gi.className,pe,le,Mi),wi=Object.assign(Object.assign({},gi==null?void 0:gi.style),Me);return $i(Ht.createElement(Se,Object.assign({},Io,pn,{style:wi,prefixCls:mi,selectPrefixCls:ii,className:Vi,selectComponentClass:Ge||(jn?xn:En),locale:$n,showSizeChanger:eo})))},Pe=ae},57809:function(Cn,cn,wt){"use strict";var Ft=wt(92310),Ht=wt.n(Ft),oe=wt(77861),ke=wt(2738),Vt=wt(59301),qt=wt(53487),Nt=wt(62892),Oe=wt(19080),be=wt(36355),Qt=wt(1684),Fe=wt(93891),ye=wt(19716),Re=wt(32441),It=wt(33234),et=wt(14154),nt=wt(58582),dt=wt(84443),at=wt(66339),gt=function(Dt,$t){var ie={};for(var Yt in Dt)Object.prototype.hasOwnProperty.call(Dt,Yt)&&$t.indexOf(Yt)<0&&(ie[Yt]=Dt[Yt]);if(Dt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var fe=0,Yt=Object.getOwnPropertySymbols(Dt);fe{var ie,{prefixCls:Yt,bordered:fe=!0,className:Zt,rootClassName:je,getPopupContainer:me,popupClassName:Xe,dropdownClassName:Se,listHeight:Ie=256,placement:ze,listItemHeight:Ue=24,size:se,disabled:jt,notFoundContent:$e,status:xn,builtinPlacements:En,dropdownMatchSelectWidth:Ne,popupMatchSelectWidth:Ze,direction:rn,style:zn,allowClear:tn}=Dt,Tn=gt(Dt,["prefixCls","bordered","className","rootClassName","getPopupContainer","popupClassName","dropdownClassName","listHeight","placement","listItemHeight","size","disabled","notFoundContent","status","builtinPlacements","dropdownMatchSelectWidth","popupMatchSelectWidth","direction","style","allowClear"]);const{getPopupContainer:we,getPrefixCls:Bn,renderEmpty:Jn,direction:Rt,virtual:Lt,popupMatchSelectWidth:St,popupOverflow:Et,select:Bt}=Vt.useContext(be.E_),yt=Bn("select",Yt),ae=Bn(),Pe=rn!=null?rn:Rt,{compactSize:ne,compactItemClassnames:_t}=(0,It.ri)(yt,Pe),[ge,pe]=(0,et.Z)(yt),le=Vt.useMemo(()=>{const{mode:wi}=Tn;if(wi!=="combobox")return wi===mt?"combobox":wi},[Tn.mode]),Me=le==="multiple"||le==="tags",nn=(0,dt.Z)(Tn.suffixIcon,Tn.showArrow),qe=(ie=Ze!=null?Ze:Ne)!==null&&ie!==void 0?ie:St,{status:Ge,hasFeedback:yn,isFormItemInput:wn,feedbackIcon:pn}=Vt.useContext(Re.aM),Yn=(0,Oe.F)(Ge,xn);let ni;$e!==void 0?ni=$e:le==="combobox"?ni=null:ni=(Jn==null?void 0:Jn("Select"))||Vt.createElement(Fe.Z,{componentName:"Select"});const{suffixIcon:Un,itemIcon:gi,removeIcon:mi,clearIcon:$i}=(0,at.Z)(Object.assign(Object.assign({},Tn),{multiple:Me,hasFeedback:yn,feedbackIcon:pn,showSuffixIcon:nn,prefixCls:yt,showArrow:Tn.showArrow,componentName:"Select"})),Mi=tn===!0?{clearIcon:$i}:tn,eo=(0,ke.Z)(Tn,["suffixIcon","itemIcon"]),Io=Ht()(Xe||Se,{[`${yt}-dropdown-${Pe}`]:Pe==="rtl"},je,pe),Ao=(0,ye.Z)(wi=>{var bt;return(bt=se!=null?se:ne)!==null&&bt!==void 0?bt:wi}),$n=Vt.useContext(Qt.Z),Kn=jt!=null?jt:$n,jn=Ht()({[`${yt}-lg`]:Ao==="large",[`${yt}-sm`]:Ao==="small",[`${yt}-rtl`]:Pe==="rtl",[`${yt}-borderless`]:!fe,[`${yt}-in-form-item`]:wn},(0,Oe.Z)(yt,Yn,yn),_t,Bt==null?void 0:Bt.className,Zt,je,pe),ii=Vt.useMemo(()=>ze!==void 0?ze:Pe==="rtl"?"bottomRight":"bottomLeft",[ze,Pe]),Vi=(0,nt.Z)(En,Et);return ge(Vt.createElement(oe.ZP,Object.assign({ref:$t,virtual:Lt,showSearch:Bt==null?void 0:Bt.showSearch},eo,{style:Object.assign(Object.assign({},Bt==null?void 0:Bt.style),zn),dropdownMatchSelectWidth:qe,builtinPlacements:Vi,transitionName:(0,Nt.m)(ae,"slide-up",Tn.transitionName),listHeight:Ie,listItemHeight:Ue,mode:le,prefixCls:yt,placement:ii,direction:Pe,suffixIcon:Un,menuItemSelectedIcon:gi,removeIcon:mi,allowClear:Mi,notFoundContent:ni,className:jn,getPopupContainer:me||we,dropdownClassName:Io,disabled:Kn})))},kt=Vt.forwardRef(Pt),Tt=(0,qt.Z)(kt);kt.SECRET_COMBOBOX_MODE_DO_NOT_USE=mt,kt.Option=oe.Wx,kt.OptGroup=oe.Xo,kt._InternalPanelDoNotUseOrYouWillBeFired=Tt,cn.default=kt},14154:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return kt}});var Ft=wt(17313),Ht=wt(74207),oe=wt(37613),ke=wt(83116),Vt=wt(13826),qt=wt(92899);const Nt=Tt=>{const{optionHeight:Dt,optionFontSize:$t,optionLineHeight:ie,optionPadding:Yt}=Tt;return{position:"relative",display:"block",minHeight:Dt,padding:Yt,color:Tt.colorText,fontWeight:"normal",fontSize:$t,lineHeight:ie,boxSizing:"border-box"}};var be=Tt=>{const{antCls:Dt,componentCls:$t}=Tt,ie=`${$t}-item`,Yt=`&${Dt}-slide-up-enter${Dt}-slide-up-enter-active`,fe=`&${Dt}-slide-up-appear${Dt}-slide-up-appear-active`,Zt=`&${Dt}-slide-up-leave${Dt}-slide-up-leave-active`,je=`${$t}-dropdown-placement-`;return[{[`${$t}-dropdown`]:Object.assign(Object.assign({},(0,Ft.Wf)(Tt)),{position:"absolute",top:-9999,zIndex:Tt.zIndexPopup,boxSizing:"border-box",padding:Tt.paddingXXS,overflow:"hidden",fontSize:Tt.fontSize,fontVariant:"initial",backgroundColor:Tt.colorBgElevated,borderRadius:Tt.borderRadiusLG,outline:"none",boxShadow:Tt.boxShadowSecondary,[` ${Yt}${je}bottomLeft, ${fe}${je}bottomLeft `]:{animationName:Vt.fJ},[` ${Yt}${je}topLeft, ${fe}${je}topLeft, ${Yt}${je}topRight, ${fe}${je}topRight `]:{animationName:Vt.Qt},[`${Zt}${je}bottomLeft`]:{animationName:Vt.Uw},[` ${Zt}${je}topLeft, ${Zt}${je}topRight `]:{animationName:Vt.ly},"&-hidden":{display:"none"},[`${ie}`]:Object.assign(Object.assign({},Nt(Tt)),{cursor:"pointer",transition:`background ${Tt.motionDurationSlow} ease`,borderRadius:Tt.borderRadiusSM,"&-group":{color:Tt.colorTextDescription,fontSize:Tt.fontSizeSM,cursor:"default"},"&-option":{display:"flex","&-content":Object.assign({flex:"auto"},Ft.vS),"&-state":{flex:"none",display:"flex",alignItems:"center"},[`&-active:not(${ie}-option-disabled)`]:{backgroundColor:Tt.optionActiveBg},[`&-selected:not(${ie}-option-disabled)`]:{color:Tt.optionSelectedColor,fontWeight:Tt.optionSelectedFontWeight,backgroundColor:Tt.optionSelectedBg,[`${ie}-option-state`]:{color:Tt.colorPrimary}},"&-disabled":{[`&${ie}-option-selected`]:{backgroundColor:Tt.colorBgContainerDisabled},color:Tt.colorTextDisabled,cursor:"not-allowed"},"&-grouped":{paddingInlineStart:Tt.controlPaddingHorizontal*2}}}),"&-rtl":{direction:"rtl"}})},(0,Vt.oN)(Tt,"slide-up"),(0,Vt.oN)(Tt,"slide-down"),(0,qt.Fm)(Tt,"move-up"),(0,qt.Fm)(Tt,"move-down")]};const Qt=2,Fe=Tt=>{let{controlHeightSM:Dt,controlHeight:$t,lineWidth:ie}=Tt;const Yt=($t-Dt)/2-ie,fe=Math.ceil(Yt/2);return[Yt,fe]};function ye(Tt,Dt){const{componentCls:$t,iconCls:ie}=Tt,Yt=`${$t}-selection-overflow`,fe=Tt.multipleSelectItemHeight,[Zt]=Fe(Tt),je=Dt?`${$t}-${Dt}`:"";return{[`${$t}-multiple${je}`]:{fontSize:Tt.fontSize,[Yt]:{position:"relative",display:"flex",flex:"auto",flexWrap:"wrap",maxWidth:"100%","&-item":{flex:"none",alignSelf:"center",maxWidth:"100%",display:"inline-flex"}},[`${$t}-selector`]:{display:"flex",flexWrap:"wrap",alignItems:"center",padding:`${Zt-Qt}px ${Qt*2}px`,borderRadius:Tt.borderRadius,[`${$t}-show-search&`]:{cursor:"text"},[`${$t}-disabled&`]:{background:Tt.multipleSelectorBgDisabled,cursor:"not-allowed"},"&:after":{display:"inline-block",width:0,margin:`${Qt}px 0`,lineHeight:`${fe}px`,visibility:"hidden",content:'"\\a0"'}},[` &${$t}-show-arrow ${$t}-selector, &${$t}-allow-clear ${$t}-selector `]:{paddingInlineEnd:Tt.fontSizeIcon+Tt.controlPaddingHorizontal},[`${$t}-selection-item`]:{position:"relative",display:"flex",flex:"none",boxSizing:"border-box",maxWidth:"100%",height:fe,marginTop:Qt,marginBottom:Qt,lineHeight:`${fe-Tt.lineWidth*2}px`,background:Tt.multipleItemBg,border:`${Tt.lineWidth}px ${Tt.lineType} ${Tt.multipleItemBorderColor}`,borderRadius:Tt.borderRadiusSM,cursor:"default",transition:`font-size ${Tt.motionDurationSlow}, line-height ${Tt.motionDurationSlow}, height ${Tt.motionDurationSlow}`,userSelect:"none",marginInlineEnd:Qt*2,paddingInlineStart:Tt.paddingXS,paddingInlineEnd:Tt.paddingXS/2,[`${$t}-disabled&`]:{color:Tt.multipleItemColorDisabled,borderColor:Tt.multipleItemBorderColorDisabled,cursor:"not-allowed"},"&-content":{display:"inline-block",marginInlineEnd:Tt.paddingXS/2,overflow:"hidden",whiteSpace:"pre",textOverflow:"ellipsis"},"&-remove":Object.assign(Object.assign({},(0,Ft.Ro)()),{display:"inline-flex",alignItems:"center",color:Tt.colorIcon,fontWeight:"bold",fontSize:10,lineHeight:"inherit",cursor:"pointer",[`> ${ie}`]:{verticalAlign:"-0.2em"},"&:hover":{color:Tt.colorIconHover}})},[`${Yt}-item + ${Yt}-item`]:{[`${$t}-selection-search`]:{marginInlineStart:0}},[`${$t}-selection-search`]:{display:"inline-flex",position:"relative",maxWidth:"100%",marginInlineStart:Tt.inputPaddingHorizontalBase-Zt,"\n &-input,\n &-mirror\n ":{height:fe,fontFamily:Tt.fontFamily,lineHeight:`${fe}px`,transition:`all ${Tt.motionDurationSlow}`},"&-input":{width:"100%",minWidth:4.1},"&-mirror":{position:"absolute",top:0,insetInlineStart:0,insetInlineEnd:"auto",zIndex:999,whiteSpace:"pre",visibility:"hidden"}},[`${$t}-selection-placeholder `]:{position:"absolute",top:"50%",insetInlineStart:Tt.inputPaddingHorizontalBase,insetInlineEnd:Tt.inputPaddingHorizontalBase,transform:"translateY(-50%)",transition:`all ${Tt.motionDurationSlow}`}}}}var It=Tt=>{const{componentCls:Dt}=Tt,$t=(0,oe.TS)(Tt,{controlHeight:Tt.controlHeightSM,multipleSelectItemHeight:Tt.controlHeightXS,borderRadius:Tt.borderRadiusSM,borderRadiusSM:Tt.borderRadiusXS}),ie=(0,oe.TS)(Tt,{fontSize:Tt.fontSizeLG,controlHeight:Tt.controlHeightLG,multipleSelectItemHeight:Tt.multipleItemHeightLG,borderRadius:Tt.borderRadiusLG,borderRadiusSM:Tt.borderRadius}),[,Yt]=Fe(Tt);return[ye(Tt),ye($t,"sm"),{[`${Dt}-multiple${Dt}-sm`]:{[`${Dt}-selection-placeholder`]:{insetInline:Tt.controlPaddingHorizontalSM-Tt.lineWidth},[`${Dt}-selection-search`]:{marginInlineStart:Yt}}},ye(ie,"lg")]};function et(Tt,Dt){const{componentCls:$t,inputPaddingHorizontalBase:ie,borderRadius:Yt}=Tt,fe=Tt.controlHeight-Tt.lineWidth*2,Zt=Math.ceil(Tt.fontSize*1.25),je=Dt?`${$t}-${Dt}`:"";return{[`${$t}-single${je}`]:{fontSize:Tt.fontSize,[`${$t}-selector`]:Object.assign(Object.assign({},(0,Ft.Wf)(Tt)),{display:"flex",borderRadius:Yt,[`${$t}-selection-search`]:{position:"absolute",top:0,insetInlineStart:ie,insetInlineEnd:ie,bottom:0,"&-input":{width:"100%"}},[` ${$t}-selection-item, ${$t}-selection-placeholder `]:{padding:0,lineHeight:`${fe}px`,transition:`all ${Tt.motionDurationSlow}, visibility 0s`,"@supports (-moz-appearance: meterbar)":{lineHeight:`${fe}px`}},[`${$t}-selection-item`]:{position:"relative",userSelect:"none"},[`${$t}-selection-placeholder`]:{transition:"none",pointerEvents:"none"},[["&:after",`${$t}-selection-item:after`,`${$t}-selection-placeholder:after`].join(",")]:{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'}}),[` &${$t}-show-arrow ${$t}-selection-item, &${$t}-show-arrow ${$t}-selection-placeholder `]:{paddingInlineEnd:Zt},[`&${$t}-open ${$t}-selection-item`]:{color:Tt.colorTextPlaceholder},[`&:not(${$t}-customize-input)`]:{[`${$t}-selector`]:{width:"100%",height:Tt.controlHeight,padding:`0 ${ie}px`,[`${$t}-selection-search-input`]:{height:fe},"&:after":{lineHeight:`${fe}px`}}},[`&${$t}-customize-input`]:{[`${$t}-selector`]:{"&:after":{display:"none"},[`${$t}-selection-search`]:{position:"static",width:"100%"},[`${$t}-selection-placeholder`]:{position:"absolute",insetInlineStart:0,insetInlineEnd:0,padding:`0 ${ie}px`,"&:after":{display:"none"}}}}}}}function nt(Tt){const{componentCls:Dt}=Tt,$t=Tt.controlPaddingHorizontalSM-Tt.lineWidth;return[et(Tt),et((0,oe.TS)(Tt,{controlHeight:Tt.controlHeightSM,borderRadius:Tt.borderRadiusSM}),"sm"),{[`${Dt}-single${Dt}-sm`]:{[`&:not(${Dt}-customize-input)`]:{[`${Dt}-selection-search`]:{insetInlineStart:$t,insetInlineEnd:$t},[`${Dt}-selector`]:{padding:`0 ${$t}px`},[`&${Dt}-show-arrow ${Dt}-selection-search`]:{insetInlineEnd:$t+Tt.fontSize*1.5},[` &${Dt}-show-arrow ${Dt}-selection-item, &${Dt}-show-arrow ${Dt}-selection-placeholder `]:{paddingInlineEnd:Tt.fontSize*1.5}}}},et((0,oe.TS)(Tt,{controlHeight:Tt.singleItemHeightLG,fontSize:Tt.fontSizeLG,borderRadius:Tt.borderRadiusLG}),"lg")]}const dt=Tt=>{const{componentCls:Dt,selectorBg:$t}=Tt;return{position:"relative",backgroundColor:$t,border:`${Tt.lineWidth}px ${Tt.lineType} ${Tt.colorBorder}`,transition:`all ${Tt.motionDurationMid} ${Tt.motionEaseInOut}`,input:{cursor:"pointer"},[`${Dt}-show-search&`]:{cursor:"text",input:{cursor:"auto",color:"inherit"}},[`${Dt}-disabled&`]:{color:Tt.colorTextDisabled,background:Tt.colorBgContainerDisabled,cursor:"not-allowed",[`${Dt}-multiple&`]:{background:Tt.multipleSelectorBgDisabled},input:{cursor:"not-allowed"}}}},at=function(Tt,Dt){let $t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;const{componentCls:ie,borderHoverColor:Yt,outlineColor:fe,antCls:Zt}=Dt,je=$t?{[`${ie}-selector`]:{borderColor:Yt}}:{};return{[Tt]:{[`&:not(${ie}-disabled):not(${ie}-customize-input):not(${Zt}-pagination-size-changer)`]:Object.assign(Object.assign({},je),{[`${ie}-focused& ${ie}-selector`]:{borderColor:Yt,boxShadow:`0 0 0 ${Dt.controlOutlineWidth}px ${fe}`,outline:0},[`&:hover ${ie}-selector`]:{borderColor:Yt}})}}},gt=Tt=>{const{componentCls:Dt}=Tt;return{[`${Dt}-selection-search-input`]:{margin:0,padding:0,background:"transparent",border:"none",outline:"none",appearance:"none","&::-webkit-search-cancel-button":{display:"none","-webkit-appearance":"none"}}}},mt=Tt=>{const{componentCls:Dt,inputPaddingHorizontalBase:$t,iconCls:ie}=Tt;return{[Dt]:Object.assign(Object.assign({},(0,Ft.Wf)(Tt)),{position:"relative",display:"inline-block",cursor:"pointer",[`&:not(${Dt}-customize-input) ${Dt}-selector`]:Object.assign(Object.assign({},dt(Tt)),gt(Tt)),[`${Dt}-selection-item`]:Object.assign({flex:1,fontWeight:"normal"},Ft.vS),[`${Dt}-selection-placeholder`]:Object.assign(Object.assign({},Ft.vS),{flex:1,color:Tt.colorTextPlaceholder,pointerEvents:"none"}),[`${Dt}-arrow`]:Object.assign(Object.assign({},(0,Ft.Ro)()),{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:$t,height:Tt.fontSizeIcon,marginTop:-Tt.fontSizeIcon/2,color:Tt.colorTextQuaternary,fontSize:Tt.fontSizeIcon,lineHeight:1,textAlign:"center",pointerEvents:"none",display:"flex",alignItems:"center",[ie]:{verticalAlign:"top",transition:`transform ${Tt.motionDurationSlow}`,"> svg":{verticalAlign:"top"},[`&:not(${Dt}-suffix)`]:{pointerEvents:"auto"}},[`${Dt}-disabled &`]:{cursor:"not-allowed"},"> *:not(:last-child)":{marginInlineEnd:8}}),[`${Dt}-clear`]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:$t,zIndex:1,display:"inline-block",width:Tt.fontSizeIcon,height:Tt.fontSizeIcon,marginTop:-Tt.fontSizeIcon/2,color:Tt.colorTextQuaternary,fontSize:Tt.fontSizeIcon,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",background:Tt.clearBg,cursor:"pointer",opacity:0,transition:`color ${Tt.motionDurationMid} ease, opacity ${Tt.motionDurationSlow} ease`,textRendering:"auto","&:before":{display:"block"},"&:hover":{color:Tt.colorTextTertiary}},"&:hover":{[`${Dt}-clear`]:{opacity:1}}}),[`${Dt}-has-feedback`]:{[`${Dt}-clear`]:{insetInlineEnd:$t+Tt.fontSize+Tt.paddingXS}}}},Pt=Tt=>{const{componentCls:Dt}=Tt;return[{[Dt]:{[`&-borderless ${Dt}-selector`]:{backgroundColor:"transparent !important",borderColor:"transparent !important",boxShadow:"none !important"},[`&${Dt}-in-form-item`]:{width:"100%"}}},mt(Tt),nt(Tt),It(Tt),be(Tt),{[`${Dt}-rtl`]:{direction:"rtl"}},at(Dt,(0,oe.TS)(Tt,{borderHoverColor:Tt.colorPrimaryHover,outlineColor:Tt.controlOutline})),at(`${Dt}-status-error`,(0,oe.TS)(Tt,{borderHoverColor:Tt.colorErrorHover,outlineColor:Tt.colorErrorOutline}),!0),at(`${Dt}-status-warning`,(0,oe.TS)(Tt,{borderHoverColor:Tt.colorWarningHover,outlineColor:Tt.colorWarningOutline}),!0),(0,Ht.c)(Tt,{borderElCls:`${Dt}-selector`,focusElCls:`${Dt}-focused`})]};var kt=(0,ke.Z)("Select",(Tt,Dt)=>{let{rootPrefixCls:$t}=Dt;const ie=(0,oe.TS)(Tt,{rootPrefixCls:$t,inputPaddingHorizontalBase:Tt.paddingSM-1,multipleSelectItemHeight:Tt.multipleItemHeight});return[Pt(ie)]},Tt=>{const{fontSize:Dt,lineHeight:$t,controlHeight:ie,controlPaddingHorizontal:Yt,zIndexPopupBase:fe,colorText:Zt,fontWeightStrong:je,controlItemBgActive:me,controlItemBgHover:Xe,colorBgContainer:Se,colorFillSecondary:Ie,controlHeightLG:ze,controlHeightSM:Ue,colorBgContainerDisabled:se,colorTextDisabled:jt}=Tt;return{zIndexPopup:fe+50,optionSelectedColor:Zt,optionSelectedFontWeight:je,optionSelectedBg:me,optionActiveBg:Xe,optionPadding:`${(ie-Dt*$t)/2}px ${Yt}px`,optionFontSize:Dt,optionLineHeight:$t,optionHeight:ie,selectorBg:Se,clearBg:Se,singleItemHeightLG:ze,multipleItemBg:Ie,multipleItemBorderColor:"transparent",multipleItemHeight:Ue,multipleItemHeightLG:ie,multipleSelectorBgDisabled:se,multipleItemColorDisabled:jt,multipleItemBorderColorDisabled:"transparent"}})},58582:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Ht}});const Ft=oe=>{const Vt={overflow:{adjustX:!0,adjustY:!0,shiftY:!0},htmlRegion:oe==="scroll"?"scroll":"visible",_experimental:{dynamicInset:!0}};return{bottomLeft:Object.assign(Object.assign({},Vt),{points:["tl","bl"],offset:[0,4]}),bottomRight:Object.assign(Object.assign({},Vt),{points:["tr","br"],offset:[0,4]}),topLeft:Object.assign(Object.assign({},Vt),{points:["bl","tl"],offset:[0,-4]}),topRight:Object.assign(Object.assign({},Vt),{points:["br","tr"],offset:[0,-4]})}};function Ht(oe,ke){return oe||Ft(ke)}},84443:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Ft}});function Ft(Ht,oe){return oe!==void 0?oe:Ht!==null}},66339:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});var Ft=wt(40001),Ht=wt(19248),oe=wt(99267),ke=wt(84105),Vt=wt(58617),qt=wt(47472),Nt=wt(59301);function Oe(be){let{suffixIcon:Qt,clearIcon:Fe,menuItemSelectedIcon:ye,removeIcon:Re,loading:It,multiple:et,hasFeedback:nt,prefixCls:dt,showSuffixIcon:at,feedbackIcon:gt,showArrow:mt,componentName:Pt}=be;const kt=Fe!=null?Fe:Nt.createElement(Ht.Z,null),Tt=Yt=>Qt===null&&!nt&&!mt?null:Nt.createElement(Nt.Fragment,null,at!==!1&&Yt,nt&>);let Dt=null;if(Qt!==void 0)Dt=Tt(Qt);else if(It)Dt=Tt(Nt.createElement(Vt.Z,{spin:!0}));else{const Yt=`${dt}-suffix`;Dt=fe=>{let{open:Zt,showSearch:je}=fe;return Tt(Zt&&je?Nt.createElement(qt.Z,{className:Yt}):Nt.createElement(ke.Z,{className:Yt}))}}let $t=null;ye!==void 0?$t=ye:et?$t=Nt.createElement(Ft.Z,null):$t=null;let ie=null;return Re!==void 0?ie=Re:ie=Nt.createElement(oe.Z,null),{clearIcon:kt,suffixIcon:Dt,itemIcon:$t,removeIcon:ie}}},81327:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return dt}});var Ft=wt(59301),Ht=wt(92310),oe=wt.n(Ht),ke=wt(11592),Vt=wt(36355),qt=wt(33234);const Nt=Ft.createContext({latestIndex:0}),Oe=Nt.Provider;var Qt=at=>{let{className:gt,index:mt,children:Pt,split:kt,style:Tt}=at;const{latestIndex:Dt}=Ft.useContext(Nt);return Pt==null?null:Ft.createElement(Ft.Fragment,null,Ft.createElement("div",{className:gt,style:Tt},Pt),mt{var mt,Pt;const{getPrefixCls:kt,space:Tt,direction:Dt}=Ft.useContext(Vt.E_),{size:$t=(Tt==null?void 0:Tt.size)||"small",align:ie,className:Yt,rootClassName:fe,children:Zt,direction:je="horizontal",prefixCls:me,split:Xe,style:Se,wrap:Ie=!1,classNames:ze,styles:Ue}=at,se=It(at,["size","align","className","rootClassName","children","direction","prefixCls","split","style","wrap","classNames","styles"]),[jt,$e]=Array.isArray($t)?$t:[$t,$t],xn=ye($e),En=ye(jt),Ne=Re($e),Ze=Re(jt),rn=(0,ke.Z)(Zt,{keepEmpty:!0}),zn=ie===void 0&&je==="horizontal"?"center":ie,tn=kt("space",me),[Tn,we]=(0,Fe.Z)(tn),Bn=oe()(tn,Tt==null?void 0:Tt.className,we,`${tn}-${je}`,{[`${tn}-rtl`]:Dt==="rtl",[`${tn}-align-${zn}`]:zn,[`${tn}-gap-row-${$e}`]:xn,[`${tn}-gap-col-${jt}`]:En},Yt,fe),Jn=oe()(`${tn}-item`,(mt=ze==null?void 0:ze.item)!==null&&mt!==void 0?mt:(Pt=Tt==null?void 0:Tt.classNames)===null||Pt===void 0?void 0:Pt.item);let Rt=0;const Lt=rn.map((Bt,yt)=>{var ae,Pe;Bt!=null&&(Rt=yt);const ne=Bt&&Bt.key||`${Jn}-${yt}`;return Ft.createElement(Qt,{className:Jn,key:ne,index:yt,split:Xe,style:(ae=Ue==null?void 0:Ue.item)!==null&&ae!==void 0?ae:(Pe=Tt==null?void 0:Tt.styles)===null||Pe===void 0?void 0:Pe.item},Bt)}),St=Ft.useMemo(()=>({latestIndex:Rt}),[Rt]);if(rn.length===0)return null;const Et={};return Ie&&(Et.flexWrap="wrap"),!En&&Ze&&(Et.columnGap=jt),!xn&&Ne&&(Et.rowGap=$e),Tn(Ft.createElement("div",Object.assign({ref:gt,className:Bn,style:Object.assign(Object.assign(Object.assign({},Et),Tt==null?void 0:Tt.style),Se)},se),Ft.createElement(Oe,{value:St},Lt)))});nt.Compact=qt.ZP;var dt=nt},15969:function(Cn,cn,wt){"use strict";wt.d(cn,{N:function(){return Ft}});const Ft=Ht=>({color:Ht.colorLink,textDecoration:"none",outline:"none",cursor:"pointer",transition:`color ${Ht.motionDurationSlow}`,"&:focus, &:hover":{color:Ht.colorLinkHover},"&:active":{color:Ht.colorLinkActive}})},78673:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return je}});var Ft=wt(58617),Ht=wt(92310),oe=wt.n(Ht),ke=wt(96663),Vt=wt(90493),qt=wt(72071),Nt=wt(6620),Oe=wt(59301),be=wt(18929),Qt=wt(10228),Fe=["prefixCls","className","checked","defaultChecked","disabled","loadingIcon","checkedChildren","unCheckedChildren","onClick","onChange","onKeyDown"],ye=Oe.forwardRef(function(me,Xe){var Se,Ie=me.prefixCls,ze=Ie===void 0?"rc-switch":Ie,Ue=me.className,se=me.checked,jt=me.defaultChecked,$e=me.disabled,xn=me.loadingIcon,En=me.checkedChildren,Ne=me.unCheckedChildren,Ze=me.onClick,rn=me.onChange,zn=me.onKeyDown,tn=(0,Nt.Z)(me,Fe),Tn=(0,be.Z)(!1,{value:se,defaultValue:jt}),we=(0,qt.Z)(Tn,2),Bn=we[0],Jn=we[1];function Rt(Bt,yt){var ae=Bn;return $e||(ae=Bt,Jn(ae),rn==null||rn(ae,yt)),ae}function Lt(Bt){Bt.which===Qt.Z.LEFT?Rt(!1,Bt):Bt.which===Qt.Z.RIGHT&&Rt(!0,Bt),zn==null||zn(Bt)}function St(Bt){var yt=Rt(!Bn,Bt);Ze==null||Ze(yt,Bt)}var Et=oe()(ze,Ue,(Se={},(0,Vt.Z)(Se,"".concat(ze,"-checked"),Bn),(0,Vt.Z)(Se,"".concat(ze,"-disabled"),$e),Se));return Oe.createElement("button",(0,ke.Z)({},tn,{type:"button",role:"switch","aria-checked":Bn,disabled:$e,className:Et,ref:Xe,onKeyDown:Lt,onClick:St}),xn,Oe.createElement("span",{className:"".concat(ze,"-inner")},Oe.createElement("span",{className:"".concat(ze,"-inner-checked")},En),Oe.createElement("span",{className:"".concat(ze,"-inner-unchecked")},Ne)))});ye.displayName="Switch";var Re=ye,It=wt(14088),et=wt(36355),nt=wt(1684),dt=wt(19716),at=wt(64993),gt=wt(17313),mt=wt(83116),Pt=wt(37613);const kt=me=>{const{componentCls:Xe,trackHeightSM:Se,trackPadding:Ie,trackMinWidthSM:ze,innerMinMarginSM:Ue,innerMaxMarginSM:se,handleSizeSM:jt}=me,$e=`${Xe}-inner`;return{[Xe]:{[`&${Xe}-small`]:{minWidth:ze,height:Se,lineHeight:`${Se}px`,[`${Xe}-inner`]:{paddingInlineStart:se,paddingInlineEnd:Ue,[`${$e}-checked`]:{marginInlineStart:`calc(-100% + ${jt+Ie*2}px - ${se*2}px)`,marginInlineEnd:`calc(100% - ${jt+Ie*2}px + ${se*2}px)`},[`${$e}-unchecked`]:{marginTop:-Se,marginInlineStart:0,marginInlineEnd:0}},[`${Xe}-handle`]:{width:jt,height:jt},[`${Xe}-loading-icon`]:{top:(jt-me.switchLoadingIconSize)/2,fontSize:me.switchLoadingIconSize},[`&${Xe}-checked`]:{[`${Xe}-inner`]:{paddingInlineStart:Ue,paddingInlineEnd:se,[`${$e}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${$e}-unchecked`]:{marginInlineStart:`calc(100% - ${jt+Ie*2}px + ${se*2}px)`,marginInlineEnd:`calc(-100% + ${jt+Ie*2}px - ${se*2}px)`}},[`${Xe}-handle`]:{insetInlineStart:`calc(100% - ${jt+Ie}px)`}},[`&:not(${Xe}-disabled):active`]:{[`&:not(${Xe}-checked) ${$e}`]:{[`${$e}-unchecked`]:{marginInlineStart:me.marginXXS/2,marginInlineEnd:-me.marginXXS/2}},[`&${Xe}-checked ${$e}`]:{[`${$e}-checked`]:{marginInlineStart:-me.marginXXS/2,marginInlineEnd:me.marginXXS/2}}}}}}},Tt=me=>{const{componentCls:Xe,handleSize:Se}=me;return{[Xe]:{[`${Xe}-loading-icon${me.iconCls}`]:{position:"relative",top:(Se-me.fontSize)/2,color:me.switchLoadingIconColor,verticalAlign:"top"},[`&${Xe}-checked ${Xe}-loading-icon`]:{color:me.switchColor}}}},Dt=me=>{const{componentCls:Xe,motion:Se,trackPadding:Ie,handleBg:ze,handleShadow:Ue,handleSize:se}=me,jt=`${Xe}-handle`;return{[Xe]:{[jt]:{position:"absolute",top:Ie,insetInlineStart:Ie,width:se,height:se,transition:`all ${me.switchDuration} ease-in-out`,"&::before":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,backgroundColor:ze,borderRadius:se/2,boxShadow:Ue,transition:`all ${me.switchDuration} ease-in-out`,content:'""'}},[`&${Xe}-checked ${jt}`]:{insetInlineStart:`calc(100% - ${se+Ie}px)`},[`&:not(${Xe}-disabled):active`]:Se?{[`${jt}::before`]:{insetInlineEnd:me.switchHandleActiveInset,insetInlineStart:0},[`&${Xe}-checked ${jt}::before`]:{insetInlineEnd:0,insetInlineStart:me.switchHandleActiveInset}}:{}}}},$t=me=>{const{componentCls:Xe,trackHeight:Se,trackPadding:Ie,innerMinMargin:ze,innerMaxMargin:Ue,handleSize:se}=me,jt=`${Xe}-inner`;return{[Xe]:{[jt]:{display:"block",overflow:"hidden",borderRadius:100,height:"100%",paddingInlineStart:Ue,paddingInlineEnd:ze,transition:`padding-inline-start ${me.switchDuration} ease-in-out, padding-inline-end ${me.switchDuration} ease-in-out`,[`${jt}-checked, ${jt}-unchecked`]:{display:"block",color:me.colorTextLightSolid,fontSize:me.fontSizeSM,transition:`margin-inline-start ${me.switchDuration} ease-in-out, margin-inline-end ${me.switchDuration} ease-in-out`,pointerEvents:"none"},[`${jt}-checked`]:{marginInlineStart:`calc(-100% + ${se+Ie*2}px - ${Ue*2}px)`,marginInlineEnd:`calc(100% - ${se+Ie*2}px + ${Ue*2}px)`},[`${jt}-unchecked`]:{marginTop:-Se,marginInlineStart:0,marginInlineEnd:0}},[`&${Xe}-checked ${jt}`]:{paddingInlineStart:ze,paddingInlineEnd:Ue,[`${jt}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${jt}-unchecked`]:{marginInlineStart:`calc(100% - ${se+Ie*2}px + ${Ue*2}px)`,marginInlineEnd:`calc(-100% + ${se+Ie*2}px - ${Ue*2}px)`}},[`&:not(${Xe}-disabled):active`]:{[`&:not(${Xe}-checked) ${jt}`]:{[`${jt}-unchecked`]:{marginInlineStart:Ie*2,marginInlineEnd:-Ie*2}},[`&${Xe}-checked ${jt}`]:{[`${jt}-checked`]:{marginInlineStart:-Ie*2,marginInlineEnd:Ie*2}}}}}},ie=me=>{const{componentCls:Xe,trackHeight:Se,trackMinWidth:Ie}=me;return{[Xe]:Object.assign(Object.assign(Object.assign(Object.assign({},(0,gt.Wf)(me)),{position:"relative",display:"inline-block",boxSizing:"border-box",minWidth:Ie,height:Se,lineHeight:`${Se}px`,verticalAlign:"middle",background:me.colorTextQuaternary,border:"0",borderRadius:100,cursor:"pointer",transition:`all ${me.motionDurationMid}`,userSelect:"none",[`&:hover:not(${Xe}-disabled)`]:{background:me.colorTextTertiary}}),(0,gt.Qy)(me)),{[`&${Xe}-checked`]:{background:me.switchColor,[`&:hover:not(${Xe}-disabled)`]:{background:me.colorPrimaryHover}},[`&${Xe}-loading, &${Xe}-disabled`]:{cursor:"not-allowed",opacity:me.switchDisabledOpacity,"*":{boxShadow:"none",cursor:"not-allowed"}},[`&${Xe}-rtl`]:{direction:"rtl"}})}};var Yt=(0,mt.Z)("Switch",me=>{const Xe=(0,Pt.TS)(me,{switchDuration:me.motionDurationMid,switchColor:me.colorPrimary,switchDisabledOpacity:me.opacityLoading,switchLoadingIconSize:me.fontSizeIcon*.75,switchLoadingIconColor:`rgba(0, 0, 0, ${me.opacityLoading})`,switchHandleActiveInset:"-30%"});return[ie(Xe),$t(Xe),Dt(Xe),Tt(Xe),kt(Xe)]},me=>{const{fontSize:Xe,lineHeight:Se,controlHeight:Ie,colorWhite:ze}=me,Ue=Xe*Se,se=Ie/2,jt=2,$e=Ue-jt*2,xn=se-jt*2;return{trackHeight:Ue,trackHeightSM:se,trackMinWidth:$e*2+jt*4,trackMinWidthSM:xn*2+jt*2,trackPadding:jt,handleBg:ze,handleSize:$e,handleSizeSM:xn,handleShadow:`0 2px 4px 0 ${new at.C("#00230b").setAlpha(.2).toRgbString()}`,innerMinMargin:$e/2,innerMaxMargin:$e+jt+jt*2,innerMinMarginSM:xn/2,innerMaxMarginSM:xn+jt+jt*2}}),fe=function(me,Xe){var Se={};for(var Ie in me)Object.prototype.hasOwnProperty.call(me,Ie)&&Xe.indexOf(Ie)<0&&(Se[Ie]=me[Ie]);if(me!=null&&typeof Object.getOwnPropertySymbols=="function")for(var ze=0,Ie=Object.getOwnPropertySymbols(me);ze{const{prefixCls:Se,size:Ie,disabled:ze,loading:Ue,className:se,rootClassName:jt,style:$e}=me,xn=fe(me,["prefixCls","size","disabled","loading","className","rootClassName","style"]),{getPrefixCls:En,direction:Ne,switch:Ze}=Oe.useContext(et.E_),rn=Oe.useContext(nt.Z),zn=(ze!=null?ze:rn)||Ue,tn=En("switch",Se),Tn=Oe.createElement("div",{className:`${tn}-handle`},Ue&&Oe.createElement(Ft.Z,{className:`${tn}-loading-icon`})),[we,Bn]=Yt(tn),Jn=(0,dt.Z)(Ie),Rt=oe()(Ze==null?void 0:Ze.className,{[`${tn}-small`]:Jn==="small",[`${tn}-loading`]:Ue,[`${tn}-rtl`]:Ne==="rtl"},se,jt,Bn),Lt=Object.assign(Object.assign({},Ze==null?void 0:Ze.style),$e);return we(Oe.createElement(It.Z,{component:"Switch"},Oe.createElement(Re,Object.assign({},xn,{prefixCls:tn,className:Rt,style:Lt,disabled:zn,ref:Xe,loadingIcon:Tn}))))});Zt.__ANT_SWITCH=!0;var je=Zt},1710:function(Cn,cn,wt){"use strict";wt.d(cn,{default:function(){return Kg}});var Ft={},Ht="rc-table-internal-hook",oe=wt(72071),ke=wt(6089),Vt=wt(34280),qt=wt(13697),Nt=wt(59301),Oe=wt(4676);function be(Xt){var ee=Nt.createContext(void 0),Ee=function(Ve){var He=Ve.value,dn=Ve.children,fn=Nt.useRef(He);fn.current=He;var ln=Nt.useState(function(){return{getValue:function(){return fn.current},listeners:new Set}}),On=(0,oe.Z)(ln,1),Rn=On[0];return(0,Vt.Z)(function(){(0,Oe.unstable_batchedUpdates)(function(){Rn.listeners.forEach(function(In){In(He)})})},[He]),Nt.createElement(ee.Provider,{value:Rn},dn)};return{Context:ee,Provider:Ee,defaultValue:Xt}}function Qt(Xt,ee){var Ee=(0,ke.Z)(typeof ee=="function"?ee:function(In){if(ee===void 0)return In;if(!Array.isArray(ee))return In[ee];var pi={};return ee.forEach(function(li){pi[li]=In[li]}),pi}),Te=Nt.useContext(Xt==null?void 0:Xt.Context),Ve=Te||{},He=Ve.listeners,dn=Ve.getValue,fn=Nt.useRef();fn.current=Ee(Te?dn():Xt==null?void 0:Xt.defaultValue);var ln=Nt.useState({}),On=(0,oe.Z)(ln,2),Rn=On[1];return(0,Vt.Z)(function(){if(!Te)return;function In(pi){var li=Ee(pi);(0,qt.Z)(fn.current,li,!0)||Rn({})}return He.add(In),function(){He.delete(In)}},[Te]),fn.current}var Fe=wt(96663),ye=wt(8654);function Re(){var Xt=Nt.createContext(null);function ee(){return Nt.useContext(Xt)}function Ee(Ve,He){var dn=(0,ye.Yr)(Ve),fn=function(On,Rn){var In=dn?{ref:Rn}:{},pi=Nt.useRef(0),li=Nt.useRef(On),qn=ee();return qn!==null?Nt.createElement(Ve,(0,Fe.Z)({},On,In)):((!He||He(li.current,On))&&(pi.current+=1),li.current=On,Nt.createElement(Xt.Provider,{value:pi.current},Nt.createElement(Ve,(0,Fe.Z)({},On,In))))};return dn?Nt.forwardRef(fn):fn}function Te(Ve,He){var dn=(0,ye.Yr)(Ve),fn=function(On,Rn){var In=dn?{ref:Rn}:{};return ee(),Nt.createElement(Ve,(0,Fe.Z)({},On,In))};return dn?Nt.memo(Nt.forwardRef(fn),He):Nt.memo(fn,He)}return{makeImmutable:Ee,responseImmutable:Te,useImmutableMark:ee}}var It=Re(),et=It.makeImmutable,nt=It.responseImmutable,dt=It.useImmutableMark,at=Re(),gt=at.makeImmutable,mt=at.responseImmutable,Pt=at.useImmutableMark,kt=be(),Tt=kt;function Dt(Xt,ee){var Ee=Nt.useRef(0);Ee.current+=1;var Te=Nt.useRef(Xt),Ve=[];Object.keys(Xt||{}).map(function(dn){var fn;(Xt==null?void 0:Xt[dn])!==((fn=Te.current)===null||fn===void 0?void 0:fn[dn])&&Ve.push(dn)}),Te.current=Xt;var He=Nt.useRef([]);return Ve.length&&(He.current=Ve),Nt.useDebugValue(Ee.current),Nt.useDebugValue(He.current.join(", ")),ee&&console.log("".concat(ee,":"),Ee.current,He.current),Ee.current}var $t=null,ie=Nt.memo(function(){var Xt=Dt();return Nt.createElement("h1",null,"Render Times: ",Xt)});ie.displayName="RenderBlock";var Yt=wt(20135),fe=wt(44127),Zt=wt(90493),je=wt(92310),me=wt.n(je),Xe=wt(80547),Se=wt(97938),Ie=wt(48736),ze=Nt.createContext({renderWithProps:!1}),Ue=ze,se="RC_TABLE_KEY";function jt(Xt){return Xt==null?[]:Array.isArray(Xt)?Xt:[Xt]}function $e(Xt){var ee=[],Ee={};return Xt.forEach(function(Te){for(var Ve=Te||{},He=Ve.key,dn=Ve.dataIndex,fn=He||jt(dn).join("-")||se;Ee[fn];)fn="".concat(fn,"_next");Ee[fn]=!0,ee.push(fn)}),ee}function xn(Xt){return Xt!=null}function En(Xt){return Xt&&(0,Yt.Z)(Xt)==="object"&&!Array.isArray(Xt)&&!Nt.isValidElement(Xt)}function Ne(Xt,ee,Ee,Te,Ve,He){var dn=Nt.useContext(Ue),fn=Pt(),ln=(0,Xe.Z)(function(){if(xn(Te))return[Te];var On=ee==null||ee===""?[]:Array.isArray(ee)?ee:[ee],Rn=(0,Se.Z)(Xt,On),In=Rn,pi=void 0;if(Ve){var li=Ve(Rn,Xt,Ee);En(li)?(In=li.children,pi=li.props,dn.renderWithProps=!0):In=li}return[In,pi]},[fn,Xt,Te,ee,Ve,Ee],function(On,Rn){if(He){var In=(0,oe.Z)(On,2),pi=In[1],li=(0,oe.Z)(Rn,2),qn=li[1];return He(qn,pi)}return dn.renderWithProps?!0:!(0,qt.Z)(On,Rn,!0)});return ln}function Ze(Xt,ee,Ee,Te){var Ve=Xt+ee-1;return Xt<=Te&&Ve>=Ee}function rn(Xt,ee){return Qt(Tt,function(Ee){var Te=Ze(Xt,ee||1,Ee.hoverStartRow,Ee.hoverEndRow);return[Te,Ee.onHover]})}var zn=function(ee){var Ee=ee.ellipsis,Te=ee.rowType,Ve=ee.children,He,dn=Ee===!0?{showTitle:!0}:Ee;return dn&&(dn.showTitle||Te==="header")&&(typeof Ve=="string"||typeof Ve=="number"?He=Ve.toString():Nt.isValidElement(Ve)&&typeof Ve.props.children=="string"&&(He=Ve.props.children)),He};function tn(Xt){var ee,Ee,Te,Ve,He,dn,fn,ln,On=Xt.component,Rn=Xt.children,In=Xt.ellipsis,pi=Xt.scope,li=Xt.prefixCls,qn=Xt.className,Oi=Xt.align,si=Xt.record,ki=Xt.render,Ei=Xt.dataIndex,Gi=Xt.renderIndex,vo=Xt.shouldCellUpdate,To=Xt.index,Ii=Xt.rowType,mo=Xt.colSpan,tr=Xt.rowSpan,ji=Xt.fixLeft,oo=Xt.fixRight,zi=Xt.firstFixLeft,Pi=Xt.lastFixLeft,_i=Xt.firstFixRight,bo=Xt.lastFixRight,zo=Xt.appendNode,jo=Xt.additionalProps,Bi=jo===void 0?{}:jo,ir=Xt.isSticky,ur="".concat(li,"-cell"),$r=Qt(Tt,["supportSticky","allColumnsFixedLeft"]),Pr=$r.supportSticky,ws=$r.allColumnsFixedLeft,ys=Ne(si,Ei,Gi,Rn,ki,vo),rr=(0,oe.Z)(ys,2),Eo=rr[0],Fr=rr[1],Cs={},us=typeof ji=="number"&&Pr,qs=typeof oo=="number"&⪻us&&(Cs.position="sticky",Cs.left=ji),qs&&(Cs.position="sticky",Cs.right=oo);var Ho=(ee=(Ee=(Te=Fr==null?void 0:Fr.colSpan)!==null&&Te!==void 0?Te:Bi.colSpan)!==null&&Ee!==void 0?Ee:mo)!==null&&ee!==void 0?ee:1,Do=(Ve=(He=(dn=Fr==null?void 0:Fr.rowSpan)!==null&&dn!==void 0?dn:Bi.rowSpan)!==null&&He!==void 0?He:tr)!==null&&Ve!==void 0?Ve:1,Go=rn(To,Do),yo=(0,oe.Z)(Go,2),Ar=yo[0],So=yo[1],er=function(Xs){var ua;si&&So(To,To+Do-1),Bi==null||(ua=Bi.onMouseEnter)===null||ua===void 0||ua.call(Bi,Xs)},Lr=function(Xs){var ua;si&&So(-1,-1),Bi==null||(ua=Bi.onMouseLeave)===null||ua===void 0||ua.call(Bi,Xs)};if(Ho===0||Do===0)return null;var Mr=(fn=Bi.title)!==null&&fn!==void 0?fn:zn({rowType:Ii,ellipsis:In,children:Eo}),va=me()(ur,qn,(ln={},(0,Zt.Z)(ln,"".concat(ur,"-fix-left"),us&&Pr),(0,Zt.Z)(ln,"".concat(ur,"-fix-left-first"),zi&&Pr),(0,Zt.Z)(ln,"".concat(ur,"-fix-left-last"),Pi&&Pr),(0,Zt.Z)(ln,"".concat(ur,"-fix-left-all"),Pi&&ws&&Pr),(0,Zt.Z)(ln,"".concat(ur,"-fix-right"),qs&&Pr),(0,Zt.Z)(ln,"".concat(ur,"-fix-right-first"),_i&&Pr),(0,Zt.Z)(ln,"".concat(ur,"-fix-right-last"),bo&&Pr),(0,Zt.Z)(ln,"".concat(ur,"-ellipsis"),In),(0,Zt.Z)(ln,"".concat(ur,"-with-append"),zo),(0,Zt.Z)(ln,"".concat(ur,"-fix-sticky"),(us||qs)&&ir&&Pr),(0,Zt.Z)(ln,"".concat(ur,"-row-hover"),!Fr&&Ar),ln),Bi.className,Fr==null?void 0:Fr.className),ia={};Oi&&(ia.textAlign=Oi);var Ra=(0,fe.Z)((0,fe.Z)((0,fe.Z)((0,fe.Z)({},Cs),Bi.style),ia),Fr==null?void 0:Fr.style),Wr=Eo;return(0,Yt.Z)(Wr)==="object"&&!Array.isArray(Wr)&&!Nt.isValidElement(Wr)&&(Wr=null),In&&(Pi||_i)&&(Wr=Nt.createElement("span",{className:"".concat(ur,"-content")},Wr)),Nt.createElement(On,(0,Fe.Z)({},Fr,Bi,{className:va,style:Ra,title:Mr,scope:pi,onMouseEnter:er,onMouseLeave:Lr,colSpan:Ho!==1?Ho:null,rowSpan:Do!==1?Do:null}),zo,Wr)}var Tn=Nt.memo(tn);function we(Xt,ee,Ee,Te,Ve,He){var dn=Ee[Xt]||{},fn=Ee[ee]||{},ln,On;dn.fixed==="left"?ln=Te.left[Ve==="rtl"?ee:Xt]:fn.fixed==="right"&&(On=Te.right[Ve==="rtl"?Xt:ee]);var Rn=!1,In=!1,pi=!1,li=!1,qn=Ee[ee+1],Oi=Ee[Xt-1],si=!(He!=null&&He.children);if(Ve==="rtl"){if(ln!==void 0){var ki=Oi&&Oi.fixed==="left";li=!ki&&si}else if(On!==void 0){var Ei=qn&&qn.fixed==="right";pi=!Ei&&si}}else if(ln!==void 0){var Gi=qn&&qn.fixed==="left";Rn=!Gi&&si}else if(On!==void 0){var vo=Oi&&Oi.fixed==="right";In=!vo&&si}return{fixLeft:ln,fixRight:On,lastFixLeft:Rn,firstFixRight:In,lastFixRight:pi,firstFixLeft:li,isSticky:Te.isSticky}}var Bn=Nt.createContext({}),Jn=Bn;function Rt(Xt){var ee=Xt.className,Ee=Xt.index,Te=Xt.children,Ve=Xt.colSpan,He=Ve===void 0?1:Ve,dn=Xt.rowSpan,fn=Xt.align,ln=Qt(Tt,["prefixCls","direction"]),On=ln.prefixCls,Rn=ln.direction,In=Nt.useContext(Jn),pi=In.scrollColumnIndex,li=In.stickyOffsets,qn=In.flattenColumns,Oi=In.columns,si=Ee+He-1,ki=si+1===pi?He+1:He,Ei=we(Ee,Ee+ki-1,qn,li,Rn,Oi==null?void 0:Oi[Ee]);return Nt.createElement(Tn,(0,Fe.Z)({className:ee,index:Ee,component:"td",prefixCls:On,record:null,dataIndex:null,align:fn,colSpan:ki,rowSpan:dn,render:function(){return Te}},Ei))}var Lt=wt(6620),St=["children"];function Et(Xt){var ee=Xt.children,Ee=(0,Lt.Z)(Xt,St);return Nt.createElement("tr",Ee,ee)}function Bt(Xt){var ee=Xt.children;return ee}Bt.Row=Et,Bt.Cell=Rt;var yt=Bt;function ae(Xt){var ee=Xt.children,Ee=Xt.stickyOffsets,Te=Xt.flattenColumns,Ve=Xt.columns,He=Qt(Tt,"prefixCls"),dn=Te.length-1,fn=Te[dn],ln=Nt.useMemo(function(){return{stickyOffsets:Ee,flattenColumns:Te,scrollColumnIndex:fn!=null&&fn.scrollbar?dn:null,columns:Ve}},[fn,Te,dn,Ee,Ve]);return Nt.createElement(Jn.Provider,{value:ln},Nt.createElement("tfoot",{className:"".concat(He,"-summary")},ee))}var Pe=mt(ae),ne=yt,_t=wt(70425),ge=wt(29301),pe=wt(29194),le=wt(24514),Me=wt(75152),nn=wt(26112);function qe(Xt,ee,Ee,Te,Ve,He,dn){Xt.push({record:ee,indent:Ee,index:dn});var fn=He(ee),ln=Ve==null?void 0:Ve.has(fn);if(ee&&Array.isArray(ee[Te])&&ln)for(var On=0;On1?zi-1:0),_i=1;_i=0;fn-=1){var ln=ee[fn],On=Ee&&Ee[fn],Rn=On&&On[Io];if(ln||Rn||dn){var In=Rn||{},pi=In.columnType,li=(0,Lt.Z)(In,$n);Ve.unshift(Nt.createElement("col",(0,Fe.Z)({key:fn,style:{width:ln}},li))),dn=!0}}return Nt.createElement("colgroup",null,Ve)}var jn=Kn,ii=wt(19127),Vi=["className","noData","columns","flattenColumns","colWidths","columCount","stickyOffsets","direction","fixHeader","stickyTopOffset","stickyBottomOffset","stickyClassName","onScroll","maxContentScroll","children"];function wi(Xt,ee){return(0,Nt.useMemo)(function(){for(var Ee=[],Te=0;Te1?"colgroup":"col":null,ellipsis:si.ellipsis,align:si.align,component:si.title?He:dn,prefixCls:Rn,key:li[Oi]},ki,{additionalProps:Ei,rowType:"header"}))}))}Ni.displayName="HeaderRow";var ho=Ni;function pr(Xt){var ee=[];function Ee(dn,fn){var ln=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;ee[ln]=ee[ln]||[];var On=fn,Rn=dn.filter(Boolean).map(function(In){var pi={key:In.key,className:In.className||"",children:In.title,column:In,colStart:On},li=1,qn=In.children;return qn&&qn.length>0&&(li=Ee(qn,On,ln+1).reduce(function(Oi,si){return Oi+si},0),pi.hasSubColumns=!0),"colSpan"in In&&(li=In.colSpan),"rowSpan"in In&&(pi.rowSpan=In.rowSpan),pi.colSpan=li,pi.colEnd=pi.colStart+li-1,ee[ln].push(pi),On+=li,li});return Rn}Ee(Xt,0);for(var Te=ee.length,Ve=function(fn){ee[fn].forEach(function(ln){!("rowSpan"in ln)&&!ln.hasSubColumns&&(ln.rowSpan=Te-fn)})},He=0;He1&&arguments[1]!==void 0?arguments[1]:"";return typeof ee=="number"?ee:ee.endsWith("%")?Xt*parseFloat(ee)/100:null}function _e(Xt,ee){return Nt.useMemo(function(){if(ee&&ee>0){var Ee=0,Te=0;Xt.forEach(function(On){var Rn=nr(ee,On.width);Rn?Ee+=Rn:Te+=1});var Ve=ee-Ee,He=Te,dn=Ve/Te,fn=0,ln=Xt.map(function(On){var Rn=(0,fe.Z)({},On),In=nr(ee,Rn.width);if(In)Rn.width=In;else{var pi=Math.floor(dn);Rn.width=He===1?Ve:pi,Ve-=pi,He-=1}return fn+=Rn.width,Rn});return[ln,fn]}return[Xt,ee]},[Xt,ee])}var We=["children"],Jt=["fixed"];function on(Xt){return(0,Fo.Z)(Xt).filter(function(ee){return Nt.isValidElement(ee)}).map(function(ee){var Ee=ee.key,Te=ee.props,Ve=Te.children,He=(0,Lt.Z)(Te,We),dn=(0,fe.Z)({key:Ee},He);return Ve&&(dn.children=on(Ve)),dn})}function Mn(Xt){var ee=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"key";return Xt.filter(function(Ee){return Ee&&(0,Yt.Z)(Ee)==="object"}).reduce(function(Ee,Te,Ve){var He=Te.fixed,dn=He===!0?"left":He,fn="".concat(ee,"-").concat(Ve),ln=Te.children;return ln&&ln.length>0?[].concat((0,ii.Z)(Ee),(0,ii.Z)(Mn(ln,fn).map(function(On){return(0,fe.Z)({fixed:dn},On)}))):[].concat((0,ii.Z)(Ee),[(0,fe.Z)((0,fe.Z)({key:fn},Te),{},{fixed:dn})])},[])}function Le(Xt){for(var ee=!0,Ee=0;Ee=0;He-=1){var dn=Xt[He];if(Ve&&dn.fixed!=="right")Ve=!1;else if(!Ve&&dn.fixed==="right"){warning(!1,"Index ".concat(He+1," of `columns` missing `fixed='right'` prop."));break}}}function ue(Xt){return Xt.map(function(ee){var Ee=ee.fixed,Te=(0,Lt.Z)(ee,Jt),Ve=Ee;return Ee==="left"?Ve="right":Ee==="right"&&(Ve="left"),(0,fe.Z)({fixed:Ve},Te)})}function Je(Xt,ee){var Ee=Xt.prefixCls,Te=Xt.columns,Ve=Xt.children,He=Xt.expandable,dn=Xt.expandedKeys,fn=Xt.columnTitle,ln=Xt.getRowKey,On=Xt.onTriggerExpand,Rn=Xt.expandIcon,In=Xt.rowExpandable,pi=Xt.expandIconColumnIndex,li=Xt.direction,qn=Xt.expandRowByClick,Oi=Xt.columnWidth,si=Xt.fixed,ki=Xt.scrollWidth,Ei=Nt.useMemo(function(){return Te||on(Ve)},[Te,Ve]),Gi=Nt.useMemo(function(){if(He){var oo,zi=Ei.slice();if(!zi.includes(Ft)){var Pi=pi||0;Pi>=0&&zi.splice(Pi,0,Ft)}var _i=zi.indexOf(Ft);zi=zi.filter(function(Bi,ir){return Bi!==Ft||ir===_i});var bo=Ei[_i],zo;(si==="left"||si)&&!pi?zo="left":(si==="right"||si)&&pi===Ei.length?zo="right":zo=bo?bo.fixed:null;var jo=(oo={},(0,Zt.Z)(oo,Io,{className:"".concat(Ee,"-expand-icon-col"),columnType:"EXPAND_COLUMN"}),(0,Zt.Z)(oo,"title",fn),(0,Zt.Z)(oo,"fixed",zo),(0,Zt.Z)(oo,"className","".concat(Ee,"-row-expand-icon-cell")),(0,Zt.Z)(oo,"width",Oi),(0,Zt.Z)(oo,"render",function(ir,ur,$r){var Pr=ln(ur,$r),ws=dn.has(Pr),ys=In?In(ur):!0,rr=Rn({prefixCls:Ee,expanded:ws,expandable:ys,record:ur,onExpand:On});return qn?Nt.createElement("span",{onClick:function(Fr){return Fr.stopPropagation()}},rr):rr}),oo);return zi.map(function(Bi){return Bi===Ft?jo:Bi})}return Ei.filter(function(Bi){return Bi!==Ft})},[He,Ei,ln,dn,Rn,li]),vo=Nt.useMemo(function(){var oo=Gi;return ee&&(oo=ee(oo)),oo.length||(oo=[{render:function(){return null}}]),oo},[ee,Gi,li]),To=Nt.useMemo(function(){return li==="rtl"?ue(Mn(vo)):Mn(vo)},[vo,li,ki]),Ii=_e(To,ki),mo=(0,oe.Z)(Ii,2),tr=mo[0],ji=mo[1];return[vo,tr,ji]}var gn=Je;function Xn(Xt){var ee,Ee=Xt.prefixCls,Te=Xt.record,Ve=Xt.onExpand,He=Xt.expanded,dn=Xt.expandable,fn="".concat(Ee,"-row-expand-icon");if(!dn)return Nt.createElement("span",{className:me()(fn,"".concat(Ee,"-row-spaced"))});var ln=function(Rn){Ve(Te,Rn),Rn.stopPropagation()};return Nt.createElement("span",{className:me()(fn,(ee={},(0,Zt.Z)(ee,"".concat(Ee,"-row-expanded"),He),(0,Zt.Z)(ee,"".concat(Ee,"-row-collapsed"),!He),ee)),onClick:ln})}function Gn(Xt,ee,Ee){var Te=[];function Ve(He){(He||[]).forEach(function(dn,fn){Te.push(ee(dn,fn)),Ve(dn[Ee])})}return Ve(Xt),Te}function ce(Xt,ee,Ee){var Te=Ao(Xt),Ve=Te.expandIcon,He=Te.expandedRowKeys,dn=Te.defaultExpandedRowKeys,fn=Te.defaultExpandAllRows,ln=Te.expandedRowRender,On=Te.onExpand,Rn=Te.onExpandedRowsChange,In=Te.childrenColumnName,pi=Ve||Xn,li=In||"children",qn=Nt.useMemo(function(){return ln?"row":Xt.expandable&&Xt.internalHooks===Ht&&Xt.expandable.__PARENT_RENDER_ICON__||ee.some(function(To){return To&&(0,Yt.Z)(To)==="object"&&To[li]})?"nest":!1},[!!ln,ee]),Oi=Nt.useState(function(){return dn||(fn?Gn(ee,Ee,li):[])}),si=(0,oe.Z)(Oi,2),ki=si[0],Ei=si[1],Gi=Nt.useMemo(function(){return new Set(He||ki||[])},[He,ki]),vo=Nt.useCallback(function(To){var Ii=Ee(To,ee.indexOf(To)),mo,tr=Gi.has(Ii);tr?(Gi.delete(Ii),mo=(0,ii.Z)(Gi)):mo=[].concat((0,ii.Z)(Gi),[Ii]),Ei(mo),On&&On(!tr,To),Rn&&Rn(mo)},[Ee,Gi,ee,On,Rn]);return[Te,qn,Gi,pi,li,vo]}function vn(Xt,ee,Ee,Te){var Ve=Xt.map(function(He,dn){return we(dn,dn,Xt,ee,Ee,Te==null?void 0:Te[dn])});return(0,Xe.Z)(function(){return Ve},[Ve],function(He,dn){return!(0,qt.Z)(He,dn)})}function An(Xt){var ee=(0,Nt.useRef)(Xt),Ee=(0,Nt.useState)({}),Te=(0,oe.Z)(Ee,2),Ve=Te[1],He=(0,Nt.useRef)(null),dn=(0,Nt.useRef)([]);function fn(ln){dn.current.push(ln);var On=Promise.resolve();He.current=On,On.then(function(){if(He.current===On){var Rn=dn.current,In=ee.current;dn.current=[],Rn.forEach(function(pi){ee.current=pi(ee.current)}),He.current=null,In!==ee.current&&Ve({})}})}return(0,Nt.useEffect)(function(){return function(){He.current=null}},[]),[ee.current,fn]}function xi(Xt){var ee=(0,Nt.useRef)(Xt||null),Ee=(0,Nt.useRef)();function Te(){window.clearTimeout(Ee.current)}function Ve(dn){ee.current=dn,Te(),Ee.current=window.setTimeout(function(){ee.current=null,Ee.current=void 0},100)}function He(){return ee.current}return(0,Nt.useEffect)(function(){return Te},[]),[Ve,He]}function Ae(){var Xt=Nt.useState(-1),ee=(0,oe.Z)(Xt,2),Ee=ee[0],Te=ee[1],Ve=Nt.useState(-1),He=(0,oe.Z)(Ve,2),dn=He[0],fn=He[1],ln=Nt.useCallback(function(On,Rn){Te(On),fn(Rn)},[]);return[Ee,dn,ln]}var en=wt(47273),ui=(0,en.Z)()?window:null;function oi(Xt,ee){var Ee=(0,Yt.Z)(Xt)==="object"?Xt:{},Te=Ee.offsetHeader,Ve=Te===void 0?0:Te,He=Ee.offsetSummary,dn=He===void 0?0:He,fn=Ee.offsetScroll,ln=fn===void 0?0:fn,On=Ee.getContainer,Rn=On===void 0?function(){return ui}:On,In=Rn()||ui;return Nt.useMemo(function(){var pi=!!Xt;return{isSticky:pi,stickyClassName:pi?"".concat(ee,"-sticky-holder"):"",offsetHeader:Ve,offsetSummary:dn,offsetScroll:ln,container:In}},[ln,Ve,dn,ee,In])}function Si(Xt,ee,Ee){var Te=(0,Nt.useMemo)(function(){for(var Ve=[],He=[],dn=0,fn=0,ln=0;ln=In&&(Bi=In-pi),dn({scrollLeft:Bi/In*(Rn+2)}),Ei.current.x=_i.pageX},oo=function(){if(He.current){var _i=(0,so.os)(He.current).top,bo=_i+He.current.offsetHeight,zo=ln===window?document.documentElement.scrollTop+window.innerHeight:(0,so.os)(ln).top+ln.clientHeight;bo-(0,Me.Z)()<=zo||_i>=zo-fn?ki(function(jo){return(0,fe.Z)((0,fe.Z)({},jo),{},{isHiddenScrollBar:!0})}):ki(function(jo){return(0,fe.Z)((0,fe.Z)({},jo),{},{isHiddenScrollBar:!1})})}},zi=function(_i){ki(function(bo){return(0,fe.Z)((0,fe.Z)({},bo),{},{scrollLeft:_i/Rn*In||0})})};return Nt.useImperativeHandle(Ee,function(){return{setScrollLeft:zi}}),Nt.useEffect(function(){var Pi=(0,Ci.Z)(document.body,"mouseup",mo,!1),_i=(0,Ci.Z)(document.body,"mousemove",ji,!1);return oo(),function(){Pi.remove(),_i.remove()}},[pi,To]),Nt.useEffect(function(){var Pi=(0,Ci.Z)(ln,"scroll",oo,!1),_i=(0,Ci.Z)(window,"resize",oo,!1);return function(){Pi.remove(),_i.remove()}},[ln]),Nt.useEffect(function(){si.isHiddenScrollBar||ki(function(Pi){var _i=He.current;return _i?(0,fe.Z)((0,fe.Z)({},Pi),{},{scrollLeft:_i.scrollLeft/_i.scrollWidth*_i.clientWidth}):Pi})},[si.isHiddenScrollBar]),Rn<=In||!pi||si.isHiddenScrollBar?null:Nt.createElement("div",{style:{height:(0,Me.Z)(),width:In,bottom:fn},className:"".concat(On,"-sticky-scroll")},Nt.createElement("div",{onMouseDown:tr,ref:li,className:me()("".concat(On,"-sticky-scroll-bar"),(0,Zt.Z)({},"".concat(On,"-sticky-scroll-bar-active"),To)),style:{width:"".concat(pi,"px"),transform:"translate3d(".concat(si.scrollLeft,"px, 0, 0)")}}))},sn=Nt.forwardRef(wo);function Bo(Xt){return null}var Vo=Bo;function io(Xt){return null}var Qe=io,Hn="rc-table",di=[],bi={};function yi(){return"No Data"}function Qi(Xt){var ee,Ee=(0,fe.Z)({rowKey:"key",prefixCls:Hn,emptyText:yi},Xt),Te=Ee.prefixCls,Ve=Ee.className,He=Ee.rowClassName,dn=Ee.style,fn=Ee.data,ln=Ee.rowKey,On=Ee.scroll,Rn=Ee.tableLayout,In=Ee.direction,pi=Ee.title,li=Ee.footer,qn=Ee.summary,Oi=Ee.caption,si=Ee.id,ki=Ee.showHeader,Ei=Ee.components,Gi=Ee.emptyText,vo=Ee.onRow,To=Ee.onHeaderRow,Ii=Ee.internalHooks,mo=Ee.transformColumns,tr=Ee.internalRefs,ji=Ee.tailor,oo=Ee.sticky,zi=fn||di,Pi=!!zi.length,_i=Ii===Ht,bo=Nt.useCallback(function(Zr,Ss){return(0,Se.Z)(Ei,Zr)||Ss},[Ei]),zo=Nt.useMemo(function(){return typeof ln=="function"?ln:function(Zr){var Ss=Zr&&Zr[ln];return Ss}},[ln]),jo=bo(["body"]),Bi=Ae(),ir=(0,oe.Z)(Bi,3),ur=ir[0],$r=ir[1],Pr=ir[2],ws=ce(Ee,zi,zo),ys=(0,oe.Z)(ws,6),rr=ys[0],Eo=ys[1],Fr=ys[2],Cs=ys[3],us=ys[4],qs=ys[5],Ho=On==null?void 0:On.x,Do=Nt.useState(0),Go=(0,oe.Z)(Do,2),yo=Go[0],Ar=Go[1],So=gn((0,fe.Z)((0,fe.Z)((0,fe.Z)({},Ee),rr),{},{expandable:!!rr.expandedRowRender,columnTitle:rr.columnTitle,expandedKeys:Fr,getRowKey:zo,onTriggerExpand:qs,expandIcon:Cs,expandIconColumnIndex:rr.expandIconColumnIndex,direction:In,scrollWidth:_i&&ji&&typeof Ho=="number"?Ho:null}),_i?mo:null),er=(0,oe.Z)(So,3),Lr=er[0],Mr=er[1],va=er[2],ia=va!=null?va:Ho,Ra=Nt.useMemo(function(){return{columns:Lr,flattenColumns:Mr}},[Lr,Mr]),Wr=Nt.useRef(),ya=Nt.useRef(),Xs=Nt.useRef(),ua=Nt.useRef(),Gu=Nt.useRef(),Kr=Nt.useState(!1),Xr=(0,oe.Z)(Kr,2),ns=Xr[0],$s=Xr[1],ha=Nt.useState(!1),vr=(0,oe.Z)(ha,2),rs=vr[0],da=vr[1],ll=An(new Map),Dl=(0,oe.Z)(ll,2),Sl=Dl[0],Xl=Dl[1],_l=$e(Mr),Al=_l.map(function(Zr){return Sl.get(Zr)}),Ur=Nt.useMemo(function(){return Al},[Al.join("_")]),Pa=Zn(Ur,Mr.length,In),As=On&&xn(On.y),ss=On&&xn(ia)||!!rr.fixed,Rl=ss&&Mr.some(function(Zr){var Ss=Zr.fixed;return Ss}),ih=Nt.useRef(),Jl=oi(oo,Te),Cu=Jl.isSticky,$u=Jl.offsetHeader,xl=Jl.offsetSummary,Rr=Jl.offsetScroll,hs=Jl.stickyClassName,oa=Jl.container,ds=Nt.useMemo(function(){return qn==null?void 0:qn(zi)},[qn,zi]),Or=(As||Cu)&&Nt.isValidElement(ds)&&ds.type===yt&&ds.props.fixed,ca,ul,du;As&&(ul={overflowY:"scroll",maxHeight:On.y}),ss&&(ca={overflowX:"auto"},As||(ul={overflowY:"hidden"}),du={width:ia===!0?"auto":ia,minWidth:"100%"});var uf=Nt.useCallback(function(Zr,Ss){(0,pe.Z)(Wr.current)&&Xl(function(Na){if(Na.get(Zr)!==Ss){var Ql=new Map(Na);return Ql.set(Zr,Ss),Ql}return Na})},[]),Be=xi(null),wh=(0,oe.Z)(Be,2),Wu=wh[0],hf=wh[1];function gd(Zr,Ss){Ss&&(typeof Ss=="function"?Ss(Zr):Ss.scrollLeft!==Zr&&(Ss.scrollLeft=Zr,Ss.scrollLeft!==Zr&&setTimeout(function(){Ss.scrollLeft=Zr},0)))}var Xh=(0,ke.Z)(function(Zr){var Ss=Zr.currentTarget,Na=Zr.scrollLeft,Ql=In==="rtl",ql=typeof Na=="number"?Na:Ss.scrollLeft,Bc=Ss||bi;if(!hf()||hf()===Bc){var Lh;Wu(Bc),gd(ql,ya.current),gd(ql,Xs.current),gd(ql,Gu.current),gd(ql,(Lh=ih.current)===null||Lh===void 0?void 0:Lh.setScrollLeft)}var Ud=Ss||ya.current;if(Ud){var cu=Ud.scrollWidth,oh=Ud.clientWidth;if(cu===oh){$s(!1),da(!1);return}Ql?($s(-ql0)):($s(ql>0),da(ql1?Oi-_i:0,zo=(0,fe.Z)((0,fe.Z)((0,fe.Z)({},mo),ln),{},{flex:"0 0 ".concat(_i,"px"),width:"".concat(_i,"px"),marginRight:bo,pointerEvents:"auto"}),jo=Nt.useMemo(function(){return Rn?zi<=1:ji===0||zi===0||zi>1},[zi,ji,Rn]);jo?zo.visibility="hidden":Rn&&(zo.height=In==null?void 0:In(zi));var Bi=jo?function(){return null}:pi,ir={};return(zi===0||ji===0)&&(ir.rowSpan=1,ir.colSpan=1),Nt.createElement(Tn,(0,Fe.Z)({className:me()(qn,On),ellipsis:Ee.ellipsis,align:Ee.align,scope:Ee.rowScope,component:"div",prefixCls:ee.prefixCls,key:Gi,record:fn,index:He,renderIndex:dn,dataIndex:li,render:Bi,shouldCellUpdate:Ee.shouldCellUpdate},vo,{appendNode:To,additionalProps:(0,fe.Z)((0,fe.Z)({},Ii),{},{style:zo},ir)}))}var kr=Po,$o=["data","index","className","rowKey","style","extra","getHeight"],Hr=Nt.forwardRef(function(Xt,ee){var Ee=Xt.data,Te=Xt.index,Ve=Xt.className,He=Xt.rowKey,dn=Xt.style,fn=Xt.extra,ln=Xt.getHeight,On=(0,Lt.Z)(Xt,$o),Rn=Ee.record,In=Ee.indent,pi=Ee.index,li=Qt(Tt,["prefixCls","flattenColumns","fixColumn","componentWidth","scrollX"]),qn=li.scrollX,Oi=li.flattenColumns,si=li.prefixCls,ki=li.fixColumn,Ei=li.componentWidth,Gi=pn(Rn,He,Te,In),vo=Gi.rowSupportExpand,To=Gi.expanded,Ii=Gi.rowProps,mo=Gi.expandedRowRender,tr=Gi.expandedRowClassName,ji;if(vo&&To){var oo=mo(Rn,Te,In+1,To),zi=tr==null?void 0:tr(Rn,Te,In),Pi={};ki&&(Pi={style:(0,Zt.Z)({},"--virtual-width","".concat(Ei,"px"))});var _i="".concat(si,"-expanded-row-cell");ji=Nt.createElement("div",{className:me()("".concat(si,"-expanded-row"),"".concat(si,"-expanded-row-level-").concat(In+1),zi)},Nt.createElement(Tn,{component:"div",prefixCls:si,className:me()(_i,(0,Zt.Z)({},"".concat(_i,"-fixed"),ki)),additionalProps:Pi},oo))}var bo=(0,fe.Z)((0,fe.Z)({},dn),{},{width:qn});fn&&(bo.position="absolute",bo.pointerEvents="none");var zo=Nt.createElement("div",(0,Fe.Z)({},Ii,On,{ref:vo?null:ee,className:me()(Ve,"".concat(si,"-row"),Ii==null?void 0:Ii.className,(0,Zt.Z)({},"".concat(si,"-row-extra"),fn)),style:(0,fe.Z)((0,fe.Z)({},bo),Ii==null?void 0:Ii.style)}),Oi.map(function(jo,Bi){return Nt.createElement(kr,{key:Bi,rowInfo:Gi,column:jo,colIndex:Bi,indent:In,index:Te,renderIndex:pi,record:Rn,inverse:fn,getHeight:ln})}));return vo?Nt.createElement("div",{ref:ee},zo,ji):zo}),xr=mt(Hr),Wi=xr,Ui=Nt.forwardRef(function(Xt,ee){var Ee=Xt.data,Te=Xt.onScroll,Ve=Qt(Tt,["flattenColumns","onColumnResize","getRowKey","prefixCls","expandedKeys","childrenColumnName","emptyNode","scrollX"]),He=Ve.flattenColumns,dn=Ve.onColumnResize,fn=Ve.getRowKey,ln=Ve.expandedKeys,On=Ve.prefixCls,Rn=Ve.childrenColumnName,In=Ve.emptyNode,pi=Ve.scrollX,li=Qt(mn),qn=li.scrollY,Oi=li.listItemHeight,si=Nt.useRef(),ki=Ge(Ee,Rn,ln,fn),Ei=Nt.useMemo(function(){var ji=0;return He.map(function(oo){var zi=oo.width,Pi=oo.key;return ji+=zi,[Pi,zi,ji]})},[He]),Gi=Nt.useMemo(function(){return Ei.map(function(ji){return ji[2]})},[Ei]);Nt.useEffect(function(){Ei.forEach(function(ji){var oo=(0,oe.Z)(ji,2),zi=oo[0],Pi=oo[1];dn(zi,Pi)})},[Ei]),Nt.useImperativeHandle(ee,function(){var ji={};return Object.defineProperty(ji,"scrollLeft",{get:function(){var zi;return((zi=si.current)===null||zi===void 0?void 0:zi.getScrollInfo().x)||0},set:function(zi){var Pi;(Pi=si.current)===null||Pi===void 0||Pi.scrollTo({left:zi})}}),ji});var vo=function(oo,zi){var Pi,_i=(Pi=ki[zi])===null||Pi===void 0?void 0:Pi.record,bo=oo.onCell;if(bo){var zo,jo=bo(_i,zi);return(zo=jo==null?void 0:jo.rowSpan)!==null&&zo!==void 0?zo:1}return 1},To=function(oo){var zi=oo.start,Pi=oo.end,_i=oo.getSize,bo=oo.offsetY;if(Pi<0)return null;for(var zo=He.filter(function(Ho){return vo(Ho,zi)===0}),jo=zi,Bi=function(Do){if(zo=zo.filter(function(Go){return vo(Go,Do)===0}),!zo.length)return jo=Do,"break"},ir=zi;ir>=0;ir-=1){var ur=Bi(ir);if(ur==="break")break}for(var $r=He.filter(function(Ho){return vo(Ho,Pi)!==1}),Pr=Pi,ws=function(Do){if($r=$r.filter(function(Go){return vo(Go,Do)!==1}),!$r.length)return Pr=Math.max(Do-1,Pi),"break"},ys=Pi;ys1})&&Eo.push(Do)},Cs=jo;Cs<=Pr;Cs+=1)var us=Fr(Cs);var qs=Eo.map(function(Ho){var Do=ki[Ho],Go=fn(Do.record,Ho),yo=function(er){var Lr=Ho+er-1,Mr=fn(ki[Lr].record,Lr),va=_i(Go,Mr);return va.bottom-va.top},Ar=_i(Go);return Nt.createElement(Wi,{key:Ho,data:Do,rowKey:Go,index:Ho,style:{top:-bo+Ar.top},extra:!0,getHeight:yo})});return qs},Ii=Nt.useMemo(function(){return{columnsOffset:Gi}},[Gi]),mo="".concat(On,"-tbody"),tr;return ki.length?tr=Nt.createElement(fo.Z,{fullHeight:!1,ref:si,className:me()(mo,"".concat(mo,"-virtual")),height:qn,itemHeight:Oi||24,data:ki,itemKey:function(oo){return fn(oo.record)},scrollWidth:pi,onVirtualScroll:function(oo){var zi=oo.x;Te({scrollLeft:zi})},extraRender:To},function(ji,oo,zi){var Pi=fn(ji.record,oo);return Nt.createElement(Wi,(0,Fe.Z)({data:ji,rowKey:Pi,index:oo},zi))}):tr=Nt.createElement("div",{className:me()("".concat(On,"-placeholder"))},Nt.createElement(Tn,{component:"div",prefixCls:On},In)),Nt.createElement(Uo.Provider,{value:Ii},tr)}),ko=mt(Ui),Yo=ko,ri=function(ee,Ee){var Te=Ee.ref,Ve=Ee.onScroll;return Nt.createElement(Yo,{ref:Te,data:ee,onScroll:Ve})},Gt=100;function qo(Xt){var ee=Xt.columns,Ee=Xt.scroll,Te=Xt.prefixCls,Ve=Te===void 0?Hn:Te,He=Xt.className,dn=Xt.listItemHeight,fn=Ee||{},ln=fn.x,On=fn.y;typeof ln!="number"&&(ln=((ee||[]).length+1)*Gt),typeof On!="number"&&(On=500);var Rn=Nt.useMemo(function(){return{scrollY:On,listItemHeight:dn}},[On,dn]);return Nt.createElement(mn.Provider,{value:Rn},Nt.createElement(Hi,(0,Fe.Z)({},Xt,{className:me()(He,"".concat(Ve,"-virtual")),scroll:(0,fe.Z)((0,fe.Z)({},Ee),{},{x:ln}),components:{body:ri},columns:ee,internalHooks:Ht,tailor:!0})))}function Sr(Xt){return gt(qo,Xt)}var ps=Sr(),ms=null;function ks(Xt){return null}var po=ks;function to(Xt){return null}var Ko=to,ao=wt(2738),lr=wt(68031),Ys=wt(36355),qi=wt(93891),Ai=wt(19716),Nn=wt(8628),Zi=wt(31724),Xo=wt(58421),zr=wt(71418),Ir=wt(88088);function Vr(Xt){return function(Ee){let{prefixCls:Te,onExpand:Ve,record:He,expanded:dn,expandable:fn}=Ee;const ln=`${Te}-row-expand-icon`;return Nt.createElement("button",{type:"button",onClick:On=>{Ve(He,On),On.stopPropagation()},className:me()(ln,{[`${ln}-spaced`]:!fn,[`${ln}-expanded`]:fn&&dn,[`${ln}-collapsed`]:fn&&!dn}),"aria-label":dn?Xt.collapse:Xt.expand,"aria-expanded":dn})}}var Ns=Vr;function Jr(Xt,ee){return"key"in Xt&&Xt.key!==void 0&&Xt.key!==null?Xt.key:Xt.dataIndex?Array.isArray(Xt.dataIndex)?Xt.dataIndex.join("."):Xt.dataIndex:ee}function ga(Xt,ee){return ee?`${ee}-${Xt}`:`${Xt}`}function Qs(Xt,ee){return typeof Xt=="function"?Xt(ee):Xt}function Ea(Xt,ee){const Ee=Qs(Xt,ee);return Object.prototype.toString.call(Ee)==="[object Object]"?"":Ee}var Ye={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M349 838c0 17.7 14.2 32 31.8 32h262.4c17.6 0 31.8-14.3 31.8-32V642H349v196zm531.1-684H143.9c-24.5 0-39.8 26.7-27.5 48l221.3 376h348.8l221.3-376c12.1-21.3-3.2-48-27.7-48z"}}]},name:"filter",theme:"filled"},Ws=Ye,gh=wt(7657),kl=function(ee,Ee){return Nt.createElement(gh.Z,(0,Fe.Z)({},ee,{ref:Ee,icon:Ws}))},uu=Nt.forwardRef(kl),ts=uu,th=wt(56762);function eh(Xt){const ee=Nt.useRef(Xt),Ee=(0,th.Z)();return[()=>ee.current,Te=>{ee.current=Te,Ee()}]}var Gr=wt(3113),Ts=wt(24905),Ul=wt(38854),lo=wt(64165),hr=wt(20834),Zo=wt(40875),ci=wt(5112),Os=wt(17574),Fs=wt(47472),Sa=wt(92832);function Nl(Xt){let{value:ee,onChange:Ee,filterSearch:Te,tablePrefixCls:Ve,locale:He}=Xt;return Te?Nt.createElement("div",{className:`${Ve}-filter-dropdown-search`},Nt.createElement(Sa.default,{prefix:Nt.createElement(Fs.Z,null),placeholder:He.filterSearchPlaceholder,onChange:Ee,value:ee,htmlSize:1,className:`${Ve}-filter-dropdown-search-input`})):null}var Yl=Nl,ei=wt(10228);const Qr=Xt=>{const{keyCode:ee}=Xt;ee===ei.Z.ENTER&&Xt.stopPropagation()};var vl=Nt.forwardRef((Xt,ee)=>Nt.createElement("div",{className:Xt.className,onClick:Ee=>Ee.stopPropagation(),onKeyDown:Qr,ref:ee},Xt.children));function Tl(Xt){let ee=[];return(Xt||[]).forEach(Ee=>{let{value:Te,children:Ve}=Ee;ee.push(Te),Ve&&(ee=[].concat((0,ii.Z)(ee),(0,ii.Z)(Tl(Ve))))}),ee}function Ol(Xt){return Xt.some(ee=>{let{children:Ee}=ee;return Ee})}function Co(Xt,ee){return typeof ee=="string"||typeof ee=="number"?ee==null?void 0:ee.toString().toLowerCase().includes(Xt.trim().toLowerCase()):!1}function ph(Xt){let{filters:ee,prefixCls:Ee,filteredKeys:Te,filterMultiple:Ve,searchValue:He,filterSearch:dn}=Xt;return ee.map((fn,ln)=>{const On=String(fn.value);if(fn.children)return{key:On||ln,label:fn.text,popupClassName:`${Ee}-dropdown-submenu`,children:ph({filters:fn.children,prefixCls:Ee,filteredKeys:Te,filterMultiple:Ve,searchValue:He,filterSearch:dn})};const Rn=Ve?Ts.default:ci.ZP,In={key:fn.value!==void 0?On:ln,label:Nt.createElement(Nt.Fragment,null,Nt.createElement(Rn,{checked:Te.includes(On)}),Nt.createElement("span",null,fn.text))};return He.trim()?typeof dn=="function"?dn(He,fn)?In:null:Co(He,fn.text)?In:null:In})}function Xa(Xt){var ee,Ee;const{tablePrefixCls:Te,prefixCls:Ve,column:He,dropdownPrefixCls:dn,columnKey:fn,filterMultiple:ln,filterMode:On="menu",filterSearch:Rn=!1,filterState:In,triggerFilter:pi,locale:li,children:qn,getPopupContainer:Oi}=Xt,{filterDropdownOpen:si,onFilterDropdownOpenChange:ki,filterResetToDefaultFilteredValue:Ei,defaultFilteredValue:Gi,filterDropdownVisible:vo,onFilterDropdownVisibleChange:To}=He,[Ii,mo]=Nt.useState(!1),tr=!!(In&&(!((ee=In.filteredKeys)===null||ee===void 0)&&ee.length||In.forceFiltered)),ji=So=>{mo(So),ki==null||ki(So),To==null||To(So)},oo=(Ee=si!=null?si:vo)!==null&&Ee!==void 0?Ee:Ii,zi=In==null?void 0:In.filteredKeys,[Pi,_i]=eh(zi||[]),bo=So=>{let{selectedKeys:er}=So;_i(er)},zo=(So,er)=>{let{node:Lr,checked:Mr}=er;bo(ln?{selectedKeys:So}:{selectedKeys:Mr&&Lr.key?[Lr.key]:[]})};Nt.useEffect(()=>{Ii&&bo({selectedKeys:zi||[]})},[zi]);const[jo,Bi]=Nt.useState([]),ir=So=>{Bi(So)},[ur,$r]=Nt.useState(""),Pr=So=>{const{value:er}=So.target;$r(er)};Nt.useEffect(()=>{Ii||$r("")},[Ii]);const ws=So=>{const er=So&&So.length?So:null;if(er===null&&(!In||!In.filteredKeys)||(0,qt.Z)(er,In==null?void 0:In.filteredKeys,!0))return null;pi({column:He,key:fn,filteredKeys:er})},ys=()=>{ji(!1),ws(Pi())},rr=function(){let{confirm:So,closeDropdown:er}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{confirm:!1,closeDropdown:!1};So&&ws([]),er&&ji(!1),$r(""),_i(Ei?(Gi||[]).map(Lr=>String(Lr)):[])},Eo=function(){let{closeDropdown:So}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{closeDropdown:!0};So&&ji(!1),ws(Pi())},Fr=So=>{So&&zi!==void 0&&_i(zi||[]),ji(So),!So&&!He.filterDropdown&&ys()},Cs=me()({[`${dn}-menu-without-submenu`]:!Ol(He.filters||[])}),us=So=>{if(So.target.checked){const er=Tl(He==null?void 0:He.filters).map(Lr=>String(Lr));_i(er)}else _i([])},qs=So=>{let{filters:er}=So;return(er||[]).map((Lr,Mr)=>{const va=String(Lr.value),ia={title:Lr.text,key:Lr.value!==void 0?va:Mr};return Lr.children&&(ia.children=qs({filters:Lr.children})),ia})},Ho=So=>{var er;return Object.assign(Object.assign({},So),{text:So.title,value:So.key,children:((er=So.children)===null||er===void 0?void 0:er.map(Lr=>Ho(Lr)))||[]})};let Do;if(typeof He.filterDropdown=="function")Do=He.filterDropdown({prefixCls:`${dn}-custom`,setSelectedKeys:So=>bo({selectedKeys:So}),selectedKeys:Pi(),confirm:Eo,clearFilters:rr,filters:He.filters,visible:oo,close:()=>{ji(!1)}});else if(He.filterDropdown)Do=He.filterDropdown;else{const So=Pi()||[],er=()=>(He.filters||[]).length===0?Nt.createElement(lo.Z,{image:lo.Z.PRESENTED_IMAGE_SIMPLE,description:li.filterEmptyText,imageStyle:{height:24},style:{margin:0,padding:"16px 0"}}):On==="tree"?Nt.createElement(Nt.Fragment,null,Nt.createElement(Yl,{filterSearch:Rn,value:ur,onChange:Pr,tablePrefixCls:Te,locale:li}),Nt.createElement("div",{className:`${Te}-filter-dropdown-tree`},ln?Nt.createElement(Ts.default,{checked:So.length===Tl(He.filters).length,indeterminate:So.length>0&&So.lengthtypeof Rn=="function"?Rn(ur,Ho(Mr)):Co(ur,Mr.title):void 0}))):Nt.createElement(Nt.Fragment,null,Nt.createElement(Yl,{filterSearch:Rn,value:ur,onChange:Pr,tablePrefixCls:Te,locale:li}),Nt.createElement(hr.default,{selectable:!0,multiple:ln,prefixCls:`${dn}-menu`,className:Cs,onSelect:bo,onDeselect:bo,selectedKeys:So,getPopupContainer:Oi,openKeys:jo,onOpenChange:ir,items:ph({filters:He.filters||[],filterSearch:Rn,prefixCls:Ve,filteredKeys:Pi(),filterMultiple:ln,searchValue:ur})})),Lr=()=>Ei?(0,qt.Z)((Gi||[]).map(Mr=>String(Mr)),So,!0):So.length===0;Do=Nt.createElement(Nt.Fragment,null,er(),Nt.createElement("div",{className:`${Ve}-dropdown-btns`},Nt.createElement(Gr.ZP,{type:"link",size:"small",disabled:Lr(),onClick:()=>rr()},li.filterReset),Nt.createElement(Gr.ZP,{type:"primary",size:"small",onClick:ys},li.filterConfirm)))}He.filterDropdown&&(Do=Nt.createElement(Zo.J,{selectable:void 0},Do));const Go=()=>Nt.createElement(vl,{className:`${Ve}-dropdown`},Do);let yo;typeof He.filterIcon=="function"?yo=He.filterIcon(tr):He.filterIcon?yo=He.filterIcon:yo=Nt.createElement(ts,null);const{direction:Ar}=Nt.useContext(Ys.E_);return Nt.createElement("div",{className:`${Ve}-column`},Nt.createElement("span",{className:`${Te}-column-title`},qn),Nt.createElement(Ul.Z,{dropdownRender:Go,trigger:["click"],open:oo,onOpenChange:Fr,getPopupContainer:Oi,placement:Ar==="rtl"?"bottomLeft":"bottomRight"},Nt.createElement("span",{role:"button",tabIndex:-1,className:me()(`${Ve}-trigger`,{active:tr}),onClick:So=>{So.stopPropagation()}},yo)))}var _a=Xa;function ka(Xt,ee,Ee){let Te=[];return(Xt||[]).forEach((Ve,He)=>{var dn;const fn=ga(He,Ee);if(Ve.filters||"filterDropdown"in Ve||"onFilter"in Ve)if("filteredValue"in Ve){let ln=Ve.filteredValue;"filterDropdown"in Ve||(ln=(dn=ln==null?void 0:ln.map(String))!==null&&dn!==void 0?dn:ln),Te.push({column:Ve,key:Jr(Ve,fn),filteredKeys:ln,forceFiltered:Ve.filtered})}else Te.push({column:Ve,key:Jr(Ve,fn),filteredKeys:ee&&Ve.defaultFilteredValue?Ve.defaultFilteredValue:void 0,forceFiltered:Ve.filtered});"children"in Ve&&(Te=[].concat((0,ii.Z)(Te),(0,ii.Z)(ka(Ve.children,ee,fn))))}),Te}function Pu(Xt,ee,Ee,Te,Ve,He,dn,fn){return Ee.map((ln,On)=>{const Rn=ga(On,fn),{filterMultiple:In=!0,filterMode:pi,filterSearch:li}=ln;let qn=ln;if(qn.filters||qn.filterDropdown){const Oi=Jr(qn,Rn),si=Te.find(ki=>{let{key:Ei}=ki;return Oi===Ei});qn=Object.assign(Object.assign({},qn),{title:ki=>Nt.createElement(_a,{tablePrefixCls:Xt,prefixCls:`${Xt}-filter`,dropdownPrefixCls:ee,column:qn,columnKey:Oi,filterState:si,filterMultiple:In,filterMode:pi,filterSearch:li,triggerFilter:He,locale:Ve,getPopupContainer:dn},Qs(ln.title,ki))})}return"children"in qn&&(qn=Object.assign(Object.assign({},qn),{children:Pu(Xt,ee,qn.children,Te,Ve,He,dn,Rn)})),qn})}function Bu(Xt){const ee={};return Xt.forEach(Ee=>{let{key:Te,filteredKeys:Ve,column:He}=Ee;const{filters:dn,filterDropdown:fn}=He;if(fn)ee[Te]=Ve||null;else if(Array.isArray(Ve)){const ln=Tl(dn);ee[Te]=ln.filter(On=>Ve.includes(String(On)))}else ee[Te]=null}),ee}function Da(Xt,ee){return ee.reduce((Ee,Te)=>{const{column:{onFilter:Ve,filters:He},filteredKeys:dn}=Te;return Ve&&dn&&dn.length?Ee.filter(fn=>dn.some(ln=>{const On=Tl(He),Rn=On.findIndex(pi=>String(pi)===String(ln)),In=Rn!==-1?On[Rn]:ln;return Ve(In,fn)})):Ee},Xt)}const sl=Xt=>Xt.flatMap(ee=>"children"in ee?[ee].concat((0,ii.Z)(sl(ee.children||[]))):[ee]);function Hh(Xt){let{prefixCls:ee,dropdownPrefixCls:Ee,mergedColumns:Te,onFilterChange:Ve,getPopupContainer:He,locale:dn}=Xt;const fn=Nt.useMemo(()=>sl(Te||[]),[Te]),[ln,On]=Nt.useState(()=>ka(fn,!0)),Rn=Nt.useMemo(()=>{const qn=ka(fn,!1);if(qn.length===0)return qn;let Oi=!0,si=!0;if(qn.forEach(ki=>{let{filteredKeys:Ei}=ki;Ei!==void 0?Oi=!1:si=!1}),Oi){const ki=(fn||[]).map((Ei,Gi)=>Jr(Ei,ga(Gi)));return ln.filter(Ei=>{let{key:Gi}=Ei;return ki.includes(Gi)}).map(Ei=>{const Gi=fn[ki.findIndex(vo=>vo===Ei.key)];return Object.assign(Object.assign({},Ei),{column:Object.assign(Object.assign({},Ei.column),Gi),forceFiltered:Gi.filtered})})}return qn},[fn,ln]),In=Nt.useMemo(()=>Bu(Rn),[Rn]),pi=qn=>{const Oi=Rn.filter(si=>{let{key:ki}=si;return ki!==qn.key});Oi.push(qn),On(Oi),Ve(Bu(Oi),Oi)};return[qn=>Pu(ee,Ee,qn,Rn,dn,pi,He),Rn,In]}var hd=Hh;function Gh(Xt,ee,Ee){const Te=Nt.useRef({});function Ve(He){if(!Te.current||Te.current.data!==Xt||Te.current.childrenColumnName!==ee||Te.current.getRowKey!==Ee){let fn=function(ln){ln.forEach((On,Rn)=>{const In=Ee(On,Rn);dn.set(In,On),On&&typeof On=="object"&&ee in On&&fn(On[ee]||[])})};const dn=new Map;fn(Xt),Te.current={data:Xt,childrenColumnName:ee,kvMap:dn,getRowKey:Ee}}return Te.current.kvMap.get(He)}return[Ve]}var $d=wt(50371),$h=function(Xt,ee){var Ee={};for(var Te in Xt)Object.prototype.hasOwnProperty.call(Xt,Te)&&ee.indexOf(Te)<0&&(Ee[Te]=Xt[Te]);if(Xt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Ve=0,Te=Object.getOwnPropertySymbols(Xt);Ve{const He=Xt[Ve];typeof He!="function"&&(Ee[Ve]=He)}),Ee}function Fl(Xt,ee,Ee){const Te=Ee&&typeof Ee=="object"?Ee:{},{total:Ve=0}=Te,He=$h(Te,["total"]),[dn,fn]=(0,Nt.useState)(()=>({current:"defaultCurrent"in He?He.defaultCurrent:1,pageSize:"defaultPageSize"in He?He.defaultPageSize:mh})),ln=(0,$d.Z)(dn,He,{total:Ve>0?Ve:Xt}),On=Math.ceil((Ve||Xt)/ln.pageSize);ln.current>On&&(ln.current=On||1);const Rn=(pi,li)=>{fn({current:pi!=null?pi:1,pageSize:li||ln.pageSize})},In=(pi,li)=>{var qn;Ee&&((qn=Ee.onChange)===null||qn===void 0||qn.call(Ee,pi,li)),Rn(pi,li),ee(pi,li||(ln==null?void 0:ln.pageSize))};return Ee===!1?[{},()=>{}]:[Object.assign(Object.assign({},ln),{onChange:In}),Rn]}var dd=Fl,Wh=wt(84105),vh=wt(35654),Wo=wt(90782),Cr=wt(71430),xa=wt(18929);const Ks={},Is="SELECT_ALL",is="SELECT_INVERT",vs="SELECT_NONE",Hs=[],Bs=(Xt,ee)=>{let Ee=[];return(ee||[]).forEach(Te=>{Ee.push(Te),Te&&typeof Te=="object"&&Xt in Te&&(Ee=[].concat((0,ii.Z)(Ee),(0,ii.Z)(Bs(Xt,Te[Xt]))))}),Ee};var Il=(Xt,ee)=>{const{preserveSelectedRowKeys:Ee,selectedRowKeys:Te,defaultSelectedRowKeys:Ve,getCheckboxProps:He,onChange:dn,onSelect:fn,onSelectAll:ln,onSelectInvert:On,onSelectNone:Rn,onSelectMultiple:In,columnWidth:pi,type:li,selections:qn,fixed:Oi,renderCell:si,hideSelectAll:ki,checkStrictly:Ei=!0}=ee||{},{prefixCls:Gi,data:vo,pageData:To,getRecordByKey:Ii,getRowKey:mo,expandType:tr,childrenColumnName:ji,locale:oo,getPopupContainer:zi}=Xt,[Pi,_i]=(0,xa.Z)(Te||Ve||Hs,{value:Te}),bo=Nt.useRef(new Map),zo=(0,Nt.useCallback)(Ho=>{if(Ee){const Do=new Map;Ho.forEach(Go=>{let yo=Ii(Go);!yo&&bo.current.has(Go)&&(yo=bo.current.get(Go)),Do.set(Go,yo)}),bo.current=Do}},[Ii,Ee]);Nt.useEffect(()=>{zo(Pi)},[Pi]);const{keyEntities:jo}=(0,Nt.useMemo)(()=>{if(Ei)return{keyEntities:null};let Ho=vo;if(Ee){const Do=new Set(vo.map((yo,Ar)=>mo(yo,Ar))),Go=Array.from(bo.current).reduce((yo,Ar)=>{let[So,er]=Ar;return Do.has(So)?yo:yo.concat(er)},[]);Ho=[].concat((0,ii.Z)(Ho),(0,ii.Z)(Go))}return(0,Cr.I8)(Ho,{externalGetKey:mo,childrenPropName:ji})},[vo,mo,Ei,ji,Ee]),Bi=(0,Nt.useMemo)(()=>Bs(ji,To),[ji,To]),ir=(0,Nt.useMemo)(()=>{const Ho=new Map;return Bi.forEach((Do,Go)=>{const yo=mo(Do,Go),Ar=(He?He(Do):null)||{};Ho.set(yo,Ar)}),Ho},[Bi,mo,He]),ur=(0,Nt.useCallback)(Ho=>{var Do;return!!(!((Do=ir.get(mo(Ho)))===null||Do===void 0)&&Do.disabled)},[ir,mo]),[$r,Pr]=(0,Nt.useMemo)(()=>{if(Ei)return[Pi||[],[]];const{checkedKeys:Ho,halfCheckedKeys:Do}=(0,Wo.S)(Pi,!0,jo,ur);return[Ho||[],Do]},[Pi,Ei,jo,ur]),ws=(0,Nt.useMemo)(()=>{const Ho=li==="radio"?$r.slice(0,1):$r;return new Set(Ho)},[$r,li]),ys=(0,Nt.useMemo)(()=>li==="radio"?new Set:new Set(Pr),[Pr,li]),[rr,Eo]=(0,Nt.useState)(null);Nt.useEffect(()=>{ee||_i(Hs)},[!!ee]);const Fr=(0,Nt.useCallback)((Ho,Do)=>{let Go,yo;zo(Ho),Ee?(Go=Ho,yo=Ho.map(Ar=>bo.current.get(Ar))):(Go=[],yo=[],Ho.forEach(Ar=>{const So=Ii(Ar);So!==void 0&&(Go.push(Ar),yo.push(So))})),_i(Go),dn==null||dn(Go,yo,{type:Do})},[_i,Ii,dn,Ee]),Cs=(0,Nt.useCallback)((Ho,Do,Go,yo)=>{if(fn){const Ar=Go.map(So=>Ii(So));fn(Ii(Ho),Do,Ar,yo)}Fr(Go,"single")},[fn,Ii,Fr]),us=(0,Nt.useMemo)(()=>!qn||ki?null:(qn===!0?[Is,is,vs]:qn).map(Do=>Do===Is?{key:"all",text:oo.selectionAll,onSelect(){Fr(vo.map((Go,yo)=>mo(Go,yo)).filter(Go=>{const yo=ir.get(Go);return!(yo!=null&&yo.disabled)||ws.has(Go)}),"all")}}:Do===is?{key:"invert",text:oo.selectInvert,onSelect(){const Go=new Set(ws);To.forEach((Ar,So)=>{const er=mo(Ar,So),Lr=ir.get(er);Lr!=null&&Lr.disabled||(Go.has(er)?Go.delete(er):Go.add(er))});const yo=Array.from(Go);On&&On(yo),Fr(yo,"invert")}}:Do===vs?{key:"none",text:oo.selectNone,onSelect(){Rn==null||Rn(),Fr(Array.from(ws).filter(Go=>{const yo=ir.get(Go);return yo==null?void 0:yo.disabled}),"none")}}:Do).map(Do=>Object.assign(Object.assign({},Do),{onSelect:function(){for(var Go,yo,Ar=arguments.length,So=new Array(Ar),er=0;er{var Do;if(!ee)return Ho.filter(Kr=>Kr!==Ks);let Go=(0,ii.Z)(Ho);const yo=new Set(ws),Ar=Bi.map(mo).filter(Kr=>!ir.get(Kr).disabled),So=Ar.every(Kr=>yo.has(Kr)),er=Ar.some(Kr=>yo.has(Kr)),Lr=()=>{const Kr=[];So?Ar.forEach(ns=>{yo.delete(ns),Kr.push(ns)}):Ar.forEach(ns=>{yo.has(ns)||(yo.add(ns),Kr.push(ns))});const Xr=Array.from(yo);ln==null||ln(!So,Xr.map(ns=>Ii(ns)),Kr.map(ns=>Ii(ns))),Fr(Xr,"all"),Eo(null)};let Mr;if(li!=="radio"){let Kr;if(us){const vr={getPopupContainer:zi,items:us.map((rs,da)=>{const{key:ll,text:Dl,onSelect:Sl}=rs;return{key:ll!=null?ll:da,onClick:()=>{Sl==null||Sl(Ar)},label:Dl}})};Kr=Nt.createElement("div",{className:`${Gi}-selection-extra`},Nt.createElement(Ul.Z,{menu:vr,getPopupContainer:zi},Nt.createElement("span",null,Nt.createElement(Wh.Z,null))))}const Xr=Bi.map((vr,rs)=>{const da=mo(vr,rs),ll=ir.get(da)||{};return Object.assign({checked:yo.has(da)},ll)}).filter(vr=>{let{disabled:rs}=vr;return rs}),ns=!!Xr.length&&Xr.length===Bi.length,$s=ns&&Xr.every(vr=>{let{checked:rs}=vr;return rs}),ha=ns&&Xr.some(vr=>{let{checked:rs}=vr;return rs});Mr=!ki&&Nt.createElement("div",{className:`${Gi}-selection`},Nt.createElement(Ts.default,{checked:ns?$s:!!Bi.length&&So,indeterminate:ns?!$s&&ha:!So&&er,onChange:Lr,disabled:Bi.length===0||ns,"aria-label":Kr?"Custom selection":"Select all",skipGroup:!0}),Kr)}let va;li==="radio"?va=(Kr,Xr,ns)=>{const $s=mo(Xr,ns),ha=yo.has($s);return{node:Nt.createElement(ci.ZP,Object.assign({},ir.get($s),{checked:ha,onClick:vr=>vr.stopPropagation(),onChange:vr=>{yo.has($s)||Cs($s,!0,[$s],vr.nativeEvent)}})),checked:ha}}:va=(Kr,Xr,ns)=>{var $s;const ha=mo(Xr,ns),vr=yo.has(ha),rs=ys.has(ha),da=ir.get(ha);let ll;return tr==="nest"?ll=rs:ll=($s=da==null?void 0:da.indeterminate)!==null&&$s!==void 0?$s:rs,{node:Nt.createElement(Ts.default,Object.assign({},da,{indeterminate:ll,checked:vr,skipGroup:!0,onClick:Dl=>Dl.stopPropagation(),onChange:Dl=>{let{nativeEvent:Sl}=Dl;const{shiftKey:Xl}=Sl;let _l=-1,Al=-1;if(Xl&&Ei){const Ur=new Set([rr,ha]);Ar.some((Pa,As)=>{if(Ur.has(Pa))if(_l===-1)_l=As;else return Al=As,!0;return!1})}if(Al!==-1&&_l!==Al&&Ei){const Ur=Ar.slice(_l,Al+1),Pa=[];vr?Ur.forEach(ss=>{yo.has(ss)&&(Pa.push(ss),yo.delete(ss))}):Ur.forEach(ss=>{yo.has(ss)||(Pa.push(ss),yo.add(ss))});const As=Array.from(yo);In==null||In(!vr,As.map(ss=>Ii(ss)),Pa.map(ss=>Ii(ss))),Fr(As,"multiple")}else{const Ur=$r;if(Ei){const Pa=vr?(0,vh._5)(Ur,ha):(0,vh.L0)(Ur,ha);Cs(ha,!vr,Pa,Sl)}else{const Pa=(0,Wo.S)([].concat((0,ii.Z)(Ur),[ha]),!0,jo,ur),{checkedKeys:As,halfCheckedKeys:ss}=Pa;let Rl=As;if(vr){const ih=new Set(As);ih.delete(ha),Rl=(0,Wo.S)(Array.from(ih),{checked:!1,halfCheckedKeys:ss},jo,ur).checkedKeys}Cs(ha,!vr,Rl,Sl)}}Eo(vr?null:ha)}})),checked:vr}};const ia=(Kr,Xr,ns)=>{const{node:$s,checked:ha}=va(Kr,Xr,ns);return si?si(ha,Xr,ns,$s):$s};if(!Go.includes(Ks))if(Go.findIndex(Kr=>{var Xr;return((Xr=Kr[Io])===null||Xr===void 0?void 0:Xr.columnType)==="EXPAND_COLUMN"})===0){const[Kr,...Xr]=Go;Go=[Kr,Ks].concat((0,ii.Z)(Xr))}else Go=[Ks].concat((0,ii.Z)(Go));const Ra=Go.indexOf(Ks);Go=Go.filter((Kr,Xr)=>Kr!==Ks||Xr===Ra);const Wr=Go[Ra-1],ya=Go[Ra+1];let Xs=Oi;Xs===void 0&&((ya==null?void 0:ya.fixed)!==void 0?Xs=ya.fixed:(Wr==null?void 0:Wr.fixed)!==void 0&&(Xs=Wr.fixed)),Xs&&Wr&&((Do=Wr[Io])===null||Do===void 0?void 0:Do.columnType)==="EXPAND_COLUMN"&&Wr.fixed===void 0&&(Wr.fixed=Xs);const ua=me()(`${Gi}-selection-col`,{[`${Gi}-selection-col-with-dropdown`]:qn&&li==="checkbox"}),Gu={fixed:Xs,width:pi,className:`${Gi}-selection-column`,title:ee.columnTitle||Mr,render:ia,onCell:ee.onCell,[Io]:{className:ua}};return Go.map(Kr=>Kr===Ks?Gu:Kr)},[mo,Bi,ee,$r,ws,ys,pi,us,tr,rr,ir,In,Cs,ur]),ws]},xs=wt(89489),xc=wt(59477),Pc=wt(6848);const Kh="ascend",Yi="descend";function cd(Xt){return typeof Xt.sorter=="object"&&typeof Xt.sorter.multiple=="number"?Xt.sorter.multiple:!1}function Ce(Xt){return typeof Xt=="function"?Xt:Xt&&typeof Xt=="object"&&Xt.compare?Xt.compare:!1}function kn(Xt,ee){return ee?Xt[Xt.indexOf(ee)+1]:Xt[0]}function wc(Xt,ee,Ee){let Te=[];function Ve(He,dn){Te.push({column:He,key:Jr(He,dn),multiplePriority:cd(He),sortOrder:He.sortOrder})}return(Xt||[]).forEach((He,dn)=>{const fn=ga(dn,Ee);He.children?("sortOrder"in He&&Ve(He,fn),Te=[].concat((0,ii.Z)(Te),(0,ii.Z)(wc(He.children,ee,fn)))):He.sorter&&("sortOrder"in He?Ve(He,fn):ee&&He.defaultSortOrder&&Te.push({column:He,key:Jr(He,fn),multiplePriority:cd(He),sortOrder:He.defaultSortOrder}))}),Te}function rf(Xt,ee,Ee,Te,Ve,He,dn,fn){return(ee||[]).map((ln,On)=>{const Rn=ga(On,fn);let In=ln;if(In.sorter){const pi=In.sortDirections||Ve,li=In.showSorterTooltip===void 0?dn:In.showSorterTooltip,qn=Jr(In,Rn),Oi=Ee.find(tr=>{let{key:ji}=tr;return ji===qn}),si=Oi?Oi.sortOrder:null,ki=kn(pi,si);let Ei;if(ln.sortIcon)Ei=ln.sortIcon({sortOrder:si});else{const tr=pi.includes(Kh)&&Nt.createElement(xc.Z,{className:me()(`${Xt}-column-sorter-up`,{active:si===Kh})}),ji=pi.includes(Yi)&&Nt.createElement(xs.Z,{className:me()(`${Xt}-column-sorter-down`,{active:si===Yi})});Ei=Nt.createElement("span",{className:me()(`${Xt}-column-sorter`,{[`${Xt}-column-sorter-full`]:!!(tr&&ji)})},Nt.createElement("span",{className:`${Xt}-column-sorter-inner`,"aria-hidden":"true"},tr,ji))}const{cancelSort:Gi,triggerAsc:vo,triggerDesc:To}=He||{};let Ii=Gi;ki===Yi?Ii=To:ki===Kh&&(Ii=vo);const mo=typeof li=="object"?li:{title:Ii};In=Object.assign(Object.assign({},In),{className:me()(In.className,{[`${Xt}-column-sort`]:si}),title:tr=>{const ji=Nt.createElement("div",{className:`${Xt}-column-sorters`},Nt.createElement("span",{className:`${Xt}-column-title`},Qs(ln.title,tr)),Ei);return li?Nt.createElement(Pc.Z,Object.assign({},mo),ji):ji},onHeaderCell:tr=>{const ji=ln.onHeaderCell&&ln.onHeaderCell(tr)||{},oo=ji.onClick,zi=ji.onKeyDown;ji.onClick=bo=>{Te({column:ln,key:qn,sortOrder:ki,multiplePriority:cd(ln)}),oo==null||oo(bo)},ji.onKeyDown=bo=>{bo.keyCode===ei.Z.ENTER&&(Te({column:ln,key:qn,sortOrder:ki,multiplePriority:cd(ln)}),zi==null||zi(bo))};const Pi=Ea(ln.title,{}),_i=Pi==null?void 0:Pi.toString();return si?ji["aria-sort"]=si==="ascend"?"ascending":"descending":ji["aria-label"]=_i||"",ji.className=me()(ji.className,`${Xt}-column-has-sorters`),ji.tabIndex=0,ln.ellipsis&&(ji.title=(Pi!=null?Pi:"").toString()),ji}})}return"children"in In&&(In=Object.assign(Object.assign({},In),{children:rf(Xt,In.children,Ee,Te,Ve,He,dn,Rn)})),In})}function Ru(Xt){const{column:ee,sortOrder:Ee}=Xt;return{column:ee,order:Ee,field:ee.dataIndex,columnKey:ee.key}}function zu(Xt){const ee=Xt.filter(Ee=>{let{sortOrder:Te}=Ee;return Te}).map(Ru);return ee.length===0&&Xt.length?Object.assign(Object.assign({},Ru(Xt[Xt.length-1])),{column:void 0}):ee.length<=1?ee[0]||{}:ee}function nh(Xt,ee,Ee){const Te=ee.slice().sort((dn,fn)=>fn.multiplePriority-dn.multiplePriority),Ve=Xt.slice(),He=Te.filter(dn=>{let{column:{sorter:fn},sortOrder:ln}=dn;return Ce(fn)&&ln});return He.length?Ve.sort((dn,fn)=>{for(let ln=0;ln{const fn=dn[Ee];return fn?Object.assign(Object.assign({},dn),{[Ee]:nh(fn,ee,Ee)}):dn}):Ve}function Cc(Xt){let{prefixCls:ee,mergedColumns:Ee,onSorterChange:Te,sortDirections:Ve,tableLocale:He,showSorterTooltip:dn}=Xt;const[fn,ln]=Nt.useState(wc(Ee,!0)),On=Nt.useMemo(()=>{let qn=!0;const Oi=wc(Ee,!1);if(!Oi.length)return fn;const si=[];function ki(Gi){qn?si.push(Gi):si.push(Object.assign(Object.assign({},Gi),{sortOrder:null}))}let Ei=null;return Oi.forEach(Gi=>{Ei===null?(ki(Gi),Gi.sortOrder&&(Gi.multiplePriority===!1?qn=!1:Ei=!0)):(Ei&&Gi.multiplePriority!==!1||(qn=!1),ki(Gi))}),si},[Ee,fn]),Rn=Nt.useMemo(()=>{const qn=On.map(Oi=>{let{column:si,sortOrder:ki}=Oi;return{column:si,order:ki}});return{sortColumns:qn,sortColumn:qn[0]&&qn[0].column,sortOrder:qn[0]&&qn[0].order}},[On]);function In(qn){let Oi;qn.multiplePriority===!1||!On.length||On[0].multiplePriority===!1?Oi=[qn]:Oi=[].concat((0,ii.Z)(On.filter(si=>{let{key:ki}=si;return ki!==qn.key})),[qn]),ln(Oi),Te(zu(Oi),Oi)}return[qn=>rf(ee,qn,On,In,Ve,He,dn),On,Rn,()=>zu(On)]}function fd(Xt,ee){return Xt.map(Ee=>{const Te=Object.assign({},Ee);return Te.title=Qs(Ee.title,ee),"children"in Te&&(Te.children=fd(Te.children,ee)),Te})}function Ds(Xt){return[Nt.useCallback(Ee=>fd(Ee,Xt),[Xt])]}var No=co((Xt,ee)=>{const{_renderTimes:Ee}=Xt,{_renderTimes:Te}=ee;return Ee!==Te}),Ja=Sr((Xt,ee)=>{const{_renderTimes:Ee}=Xt,{_renderTimes:Te}=ee;return Ee!==Te}),Aa=wt(64993),ls=wt(17313),cr=wt(83116),na=wt(37613),os=Xt=>{const{componentCls:ee}=Xt,Ee=`${Xt.lineWidth}px ${Xt.lineType} ${Xt.tableBorderColor}`,Te=(Ve,He,dn)=>({[`&${ee}-${Ve}`]:{[`> ${ee}-container`]:{[`> ${ee}-content, > ${ee}-body`]:{"\n > table > tbody > tr > th,\n > table > tbody > tr > td\n ":{[`> ${ee}-expanded-row-fixed`]:{margin:`-${He}px -${dn+Xt.lineWidth}px`}}}}}});return{[`${ee}-wrapper`]:{[`${ee}${ee}-bordered`]:Object.assign(Object.assign(Object.assign({[`> ${ee}-title`]:{border:Ee,borderBottom:0},[`> ${ee}-container`]:{borderInlineStart:Ee,borderTop:Ee,[` > ${ee}-content, > ${ee}-header, > ${ee}-body, > ${ee}-summary `]:{"> table":{"\n > thead > tr > th,\n > thead > tr > td,\n > tbody > tr > th,\n > tbody > tr > td,\n > tfoot > tr > th,\n > tfoot > tr > td\n ":{borderInlineEnd:Ee},"> thead":{"> tr:not(:last-child) > th":{borderBottom:Ee},"> tr > th::before":{backgroundColor:"transparent !important"}},"\n > thead > tr,\n > tbody > tr,\n > tfoot > tr\n ":{[`> ${ee}-cell-fix-right-first::after`]:{borderInlineEnd:Ee}},"\n > tbody > tr > th,\n > tbody > tr > td\n ":{[`> ${ee}-expanded-row-fixed`]:{margin:`-${Xt.tablePaddingVertical}px -${Xt.tablePaddingHorizontal+Xt.lineWidth}px`,"&::after":{position:"absolute",top:0,insetInlineEnd:Xt.lineWidth,bottom:0,borderInlineEnd:Ee,content:'""'}}}}}},[`&${ee}-scroll-horizontal`]:{[`> ${ee}-container > ${ee}-body`]:{"> table > tbody":{[` > tr${ee}-expanded-row, > tr${ee}-placeholder `]:{"> th, > td":{borderInlineEnd:0}}}}}},Te("middle",Xt.tablePaddingVerticalMiddle,Xt.tablePaddingHorizontalMiddle)),Te("small",Xt.tablePaddingVerticalSmall,Xt.tablePaddingHorizontalSmall)),{[`> ${ee}-footer`]:{border:Ee,borderTop:0}}),[`${ee}-cell`]:{[`${ee}-container:first-child`]:{borderTop:0},"&-scrollbar:not([rowspan])":{boxShadow:`0 ${Xt.lineWidth}px 0 ${Xt.lineWidth}px ${Xt.tableHeaderBg}`}},[`${ee}-bordered ${ee}-cell-scrollbar`]:{borderInlineEnd:Ee}}}},ma=Xt=>{const{componentCls:ee}=Xt;return{[`${ee}-wrapper`]:{[`${ee}-cell-ellipsis`]:Object.assign(Object.assign({},ls.vS),{wordBreak:"keep-all",[` &${ee}-cell-fix-left-last, &${ee}-cell-fix-right-first `]:{overflow:"visible",[`${ee}-cell-content`]:{display:"block",overflow:"hidden",textOverflow:"ellipsis"}},[`${ee}-column-title`]:{overflow:"hidden",textOverflow:"ellipsis",wordBreak:"keep-all"}})}}},Nr=Xt=>{const{componentCls:ee}=Xt;return{[`${ee}-wrapper`]:{[`${ee}-tbody > tr${ee}-placeholder`]:{textAlign:"center",color:Xt.colorTextDisabled,"\n &:hover > th,\n &:hover > td,\n ":{background:Xt.colorBgContainer}}}}},Qa=wt(15969),es=Xt=>{const{componentCls:ee,antCls:Ee,controlInteractiveSize:Te,motionDurationSlow:Ve,lineWidth:He,paddingXS:dn,lineType:fn,tableBorderColor:ln,tableExpandIconBg:On,tableExpandColumnWidth:Rn,borderRadius:In,fontSize:pi,fontSizeSM:li,lineHeight:qn,tablePaddingVertical:Oi,tablePaddingHorizontal:si,tableExpandedRowBg:ki,paddingXXS:Ei}=Xt,Gi=Te/2-He,vo=Gi*2+He*3,To=`${He}px ${fn} ${ln}`,Ii=Ei-He;return{[`${ee}-wrapper`]:{[`${ee}-expand-icon-col`]:{width:Rn},[`${ee}-row-expand-icon-cell`]:{textAlign:"center",[`${ee}-row-expand-icon`]:{display:"inline-flex",float:"none",verticalAlign:"sub"}},[`${ee}-row-indent`]:{height:1,float:"left"},[`${ee}-row-expand-icon`]:Object.assign(Object.assign({},(0,Qa.N)(Xt)),{position:"relative",float:"left",boxSizing:"border-box",width:vo,height:vo,padding:0,color:"inherit",lineHeight:`${vo}px`,background:On,border:To,borderRadius:In,transform:`scale(${Te/vo})`,transition:`all ${Ve}`,userSelect:"none","&:focus, &:hover, &:active":{borderColor:"currentcolor"},"&::before, &::after":{position:"absolute",background:"currentcolor",transition:`transform ${Ve} ease-out`,content:'""'},"&::before":{top:Gi,insetInlineEnd:Ii,insetInlineStart:Ii,height:He},"&::after":{top:Ii,bottom:Ii,insetInlineStart:Gi,width:He,transform:"rotate(90deg)"},"&-collapsed::before":{transform:"rotate(-180deg)"},"&-collapsed::after":{transform:"rotate(0deg)"},"&-spaced":{"&::before, &::after":{display:"none",content:"none"},background:"transparent",border:0,visibility:"hidden"}}),[`${ee}-row-indent + ${ee}-row-expand-icon`]:{marginTop:(pi*qn-He*3)/2-Math.ceil((li*1.4-He*3)/2),marginInlineEnd:dn},[`tr${ee}-expanded-row`]:{"&, &:hover":{"> th, > td":{background:ki}},[`${Ee}-descriptions-view`]:{display:"flex",table:{flex:"auto",width:"auto"}}},[`${ee}-expanded-row-fixed`]:{position:"relative",margin:`-${Oi}px -${si}px`,padding:`${Oi}px ${si}px`}}}},Gs=Xt=>{const{componentCls:ee,antCls:Ee,iconCls:Te,tableFilterDropdownWidth:Ve,tableFilterDropdownSearchWidth:He,paddingXXS:dn,paddingXS:fn,colorText:ln,lineWidth:On,lineType:Rn,tableBorderColor:In,tableHeaderIconColor:pi,fontSizeSM:li,tablePaddingHorizontal:qn,borderRadius:Oi,motionDurationSlow:si,colorTextDescription:ki,colorPrimary:Ei,tableHeaderFilterActiveBg:Gi,colorTextDisabled:vo,tableFilterDropdownBg:To,tableFilterDropdownHeight:Ii,controlItemBgHover:mo,controlItemBgActive:tr,boxShadowSecondary:ji,filterDropdownMenuBg:oo}=Xt,zi=`${Ee}-dropdown`,Pi=`${ee}-filter-dropdown`,_i=`${Ee}-tree`,bo=`${On}px ${Rn} ${In}`;return[{[`${ee}-wrapper`]:{[`${ee}-filter-column`]:{display:"flex",justifyContent:"space-between"},[`${ee}-filter-trigger`]:{position:"relative",display:"flex",alignItems:"center",marginBlock:-dn,marginInline:`${dn}px ${-qn/2}px`,padding:`0 ${dn}px`,color:pi,fontSize:li,borderRadius:Oi,cursor:"pointer",transition:`all ${si}`,"&:hover":{color:ki,background:Gi},"&.active":{color:Ei}}}},{[`${Ee}-dropdown`]:{[Pi]:Object.assign(Object.assign({},(0,ls.Wf)(Xt)),{minWidth:Ve,backgroundColor:To,borderRadius:Oi,boxShadow:ji,overflow:"hidden",[`${zi}-menu`]:{maxHeight:Ii,overflowX:"hidden",border:0,boxShadow:"none",borderRadius:"unset",backgroundColor:oo,"&:empty::after":{display:"block",padding:`${fn}px 0`,color:vo,fontSize:li,textAlign:"center",content:'"Not Found"'}},[`${Pi}-tree`]:{paddingBlock:`${fn}px 0`,paddingInline:fn,[_i]:{padding:0},[`${_i}-treenode ${_i}-node-content-wrapper:hover`]:{backgroundColor:mo},[`${_i}-treenode-checkbox-checked ${_i}-node-content-wrapper`]:{"&, &:hover":{backgroundColor:tr}}},[`${Pi}-search`]:{padding:fn,borderBottom:bo,"&-input":{input:{minWidth:He},[Te]:{color:vo}}},[`${Pi}-checkall`]:{width:"100%",marginBottom:dn,marginInlineStart:dn},[`${Pi}-btns`]:{display:"flex",justifyContent:"space-between",padding:`${fn-On}px ${fn}px`,overflow:"hidden",borderTop:bo}})}},{[`${Ee}-dropdown ${Pi}, ${Pi}-submenu`]:{[`${Ee}-checkbox-wrapper + span`]:{paddingInlineStart:fn,color:ln},"> ul":{maxHeight:"calc(100vh - 130px)",overflowX:"hidden",overflowY:"auto"}}}]},Vh=Xt=>{const{componentCls:ee,lineWidth:Ee,colorSplit:Te,motionDurationSlow:Ve,zIndexTableFixed:He,tableBg:dn,zIndexTableSticky:fn}=Xt,ln=Te;return{[`${ee}-wrapper`]:{[` ${ee}-cell-fix-left, ${ee}-cell-fix-right `]:{position:"sticky !important",zIndex:He,background:dn},[` ${ee}-cell-fix-left-first::after, ${ee}-cell-fix-left-last::after `]:{position:"absolute",top:0,right:{_skip_check_:!0,value:0},bottom:-Ee,width:30,transform:"translateX(100%)",transition:`box-shadow ${Ve}`,content:'""',pointerEvents:"none"},[`${ee}-cell-fix-left-all::after`]:{display:"none"},[` ${ee}-cell-fix-right-first::after, ${ee}-cell-fix-right-last::after `]:{position:"absolute",top:0,bottom:-Ee,left:{_skip_check_:!0,value:0},width:30,transform:"translateX(-100%)",transition:`box-shadow ${Ve}`,content:'""',pointerEvents:"none"},[`${ee}-container`]:{"&::before, &::after":{position:"absolute",top:0,bottom:0,zIndex:fn+1,width:30,transition:`box-shadow ${Ve}`,content:'""',pointerEvents:"none"},"&::before":{insetInlineStart:0},"&::after":{insetInlineEnd:0}},[`${ee}-ping-left`]:{[`&:not(${ee}-has-fix-left) ${ee}-container`]:{position:"relative","&::before":{boxShadow:`inset 10px 0 8px -8px ${ln}`}},[` ${ee}-cell-fix-left-first::after, ${ee}-cell-fix-left-last::after `]:{boxShadow:`inset 10px 0 8px -8px ${ln}`},[`${ee}-cell-fix-left-last::before`]:{backgroundColor:"transparent !important"}},[`${ee}-ping-right`]:{[`&:not(${ee}-has-fix-right) ${ee}-container`]:{position:"relative","&::after":{boxShadow:`inset -10px 0 8px -8px ${ln}`}},[` ${ee}-cell-fix-right-first::after, ${ee}-cell-fix-right-last::after `]:{boxShadow:`inset -10px 0 8px -8px ${ln}`}}}}},$f=Xt=>{const{componentCls:ee,antCls:Ee}=Xt;return{[`${ee}-wrapper`]:{[`${ee}-pagination${Ee}-pagination`]:{margin:`${Xt.margin}px 0`},[`${ee}-pagination`]:{display:"flex",flexWrap:"wrap",rowGap:Xt.paddingXS,"> *":{flex:"none"},"&-left":{justifyContent:"flex-start"},"&-center":{justifyContent:"center"},"&-right":{justifyContent:"flex-end"}}}}},Wf=Xt=>{const{componentCls:ee,tableRadius:Ee}=Xt;return{[`${ee}-wrapper`]:{[ee]:{[`${ee}-title, ${ee}-header`]:{borderRadius:`${Ee}px ${Ee}px 0 0`},[`${ee}-title + ${ee}-container`]:{borderStartStartRadius:0,borderStartEndRadius:0,[`${ee}-header, table`]:{borderRadius:0},"table > thead > tr:first-child":{"th:first-child, th:last-child, td:first-child, td:last-child":{borderRadius:0}}},"&-container":{borderStartStartRadius:Ee,borderStartEndRadius:Ee,"table > thead > tr:first-child":{"> *:first-child":{borderStartStartRadius:Ee},"> *:last-child":{borderStartEndRadius:Ee}}},"&-footer":{borderRadius:`0 0 ${Ee}px ${Ee}px`}}}}},Kd=Xt=>{const{componentCls:ee}=Xt;return{[`${ee}-wrapper-rtl`]:{direction:"rtl",table:{direction:"rtl"},[`${ee}-pagination-left`]:{justifyContent:"flex-end"},[`${ee}-pagination-right`]:{justifyContent:"flex-start"},[`${ee}-row-expand-icon`]:{float:"right","&::after":{transform:"rotate(-90deg)"},"&-collapsed::before":{transform:"rotate(180deg)"},"&-collapsed::after":{transform:"rotate(0deg)"}},[`${ee}-container`]:{"&::before":{insetInlineStart:"unset",insetInlineEnd:0},"&::after":{insetInlineStart:0,insetInlineEnd:"unset"},[`${ee}-row-indent`]:{float:"right"}}}}},bc=Xt=>{const{componentCls:ee,antCls:Ee,iconCls:Te,fontSizeIcon:Ve,padding:He,paddingXS:dn,tableHeaderIconColor:fn,tableHeaderIconColorHover:ln,tableSelectionColumnWidth:On}=Xt;return{[`${ee}-wrapper`]:{[`${ee}-selection-col`]:{width:On,[`&${ee}-selection-col-with-dropdown`]:{width:On+Ve+He/4}},[`${ee}-bordered ${ee}-selection-col`]:{width:On+dn*2,[`&${ee}-selection-col-with-dropdown`]:{width:On+Ve+He/4+dn*2}},[` table tr th${ee}-selection-column, table tr td${ee}-selection-column `]:{paddingInlineEnd:Xt.paddingXS,paddingInlineStart:Xt.paddingXS,textAlign:"center",[`${Ee}-radio-wrapper`]:{marginInlineEnd:0}},[`table tr th${ee}-selection-column${ee}-cell-fix-left`]:{zIndex:Xt.zIndexTableFixed+1},[`table tr th${ee}-selection-column::after`]:{backgroundColor:"transparent !important"},[`${ee}-selection`]:{position:"relative",display:"inline-flex",flexDirection:"column"},[`${ee}-selection-extra`]:{position:"absolute",top:0,zIndex:1,cursor:"pointer",transition:`all ${Xt.motionDurationSlow}`,marginInlineStart:"100%",paddingInlineStart:`${Xt.tablePaddingHorizontal/4}px`,[Te]:{color:fn,fontSize:Ve,verticalAlign:"baseline","&:hover":{color:ln}}}}}},Uh=Xt=>{const{componentCls:ee}=Xt,Ee=(Te,Ve,He,dn)=>({[`${ee}${ee}-${Te}`]:{fontSize:dn,[` ${ee}-title, ${ee}-footer, ${ee}-cell, ${ee}-thead > tr > th, ${ee}-tbody > tr > th, ${ee}-tbody > tr > td, tfoot > tr > th, tfoot > tr > td `]:{padding:`${Ve}px ${He}px`},[`${ee}-filter-trigger`]:{marginInlineEnd:`-${He/2}px`},[`${ee}-expanded-row-fixed`]:{margin:`-${Ve}px -${He}px`},[`${ee}-tbody`]:{[`${ee}-wrapper:only-child ${ee}`]:{marginBlock:`-${Ve}px`,marginInline:`${Xt.tableExpandColumnWidth-He}px -${He}px`}},[`${ee}-selection-column`]:{paddingInlineStart:`${He/4}px`}}});return{[`${ee}-wrapper`]:Object.assign(Object.assign({},Ee("middle",Xt.tablePaddingVerticalMiddle,Xt.tablePaddingHorizontalMiddle,Xt.tableFontSizeMiddle)),Ee("small",Xt.tablePaddingVerticalSmall,Xt.tablePaddingHorizontalSmall,Xt.tableFontSizeSmall))}},ju=Xt=>{const{componentCls:ee,marginXXS:Ee,fontSizeIcon:Te,tableHeaderIconColor:Ve,tableHeaderIconColorHover:He}=Xt;return{[`${ee}-wrapper`]:{[`${ee}-thead th${ee}-column-has-sorters`]:{outline:"none",cursor:"pointer",transition:`all ${Xt.motionDurationSlow}`,"&:hover":{background:Xt.tableHeaderSortHoverBg,"&::before":{backgroundColor:"transparent !important"}},"&:focus-visible":{color:Xt.colorPrimary},[` &${ee}-cell-fix-left:hover, &${ee}-cell-fix-right:hover `]:{background:Xt.tableFixedHeaderSortActiveBg}},[`${ee}-thead th${ee}-column-sort`]:{background:Xt.tableHeaderSortBg,"&::before":{backgroundColor:"transparent !important"}},[`td${ee}-column-sort`]:{background:Xt.tableBodySortBg},[`${ee}-column-title`]:{position:"relative",zIndex:1,flex:1},[`${ee}-column-sorters`]:{display:"flex",flex:"auto",alignItems:"center",justifyContent:"space-between","&::after":{position:"absolute",inset:0,width:"100%",height:"100%",content:'""'}},[`${ee}-column-sorter`]:{marginInlineStart:Ee,color:Ve,fontSize:0,transition:`color ${Xt.motionDurationSlow}`,"&-inner":{display:"inline-flex",flexDirection:"column",alignItems:"center"},"&-up, &-down":{fontSize:Te,"&.active":{color:Xt.colorPrimary}},[`${ee}-column-sorter-up + ${ee}-column-sorter-down`]:{marginTop:"-0.3em"}},[`${ee}-column-sorters:hover ${ee}-column-sorter`]:{color:He}}}},Yh=Xt=>{const{componentCls:ee,opacityLoading:Ee,tableScrollThumbBg:Te,tableScrollThumbBgHover:Ve,tableScrollThumbSize:He,tableScrollBg:dn,zIndexTableSticky:fn,stickyScrollBarBorderRadius:ln}=Xt,On=`${Xt.lineWidth}px ${Xt.lineType} ${Xt.tableBorderColor}`;return{[`${ee}-wrapper`]:{[`${ee}-sticky`]:{"&-holder":{position:"sticky",zIndex:fn,background:Xt.colorBgContainer},"&-scroll":{position:"sticky",bottom:0,height:`${He}px !important`,zIndex:fn,display:"flex",alignItems:"center",background:dn,borderTop:On,opacity:Ee,"&:hover":{transformOrigin:"center bottom"},"&-bar":{height:He,backgroundColor:Te,borderRadius:ln,transition:`all ${Xt.motionDurationSlow}, transform none`,position:"absolute",bottom:0,"&:hover, &-active":{backgroundColor:Ve}}}}}}},Hu=Xt=>{const{componentCls:ee,lineWidth:Ee,tableBorderColor:Te}=Xt,Ve=`${Ee}px ${Xt.lineType} ${Te}`;return{[`${ee}-wrapper`]:{[`${ee}-summary`]:{position:"relative",zIndex:Xt.zIndexTableFixed,background:Xt.tableBg,"> tr":{"> th, > td":{borderBottom:Ve}}},[`div${ee}-summary`]:{boxShadow:`0 -${Ee}px 0 ${Te}`}}}},Sh=Xt=>{const{componentCls:ee}=Xt,Ee=`${Xt.lineWidth}px ${Xt.lineType} ${Xt.tableBorderColor}`,Te=`${ee}-expanded-row-cell`;return{[`${ee}-wrapper`]:{[`${ee}-tbody-virtual`]:{[`${ee}-row`]:{display:"flex",boxSizing:"border-box",width:"100%"},[`${ee}-cell`]:{borderBottom:Ee},[`${ee}-expanded-row`]:{[`${Te}${Te}-fixed`]:{position:"sticky",insetInlineStart:0,overflow:"hidden",width:`calc(var(--virtual-width) - ${Xt.lineWidth}px)`,borderInlineEnd:"none"}}},[`${ee}-bordered`]:{[`${ee}-tbody-virtual`]:{"&:after":{content:'""',insetInline:0,bottom:0,borderBottom:Ee,position:"absolute"},[`${ee}-cell`]:{borderInlineEnd:Ee,[`&${ee}-cell-fix-right-first:before`]:{content:'""',position:"absolute",insetBlock:0,insetInlineStart:-Xt.lineWidth,borderInlineStart:Ee}}}}}}};const wu=Xt=>{const{componentCls:ee,fontWeightStrong:Ee,tablePaddingVertical:Te,tablePaddingHorizontal:Ve,lineWidth:He,lineType:dn,tableBorderColor:fn,tableFontSize:ln,tableBg:On,tableRadius:Rn,tableHeaderTextColor:In,motionDurationMid:pi,tableHeaderBg:li,tableHeaderCellSplitColor:qn,tableRowHoverBg:Oi,tableSelectedRowBg:si,tableSelectedRowHoverBg:ki,tableFooterTextColor:Ei,tableFooterBg:Gi,paddingContentVerticalLG:vo}=Xt,To=`${He}px ${dn} ${fn}`;return{[`${ee}-wrapper`]:Object.assign(Object.assign({clear:"both",maxWidth:"100%"},(0,ls.dF)()),{[ee]:Object.assign(Object.assign({},(0,ls.Wf)(Xt)),{fontSize:ln,background:On,borderRadius:`${Rn}px ${Rn}px 0 0`}),table:{width:"100%",textAlign:"start",borderRadius:`${Rn}px ${Rn}px 0 0`,borderCollapse:"separate",borderSpacing:0},[` ${ee}-cell, ${ee}-thead > tr > th, ${ee}-tbody > tr > th, ${ee}-tbody > tr > td, tfoot > tr > th, tfoot > tr > td `]:{position:"relative",padding:`${vo}px ${Ve}px`,overflowWrap:"break-word"},[`${ee}-title`]:{padding:`${Te}px ${Ve}px`},[`${ee}-thead`]:{"\n > tr > th,\n > tr > td\n ":{position:"relative",color:In,fontWeight:Ee,textAlign:"start",background:li,borderBottom:To,transition:`background ${pi} ease`,"&[colspan]:not([colspan='1'])":{textAlign:"center"},[`&:not(:last-child):not(${ee}-selection-column):not(${ee}-row-expand-icon-cell):not([colspan])::before`]:{position:"absolute",top:"50%",insetInlineEnd:0,width:1,height:"1.6em",backgroundColor:qn,transform:"translateY(-50%)",transition:`background-color ${pi}`,content:'""'}},"> tr:not(:last-child) > th[colspan]":{borderBottom:0}},[`${ee}-tbody`]:{"> tr":{"> th, > td":{transition:`background ${pi}, border-color ${pi}`,borderBottom:To,[` > ${ee}-wrapper:only-child, > ${ee}-expanded-row-fixed > ${ee}-wrapper:only-child `]:{[ee]:{marginBlock:`-${Te}px`,marginInline:`${Xt.tableExpandColumnWidth-Ve}px -${Ve}px`,[`${ee}-tbody > tr:last-child > td`]:{borderBottom:0,"&:first-child, &:last-child":{borderRadius:0}}}}},"> th":{position:"relative",color:In,fontWeight:Ee,textAlign:"start",background:li,borderBottom:To,transition:`background ${pi} ease`},[` &${ee}-row:hover > th, &${ee}-row:hover > td, > th${ee}-cell-row-hover, > td${ee}-cell-row-hover `]:{background:Oi},[`&${ee}-row-selected`]:{"> th, > td":{background:si},"&:hover > th, &:hover > td":{background:ki}}}},[`${ee}-footer`]:{padding:`${Te}px ${Ve}px`,color:Ei,background:Gi}})}};var xh=(0,cr.Z)("Table",Xt=>{const{colorTextHeading:ee,colorSplit:Ee,colorIcon:Te,colorIconHover:Ve,opacityLoading:He,colorBgContainer:dn,controlInteractiveSize:fn,headerBg:ln,headerColor:On,headerSortActiveBg:Rn,headerSortHoverBg:In,bodySortBg:pi,rowHoverBg:li,rowSelectedBg:qn,rowSelectedHoverBg:Oi,rowExpandedBg:si,cellPaddingBlock:ki,cellPaddingInline:Ei,cellPaddingBlockMD:Gi,cellPaddingInlineMD:vo,cellPaddingBlockSM:To,cellPaddingInlineSM:Ii,borderColor:mo,footerBg:tr,footerColor:ji,headerBorderRadius:oo,cellFontSize:zi,cellFontSizeMD:Pi,cellFontSizeSM:_i,headerSplitColor:bo,fixedHeaderSortActiveBg:zo,headerFilterHoverBg:jo,filterDropdownBg:Bi,expandIconBg:ir,selectionColumnWidth:ur,stickyScrollBarBg:$r}=Xt,Pr=new Aa.C(Te),ws=new Aa.C(Ve),ys=2,rr=(0,na.TS)(Xt,{tableFontSize:zi,tableBg:dn,tableRadius:oo,tablePaddingVertical:ki,tablePaddingHorizontal:Ei,tablePaddingVerticalMiddle:Gi,tablePaddingHorizontalMiddle:vo,tablePaddingVerticalSmall:To,tablePaddingHorizontalSmall:Ii,tableBorderColor:mo,tableHeaderTextColor:On,tableHeaderBg:ln,tableFooterTextColor:ji,tableFooterBg:tr,tableHeaderCellSplitColor:bo,tableHeaderSortBg:Rn,tableHeaderSortHoverBg:In,tableHeaderIconColor:Pr.clone().setAlpha(Pr.getAlpha()*He).toRgbString(),tableHeaderIconColorHover:ws.clone().setAlpha(ws.getAlpha()*He).toRgbString(),tableBodySortBg:pi,tableFixedHeaderSortActiveBg:zo,tableHeaderFilterActiveBg:jo,tableFilterDropdownBg:Bi,tableRowHoverBg:li,tableSelectedRowBg:qn,tableSelectedRowHoverBg:Oi,zIndexTableFixed:ys,zIndexTableSticky:ys+1,tableFontSizeMiddle:Pi,tableFontSizeSmall:_i,tableSelectionColumnWidth:ur,tableExpandIconBg:ir,tableExpandColumnWidth:fn+2*Xt.padding,tableExpandedRowBg:si,tableFilterDropdownWidth:120,tableFilterDropdownHeight:264,tableFilterDropdownSearchWidth:140,tableScrollThumbSize:8,tableScrollThumbBg:$r,tableScrollThumbBgHover:ee,tableScrollBg:Ee});return[wu(rr),$f(rr),Hu(rr),ju(rr),Gs(rr),os(rr),Wf(rr),es(rr),Hu(rr),Nr(rr),bc(rr),Vh(rr),Yh(rr),ma(rr),Uh(rr),Kd(rr),Sh(rr)]},Xt=>{const{colorFillAlter:ee,colorBgContainer:Ee,colorTextHeading:Te,colorFillSecondary:Ve,colorFillContent:He,controlItemBgActive:dn,controlItemBgActiveHover:fn,padding:ln,paddingSM:On,paddingXS:Rn,colorBorderSecondary:In,borderRadiusLG:pi,fontSize:li,controlHeight:qn,colorTextPlaceholder:Oi}=Xt,si=new Aa.C(Ve).onBackground(Ee).toHexShortString(),ki=new Aa.C(He).onBackground(Ee).toHexShortString(),Ei=new Aa.C(ee).onBackground(Ee).toHexShortString();return{headerBg:Ei,headerColor:Te,headerSortActiveBg:si,headerSortHoverBg:ki,bodySortBg:Ei,rowHoverBg:Ei,rowSelectedBg:dn,rowSelectedHoverBg:fn,rowExpandedBg:ee,cellPaddingBlock:ln,cellPaddingInline:ln,cellPaddingBlockMD:On,cellPaddingInlineMD:Rn,cellPaddingBlockSM:Rn,cellPaddingInlineSM:Rn,borderColor:In,headerBorderRadius:pi,footerBg:Ei,footerColor:Te,cellFontSize:li,cellFontSizeMD:li,cellFontSizeSM:li,headerSplitColor:In,fixedHeaderSortActiveBg:si,headerFilterHoverBg:He,filterDropdownMenuBg:Ee,filterDropdownBg:Ee,expandIconBg:Ee,selectionColumnWidth:qn,stickyScrollBarBg:Oi,stickyScrollBarBorderRadius:100}});const Lc=[],af=(Xt,ee)=>{const{prefixCls:Ee,className:Te,rootClassName:Ve,style:He,size:dn,bordered:fn,dropdownPrefixCls:ln,dataSource:On,pagination:Rn,rowSelection:In,rowKey:pi="key",rowClassName:li,columns:qn,children:Oi,childrenColumnName:si,onChange:ki,getPopupContainer:Ei,loading:Gi,expandIcon:vo,expandable:To,expandedRowRender:Ii,expandIconColumnIndex:mo,indentSize:tr,scroll:ji,sortDirections:oo,locale:zi,showSorterTooltip:Pi=!0,virtual:_i}=Xt,bo=Nt.useMemo(()=>qn||on(Oi),[qn,Oi]),zo=Nt.useMemo(()=>bo.some(Rr=>Rr.responsive),[bo]),jo=(0,Nn.Z)(zo),Bi=Nt.useMemo(()=>{const Rr=new Set(Object.keys(jo).filter(hs=>jo[hs]));return bo.filter(hs=>!hs.responsive||hs.responsive.some(oa=>Rr.has(oa)))},[bo,jo]),ir=(0,ao.Z)(Xt,["className","style","columns"]),{locale:ur=Zi.Z,direction:$r,table:Pr,renderEmpty:ws,getPrefixCls:ys,getPopupContainer:rr}=Nt.useContext(Ys.E_),Eo=(0,Ai.Z)(dn),Fr=Object.assign(Object.assign({},ur.Table),zi),Cs=On||Lc,us=ys("table",Ee),qs=ys("dropdown",ln),Ho=Object.assign({childrenColumnName:si,expandIconColumnIndex:mo},To),{childrenColumnName:Do="children"}=Ho,Go=Nt.useMemo(()=>Cs.some(Rr=>Rr==null?void 0:Rr[Do])?"nest":Ii||To&&To.expandedRowRender?"row":null,[Cs]),yo={body:Nt.useRef()},Ar=Nt.useMemo(()=>typeof pi=="function"?pi:Rr=>Rr==null?void 0:Rr[pi],[pi]),[So]=Gh(Cs,Do,Ar),er={},Lr=function(Rr,hs){let oa=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;var ds,Or,ca;const ul=Object.assign(Object.assign({},er),Rr);oa&&((ds=er.resetPagination)===null||ds===void 0||ds.call(er),!((Or=ul.pagination)===null||Or===void 0)&&Or.current&&(ul.pagination.current=1),Rn&&Rn.onChange&&Rn.onChange(1,(ca=ul.pagination)===null||ca===void 0?void 0:ca.pageSize)),ji&&ji.scrollToFirstRowOnChange!==!1&&yo.body.current&&(0,lr.Z)(0,{getContainer:()=>yo.body.current}),ki==null||ki(ul.pagination,ul.filters,ul.sorter,{currentDataSource:Da(nh(Cs,ul.sorterStates,Do),ul.filterStates),action:hs})},Mr=(Rr,hs)=>{Lr({sorter:Rr,sorterStates:hs},"sort",!1)},[va,ia,Ra,Wr]=Cc({prefixCls:us,mergedColumns:Bi,onSorterChange:Mr,sortDirections:oo||["ascend","descend"],tableLocale:Fr,showSorterTooltip:Pi}),ya=Nt.useMemo(()=>nh(Cs,ia,Do),[Cs,ia]);er.sorter=Wr(),er.sorterStates=ia;const Xs=(Rr,hs)=>{Lr({filters:Rr,filterStates:hs},"filter",!0)},[ua,Gu,Kr]=hd({prefixCls:us,locale:Fr,dropdownPrefixCls:qs,mergedColumns:Bi,onFilterChange:Xs,getPopupContainer:Ei||rr}),Xr=Da(ya,Gu);er.filters=Kr,er.filterStates=Gu;const ns=Nt.useMemo(()=>{const Rr={};return Object.keys(Kr).forEach(hs=>{Kr[hs]!==null&&(Rr[hs]=Kr[hs])}),Object.assign(Object.assign({},Ra),{filters:Rr})},[Ra,Kr]),[$s]=Ds(ns),ha=(Rr,hs)=>{Lr({pagination:Object.assign(Object.assign({},er.pagination),{current:Rr,pageSize:hs})},"paginate")},[vr,rs]=dd(Xr.length,ha,Rn);er.pagination=Rn===!1?{}:Du(vr,Rn),er.resetPagination=rs;const da=Nt.useMemo(()=>{if(Rn===!1||!vr.pageSize)return Xr;const{current:Rr=1,total:hs,pageSize:oa=mh}=vr;return Xr.lengthoa?Xr.slice((Rr-1)*oa,Rr*oa):Xr:Xr.slice((Rr-1)*oa,Rr*oa)},[!!Rn,Xr,vr&&vr.current,vr&&vr.pageSize,vr&&vr.total]),[ll,Dl]=Il({prefixCls:us,data:Xr,pageData:da,getRowKey:Ar,getRecordByKey:So,expandType:Go,childrenColumnName:Do,locale:Fr,getPopupContainer:Ei||rr},In),Sl=(Rr,hs,oa)=>{let ds;return typeof li=="function"?ds=me()(li(Rr,hs,oa)):ds=me()(li),me()({[`${us}-row-selected`]:Dl.has(Ar(Rr,hs))},ds)};Ho.__PARENT_RENDER_ICON__=Ho.expandIcon,Ho.expandIcon=Ho.expandIcon||vo||Ns(Fr),Go==="nest"&&Ho.expandIconColumnIndex===void 0?Ho.expandIconColumnIndex=In?1:0:Ho.expandIconColumnIndex>0&&In&&(Ho.expandIconColumnIndex-=1),typeof Ho.indentSize!="number"&&(Ho.indentSize=typeof tr=="number"?tr:15);const Xl=Nt.useCallback(Rr=>$s(ll(ua(va(Rr)))),[va,ua,ll]);let _l,Al;if(Rn!==!1&&(vr!=null&&vr.total)){let Rr;vr.size?Rr=vr.size:Rr=Eo==="small"||Eo==="middle"?"small":void 0;const hs=Or=>Nt.createElement(Xo.Z,Object.assign({},vr,{className:me()(`${us}-pagination ${us}-pagination-${Or}`,vr.className),size:Rr})),oa=$r==="rtl"?"left":"right",{position:ds}=vr;if(ds!==null&&Array.isArray(ds)){const Or=ds.find(du=>du.includes("top")),ca=ds.find(du=>du.includes("bottom")),ul=ds.every(du=>`${du}`=="none");!Or&&!ca&&!ul&&(Al=hs(oa)),Or&&(_l=hs(Or.toLowerCase().replace("top",""))),ca&&(Al=hs(ca.toLowerCase().replace("bottom","")))}else Al=hs(oa)}let Ur;typeof Gi=="boolean"?Ur={spinning:Gi}:typeof Gi=="object"&&(Ur=Object.assign({spinning:!0},Gi));const[Pa,As]=xh(us),[,ss]=(0,Ir.Z)(),Rl=me()(`${us}-wrapper`,Pr==null?void 0:Pr.className,{[`${us}-wrapper-rtl`]:$r==="rtl"},Te,Ve,As),ih=Object.assign(Object.assign({},Pr==null?void 0:Pr.style),He),Jl=zi&&zi.emptyText||(ws==null?void 0:ws("Table"))||Nt.createElement(qi.Z,{componentName:"Table"}),Cu=_i?Ja:No,$u={},xl=Nt.useMemo(()=>{const{fontSize:Rr,lineHeight:hs,padding:oa,paddingXS:ds,paddingSM:Or}=ss,ca=Math.floor(Rr*hs);switch(Eo){case"large":return oa*2+ca;case"small":return ds*2+ca;default:return Or*2+ca}},[ss,Eo]);return _i&&($u.listItemHeight=xl),Pa(Nt.createElement("div",{ref:ee,className:Rl,style:ih},Nt.createElement(zr.Z,Object.assign({spinning:!1},Ur),_l,Nt.createElement(Cu,Object.assign({},$u,ir,{columns:Bi,direction:$r,expandable:Ho,prefixCls:us,className:me()({[`${us}-middle`]:Eo==="middle",[`${us}-small`]:Eo==="small",[`${us}-bordered`]:fn,[`${us}-empty`]:Cs.length===0}),data:da,rowKey:Ar,rowClassName:Sl,emptyText:Jl,internalHooks:Ht,internalRefs:yo,transformColumns:Xl})),Al)))};var lf=Nt.forwardRef(af);const Vf=(Xt,ee)=>{const Ee=Nt.useRef(0);return Ee.current+=1,Nt.createElement(lf,Object.assign({},Xt,{ref:ee,_renderTimes:Ee.current}))},al=Nt.forwardRef(Vf);al.SELECTION_COLUMN=Ks,al.EXPAND_COLUMN=Ft,al.SELECTION_ALL=Is,al.SELECTION_INVERT=is,al.SELECTION_NONE=vs,al.Column=po,al.ColumnGroup=Ko,al.Summary=ne;var Ph=al,Kg=Ph},17574:function(Cn,cn,wt){"use strict";wt.d(cn,{default:function(){return se}});var Ft=wt(43858),Ht=wt(19127),oe=wt(52671),ke=wt(8657),Vt=wt(96663),qt=wt(59301),Nt={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M880 298.4H521L403.7 186.2a8.15 8.15 0 00-5.5-2.2H144c-17.7 0-32 14.3-32 32v592c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V330.4c0-17.7-14.3-32-32-32zM840 768H184V256h188.5l119.6 114.4H840V768z"}}]},name:"folder",theme:"outlined"},Oe=Nt,be=wt(7657),Qt=function($e,xn){return qt.createElement(be.Z,(0,Vt.Z)({},$e,{ref:xn,icon:Oe}))},Fe=qt.forwardRef(Qt),ye=Fe,Re=wt(92310),It=wt.n(Re),et=wt(35654),nt=wt(71430),dt=wt(36355),at=wt(56082),gt=wt(62892),mt=wt(20648);const Pt=4;function kt(jt){const{dropPosition:$e,dropLevelOffset:xn,prefixCls:En,indent:Ne,direction:Ze="ltr"}=jt,rn=Ze==="ltr"?"left":"right",zn=Ze==="ltr"?"right":"left",tn={[rn]:-xn*Ne+Pt,[zn]:0};switch($e){case-1:tn.top=-3;break;case 1:tn.bottom=-3;break;default:tn.bottom=-3,tn[rn]=Ne+Pt;break}return qt.createElement("div",{style:tn,className:`${En}-drop-indicator`})}var Tt=wt(71997),$t=qt.forwardRef((jt,$e)=>{const{getPrefixCls:xn,direction:En,virtual:Ne,tree:Ze}=qt.useContext(dt.E_),{prefixCls:rn,className:zn,showIcon:tn=!1,showLine:Tn,switcherIcon:we,blockNode:Bn=!1,children:Jn,checkable:Rt=!1,selectable:Lt=!0,draggable:St,motion:Et,style:Bt}=jt,yt=xn("tree",rn),ae=xn(),Pe=Et!=null?Et:Object.assign(Object.assign({},(0,gt.Z)(ae)),{motionAppear:!1}),ne=Object.assign(Object.assign({},jt),{checkable:Rt,selectable:Lt,showIcon:tn,motion:Pe,blockNode:Bn,showLine:!!Tn,dropIndicatorRender:kt}),[_t,ge]=(0,mt.ZP)(yt),pe=qt.useMemo(()=>{if(!St)return!1;let Me={};switch(typeof St){case"function":Me.nodeDraggable=St;break;case"object":Me=Object.assign({},St);break;default:break}return Me.icon!==!1&&(Me.icon=Me.icon||qt.createElement(at.Z,null)),Me},[St]),le=Me=>qt.createElement(Tt.Z,{prefixCls:yt,switcherIcon:we,treeNodeProps:Me,showLine:Tn});return _t(qt.createElement(Ft.Z,Object.assign({itemHeight:20,ref:$e,virtual:Ne},ne,{style:Object.assign(Object.assign({},Ze==null?void 0:Ze.style),Bt),prefixCls:yt,className:It()({[`${yt}-icon-hide`]:!tn,[`${yt}-block-node`]:Bn,[`${yt}-unselectable`]:!Lt,[`${yt}-rtl`]:En==="rtl"},Ze==null?void 0:Ze.className,zn,ge),direction:En,checkable:Rt&&qt.createElement("span",{className:`${yt}-checkbox-inner`}),selectable:Lt,switcherIcon:le,draggable:pe}),Jn))}),ie;(function(jt){jt[jt.None=0]="None",jt[jt.Start=1]="Start",jt[jt.End=2]="End"})(ie||(ie={}));function Yt(jt,$e){function xn(En){const{key:Ne,children:Ze}=En;$e(Ne,En)!==!1&&Yt(Ze||[],$e)}jt.forEach(xn)}function fe(jt){let{treeData:$e,expandedKeys:xn,startKey:En,endKey:Ne}=jt;const Ze=[];let rn=ie.None;if(En&&En===Ne)return[En];if(!En||!Ne)return[];function zn(tn){return tn===En||tn===Ne}return Yt($e,tn=>{if(rn===ie.End)return!1;if(zn(tn)){if(Ze.push(tn),rn===ie.None)rn=ie.Start;else if(rn===ie.Start)return rn=ie.End,!1}else rn===ie.Start&&Ze.push(tn);return xn.includes(tn)}),Ze}function Zt(jt,$e){const xn=(0,Ht.Z)($e),En=[];return Yt(jt,(Ne,Ze)=>{const rn=xn.indexOf(Ne);return rn!==-1&&(En.push(Ze),xn.splice(rn,1)),!!xn.length}),En}var je=function(jt,$e){var xn={};for(var En in jt)Object.prototype.hasOwnProperty.call(jt,En)&&$e.indexOf(En)<0&&(xn[En]=jt[En]);if(jt!=null&&typeof Object.getOwnPropertySymbols=="function")for(var Ne=0,En=Object.getOwnPropertySymbols(jt);Ne{var{defaultExpandAll:xn,defaultExpandParent:En,defaultExpandedKeys:Ne}=jt,Ze=je(jt,["defaultExpandAll","defaultExpandParent","defaultExpandedKeys"]);const rn=qt.useRef(),zn=qt.useRef(),tn=()=>{const{keyEntities:pe}=(0,nt.I8)(Xe(Ze));let le;return xn?le=Object.keys(pe):En?le=(0,et.r7)(Ze.expandedKeys||Ne||[],pe):le=Ze.expandedKeys||Ne,le},[Tn,we]=qt.useState(Ze.selectedKeys||Ze.defaultSelectedKeys||[]),[Bn,Jn]=qt.useState(()=>tn());qt.useEffect(()=>{"selectedKeys"in Ze&&we(Ze.selectedKeys)},[Ze.selectedKeys]),qt.useEffect(()=>{"expandedKeys"in Ze&&Jn(Ze.expandedKeys)},[Ze.expandedKeys]);const Rt=(pe,le)=>{var Me;return"expandedKeys"in Ze||Jn(pe),(Me=Ze.onExpand)===null||Me===void 0?void 0:Me.call(Ze,pe,le)},Lt=(pe,le)=>{var Me;const{multiple:nn}=Ze,{node:qe,nativeEvent:Ge}=le,{key:yn=""}=qe,wn=Xe(Ze),pn=Object.assign(Object.assign({},le),{selected:!0}),Yn=(Ge==null?void 0:Ge.ctrlKey)||(Ge==null?void 0:Ge.metaKey),ni=Ge==null?void 0:Ge.shiftKey;let Un;nn&&Yn?(Un=pe,rn.current=yn,zn.current=Un,pn.selectedNodes=Zt(wn,Un)):nn&&ni?(Un=Array.from(new Set([].concat((0,Ht.Z)(zn.current||[]),(0,Ht.Z)(fe({treeData:wn,expandedKeys:Bn,startKey:yn,endKey:rn.current}))))),pn.selectedNodes=Zt(wn,Un)):(Un=[yn],rn.current=yn,zn.current=Un,pn.selectedNodes=Zt(wn,Un)),(Me=Ze.onSelect)===null||Me===void 0||Me.call(Ze,Un,pn),"selectedKeys"in Ze||we(Un)},{getPrefixCls:St,direction:Et}=qt.useContext(dt.E_),{prefixCls:Bt,className:yt,showIcon:ae=!0,expandAction:Pe="click"}=Ze,ne=je(Ze,["prefixCls","className","showIcon","expandAction"]),_t=St("tree",Bt),ge=It()(`${_t}-directory`,{[`${_t}-directory-rtl`]:Et==="rtl"},yt);return qt.createElement($t,Object.assign({icon:me,ref:$e,blockNode:!0},ne,{showIcon:ae,expandAction:Pe,prefixCls:_t,className:ge,expandedKeys:Bn,selectedKeys:Tn,onSelect:Lt,onExpand:Rt}))};var ze=qt.forwardRef(Se);const Ue=$t;Ue.DirectoryTree=ze,Ue.TreeNode=Ft.O;var se=Ue},20648:function(Cn,cn,wt){"use strict";wt.d(cn,{TM:function(){return Re},Yk:function(){return ye}});var Ft=wt(93083),Ht=wt(98447),oe=wt(17313),ke=wt(8378),Vt=wt(37613),qt=wt(83116);const Nt=new Ft.Keyframes("ant-tree-node-fx-do-not-use",{"0%":{opacity:0},"100%":{opacity:1}}),Oe=(It,et)=>({[`.${It}-switcher-icon`]:{display:"inline-block",fontSize:10,verticalAlign:"baseline",svg:{transition:`transform ${et.motionDurationSlow}`}}}),be=(It,et)=>({[`.${It}-drop-indicator`]:{position:"absolute",zIndex:1,height:2,backgroundColor:et.colorPrimary,borderRadius:1,pointerEvents:"none","&:after":{position:"absolute",top:-3,insetInlineStart:-6,width:8,height:8,backgroundColor:"transparent",border:`${et.lineWidthBold}px solid ${et.colorPrimary}`,borderRadius:"50%",content:'""'}}}),Qt=(It,et)=>{const{treeCls:nt,treeNodeCls:dt,treeNodePadding:at,titleHeight:gt,nodeSelectedBg:mt,nodeHoverBg:Pt}=et,kt=et.paddingXS;return{[nt]:Object.assign(Object.assign({},(0,oe.Wf)(et)),{background:et.colorBgContainer,borderRadius:et.borderRadius,transition:`background-color ${et.motionDurationSlow}`,[`&${nt}-rtl`]:{[`${nt}-switcher`]:{"&_close":{[`${nt}-switcher-icon`]:{svg:{transform:"rotate(90deg)"}}}}},[`&-focused:not(:hover):not(${nt}-active-focused)`]:Object.assign({},(0,oe.oN)(et)),[`${nt}-list-holder-inner`]:{alignItems:"flex-start"},[`&${nt}-block-node`]:{[`${nt}-list-holder-inner`]:{alignItems:"stretch",[`${nt}-node-content-wrapper`]:{flex:"auto"},[`${dt}.dragging`]:{position:"relative","&:after":{position:"absolute",top:0,insetInlineEnd:0,bottom:at,insetInlineStart:0,border:`1px solid ${et.colorPrimary}`,opacity:0,animationName:Nt,animationDuration:et.motionDurationSlow,animationPlayState:"running",animationFillMode:"forwards",content:'""',pointerEvents:"none"}}}},[`${dt}`]:{display:"flex",alignItems:"flex-start",padding:`0 0 ${at}px 0`,outline:"none","&-rtl":{direction:"rtl"},"&-disabled":{[`${nt}-node-content-wrapper`]:{color:et.colorTextDisabled,cursor:"not-allowed","&:hover":{background:"transparent"}}},[`&-active ${nt}-node-content-wrapper`]:Object.assign({},(0,oe.oN)(et)),[`&:not(${dt}-disabled).filter-node ${nt}-title`]:{color:"inherit",fontWeight:500},"&-draggable":{[`${nt}-draggable-icon`]:{flexShrink:0,width:gt,lineHeight:`${gt}px`,textAlign:"center",visibility:"visible",opacity:.2,transition:`opacity ${et.motionDurationSlow}`,[`${dt}:hover &`]:{opacity:.45}},[`&${dt}-disabled`]:{[`${nt}-draggable-icon`]:{visibility:"hidden"}}}},[`${nt}-indent`]:{alignSelf:"stretch",whiteSpace:"nowrap",userSelect:"none","&-unit":{display:"inline-block",width:gt}},[`${nt}-draggable-icon`]:{visibility:"hidden"},[`${nt}-switcher`]:Object.assign(Object.assign({},Oe(It,et)),{position:"relative",flex:"none",alignSelf:"stretch",width:gt,margin:0,lineHeight:`${gt}px`,textAlign:"center",cursor:"pointer",userSelect:"none","&-noop":{cursor:"default"},"&_close":{[`${nt}-switcher-icon`]:{svg:{transform:"rotate(-90deg)"}}},"&-loading-icon":{color:et.colorPrimary},"&-leaf-line":{position:"relative",zIndex:1,display:"inline-block",width:"100%",height:"100%","&:before":{position:"absolute",top:0,insetInlineEnd:gt/2,bottom:-at,marginInlineStart:-1,borderInlineEnd:`1px solid ${et.colorBorder}`,content:'""'},"&:after":{position:"absolute",width:gt/2*.8,height:gt/2,borderBottom:`1px solid ${et.colorBorder}`,content:'""'}}}),[`${nt}-checkbox`]:{top:"initial",marginInlineEnd:kt},[`${nt}-node-content-wrapper, ${nt}-checkbox + span`]:{position:"relative",zIndex:"auto",minHeight:gt,margin:0,padding:`0 ${et.paddingXS/2}px`,color:"inherit",lineHeight:`${gt}px`,background:"transparent",borderRadius:et.borderRadius,cursor:"pointer",transition:`all ${et.motionDurationMid}, border 0s, line-height 0s, box-shadow 0s`,"&:hover":{backgroundColor:Pt},[`&${nt}-node-selected`]:{backgroundColor:mt},[`${nt}-iconEle`]:{display:"inline-block",width:gt,height:gt,lineHeight:`${gt}px`,textAlign:"center",verticalAlign:"top","&:empty":{display:"none"}}},[`${nt}-unselectable ${nt}-node-content-wrapper:hover`]:{backgroundColor:"transparent"},[`${nt}-node-content-wrapper`]:Object.assign({lineHeight:`${gt}px`,userSelect:"none"},be(It,et)),[`${dt}.drop-container`]:{"> [draggable]":{boxShadow:`0 0 0 2px ${et.colorPrimary}`}},"&-show-line":{[`${nt}-indent`]:{"&-unit":{position:"relative",height:"100%","&:before":{position:"absolute",top:0,insetInlineEnd:gt/2,bottom:-at,borderInlineEnd:`1px solid ${et.colorBorder}`,content:'""'},"&-end":{"&:before":{display:"none"}}}},[`${nt}-switcher`]:{background:"transparent","&-line-icon":{verticalAlign:"-0.15em"}}},[`${dt}-leaf-last`]:{[`${nt}-switcher`]:{"&-leaf-line":{"&:before":{top:"auto !important",bottom:"auto !important",height:`${gt/2}px !important`}}}}})}},Fe=It=>{const{treeCls:et,treeNodeCls:nt,treeNodePadding:dt,directoryNodeSelectedBg:at,directoryNodeSelectedColor:gt}=It;return{[`${et}${et}-directory`]:{[nt]:{position:"relative","&:before":{position:"absolute",top:0,insetInlineEnd:0,bottom:dt,insetInlineStart:0,transition:`background-color ${It.motionDurationMid}`,content:'""',pointerEvents:"none"},"&:hover":{"&:before":{background:It.controlItemBgHover}},"> *":{zIndex:1},[`${et}-switcher`]:{transition:`color ${It.motionDurationMid}`},[`${et}-node-content-wrapper`]:{borderRadius:0,userSelect:"none","&:hover":{background:"transparent"},[`&${et}-node-selected`]:{color:gt,background:"transparent"}},"&-selected":{"\n &:hover::before,\n &::before\n ":{background:at},[`${et}-switcher`]:{color:gt},[`${et}-node-content-wrapper`]:{color:gt,background:"transparent"}}}}}},ye=(It,et)=>{const nt=`.${It}`,dt=`${nt}-treenode`,at=et.paddingXS/2,gt=(0,Vt.TS)(et,{treeCls:nt,treeNodeCls:dt,treeNodePadding:at});return[Qt(It,gt),Fe(gt)]},Re=It=>{const{controlHeightSM:et}=It;return{titleHeight:et,nodeHoverBg:It.controlItemBgHover,nodeSelectedBg:It.controlItemBgActive}};cn.ZP=(0,qt.Z)("Tree",(It,et)=>{let{prefixCls:nt}=et;return[{[It.componentCls]:(0,Ht.C2)(`${nt}-checkbox`,It)},ye(nt,It),(0,ke.Z)(It)]},It=>{const{colorTextLightSolid:et,colorPrimary:nt}=It;return Object.assign(Object.assign({},Re(It)),{directoryNodeSelectedColor:et,directoryNodeSelectedBg:nt})})},71997:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return dt}});var Ft=wt(96663),Ht=wt(59301),oe={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M840.4 300H183.6c-19.7 0-30.7 20.8-18.5 35l328.4 380.8c9.4 10.9 27.5 10.9 37 0L858.9 335c12.2-14.2 1.2-35-18.5-35z"}}]},name:"caret-down",theme:"filled"},ke=oe,Vt=wt(7657),qt=function(gt,mt){return Ht.createElement(Vt.Z,(0,Ft.Z)({},gt,{ref:mt,icon:ke}))},Nt=Ht.forwardRef(qt),Oe=Nt,be=wt(52671),Qt=wt(58617),Fe=wt(15075),ye=wt(43531),Re=wt(92310),It=wt.n(Re),et=wt(92343),dt=at=>{const{prefixCls:gt,switcherIcon:mt,treeNodeProps:Pt,showLine:kt}=at,{isLeaf:Tt,expanded:Dt,loading:$t}=Pt;if($t)return Ht.createElement(Qt.Z,{className:`${gt}-switcher-loading-icon`});let ie;if(kt&&typeof kt=="object"&&(ie=kt.showLeafIcon),Tt){if(!kt)return null;if(typeof ie!="boolean"&&ie){const Zt=typeof ie=="function"?ie(Pt):ie,je=`${gt}-switcher-line-custom-icon`;return(0,et.l$)(Zt)?(0,et.Tm)(Zt,{className:It()(Zt.props.className||"",je)}):Zt}return ie?Ht.createElement(be.Z,{className:`${gt}-switcher-line-icon`}):Ht.createElement("span",{className:`${gt}-switcher-leaf-line`})}const Yt=`${gt}-switcher-icon`,fe=typeof mt=="function"?mt(Pt):mt;return(0,et.l$)(fe)?(0,et.Tm)(fe,{className:It()(fe.props.className||"",Yt)}):fe!==void 0?fe:kt?Dt?Ht.createElement(Fe.Z,{className:`${gt}-switcher-line-icon`}):Ht.createElement(ye.Z,{className:`${gt}-switcher-line-icon`}):Ht.createElement(Oe,{className:Yt})}},99498:function(Cn,cn,wt){(function(Ft){Ft(wt(89780))})(function(Ft){Ft.defineOption("placeholder","",function(Oe,be,Qt){var Fe=Qt&&Qt!=Ft.Init;if(be&&!Fe)Oe.on("blur",Vt),Oe.on("change",qt),Oe.on("swapDoc",qt),Ft.on(Oe.getInputField(),"compositionupdate",Oe.state.placeholderCompose=function(){ke(Oe)}),qt(Oe);else if(!be&&Fe){Oe.off("blur",Vt),Oe.off("change",qt),Oe.off("swapDoc",qt),Ft.off(Oe.getInputField(),"compositionupdate",Oe.state.placeholderCompose),Ht(Oe);var ye=Oe.getWrapperElement();ye.className=ye.className.replace(" CodeMirror-empty","")}be&&!Oe.hasFocus()&&Vt(Oe)});function Ht(Oe){Oe.state.placeholder&&(Oe.state.placeholder.parentNode.removeChild(Oe.state.placeholder),Oe.state.placeholder=null)}function oe(Oe){Ht(Oe);var be=Oe.state.placeholder=document.createElement("pre");be.style.cssText="height: 0; overflow: visible",be.style.direction=Oe.getOption("direction"),be.className="CodeMirror-placeholder CodeMirror-line-like";var Qt=Oe.getOption("placeholder");typeof Qt=="string"&&(Qt=document.createTextNode(Qt)),be.appendChild(Qt),Oe.display.lineSpace.insertBefore(be,Oe.display.lineSpace.firstChild)}function ke(Oe){setTimeout(function(){var be=!1,Qt=Oe.getInputField();Qt.nodeName=="TEXTAREA"?be=!Qt.value:Oe.lineCount()==1&&(be=!/[^\u200b]/.test(Qt.querySelector(".CodeMirror-line").textContent)),be?oe(Oe):Ht(Oe)},20)}function Vt(Oe){Nt(Oe)&&oe(Oe)}function qt(Oe){var be=Oe.getWrapperElement(),Qt=Nt(Oe);be.className=be.className.replace(" CodeMirror-empty","")+(Qt?" CodeMirror-empty":""),Qt?oe(Oe):Ht(Oe)}function Nt(Oe){return Oe.lineCount()===1&&Oe.getLine(0)===""}})},25717:function(Cn,cn,wt){(function(Ft){Ft(wt(89780))})(function(Ft){var Ht={pairs:`()[]{}''""`,closeBefore:`)]}'":;>`,triples:"",explode:"[]{}"},oe=Ft.Pos;Ft.defineOption("autoCloseBrackets",!1,function(et,nt,dt){dt&&dt!=Ft.Init&&(et.removeKeyMap(Vt),et.state.closeBrackets=null),nt&&(qt(ke(nt,"pairs")),et.state.closeBrackets=nt,et.addKeyMap(Vt))});function ke(et,nt){return nt=="pairs"&&typeof et=="string"?et:typeof et=="object"&&et[nt]!=null?et[nt]:Ht[nt]}var Vt={Backspace:be,Enter:Qt};function qt(et){for(var nt=0;nt=0;gt--){var Pt=at[gt].head;et.replaceRange("",oe(Pt.line,Pt.ch-1),oe(Pt.line,Pt.ch+1),"+delete")}}function Qt(et){var nt=Oe(et),dt=nt&&ke(nt,"explode");if(!dt||et.getOption("disableInput"))return Ft.Pass;for(var at=et.listSelections(),gt=0;gt0;return{anchor:new oe(et.anchor.line,et.anchor.ch+(nt?-1:1)),head:new oe(et.head.line,et.head.ch+(nt?1:-1))}}function ye(et,nt){var dt=Oe(et);if(!dt||et.getOption("disableInput"))return Ft.Pass;var at=ke(dt,"pairs"),gt=at.indexOf(nt);if(gt==-1)return Ft.Pass;for(var mt=ke(dt,"closeBefore"),Pt=ke(dt,"triples"),kt=at.charAt(gt+1)==nt,Tt=et.listSelections(),Dt=gt%2==0,$t,ie=0;ie=0&&et.getRange(fe,oe(fe.line,fe.ch+3))==nt+nt+nt?Zt="skipThree":Zt="skip";else if(kt&&fe.ch>1&&Pt.indexOf(nt)>=0&&et.getRange(oe(fe.line,fe.ch-2),fe)==nt+nt){if(fe.ch>2&&/\bstring/.test(et.getTokenTypeAt(oe(fe.line,fe.ch-2))))return Ft.Pass;Zt="addFour"}else if(kt){var me=fe.ch==0?" ":et.getRange(oe(fe.line,fe.ch-1),fe);if(!Ft.isWordChar(je)&&me!=nt&&!Ft.isWordChar(me))Zt="both";else return Ft.Pass}else if(Dt&&(je.length===0||/\s/.test(je)||mt.indexOf(je)>-1))Zt="both";else return Ft.Pass;if(!$t)$t=Zt;else if($t!=Zt)return Ft.Pass}var Xe=gt%2?at.charAt(gt-1):nt,Se=gt%2?nt:at.charAt(gt+1);et.operation(function(){if($t=="skip")et.execCommand("goCharRight");else if($t=="skipThree")for(var Ie=0;Ie<3;Ie++)et.execCommand("goCharRight");else if($t=="surround"){for(var ze=et.getSelections(),Ie=0;Ie'"]=function(Re){return ke(Re)}),be.addKeyMap(ye)}});var Ht=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],oe=["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 ke(be){if(be.getOption("disableInput"))return Ft.Pass;for(var Qt=be.listSelections(),Fe=[],ye=be.getOption("autoCloseTags"),Re=0;ReIt.ch&&(gt=gt.slice(0,gt.length-et.end+It.ch));var Tt=gt.toLowerCase();if(!gt||et.type=="string"&&(et.end!=It.ch||!/[\"\']/.test(et.string.charAt(et.string.length-1))||et.string.length==1)||et.type=="tag"&&at.close||et.string.indexOf("/")==It.ch-et.start-1||Pt&&Nt(Pt,Tt)>-1||Oe(be,nt.mode.xmlCurrentContext&&nt.mode.xmlCurrentContext(dt)||[],gt,It,!0))return Ft.Pass;var Dt=typeof ye=="object"&&ye.emptyTags;if(Dt&&Nt(Dt,gt)>-1){Fe[Re]={text:"/>",newPos:Ft.Pos(It.line,It.ch+2)};continue}var $t=kt&&Nt(kt,Tt)>-1;Fe[Re]={indent:$t,text:">"+($t?` `:"")+"",newPos:$t?Ft.Pos(It.line+1,0):Ft.Pos(It.line,It.ch+1)}}for(var ie=typeof ye=="object"&&ye.dontIndentOnAutoClose,Re=Qt.length-1;Re>=0;Re--){var Yt=Fe[Re];be.replaceRange(Yt.text,Qt[Re].head,Qt[Re].anchor,"+insert");var fe=be.listSelections().slice(0);fe[Re]={head:Yt.newPos,anchor:Yt.newPos},be.setSelections(fe),!ie&&Yt.indent&&(be.indentLine(Yt.newPos.line,null,!0),be.indentLine(Yt.newPos.line+1,null,!0))}}function Vt(be,Qt){for(var Fe=be.listSelections(),ye=[],Re=Qt?"/":""&&(Pt+=">"),ye[nt]=Pt}if(be.replaceSelections(ye),Fe=be.listSelections(),!et)for(var nt=0;nt=0&&Qt[dt]==Fe;dt--)++nt;ye=et.to;for(var dt=1;dt=dt.max))return dt.ch=0,dt.text=dt.cm.getLine(++dt.line),!0}function Qt(dt){if(!(dt.line<=dt.min))return dt.text=dt.cm.getLine(--dt.line),dt.ch=dt.text.length,!0}function Fe(dt){for(;;){var at=dt.text.indexOf(">",dt.ch);if(at==-1){if(be(dt))continue;return}if(!Oe(dt,at+1)){dt.ch=at+1;continue}var gt=dt.text.lastIndexOf("/",at),mt=gt>-1&&!/\S/.test(dt.text.slice(gt+1,at));return dt.ch=at+1,mt?"selfClose":"regular"}}function ye(dt){for(;;){var at=dt.ch?dt.text.lastIndexOf("<",dt.ch-1):-1;if(at==-1){if(Qt(dt))continue;return}if(!Oe(dt,at+1)){dt.ch=at;continue}qt.lastIndex=at,dt.ch=at;var gt=qt.exec(dt.text);if(gt&>.index==at)return gt}}function Re(dt){for(;;){qt.lastIndex=dt.ch;var at=qt.exec(dt.text);if(!at){if(be(dt))continue;return}if(!Oe(dt,at.index+1)){dt.ch=at.index+1;continue}return dt.ch=at.index+at[0].length,at}}function It(dt){for(;;){var at=dt.ch?dt.text.lastIndexOf(">",dt.ch-1):-1;if(at==-1){if(Qt(dt))continue;return}if(!Oe(dt,at+1)){dt.ch=at;continue}var gt=dt.text.lastIndexOf("/",at),mt=gt>-1&&!/\S/.test(dt.text.slice(gt+1,at));return dt.ch=at+1,mt?"selfClose":"regular"}}function et(dt,at){for(var gt=[];;){var mt=Re(dt),Pt,kt=dt.line,Tt=dt.ch-(mt?mt[0].length:0);if(!mt||!(Pt=Fe(dt)))return;if(Pt!="selfClose")if(mt[1]){for(var Dt=gt.length-1;Dt>=0;--Dt)if(gt[Dt]==mt[2]){gt.length=Dt;break}if(Dt<0&&(!at||at==mt[2]))return{tag:mt[2],from:Ht(kt,Tt),to:Ht(dt.line,dt.ch)}}else gt.push(mt[2])}}function nt(dt,at){for(var gt=[];;){var mt=It(dt);if(!mt)return;if(mt=="selfClose"){ye(dt);continue}var Pt=dt.line,kt=dt.ch,Tt=ye(dt);if(!Tt)return;if(Tt[1])gt.push(Tt[2]);else{for(var Dt=gt.length-1;Dt>=0;--Dt)if(gt[Dt]==Tt[2]){gt.length=Dt;break}if(Dt<0&&(!at||at==Tt[2]))return{tag:Tt[2],from:Ht(dt.line,dt.ch),to:Ht(Pt,kt)}}}}Ft.registerHelper("fold","xml",function(dt,at){for(var gt=new Nt(dt,at.line,0);;){var mt=Re(gt);if(!mt||gt.line!=at.line)return;var Pt=Fe(gt);if(!Pt)return;if(!mt[1]&&Pt!="selfClose"){var kt=Ht(gt.line,gt.ch),Tt=et(gt,mt[2]);return Tt&&oe(Tt.from,kt)>0?{from:kt,to:Tt.from}:null}}}),Ft.findMatchingTag=function(dt,at,gt){var mt=new Nt(dt,at.line,at.ch,gt);if(!(mt.text.indexOf(">")==-1&&mt.text.indexOf("<")==-1)){var Pt=Fe(mt),kt=Pt&&Ht(mt.line,mt.ch),Tt=Pt&&ye(mt);if(!(!Pt||!Tt||oe(mt,at)>0)){var Dt={from:Ht(mt.line,mt.ch),to:kt,tag:Tt[2]};return Pt=="selfClose"?{open:Dt,close:null,at:"open"}:Tt[1]?{open:nt(mt,Tt[2]),close:Dt,at:"close"}:(mt=new Nt(dt,kt.line,kt.ch,gt),{open:Dt,close:et(mt,Tt[2]),at:"open"})}}},Ft.findEnclosingTag=function(dt,at,gt,mt){for(var Pt=new Nt(dt,at.line,at.ch,gt);;){var kt=nt(Pt,mt);if(!kt)break;var Tt=new Nt(dt,at.line,at.ch,gt),Dt=et(Tt,kt.tag);if(Dt)return{open:kt,close:Dt}}},Ft.scanForClosingTag=function(dt,at,gt,mt){var Pt=new Nt(dt,at.line,at.ch,mt?{from:0,to:mt}:null);return et(Pt,gt)}})},89780:function(Cn){(function(cn,wt){Cn.exports=wt()})(this,function(){"use strict";var cn=navigator.userAgent,wt=navigator.platform,Ft=/gecko\/\d/i.test(cn),Ht=/MSIE \d/.test(cn),oe=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(cn),ke=/Edge\/(\d+)/.exec(cn),Vt=Ht||oe||ke,qt=Vt&&(Ht?document.documentMode||6:+(ke||oe)[1]),Nt=!ke&&/WebKit\//.test(cn),Oe=Nt&&/Qt\/\d+\.\d+/.test(cn),be=!ke&&/Chrome\//.test(cn),Qt=/Opera\//.test(cn),Fe=/Apple Computer/.test(navigator.vendor),ye=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(cn),Re=/PhantomJS/.test(cn),It=!ke&&/AppleWebKit/.test(cn)&&/Mobile\/\w+/.test(cn),et=/Android/.test(cn),nt=It||et||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(cn),dt=It||/Mac/.test(wt),at=/\bCrOS\b/.test(cn),gt=/win/i.test(wt),mt=Qt&&cn.match(/Version\/(\d*\.\d*)/);mt&&(mt=Number(mt[1])),mt&&mt>=15&&(Qt=!1,Nt=!0);var Pt=dt&&(Oe||Qt&&(mt==null||mt<12.11)),kt=Ft||Vt&&qt>=9;function Tt(it){return new RegExp("(^|\\s)"+it+"(?:$|\\s)\\s*")}var Dt=function(it,st){var ct=it.className,ht=Tt(st).exec(ct);if(ht){var pt=ct.slice(ht.index+ht[0].length);it.className=ct.slice(0,ht.index)+(pt?ht[1]+pt:"")}};function $t(it){for(var st=it.childNodes.length;st>0;--st)it.removeChild(it.firstChild);return it}function ie(it,st){return $t(it).appendChild(st)}function Yt(it,st,ct,ht){var pt=document.createElement(it);if(ct&&(pt.className=ct),ht&&(pt.style.cssText=ht),typeof st=="string")pt.appendChild(document.createTextNode(st));else if(st)for(var Mt=0;Mt=st)return At+(st-Mt);At+=Ut-Mt,At+=ct-At%ct,Mt=Ut+1}}var jt=function(){this.id=null,this.f=null,this.time=0,this.handler=ze(this.onTimeout,this)};jt.prototype.onTimeout=function(it){it.id=0,it.time<=+new Date?it.f():setTimeout(it.handler,it.time-+new Date)},jt.prototype.set=function(it,st){this.f=st;var ct=+new Date+it;(!this.id||ct=st)return ht+Math.min(At,st-pt);if(pt+=Mt-ht,pt+=ct-pt%ct,ht=Mt+1,pt>=st)return ht}}var tn=[""];function Tn(it){for(;tn.length<=it;)tn.push(we(tn)+" ");return tn[it]}function we(it){return it[it.length-1]}function Bn(it,st){for(var ct=[],ht=0;ht"\x80"&&(it.toUpperCase()!=it.toLowerCase()||St.test(it))}function Bt(it,st){return st?st.source.indexOf("\\w")>-1&&Et(it)?!0:st.test(it):Et(it)}function yt(it){for(var st in it)if(it.hasOwnProperty(st)&&it[st])return!1;return!0}var ae=/[\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 Pe(it){return it.charCodeAt(0)>=768&&ae.test(it)}function ne(it,st,ct){for(;(ct<0?st>0:stct?-1:1;;){if(st==ct)return st;var pt=(st+ct)/2,Mt=ht<0?Math.ceil(pt):Math.floor(pt);if(Mt==st)return it(Mt)?st:ct;it(Mt)?ct=Mt:st=Mt+ht}}function ge(it,st,ct,ht){if(!it)return ht(st,ct,"ltr",0);for(var pt=!1,Mt=0;Mtst||st==ct&&At.to==st)&&(ht(Math.max(At.from,st),Math.min(At.to,ct),At.level==1?"rtl":"ltr",Mt),pt=!0)}pt||ht(st,ct,"ltr")}var pe=null;function le(it,st,ct){var ht;pe=null;for(var pt=0;ptst)return pt;Mt.to==st&&(Mt.from!=Mt.to&&ct=="before"?ht=pt:pe=pt),Mt.from==st&&(Mt.from!=Mt.to&&ct!="before"?ht=pt:pe=pt)}return ht!=null?ht:pe}var Me=function(){var it="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",st="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function ct(de){return de<=247?it.charAt(de):1424<=de&&de<=1524?"R":1536<=de&&de<=1785?st.charAt(de-1536):1774<=de&&de<=2220?"r":8192<=de&&de<=8203?"w":de==8204?"b":"L"}var ht=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,pt=/[stwN]/,Mt=/[LRr]/,At=/[Lb1n]/,Ut=/[1n]/;function Wt(de,Ke,xe){this.level=de,this.from=Ke,this.to=xe}return function(de,Ke){var xe=Ke=="ltr"?"L":"R";if(de.length==0||Ke=="ltr"&&!ht.test(de))return!1;for(var Sn=de.length,hn=[],_n=0;_n-1&&(ht[st]=pt.slice(0,Mt).concat(pt.slice(Mt+1)))}}}function pn(it,st){var ct=yn(it,st);if(ct.length)for(var ht=Array.prototype.slice.call(arguments,2),pt=0;pt0}function gi(it){it.prototype.on=function(st,ct){Ge(this,st,ct)},it.prototype.off=function(st,ct){wn(this,st,ct)}}function mi(it){it.preventDefault?it.preventDefault():it.returnValue=!1}function $i(it){it.stopPropagation?it.stopPropagation():it.cancelBubble=!0}function Mi(it){return it.defaultPrevented!=null?it.defaultPrevented:it.returnValue==!1}function eo(it){mi(it),$i(it)}function Io(it){return it.target||it.srcElement}function Ao(it){var st=it.which;return st==null&&(it.button&1?st=1:it.button&2?st=3:it.button&4&&(st=2)),dt&&it.ctrlKey&&st==1&&(st=3),st}var $n=function(){if(Vt&&qt<9)return!1;var it=Yt("div");return"draggable"in it||"dragDrop"in it}(),Kn;function jn(it){if(Kn==null){var st=Yt("span","\u200B");ie(it,Yt("span",[st,document.createTextNode("x")])),it.firstChild.offsetHeight!=0&&(Kn=st.offsetWidth<=1&&st.offsetHeight>2&&!(Vt&&qt<8))}var ct=Kn?Yt("span","\u200B"):Yt("span","\xA0",null,"display: inline-block; width: 1px; margin-right: -1px");return ct.setAttribute("cm-text",""),ct}var ii;function Vi(it){if(ii!=null)return ii;var st=ie(it,document.createTextNode("A\u062EA")),ct=Zt(st,0,1).getBoundingClientRect(),ht=Zt(st,1,2).getBoundingClientRect();return $t(it),!ct||ct.left==ct.right?!1:ii=ht.right-ct.right<3}var wi=` b`.split(/\n/).length!=3?function(it){for(var st=0,ct=[],ht=it.length;st<=ht;){var pt=it.indexOf(` `,st);pt==-1&&(pt=it.length);var Mt=it.slice(st,it.charAt(pt-1)=="\r"?pt-1:pt),At=Mt.indexOf("\r");At!=-1?(ct.push(Mt.slice(0,At)),st+=At+1):(ct.push(Mt),st=pt+1)}return ct}:function(it){return it.split(/\r\n?|\n/)},bt=window.getSelection?function(it){try{return it.selectionStart!=it.selectionEnd}catch(st){return!1}}:function(it){var st;try{st=it.ownerDocument.selection.createRange()}catch(ct){}return!st||st.parentElement()!=it?!1:st.compareEndPoints("StartToEnd",st)!=0},no=function(){var it=Yt("div");return"oncopy"in it?!0:(it.setAttribute("oncopy","return;"),typeof it.oncopy=="function")}(),Ni=null;function ho(it){if(Ni!=null)return Ni;var st=ie(it,Yt("span","x")),ct=st.getBoundingClientRect(),ht=Zt(st,0,1).getBoundingClientRect();return Ni=Math.abs(ct.left-ht.left)>1}var pr={},ar={};function sr(it,st){arguments.length>2&&(st.dependencies=Array.prototype.slice.call(arguments,2)),pr[it]=st}function Fo(it,st){ar[it]=st}function nr(it){if(typeof it=="string"&&ar.hasOwnProperty(it))it=ar[it];else if(it&&typeof it.name=="string"&&ar.hasOwnProperty(it.name)){var st=ar[it.name];typeof st=="string"&&(st={name:st}),it=Lt(st,it),it.name=st.name}else{if(typeof it=="string"&&/^[\w\-]+\/[\w\-]+\+xml$/.test(it))return nr("application/xml");if(typeof it=="string"&&/^[\w\-]+\/[\w\-]+\+json$/.test(it))return nr("application/json")}return typeof it=="string"?{name:it}:it||{name:"null"}}function _e(it,st){st=nr(st);var ct=pr[st.name];if(!ct)return _e(it,"text/plain");var ht=ct(it,st);if(We.hasOwnProperty(st.name)){var pt=We[st.name];for(var Mt in pt)pt.hasOwnProperty(Mt)&&(ht.hasOwnProperty(Mt)&&(ht["_"+Mt]=ht[Mt]),ht[Mt]=pt[Mt])}if(ht.name=st.name,st.helperType&&(ht.helperType=st.helperType),st.modeProps)for(var At in st.modeProps)ht[At]=st.modeProps[At];return ht}var We={};function Jt(it,st){var ct=We.hasOwnProperty(it)?We[it]:We[it]={};Ue(st,ct)}function on(it,st){if(st===!0)return st;if(it.copyState)return it.copyState(st);var ct={};for(var ht in st){var pt=st[ht];pt instanceof Array&&(pt=pt.concat([])),ct[ht]=pt}return ct}function Mn(it,st){for(var ct;it.innerMode&&(ct=it.innerMode(st),!(!ct||ct.mode==it));)st=ct.state,it=ct.mode;return ct||{mode:it,state:st}}function Le(it,st,ct){return it.startState?it.startState(st,ct):!0}var ue=function(it,st,ct){this.pos=this.start=0,this.string=it,this.tabSize=st||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=ct};ue.prototype.eol=function(){return this.pos>=this.string.length},ue.prototype.sol=function(){return this.pos==this.lineStart},ue.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},ue.prototype.next=function(){if(this.posst},ue.prototype.eatSpace=function(){for(var it=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>it},ue.prototype.skipToEnd=function(){this.pos=this.string.length},ue.prototype.skipTo=function(it){var st=this.string.indexOf(it,this.pos);if(st>-1)return this.pos=st,!0},ue.prototype.backUp=function(it){this.pos-=it},ue.prototype.column=function(){return this.lastColumnPos0?null:(Mt&&st!==!1&&(this.pos+=Mt[0].length),Mt)}},ue.prototype.current=function(){return this.string.slice(this.start,this.pos)},ue.prototype.hideFirstChars=function(it,st){this.lineStart+=it;try{return st()}finally{this.lineStart-=it}},ue.prototype.lookAhead=function(it){var st=this.lineOracle;return st&&st.lookAhead(it)},ue.prototype.baseToken=function(){var it=this.lineOracle;return it&&it.baseToken(this.pos)};function Je(it,st){if(st-=it.first,st<0||st>=it.size)throw new Error("There is no line "+(st+it.first)+" in the document.");for(var ct=it;!ct.lines;)for(var ht=0;;++ht){var pt=ct.children[ht],Mt=pt.chunkSize();if(st=it.first&&stct?Ae(ct,Je(it,ct).text.length):Ci(st,Je(it,st.line).text.length)}function Ci(it,st){var ct=it.ch;return ct==null||ct>st?Ae(it.line,st):ct<0?Ae(it.line,0):it}function so(it,st){for(var ct=[],ht=0;htthis.maxLookAhead&&(this.maxLookAhead=it),st},sn.prototype.baseToken=function(it){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=it;)this.baseTokenPos+=2;var st=this.baseTokens[this.baseTokenPos+1];return{type:st&&st.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-it}},sn.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},sn.fromSaved=function(it,st,ct){return st instanceof wo?new sn(it,on(it.mode,st.state),ct,st.lookAhead):new sn(it,on(it.mode,st),ct)},sn.prototype.save=function(it){var st=it!==!1?on(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new wo(st,this.maxLookAhead):st};function Bo(it,st,ct,ht){var pt=[it.state.modeGen],Mt={};co(it,st.text,it.doc.mode,ct,function(de,Ke){return pt.push(de,Ke)},Mt,ht);for(var At=ct.state,Ut=function(de){ct.baseTokens=pt;var Ke=it.state.overlays[de],xe=1,Sn=0;ct.state=!0,co(it,st.text,Ke.mode,ct,function(hn,_n){for(var ai=xe;Snhn&&pt.splice(xe,1,hn,pt[xe+1],vi),xe+=2,Sn=Math.min(hn,vi)}if(_n)if(Ke.opaque)pt.splice(ai,xe-ai,hn,"overlay "+_n),xe=ai+2;else for(;aiit.options.maxHighlightLength&&on(it.doc.mode,ht.state),Mt=Bo(it,st,ht);pt&&(ht.state=pt),st.stateAfter=ht.save(!pt),st.styles=Mt.styles,Mt.classes?st.styleClasses=Mt.classes:st.styleClasses&&(st.styleClasses=null),ct===it.doc.highlightFrontier&&(it.doc.modeFrontier=Math.max(it.doc.modeFrontier,++it.doc.highlightFrontier))}return st.styles}function io(it,st,ct){var ht=it.doc,pt=it.display;if(!ht.mode.startState)return new sn(ht,!0,st);var Mt=Ri(it,st,ct),At=Mt>ht.first&&Je(ht,Mt-1).stateAfter,Ut=At?sn.fromSaved(ht,At,Mt):new sn(ht,Le(ht.mode),Mt);return ht.iter(Mt,st,function(Wt){Qe(it,Wt.text,Ut);var de=Ut.line;Wt.stateAfter=de==st-1||de%5==0||de>=pt.viewFrom&&dest.start)return Mt}throw new Error("Mode "+it.name+" failed to advance stream.")}var bi=function(it,st,ct){this.start=it.start,this.end=it.pos,this.string=it.current(),this.type=st||null,this.state=ct};function yi(it,st,ct,ht){var pt=it.doc,Mt=pt.mode,At;st=Qn(pt,st);var Ut=Je(pt,st.line),Wt=io(it,st.line,ct),de=new ue(Ut.text,it.options.tabSize,Wt),Ke;for(ht&&(Ke=[]);(ht||de.posit.options.maxHighlightLength?(Ut=!1,At&&Qe(it,st,ht,Ke.pos),Ke.pos=st.length,xe=null):xe=Qi(di(ct,Ke,ht.state,Sn),Mt),Sn){var hn=Sn[0].name;hn&&(xe="m-"+(xe?hn+" "+xe:hn))}if(!Ut||de!=xe){for(;WtAt;--Ut){if(Ut<=Mt.first)return Mt.first;var Wt=Je(Mt,Ut-1),de=Wt.stateAfter;if(de&&(!ct||Ut+(de instanceof wo?de.lookAhead:0)<=Mt.modeFrontier))return Ut;var Ke=se(Wt.text,null,it.options.tabSize);(pt==null||ht>Ke)&&(pt=Ut-1,ht=Ke)}return pt}function Hi(it,st){if(it.modeFrontier=Math.min(it.modeFrontier,st),!(it.highlightFrontierct;ht--){var pt=Je(it,ht).stateAfter;if(pt&&(!(pt instanceof wo)||ht+pt.lookAhead=st:Mt.to>st);(ht||(ht=[])).push(new Po(At,Mt.from,Wt?null:Mt.to))}}return ht}function Wi(it,st,ct){var ht;if(it)for(var pt=0;pt=st:Mt.to>st);if(Ut||Mt.from==st&&At.type=="bookmark"&&(!ct||Mt.marker.insertLeft)){var Wt=Mt.from==null||(At.inclusiveLeft?Mt.from<=st:Mt.from0&&Ut)for(var Lo=0;Lo0)){var Ke=[Wt,1],xe=en(de.from,Ut.from),Sn=en(de.to,Ut.to);(xe<0||!At.inclusiveLeft&&!xe)&&Ke.push({from:de.from,to:Ut.from}),(Sn>0||!At.inclusiveRight&&!Sn)&&Ke.push({from:Ut.to,to:de.to}),pt.splice.apply(pt,Ke),Wt+=Ke.length-3}}return pt}function ri(it){var st=it.markedSpans;if(st){for(var ct=0;ctst)&&(!ht||ps(ht,Mt.marker)<0)&&(ht=Mt.marker)}return ht}function Ko(it,st,ct,ht,pt){var Mt=Je(it,st),At=mn&&Mt.markedSpans;if(At)for(var Ut=0;Ut=0&&xe<=0||Ke<=0&&xe>=0)&&(Ke<=0&&(Wt.marker.inclusiveRight&&pt.inclusiveLeft?en(de.to,ct)>=0:en(de.to,ct)>0)||Ke>=0&&(Wt.marker.inclusiveRight&&pt.inclusiveLeft?en(de.from,ht)<=0:en(de.from,ht)<0)))return!0}}}function ao(it){for(var st;st=ks(it);)it=st.find(-1,!0).line;return it}function lr(it){for(var st;st=po(it);)it=st.find(1,!0).line;return it}function Ys(it){for(var st,ct;st=po(it);)it=st.find(1,!0).line,(ct||(ct=[])).push(it);return ct}function qi(it,st){var ct=Je(it,st),ht=ao(ct);return ct==ht?st:ce(ht)}function Ai(it,st){if(st>it.lastLine())return st;var ct=Je(it,st),ht;if(!Nn(it,ct))return st;for(;ht=po(ct);)ct=ht.find(1,!0).line;return ce(ct)+1}function Nn(it,st){var ct=mn&&st.markedSpans;if(ct){for(var ht=void 0,pt=0;ptst.maxLineLength&&(st.maxLineLength=pt,st.maxLine=ht)})}var Vr=function(it,st,ct){this.text=it,Gt(this,st),this.height=ct?ct(this):1};Vr.prototype.lineNo=function(){return ce(this)},gi(Vr);function Ns(it,st,ct,ht){it.text=st,it.stateAfter&&(it.stateAfter=null),it.styles&&(it.styles=null),it.order!=null&&(it.order=null),ri(it),Gt(it,ct);var pt=ht?ht(it):1;pt!=it.height&&Gn(it,pt)}function Jr(it){it.parent=null,ri(it)}var ga={},Qs={};function Ea(it,st){if(!it||/^\s*$/.test(it))return null;var ct=st.addModeClass?Qs:ga;return ct[it]||(ct[it]=it.replace(/\S+/g,"cm-$&"))}function Ye(it,st){var ct=fe("span",null,null,Nt?"padding-right: .1px":null),ht={pre:fe("pre",[ct],"CodeMirror-line"),content:ct,col:0,pos:0,cm:it,trailingSpace:!1,splitSpaces:it.getOption("lineWrapping")};st.measure={};for(var pt=0;pt<=(st.rest?st.rest.length:0);pt++){var Mt=pt?st.rest[pt-1]:st.line,At=void 0;ht.pos=0,ht.addToken=gh,Vi(it.display.measure)&&(At=nn(Mt,it.doc.direction))&&(ht.addToken=uu(ht.addToken,At)),ht.map=[];var Ut=st!=it.display.externalMeasured&&ce(Mt);th(Mt,ht,Vo(it,Mt,Ut)),Mt.styleClasses&&(Mt.styleClasses.bgClass&&(ht.bgClass=Se(Mt.styleClasses.bgClass,ht.bgClass||"")),Mt.styleClasses.textClass&&(ht.textClass=Se(Mt.styleClasses.textClass,ht.textClass||""))),ht.map.length==0&&ht.map.push(0,0,ht.content.appendChild(jn(it.display.measure))),pt==0?(st.measure.map=ht.map,st.measure.cache={}):((st.measure.maps||(st.measure.maps=[])).push(ht.map),(st.measure.caches||(st.measure.caches=[])).push({}))}if(Nt){var Wt=ht.content.lastChild;(/\bcm-tab\b/.test(Wt.className)||Wt.querySelector&&Wt.querySelector(".cm-tab"))&&(ht.content.className="cm-tab-wrap-hack")}return pn(it,"renderLine",it,st.line,ht.pre),ht.pre.className&&(ht.textClass=Se(ht.pre.className,ht.textClass||"")),ht}function Ws(it){var st=Yt("span","\u2022","cm-invalidchar");return st.title="\\u"+it.charCodeAt(0).toString(16),st.setAttribute("aria-label",st.title),st}function gh(it,st,ct,ht,pt,Mt,At){if(st){var Ut=it.splitSpaces?kl(st,it.trailingSpace):st,Wt=it.cm.state.specialChars,de=!1,Ke;if(!Wt.test(st))it.col+=st.length,Ke=document.createTextNode(Ut),it.map.push(it.pos,it.pos+st.length,Ke),Vt&&qt<9&&(de=!0),it.pos+=st.length;else{Ke=document.createDocumentFragment();for(var xe=0;;){Wt.lastIndex=xe;var Sn=Wt.exec(st),hn=Sn?Sn.index-xe:st.length-xe;if(hn){var _n=document.createTextNode(Ut.slice(xe,xe+hn));Vt&&qt<9?Ke.appendChild(Yt("span",[_n])):Ke.appendChild(_n),it.map.push(it.pos,it.pos+hn,_n),it.col+=hn,it.pos+=hn}if(!Sn)break;xe+=hn+1;var ai=void 0;if(Sn[0]==" "){var vi=it.cm.options.tabSize,Di=vi-it.col%vi;ai=Ke.appendChild(Yt("span",Tn(Di),"cm-tab")),ai.setAttribute("role","presentation"),ai.setAttribute("cm-text"," "),it.col+=Di}else Sn[0]=="\r"||Sn[0]==` `?(ai=Ke.appendChild(Yt("span",Sn[0]=="\r"?"\u240D":"\u2424","cm-invalidchar")),ai.setAttribute("cm-text",Sn[0]),it.col+=1):(ai=it.cm.options.specialCharPlaceholder(Sn[0]),ai.setAttribute("cm-text",Sn[0]),Vt&&qt<9?Ke.appendChild(Yt("span",[ai])):Ke.appendChild(ai),it.col+=1);it.map.push(it.pos,it.pos+1,ai),it.pos++}}if(it.trailingSpace=Ut.charCodeAt(st.length-1)==32,ct||ht||pt||de||Mt||At){var uo=ct||"";ht&&(uo+=ht),pt&&(uo+=pt);var Ji=Yt("span",[Ke],uo,Mt);if(At)for(var Lo in At)At.hasOwnProperty(Lo)&&Lo!="style"&&Lo!="class"&&Ji.setAttribute(Lo,At[Lo]);return it.content.appendChild(Ji)}it.content.appendChild(Ke)}}function kl(it,st){if(it.length>1&&!/ /.test(it))return it;for(var ct=st,ht="",pt=0;ptde&&xe.from<=de));Sn++);if(xe.to>=Ke)return it(ct,ht,pt,Mt,At,Ut,Wt);it(ct,ht.slice(0,xe.to-de),pt,Mt,null,Ut,Wt),Mt=null,ht=ht.slice(xe.to-de),de=xe.to}}}function ts(it,st,ct,ht){var pt=!ht&&ct.widgetNode;pt&&it.map.push(it.pos,it.pos+st,pt),!ht&&it.cm.display.input.needsContentAttribute&&(pt||(pt=it.content.appendChild(document.createElement("span"))),pt.setAttribute("cm-marker",ct.id)),pt&&(it.cm.display.input.setUneditable(pt),it.content.appendChild(pt)),it.pos+=st,it.trailingSpace=!1}function th(it,st,ct){var ht=it.markedSpans,pt=it.text,Mt=0;if(!ht){for(var At=1;AtWt||yr.collapsed&&Xi.to==Wt&&Xi.from==Wt)){if(Xi.to!=null&&Xi.to!=Wt&&hn>Xi.to&&(hn=Xi.to,ai=""),yr.className&&(_n+=" "+yr.className),yr.css&&(Sn=(Sn?Sn+";":"")+yr.css),yr.startStyle&&Xi.from==Wt&&(vi+=" "+yr.startStyle),yr.endStyle&&Xi.to==hn&&(Lo||(Lo=[])).push(yr.endStyle,Xi.to),yr.title&&((uo||(uo={})).title=yr.title),yr.attributes)for(var Zs in yr.attributes)(uo||(uo={}))[Zs]=yr.attributes[Zs];yr.collapsed&&(!Di||ps(Di.marker,yr)<0)&&(Di=Xi)}else Xi.from>Wt&&hn>Xi.from&&(hn=Xi.from)}if(Lo)for(var Oa=0;Oa=Ut)break;for(var Gl=Math.min(Ut,hn);;){if(Ke){var dl=Wt+Ke.length;if(!Di){var ba=dl>Gl?Ke.slice(0,Gl-Wt):Ke;st.addToken(st,ba,xe?xe+_n:_n,vi,Wt+ba.length==hn?ai:"",Sn,uo)}if(dl>=Gl){Ke=Ke.slice(Gl-Wt),Wt=Gl;break}Wt=dl,vi=""}Ke=pt.slice(Mt,Mt=ct[de++]),xe=Ea(ct[de++],st.cm.options)}}}function eh(it,st,ct){this.line=st,this.rest=Ys(st),this.size=this.rest?ce(we(this.rest))-ct+1:1,this.node=this.text=null,this.hidden=Nn(it,st)}function Gr(it,st,ct){for(var ht=[],pt,Mt=st;Mt2&&Mt.push((Wt.bottom+de.top)/2-ct.top)}}Mt.push(ct.bottom-ct.top)}}function Gh(it,st,ct){if(it.line==st)return{map:it.measure.map,cache:it.measure.cache};for(var ht=0;htct)return{map:it.measure.maps[pt],cache:it.measure.caches[pt],before:!0}}function $d(it,st){st=ao(st);var ct=ce(st),ht=it.display.externalMeasured=new eh(it.doc,st,ct);ht.lineN=ct;var pt=ht.built=Ye(it,ht);return ht.text=pt.pre,ie(it.display.lineMeasure,pt.pre),ht}function $h(it,st,ct,ht){return Fl(it,Du(it,st),ct,ht)}function mh(it,st){if(st>=it.display.viewFrom&&st=ct.lineN&&stst)&&(Mt=Wt-Ut,pt=Mt-1,st>=Wt&&(At="right")),pt!=null){if(ht=it[de+2],Ut==Wt&&ct==(ht.insertLeft?"left":"right")&&(At=ct),ct=="left"&&pt==0)for(;de&&it[de-2]==it[de-3]&&it[de-1].insertLeft;)ht=it[(de-=3)+2],At="left";if(ct=="right"&&pt==Wt-Ut)for(;de=0&&(ct=it[pt]).left==ct.right;pt--);return ct}function Wo(it,st,ct,ht){var pt=Wh(st.map,ct,ht),Mt=pt.node,At=pt.start,Ut=pt.end,Wt=pt.collapse,de;if(Mt.nodeType==3){for(var Ke=0;Ke<4;Ke++){for(;At&&Pe(st.line.text.charAt(pt.coverStart+At));)--At;for(;pt.coverStart+Ut0&&(Wt=ht="right");var xe;it.options.lineWrapping&&(xe=Mt.getClientRects()).length>1?de=xe[ht=="right"?xe.length-1:0]:de=Mt.getBoundingClientRect()}if(Vt&&qt<9&&!At&&(!de||!de.left&&!de.right)){var Sn=Mt.parentNode.getClientRects()[0];Sn?de={left:Sn.left,right:Sn.left+nh(it.display),top:Sn.top,bottom:Sn.bottom}:de=dd}for(var hn=de.top-st.rect.top,_n=de.bottom-st.rect.top,ai=(hn+_n)/2,vi=st.view.measure.heights,Di=0;Di=ht.text.length?(Wt=ht.text.length,de="before"):Wt<=0&&(Wt=0,de="after"),!Ut)return At(de=="before"?Wt-1:Wt,de=="before");function Ke(_n,ai,vi){var Di=Ut[ai],uo=Di.level==1;return At(vi?_n-1:_n,uo!=vi)}var xe=le(Ut,Wt,de),Sn=pe,hn=Ke(Wt,xe,de=="before");return Sn!=null&&(hn.other=Ke(Wt,Sn,de!="before")),hn}function xc(it,st){var ct=0;st=Qn(it.doc,st),it.options.lineWrapping||(ct=nh(it.display)*st.ch);var ht=Je(it.doc,st.line),pt=Xo(ht)+ka(it.display);return{left:ct,right:ct,top:pt,bottom:pt+ht.height}}function Pc(it,st,ct,ht,pt){var Mt=Ae(it,st,ct);return Mt.xRel=pt,ht&&(Mt.outside=ht),Mt}function Kh(it,st,ct){var ht=it.doc;if(ct+=it.display.viewOffset,ct<0)return Pc(ht.first,0,null,-1,-1);var pt=vn(ht,ct),Mt=ht.first+ht.size-1;if(pt>Mt)return Pc(ht.first+ht.size-1,Je(ht,Mt).text.length,null,1,1);st<0&&(st=0);for(var At=Je(ht,pt);;){var Ut=kn(it,At,pt,st,ct),Wt=to(At,Ut.ch+(Ut.xRel>0||Ut.outside>0?1:0));if(!Wt)return Ut;var de=Wt.find(1);if(de.line==pt)return de;At=Je(ht,pt=de.line)}}function Yi(it,st,ct,ht){ht-=Hs(st);var pt=st.text.length,Mt=_t(function(At){return Fl(it,ct,At-1).bottom<=ht},pt,0);return pt=_t(function(At){return Fl(it,ct,At).top>ht},Mt,pt),{begin:Mt,end:pt}}function cd(it,st,ct,ht){ct||(ct=Du(it,st));var pt=Bs(it,st,Fl(it,ct,ht),"line").top;return Yi(it,st,ct,pt)}function Ce(it,st,ct,ht){return it.bottom<=ct?!1:it.top>ct?!0:(ht?it.left:it.right)>st}function kn(it,st,ct,ht,pt){pt-=Xo(st);var Mt=Du(it,st),At=Hs(st),Ut=0,Wt=st.text.length,de=!0,Ke=nn(st,it.doc.direction);if(Ke){var xe=(it.options.lineWrapping?rf:wc)(it,st,ct,Mt,Ke,ht,pt);de=xe.level!=1,Ut=de?xe.from:xe.to-1,Wt=de?xe.to:xe.from-1}var Sn=null,hn=null,_n=_t(function(or){var Xi=Fl(it,Mt,or);return Xi.top+=At,Xi.bottom+=At,Ce(Xi,ht,pt,!1)?(Xi.top<=pt&&Xi.left<=ht&&(Sn=or,hn=Xi),!0):!1},Ut,Wt),ai,vi,Di=!1;if(hn){var uo=ht-hn.left=Lo.bottom?1:0}return _n=ne(st.text,_n,1),Pc(ct,_n,vi,Di,ht-ai)}function wc(it,st,ct,ht,pt,Mt,At){var Ut=_t(function(xe){var Sn=pt[xe],hn=Sn.level!=1;return Ce(xs(it,Ae(ct,hn?Sn.to:Sn.from,hn?"before":"after"),"line",st,ht),Mt,At,!0)},0,pt.length-1),Wt=pt[Ut];if(Ut>0){var de=Wt.level!=1,Ke=xs(it,Ae(ct,de?Wt.from:Wt.to,de?"after":"before"),"line",st,ht);Ce(Ke,Mt,At,!0)&&Ke.top>At&&(Wt=pt[Ut-1])}return Wt}function rf(it,st,ct,ht,pt,Mt,At){var Ut=Yi(it,st,ht,At),Wt=Ut.begin,de=Ut.end;/\s/.test(st.text.charAt(de-1))&&de--;for(var Ke=null,xe=null,Sn=0;Sn=de||hn.to<=Wt)){var _n=hn.level!=1,ai=Fl(it,ht,_n?Math.min(de,hn.to)-1:Math.max(Wt,hn.from)).right,vi=aivi)&&(Ke=hn,xe=vi)}}return Ke||(Ke=pt[pt.length-1]),Ke.fromde&&(Ke={from:Ke.from,to:de,level:Ke.level}),Ke}var Ru;function zu(it){if(it.cachedTextHeight!=null)return it.cachedTextHeight;if(Ru==null){Ru=Yt("pre",null,"CodeMirror-line-like");for(var st=0;st<49;++st)Ru.appendChild(document.createTextNode("x")),Ru.appendChild(Yt("br"));Ru.appendChild(document.createTextNode("x"))}ie(it.measure,Ru);var ct=Ru.offsetHeight/50;return ct>3&&(it.cachedTextHeight=ct),$t(it.measure),ct||1}function nh(it){if(it.cachedCharWidth!=null)return it.cachedCharWidth;var st=Yt("span","xxxxxxxxxx"),ct=Yt("pre",[st],"CodeMirror-line-like");ie(it.measure,ct);var ht=st.getBoundingClientRect(),pt=(ht.right-ht.left)/10;return pt>2&&(it.cachedCharWidth=pt),pt||10}function Cc(it){for(var st=it.display,ct={},ht={},pt=st.gutters.clientLeft,Mt=st.gutters.firstChild,At=0;Mt;Mt=Mt.nextSibling,++At){var Ut=it.display.gutterSpecs[At].className;ct[Ut]=Mt.offsetLeft+Mt.clientLeft+pt,ht[Ut]=Mt.clientWidth}return{fixedPos:fd(st),gutterTotalWidth:st.gutters.offsetWidth,gutterLeft:ct,gutterWidth:ht,wrapperWidth:st.wrapper.clientWidth}}function fd(it){return it.scroller.getBoundingClientRect().left-it.sizer.getBoundingClientRect().left}function Ds(it){var st=zu(it.display),ct=it.options.lineWrapping,ht=ct&&Math.max(5,it.display.scroller.clientWidth/nh(it.display)-3);return function(pt){if(Nn(it.doc,pt))return 0;var Mt=0;if(pt.widgets)for(var At=0;At0&&(de=Je(it.doc,Wt.line).text).length==Wt.ch){var Ke=se(de,de.length,it.options.tabSize)-de.length;Wt=Ae(Wt.line,Math.max(0,Math.round((Mt-Bu(it.display).left)/nh(it.display))-Ke))}return Wt}function Aa(it,st){if(st>=it.display.viewTo||(st-=it.display.viewFrom,st<0))return null;for(var ct=it.display.view,ht=0;htst)&&(pt.updateLineNumbers=st),it.curOp.viewChanged=!0,st>=pt.viewTo)mn&&qi(it.doc,st)pt.viewFrom?na(it):(pt.viewFrom+=ht,pt.viewTo+=ht);else if(st<=pt.viewFrom&&ct>=pt.viewTo)na(it);else if(st<=pt.viewFrom){var Mt=yl(it,ct,ct+ht,1);Mt?(pt.view=pt.view.slice(Mt.index),pt.viewFrom=Mt.lineN,pt.viewTo+=ht):na(it)}else if(ct>=pt.viewTo){var At=yl(it,st,st,-1);At?(pt.view=pt.view.slice(0,At.index),pt.viewTo=At.lineN):na(it)}else{var Ut=yl(it,st,st,-1),Wt=yl(it,ct,ct+ht,1);Ut&&Wt?(pt.view=pt.view.slice(0,Ut.index).concat(Gr(it,Ut.lineN,Wt.lineN)).concat(pt.view.slice(Wt.index)),pt.viewTo+=ht):na(it)}var de=pt.externalMeasured;de&&(ct=pt.lineN&&st=ht.viewTo)){var Mt=ht.view[Aa(it,st)];if(Mt.node!=null){var At=Mt.changes||(Mt.changes=[]);$e(At,ct)==-1&&At.push(ct)}}}function na(it){it.display.viewFrom=it.display.viewTo=it.doc.first,it.display.view=[],it.display.viewOffset=0}function yl(it,st,ct,ht){var pt=Aa(it,st),Mt,At=it.display.view;if(!mn||ct==it.doc.first+it.doc.size)return{index:pt,lineN:ct};for(var Ut=it.display.viewFrom,Wt=0;Wt0){if(pt==At.length-1)return null;Mt=Ut+At[pt].size-st,pt++}else Mt=Ut-st;st+=Mt,ct+=Mt}for(;qi(it.doc,ct)!=ct;){if(pt==(ht<0?0:At.length-1))return null;ct+=ht*At[pt-(ht<0?1:0)].size,pt+=ht}return{index:pt,lineN:ct}}function os(it,st,ct){var ht=it.display,pt=ht.view;pt.length==0||st>=ht.viewTo||ct<=ht.viewFrom?(ht.view=Gr(it,st,ct),ht.viewFrom=st):(ht.viewFrom>st?ht.view=Gr(it,st,ht.viewFrom).concat(ht.view):ht.viewFromct&&(ht.view=ht.view.slice(0,Aa(it,ct)))),ht.viewTo=ct}function Bl(it){for(var st=it.display.view,ct=0,ht=0;ht=it.display.viewTo||Ut.to().line0?st.blinker=setInterval(function(){it.hasFocus()||Vh(it),st.cursorDiv.style.visibility=(ct=!ct)?"":"hidden"},it.options.cursorBlinkRate):it.options.cursorBlinkRate<0&&(st.cursorDiv.style.visibility="hidden")}}function Ps(it){it.state.focused||(it.display.input.focus(),Br(it))}function Gs(it){it.state.delayingBlurEvent=!0,setTimeout(function(){it.state.delayingBlurEvent&&(it.state.delayingBlurEvent=!1,Vh(it))},100)}function Br(it,st){it.state.delayingBlurEvent&&(it.state.delayingBlurEvent=!1),it.options.readOnly!="nocursor"&&(it.state.focused||(pn(it,"focus",it,st),it.state.focused=!0,Xe(it.display.wrapper,"CodeMirror-focused"),!it.curOp&&it.display.selForContextMenu!=it.doc.sel&&(it.display.input.reset(),Nt&&setTimeout(function(){return it.display.input.reset(!0)},20)),it.display.input.receivedFocus()),es(it))}function Vh(it,st){it.state.delayingBlurEvent||(it.state.focused&&(pn(it,"blur",it,st),it.state.focused=!1,Dt(it.display.wrapper,"CodeMirror-focused")),clearInterval(it.display.blinker),setTimeout(function(){it.state.focused||(it.display.shift=!1)},150))}function Mo(it){for(var st=it.display,ct=st.lineDiv.offsetTop,ht=0;ht.005||Ke<-.005)&&(Gn(pt.line,At),$f(pt.line),pt.rest))for(var xe=0;xeit.display.sizerWidth){var Sn=Math.ceil(Ut/nh(it.display));Sn>it.display.maxLineLength&&(it.display.maxLineLength=Sn,it.display.maxLine=pt.line,it.display.maxLineChanged=!0)}}}}function $f(it){if(it.widgets)for(var st=0;st=At&&(Mt=vn(st,Xo(Je(st,Wt))-it.wrapper.clientHeight),At=Wt)}return{from:Mt,to:Math.max(At,Mt+1)}}function Wf(it,st){if(!Yn(it,"scrollCursorIntoView")){var ct=it.display,ht=ct.sizer.getBoundingClientRect(),pt=null;if(st.top+ht.top<0?pt=!0:st.bottom+ht.top>(window.innerHeight||document.documentElement.clientHeight)&&(pt=!1),pt!=null&&!Re){var Mt=Yt("div","\u200B",null,`position: absolute; top: `+(st.top-ct.viewOffset-ka(it.display))+`px; height: `+(st.bottom-st.top+Da(it)+ct.barHeight)+`px; left: `+st.left+"px; width: "+Math.max(2,st.right-st.left)+"px;");it.display.lineSpace.appendChild(Mt),Mt.scrollIntoView(pt),it.display.lineSpace.removeChild(Mt)}}}function Wd(it,st,ct,ht){ht==null&&(ht=0);var pt;!it.options.lineWrapping&&st==ct&&(st=st.ch?Ae(st.line,st.sticky=="before"?st.ch-1:st.ch,"after"):st,ct=st.sticky=="before"?Ae(st.line,st.ch+1,"before"):st);for(var Mt=0;Mt<5;Mt++){var At=!1,Ut=xs(it,st),Wt=!ct||ct==st?Ut:xs(it,ct);pt={left:Math.min(Ut.left,Wt.left),top:Math.min(Ut.top,Wt.top)-ht,right:Math.max(Ut.left,Wt.left),bottom:Math.max(Ut.bottom,Wt.bottom)+ht};var de=Kf(it,pt),Ke=it.doc.scrollTop,xe=it.doc.scrollLeft;if(de.scrollTop!=null&&(Yh(it,de.scrollTop),Math.abs(it.doc.scrollTop-Ke)>1&&(At=!0)),de.scrollLeft!=null&&(Hu(it,de.scrollLeft),Math.abs(it.doc.scrollLeft-xe)>1&&(At=!0)),!At)break}return pt}function Kd(it,st){var ct=Kf(it,st);ct.scrollTop!=null&&Yh(it,ct.scrollTop),ct.scrollLeft!=null&&Hu(it,ct.scrollLeft)}function Kf(it,st){var ct=it.display,ht=zu(it.display);st.top<0&&(st.top=0);var pt=it.curOp&&it.curOp.scrollTop!=null?it.curOp.scrollTop:ct.scroller.scrollTop,Mt=Hh(it),At={};st.bottom-st.top>Mt&&(st.bottom=st.top+Mt);var Ut=it.doc.height+Pu(ct),Wt=st.topUt-ht;if(st.toppt+Mt){var Ke=Math.min(st.top,(de?Ut:st.bottom)-Mt);Ke!=pt&&(At.scrollTop=Ke)}var xe=it.options.fixedGutter?0:ct.gutters.offsetWidth,Sn=it.curOp&&it.curOp.scrollLeft!=null?it.curOp.scrollLeft:ct.scroller.scrollLeft-xe,hn=sl(it)-ct.gutters.offsetWidth,_n=st.right-st.left>hn;return _n&&(st.right=st.left+hn),st.left<10?At.scrollLeft=0:st.lefthn+Sn-3&&(At.scrollLeft=st.right+(_n?0:10)-hn),At}function bc(it,st){st!=null&&(ju(it),it.curOp.scrollTop=(it.curOp.scrollTop==null?it.doc.scrollTop:it.curOp.scrollTop)+st)}function yh(it){ju(it);var st=it.getCursor();it.curOp.scrollToPos={from:st,to:st,margin:it.options.cursorScrollMargin}}function Uh(it,st,ct){(st!=null||ct!=null)&&ju(it),st!=null&&(it.curOp.scrollLeft=st),ct!=null&&(it.curOp.scrollTop=ct)}function Dr(it,st){ju(it),it.curOp.scrollToPos=st}function ju(it){var st=it.curOp.scrollToPos;if(st){it.curOp.scrollToPos=null;var ct=xc(it,st.from),ht=xc(it,st.to);sf(it,ct,ht,st.margin)}}function sf(it,st,ct,ht){var pt=Kf(it,{left:Math.min(st.left,ct.left),top:Math.min(st.top,ct.top)-ht,right:Math.max(st.right,ct.right),bottom:Math.max(st.bottom,ct.bottom)+ht});Uh(it,pt.scrollLeft,pt.scrollTop)}function Yh(it,st){Math.abs(it.doc.scrollTop-st)<2||(Ft||ki(it,{top:st}),Zf(it,st,!0),Ft&&ki(it),On(it,100))}function Zf(it,st,ct){st=Math.max(0,Math.min(it.display.scroller.scrollHeight-it.display.scroller.clientHeight,st)),!(it.display.scroller.scrollTop==st&&!ct)&&(it.doc.scrollTop=st,it.display.scrollbars.setScrollTop(st),it.display.scroller.scrollTop!=st&&(it.display.scroller.scrollTop=st))}function Hu(it,st,ct,ht){st=Math.max(0,Math.min(st,it.display.scroller.scrollWidth-it.display.scroller.clientWidth)),!((ct?st==it.doc.scrollLeft:Math.abs(it.doc.scrollLeft-st)<2)&&!ht)&&(it.doc.scrollLeft=st,To(it),it.display.scroller.scrollLeft!=st&&(it.display.scroller.scrollLeft=st),it.display.scrollbars.setScrollLeft(st))}function hu(it){var st=it.display,ct=st.gutters.offsetWidth,ht=Math.round(it.doc.height+Pu(it.display));return{clientHeight:st.scroller.clientHeight,viewHeight:st.wrapper.clientHeight,scrollWidth:st.scroller.scrollWidth,clientWidth:st.scroller.clientWidth,viewWidth:st.wrapper.clientWidth,barLeft:it.options.fixedGutter?ct:0,docHeight:ht,scrollHeight:ht+Da(it)+st.barHeight,nativeBarWidth:st.nativeBarWidth,gutterWidth:ct}}var Sh=function(it,st,ct){this.cm=ct;var ht=this.vert=Yt("div",[Yt("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),pt=this.horiz=Yt("div",[Yt("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");ht.tabIndex=pt.tabIndex=-1,it(ht),it(pt),Ge(ht,"scroll",function(){ht.clientHeight&&st(ht.scrollTop,"vertical")}),Ge(pt,"scroll",function(){pt.clientWidth&&st(pt.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,Vt&&qt<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Sh.prototype.update=function(it){var st=it.scrollWidth>it.clientWidth+1,ct=it.scrollHeight>it.clientHeight+1,ht=it.nativeBarWidth;if(ct){this.vert.style.display="block",this.vert.style.bottom=st?ht+"px":"0";var pt=it.viewHeight-(st?ht:0);this.vert.firstChild.style.height=Math.max(0,it.scrollHeight-it.clientHeight+pt)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(st){this.horiz.style.display="block",this.horiz.style.right=ct?ht+"px":"0",this.horiz.style.left=it.barLeft+"px";var Mt=it.viewWidth-it.barLeft-(ct?ht:0);this.horiz.firstChild.style.width=Math.max(0,it.scrollWidth-it.clientWidth+Mt)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&it.clientHeight>0&&(ht==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:ct?ht:0,bottom:st?ht:0}},Sh.prototype.setScrollLeft=function(it){this.horiz.scrollLeft!=it&&(this.horiz.scrollLeft=it),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Sh.prototype.setScrollTop=function(it){this.vert.scrollTop!=it&&(this.vert.scrollTop=it),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Sh.prototype.zeroWidthHack=function(){var it=dt&&!ye?"12px":"18px";this.horiz.style.height=this.vert.style.width=it,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new jt,this.disableVert=new jt},Sh.prototype.enableZeroWidthBar=function(it,st,ct){it.style.pointerEvents="auto";function ht(){var pt=it.getBoundingClientRect(),Mt=ct=="vert"?document.elementFromPoint(pt.right-1,(pt.top+pt.bottom)/2):document.elementFromPoint((pt.right+pt.left)/2,pt.bottom-1);Mt!=it?it.style.pointerEvents="none":st.set(1e3,ht)}st.set(1e3,ht)},Sh.prototype.clear=function(){var it=this.horiz.parentNode;it.removeChild(this.horiz),it.removeChild(this.vert)};var wu=function(){};wu.prototype.update=function(){return{bottom:0,right:0}},wu.prototype.setScrollLeft=function(){},wu.prototype.setScrollTop=function(){},wu.prototype.clear=function(){};function xh(it,st){st||(st=hu(it));var ct=it.display.barWidth,ht=it.display.barHeight;Lc(it,st);for(var pt=0;pt<4&&ct!=it.display.barWidth||ht!=it.display.barHeight;pt++)ct!=it.display.barWidth&&it.options.lineWrapping&&Mo(it),Lc(it,hu(it)),ct=it.display.barWidth,ht=it.display.barHeight}function Lc(it,st){var ct=it.display,ht=ct.scrollbars.update(st);ct.sizer.style.paddingRight=(ct.barWidth=ht.right)+"px",ct.sizer.style.paddingBottom=(ct.barHeight=ht.bottom)+"px",ct.heightForcer.style.borderBottom=ht.bottom+"px solid transparent",ht.right&&ht.bottom?(ct.scrollbarFiller.style.display="block",ct.scrollbarFiller.style.height=ht.bottom+"px",ct.scrollbarFiller.style.width=ht.right+"px"):ct.scrollbarFiller.style.display="",ht.bottom&&it.options.coverGutterNextToScrollbar&&it.options.fixedGutter?(ct.gutterFiller.style.display="block",ct.gutterFiller.style.height=ht.bottom+"px",ct.gutterFiller.style.width=st.gutterWidth+"px"):ct.gutterFiller.style.display=""}var af={native:Sh,null:wu};function lf(it){it.display.scrollbars&&(it.display.scrollbars.clear(),it.display.scrollbars.addClass&&Dt(it.display.wrapper,it.display.scrollbars.addClass)),it.display.scrollbars=new af[it.options.scrollbarStyle](function(st){it.display.wrapper.insertBefore(st,it.display.scrollbarFiller),Ge(st,"mousedown",function(){it.state.focused&&setTimeout(function(){return it.display.input.focus()},0)}),st.setAttribute("cm-not-content","true")},function(st,ct){ct=="horizontal"?Hu(it,st):Yh(it,st)},it),it.display.scrollbars.addClass&&Xe(it.display.wrapper,it.display.scrollbars.addClass)}var Vf=0;function al(it){it.curOp={cm:it,viewChanged:!1,startHeight:it.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:++Vf},Ul(it.curOp)}function Ph(it){var st=it.curOp;st&&hr(st,function(ct){for(var ht=0;ht=ct.viewTo)||ct.maxLineChanged&&st.options.lineWrapping,it.update=it.mustUpdate&&new In(st,it.mustUpdate&&{top:it.scrollTop,ensure:it.scrollToPos},it.forceUpdate)}function ee(it){it.updatedDisplay=it.mustUpdate&&Oi(it.cm,it.update)}function Ee(it){var st=it.cm,ct=st.display;it.updatedDisplay&&Mo(st),it.barMeasure=hu(st),ct.maxLineChanged&&!st.options.lineWrapping&&(it.adjustWidthTo=$h(st,ct.maxLine,ct.maxLine.text.length).left+3,st.display.sizerWidth=it.adjustWidthTo,it.barMeasure.scrollWidth=Math.max(ct.scroller.clientWidth,ct.sizer.offsetLeft+it.adjustWidthTo+Da(st)+st.display.barWidth),it.maxScrollLeft=Math.max(0,ct.sizer.offsetLeft+it.adjustWidthTo-sl(st))),(it.updatedDisplay||it.selectionChanged)&&(it.preparedSelection=ct.input.prepareSelection())}function Te(it){var st=it.cm;it.adjustWidthTo!=null&&(st.display.sizer.style.minWidth=it.adjustWidthTo+"px",it.maxScrollLeft=it.display.viewTo)){var ct=+new Date+it.options.workTime,ht=io(it,st.highlightFrontier),pt=[];st.iter(ht.line,Math.min(st.first+st.size,it.display.viewTo+500),function(Mt){if(ht.line>=it.display.viewFrom){var At=Mt.styles,Ut=Mt.text.length>it.options.maxHighlightLength?on(st.mode,ht.state):null,Wt=Bo(it,Mt,ht,!0);Ut&&(ht.state=Ut),Mt.styles=Wt.styles;var de=Mt.styleClasses,Ke=Wt.classes;Ke?Mt.styleClasses=Ke:de&&(Mt.styleClasses=null);for(var xe=!At||At.length!=Mt.styles.length||de!=Ke&&(!de||!Ke||de.bgClass!=Ke.bgClass||de.textClass!=Ke.textClass),Sn=0;!xe&&Snct)return On(it,it.options.workDelay),!0}),st.highlightFrontier=ht.line,st.modeFrontier=Math.max(st.modeFrontier,ht.line),pt.length&&He(it,function(){for(var Mt=0;Mt=ct.viewFrom&&st.visible.to<=ct.viewTo&&(ct.updateLineNumbers==null||ct.updateLineNumbers>=ct.viewTo)&&ct.renderedView==ct.view&&Bl(it)==0)return!1;Ii(it)&&(na(it),st.dims=Cc(it));var pt=ht.first+ht.size,Mt=Math.max(st.visible.from-it.options.viewportMargin,ht.first),At=Math.min(pt,st.visible.to+it.options.viewportMargin);ct.viewFromAt&&ct.viewTo-At<20&&(At=Math.min(pt,ct.viewTo)),mn&&(Mt=qi(it.doc,Mt),At=Ai(it.doc,At));var Ut=Mt!=ct.viewFrom||At!=ct.viewTo||ct.lastWrapHeight!=st.wrapperHeight||ct.lastWrapWidth!=st.wrapperWidth;os(it,Mt,At),ct.viewOffset=Xo(Je(it.doc,ct.viewFrom)),it.display.mover.style.top=ct.viewOffset+"px";var Wt=Bl(it);if(!Ut&&Wt==0&&!st.force&&ct.renderedView==ct.view&&(ct.updateLineNumbers==null||ct.updateLineNumbers>=ct.viewTo))return!1;var de=li(it);return Wt>4&&(ct.lineDiv.style.display="none"),Ei(it,ct.updateLineNumbers,st.dims),Wt>4&&(ct.lineDiv.style.display=""),ct.renderedView=ct.view,qn(de),$t(ct.cursorDiv),$t(ct.selectionDiv),ct.gutters.style.height=ct.sizer.style.minHeight=0,Ut&&(ct.lastWrapHeight=st.wrapperHeight,ct.lastWrapWidth=st.wrapperWidth,On(it,400)),ct.updateLineNumbers=null,!0}function si(it,st){for(var ct=st.viewport,ht=!0;;ht=!1){if(!ht||!it.options.lineWrapping||st.oldDisplayWidth==sl(it)){if(ct&&ct.top!=null&&(ct={top:Math.min(it.doc.height+Pu(it.display)-Hh(it),ct.top)}),st.visible=br(it.display,it.doc,ct),st.visible.from>=it.display.viewFrom&&st.visible.to<=it.display.viewTo)break}else ht&&(st.visible=br(it.display,it.doc,ct));if(!Oi(it,st))break;Mo(it);var pt=hu(it);ma(it),xh(it,pt),vo(it,pt),st.force=!1}st.signal(it,"update",it),(it.display.viewFrom!=it.display.reportedViewFrom||it.display.viewTo!=it.display.reportedViewTo)&&(st.signal(it,"viewportChange",it,it.display.viewFrom,it.display.viewTo),it.display.reportedViewFrom=it.display.viewFrom,it.display.reportedViewTo=it.display.viewTo)}function ki(it,st){var ct=new In(it,st);if(Oi(it,ct)){Mo(it),si(it,ct);var ht=hu(it);ma(it),xh(it,ht),vo(it,ht),ct.finish()}}function Ei(it,st,ct){var ht=it.display,pt=it.options.lineNumbers,Mt=ht.lineDiv,At=Mt.firstChild;function Ut(_n){var ai=_n.nextSibling;return Nt&&dt&&it.display.currentWheelTarget==_n?_n.style.display="none":_n.parentNode.removeChild(_n),ai}for(var Wt=ht.view,de=ht.viewFrom,Ke=0;Ke-1&&(hn=!1),Fs(it,xe,de,ct)),hn&&($t(xe.lineNumber),xe.lineNumber.appendChild(document.createTextNode(xi(it.options,de)))),At=xe.node.nextSibling}de+=xe.size}for(;At;)At=Ut(At)}function Gi(it){var st=it.gutters.offsetWidth;it.sizer.style.marginLeft=st+"px"}function vo(it,st){it.display.sizer.style.minHeight=st.docHeight+"px",it.display.heightForcer.style.top=st.docHeight+"px",it.display.gutters.style.height=st.docHeight+it.display.barHeight+Da(it)+"px"}function To(it){var st=it.display,ct=st.view;if(!(!st.alignWidgets&&(!st.gutters.firstChild||!it.options.fixedGutter))){for(var ht=fd(st)-st.scroller.scrollLeft+it.doc.scrollLeft,pt=st.gutters.offsetWidth,Mt=ht+"px",At=0;AtAt.clientWidth,Wt=At.scrollHeight>At.clientHeight;if(ht&&Ut||pt&&Wt){if(pt&&dt&&Nt){t:for(var de=st.target,Ke=Mt.view;de!=At;de=de.parentNode)for(var xe=0;xe=0&&en(it,ht.to())<=0)return ct}return-1};var Bi=function(it,st){this.anchor=it,this.head=st};Bi.prototype.from=function(){return Zn(this.anchor,this.head)},Bi.prototype.to=function(){return Si(this.anchor,this.head)},Bi.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function ir(it,st,ct){var ht=it&&it.options.selectionsMayTouch,pt=st[ct];st.sort(function(Sn,hn){return en(Sn.from(),hn.from())}),ct=$e(st,pt);for(var Mt=1;Mt0:Wt>=0){var de=Zn(Ut.from(),At.from()),Ke=Si(Ut.to(),At.to()),xe=Ut.empty()?At.from()==At.head:Ut.from()==Ut.head;Mt<=ct&&--ct,st.splice(--Mt,2,new Bi(xe?Ke:de,xe?de:Ke))}}return new jo(st,ct)}function ur(it,st){return new jo([new Bi(it,st||it)],0)}function $r(it){return it.text?Ae(it.from.line+it.text.length-1,we(it.text).length+(it.text.length==1?it.from.ch:0)):it.to}function Pr(it,st){if(en(it,st.from)<0)return it;if(en(it,st.to)<=0)return $r(st);var ct=it.line+st.text.length-(st.to.line-st.from.line)-1,ht=it.ch;return it.line==st.to.line&&(ht+=$r(st).ch-st.to.ch),Ae(ct,ht)}function ws(it,st){for(var ct=[],ht=0;ht1&&it.remove(Ut.line+1,_n-1),it.insert(Ut.line+1,Di)}ci(it,"change",it,st)}function qs(it,st,ct){function ht(pt,Mt,At){if(pt.linked)for(var Ut=0;Ut1&&!it.done[it.done.length-2].ranges)return it.done.pop(),we(it.done)}function Lr(it,st,ct,ht){var pt=it.history;pt.undone.length=0;var Mt=+new Date,At,Ut;if((pt.lastOp==ht||pt.lastOrigin==st.origin&&st.origin&&(st.origin.charAt(0)=="+"&&pt.lastModTime>Mt-(it.cm?it.cm.options.historyEventDelay:500)||st.origin.charAt(0)=="*"))&&(At=er(pt,pt.lastOp==ht)))Ut=we(At.changes),en(st.from,st.to)==0&&en(st.from,Ut.to)==0?Ut.to=$r(st):At.changes.push(Ar(it,st));else{var Wt=we(pt.done);for((!Wt||!Wt.ranges)&&ia(it.sel,pt.done),At={changes:[Ar(it,st)],generation:pt.generation},pt.done.push(At);pt.done.length>pt.undoDepth;)pt.done.shift(),pt.done[0].ranges||pt.done.shift()}pt.done.push(ct),pt.generation=++pt.maxGeneration,pt.lastModTime=pt.lastSelTime=Mt,pt.lastOp=pt.lastSelOp=ht,pt.lastOrigin=pt.lastSelOrigin=st.origin,Ut||pn(it,"historyAdded")}function Mr(it,st,ct,ht){var pt=st.charAt(0);return pt=="*"||pt=="+"&&ct.ranges.length==ht.ranges.length&&ct.somethingSelected()==ht.somethingSelected()&&new Date-it.history.lastSelTime<=(it.cm?it.cm.options.historyEventDelay:500)}function va(it,st,ct,ht){var pt=it.history,Mt=ht&&ht.origin;ct==pt.lastSelOp||Mt&&pt.lastSelOrigin==Mt&&(pt.lastModTime==pt.lastSelTime&&pt.lastOrigin==Mt||Mr(it,Mt,we(pt.done),st))?pt.done[pt.done.length-1]=st:ia(st,pt.done),pt.lastSelTime=+new Date,pt.lastSelOrigin=Mt,pt.lastSelOp=ct,ht&&ht.clearRedo!==!1&&So(pt.undone)}function ia(it,st){var ct=we(st);ct&&ct.ranges&&ct.equals(it)||st.push(it)}function Ra(it,st,ct,ht){var pt=st["spans_"+it.id],Mt=0;it.iter(Math.max(it.first,ct),Math.min(it.first+it.size,ht),function(At){At.markedSpans&&((pt||(pt=st["spans_"+it.id]={}))[Mt]=At.markedSpans),++Mt})}function Wr(it){if(!it)return null;for(var st,ct=0;ct-1&&(we(Ut)[xe]=de[xe],delete de[xe])}}return ht}function Gu(it,st,ct,ht){if(ht){var pt=it.anchor;if(ct){var Mt=en(st,pt)<0;Mt!=en(ct,pt)<0?(pt=st,st=ct):Mt!=en(st,ct)<0&&(st=ct)}return new Bi(pt,st)}else return new Bi(ct||st,st)}function Kr(it,st,ct,ht,pt){pt==null&&(pt=it.cm&&(it.cm.display.shift||it.extend)),rs(it,new jo([Gu(it.sel.primary(),st,ct,pt)],0),ht)}function Xr(it,st,ct){for(var ht=[],pt=it.cm&&(it.cm.display.shift||it.extend),Mt=0;Mt=st.ch:Ut.to>st.ch))){if(pt&&(pn(Wt,"beforeCursorEnter"),Wt.explicitlyCleared))if(Mt.markedSpans){--At;continue}else break;if(!Wt.atomic)continue;if(ct){var xe=Wt.find(ht<0?1:-1),Sn=void 0;if((ht<0?Ke:de)&&(xe=Al(it,xe,-ht,xe&&xe.line==st.line?Mt:null)),xe&&xe.line==st.line&&(Sn=en(xe,ct))&&(ht<0?Sn<0:Sn>0))return Xl(it,xe,st,ht,pt)}var hn=Wt.find(ht<0?-1:1);return(ht<0?de:Ke)&&(hn=Al(it,hn,ht,hn.line==st.line?Mt:null)),hn?Xl(it,hn,st,ht,pt):null}}return st}function _l(it,st,ct,ht,pt){var Mt=ht||1,At=Xl(it,st,ct,Mt,pt)||!pt&&Xl(it,st,ct,Mt,!0)||Xl(it,st,ct,-Mt,pt)||!pt&&Xl(it,st,ct,-Mt,!0);return At||(it.cantEdit=!0,Ae(it.first,0))}function Al(it,st,ct,ht){return ct<0&&st.ch==0?st.line>it.first?Qn(it,Ae(st.line-1)):null:ct>0&&st.ch==(ht||Je(it,st.line)).text.length?st.line=0;--pt)ss(it,{from:ht[pt].from,to:ht[pt].to,text:pt?[""]:st.text,origin:st.origin});else ss(it,st)}}function ss(it,st){if(!(st.text.length==1&&st.text[0]==""&&en(st.from,st.to)==0)){var ct=ws(it,st);Lr(it,st,ct,it.cm?it.cm.curOp.id:NaN),Jl(it,st,ct,Ui(it,st));var ht=[];qs(it,function(pt,Mt){!Mt&&$e(ht,pt.history)==-1&&(hs(pt.history,st),ht.push(pt.history)),Jl(pt,st,null,Ui(pt,st))})}}function Rl(it,st,ct){var ht=it.cm&&it.cm.state.suppressEdits;if(!(ht&&!ct)){for(var pt=it.history,Mt,At=it.sel,Ut=st=="undo"?pt.done:pt.undone,Wt=st=="undo"?pt.undone:pt.done,de=0;de=0;--hn){var _n=Sn(hn);if(_n)return _n.v}}}}function ih(it,st){if(st!=0&&(it.first+=st,it.sel=new jo(Bn(it.sel.ranges,function(pt){return new Bi(Ae(pt.anchor.line+st,pt.anchor.ch),Ae(pt.head.line+st,pt.head.ch))}),it.sel.primIndex),it.cm)){ls(it.cm,it.first,it.first-st,st);for(var ct=it.cm.display,ht=ct.viewFrom;htit.lastLine())){if(st.from.lineMt&&(st={from:st.from,to:Ae(Mt,Je(it,Mt).text.length),text:[st.text[0]],origin:st.origin}),st.removed=gn(it,st.from,st.to),ct||(ct=ws(it,st)),it.cm?Cu(it.cm,st,ht):us(it,st,ht),da(it,ct,Ne),it.cantEdit&&_l(it,Ae(it.firstLine(),0))&&(it.cantEdit=!1)}}function Cu(it,st,ct){var ht=it.doc,pt=it.display,Mt=st.from,At=st.to,Ut=!1,Wt=Mt.line;it.options.lineWrapping||(Wt=ce(ao(Je(ht,Mt.line))),ht.iter(Wt,At.line+1,function(hn){if(hn==pt.maxLine)return Ut=!0,!0})),ht.sel.contains(st.from,st.to)>-1&&ni(it),us(ht,st,ct,Ds(it)),it.options.lineWrapping||(ht.iter(Wt,Mt.line+st.text.length,function(hn){var _n=zr(hn);_n>pt.maxLineLength&&(pt.maxLine=hn,pt.maxLineLength=_n,pt.maxLineChanged=!0,Ut=!1)}),Ut&&(it.curOp.updateMaxLine=!0)),Hi(ht,Mt.line),On(it,400);var de=st.text.length-(At.line-Mt.line)-1;st.full?ls(it):Mt.line==At.line&&st.text.length==1&&!Cs(it.doc,st)?cr(it,Mt.line,"text"):ls(it,Mt.line,At.line+1,de);var Ke=Un(it,"changes"),xe=Un(it,"change");if(xe||Ke){var Sn={from:Mt,to:At,text:st.text,removed:st.removed,origin:st.origin};xe&&ci(it,"change",it,Sn),Ke&&(it.curOp.changeObjs||(it.curOp.changeObjs=[])).push(Sn)}it.display.selForContextMenu=null}function $u(it,st,ct,ht,pt){var Mt;ht||(ht=ct),en(ht,ct)<0&&(Mt=[ht,ct],ct=Mt[0],ht=Mt[1]),typeof st=="string"&&(st=it.splitLines(st)),As(it,{from:ct,to:ht,text:st,origin:pt})}function xl(it,st,ct,ht){ct1||!(this.children[0]instanceof ds))){var Ut=[];this.collapse(Ut),this.children=[new ds(Ut)],this.children[0].parent=this}},collapse:function(it){for(var st=0;st50){for(var At=pt.lines.length%25+25,Ut=At;Ut10);it.parent.maybeSpill()}},iterN:function(it,st,ct){for(var ht=0;htit.display.maxLineLength&&(it.display.maxLine=de,it.display.maxLineLength=Ke,it.display.maxLineChanged=!0)}ht!=null&&it&&this.collapsed&&ls(it,ht,pt+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,it&&Dl(it.doc)),it&&ci(it,"markerCleared",it,this,ht,pt),st&&Ph(it),this.parent&&this.parent.clear()}},Be.prototype.find=function(it,st){it==null&&this.type=="bookmark"&&(it=1);for(var ct,ht,pt=0;pt0||At==0&&Mt.clearWhenEmpty!==!1)return Mt;if(Mt.replacedWith&&(Mt.collapsed=!0,Mt.widgetNode=fe("span",[Mt.replacedWith],"CodeMirror-widget"),ht.handleMouseEvents||Mt.widgetNode.setAttribute("cm-ignore-events","true"),ht.insertLeft&&(Mt.widgetNode.insertLeft=!0)),Mt.collapsed){if(Ko(it,st.line,st,ct,Mt)||st.line!=ct.line&&Ko(it,ct.line,st,ct,Mt))throw new Error("Inserting collapsed marker partially overlapping an existing one");un()}Mt.addToHistory&&Lr(it,{from:st,to:ct,origin:"markText"},it.sel,NaN);var Ut=st.line,Wt=it.cm,de;if(it.iter(Ut,ct.line+1,function(xe){Wt&&Mt.collapsed&&!Wt.options.lineWrapping&&ao(xe)==Wt.display.maxLine&&(de=!0),Mt.collapsed&&Ut!=st.line&&Gn(xe,0),Hr(xe,new Po(Mt,Ut==st.line?st.ch:null,Ut==ct.line?ct.ch:null)),++Ut}),Mt.collapsed&&it.iter(st.line,ct.line+1,function(xe){Nn(it,xe)&&Gn(xe,0)}),Mt.clearOnEnter&&Ge(Mt,"beforeCursorEnter",function(){return Mt.clear()}),Mt.readOnly&&(Uo(),(it.history.done.length||it.history.undone.length)&&it.clearHistory()),Mt.collapsed&&(Mt.id=++uf,Mt.atomic=!0),Wt){if(de&&(Wt.curOp.updateMaxLine=!0),Mt.collapsed)ls(Wt,st.line,ct.line+1);else if(Mt.className||Mt.startStyle||Mt.endStyle||Mt.css||Mt.attributes||Mt.title)for(var Ke=st.line;Ke<=ct.line;Ke++)cr(Wt,Ke,"text");Mt.atomic&&Dl(Wt.doc),ci(Wt,"markerAdded",Wt,Mt)}return Mt}var Wu=function(it,st){this.markers=it,this.primary=st;for(var ct=0;ct=0;Wt--)As(this,ht[Wt]);Ut?vr(this,Ut):this.cm&&yh(this.cm)}),undo:ln(function(){Rl(this,"undo")}),redo:ln(function(){Rl(this,"redo")}),undoSelection:ln(function(){Rl(this,"undo",!0)}),redoSelection:ln(function(){Rl(this,"redo",!0)}),setExtending:function(it){this.extend=it},getExtending:function(){return this.extend},historySize:function(){for(var it=this.history,st=0,ct=0,ht=0;ht=it.ch)&&st.push(pt.marker.parent||pt.marker)}return st},findMarks:function(it,st,ct){it=Qn(this,it),st=Qn(this,st);var ht=[],pt=it.line;return this.iter(it.line,st.line+1,function(Mt){var At=Mt.markedSpans;if(At)for(var Ut=0;Ut=Wt.to||Wt.from==null&&pt!=it.line||Wt.from!=null&&pt==st.line&&Wt.from>=st.ch)&&(!ct||ct(Wt.marker))&&ht.push(Wt.marker.parent||Wt.marker)}++pt}),ht},getAllMarks:function(){var it=[];return this.iter(function(st){var ct=st.markedSpans;if(ct)for(var ht=0;htit)return st=it,!0;it-=Mt,++ct}),Qn(this,Ae(ct,st))},indexFromPos:function(it){it=Qn(this,it);var st=it.ch;if(it.linest&&(st=it.from),it.to!=null&&it.to-1){st.state.draggingText(it),setTimeout(function(){return st.display.input.focus()},20);return}try{var Ke=it.dataTransfer.getData("Text");if(Ke){var xe;if(st.state.draggingText&&!st.state.draggingText.copy&&(xe=st.listSelections()),da(st.doc,ur(ct,ct)),xe)for(var Sn=0;Sn=0;Ut--)$u(it.doc,"",ht[Ut].from,ht[Ut].to,"+delete");yh(it)})}function Ic(it,st,ct){var ht=ne(it.text,st+ct,ct);return ht<0||ht>it.text.length?null:ht}function ra(it,st,ct){var ht=Ic(it,st.ch,ct);return ht==null?null:new Ae(st.line,ht,ct<0?"after":"before")}function Zr(it,st,ct,ht,pt){if(it){st.doc.direction=="rtl"&&(pt=-pt);var Mt=nn(ct,st.doc.direction);if(Mt){var At=pt<0?we(Mt):Mt[0],Ut=pt<0==(At.level==1),Wt=Ut?"after":"before",de;if(At.level>0||st.doc.direction=="rtl"){var Ke=Du(st,ct);de=pt<0?ct.text.length-1:0;var xe=Fl(st,Ke,de).top;de=_t(function(Sn){return Fl(st,Ke,Sn).top==xe},pt<0==(At.level==1)?At.from:At.to-1,de),Wt=="before"&&(de=Ic(ct,de,1))}else de=pt<0?At.to:At.from;return new Ae(ht,de,Wt)}}return new Ae(ht,pt<0?ct.text.length:0,pt<0?"before":"after")}function Ss(it,st,ct,ht){var pt=nn(st,it.doc.direction);if(!pt)return ra(st,ct,ht);ct.ch>=st.text.length?(ct.ch=st.text.length,ct.sticky="before"):ct.ch<=0&&(ct.ch=0,ct.sticky="after");var Mt=le(pt,ct.ch,ct.sticky),At=pt[Mt];if(it.doc.direction=="ltr"&&At.level%2==0&&(ht>0?At.to>ct.ch:At.from=At.from&&Sn>=Ke.begin)){var hn=xe?"before":"after";return new Ae(ct.line,Sn,hn)}}var _n=function(Di,uo,Ji){for(var Lo=function(Zs,Oa){return Oa?new Ae(ct.line,Ut(Zs,1),"before"):new Ae(ct.line,Zs,"after")};Di>=0&&Di0==(or.level!=1),yr=Xi?Ji.begin:Ut(Ji.end,-1);if(or.from<=yr&&yr0?Ke.end:Ut(Ke.begin,-1);return vi!=null&&!(ht>0&&vi==st.text.length)&&(ai=_n(ht>0?0:pt.length-1,ht,de(vi)),ai)?ai:null}var Na={selectAll:Ur,singleSelection:function(it){return it.setSelection(it.getCursor("anchor"),it.getCursor("head"),Ne)},killLine:function(it){return qa(it,function(st){if(st.empty()){var ct=Je(it.doc,st.head.line).text.length;return st.head.ch==ct&&st.head.line0)pt=new Ae(pt.line,pt.ch+1),it.replaceRange(Mt.charAt(pt.ch-1)+Mt.charAt(pt.ch-2),Ae(pt.line,pt.ch-2),pt,"+transpose");else if(pt.line>it.doc.first){var At=Je(it.doc,pt.line-1).text;At&&(pt=new Ae(pt.line,1),it.replaceRange(Mt.charAt(0)+it.doc.lineSeparator()+At.charAt(At.length-1),Ae(pt.line-1,At.length-1),pt,"+transpose"))}}ct.push(new Bi(pt,pt))}it.setSelections(ct)})},newlineAndIndent:function(it){return He(it,function(){for(var st=it.listSelections(),ct=st.length-1;ct>=0;ct--)it.replaceRange(it.doc.lineSeparator(),st[ct].anchor,st[ct].head,"+input");st=it.listSelections();for(var ht=0;htit&&en(st,this.pos)==0&&ct==this.button};var Dc,Xd;function _g(it,st){var ct=+new Date;return Xd&&Xd.compare(ct,it,st)?(Dc=Xd=null,"triple"):Dc&&Dc.compare(ct,it,st)?(Xd=new Xg(ct,it,st),Dc=null,"double"):(Dc=new Xg(ct,it,st),Xd=null,"single")}function sh(it){var st=this,ct=st.display;if(!(Yn(st,it)||ct.activeTouch&&ct.input.supportsTouch())){if(ct.input.ensurePolled(),ct.shift=it.shiftKey,_a(ct,it)){Nt||(ct.scroller.draggable=!1,setTimeout(function(){return ct.scroller.draggable=!0},100));return}if(!qf(st,it)){var ht=Ja(st,it),pt=Ao(it),Mt=ht?_g(ht,pt):"single";window.focus(),pt==1&&st.state.selectingText&&st.state.selectingText(it),!(ht&&Jg(st,pt,ht,Mt,it))&&(pt==1?ht?rm(st,ht,Mt,it):Io(it)==ct.scroller&&mi(it):pt==2?(ht&&Kr(st.doc,ht),setTimeout(function(){return ct.input.focus()},20)):pt==3&&(kt?st.display.input.onContextMenu(it):Gs(st)))}}}function Jg(it,st,ct,ht,pt){var Mt="Click";return ht=="double"?Mt="Double"+Mt:ht=="triple"&&(Mt="Triple"+Mt),Mt=(st==1?"Left":st==2?"Middle":"Right")+Mt,oh(it,Oc(Mt,pt),pt,function(At){if(typeof At=="string"&&(At=Na[At]),!At)return!1;var Ut=!1;try{it.isReadOnly()&&(it.state.suppressEdits=!0),Ut=At(it,ct)!=En}finally{it.state.suppressEdits=!1}return Ut})}function Jf(it,st,ct){var ht=it.getOption("configureMouse"),pt=ht?ht(it,st,ct):{};if(pt.unit==null){var Mt=at?ct.shiftKey&&ct.metaKey:ct.altKey;pt.unit=Mt?"rectangle":st=="single"?"char":st=="double"?"word":"line"}return(pt.extend==null||it.doc.extend)&&(pt.extend=it.doc.extend||ct.shiftKey),pt.addNew==null&&(pt.addNew=dt?ct.metaKey:ct.ctrlKey),pt.moveOnDrag==null&&(pt.moveOnDrag=!(dt?ct.altKey:ct.ctrlKey)),pt}function rm(it,st,ct,ht){Vt?setTimeout(ze(Ps,it),0):it.curOp.focus=me();var pt=Jf(it,ct,ht),Mt=it.doc.sel,At;it.options.dragDrop&&$n&&!it.isReadOnly()&&ct=="single"&&(At=Mt.contains(st))>-1&&(en((At=Mt.ranges[At]).from(),st)<0||st.xRel>0)&&(en(At.to(),st)>0||st.xRel<0)?Qg(it,ht,st,pt):ev(it,ht,st,pt)}function Qg(it,st,ct,ht){var pt=it.display,Mt=!1,At=dn(it,function(de){Nt&&(pt.scroller.draggable=!1),it.state.draggingText=!1,wn(pt.wrapper.ownerDocument,"mouseup",At),wn(pt.wrapper.ownerDocument,"mousemove",Ut),wn(pt.scroller,"dragstart",Wt),wn(pt.scroller,"drop",At),Mt||(mi(de),ht.addNew||Kr(it.doc,ct,null,null,ht.extend),Nt&&!Fe||Vt&&qt==9?setTimeout(function(){pt.wrapper.ownerDocument.body.focus({preventScroll:!0}),pt.input.focus()},20):pt.input.focus())}),Ut=function(de){Mt=Mt||Math.abs(st.clientX-de.clientX)+Math.abs(st.clientY-de.clientY)>=10},Wt=function(){return Mt=!0};Nt&&(pt.scroller.draggable=!0),it.state.draggingText=At,At.copy=!ht.moveOnDrag,pt.scroller.dragDrop&&pt.scroller.dragDrop(),Ge(pt.wrapper.ownerDocument,"mouseup",At),Ge(pt.wrapper.ownerDocument,"mousemove",Ut),Ge(pt.scroller,"dragstart",Wt),Ge(pt.scroller,"drop",At),Gs(it),setTimeout(function(){return pt.input.focus()},20)}function qg(it,st,ct){if(ct=="char")return new Bi(st,st);if(ct=="word")return it.findWordAt(st);if(ct=="line")return new Bi(Ae(st.line,0),Qn(it.doc,Ae(st.line+1,0)));var ht=ct(it,st);return new Bi(ht.from,ht.to)}function ev(it,st,ct,ht){var pt=it.display,Mt=it.doc;mi(st);var At,Ut,Wt=Mt.sel,de=Wt.ranges;if(ht.addNew&&!ht.extend?(Ut=Mt.sel.contains(ct),Ut>-1?At=de[Ut]:At=new Bi(ct,ct)):(At=Mt.sel.primary(),Ut=Mt.sel.primIndex),ht.unit=="rectangle")ht.addNew||(At=new Bi(ct,ct)),ct=Ja(it,st,!0,!0),Ut=-1;else{var Ke=qg(it,ct,ht.unit);ht.extend?At=Gu(At,Ke.anchor,Ke.head,ht.extend):At=Ke}ht.addNew?Ut==-1?(Ut=de.length,rs(Mt,ir(it,de.concat([At]),Ut),{scroll:!1,origin:"*mouse"})):de.length>1&&de[Ut].empty()&&ht.unit=="char"&&!ht.extend?(rs(Mt,ir(it,de.slice(0,Ut).concat(de.slice(Ut+1)),0),{scroll:!1,origin:"*mouse"}),Wt=Mt.sel):ns(Mt,Ut,At,Ze):(Ut=0,rs(Mt,new jo([At],0),Ze),Wt=Mt.sel);var xe=ct;function Sn(Ji){if(en(xe,Ji)!=0)if(xe=Ji,ht.unit=="rectangle"){for(var Lo=[],or=it.options.tabSize,Xi=se(Je(Mt,ct.line).text,ct.ch,or),yr=se(Je(Mt,Ji.line).text,Ji.ch,or),Zs=Math.min(Xi,yr),Oa=Math.max(Xi,yr),ta=Math.min(ct.line,Ji.line),Gl=Math.min(it.lastLine(),Math.max(ct.line,Ji.line));ta<=Gl;ta++){var dl=Je(Mt,ta).text,ba=zn(dl,Zs,or);Zs==Oa?Lo.push(new Bi(Ae(ta,ba),Ae(ta,ba))):dl.length>ba&&Lo.push(new Bi(Ae(ta,ba),Ae(ta,zn(dl,Oa,or))))}Lo.length||Lo.push(new Bi(ct,ct)),rs(Mt,ir(it,Wt.ranges.slice(0,Ut).concat(Lo),Ut),{origin:"*mouse",scroll:!1}),it.scrollIntoView(Ji)}else{var tu=At,tl=qg(it,Ji,ht.unit),La=tu.anchor,_r;en(tl.anchor,La)>0?(_r=tl.head,La=Zn(tu.from(),tl.anchor)):(_r=tl.anchor,La=Si(tu.to(),tl.head));var sa=Wt.ranges.slice(0);sa[Ut]=sm(it,new Bi(Qn(Mt,La),_r)),rs(Mt,ir(it,sa,Ut),Ze)}}var hn=pt.wrapper.getBoundingClientRect(),_n=0;function ai(Ji){var Lo=++_n,or=Ja(it,Ji,!0,ht.unit=="rectangle");if(or)if(en(or,xe)!=0){it.curOp.focus=me(),Sn(or);var Xi=br(pt,Mt);(or.line>=Xi.to||or.linehn.bottom?20:0;yr&&setTimeout(dn(it,function(){_n==Lo&&(pt.scroller.scrollTop+=yr,ai(Ji))}),50)}}function vi(Ji){it.state.selectingText=!1,_n=1/0,Ji&&(mi(Ji),pt.input.focus()),wn(pt.wrapper.ownerDocument,"mousemove",Di),wn(pt.wrapper.ownerDocument,"mouseup",uo),Mt.history.lastSelOrigin=null}var Di=dn(it,function(Ji){Ji.buttons===0||!Ao(Ji)?vi(Ji):ai(Ji)}),uo=dn(it,vi);it.state.selectingText=uo,Ge(pt.wrapper.ownerDocument,"mousemove",Di),Ge(pt.wrapper.ownerDocument,"mouseup",uo)}function sm(it,st){var ct=st.anchor,ht=st.head,pt=Je(it.doc,ct.line);if(en(ct,ht)==0&&ct.sticky==ht.sticky)return st;var Mt=nn(pt);if(!Mt)return st;var At=le(Mt,ct.ch,ct.sticky),Ut=Mt[At];if(Ut.from!=ct.ch&&Ut.to!=ct.ch)return st;var Wt=At+(Ut.from==ct.ch==(Ut.level!=1)?0:1);if(Wt==0||Wt==Mt.length)return st;var de;if(ht.line!=ct.line)de=(ht.line-ct.line)*(it.doc.direction=="ltr"?1:-1)>0;else{var Ke=le(Mt,ht.ch,ht.sticky),xe=Ke-At||(ht.ch-ct.ch)*(Ut.level==1?-1:1);Ke==Wt-1||Ke==Wt?de=xe<0:de=xe>0}var Sn=Mt[Wt+(de?-1:0)],hn=de==(Sn.level==1),_n=hn?Sn.from:Sn.to,ai=hn?"after":"before";return ct.ch==_n&&ct.sticky==ai?st:new Bi(new Ae(ct.line,_n,ai),ht)}function Qf(it,st,ct,ht){var pt,Mt;if(st.touches)pt=st.touches[0].clientX,Mt=st.touches[0].clientY;else try{pt=st.clientX,Mt=st.clientY}catch(Sn){return!1}if(pt>=Math.floor(it.display.gutters.getBoundingClientRect().right))return!1;ht&&mi(st);var At=it.display,Ut=At.lineDiv.getBoundingClientRect();if(Mt>Ut.bottom||!Un(it,ct))return Mi(st);Mt-=Ut.top-At.viewOffset;for(var Wt=0;Wt=pt){var Ke=vn(it.doc,Mt),xe=it.display.gutterSpecs[Wt];return pn(it,ct,it,Ke,xe.className,st),Mi(st)}}}function qf(it,st){return Qf(it,st,"gutterClick",!0)}function tg(it,st){_a(it.display,st)||am(it,st)||Yn(it,st,"contextmenu")||kt||it.display.input.onContextMenu(st)}function am(it,st){return Un(it,"gutterContextMenu")?Qf(it,st,"gutterContextMenu",!1):!1}function eg(it){it.display.wrapper.className=it.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+it.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Is(it)}var yd={toString:function(){return"CodeMirror.Init"}},tp={},gf={};function lm(it){var st=it.optionHandlers;function ct(ht,pt,Mt,At){it.defaults[ht]=pt,Mt&&(st[ht]=At?function(Ut,Wt,de){de!=yd&&Mt(Ut,Wt,de)}:Mt)}it.defineOption=ct,it.Init=yd,ct("value","",function(ht,pt){return ht.setValue(pt)},!0),ct("mode",null,function(ht,pt){ht.doc.modeOption=pt,Eo(ht)},!0),ct("indentUnit",2,Eo,!0),ct("indentWithTabs",!1),ct("smartIndent",!0),ct("tabSize",4,function(ht){Fr(ht),Is(ht),ls(ht)},!0),ct("lineSeparator",null,function(ht,pt){if(ht.doc.lineSep=pt,!!pt){var Mt=[],At=ht.doc.first;ht.doc.iter(function(Wt){for(var de=0;;){var Ke=Wt.text.indexOf(pt,de);if(Ke==-1)break;de=Ke+pt.length,Mt.push(Ae(At,Ke))}At++});for(var Ut=Mt.length-1;Ut>=0;Ut--)$u(ht.doc,pt,Mt[Ut],Ae(Mt[Ut].line,Mt[Ut].ch+pt.length))}}),ct("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200c\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,function(ht,pt,Mt){ht.state.specialChars=new RegExp(pt.source+(pt.test(" ")?"":"| "),"g"),Mt!=yd&&ht.refresh()}),ct("specialCharPlaceholder",Ws,function(ht){return ht.refresh()},!0),ct("electricChars",!0),ct("inputStyle",nt?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),ct("spellcheck",!1,function(ht,pt){return ht.getInputField().spellcheck=pt},!0),ct("autocorrect",!1,function(ht,pt){return ht.getInputField().autocorrect=pt},!0),ct("autocapitalize",!1,function(ht,pt){return ht.getInputField().autocapitalize=pt},!0),ct("rtlMoveVisually",!gt),ct("wholeLineUpdateBefore",!0),ct("theme","default",function(ht){eg(ht),ji(ht)},!0),ct("keyMap","default",function(ht,pt,Mt){var At=bh(pt),Ut=Mt!=yd&&bh(Mt);Ut&&Ut.detach&&Ut.detach(ht,At),At.attach&&At.attach(ht,Ut||null)}),ct("extraKeys",null),ct("configureMouse",null),ct("lineWrapping",!1,um,!0),ct("gutters",[],function(ht,pt){ht.display.gutterSpecs=mo(pt,ht.options.lineNumbers),ji(ht)},!0),ct("fixedGutter",!0,function(ht,pt){ht.display.gutters.style.left=pt?fd(ht.display)+"px":"0",ht.refresh()},!0),ct("coverGutterNextToScrollbar",!1,function(ht){return xh(ht)},!0),ct("scrollbarStyle","native",function(ht){lf(ht),xh(ht),ht.display.scrollbars.setScrollTop(ht.doc.scrollTop),ht.display.scrollbars.setScrollLeft(ht.doc.scrollLeft)},!0),ct("lineNumbers",!1,function(ht,pt){ht.display.gutterSpecs=mo(ht.options.gutters,pt),ji(ht)},!0),ct("firstLineNumber",1,ji,!0),ct("lineNumberFormatter",function(ht){return ht},ji,!0),ct("showCursorWhenSelecting",!1,ma,!0),ct("resetSelectionOnContextMenu",!0),ct("lineWiseCopyCut",!0),ct("pasteLinesPerSelection",!0),ct("selectionsMayTouch",!1),ct("readOnly",!1,function(ht,pt){pt=="nocursor"&&(Vh(ht),ht.display.input.blur()),ht.display.input.readOnlyChanged(pt)}),ct("screenReaderLabel",null,function(ht,pt){pt=pt===""?null:pt,ht.display.input.screenReaderLabelChanged(pt)}),ct("disableInput",!1,function(ht,pt){pt||ht.display.input.reset()},!0),ct("dragDrop",!0,ng),ct("allowDropFileTypes",null),ct("cursorBlinkRate",530),ct("cursorScrollMargin",0),ct("cursorHeight",1,ma,!0),ct("singleCursorHeightPerLine",!0,ma,!0),ct("workTime",100),ct("workDelay",100),ct("flattenSpans",!0,Fr,!0),ct("addModeClass",!1,Fr,!0),ct("pollInterval",100),ct("undoDepth",200,function(ht,pt){return ht.doc.history.undoDepth=pt}),ct("historyEventDelay",1250),ct("viewportMargin",10,function(ht){return ht.refresh()},!0),ct("maxHighlightLength",1e4,Fr,!0),ct("moveInputWithCursor",!0,function(ht,pt){pt||ht.display.input.resetPosition()}),ct("tabindex",null,function(ht,pt){return ht.display.input.getField().tabIndex=pt||""}),ct("autofocus",null),ct("direction","ltr",function(ht,pt){return ht.doc.setDirection(pt)},!0),ct("phrases",null)}function ng(it,st,ct){var ht=ct&&ct!=yd;if(!st!=!ht){var pt=it.display.dragFunctions,Mt=st?Ge:wn;Mt(it.display.scroller,"dragstart",pt.start),Mt(it.display.scroller,"dragenter",pt.enter),Mt(it.display.scroller,"dragover",pt.over),Mt(it.display.scroller,"dragleave",pt.leave),Mt(it.display.scroller,"drop",pt.drop)}}function um(it){it.options.lineWrapping?(Xe(it.display.wrapper,"CodeMirror-wrap"),it.display.sizer.style.minWidth="",it.display.sizerWidth=null):(Dt(it.display.wrapper,"CodeMirror-wrap"),Ir(it)),No(it),ls(it),Is(it),setTimeout(function(){return xh(it)},100)}function Yr(it,st){var ct=this;if(!(this instanceof Yr))return new Yr(it,st);this.options=st=st?Ue(st):{},Ue(tp,st,!1);var ht=st.value;typeof ht=="string"?ht=new wa(ht,st.mode,null,st.lineSeparator,st.direction):st.mode&&(ht.modeOption=st.mode),this.doc=ht;var pt=new Yr.inputStyles[st.inputStyle](this),Mt=this.display=new oo(it,ht,pt,st);Mt.wrapper.CodeMirror=this,eg(this),st.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),lf(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 jt,keySeq:null,specialChars:null},st.autofocus&&!nt&&Mt.input.focus(),Vt&&qt<11&&setTimeout(function(){return ct.display.input.reset(!0)},20),Ac(this),zl(),al(this),this.curOp.forceUpdate=!0,Ho(this,ht),st.autofocus&&!nt||this.hasFocus()?setTimeout(function(){ct.hasFocus()&&!ct.state.focused&&Br(ct)},20):Vh(this);for(var At in gf)gf.hasOwnProperty(At)&&gf[At](this,st[At],yd);Ii(this),st.finishInit&&st.finishInit(this);for(var Ut=0;Ut<_d.length;++Ut)_d[Ut](this);Ph(this),Nt&&st.lineWrapping&&getComputedStyle(Mt.lineDiv).textRendering=="optimizelegibility"&&(Mt.lineDiv.style.textRendering="auto")}Yr.defaults=tp,Yr.optionHandlers=gf;function Ac(it){var st=it.display;Ge(st.scroller,"mousedown",dn(it,sh)),Vt&&qt<11?Ge(st.scroller,"dblclick",dn(it,function(Wt){if(!Yn(it,Wt)){var de=Ja(it,Wt);if(!(!de||qf(it,Wt)||_a(it.display,Wt))){mi(Wt);var Ke=it.findWordAt(de);Kr(it.doc,Ke.anchor,Ke.head)}}})):Ge(st.scroller,"dblclick",function(Wt){return Yn(it,Wt)||mi(Wt)}),Ge(st.scroller,"contextmenu",function(Wt){return tg(it,Wt)}),Ge(st.input.getField(),"contextmenu",function(Wt){st.scroller.contains(Wt.target)||tg(it,Wt)});var ct,ht={end:0};function pt(){st.activeTouch&&(ct=setTimeout(function(){return st.activeTouch=null},1e3),ht=st.activeTouch,ht.end=+new Date)}function Mt(Wt){if(Wt.touches.length!=1)return!1;var de=Wt.touches[0];return de.radiusX<=1&&de.radiusY<=1}function At(Wt,de){if(de.left==null)return!0;var Ke=de.left-Wt.left,xe=de.top-Wt.top;return Ke*Ke+xe*xe>20*20}Ge(st.scroller,"touchstart",function(Wt){if(!Yn(it,Wt)&&!Mt(Wt)&&!qf(it,Wt)){st.input.ensurePolled(),clearTimeout(ct);var de=+new Date;st.activeTouch={start:de,moved:!1,prev:de-ht.end<=300?ht:null},Wt.touches.length==1&&(st.activeTouch.left=Wt.touches[0].pageX,st.activeTouch.top=Wt.touches[0].pageY)}}),Ge(st.scroller,"touchmove",function(){st.activeTouch&&(st.activeTouch.moved=!0)}),Ge(st.scroller,"touchend",function(Wt){var de=st.activeTouch;if(de&&!_a(st,Wt)&&de.left!=null&&!de.moved&&new Date-de.start<300){var Ke=it.coordsChar(st.activeTouch,"page"),xe;!de.prev||At(de,de.prev)?xe=new Bi(Ke,Ke):!de.prev.prev||At(de,de.prev.prev)?xe=it.findWordAt(Ke):xe=new Bi(Ae(Ke.line,0),Qn(it.doc,Ae(Ke.line+1,0))),it.setSelection(xe.anchor,xe.head),it.focus(),mi(Wt)}pt()}),Ge(st.scroller,"touchcancel",pt),Ge(st.scroller,"scroll",function(){st.scroller.clientHeight&&(Yh(it,st.scroller.scrollTop),Hu(it,st.scroller.scrollLeft,!0),pn(it,"scroll",it))}),Ge(st.scroller,"mousewheel",function(Wt){return zo(it,Wt)}),Ge(st.scroller,"DOMMouseScroll",function(Wt){return zo(it,Wt)}),Ge(st.wrapper,"scroll",function(){return st.wrapper.scrollTop=st.wrapper.scrollLeft=0}),st.dragFunctions={enter:function(Wt){Yn(it,Wt)||eo(Wt)},over:function(Wt){Yn(it,Wt)||(df(it,Wt),eo(Wt))},start:function(Wt){return Vd(it,Wt)},drop:dn(it,Ec),leave:function(Wt){Yn(it,Wt)||Uf(it)}};var Ut=st.input.getField();Ge(Ut,"keyup",function(Wt){return Yg.call(it,Wt)}),Ge(Ut,"keydown",dn(it,Vg)),Ge(Ut,"keypress",dn(it,rh)),Ge(Ut,"focus",function(Wt){return Br(it,Wt)}),Ge(Ut,"blur",function(Wt){return Vh(it,Wt)})}var _d=[];Yr.defineInitHook=function(it){return _d.push(it)};function Ta(it,st,ct,ht){var pt=it.doc,Mt;ct==null&&(ct="add"),ct=="smart"&&(pt.mode.indent?Mt=io(it,st).state:ct="prev");var At=it.options.tabSize,Ut=Je(pt,st),Wt=se(Ut.text,null,At);Ut.stateAfter&&(Ut.stateAfter=null);var de=Ut.text.match(/^\s*/)[0],Ke;if(!ht&&!/\S/.test(Ut.text))Ke=0,ct="not";else if(ct=="smart"&&(Ke=pt.mode.indent(Mt,Ut.text.slice(de.length),Ut.text),Ke==En||Ke>150)){if(!ht)return;ct="prev"}ct=="prev"?st>pt.first?Ke=se(Je(pt,st-1).text,null,At):Ke=0:ct=="add"?Ke=Wt+it.options.indentUnit:ct=="subtract"?Ke=Wt-it.options.indentUnit:typeof ct=="number"&&(Ke=Wt+ct),Ke=Math.max(0,Ke);var xe="",Sn=0;if(it.options.indentWithTabs)for(var hn=Math.floor(Ke/At);hn;--hn)Sn+=At,xe+=" ";if(SnAt,Wt=wi(st),de=null;if(Ut&&ht.ranges.length>1)if(Hl&&Hl.text.join(` `)==st){if(ht.ranges.length%Hl.text.length==0){de=[];for(var Ke=0;Ke=0;Sn--){var hn=ht.ranges[Sn],_n=hn.from(),ai=hn.to();hn.empty()&&(ct&&ct>0?_n=Ae(_n.line,_n.ch-ct):it.state.overwrite&&!Ut?ai=Ae(ai.line,Math.min(Je(Mt,ai.line).text.length,ai.ch+we(Wt).length)):Ut&&Hl&&Hl.lineWise&&Hl.text.join(` `)==Wt.join(` `)&&(_n=ai=Ae(_n.line,0)));var vi={from:_n,to:ai,text:de?de[Sn%de.length]:Wt,origin:pt||(Ut?"paste":it.state.cutIncoming>At?"cut":"+input")};As(it.doc,vi),ci(it,"inputRead",it,vi)}st&&!Ut&&np(it,st),yh(it),it.curOp.updateInput<2&&(it.curOp.updateInput=xe),it.curOp.typing=!0,it.state.pasteIncoming=it.state.cutIncoming=-1}function ep(it,st){var ct=it.clipboardData&&it.clipboardData.getData("Text");if(ct)return it.preventDefault(),!st.isReadOnly()&&!st.options.disableInput&&He(st,function(){return pf(st,ct,0,null,"paste")}),!0}function np(it,st){if(!(!it.options.electricChars||!it.options.smartIndent))for(var ct=it.doc.sel,ht=ct.ranges.length-1;ht>=0;ht--){var pt=ct.ranges[ht];if(!(pt.head.ch>100||ht&&ct.ranges[ht-1].head.line==pt.head.line)){var Mt=it.getModeAt(pt.head),At=!1;if(Mt.electricChars){for(var Ut=0;Ut-1){At=Ta(it,pt.head.line,"smart");break}}else Mt.electricInput&&Mt.electricInput.test(Je(it.doc,pt.head.line).text.slice(0,pt.head.ch))&&(At=Ta(it,pt.head.line,"smart"));At&&ci(it,"electricInput",it,pt.head.line)}}}function ip(it){for(var st=[],ct=[],ht=0;htMt&&(Ta(this,Ut.head.line,ht,!0),Mt=Ut.head.line,At==this.doc.sel.primIndex&&yh(this));else{var Wt=Ut.from(),de=Ut.to(),Ke=Math.max(Mt,Wt.line);Mt=Math.min(this.lastLine(),de.line-(de.ch?0:1))+1;for(var xe=Ke;xe0&&ns(this.doc,At,new Bi(Wt,Sn[At].to()),Ne)}}}),getTokenAt:function(ht,pt){return yi(this,ht,pt)},getLineTokens:function(ht,pt){return yi(this,Ae(ht),pt,!0)},getTokenTypeAt:function(ht){ht=Qn(this.doc,ht);var pt=Vo(this,Je(this.doc,ht.line)),Mt=0,At=(pt.length-1)/2,Ut=ht.ch,Wt;if(Ut==0)Wt=pt[2];else for(;;){var de=Mt+At>>1;if((de?pt[de*2-1]:0)>=Ut)At=de;else if(pt[de*2+1]Wt&&(ht=Wt,At=!0),Ut=Je(this.doc,ht)}else Ut=ht;return Bs(this,Ut,{top:0,left:0},pt||"page",Mt||At).top+(At?this.doc.height-Xo(Ut):0)},defaultTextHeight:function(){return zu(this.display)},defaultCharWidth:function(){return nh(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(ht,pt,Mt,At,Ut){var Wt=this.display;ht=xs(this,Qn(this.doc,ht));var de=ht.bottom,Ke=ht.left;if(pt.style.position="absolute",pt.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(pt),Wt.sizer.appendChild(pt),At=="over")de=ht.top;else if(At=="above"||At=="near"){var xe=Math.max(Wt.wrapper.clientHeight,this.doc.height),Sn=Math.max(Wt.sizer.clientWidth,Wt.lineSpace.clientWidth);(At=="above"||ht.bottom+pt.offsetHeight>xe)&&ht.top>pt.offsetHeight?de=ht.top-pt.offsetHeight:ht.bottom+pt.offsetHeight<=xe&&(de=ht.bottom),Ke+pt.offsetWidth>Sn&&(Ke=Sn-pt.offsetWidth)}pt.style.top=de+"px",pt.style.left=pt.style.right="",Ut=="right"?(Ke=Wt.sizer.clientWidth-pt.offsetWidth,pt.style.right="0px"):(Ut=="left"?Ke=0:Ut=="middle"&&(Ke=(Wt.sizer.clientWidth-pt.offsetWidth)/2),pt.style.left=Ke+"px"),Mt&&Kd(this,{left:Ke,top:de,right:Ke+pt.offsetWidth,bottom:de+pt.offsetHeight})},triggerOnKeyDown:fn(Vg),triggerOnKeyPress:fn(rh),triggerOnKeyUp:Yg,triggerOnMouseDown:fn(sh),execCommand:function(ht){if(Na.hasOwnProperty(ht))return Na[ht].call(null,this)},triggerElectric:fn(function(ht){np(this,ht)}),findPosH:function(ht,pt,Mt,At){var Ut=1;pt<0&&(Ut=-1,pt=-pt);for(var Wt=Qn(this.doc,ht),de=0;de0&&Ke(Mt.charAt(At-1));)--At;for(;Ut.5||this.options.lineWrapping)&&No(this),pn(this,"refresh",this)}),swapDoc:fn(function(ht){var pt=this.doc;return pt.cm=null,this.state.selectingText&&this.state.selectingText(),Ho(this,ht),Is(this),this.display.input.reset(),Uh(this,ht.scrollLeft,ht.scrollTop),this.curOp.forceScroll=!0,ci(this,"swapDoc",this,pt),pt}),phrase:function(ht){var pt=this.options.phrases;return pt&&Object.prototype.hasOwnProperty.call(pt,ht)?pt[ht]:ht},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}},gi(it),it.registerHelper=function(ht,pt,Mt){ct.hasOwnProperty(ht)||(ct[ht]=it[ht]={_global:[]}),ct[ht][pt]=Mt},it.registerGlobalHelper=function(ht,pt,Mt,At){it.registerHelper(ht,pt,At),ct[ht]._global.push({pred:Mt,val:At})}}function mf(it,st,ct,ht,pt){var Mt=st,At=ct,Ut=Je(it,st.line),Wt=pt&&it.direction=="rtl"?-ct:ct;function de(){var uo=st.line+Wt;return uo=it.first+it.size?!1:(st=new Ae(uo,st.ch,st.sticky),Ut=Je(it,uo))}function Ke(uo){var Ji;if(ht=="codepoint"){var Lo=Ut.text.charCodeAt(st.ch+(ht>0?0:-1));isNaN(Lo)?Ji=null:Ji=new Ae(st.line,Math.max(0,Math.min(Ut.text.length,st.ch+ct*(Lo>=55296&&Lo<56320?2:1))),-ct)}else pt?Ji=Ss(it.cm,Ut,st,ct):Ji=ra(Ut,st,ct);if(Ji==null)if(!uo&&de())st=Zr(pt,it.cm,Ut,st.line,Wt);else return!1;else st=Ji;return!0}if(ht=="char"||ht=="codepoint")Ke();else if(ht=="column")Ke(!0);else if(ht=="word"||ht=="group")for(var xe=null,Sn=ht=="group",hn=it.cm&&it.cm.getHelper(st,"wordChars"),_n=!0;!(ct<0&&!Ke(!_n));_n=!1){var ai=Ut.text.charAt(st.ch)||` `,vi=Bt(ai,hn)?"w":Sn&&ai==` `?"n":!Sn||/\s/.test(ai)?null:"p";if(Sn&&!_n&&!vi&&(vi="s"),xe&&xe!=vi){ct<0&&(ct=1,Ke(),st.sticky="after");break}if(vi&&(xe=vi),ct>0&&!Ke(!_n))break}var Di=_l(it,st,Mt,At,!0);return ui(Mt,Di)&&(Di.hitSide=!0),Di}function xd(it,st,ct,ht){var pt=it.doc,Mt=st.left,At;if(ht=="page"){var Ut=Math.min(it.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),Wt=Math.max(Ut-.5*zu(it.display),3);At=(ct>0?st.bottom:st.top)+ct*Wt}else ht=="line"&&(At=ct>0?st.bottom+3:st.top-3);for(var de;de=Kh(it,Mt,At),!!de.outside;){if(ct<0?At<=0:At>=pt.height){de.hitSide=!0;break}At+=ct*5}return de}var bs=function(it){this.cm=it,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new jt,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};bs.prototype.init=function(it){var st=this,ct=this,ht=ct.cm,pt=ct.div=it.lineDiv;op(pt,ht.options.spellcheck,ht.options.autocorrect,ht.options.autocapitalize);function Mt(Ut){for(var Wt=Ut.target;Wt;Wt=Wt.parentNode){if(Wt==pt)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(Wt.className))break}return!1}Ge(pt,"paste",function(Ut){!Mt(Ut)||Yn(ht,Ut)||ep(Ut,ht)||qt<=11&&setTimeout(dn(ht,function(){return st.updateFromDOM()}),20)}),Ge(pt,"compositionstart",function(Ut){st.composing={data:Ut.data,done:!1}}),Ge(pt,"compositionupdate",function(Ut){st.composing||(st.composing={data:Ut.data,done:!1})}),Ge(pt,"compositionend",function(Ut){st.composing&&(Ut.data!=st.composing.data&&st.readFromDOMSoon(),st.composing.done=!0)}),Ge(pt,"touchstart",function(){return ct.forceCompositionEnd()}),Ge(pt,"input",function(){st.composing||st.readFromDOMSoon()});function At(Ut){if(!(!Mt(Ut)||Yn(ht,Ut))){if(ht.somethingSelected())Jd({lineWise:!1,text:ht.getSelections()}),Ut.type=="cut"&&ht.replaceSelection("",null,"cut");else if(ht.options.lineWiseCopyCut){var Wt=ip(ht);Jd({lineWise:!0,text:Wt.text}),Ut.type=="cut"&&ht.operation(function(){ht.setSelections(Wt.ranges,0,Ne),ht.replaceSelection("",null,"cut")})}else return;if(Ut.clipboardData){Ut.clipboardData.clearData();var de=Hl.text.join(` `);if(Ut.clipboardData.setData("Text",de),Ut.clipboardData.getData("Text")==de){Ut.preventDefault();return}}var Ke=rp(),xe=Ke.firstChild;ht.display.lineSpace.insertBefore(Ke,ht.display.lineSpace.firstChild),xe.value=Hl.text.join(` `);var Sn=document.activeElement;Ie(xe),setTimeout(function(){ht.display.lineSpace.removeChild(Ke),Sn.focus(),Sn==pt&&ct.showPrimarySelection()},50)}}Ge(pt,"copy",At),Ge(pt,"cut",At)},bs.prototype.screenReaderLabelChanged=function(it){it?this.div.setAttribute("aria-label",it):this.div.removeAttribute("aria-label")},bs.prototype.prepareSelection=function(){var it=Zh(this.cm,!1);return it.focus=document.activeElement==this.div,it},bs.prototype.showSelection=function(it,st){!it||!this.cm.display.view.length||((it.focus||st)&&this.showPrimarySelection(),this.showMultipleSelections(it))},bs.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},bs.prototype.showPrimarySelection=function(){var it=this.getSelection(),st=this.cm,ct=st.doc.sel.primary(),ht=ct.from(),pt=ct.to();if(st.display.viewTo==st.display.viewFrom||ht.line>=st.display.viewTo||pt.line=st.display.viewFrom&&ig(st,ht)||{node:Ut[0].measure.map[2],offset:0},de=pt.lineit.firstLine()&&(ht=Ae(ht.line-1,Je(it.doc,ht.line-1).length)),pt.ch==Je(it.doc,pt.line).text.length&&pt.linest.viewTo-1)return!1;var Mt,At,Ut;ht.line==st.viewFrom||(Mt=Aa(it,ht.line))==0?(At=ce(st.view[0].line),Ut=st.view[0].node):(At=ce(st.view[Mt].line),Ut=st.view[Mt-1].node.nextSibling);var Wt=Aa(it,pt.line),de,Ke;if(Wt==st.view.length-1?(de=st.viewTo-1,Ke=st.lineDiv.lastChild):(de=ce(st.view[Wt+1].line)-1,Ke=st.view[Wt+1].node.previousSibling),!Ut)return!1;for(var xe=it.doc.splitLines(zc(it,Ut,Ke,At,de)),Sn=gn(it.doc,Ae(At,0),Ae(de,Je(it.doc,de).text.length));xe.length>1&&Sn.length>1;)if(we(xe)==we(Sn))xe.pop(),Sn.pop(),de--;else if(xe[0]==Sn[0])xe.shift(),Sn.shift(),At++;else break;for(var hn=0,_n=0,ai=xe[0],vi=Sn[0],Di=Math.min(ai.length,vi.length);hnht.ch&&uo.charCodeAt(uo.length-_n-1)==Ji.charCodeAt(Ji.length-_n-1);)hn--,_n++;xe[xe.length-1]=uo.slice(0,uo.length-_n).replace(/^\u200b+/,""),xe[0]=xe[0].slice(hn).replace(/\u200b+$/,"");var or=Ae(At,hn),Xi=Ae(de,Sn.length?we(Sn).length-_n:0);if(xe.length>1||xe[0]||en(or,Xi))return $u(it.doc,xe,or,Xi,"+input"),!0},bs.prototype.ensurePolled=function(){this.forceCompositionEnd()},bs.prototype.reset=function(){this.forceCompositionEnd()},bs.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},bs.prototype.readFromDOMSoon=function(){var it=this;this.readDOMTimeout==null&&(this.readDOMTimeout=setTimeout(function(){if(it.readDOMTimeout=null,it.composing)if(it.composing.done)it.composing=null;else return;it.updateFromDOM()},80))},bs.prototype.updateFromDOM=function(){var it=this;(this.cm.isReadOnly()||!this.pollContent())&&He(this.cm,function(){return ls(it.cm)})},bs.prototype.setUneditable=function(it){it.contentEditable="false"},bs.prototype.onKeyPress=function(it){it.charCode==0||this.composing||(it.preventDefault(),this.cm.isReadOnly()||dn(this.cm,pf)(this.cm,String.fromCharCode(it.charCode==null?it.keyCode:it.charCode),0))},bs.prototype.readOnlyChanged=function(it){this.div.contentEditable=String(it!="nocursor")},bs.prototype.onContextMenu=function(){},bs.prototype.resetPosition=function(){},bs.prototype.needsContentAttribute=!0;function ig(it,st){var ct=mh(it,st.line);if(!ct||ct.hidden)return null;var ht=Je(it.doc,st.line),pt=Gh(ct,ht,st.line),Mt=nn(ht,it.doc.direction),At="left";if(Mt){var Ut=le(Mt,st.ch);At=Ut%2?"right":"left"}var Wt=Wh(pt.map,st.ch,At);return Wt.offset=Wt.collapse=="right"?Wt.end:Wt.start,Wt}function sp(it){for(var st=it;st;st=st.parentNode)if(/CodeMirror-gutter-wrapper/.test(st.className))return!0;return!1}function Rc(it,st){return st&&(it.bad=!0),it}function zc(it,st,ct,ht,pt){var Mt="",At=!1,Ut=it.doc.lineSeparator(),Wt=!1;function de(hn){return function(_n){return _n.id==hn}}function Ke(){At&&(Mt+=Ut,Wt&&(Mt+=Ut),At=Wt=!1)}function xe(hn){hn&&(Ke(),Mt+=hn)}function Sn(hn){if(hn.nodeType==1){var _n=hn.getAttribute("cm-text");if(_n){xe(_n);return}var ai=hn.getAttribute("cm-marker"),vi;if(ai){var Di=it.findMarks(Ae(ht,0),Ae(pt+1,0),de(+ai));Di.length&&(vi=Di[0].find(0))&&xe(gn(it.doc,vi.from,vi.to).join(Ut));return}if(hn.getAttribute("contenteditable")=="false")return;var uo=/^(pre|div|p|li|table|br)$/i.test(hn.nodeName);if(!/^br$/i.test(hn.nodeName)&&hn.textContent.length==0)return;uo&&Ke();for(var Ji=0;Ji=9&&st.hasSelection&&(st.hasSelection=null),ct.poll()}),Ge(pt,"paste",function(At){Yn(ht,At)||ep(At,ht)||(ht.state.pasteIncoming=+new Date,ct.fastPoll())});function Mt(At){if(!Yn(ht,At)){if(ht.somethingSelected())Jd({lineWise:!1,text:ht.getSelections()});else if(ht.options.lineWiseCopyCut){var Ut=ip(ht);Jd({lineWise:!0,text:Ut.text}),At.type=="cut"?ht.setSelections(Ut.ranges,null,Ne):(ct.prevInput="",pt.value=Ut.text.join(` `),Ie(pt))}else return;At.type=="cut"&&(ht.state.cutIncoming=+new Date)}}Ge(pt,"cut",Mt),Ge(pt,"copy",Mt),Ge(it.scroller,"paste",function(At){if(!(_a(it,At)||Yn(ht,At))){if(!pt.dispatchEvent){ht.state.pasteIncoming=+new Date,ct.focus();return}var Ut=new Event("paste");Ut.clipboardData=At.clipboardData,pt.dispatchEvent(Ut)}}),Ge(it.lineSpace,"selectstart",function(At){_a(it,At)||mi(At)}),Ge(pt,"compositionstart",function(){var At=ht.getCursor("from");ct.composing&&ct.composing.range.clear(),ct.composing={start:At,range:ht.markText(At,ht.getCursor("to"),{className:"CodeMirror-composing"})}}),Ge(pt,"compositionend",function(){ct.composing&&(ct.poll(),ct.composing.range.clear(),ct.composing=null)})},Ca.prototype.createField=function(it){this.wrapper=rp(),this.textarea=this.wrapper.firstChild},Ca.prototype.screenReaderLabelChanged=function(it){it?this.textarea.setAttribute("aria-label",it):this.textarea.removeAttribute("aria-label")},Ca.prototype.prepareSelection=function(){var it=this.cm,st=it.display,ct=it.doc,ht=Zh(it);if(it.options.moveInputWithCursor){var pt=xs(it,ct.sel.primary().head,"div"),Mt=st.wrapper.getBoundingClientRect(),At=st.lineDiv.getBoundingClientRect();ht.teTop=Math.max(0,Math.min(st.wrapper.clientHeight-10,pt.top+At.top-Mt.top)),ht.teLeft=Math.max(0,Math.min(st.wrapper.clientWidth-10,pt.left+At.left-Mt.left))}return ht},Ca.prototype.showSelection=function(it){var st=this.cm,ct=st.display;ie(ct.cursorDiv,it.cursors),ie(ct.selectionDiv,it.selection),it.teTop!=null&&(this.wrapper.style.top=it.teTop+"px",this.wrapper.style.left=it.teLeft+"px")},Ca.prototype.reset=function(it){if(!(this.contextMenuPending||this.composing)){var st=this.cm;if(st.somethingSelected()){this.prevInput="";var ct=st.getSelection();this.textarea.value=ct,st.state.focused&&Ie(this.textarea),Vt&&qt>=9&&(this.hasSelection=ct)}else it||(this.prevInput=this.textarea.value="",Vt&&qt>=9&&(this.hasSelection=null))}},Ca.prototype.getField=function(){return this.textarea},Ca.prototype.supportsTouch=function(){return!1},Ca.prototype.focus=function(){if(this.cm.options.readOnly!="nocursor"&&(!nt||me()!=this.textarea))try{this.textarea.focus()}catch(it){}},Ca.prototype.blur=function(){this.textarea.blur()},Ca.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Ca.prototype.receivedFocus=function(){this.slowPoll()},Ca.prototype.slowPoll=function(){var it=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){it.poll(),it.cm.state.focused&&it.slowPoll()})},Ca.prototype.fastPoll=function(){var it=!1,st=this;st.pollingFast=!0;function ct(){var ht=st.poll();!ht&&!it?(it=!0,st.polling.set(60,ct)):(st.pollingFast=!1,st.slowPoll())}st.polling.set(20,ct)},Ca.prototype.poll=function(){var it=this,st=this.cm,ct=this.textarea,ht=this.prevInput;if(this.contextMenuPending||!st.state.focused||bt(ct)&&!ht&&!this.composing||st.isReadOnly()||st.options.disableInput||st.state.keySeq)return!1;var pt=ct.value;if(pt==ht&&!st.somethingSelected())return!1;if(Vt&&qt>=9&&this.hasSelection===pt||dt&&/[\uf700-\uf7ff]/.test(pt))return st.display.input.reset(),!1;if(st.doc.sel==st.display.selForContextMenu){var Mt=pt.charCodeAt(0);if(Mt==8203&&!ht&&(ht="\u200B"),Mt==8666)return this.reset(),this.cm.execCommand("undo")}for(var At=0,Ut=Math.min(ht.length,pt.length);At1e3||pt.indexOf(` `)>-1?ct.value=it.prevInput="":it.prevInput=pt,it.composing&&(it.composing.range.clear(),it.composing.range=st.markText(it.composing.start,st.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},Ca.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Ca.prototype.onKeyPress=function(){Vt&&qt>=9&&(this.hasSelection=null),this.fastPoll()},Ca.prototype.onContextMenu=function(it){var st=this,ct=st.cm,ht=ct.display,pt=st.textarea;st.contextMenuPending&&st.contextMenuPending();var Mt=Ja(ct,it),At=ht.scroller.scrollTop;if(!Mt||Qt)return;var Ut=ct.options.resetSelectionOnContextMenu;Ut&&ct.doc.sel.contains(Mt)==-1&&dn(ct,rs)(ct.doc,ur(Mt),Ne);var Wt=pt.style.cssText,de=st.wrapper.style.cssText,Ke=st.wrapper.offsetParent.getBoundingClientRect();st.wrapper.style.cssText="position: static",pt.style.cssText=`position: absolute; width: 30px; height: 30px; top: `+(it.clientY-Ke.top-5)+"px; left: "+(it.clientX-Ke.left-5)+`px; z-index: 1000; background: `+(Vt?"rgba(255, 255, 255, .05)":"transparent")+`; outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);`;var xe;Nt&&(xe=window.scrollY),ht.input.focus(),Nt&&window.scrollTo(null,xe),ht.input.reset(),ct.somethingSelected()||(pt.value=st.prevInput=" "),st.contextMenuPending=hn,ht.selForContextMenu=ct.doc.sel,clearTimeout(ht.detectingSelectAll);function Sn(){if(pt.selectionStart!=null){var ai=ct.somethingSelected(),vi="\u200B"+(ai?pt.value:"");pt.value="\u21DA",pt.value=vi,st.prevInput=ai?"":"\u200B",pt.selectionStart=1,pt.selectionEnd=vi.length,ht.selForContextMenu=ct.doc.sel}}function hn(){if(st.contextMenuPending==hn&&(st.contextMenuPending=!1,st.wrapper.style.cssText=de,pt.style.cssText=Wt,Vt&&qt<9&&ht.scrollbars.setScrollTop(ht.scroller.scrollTop=At),pt.selectionStart!=null)){(!Vt||Vt&&qt<9)&&Sn();var ai=0,vi=function(){ht.selForContextMenu==ct.doc.sel&&pt.selectionStart==0&&pt.selectionEnd>0&&st.prevInput=="\u200B"?dn(ct,Ur)(ct):ai++<10?ht.detectingSelectAll=setTimeout(vi,500):(ht.selForContextMenu=null,ht.input.reset())};ht.detectingSelectAll=setTimeout(vi,200)}}if(Vt&&qt>=9&&Sn(),kt){eo(it);var _n=function(){wn(window,"mouseup",_n),setTimeout(hn,20)};Ge(window,"mouseup",_n)}else setTimeout(hn,50)},Ca.prototype.readOnlyChanged=function(it){it||this.reset(),this.textarea.disabled=it=="nocursor",this.textarea.readOnly=!!it},Ca.prototype.setUneditable=function(){},Ca.prototype.needsContentAttribute=!1;function dm(it,st){if(st=st?Ue(st):{},st.value=it.value,!st.tabindex&&it.tabIndex&&(st.tabindex=it.tabIndex),!st.placeholder&&it.placeholder&&(st.placeholder=it.placeholder),st.autofocus==null){var ct=me();st.autofocus=ct==it||it.getAttribute("autofocus")!=null&&ct==document.body}function ht(){it.value=Ut.getValue()}var pt;if(it.form&&(Ge(it.form,"submit",ht),!st.leaveSubmitMethodAlone)){var Mt=it.form;pt=Mt.submit;try{var At=Mt.submit=function(){ht(),Mt.submit=pt,Mt.submit(),Mt.submit=At}}catch(Wt){}}st.finishInit=function(Wt){Wt.save=ht,Wt.getTextArea=function(){return it},Wt.toTextArea=function(){Wt.toTextArea=isNaN,ht(),it.parentNode.removeChild(Wt.getWrapperElement()),it.style.display="",it.form&&(wn(it.form,"submit",ht),!st.leaveSubmitMethodAlone&&typeof it.form.submit=="function"&&(it.form.submit=pt))}},it.style.display="none";var Ut=Yr(function(Wt){return it.parentNode.insertBefore(Wt,it.nextSibling)},st);return Ut}function jc(it){it.off=wn,it.on=Ge,it.wheelEventPixels=bo,it.Doc=wa,it.splitLines=wi,it.countColumn=se,it.findColumn=zn,it.isWordChar=Et,it.Pass=En,it.signal=pn,it.Line=Vr,it.changeEnd=$r,it.scrollbarModel=af,it.Pos=Ae,it.cmpPos=en,it.modes=pr,it.mimeModes=ar,it.resolveMode=nr,it.getMode=_e,it.modeExtensions=We,it.extendMode=Jt,it.copyState=on,it.startState=Le,it.innerMode=Mn,it.commands=Na,it.keyMap=hl,it.keyName=Fc,it.isModifierKey=vd,it.lookupKey=jl,it.normalizeKeyMap=Tc,it.StringStream=ue,it.SharedTextMarker=Wu,it.TextMarker=Be,it.LineWidget=ca,it.e_preventDefault=mi,it.e_stopPropagation=$i,it.e_stop=eo,it.addClass=Xe,it.contains=je,it.rmClass=Dt,it.keyNames=bu}lm(Yr),Sd(Yr);var Jh="iter insert remove copy getEditor constructor".split(" ");for(var yf in wa.prototype)wa.prototype.hasOwnProperty(yf)&&$e(Jh,yf)<0&&(Yr.prototype[yf]=function(it){return function(){return it.apply(this.doc,arguments)}}(wa.prototype[yf]));return gi(wa),Yr.inputStyles={textarea:Ca,contenteditable:bs},Yr.defineMode=function(it){!Yr.defaults.mode&&it!="null"&&(Yr.defaults.mode=it),sr.apply(this,arguments)},Yr.defineMIME=Fo,Yr.defineMode("null",function(){return{token:function(it){return it.skipToEnd()}}}),Yr.defineMIME("text/plain","null"),Yr.defineExtension=function(it,st){Yr.prototype[it]=st},Yr.defineDocExtension=function(it,st){wa.prototype[it]=st},Yr.fromTextArea=dm,jc(Yr),Yr.version="5.58.2",Yr})},25419:function(Cn,cn,wt){(function(Ft){Ft(wt(89780),wt(15525),wt(98101))})(function(Ft){"use strict";Ft.defineMode("markdown",function(Ht,oe){var ke=Ft.getMode(Ht,"text/html"),Vt=ke.name=="null";function qt(se){if(Ft.findModeByName){var jt=Ft.findModeByName(se);jt&&(se=jt.mime||jt.mimes[0])}var $e=Ft.getMode(Ht,se);return $e.name=="null"?null:$e}oe.highlightFormatting===void 0&&(oe.highlightFormatting=!1),oe.maxBlockquoteDepth===void 0&&(oe.maxBlockquoteDepth=0),oe.taskLists===void 0&&(oe.taskLists=!1),oe.strikethrough===void 0&&(oe.strikethrough=!1),oe.emoji===void 0&&(oe.emoji=!1),oe.fencedCodeBlockHighlighting===void 0&&(oe.fencedCodeBlockHighlighting=!0),oe.fencedCodeBlockDefaultMode===void 0&&(oe.fencedCodeBlockDefaultMode="text/plain"),oe.xml===void 0&&(oe.xml=!0),oe.tokenTypeOverrides===void 0&&(oe.tokenTypeOverrides={});var Nt={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 Oe in Nt)Nt.hasOwnProperty(Oe)&&oe.tokenTypeOverrides[Oe]&&(Nt[Oe]=oe.tokenTypeOverrides[Oe]);var be=/^([*\-_])(?:\s*\1){2,}\s*$/,Qt=/^(?:[*\-+]|^[0-9]+([.)]))\s+/,Fe=/^\[(x| )\](?=\s)/i,ye=oe.allowAtxHeaderWithoutSpace?/^(#+)/:/^(#+)(?: |$)/,Re=/^ {0,3}(?:\={1,}|-{2,})\s*$/,It=/^[^#!\[\]*_\\<>` "'(~:]+/,et=/^(~~~+|```+)[ \t]*([\w\/+#-]*)[^\n`]*$/,nt=/^\s*\[[^\]]+?\]:.*$/,dt=/[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~\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]/,at=" ";function gt(se,jt,$e){return jt.f=jt.inline=$e,$e(se,jt)}function mt(se,jt,$e){return jt.f=jt.block=$e,$e(se,jt)}function Pt(se){return!se||!/\S/.test(se.string)}function kt(se){if(se.linkTitle=!1,se.linkHref=!1,se.linkText=!1,se.em=!1,se.strong=!1,se.strikethrough=!1,se.quote=0,se.indentedCode=!1,se.f==Dt){var jt=Vt;if(!jt){var $e=Ft.innerMode(ke,se.htmlState);jt=$e.mode.name=="xml"&&$e.state.tagStart===null&&!$e.state.context&&$e.state.tokenize.isInText}jt&&(se.f=fe,se.block=Tt,se.htmlState=null)}return se.trailingSpace=0,se.trailingSpaceNewLine=!1,se.prevLine=se.thisLine,se.thisLine={stream:null},null}function Tt(se,jt){var $e=se.column()===jt.indentation,xn=Pt(jt.prevLine.stream),En=jt.indentedCode,Ne=jt.prevLine.hr,Ze=jt.list!==!1,rn=(jt.listStack[jt.listStack.length-1]||0)+3;jt.indentedCode=!1;var zn=jt.indentation;if(jt.indentationDiff===null&&(jt.indentationDiff=jt.indentation,Ze)){for(jt.list=null;zn=4&&(En||jt.prevLine.fencedCodeEnd||jt.prevLine.header||xn))return se.skipToEnd(),jt.indentedCode=!0,Nt.code;if(se.eatSpace())return null;if($e&&jt.indentation<=rn&&(we=se.match(ye))&&we[1].length<=6)return jt.quote=0,jt.header=we[1].length,jt.thisLine.header=!0,oe.highlightFormatting&&(jt.formatting="header"),jt.f=jt.inline,ie(jt);if(jt.indentation<=rn&&se.eat(">"))return jt.quote=$e?1:jt.quote+1,oe.highlightFormatting&&(jt.formatting="quote"),se.eatSpace(),ie(jt);if(!Tn&&!jt.setext&&$e&&jt.indentation<=rn&&(we=se.match(Qt))){var Bn=we[1]?"ol":"ul";return jt.indentation=zn+se.current().length,jt.list=!0,jt.quote=0,jt.listStack.push(jt.indentation),jt.em=!1,jt.strong=!1,jt.code=!1,jt.strikethrough=!1,oe.taskLists&&se.match(Fe,!1)&&(jt.taskList=!0),jt.f=jt.inline,oe.highlightFormatting&&(jt.formatting=["list","list-"+Bn]),ie(jt)}else{if($e&&jt.indentation<=rn&&(we=se.match(et,!0)))return jt.quote=0,jt.fencedEndRE=new RegExp(we[1]+"+ *$"),jt.localMode=oe.fencedCodeBlockHighlighting&&qt(we[2]||oe.fencedCodeBlockDefaultMode),jt.localMode&&(jt.localState=Ft.startState(jt.localMode)),jt.f=jt.block=$t,oe.highlightFormatting&&(jt.formatting="code-block"),jt.code=-1,ie(jt);if(jt.setext||(!tn||!Ze)&&!jt.quote&&jt.list===!1&&!jt.code&&!Tn&&!nt.test(se.string)&&(we=se.lookAhead(1))&&(we=we.match(Re)))return jt.setext?(jt.header=jt.setext,jt.setext=0,se.skipToEnd(),oe.highlightFormatting&&(jt.formatting="header")):(jt.header=we[0].charAt(0)=="="?1:2,jt.setext=jt.header),jt.thisLine.header=!0,jt.f=jt.inline,ie(jt);if(Tn)return se.skipToEnd(),jt.hr=!0,jt.thisLine.hr=!0,Nt.hr;if(se.peek()==="[")return gt(se,jt,Se)}return gt(se,jt,jt.inline)}function Dt(se,jt){var $e=ke.token(se,jt.htmlState);if(!Vt){var xn=Ft.innerMode(ke,jt.htmlState);(xn.mode.name=="xml"&&xn.state.tagStart===null&&!xn.state.context&&xn.state.tokenize.isInText||jt.md_inside&&se.current().indexOf(">")>-1)&&(jt.f=fe,jt.block=Tt,jt.htmlState=null)}return $e}function $t(se,jt){var $e=jt.listStack[jt.listStack.length-1]||0,xn=jt.indentation<$e,En=$e+3;if(jt.fencedEndRE&&jt.indentation<=En&&(xn||se.match(jt.fencedEndRE))){oe.highlightFormatting&&(jt.formatting="code-block");var Ne;return xn||(Ne=ie(jt)),jt.localMode=jt.localState=null,jt.block=Tt,jt.f=fe,jt.fencedEndRE=null,jt.code=0,jt.thisLine.fencedCodeEnd=!0,xn?mt(se,jt,jt.block):Ne}else return jt.localMode?jt.localMode.token(se,jt.localState):(se.skipToEnd(),Nt.code)}function ie(se){var jt=[];if(se.formatting){jt.push(Nt.formatting),typeof se.formatting=="string"&&(se.formatting=[se.formatting]);for(var $e=0;$e=se.quote?jt.push(Nt.formatting+"-"+se.formatting[$e]+"-"+se.quote):jt.push("error"))}if(se.taskOpen)return jt.push("meta"),jt.length?jt.join(" "):null;if(se.taskClosed)return jt.push("property"),jt.length?jt.join(" "):null;if(se.linkHref?jt.push(Nt.linkHref,"url"):(se.strong&&jt.push(Nt.strong),se.em&&jt.push(Nt.em),se.strikethrough&&jt.push(Nt.strikethrough),se.emoji&&jt.push(Nt.emoji),se.linkText&&jt.push(Nt.linkText),se.code&&jt.push(Nt.code),se.image&&jt.push(Nt.image),se.imageAltText&&jt.push(Nt.imageAltText,"link"),se.imageMarker&&jt.push(Nt.imageMarker)),se.header&&jt.push(Nt.header,Nt.header+"-"+se.header),se.quote&&(jt.push(Nt.quote),!oe.maxBlockquoteDepth||oe.maxBlockquoteDepth>=se.quote?jt.push(Nt.quote+"-"+se.quote):jt.push(Nt.quote+"-"+oe.maxBlockquoteDepth)),se.list!==!1){var xn=(se.listStack.length-1)%3;xn?xn===1?jt.push(Nt.list2):jt.push(Nt.list3):jt.push(Nt.list1)}return se.trailingSpaceNewLine?jt.push("trailing-space-new-line"):se.trailingSpace&&jt.push("trailing-space-"+(se.trailingSpace%2?"a":"b")),jt.length?jt.join(" "):null}function Yt(se,jt){if(se.match(It,!0))return ie(jt)}function fe(se,jt){var $e=jt.text(se,jt);if(typeof $e!="undefined")return $e;if(jt.list)return jt.list=null,ie(jt);if(jt.taskList){var xn=se.match(Fe,!0)[1]===" ";return xn?jt.taskOpen=!0:jt.taskClosed=!0,oe.highlightFormatting&&(jt.formatting="task"),jt.taskList=!1,ie(jt)}if(jt.taskOpen=!1,jt.taskClosed=!1,jt.header&&se.match(/^#+$/,!0))return oe.highlightFormatting&&(jt.formatting="header"),ie(jt);var En=se.next();if(jt.linkTitle){jt.linkTitle=!1;var Ne=En;En==="("&&(Ne=")"),Ne=(Ne+"").replace(/([.?*+^\[\]\\(){}|-])/g,"\\$1");var Ze="^\\s*(?:[^"+Ne+"\\\\]+|\\\\\\\\|\\\\.)"+Ne;if(se.match(new RegExp(Ze),!0))return Nt.linkHref}if(En==="`"){var rn=jt.formatting;oe.highlightFormatting&&(jt.formatting="code"),se.eatWhile("`");var zn=se.current().length;if(jt.code==0&&(!jt.quote||zn==1))return jt.code=zn,ie(jt);if(zn==jt.code){var tn=ie(jt);return jt.code=0,tn}else return jt.formatting=rn,ie(jt)}else if(jt.code)return ie(jt);if(En==="\\"&&(se.next(),oe.highlightFormatting)){var Tn=ie(jt),we=Nt.formatting+"-escape";return Tn?Tn+" "+we:we}if(En==="!"&&se.match(/\[[^\]]*\] ?(?:\(|\[)/,!1))return jt.imageMarker=!0,jt.image=!0,oe.highlightFormatting&&(jt.formatting="image"),ie(jt);if(En==="["&&jt.imageMarker&&se.match(/[^\]]*\](\(.*?\)| ?\[.*?\])/,!1))return jt.imageMarker=!1,jt.imageAltText=!0,oe.highlightFormatting&&(jt.formatting="image"),ie(jt);if(En==="]"&&jt.imageAltText){oe.highlightFormatting&&(jt.formatting="image");var Tn=ie(jt);return jt.imageAltText=!1,jt.image=!1,jt.inline=jt.f=je,Tn}if(En==="["&&!jt.image)return jt.linkText&&se.match(/^.*?\]/)||(jt.linkText=!0,oe.highlightFormatting&&(jt.formatting="link")),ie(jt);if(En==="]"&&jt.linkText){oe.highlightFormatting&&(jt.formatting="link");var Tn=ie(jt);return jt.linkText=!1,jt.inline=jt.f=se.match(/\(.*?\)| ?\[.*?\]/,!1)?je:fe,Tn}if(En==="<"&&se.match(/^(https?|ftps?):\/\/(?:[^\\>]|\\.)+>/,!1)){jt.f=jt.inline=Zt,oe.highlightFormatting&&(jt.formatting="link");var Tn=ie(jt);return Tn?Tn+=" ":Tn="",Tn+Nt.linkInline}if(En==="<"&&se.match(/^[^> \\]+@(?:[^\\>]|\\.)+>/,!1)){jt.f=jt.inline=Zt,oe.highlightFormatting&&(jt.formatting="link");var Tn=ie(jt);return Tn?Tn+=" ":Tn="",Tn+Nt.linkEmail}if(oe.xml&&En==="<"&&se.match(/^(!--|\?|!\[CDATA\[|[a-z][a-z0-9-]*(?:\s+[a-z_:.\-]+(?:\s*=\s*[^>]+)?)*\s*(?:>|$))/i,!1)){var Bn=se.string.indexOf(">",se.pos);if(Bn!=-1){var Jn=se.string.substring(se.start,Bn);/markdown\s*=\s*('|"){0,1}1('|"){0,1}/.test(Jn)&&(jt.md_inside=!0)}return se.backUp(1),jt.htmlState=Ft.startState(ke),mt(se,jt,Dt)}if(oe.xml&&En==="<"&&se.match(/^\/\w*?>/))return jt.md_inside=!1,"tag";if(En==="*"||En==="_"){for(var Rt=1,Lt=se.pos==1?" ":se.string.charAt(se.pos-2);Rt<3&&se.eat(En);)Rt++;var St=se.peek()||" ",Et=!/\s/.test(St)&&(!dt.test(St)||/\s/.test(Lt)||dt.test(Lt)),Bt=!/\s/.test(Lt)&&(!dt.test(Lt)||/\s/.test(St)||dt.test(St)),yt=null,ae=null;if(Rt%2&&(!jt.em&&Et&&(En==="*"||!Bt||dt.test(Lt))?yt=!0:jt.em==En&&Bt&&(En==="*"||!Et||dt.test(St))&&(yt=!1)),Rt>1&&(!jt.strong&&Et&&(En==="*"||!Bt||dt.test(Lt))?ae=!0:jt.strong==En&&Bt&&(En==="*"||!Et||dt.test(St))&&(ae=!1)),ae!=null||yt!=null){oe.highlightFormatting&&(jt.formatting=yt==null?"strong":ae==null?"em":"strong em"),yt===!0&&(jt.em=En),ae===!0&&(jt.strong=En);var tn=ie(jt);return yt===!1&&(jt.em=!1),ae===!1&&(jt.strong=!1),tn}}else if(En===" "&&(se.eat("*")||se.eat("_"))){if(se.peek()===" ")return ie(jt);se.backUp(1)}if(oe.strikethrough){if(En==="~"&&se.eatWhile(En)){if(jt.strikethrough){oe.highlightFormatting&&(jt.formatting="strikethrough");var tn=ie(jt);return jt.strikethrough=!1,tn}else if(se.match(/^[^\s]/,!1))return jt.strikethrough=!0,oe.highlightFormatting&&(jt.formatting="strikethrough"),ie(jt)}else if(En===" "&&se.match(/^~~/,!0)){if(se.peek()===" ")return ie(jt);se.backUp(2)}}if(oe.emoji&&En===":"&&se.match(/^(?:[a-z_\d+][a-z_\d+-]*|\-[a-z_\d+][a-z_\d+-]*):/)){jt.emoji=!0,oe.highlightFormatting&&(jt.formatting="emoji");var Pe=ie(jt);return jt.emoji=!1,Pe}return En===" "&&(se.match(/^ +$/,!1)?jt.trailingSpace++:jt.trailingSpace&&(jt.trailingSpaceNewLine=!0)),ie(jt)}function Zt(se,jt){var $e=se.next();if($e===">"){jt.f=jt.inline=fe,oe.highlightFormatting&&(jt.formatting="link");var xn=ie(jt);return xn?xn+=" ":xn="",xn+Nt.linkInline}return se.match(/^[^>]+/,!0),Nt.linkInline}function je(se,jt){if(se.eatSpace())return null;var $e=se.next();return $e==="("||$e==="["?(jt.f=jt.inline=Xe($e==="("?")":"]"),oe.highlightFormatting&&(jt.formatting="link-string"),jt.linkHref=!0,ie(jt)):"error"}var me={")":/^(?:[^\\\(\)]|\\.|\((?:[^\\\(\)]|\\.)*\))*?(?=\))/,"]":/^(?:[^\\\[\]]|\\.|\[(?:[^\\\[\]]|\\.)*\])*?(?=\])/};function Xe(se){return function(jt,$e){var xn=jt.next();if(xn===se){$e.f=$e.inline=fe,oe.highlightFormatting&&($e.formatting="link-string");var En=ie($e);return $e.linkHref=!1,En}return jt.match(me[se]),$e.linkHref=!0,ie($e)}}function Se(se,jt){return se.match(/^([^\]\\]|\\.)*\]:/,!1)?(jt.f=Ie,se.next(),oe.highlightFormatting&&(jt.formatting="link"),jt.linkText=!0,ie(jt)):gt(se,jt,fe)}function Ie(se,jt){if(se.match(/^\]:/,!0)){jt.f=jt.inline=ze,oe.highlightFormatting&&(jt.formatting="link");var $e=ie(jt);return jt.linkText=!1,$e}return se.match(/^([^\]\\]|\\.)+/,!0),Nt.linkText}function ze(se,jt){return se.eatSpace()?null:(se.match(/^[^\s]+/,!0),se.peek()===void 0?jt.linkTitle=!0:se.match(/^(?:\s+(?:"(?:[^"\\]|\\\\|\\.)+"|'(?:[^'\\]|\\\\|\\.)+'|\((?:[^)\\]|\\\\|\\.)+\)))?/,!0),jt.f=jt.inline=fe,Nt.linkHref+" url")}var Ue={startState:function(){return{f:Tt,prevLine:{stream:null},thisLine:{stream:null},block:Tt,htmlState:null,indentation:0,inline:fe,text:Yt,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(se){return{f:se.f,prevLine:se.prevLine,thisLine:se.thisLine,block:se.block,htmlState:se.htmlState&&Ft.copyState(ke,se.htmlState),indentation:se.indentation,localMode:se.localMode,localState:se.localMode?Ft.copyState(se.localMode,se.localState):null,inline:se.inline,text:se.text,formatting:!1,linkText:se.linkText,linkTitle:se.linkTitle,linkHref:se.linkHref,code:se.code,em:se.em,strong:se.strong,strikethrough:se.strikethrough,emoji:se.emoji,header:se.header,setext:se.setext,hr:se.hr,taskList:se.taskList,list:se.list,listStack:se.listStack.slice(0),quote:se.quote,indentedCode:se.indentedCode,trailingSpace:se.trailingSpace,trailingSpaceNewLine:se.trailingSpaceNewLine,md_inside:se.md_inside,fencedEndRE:se.fencedEndRE}},token:function(se,jt){if(jt.formatting=!1,se!=jt.thisLine.stream){if(jt.header=0,jt.hr=!1,se.match(/^\s*$/,!0))return kt(jt),null;if(jt.prevLine=jt.thisLine,jt.thisLine={stream:se},jt.taskList=!1,jt.trailingSpace=0,jt.trailingSpaceNewLine=!1,!jt.localState&&(jt.f=jt.block,jt.f!=Dt)){var $e=se.match(/^\s*/,!0)[0].replace(/\t/g,at).length;if(jt.indentation=$e,jt.indentationDiff=null,$e>0)return null}}return jt.f(se,jt)},innerMode:function(se){return se.block==Dt?{state:se.htmlState,mode:ke}:se.localState?{state:se.localState,mode:se.localMode}:{state:se,mode:Ue}},indent:function(se,jt,$e){return se.block==Dt&&ke.indent?ke.indent(se.htmlState,jt,$e):se.localState&&se.localMode.indent?se.localMode.indent(se.localState,jt,$e):Ft.Pass},blankLine:kt,getType:ie,blockCommentStart:"",closeBrackets:"()[]{}''\"\"``",fold:"markdown"};return Ue},"xml"),Ft.defineMIME("text/markdown","markdown"),Ft.defineMIME("text/x-markdown","markdown")})},98101:function(Cn,cn,wt){(function(Ft){Ft(wt(89780))})(function(Ft){"use strict";Ft.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 Ht=0;Ht-1&&ke.substring(Nt+1,ke.length);if(Oe)return Ft.findModeByExtension(Oe)},Ft.findModeByName=function(ke){ke=ke.toLowerCase();for(var Vt=0;Vt0?It.cmdState[It.cmdState.length-1]:null}function qt(It){var et=It.cmdState.pop();et&&et.closeBracket()}function Nt(It){for(var et=It.cmdState,nt=et.length-1;nt>=0;nt--){var dt=et[nt];if(dt.name!="DEFAULT")return dt}return{styleIdentifier:function(){return null}}}function Oe(It,et,nt){return function(){this.name=It,this.bracketNo=0,this.style=et,this.styles=nt,this.argument=null,this.styleIdentifier=function(){return this.styles[this.bracketNo-1]||null},this.openBracket=function(){return this.bracketNo++,"bracket"},this.closeBracket=function(){}}}var be={};be.importmodule=Oe("importmodule","tag",["string","builtin"]),be.documentclass=Oe("documentclass","tag",["","atom"]),be.usepackage=Oe("usepackage","tag",["atom"]),be.begin=Oe("begin","tag",["atom"]),be.end=Oe("end","tag",["atom"]),be.label=Oe("label","tag",["atom"]),be.ref=Oe("ref","tag",["atom"]),be.eqref=Oe("eqref","tag",["atom"]),be.cite=Oe("cite","tag",["atom"]),be.bibitem=Oe("bibitem","tag",["atom"]),be.Bibitem=Oe("Bibitem","tag",["atom"]),be.RBibitem=Oe("RBibitem","tag",["atom"]),be.DEFAULT=function(){this.name="DEFAULT",this.style="tag",this.styleIdentifier=this.openBracket=this.closeBracket=function(){}};function Qt(It,et){It.f=et}function Fe(It,et){var nt;if(It.match(/^\\[a-zA-Z@]+/)){var dt=It.current().slice(1);return nt=be.hasOwnProperty(dt)?be[dt]:be.DEFAULT,nt=new nt,ke(et,nt),Qt(et,Re),nt.style}if(It.match(/^\\[$&%#{}_]/)||It.match(/^\\[,;!\/\\]/))return"tag";if(It.match("\\["))return Qt(et,function(gt,mt){return ye(gt,mt,"\\]")}),"keyword";if(It.match("\\("))return Qt(et,function(gt,mt){return ye(gt,mt,"\\)")}),"keyword";if(It.match("$$"))return Qt(et,function(gt,mt){return ye(gt,mt,"$$")}),"keyword";if(It.match("$"))return Qt(et,function(gt,mt){return ye(gt,mt,"$")}),"keyword";var at=It.next();if(at=="%")return It.skipToEnd(),"comment";if(at=="}"||at=="]"){if(nt=Vt(et),nt)nt.closeBracket(at),Qt(et,Re);else return"error";return"bracket"}else return at=="{"||at=="["?(nt=be.DEFAULT,nt=new nt,ke(et,nt),"bracket"):/\d/.test(at)?(It.eatWhile(/[\w.%]/),"atom"):(It.eatWhile(/[\w\-_]/),nt=Nt(et),nt.name=="begin"&&(nt.argument=It.current()),nt.styleIdentifier())}function ye(It,et,nt){if(It.eatSpace())return null;if(nt&&It.match(nt))return Qt(et,Fe),"keyword";if(It.match(/^\\[a-zA-Z@]+/))return"tag";if(It.match(/^[a-zA-Z]+/))return"variable-2";if(It.match(/^\\[$&%#{}_]/)||It.match(/^\\[,;!\/]/)||It.match(/^[\^_&]/))return"tag";if(It.match(/^[+\-<>|=,\/@!*:;'"`~#?]/))return null;if(It.match(/^(\d+\.\d*|\d*\.\d+|\d+)/))return"number";var dt=It.next();return dt=="{"||dt=="}"||dt=="["||dt=="]"||dt=="("||dt==")"?"bracket":dt=="%"?(It.skipToEnd(),"comment"):"error"}function Re(It,et){var nt=It.peek(),dt;return nt=="{"||nt=="["?(dt=Vt(et),dt.openBracket(nt),It.eat(nt),Qt(et,Fe),"bracket"):/[ \t\r]/.test(nt)?(It.eat(nt),null):(Qt(et,Fe),qt(et),Fe(It,et))}return{startState:function(){var It=oe.inMathMode?function(et,nt){return ye(et,nt)}:Fe;return{cmdState:[],f:It}},copyState:function(It){return{cmdState:It.cmdState.slice(),f:It.f}},token:function(It,et){return et.f(It,et)},blankLine:function(It){It.f=Fe,It.cmdState.length=0},lineComment:"%"}}),Ft.defineMIME("text/x-stex","stex"),Ft.defineMIME("text/x-latex","stex")})},15525:function(Cn,cn,wt){(function(Ft){Ft(wt(89780))})(function(Ft){"use strict";var Ht={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},oe={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};Ft.defineMode("xml",function(ke,Vt){var qt=ke.indentUnit,Nt={},Oe=Vt.htmlMode?Ht:oe;for(var be in Oe)Nt[be]=Oe[be];for(var be in Vt)Nt[be]=Vt[be];var Qt,Fe;function ye(Zt,je){function me(Ie){return je.tokenize=Ie,Ie(Zt,je)}var Xe=Zt.next();if(Xe=="<")return Zt.eat("!")?Zt.eat("[")?Zt.match("CDATA[")?me(et("atom","]]>")):null:Zt.match("--")?me(et("comment","-->")):Zt.match("DOCTYPE",!0,!0)?(Zt.eatWhile(/[\w\._\-]/),me(nt(1))):null:Zt.eat("?")?(Zt.eatWhile(/[\w\._\-]/),je.tokenize=et("meta","?>"),"meta"):(Qt=Zt.eat("/")?"closeTag":"openTag",je.tokenize=Re,"tag bracket");if(Xe=="&"){var Se;return Zt.eat("#")?Zt.eat("x")?Se=Zt.eatWhile(/[a-fA-F\d]/)&&Zt.eat(";"):Se=Zt.eatWhile(/[\d]/)&&Zt.eat(";"):Se=Zt.eatWhile(/[\w\.\-:]/)&&Zt.eat(";"),Se?"atom":"error"}else return Zt.eatWhile(/[^&<]/),null}ye.isInText=!0;function Re(Zt,je){var me=Zt.next();if(me==">"||me=="/"&&Zt.eat(">"))return je.tokenize=ye,Qt=me==">"?"endTag":"selfcloseTag","tag bracket";if(me=="=")return Qt="equals",null;if(me=="<"){je.tokenize=ye,je.state=mt,je.tagName=je.tagStart=null;var Xe=je.tokenize(Zt,je);return Xe?Xe+" tag error":"tag error"}else return/[\'\"]/.test(me)?(je.tokenize=It(me),je.stringStartCol=Zt.column(),je.tokenize(Zt,je)):(Zt.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function It(Zt){var je=function(me,Xe){for(;!me.eol();)if(me.next()==Zt){Xe.tokenize=Re;break}return"string"};return je.isInAttribute=!0,je}function et(Zt,je){return function(me,Xe){for(;!me.eol();){if(me.match(je)){Xe.tokenize=ye;break}me.next()}return Zt}}function nt(Zt){return function(je,me){for(var Xe;(Xe=je.next())!=null;){if(Xe=="<")return me.tokenize=nt(Zt+1),me.tokenize(je,me);if(Xe==">")if(Zt==1){me.tokenize=ye;break}else return me.tokenize=nt(Zt-1),me.tokenize(je,me)}return"meta"}}function dt(Zt,je,me){this.prev=Zt.context,this.tagName=je,this.indent=Zt.indented,this.startOfLine=me,(Nt.doNotIndent.hasOwnProperty(je)||Zt.context&&Zt.context.noIndent)&&(this.noIndent=!0)}function at(Zt){Zt.context&&(Zt.context=Zt.context.prev)}function gt(Zt,je){for(var me;;){if(!Zt.context||(me=Zt.context.tagName,!Nt.contextGrabbers.hasOwnProperty(me)||!Nt.contextGrabbers[me].hasOwnProperty(je)))return;at(Zt)}}function mt(Zt,je,me){return Zt=="openTag"?(me.tagStart=je.column(),Pt):Zt=="closeTag"?kt:mt}function Pt(Zt,je,me){return Zt=="word"?(me.tagName=je.current(),Fe="tag",$t):Nt.allowMissingTagName&&Zt=="endTag"?(Fe="tag bracket",$t(Zt,je,me)):(Fe="error",Pt)}function kt(Zt,je,me){if(Zt=="word"){var Xe=je.current();return me.context&&me.context.tagName!=Xe&&Nt.implicitlyClosed.hasOwnProperty(me.context.tagName)&&at(me),me.context&&me.context.tagName==Xe||Nt.matchClosing===!1?(Fe="tag",Tt):(Fe="tag error",Dt)}else return Nt.allowMissingTagName&&Zt=="endTag"?(Fe="tag bracket",Tt(Zt,je,me)):(Fe="error",Dt)}function Tt(Zt,je,me){return Zt!="endTag"?(Fe="error",Tt):(at(me),mt)}function Dt(Zt,je,me){return Fe="error",Tt(Zt,je,me)}function $t(Zt,je,me){if(Zt=="word")return Fe="attribute",ie;if(Zt=="endTag"||Zt=="selfcloseTag"){var Xe=me.tagName,Se=me.tagStart;return me.tagName=me.tagStart=null,Zt=="selfcloseTag"||Nt.autoSelfClosers.hasOwnProperty(Xe)?gt(me,Xe):(gt(me,Xe),me.context=new dt(me,Xe,Se==me.indented)),mt}return Fe="error",$t}function ie(Zt,je,me){return Zt=="equals"?Yt:(Nt.allowMissing||(Fe="error"),$t(Zt,je,me))}function Yt(Zt,je,me){return Zt=="string"?fe:Zt=="word"&&Nt.allowUnquoted?(Fe="string",$t):(Fe="error",$t(Zt,je,me))}function fe(Zt,je,me){return Zt=="string"?fe:$t(Zt,je,me)}return{startState:function(Zt){var je={tokenize:ye,state:mt,indented:Zt||0,tagName:null,tagStart:null,context:null};return Zt!=null&&(je.baseIndent=Zt),je},token:function(Zt,je){if(!je.tagName&&Zt.sol()&&(je.indented=Zt.indentation()),Zt.eatSpace())return null;Qt=null;var me=je.tokenize(Zt,je);return(me||Qt)&&me!="comment"&&(Fe=null,je.state=je.state(Qt||me,Zt,je),Fe&&(me=Fe=="error"?me+" error":Fe)),me},indent:function(Zt,je,me){var Xe=Zt.context;if(Zt.tokenize.isInAttribute)return Zt.tagStart==Zt.indented?Zt.stringStartCol+1:Zt.indented+qt;if(Xe&&Xe.noIndent)return Ft.Pass;if(Zt.tokenize!=Re&&Zt.tokenize!=ye)return me?me.match(/^(\s*)/)[0].length:0;if(Zt.tagName)return Nt.multilineTagIndentPastTag!==!1?Zt.tagStart+Zt.tagName.length+2:Zt.tagStart+qt*(Nt.multilineTagIndentFactor||1);if(Nt.alignCDATA&&/$/,blockCommentStart:"",configuration:Nt.htmlMode?"html":"xml",helperType:Nt.htmlMode?"html":"xml",skipAttribute:function(Zt){Zt.state==Yt&&(Zt.state=$t)},xmlCurrentTag:function(Zt){return Zt.tagName?{name:Zt.tagName,close:Zt.type=="closeTag"}:null},xmlCurrentContext:function(Zt){for(var je=[],me=Zt.context;me;me=me.prev)me.tagName&&je.push(me.tagName);return je.reverse()}}}),Ft.defineMIME("text/xml","xml"),Ft.defineMIME("application/xml","xml"),Ft.mimeModes.hasOwnProperty("text/html")||Ft.defineMIME("text/html",{name:"xml",htmlMode:!0})})},12378:function(Cn,cn,wt){"use strict";wt.d(cn,{$u:function(){return be},BD:function(){return Rt},E9:function(){return Oe},FF:function(){return Kn},FJ:function(){return mt},Hn:function(){return gt},KX:function(){return kt},NB:function(){return ge},S0:function(){return we},UL:function(){return Qt},Vk:function(){return at},Vm:function(){return le},YI:function(){return Bn},ZA:function(){return oe},Zt:function(){return Fe},al:function(){return yt},bn:function(){return Bt},bx:function(){return Lt},g2:function(){return Jn},h1:function(){return Yt},hD:function(){return gi},l4:function(){return qt},rU:function(){return pe},s_:function(){return St},uz:function(){return _t},z6:function(){return ye}}),Cn=wt.hmd(Cn),function(){var bt;function no(a){var y=0;return function(){return yx&&(x=Math.max(0,E+x)),(b==null||b>E)&&(b=E),b=Number(b),0>b&&(b=Math.max(0,E+b)),x=Number(x||0);x=a.length?a.push(x):a.splice(y,0,x):ce("Cannot insert an object into an HTMLCollection or NodeList: "+x+" at "+y)}function Si(a,y){Array.isArray(a)?y>=a.length?a.pop():a.splice(y,1):ce("Cannot remove an object from an HTMLCollection or NodeList at "+y)}function Zn(){var a=io.pop();return a===void 0?[]:a}function hi(a){a.length=0,io.push(a)}function Qn(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(Ae(a)&&a.constructor)return Qn(a.constructor);return typeof a}function Ci(a){var y=a;return Ae(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 so(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 wo(a,y,x){Object.defineProperty(br.prototype,a,{get:y,set:x})}function sn(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 b=0,E=0;Ex;x++)y[x]=x;for(x=b=0;256>x;x++)b=(b+y[x]+119)%256,E=y[x],y[x]=y[b],y[b]=E;b=x=0;for(var z="",tt=0;tt-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 Bo=ue.navigator!==void 0&&0this.key)return!1;a=a.s;var y=a.length,x=++this.Za,b=this.qf;if(b!==null)for(;xthis.key)return!1;var y=--this.Za;return 0<=y?(this.key=y,this.value=a.s[y],!0):(this.de(),!1)},fo.prototype.Ad=function(){return this.next()},fo.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},fo.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},fo.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},fo.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},fo.prototype.map=function(a){var y=this.Bb;y.Hg=null;var x=[];y=y.s;var b=y.length;for(this.Za=b,--b;0<=b;b--)x.push(a(y[b]));return a=new mn,a.s=x,a.xb(),a.iterator},fo.prototype.filter=function(a){var y=this.Bb;y.Hg=null;var x=[];y=y.s;var b=y.length;for(this.Za=b,--b;0<=b;b--){var E=y[b];a(E)&&x.push(E)}return a=new mn,a.s=x,a.xb(),a.iterator},fo.prototype.de=function(){this.key=-1,this.value=null,this.qa=-1,this.Bb.Hg=this},fo.prototype.toString=function(){return"ListIteratorBackwards("+this.Za+"/"+this.Bb.count+")"},Jt.Object.defineProperties(fo.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.Bb.s.length}}}),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="ListIteratorBackwards";function mn(a){Po(this),this._isFrozen=!1,this.s=[],this.Ja=0,this.Hg=this.Sa=null,typeof a=="string"&&ce("Error: Since 2.0 List/Map/Set constructors no longer take an argument that enforces type."),a!==void 0&&this.addAll(a)}bt=mn.prototype,bt.xb=function(){var a=this.Ja;a++,999999999a||a>=y.length)&&An(a,"0 <= i < length",mn,"elt:i"),y[a]},bt.get=function(a){return this.M(a)},bt.cd=function(a,y){var x=this.s;(0>a||a>=x.length)&&An(a,"0 <= i < length",mn,"setElt:i"),this._isFrozen&&vn(this,a),x[a]=y},bt.set=function(a,y){this.cd(a,y)},bt.first=function(){var a=this.s;return a.length===0?null:a[0]},bt.jc=function(){var a=this.s,y=a.length;return 0a&&An(a,">= 0",mn,"insertAt:i"),this._isFrozen&&vn(this,a);var x=this.s;a>=x.length?x.push(y):x.splice(a,0,y),this.xb()},bt.remove=function(a){if(a===null)return!1;this._isFrozen&&vn(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)},bt.delete=function(a){return this.remove(a)},bt.mb=function(a){var y=this.s;(0>a||a>=y.length)&&An(a,"0 <= i < length",mn,"removeAt:i"),this._isFrozen&&vn(this,a),a===y.length-1?y.pop():y.splice(a,1),this.xb()},bt.removeRange=function(a,y){var x=this.s,b=x.length;if(0>a)a=0;else if(a>=b)return this;if(0>y)return this;if(y>=b&&(y=b-1),a>y)return this;this._isFrozen&&vn(this);for(var E=a,z=y+1;z=z)return this;if((0>y||y>=E-1)&&An(y,"0 <= from < length",mn,"sortRange:from"),z===2)return x=b[y],E=b[y+1],0=E)b.sort(a);else for(y=b.slice(0,x),y.sort(a),a=0;a=E)for(x=b.slice(y),x.sort(a),a=y;a=this.s.length)return co;var a=this.Sa;return a!==null?(a.reset(),a):new Hi(this)}},iteratorBackwards:{get:function(){if(0>=this.s.length)return co;var a=this.Hg;return a!==null?(a.reset(),a):new fo(this)}}}),mn.prototype.reverse=mn.prototype.reverse,mn.prototype.sortRange=mn.prototype.zi,mn.prototype.sort=mn.prototype.sort,mn.prototype.toSet=mn.prototype.Iv,mn.prototype.toArray=mn.prototype.Fa,mn.prototype.removeRange=mn.prototype.removeRange,mn.prototype.removeAt=mn.prototype.mb,mn.prototype.delete=mn.prototype.delete,mn.prototype.remove=mn.prototype.remove,mn.prototype.insertAt=mn.prototype.Gb,mn.prototype.pop=mn.prototype.pop,mn.prototype.last=mn.prototype.jc,mn.prototype.first=mn.prototype.first,mn.prototype.set=mn.prototype.set,mn.prototype.setElt=mn.prototype.cd,mn.prototype.get=mn.prototype.get,mn.prototype.elt=mn.prototype.M,mn.prototype.indexOf=mn.prototype.indexOf,mn.prototype.has=mn.prototype.has,mn.prototype.contains=mn.prototype.contains,mn.prototype.clear=mn.prototype.clear,mn.prototype.addAll=mn.prototype.addAll,mn.prototype.push=mn.prototype.push,mn.prototype.add=mn.prototype.add,mn.prototype.thaw=mn.prototype.ka,mn.prototype.freeze=mn.prototype.freeze,mn.className="List";function Uo(a){this.eg=a,a.Sa=null,this.qa=a.Ja,this.sa=null}Uo.prototype.reset=function(){var a=this.eg;a.Sa=null,this.qa=a.Ja,this.sa=null},Uo.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)},Uo.prototype.Ad=function(){return this.next()},Uo.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},Uo.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},Uo.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},Uo.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},Uo.prototype.map=function(a){var y=this.eg;y.Sa=null;var x=new mn;for(y=y.ea;y!==null;)x.add(a(y.value)),y=y.va;return x.iterator},Uo.prototype.filter=function(a){var y=this.eg;y.Sa=null;var x=new mn;for(y=y.ea;y!==null;){var b=y.value;a(b)&&x.add(b),y=y.va}return x.iterator},Uo.prototype.de=function(){this.value=this.key=null,this.qa=-1,this.eg.Sa=this},Uo.prototype.toString=function(){return this.sa!==null?"SetIterator@"+this.sa.value:"SetIterator"},Jt.Object.defineProperties(Uo.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.eg.Sb}}}),Uo.prototype.first=Uo.prototype.first,Uo.prototype.hasNext=Uo.prototype.Ad,Uo.prototype.next=Uo.prototype.next,Uo.prototype.reset=Uo.prototype.reset,Uo.className="SetIterator";function un(a){Po(this),this._isFrozen=!1,this.Tb={},this.Sb=0,this.Sa=null,this.Ja=0,this.kf=this.ea=null,typeof a=="string"&&ce("Error: Since 2.0 List/Map/Set constructors no longer take an argument that enforces type."),a!==void 0&&this.addAll(a)}bt=un.prototype,bt.xb=function(){var a=this.Ja;a++,999999999=this.Sb)return co;var a=this.Sa;return a!==null?(a.reset(),a):new Uo(this)}}}),un.prototype.toList=un.prototype.Hv,un.prototype.toArray=un.prototype.Fa,un.prototype.clear=un.prototype.clear,un.prototype.retainAll=un.prototype.pA,un.prototype.removeAll=un.prototype.hp,un.prototype.delete=un.prototype.delete,un.prototype.remove=un.prototype.remove,un.prototype.first=un.prototype.first,un.prototype.containsAny=un.prototype.Ty,un.prototype.containsAll=un.prototype.Sy,un.prototype.has=un.prototype.has,un.prototype.contains=un.prototype.contains,un.prototype.addAll=un.prototype.addAll,un.prototype.add=un.prototype.add,un.prototype.thaw=un.prototype.ka,un.prototype.freeze=un.prototype.freeze;var Hr=1;un.className="Set",un.uniqueHash=Po,un.hashIdUnique=kr,un.hashId=$o;function xr(a){this.ma=a,this.qa=a.Ja,this.sa=null}xr.prototype.reset=function(){this.qa=this.ma.Ja,this.sa=null},xr.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)},xr.prototype.Ad=function(){return this.next()},xr.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},xr.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},xr.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},xr.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},xr.prototype.map=function(a){var y=this.ma;this.sa=null;var x=new mn;for(y=y.ea;y!==null;)x.add(a(y.key)),y=y.va;return x.iterator},xr.prototype.filter=function(a){var y=this.ma;this.sa=null;var x=new mn;for(y=y.ea;y!==null;){var b=y.key;a(b)&&x.add(b),y=y.va}return x.iterator},xr.prototype.de=function(){this.value=this.key=null,this.qa=-1},xr.prototype.toString=function(){return this.sa!==null?"MapKeySetIterator@"+this.sa.value:"MapKeySetIterator"},Jt.Object.defineProperties(xr.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.ma.Sb}}}),xr.prototype.first=xr.prototype.first,xr.prototype.hasNext=xr.prototype.Ad,xr.prototype.next=xr.prototype.next,xr.prototype.reset=xr.prototype.reset,xr.className="MapKeySetIterator";function Wi(a){un.call(this),Po(this),this._isFrozen=!0,this.ma=a}We(Wi,un),bt=Wi.prototype,bt.freeze=function(){return this},bt.ka=function(){return this},bt.toString=function(){return"MapKeySet("+this.ma.toString()+")"},bt.add=function(){ce("This Set is read-only: "+this.toString())},bt.contains=function(a){return this.ma.contains(a)},bt.has=function(a){return this.contains(a)},bt.remove=function(){ce("This Set is read-only: "+this.toString())},bt.delete=function(a){return this.remove(a)},bt.clear=function(){ce("This Set is read-only: "+this.toString())},bt.first=function(){var a=this.ma.ea;return a!==null?a.key:null},Wi.prototype.any=function(a){for(var y=this.ma.ea;y!==null;){if(a(y.key))return!0;y=y.va}return!1},Wi.prototype.all=function(a){for(var y=this.ma.ea;y!==null;){if(!a(y.key))return!1;y=y.va}return!0},Wi.prototype.each=function(a){for(var y=this.ma.ea;y!==null;)a(y.key),y=y.va;return this},Wi.prototype.map=function(a){for(var y=new un,x=this.ma.ea;x!==null;)y.add(a(x.key)),x=x.va;return y},Wi.prototype.filter=function(a){for(var y=new un,x=this.ma.ea;x!==null;){var b=x.key;a(b)&&y.add(b),x=x.va}return y},Wi.prototype.copy=function(){return new Wi(this.ma)},Wi.prototype.Iv=function(){var a=new un,y=this.ma.Tb,x;for(x in y)a.add(y[x].key);return a},Wi.prototype.Fa=function(){var a=this.ma.Tb,y=Array(this.ma.Sb),x=0,b;for(b in a)y[x]=a[b].key,x++;return y},Wi.prototype.Hv=function(){var a=new mn,y=this.ma.Tb,x;for(x in y)a.add(y[x].key);return a},Jt.Object.defineProperties(Wi.prototype,{count:{get:function(){return this.ma.Sb}},size:{get:function(){return this.ma.Sb}},iterator:{get:function(){return 0>=this.ma.Sb?co:new xr(this.ma)}}}),Wi.prototype.toList=Wi.prototype.Hv,Wi.prototype.toArray=Wi.prototype.Fa,Wi.prototype.toSet=Wi.prototype.Iv,Wi.prototype.first=Wi.prototype.first,Wi.prototype.clear=Wi.prototype.clear,Wi.prototype.delete=Wi.prototype.delete,Wi.prototype.remove=Wi.prototype.remove,Wi.prototype.has=Wi.prototype.has,Wi.prototype.contains=Wi.prototype.contains,Wi.prototype.add=Wi.prototype.add,Wi.prototype.thaw=Wi.prototype.ka,Wi.prototype.freeze=Wi.prototype.freeze,Wi.className="MapKeySet";function Ui(a){this.ma=a,a.jf=null,this.qa=a.Ja,this.sa=null}Ui.prototype.reset=function(){var a=this.ma;a.jf=null,this.qa=a.Ja,this.sa=null},Ui.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)},Ui.prototype.Ad=function(){return this.next()},Ui.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},Ui.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},Ui.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},Ui.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},Ui.prototype.map=function(a){var y=this.ma;this.sa=y.jf=null;var x=new mn;for(y=y.ea;y!==null;)x.add(a(y.value)),y=y.va;return x.iterator},Ui.prototype.filter=function(a){var y=this.ma;this.sa=y.jf=null;var x=new mn;for(y=y.ea;y!==null;){var b=y.value;a(b)&&x.add(b),y=y.va}return x.iterator},Ui.prototype.de=function(){this.value=this.key=null,this.qa=-1,this.ma.jf=this},Ui.prototype.toString=function(){return this.sa!==null?"MapValueSetIterator@"+this.sa.value:"MapValueSetIterator"},Jt.Object.defineProperties(Ui.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.ma.Sb}}}),Ui.prototype.first=Ui.prototype.first,Ui.prototype.hasNext=Ui.prototype.Ad,Ui.prototype.next=Ui.prototype.next,Ui.prototype.reset=Ui.prototype.reset,Ui.className="MapValueSetIterator";function ko(a,y){this.key=a,this.value=y,this.ll=this.va=null}ko.prototype.toString=function(){return"{"+this.key+":"+this.value+"}"},ko.className="KeyValuePair";function Yo(a){this.ma=a,a.Sa=null,this.qa=a.Ja,this.sa=null}Yo.prototype.reset=function(){var a=this.ma;a.Sa=null,this.qa=a.Ja,this.sa=null},Yo.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)},Yo.prototype.Ad=function(){return this.next()},Yo.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},Yo.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},Yo.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},Yo.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},Yo.prototype.map=function(a){var y=this.ma;this.sa=y.Sa=null;var x=new mn;for(y=y.ea;y!==null;)x.add(a(y)),y=y.va;return x.iterator},Yo.prototype.filter=function(a){var y=this.ma;this.sa=y.Sa=null;var x=new mn;for(y=y.ea;y!==null;)a(y)&&x.add(y),y=y.va;return x.iterator},Yo.prototype.de=function(){this.value=this.key=null,this.qa=-1,this.ma.Sa=this},Yo.prototype.toString=function(){return this.sa!==null?"MapIterator@"+this.sa:"MapIterator"},Jt.Object.defineProperties(Yo.prototype,{iterator:{get:function(){return this}},count:{get:function(){return this.ma.Sb}}}),Yo.prototype.first=Yo.prototype.first,Yo.prototype.hasNext=Yo.prototype.Ad,Yo.prototype.next=Yo.prototype.next,Yo.prototype.reset=Yo.prototype.reset,Yo.className="MapIterator";function ri(a){Po(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"&&ce("Error: Since 2.0 List/Map/Set constructors no longer take an argument that enforces type."),a!==void 0&&this.addAll(a)}bt=ri.prototype,bt.xb=function(){var a=this.Ja;a++,999999999=this.count)return co;var a=this.Sa;return a!==null?(a.reset(),a):new Yo(this)}},iteratorKeys:{get:function(){return 0>=this.count?co:new xr(this)}},iteratorValues:{get:function(){if(0>=this.count)return co;var a=this.jf;return a!==null?(a.reset(),a):new Ui(this)}}}),ri.prototype.toKeySet=ri.prototype.Lf,ri.prototype.toArray=ri.prototype.Fa,ri.prototype.clear=ri.prototype.clear,ri.prototype.delete=ri.prototype.delete,ri.prototype.remove=ri.prototype.remove,ri.prototype.get=ri.prototype.get,ri.prototype.getValue=ri.prototype.I,ri.prototype.has=ri.prototype.has,ri.prototype.contains=ri.prototype.contains,ri.prototype.first=ri.prototype.first,ri.prototype.addAll=ri.prototype.addAll,ri.prototype.set=ri.prototype.set,ri.prototype.add=ri.prototype.add,ri.prototype.thaw=ri.prototype.ka,ri.prototype.freeze=ri.prototype.freeze,ri.className="Map";function Gt(a,y){a===void 0?this.y=this.x=0:typeof a=="number"&&typeof y=="number"?(this.x=a,this.y=y):ce("Invalid arguments to Point constructor: "+a+", "+y),this._isFrozen=!1}var qo,Sr,ps,ms,ks;Gt.prototype.assign=function(a){return this.x=a.x,this.y=a.y,this},Gt.prototype.h=function(a,y){return this.x=a,this.y=y,this},Gt.prototype.sg=function(a,y){return this.x=a,this.y=y,this},Gt.prototype.set=function(a){return this.x=a.x,this.y=a.y,this},Gt.prototype.copy=function(){var a=new Gt;return a.x=this.x,a.y=this.y,a},bt=Gt.prototype,bt.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},bt.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},bt.freeze=function(){return this._isFrozen=!0,this},bt.ka=function(){return Object.isFrozen(this)&&ce("cannot thaw constant: "+this),this._isFrozen=!1,this};function po(a){if(typeof a=="string"){a=a.split(" ");for(var y=0,x=0;a[y]==="";)y++;var b=a[y++];b&&(x=parseFloat(b));for(var E=0;a[y]==="";)y++;return(b=a[y++])&&(E=parseFloat(b)),new Gt(x,E)}return new Gt}function to(a){return a.x.toString()+" "+a.y.toString()}bt.toString=function(){return"Point("+this.x+","+this.y+")"},bt.D=function(a){return a instanceof Gt?this.x===a.x&&this.y===a.y:!1},bt.hi=function(a,y){return this.x===a&&this.y===y},bt.Xa=function(a){return Ce.B(this.x,a.x)&&Ce.B(this.y,a.y)},bt.add=function(a){return this.x+=a.x,this.y+=a.y,this},bt.re=function(a){return this.x-=a.x,this.y-=a.y,this},bt.offset=function(a,y){return this.x+=a,this.y+=y,this},Gt.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 b=1}else a===180?(a=-1,b=0):a===270?(a=0,b=-1):(b=a*Math.PI/180,a=Math.cos(b),b=Math.sin(b));return this.x=a*y-b*x,this.y=b*y+a*x,this},bt=Gt.prototype,bt.scale=function(a,y){return this.x*=a,this.y*=y,this},bt.Bf=function(a){var y=a.x-this.x;return a=a.y-this.y,y*y+a*a},bt.zd=function(a,y){return a-=this.x,y-=this.y,a*a+y*y},bt.normalize=function(){var a=this.x,y=this.y,x=Math.sqrt(a*a+y*y);return 0y?270:0;if(y===0)return 0a?x=0>y?x+180:180-x:0>y&&(x=360-x),x}bt.Ry=function(a,y){return Ce.Fl(a.x,a.y,y.x,y.y,this.x,this.y)},bt.fA=function(a,y,x,b){return Ce.qh(a,y,x,b,this.x,this.y,this),this},bt.gA=function(a,y){return Ce.qh(a.x,a.y,y.x,y.y,this.x,this.y,this),this},bt.uA=function(a,y,x,b){return Ce.No(this.x,this.y,a,y,x,b,this),this},bt.vA=function(a,y){return Ce.No(this.x,this.y,a.x,a.y,y.width,y.height,this),this},bt.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},bt.yi=function(a,y,x,b,E){return this.x=a+E.x*x+E.offsetX,this.y=y+E.y*b+E.offsetY,this},bt.transform=function(a){return a.Ga(this),this};function ao(a,y){return y.Cd(a),a}function lr(a,y,x,b,E,z){var tt=E-x,ot=z-b,rt=tt*tt+ot*ot;x-=a,b-=y;var lt=-x*tt-b*ot;return 0>=lt||lt>=rt?(tt=E-a,ot=z-y,Math.min(x*x+b*b,tt*tt+ot*ot)):(a=tt*b-ot*x,a*a/rt)}function Ys(a,y,x,b){return a=x-a,y=b-y,a*a+y*y}function qi(a,y,x,b){return a=x-a,y=b-y,a===0?0y?270:0:y===0?0a?b=0>y?b+180:180-b:0>y&&(b=360-b),b)}bt.w=function(){return isFinite(this.x)&&isFinite(this.y)},Gt.alloc=function(){var a=Ai.pop();return a===void 0?new Gt:a},Gt.allocAt=function(a,y){var x=Ai.pop();return x===void 0?new Gt(a,y):(x.x=a,x.y=y,x)},Gt.free=function(a){Ai.push(a)},Gt.prototype.isReal=Gt.prototype.w,Gt.prototype.setSpot=Gt.prototype.yi,Gt.prototype.setRectSpot=Gt.prototype.xi,Gt.prototype.snapToGridPoint=Gt.prototype.vA,Gt.prototype.snapToGrid=Gt.prototype.uA,Gt.prototype.projectOntoLineSegmentPoint=Gt.prototype.gA,Gt.prototype.projectOntoLineSegment=Gt.prototype.fA,Gt.intersectingLineSegments=function(a,y,x,b,E,z,tt,ot){return Ce.Rl(a,y,x,b,E,z,tt,ot)},Gt.prototype.compareWithLineSegmentPoint=Gt.prototype.Ry,Gt.compareWithLineSegment=function(a,y,x,b,E,z){return Ce.Fl(a,y,x,b,E,z)},Gt.prototype.direction=Gt.prototype.direction,Gt.prototype.directionPoint=Gt.prototype.ab,Gt.prototype.normalize=Gt.prototype.normalize,Gt.prototype.distanceSquared=Gt.prototype.zd,Gt.prototype.distanceSquaredPoint=Gt.prototype.Bf,Gt.prototype.scale=Gt.prototype.scale,Gt.prototype.rotate=Gt.prototype.rotate,Gt.prototype.offset=Gt.prototype.offset,Gt.prototype.subtract=Gt.prototype.re,Gt.prototype.add=Gt.prototype.add,Gt.prototype.equalsApprox=Gt.prototype.Xa,Gt.prototype.equalTo=Gt.prototype.hi,Gt.prototype.equals=Gt.prototype.D,Gt.prototype.set=Gt.prototype.set,Gt.prototype.setTo=Gt.prototype.sg;var Ai=[];Gt.className="Point",Gt.parse=po,Gt.stringify=to,Gt.distanceLineSegmentSquared=lr,Gt.distanceSquared=Ys,Gt.direction=qi,Gt.Origin=qo=new Gt(0,0).ja(),Gt.InfiniteTopLeft=Sr=new Gt(-1/0,-1/0).ja(),Gt.InfiniteBottomRight=ps=new Gt(1/0,1/0).ja(),Gt.SixPoint=ms=new Gt(6,6).ja(),Gt.NoPoint=ks=new Gt(NaN,NaN).ja(),Gt.parse=po,Gt.stringify=to,Gt.distanceLineSegmentSquared=lr,Gt.distanceSquared=Ys,Gt.direction=qi;function Nn(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):ce("Invalid arguments to Size constructor: "+a+", "+y),this._isFrozen=!1}var Zi,Xo,zr,Ir,Vr,Ns,Jr;Nn.prototype.assign=function(a){return this.width=a.width,this.height=a.height,this},Nn.prototype.h=function(a,y){return this.width=a,this.height=y,this},Nn.prototype.sg=function(a,y){return this.width=a,this.height=y,this},Nn.prototype.set=function(a){return this.width=a.width,this.height=a.height,this},Nn.prototype.copy=function(){var a=new Nn;return a.width=this.width,a.height=this.height,a},bt=Nn.prototype,bt.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},bt.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},bt.freeze=function(){return this._isFrozen=!0,this},bt.ka=function(){return Object.isFrozen(this)&&ce("cannot thaw constant: "+this),this._isFrozen=!1,this};function ga(a){if(typeof a=="string"){a=a.split(" ");for(var y=0,x=0;a[y]==="";)y++;var b=a[y++];b&&(x=parseFloat(b));for(var E=0;a[y]==="";)y++;return(b=a[y++])&&(E=parseFloat(b)),new Nn(x,E)}return new Nn}function Qs(a){return a.width.toString()+" "+a.height.toString()}bt.toString=function(){return"Size("+this.width+","+this.height+")"},bt.D=function(a){return a instanceof Nn?this.width===a.width&&this.height===a.height:!1},bt.hi=function(a,y){return this.width===a&&this.height===y},bt.Xa=function(a){return Ce.B(this.width,a.width)&&Ce.B(this.height,a.height)},bt.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},bt.w=function(){return isFinite(this.width)&&isFinite(this.height)},Nn.alloc=function(){var a=Ea.pop();return a===void 0?new Nn:a},Nn.free=function(a){Ea.push(a)},Nn.prototype.isReal=Nn.prototype.w,Nn.prototype.inflate=Nn.prototype.Bc,Nn.prototype.equalsApprox=Nn.prototype.Xa,Nn.prototype.equalTo=Nn.prototype.hi,Nn.prototype.equals=Nn.prototype.D,Nn.prototype.set=Nn.prototype.set,Nn.prototype.setTo=Nn.prototype.sg;var Ea=[];Nn.className="Size",Nn.parse=ga,Nn.stringify=Qs,Nn.ZeroSize=Zi=new Nn(0,0).ja(),Nn.OneSize=Xo=new Nn(1,1).ja(),Nn.SixSize=zr=new Nn(6,6).ja(),Nn.EightSize=Ir=new Nn(8,8).ja(),Nn.TenSize=Vr=new Nn(10,10).ja(),Nn.InfiniteSize=Ns=new Nn(1/0,1/0).ja(),Nn.NoSize=Jr=new Nn(NaN,NaN).ja(),Nn.parse=ga,Nn.stringify=Qs;function Ye(a,y,x,b){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 b=="number"&&(0<=b||isNaN(b))?(this.x=a,this.y=y,this.width=x,this.height=b):a instanceof Gt?(x=a.x,a=a.y,y instanceof Gt?(b=y.x,y=y.y,this.x=Math.min(x,b),this.y=Math.min(a,y),this.width=Math.abs(x-b),this.height=Math.abs(a-y)):y instanceof Nn?(this.x=x,this.y=a,this.width=y.width,this.height=y.height):ce("Incorrect second argument supplied to Rect constructor "+y)):ce("Invalid arguments to Rect constructor: "+a+", "+y+", "+x+", "+b),this._isFrozen=!1}bt=Ye.prototype,bt.assign=function(a){return this.x=a.x,this.y=a.y,this.width=a.width,this.height=a.height,this},bt.h=function(a,y,x,b){return this.x=a,this.y=y,this.width=x,this.height=b,this};function Ws(a,y,x){a.width=y,a.height=x}bt.sg=function(a,y,x,b){return this.x=a,this.y=y,this.width=x,this.height=b,this},bt.set=function(a){return this.x=a.x,this.y=a.y,this.width=a.width,this.height=a.height,this},bt.dd=function(a){return this.x=a.x,this.y=a.y,this},bt.tA=function(a){return this.width=a.width,this.height=a.height,this},Ye.prototype.copy=function(){var a=new Ye;return a.x=this.x,a.y=this.y,a.width=this.width,a.height=this.height,a},bt=Ye.prototype,bt.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},bt.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},bt.freeze=function(){return this._isFrozen=!0,this},bt.ka=function(){return Object.isFrozen(this)&&ce("cannot thaw constant: "+this),this._isFrozen=!1,this};function gh(a){if(typeof a=="string"){a=a.split(" ");for(var y=0,x=0;a[y]==="";)y++;var b=a[y++];b&&(x=parseFloat(b));for(var E=0;a[y]==="";)y++;(b=a[y++])&&(E=parseFloat(b));for(var z=0;a[y]==="";)y++;(b=a[y++])&&(z=parseFloat(b));for(var tt=0;a[y]==="";)y++;return(b=a[y++])&&(tt=parseFloat(b)),new Ye(x,E,z,tt)}return new Ye}function kl(a){return a.x.toString()+" "+a.y.toString()+" "+a.width.toString()+" "+a.height.toString()}bt.toString=function(){return"Rect("+this.x+","+this.y+","+this.width+","+this.height+")"},bt.D=function(a){return a instanceof Ye?this.x===a.x&&this.y===a.y&&this.width===a.width&&this.height===a.height:!1},bt.hi=function(a,y,x,b){return this.x===a&&this.y===y&&this.width===x&&this.height===b},bt.Xa=function(a){return Ce.B(this.x,a.x)&&Ce.B(this.y,a.y)&&Ce.B(this.width,a.width)&&Ce.B(this.height,a.height)};function uu(a,y){return Ce.$(a.x,y.x)&&Ce.$(a.y,y.y)&&Ce.$(a.width,y.width)&&Ce.$(a.height,y.height)}bt.ca=function(a){return this.x<=a.x&&this.x+this.width>=a.x&&this.y<=a.y&&this.y+this.height>=a.y},bt.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},bt.contains=function(a,y,x,b){return x===void 0&&(x=0),b===void 0&&(b=0),this.x<=a&&a+x<=this.x+this.width&&this.y<=y&&y+b<=this.y+this.height},bt.offset=function(a,y){return this.x+=a,this.y+=y,this},bt.Bc=function(a,y){return ts(this,y,a,y,a)},bt.Co=function(a){return ts(this,a.top,a.right,a.bottom,a.left)},bt.Fv=function(a){return ts(this,-a.top,-a.right,-a.bottom,-a.left)},bt.Hz=function(a,y,x,b){return ts(this,a,y,x,b)};function ts(a,y,x,b,E){var z=a.width;return x+E<=-z?(a.x+=z/2,a.width=0):(a.x-=E,a.width+=x+E),x=a.height,y+b<=-x?(a.y+=x/2,a.height=0):(a.y-=y,a.height+=y+b),a}bt.Ex=function(a){return th(this,a.x,a.y,a.width,a.height)},bt.Uu=function(a,y,x,b){return th(this,a,y,x,b)};function th(a,y,x,b,E){var z=Math.max(a.x,y),tt=Math.max(a.y,x);return y=Math.min(a.x+a.width,y+b),x=Math.min(a.y+a.height,x+E),a.x=z,a.y=tt,a.width=Math.max(0,y-z),a.height=Math.max(0,x-tt),a}bt.Yc=function(a){return this.Vu(a.x,a.y,a.width,a.height)},bt.Vu=function(a,y,x,b){var E=this.width,z=this.x;return E!==1/0&&x!==1/0&&(E+=z,x+=a,isNaN(x)||isNaN(E)||z>x||a>E)?!1:(a=this.height,x=this.y,!(a!==1/0&&b!==1/0&&(a+=x,b+=y,isNaN(b)||isNaN(a)||x>b||y>a)))};function eh(a,y){var x=a.width,b=a.x,E=y.x-10;return b>y.width+10+10+E||E>x+b?!1:(x=a.height,a=a.y,b=y.y-10,!(a>y.height+10+10+b||b>x+a))}bt.Ye=function(a){return Gr(this,a.x,a.y,0,0)},bt.ed=function(a){return Gr(this,a.x,a.y,a.width,a.height)},bt.Kv=function(a,y,x,b){return x===void 0&&(x=0),b===void 0&&(b=0),Gr(this,a,y,x,b)};function Gr(a,y,x,b,E){var z=Math.min(a.x,y),tt=Math.min(a.y,x);return y=Math.max(a.x+a.width,y+b),x=Math.max(a.y+a.height,x+E),a.x=z,a.y=tt,a.width=y-z,a.height=x-tt,a}bt.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 Ts(a,y,x,b,E,z,tt,ot){return tt===void 0&&(tt=0),ot===void 0&&(ot=0),a<=E&&E+tt<=a+x&&y<=z&&z+ot<=y+b}function Ul(a,y,x,b,E,z,tt,ot){return a>tt+E||E>x+a?!1:!(y>ot+z||z>b+y)}bt.w=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},bt.Mz=function(){return this.width===0&&this.height===0},Ye.alloc=function(){var a=Zo.pop();return a===void 0?new Ye:a},Ye.allocAt=function(a,y,x,b){var E=Zo.pop();return E===void 0?new Ye(a,y,x,b):E.h(a,y,x,b)},Ye.free=function(a){Zo.push(a)},Jt.Object.defineProperties(Ye.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 Gt(this.x,this.y)},set:function(a){this.x=a.x,this.y=a.y}},size:{get:function(){return new Nn(this.width,this.height)},set:function(a){this.width=a.width,this.height=a.height}},center:{get:function(){return new Gt(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}}}),Ye.prototype.isEmpty=Ye.prototype.Mz,Ye.prototype.isReal=Ye.prototype.w,Ye.intersectsLineSegment=function(a,y,x,b,E,z,tt,ot){return Ce.Fx(a,y,x,b,E,z,tt,ot)},Ye.prototype.setSpot=Ye.prototype.yi,Ye.prototype.union=Ye.prototype.Kv,Ye.prototype.unionRect=Ye.prototype.ed,Ye.prototype.unionPoint=Ye.prototype.Ye,Ye.prototype.intersects=Ye.prototype.Vu,Ye.prototype.intersectsRect=Ye.prototype.Yc,Ye.prototype.intersect=Ye.prototype.Uu,Ye.prototype.intersectRect=Ye.prototype.Ex,Ye.prototype.grow=Ye.prototype.Hz,Ye.prototype.subtractMargin=Ye.prototype.Fv,Ye.prototype.addMargin=Ye.prototype.Co,Ye.prototype.inflate=Ye.prototype.Bc,Ye.prototype.offset=Ye.prototype.offset,Ye.prototype.contains=Ye.prototype.contains,Ye.prototype.containsRect=Ye.prototype.Re,Ye.prototype.containsPoint=Ye.prototype.ca,Ye.prototype.equalsApprox=Ye.prototype.Xa,Ye.prototype.equalTo=Ye.prototype.hi,Ye.prototype.equals=Ye.prototype.D,Ye.prototype.setSize=Ye.prototype.tA,Ye.prototype.setPoint=Ye.prototype.dd,Ye.prototype.set=Ye.prototype.set,Ye.prototype.setTo=Ye.prototype.sg;var lo=null,hr=null,Zo=[];Ye.className="Rect",Ye.parse=gh,Ye.stringify=kl,Ye.contains=Ts,Ye.intersects=Ul,Ye.ZeroRect=lo=new Ye(0,0,0,0).ja(),Ye.NoRect=hr=new Ye(NaN,NaN,NaN,NaN).ja(),Ye.parse=gh,Ye.stringify=kl,Ye.contains=Ts,Ye.intersects=Ul;function ci(a,y,x,b){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):b!==void 0?(this.top=a,this.right=y,this.bottom=x,this.left=b):ce("Invalid arguments to Margin constructor: "+a+", "+y+", "+x+", "+b),this._isFrozen=!1}ci.prototype.assign=function(a){return this.top=a.top,this.right=a.right,this.bottom=a.bottom,this.left=a.left,this},ci.prototype.sg=function(a,y,x,b){return this.top=a,this.right=y,this.bottom=x,this.left=b,this},ci.prototype.set=function(a){return this.top=a.top,this.right=a.right,this.bottom=a.bottom,this.left=a.left,this},ci.prototype.copy=function(){var a=new ci;return a.top=this.top,a.right=this.right,a.bottom=this.bottom,a.left=this.left,a},bt=ci.prototype,bt.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},bt.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},bt.freeze=function(){return this._isFrozen=!0,this},bt.ka=function(){return Object.isFrozen(this)&&ce("cannot thaw constant: "+this),this._isFrozen=!1,this};function Os(a){if(typeof a=="string"){a=a.split(" ");for(var y=0,x=NaN;a[y]==="";)y++;var b=a[y++];if(b&&(x=parseFloat(b)),isNaN(x))return new ci;for(var E=NaN;a[y]==="";)y++;if((b=a[y++])&&(E=parseFloat(b)),isNaN(E))return new ci(x);for(var z=NaN;a[y]==="";)y++;if((b=a[y++])&&(z=parseFloat(b)),isNaN(z))return new ci(x,E);for(var tt=NaN;a[y]==="";)y++;return(b=a[y++])&&(tt=parseFloat(b)),isNaN(tt)?new ci(x,E):new ci(x,E,z,tt)}return new ci}function Fs(a){return a.top.toString()+" "+a.right.toString()+" "+a.bottom.toString()+" "+a.left.toString()}bt.toString=function(){return"Margin("+this.top+","+this.right+","+this.bottom+","+this.left+")"},bt.D=function(a){return a instanceof ci?this.top===a.top&&this.right===a.right&&this.bottom===a.bottom&&this.left===a.left:!1},bt.hi=function(a,y,x,b){return this.top===a&&this.right===y&&this.bottom===x&&this.left===b},bt.Xa=function(a){return Ce.B(this.top,a.top)&&Ce.B(this.right,a.right)&&Ce.B(this.bottom,a.bottom)&&Ce.B(this.left,a.left)},bt.w=function(){return isFinite(this.top)&&isFinite(this.right)&&isFinite(this.bottom)&&isFinite(this.left)},ci.alloc=function(){var a=Yl.pop();return a===void 0?new ci:a},ci.free=function(a){Yl.push(a)},ci.prototype.isReal=ci.prototype.w,ci.prototype.equalsApprox=ci.prototype.Xa,ci.prototype.equalTo=ci.prototype.hi,ci.prototype.equals=ci.prototype.D,ci.prototype.set=ci.prototype.set,ci.prototype.setTo=ci.prototype.sg;var Sa=null,Nl=null,Yl=[];ci.className="Margin",ci.parse=Os,ci.stringify=Fs,ci.ZeroMargin=Sa=new ci(0,0,0,0).ja(),ci.TwoMargin=Nl=new ci(2,2,2,2).ja(),ci.parse=Os,ci.stringify=Fs;function ei(a,y,x,b){a===void 0?this.offsetY=this.offsetX=this.y=this.x=0:(y===void 0&&(y=0),x===void 0&&(x=0),b===void 0&&(b=0),this.x=a,this.y=y,this.offsetX=x,this.offsetY=b),this._isFrozen=!1}var Qr,js,vl,Tl,Ol,Co,ph,Xa,_a,ka,Pu,Bu,Da,sl,Hh,hd,Gh,$d,$h,mh,Du,Fl,dd,Wh,vh,Wo,Cr,xa,Ks,Is,is,vs,Hs,Bs,Au,Il;ei.prototype.assign=function(a){return this.x=a.x,this.y=a.y,this.offsetX=a.offsetX,this.offsetY=a.offsetY,this},ei.prototype.sg=function(a,y,x,b){return this.x=a,this.y=y,this.offsetX=x,this.offsetY=b,this},ei.prototype.set=function(a){return this.x=a.x,this.y=a.y,this.offsetX=a.offsetX,this.offsetY=a.offsetY,this},ei.prototype.copy=function(){var a=new ei;return a.x=this.x,a.y=this.y,a.offsetX=this.offsetX,a.offsetY=this.offsetY,a},bt=ei.prototype,bt.ja=function(){return this._isFrozen=!0,Object.freeze(this),this},bt.J=function(){return this._isFrozen||Object.isFrozen(this)?this:this.copy().freeze()},bt.freeze=function(){return this._isFrozen=!0,this},bt.ka=function(){return Object.isFrozen(this)&&ce("cannot thaw constant: "+this),this._isFrozen=!1,this};function xs(a,y){return a.x=NaN,a.y=NaN,a.offsetX=y,a}function xc(a){if(typeof a=="string"){if(a=a.trim(),a==="None")return Qr;if(a==="TopLeft")return js;if(a==="Top"||a==="TopCenter"||a==="MiddleTop")return vl;if(a==="TopRight")return Tl;if(a==="Left"||a==="LeftCenter"||a==="MiddleLeft")return Ol;if(a==="Center")return Co;if(a==="Right"||a==="RightCenter"||a==="MiddleRight")return ph;if(a==="BottomLeft")return Xa;if(a==="Bottom"||a==="BottomCenter"||a==="MiddleBottom")return _a;if(a==="BottomRight")return ka;if(a==="TopSide")return Pu;if(a==="LeftSide")return Bu;if(a==="RightSide")return Da;if(a==="BottomSide")return sl;if(a==="TopBottomSides")return Hh;if(a==="LeftRightSides")return hd;if(a==="TopLeftSides")return Gh;if(a==="TopRightSides")return $d;if(a==="BottomLeftSides")return $h;if(a==="BottomRightSides")return mh;if(a==="NotTopSide")return Du;if(a==="NotLeftSide")return Fl;if(a==="NotRightSide")return dd;if(a==="NotBottomSide")return Wh;if(a==="AllSides")return vh;if(a==="Default")return Wo;a=a.split(" ");for(var y=0,x=0;a[y]==="";)y++;var b=a[y++];b!==void 0&&0a&&(a+=360),a===0)return this;if(this.translate(y,x),a===90){a=0;var b=1}else a===180?(a=-1,b=0):a===270?(a=0,b=-1):(b=a*Math.PI/180,a=Math.cos(b),b=Math.sin(b));var E=this.m12*a+this.m22*b,z=this.m11*-b+this.m21*a,tt=this.m12*-b+this.m22*a;return this.m11=this.m11*a+this.m21*b,this.m12=E,this.m21=z,this.m22=tt,this.translate(-y,-x),this},bt=Yi.prototype,bt.translate=function(a,y){return this.dx+=this.m11*a+this.m21*y,this.dy+=this.m12*a+this.m22*y,this},bt.scale=function(a,y){return y===void 0&&(y=a),this.m11*=a,this.m12*=a,this.m21*=y,this.m22*=y,this},bt.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)},bt.Cd=function(a){var y=1/(this.m11*this.m22-this.m12*this.m21),x=a.x,b=a.y;return a.h(x*this.m22*y+b*-this.m21*y+y*(this.m21*this.dy-this.m22*this.dx),x*-this.m12*y+b*this.m11*y+y*(this.m12*this.dx-this.m11*this.dy))},bt.Eu=function(a){var y=1/(this.m11*this.m22-this.m12*this.m21),x=1.25*a.x,b=1.2*a.y;return a.h(x*this.m22*y+b*-this.m21*y+y*(this.m21*this.dy-this.m22*this.dx),x*-this.m12*y+b*this.m11*y+y*(this.m12*this.dx-this.m11*this.dy))},bt.pp=function(a){var y=a.x,x=a.y,b=y+a.width,E=x+a.height,z=this.m11,tt=this.m12,ot=this.m21,rt=this.m22,lt=this.dx,ut=this.dy,ft=y*z+x*ot+lt,vt=y*tt+x*rt+ut,xt=b*z+x*ot+lt,Ct=b*tt+x*rt+ut;return x=y*z+E*ot+lt,y=y*tt+E*rt+ut,z=b*z+E*ot+lt,b=b*tt+E*rt+ut,E=Math.min(ft,xt),ft=Math.max(ft,xt),xt=Math.min(vt,Ct),vt=Math.max(vt,Ct),E=Math.min(E,x),ft=Math.max(ft,x),xt=Math.min(xt,y),vt=Math.max(vt,y),E=Math.min(E,z),ft=Math.max(ft,z),xt=Math.min(xt,b),vt=Math.max(vt,b),a.h(E,xt,ft-E,vt-xt),a},Yi.alloc=function(){var a=cd.pop();return a===void 0?new Yi:a},Yi.free=function(a){cd.push(a)},Yi.prototype.transformRect=Yi.prototype.pp,Yi.prototype.transformPoint=Yi.prototype.Ga,Yi.prototype.scale=Yi.prototype.scale,Yi.prototype.translate=Yi.prototype.translate,Yi.prototype.rotate=Yi.prototype.rotate,Yi.prototype.invert=Yi.prototype.Vj,Yi.prototype.multiplyInverted=Yi.prototype.bv,Yi.prototype.multiply=Yi.prototype.multiply,Yi.prototype.reset=Yi.prototype.reset,Yi.prototype.isIdentity=Yi.prototype.ws,Yi.prototype.equals=Yi.prototype.D,Yi.prototype.setTransform=Yi.prototype.setTransform,Yi.prototype.set=Yi.prototype.set;var cd=[];Yi.className="Transform",Yi.xF="54a702f3e53909c447824c6706603faf4c";var Ce={AA:"7da71ca0ad381e90",wg:(Math.sqrt(2)-1)/3*4,Uv:null,sqrt:function(a){if(0>=a)return 0;var y=Ce.Uv;if(y===null){y=[];for(var x=0;2e3>=x;x++)y[x]=Math.sqrt(x);Ce.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&&-.5a&&-5e-8=E&&(E=1e-6),aut-lt)if(a-x>E||x-a>E){if(z=(b-y)/(x-a)*(z-a)+y,z-E<=tt&&tt<=z+E)return!0}else return!0;else if(y-b>E||b-y>E){if(tt=(x-a)/(b-y)*(tt-y)+a,tt-E<=z&&z<=tt+E)return!0}else return!0;return!1},cs:function(a,y,x,b,E,z,tt,ot,rt,lt,ut,ft){if(Ce.Yb(a,y,tt,ot,ft,x,b)&&Ce.Yb(a,y,tt,ot,ft,E,z))return Ce.Yb(a,y,tt,ot,ft,lt,ut);var vt=(a+x)/2,xt=(y+b)/2,Ct=(x+E)/2,Ot=(b+z)/2;E=(E+tt)/2,z=(z+ot)/2,b=(vt+Ct)/2,x=(xt+Ot)/2,Ct=(Ct+E)/2,Ot=(Ot+z)/2;var Kt=(b+Ct)/2,zt=(x+Ot)/2;return Ce.cs(a,y,vt,xt,b,x,Kt,zt,rt,lt,ut,ft)||Ce.cs(Kt,zt,Ct,Ot,E,z,tt,ot,rt,lt,ut,ft)},ax:function(a,y,x,b,E,z,tt,ot,rt){var lt=(x+E)/2,ut=(b+z)/2;return rt.h((((a+x)/2+lt)/2+(lt+(E+tt)/2)/2)/2,(((y+b)/2+ut)/2+(ut+(z+ot)/2)/2)/2),rt},My:function(a,y,x,b,E,z,tt,ot){var rt=(x+E)/2,lt=(b+z)/2;return qi(((a+x)/2+rt)/2,((y+b)/2+lt)/2,(rt+(E+tt)/2)/2,(lt+(z+ot)/2)/2)},Dl:function(a,y,x,b,E,z,tt,ot,rt,lt){if(Ce.Yb(a,y,tt,ot,rt,x,b)&&Ce.Yb(a,y,tt,ot,rt,E,z))Gr(lt,a,y,0,0),Gr(lt,tt,ot,0,0);else{var ut=(a+x)/2,ft=(y+b)/2,vt=(x+E)/2,xt=(b+z)/2;E=(E+tt)/2,z=(z+ot)/2,b=(ut+vt)/2,x=(ft+xt)/2,vt=(vt+E)/2,xt=(xt+z)/2;var Ct=(b+vt)/2,Ot=(x+xt)/2;Ce.Dl(a,y,ut,ft,b,x,Ct,Ot,rt,lt),Ce.Dl(Ct,Ot,vt,xt,E,z,tt,ot,rt,lt)}return lt},Qe:function(a,y,x,b,E,z,tt,ot,rt,lt){if(Ce.Yb(a,y,tt,ot,rt,x,b)&&Ce.Yb(a,y,tt,ot,rt,E,z))lt.length===0&&(lt.push(a),lt.push(y)),lt.push(tt),lt.push(ot);else{var ut=(a+x)/2,ft=(y+b)/2,vt=(x+E)/2,xt=(b+z)/2;E=(E+tt)/2,z=(z+ot)/2,b=(ut+vt)/2,x=(ft+xt)/2,vt=(vt+E)/2,xt=(xt+z)/2;var Ct=(b+vt)/2,Ot=(x+xt)/2;Ce.Qe(a,y,ut,ft,b,x,Ct,Ot,rt,lt),Ce.Qe(Ct,Ot,vt,xt,E,z,tt,ot,rt,lt)}return lt},jv:function(a,y,x,b,E,z,tt,ot,rt,lt){if(Ce.Yb(a,y,E,z,lt,x,b))return Ce.Yb(a,y,E,z,lt,ot,rt);var ut=(a+x)/2,ft=(y+b)/2;x=(x+E)/2,b=(b+z)/2;var vt=(ut+x)/2,xt=(ft+b)/2;return Ce.jv(a,y,ut,ft,vt,xt,tt,ot,rt,lt)||Ce.jv(vt,xt,x,b,E,z,tt,ot,rt,lt)},OA:function(a,y,x,b,E,z,tt){return tt.h(((a+x)/2+(x+E)/2)/2,((y+b)/2+(b+z)/2)/2),tt},iv:function(a,y,x,b,E,z,tt,ot){if(Ce.Yb(a,y,E,z,tt,x,b))Gr(ot,a,y,0,0),Gr(ot,E,z,0,0);else{var rt=(a+x)/2,lt=(y+b)/2;x=(x+E)/2,b=(b+z)/2;var ut=(rt+x)/2,ft=(lt+b)/2;Ce.iv(a,y,rt,lt,ut,ft,tt,ot),Ce.iv(ut,ft,x,b,E,z,tt,ot)}return ot},ep:function(a,y,x,b,E,z,tt,ot){if(Ce.Yb(a,y,E,z,tt,x,b))ot.length===0&&(ot.push(a),ot.push(y)),ot.push(E),ot.push(z);else{var rt=(a+x)/2,lt=(y+b)/2;x=(x+E)/2,b=(b+z)/2;var ut=(rt+x)/2,ft=(lt+b)/2;Ce.ep(a,y,rt,lt,ut,ft,tt,ot),Ce.ep(ut,ft,x,b,E,z,tt,ot)}return ot},Eo:function(a,y,x,b,E,z,tt,ot,rt,lt,ut,ft,vt,xt){if(Ce.Yb(a,y,tt,ot,vt,x,b)&&Ce.Yb(a,y,tt,ot,vt,E,z))return!Ce.Rl(a,y,tt,ot,rt,lt,ut,ft)||(vt=(a-tt)*(lt-ft)-(y-ot)*(rt-ut),vt===0)?!1:(xt.h(((a*ot-y*tt)*(rt-ut)-(a-tt)*(rt*ft-lt*ut))/vt,((a*ot-y*tt)*(lt-ft)-(y-ot)*(rt*ft-lt*ut))/vt),!0);var Ct=(a+x)/2,Ot=(y+b)/2,Kt=(x+E)/2,zt=(b+z)/2;E=(E+tt)/2,z=(z+ot)/2,b=(Ct+Kt)/2,x=(Ot+zt)/2,Kt=(Kt+E)/2,zt=(zt+z)/2;var te=(b+Kt)/2,re=(x+zt)/2,he=1/0,ve=!1,De=0,Fn=0;return Ce.Eo(a,y,Ct,Ot,b,x,te,re,rt,lt,ut,ft,vt,xt)&&(a=(xt.x-rt)*(xt.x-rt)+(xt.y-lt)*(xt.y-lt),a=ut)return xt;if((rt>ut?rt-ut:ut-rt)<(lt>ft?lt-ft:ft-lt)){if(ya)return xt}else if(aa)return xt;0vt&&xt--}else{Ct=(a+x)/2,Ot=(y+b)/2;var Kt=(x+E)/2,zt=(b+z)/2;E=(E+tt)/2,z=(z+ot)/2,b=(Ct+Kt)/2,x=(Ot+zt)/2,Kt=(Kt+E)/2,zt=(zt+z)/2;var te=(b+Kt)/2,re=(x+zt)/2;xt+=Ce.Fo(a,y,Ct,Ot,b,x,te,re,rt,lt,ut,ft,vt),xt+=Ce.Fo(te,re,Kt,zt,E,z,tt,ot,rt,lt,ut,ft,vt)}return xt},qh:function(a,y,x,b,E,z,tt){return Ce.$(a,x)?(yy?(tt.h(a,y),!1):(tt.h(a,z),!0)):Ce.$(y,b)?(aa?(tt.h(a,y),!1):(tt.h(E,y),!0)):(E=((a-E)*(a-x)+(y-z)*(y-b))/((x-a)*(x-a)+(b-y)*(b-y)),-5e-6>E?(tt.h(a,y),!1):1.000005y?(rt.h(a,y),!1):(rt.h(a,x),!0)):(tt=(b-y)/(x-a),Ce.$(ot,tt)?(Ce.qh(a,y,x,b,E,z,rt),!1):(E=(tt*a-ot*E+z-y)/(tt-ot),Ce.$(tt,0)?(aa?(rt.h(a,y),!1):(rt.h(E,y),!0)):Ce.qh(a,y,x,b,E,tt*(E-a)+y,rt))))},MA:function(a,y,x,b,E){return Ce.Ve(x.x,x.y,b.x,b.y,a.x,a.y,y.x,y.y,E)},KA:function(a,y,x,b,E,z,tt,ot,rt,lt){function ut(Kt,zt){var te=(Kt-a)*(Kt-a)+(zt-y)*(zt-y);te(x>a?x-a:a-x)){if(vt=1-(x-E)*(x-E)/(vt*vt),0>vt)return rt;vt=Math.sqrt(vt),b=-lt*vt+z,ut(x,lt*vt+z),ut(x,b)}else{if(x=(b-y)/(x-a),b=1/(vt*vt)+x*x/(lt*lt),ot=2*x*(y-x*a)/(lt*lt)-2*x*z/(lt*lt)-2*E/(vt*vt),vt=ot*ot-4*b*(2*x*a*z/(lt*lt)-2*y*z/(lt*lt)+z*z/(lt*lt)+E*E/(vt*vt)-1+(y-x*a)*(y-x*a)/(lt*lt)),0>vt)return rt;vt=Math.sqrt(vt),lt=(-ot+vt)/(2*b),ut(lt,x*lt-x*a+y),vt=(-ot-vt)/(2*b),ut(vt,x*vt-x*a+y)}return rt},Ff:function(a,y,x,b,E,z,tt,ot,rt){var lt=1e21,ut=a,ft=y;if(Ce.Ve(a,y,a,b,E,z,tt,ot,rt)){var vt=(rt.x-E)*(rt.x-E)+(rt.y-z)*(rt.y-z);vtlt},us:function(a,y,x){return Ce.Fx(a.x,a.y,a.width,a.height,y.x,y.y,x.x,x.y)},Fx:function(a,y,x,b,E,z,tt,ot){var rt=a+x,lt=y+b;return E===tt?(z=y):z===ot?(E=a):!!(Ts(a,y,x,b,E,z)||Ts(a,y,x,b,tt,ot)||Ce.Rl(a,y,rt,y,E,z,tt,ot)||Ce.Rl(rt,y,rt,lt,E,z,tt,ot)||Ce.Rl(rt,lt,a,lt,E,z,tt,ot)||Ce.Rl(a,lt,a,y,E,z,tt,ot))},Rl:function(a,y,x,b,E,z,tt,ot){return a===x&&y===b&&E===tt&&z===ot?a===E&&y===z:0>=Ce.Fl(a,y,x,b,E,z)*Ce.Fl(a,y,x,b,tt,ot)&&0>=Ce.Fl(E,z,tt,ot,a,y)*Ce.Fl(E,z,tt,ot,x,b)},Fl:function(a,y,x,b,E,z){return x-=a,b-=y,a=E-a,y=z-y,z=a*b-y*x,z===0&&(z=a*x+y*b,0z&&(z=0))),z},bp:function(a){return 0>a&&(a+=360),360<=a&&(a-=360),a},jx:function(a,y,x,b,E,z){var tt=Math.PI;z||(b*=tt/180,E*=tt/180);var ot=b>E?-1:1;z=[];var rt=tt/2,lt=b;if(b=Math.min(2*tt,Math.abs(E-b)),1e-5>b)return rt=lt+ot*Math.min(b,rt),ot=a+x*Math.cos(lt),lt=y+x*Math.sin(lt),a+=x*Math.cos(rt),y+=x*Math.sin(rt),x=(ot+a)/2,rt=(lt+y)/2,z.push([ot,lt,x,rt,x,rt,a,y]),z;for(;1e-5x,z=0>b;if(alt&&(y=.5*(ot+rt),!(y===ot||y===rt));++lt){var ut=a/(y+E),ft=tt/(y+z);if(ut=ut*ut+ft*ft-1,0ut)rt=y;else break}x=E*x/(y+E)-x,b=z*b/(y+z)-b,x=Math.sqrt(x*x+b*b)}else x=Math.abs(b-y);else b=a*a-y*y,z=a*x,za?"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 kn.u:var y=new Ye(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 kn.F:if(y=new Ye(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 kn.o:y="",x=this.figures.s;for(var b=x.length,E=0;E=he-1?!0:lt[Ot+1].match(ve)!==null}function b(){return Ot++,lt[Ot]}function E(Ti){var Li=parseFloat(b()),Ro=parseFloat(b());Kt===Kt.toLowerCase()&&(Li=re.x+Li,Ro=re.y+Ro),Ti.h(Li,Ro)}function z(){return E(re),re}function tt(){return E(te),te}function ot(){var Ti=zt.toLowerCase();return Ti!=="c"&&Ti!=="s"&&Ti!=="q"&&Ti!=="t"?re:new Gt(2*re.x-te.x,2*re.y-te.y)}y===void 0&&(y=!1);var rt=/([UuBbMmZzLlHhVvCcSsQqTtAaFfXx])([UuBbMmZzLlHhVvCcSsQqTtAaFfXx])/gm;a=a.replace(/,/gm," "),a=a.replace(rt,"$1 $2"),a=a.replace(rt,"$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 lt=a.split(" ");for(a=0;a=he-1);)if(zt=Kt,Kt=b(),Kt!=="")switch(Kt.toUpperCase()){case"X":xt=!0,ft=ut=!1;break;case"M":for(Ct=z(),a.mc===null||xt===!0?(vg(a,Ct.x,Ct.y,ut,!ft,vt),xt=!1):a.moveTo(Ct.x,Ct.y),rt.assign(re);!x();)Ct=z(),a.lineTo(Ct.x,Ct.y);break;case"L":for(;!x();)Ct=z(),a.lineTo(Ct.x,Ct.y);break;case"H":for(;!x();)re=new Gt((Kt===Kt.toLowerCase()?re.x:0)+parseFloat(b()),re.y),a.lineTo(re.x,re.y);break;case"V":for(;!x();)re=new Gt(re.x,(Kt===Kt.toLowerCase()?re.y:0)+parseFloat(b())),a.lineTo(re.x,re.y);break;case"C":for(;!x();){Ct=new Gt,E(Ct);var De=tt(),Fn=z();bd(a,Ct.x,Ct.y,De.x,De.y,Fn.x,Fn.y)}break;case"S":for(;!x();)Ct=ot(),De=tt(),Fn=z(),bd(a,Ct.x,Ct.y,De.x,De.y,Fn.x,Fn.y);break;case"Q":for(;!x();)Ct=tt(),De=z(),Gm(a,Ct.x,Ct.y,De.x,De.y);break;case"T":for(;!x();)te=Ct=ot(),De=z(),Gm(a,Ct.x,Ct.y,De.x,De.y);break;case"B":for(;!x();){Ct=parseFloat(b()),De=parseFloat(b()),Fn=parseFloat(b());var Vn=parseFloat(b()),Wn=parseFloat(b()),bn=Wn,an=!1;x()||(bn=parseFloat(b()),x()||(an=parseFloat(b())!==0)),Kt===Kt.toLowerCase()&&(Fn+=re.x,Vn+=re.y),a.arcTo(Ct,De,Fn,Vn,Wn,bn,an)}break;case"A":for(;!x();)Ct=Math.abs(parseFloat(b())),De=Math.abs(parseFloat(b())),Fn=parseFloat(b()),Wn=Vn=!1,an=bn=0,bn=b(),bn.length===1?(Vn=!!parseFloat(bn),Wn=!!parseFloat(b()),bn=parseFloat(b())):bn.length===2?(Vn=!!parseFloat(bn[0]),Wn=!!parseFloat(bn[1]),bn=parseFloat(b())):(Vn=!!parseFloat(bn[0]),Wn=!!parseFloat(bn[1]),bn=parseFloat(bn.slice(2))),an=parseFloat(b()),Kt===Kt.toLowerCase()&&(bn=re.x+bn,an=re.y+an),re.h(bn,an),wx(a,Ct,De,Fn,Vn,Wn,bn,an);break;case"Z":Px(a),re.assign(rt);break;case"F":for(Ct="",De=1;lt[Ot+De];)if(lt[Ot+De]==="0")vt=!0,De++;else if(lt[Ot+De].match(/[Uu]/)!==null)De++;else if(lt[Ot+De].match(ve)===null)De++;else{Ct=lt[Ot+De];break}Ct.match(/[Mm]/)?ut=!0:0tt&&(tt+=360),Ct.startAngle+=tt),0>a&&(Ct.startAngle=180-Ct.startAngle,Ct.sweepAngle=-Ct.sweepAngle),0>b&&(Ct.startAngle=-Ct.startAngle,Ct.sweepAngle=-Ct.sweepAngle),Ct.radiusX*=Math.sqrt(a*a+x*x),Ct.radiusY!==void 0&&(Ct.radiusY*=Math.sqrt(y*y+b*b));break;case Bl:if(tt=Ct.endX,ot=Ct.endY,Ct.endX=tt*a+ot*x+E,Ct.endY=tt*y+ot*b+z,Ct.radiusX===0||Ct.radiusY===0)break;y!==0&&(tt=180*Math.atan2(y,a)/Math.PI,0>tt&&(tt+=360),Ct.xAxisRotation+=tt),0>a&&(Ct.xAxisRotation=180-Ct.xAxisRotation,Ct.isClockwiseArc=!Ct.isClockwiseArc),0>b&&(Ct.xAxisRotation=-Ct.xAxisRotation,Ct.isClockwiseArc=!Ct.isClockwiseArc),Ct.radiusX*=Math.sqrt(a*a+x*x),Ct.radiusY*=Math.sqrt(y*y+b*b);break;default:ce("Unknown Segment type: "+Ct.type)}}}}return this._isInvalidBounds=!0,this},bt.ca=function(a,y){y===void 0&&(y=0);var x=this.od,b=this.pd,E=this.Dc,z=this.Ec;switch(this.type){case kn.j:return Ce.Yb(x,b,E,z,y,a.x,a.y);case kn.u:var tt=Ye.allocAt(Math.min(x,E)-y,Math.min(b,z)-y,Math.abs(E-x)+2*y,Math.abs(z-b)+2*y);return a=tt.ca(a),Ye.free(tt),a;case kn.F:tt=Math.min(x,E)-y;var ot=Math.min(b,z)-y;return x=(Math.abs(E-x)+2*y)/2,y=(Math.abs(z-b)+2*y)/2,0>=x||0>=y?!1:(tt=a.x-(tt+x),ot=a.y-(ot+y),1>=tt*tt/(x*x)+ot*ot/(y*y));case kn.o:return Ru(this,a,y,!0,!1);default:return!1}};function Ru(a,y,x,b,E){var z=y.x;y=y.y;for(var tt=a.bounds.x-20,ot=0,rt,lt,ut,ft,vt=a.figures.s,xt=vt.length,Ct=0;Ct=a)return 0;if((E>tt?E-tt:tt-E)<(z>ot?z-ot:ot-z)){if(zot)return 0}else if(yz)return 0}else if(Ett)return 0}else if(ltE)return 0;return 0a?a=0:1=z)return b=z-tt,b=ut===0?0:b/ut,x=x[ot],ot=x[2*a],E=x[2*a+1],y.h(ot+(x[2*a+2]-ot)*b,E+(x[2*a+3]-E)*b),y;tt+=ut}}return y},bt.wx=function(a){if(0>a?a=0:1=E)return E=y[tt],y=E[2*a],x=E[2*a+1],b=E[2*a+2],a=E[2*a+3],1>Math.abs(b-y)&&1>Math.abs(a-x)?0:1>Math.abs(b-y)?0<=a-x?90:270:1>Math.abs(a-x)?0<=b-y?0:180:180*Math.atan2(a-x,b-y)/Math.PI;z+=lt}}return NaN},bt.Qu=function(a,y){if(0>a?a=0:1=z)return b=z-tt,b=ut===0?0:b/ut,ut=x[ot],x=ut[2*a],ot=ut[2*a+1],E=ut[2*a+2],a=ut[2*a+3],y[0]=x+(E-x)*b,y[1]=ot+(a-ot)*b,y[2]=1>Math.abs(E-x)&&1>Math.abs(a-ot)?0:1>Math.abs(E-x)?0<=a-ot?90:270:1>Math.abs(a-ot)?0<=E-x?0:180:180*Math.atan2(a-ot,E-x)/Math.PI,y;tt+=ut}}return y},bt.xx=function(a){if(this.type===kn.j){var y=this.startX,x=this.startY,b=this.endX,E=this.endY;if(y!==b||x!==E){var z=a.x;if(a=a.y,y===b){if(x=b?b===x?0:1:Math.abs(a-x)/(b-tt)}if(x===E)return y=b?b===y?0:1:Math.abs(z-y)/(b-tt);tt=(b-y)*(b-y)+(E-x)*(E-x);var ot=Gt.alloc();return Ce.qh(y,x,b,E,z,a,ot),a=ot.x,z=ot.y,Gt.free(ot),Math.sqrt(((a-y)*(a-y)+(z-x)*(z-x))/tt)}}else if(this.type===kn.u){tt=this.startX,ot=this.startY;var rt=this.endX;if(E=this.endY,tt!==rt||ot!==E){y=rt-tt,x=E-ot,z=2*y+2*x,b=a.x,a=a.y,b=Math.min(Math.max(b,tt),rt),a=Math.min(Math.max(a,ot),E),tt=Math.abs(b-tt),rt=Math.abs(b-rt),ot=Math.abs(a-ot),E=Math.abs(a-E);var lt=Math.min(tt,rt,ot,E);if(lt===ot)return b/z;if(lt===rt)return(y+a)/z;if(lt===E)return(2*y+x-b)/z;if(lt===tt)return(2*y+2*x-a)/z}}else{y=this.flattenedSegments,x=this.flattenedLengths,z=this.flattenedTotalLength,b=Gt.alloc(),E=1/0,ot=tt=0,rt=y.length;for(var ut=lt=0,ft=0;fta?0:1a?"M"+this.startX.toString()+" "+this.startY.toString():"M"+this.startX.toFixed(a)+" "+this.startY.toFixed(a),x=this.segments.s,b=x.length,E=0;Ea&&(a+=360),this.Ne=a,this.Vh=0,this.Wh=Math.max(b,0),this.Pg=Math.max(E,0),typeof tt=="boolean"?tt&&(this.isLargeArc=!0):typeof tt=="number"&&tt&&(this.isLargeArc=!0),ot&&(this.isClockwiseArc=!0)):(this.Ne=b,this.Vh=E,a===os&&(z=Math.max(z,0)),this.Wh=z,typeof tt=="number"?(a===os&&(tt=Math.max(tt,0)),this.Pg=tt):this.Pg=0),this.ae=null}No.prototype.copy=function(){var a=new No;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},bt=No.prototype,bt.Xa=function(a){if(!(a instanceof No)||this.type!==a.type||this.isClosed!==a.isClosed)return!1;switch(this.type){case ls:case cr:return Ce.B(this.endX,a.endX)&&Ce.B(this.endY,a.endY);case na:return Ce.B(this.endX,a.endX)&&Ce.B(this.endY,a.endY)&&Ce.B(this.point1X,a.point1X)&&Ce.B(this.point1Y,a.point1Y)&&Ce.B(this.point2X,a.point2X)&&Ce.B(this.point2Y,a.point2Y);case yl:return Ce.B(this.endX,a.endX)&&Ce.B(this.endY,a.endY)&&Ce.B(this.point1X,a.point1X)&&Ce.B(this.point1Y,a.point1Y);case os:return Ce.B(this.startAngle,a.startAngle)&&Ce.B(this.sweepAngle,a.sweepAngle)&&Ce.B(this.centerX,a.centerX)&&Ce.B(this.centerY,a.centerY)&&Ce.B(this.radiusX,a.radiusX)&&Ce.B(this.radiusY,a.radiusY);case Bl:return this.isClockwiseArc===a.isClockwiseArc&&this.isLargeArc===a.isLargeArc&&Ce.B(this.xAxisRotation,a.xAxisRotation)&&Ce.B(this.endX,a.endX)&&Ce.B(this.endY,a.endY)&&Ce.B(this.radiusX,a.radiusX)&&Ce.B(this.radiusY,a.radiusY);default:return!1}},bt.qb=function(a){a.classType===No&&(this.type=a)},bt.toString=function(a){switch(a===void 0&&(a=-1),this.type){case ls:a=0>a?"M"+this.endX.toString()+" "+this.endY.toString():"M"+this.endX.toFixed(a)+" "+this.endY.toFixed(a);break;case cr:a=0>a?"L"+this.endX.toString()+" "+this.endY.toString():"L"+this.endX.toFixed(a)+" "+this.endY.toFixed(a);break;case na: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 yl: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 os: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 Bl: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":"")},bt.freeze=function(){return this._isFrozen=!0,this},bt.ka=function(){return this._isFrozen=!1,this},bt.close=function(){return this.isClosed=!0,this};function Ja(a,y){if(a.ae!==null&&y._isInvalidBounds===!1)return a.ae;var x=a.radiusX,b=a.radiusY;if(b===void 0&&(b=x),x===0||b===0)return a.ae=[],a.ae;y=a.Ne;var E=a.Vh,z=Ce.jx(0,0,x=xt?tt=Math.PI:1<=xt&&(tt=0),!rt&&0tt&&(tt+=2*Math.PI),rt=y>z?1:y/z,xt=y>z?z/y:1,y=Ce.jx(0,0,y>z?y:z,ut,ut+tt,!0),z=Yi.alloc(),z.reset(),z.translate(x,b),z.rotate(a.Ne,0,0),z.scale(rt,xt),kn.Ha(y,z),Yi.free(z),a.ae=y,a.ae}Jt.Object.defineProperties(No.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&&vn(this,a),this.na=a,this._isInvalidBounds=!0}},endX:{get:function(){return this.Dc},set:function(a){this._isFrozen&&vn(this,a),this.Dc=a,this._isInvalidBounds=!0}},endY:{get:function(){return this.Ec},set:function(a){this._isFrozen&&vn(this,a),this.Ec=a,this._isInvalidBounds=!0}},point1X:{get:function(){return this.Ne},set:function(a){this._isFrozen&&vn(this,a),this.Ne=a,this._isInvalidBounds=!0}},point1Y:{get:function(){return this.Vh},set:function(a){this._isFrozen&&vn(this,a),this.Vh=a,this._isInvalidBounds=!0}},point2X:{get:function(){return this.Wh},set:function(a){this._isFrozen&&vn(this,a),this.Wh=a,this._isInvalidBounds=!0}},point2Y:{get:function(){return this.Pg},set:function(a){this._isFrozen&&vn(this,a),this.Pg=a,this._isInvalidBounds=!0}},centerX:{get:function(){return this.Ne},set:function(a){this._isFrozen&&vn(this,a),this.Ne=a,this._isInvalidBounds=!0}},centerY:{get:function(){return this.Vh},set:function(a){this._isFrozen&&vn(this,a),this.Vh=a,this._isInvalidBounds=!0}},radiusX:{get:function(){return this.Wh},set:function(a){0>a&&An(a,">= zero",No,"radiusX"),this._isFrozen&&vn(this,a),this.Wh=a,this._isInvalidBounds=!0}},radiusY:{get:function(){return this.Pg},set:function(a){0>a&&An(a,">= zero",No,"radiusY"),this._isFrozen&&vn(this,a),this.Pg=a,this._isInvalidBounds=!0}},startAngle:{get:function(){return this.Dc},set:function(a){this._isFrozen&&vn(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&&vn(this,a),360a&&(a=-360),this.Ec=a,this._isInvalidBounds=!0}},isClockwiseArc:{get:function(){return(this.l&4)!==0},set:function(a){this._isFrozen&&vn(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&&vn(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&&vn(this,a),a%=360,0>a&&(a+=360),this.Ne=a,this._isInvalidBounds=!0}}}),No.prototype.equalsApprox=No.prototype.Xa;var ls=new Qe(No,"Move",0),cr=new Qe(No,"Line",1),na=new Qe(No,"Bezier",2),yl=new Qe(No,"QuadraticBezier",3),os=new Qe(No,"Arc",4),Bl=new Qe(No,"SvgArc",4);No.className="PathSegment",No.Move=ls,No.Line=cr,No.Bezier=na,No.QuadraticBezier=yl,No.Arc=os,No.SvgArc=Bl;function ma(){this.H=null,this.xu=new Gt(0,0).freeze(),this.mt=new Gt(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}ma.prototype.copy=function(){var a=new ma;return this.clone(a)},ma.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},ma.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},ma.prototype.So=function(a,y){var x=this.diagram;return x===null||Oc(x,a,y),y},ma.prototype.Bz=function(a,y){var x=this.diagram;return x===null||(Oc(x,a,y),y.assign(x.Ps(y))),y},Jt.Object.defineProperties(ma.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}}}),ma.prototype.getMultiTouchDocumentPoint=ma.prototype.Bz,ma.prototype.getMultiTouchViewPoint=ma.prototype.So,ma.className="InputEvent";function Zh(){this.H=null,this.xa="",this.ar=this.Lr=null}Zh.prototype.copy=function(){var a=new Zh;return a.H=this.H,a.xa=this.xa,a.Lr=this.Lr,a.ar=this.ar,a},Zh.prototype.toString=function(){var a="*"+this.name;return this.subject!==null&&(a+=":"+this.subject.toString()),this.parameter!==null&&(a+="("+this.parameter.toString()+")"),a},Jt.Object.defineProperties(Zh.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}}}),Zh.className="DiagramEvent";function Nr(){this.Fm=Tr,this.rf=this.Qq="",this.Ln=this.Mn=this.Rn=this.Sn=this.Qn=this.H=this.cc=null}Nr.prototype.clear=function(){this.Ln=this.Mn=this.Rn=this.Sn=this.Qn=this.H=this.cc=null},Nr.prototype.copy=function(){var a=new Nr;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=Ae(y)&&typeof y.J=="function"?y.J():y,y=this.Rn,a.Rn=Ae(y)&&typeof y.J=="function"?y.J():y,y=this.Mn,a.Mn=Ae(y)&&typeof y.J=="function"?y.J():y,y=this.Ln,a.Ln=Ae(y)&&typeof y.J=="function"?y.J():y,a},Nr.prototype.qb=function(a){a.classType===Nr&&(this.change=a)},Nr.prototype.toString=function(){var a="";return a=this.change===Qa?a+"* ":this.change===Tr?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===Qa?this.oldValue!==null&&(a+=" "+this.oldValue):(this.object!==null&&(a+=Ci(this.object)),this.oldValue!==null&&(a+=" old: "+Ci(this.oldValue)),this.oldParam!==null&&(a+=" "+this.oldParam),this.newValue!==null&&(a+=" new: "+Ci(this.newValue)),this.newParam!==null&&(a+=" "+this.newParam)),a},Nr.prototype.I=function(a){return a?this.oldValue:this.newValue},Nr.prototype.Dz=function(a){return a?this.oldParam:this.newParam},Nr.prototype.canUndo=function(){return this.model!==null||this.diagram!==null},Nr.prototype.undo=function(){this.canUndo()&&(this.model!==null?this.model.changeState(this,!0):this.diagram!==null&&this.diagram.changeState(this,!0))},Nr.prototype.canRedo=function(){return this.model!==null||this.diagram!==null},Nr.prototype.redo=function(){this.canRedo()&&(this.model!==null?this.model.changeState(this,!1):this.diagram!==null&&this.diagram.changeState(this,!1))},Jt.Object.defineProperties(Nr.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===Qa&&(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}}}),Nr.prototype.redo=Nr.prototype.redo,Nr.prototype.canRedo=Nr.prototype.canRedo,Nr.prototype.undo=Nr.prototype.undo,Nr.prototype.canUndo=Nr.prototype.canUndo,Nr.prototype.getParam=Nr.prototype.Dz,Nr.prototype.getValue=Nr.prototype.I,Nr.prototype.clear=Nr.prototype.clear;var Qa=new Qe(Nr,"Transaction",-1),Tr=new Qe(Nr,"Property",0),es=new Qe(Nr,"Insert",1),Ps=new Qe(Nr,"Remove",2);Nr.className="ChangedEvent",Nr.Transaction=Qa,Nr.Property=Tr,Nr.Insert=es,Nr.Remove=Ps;function Gs(){this.o=new mn().freeze(),this.xa="",this.j=!1}Gs.prototype.toString=function(a){var y="Transaction: "+this.name+" "+this.changes.count.toString()+(this.isComplete?"":", incomplete");if(a!==void 0&&0y&&a.cd(y,b),y++);for(;a.length>y;)a.pop();a.freeze()}},Jt.Object.defineProperties(Gs.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}}}),Gs.prototype.optimize=Gs.prototype.ak,Gs.prototype.redo=Gs.prototype.redo,Gs.prototype.canRedo=Gs.prototype.canRedo,Gs.prototype.undo=Gs.prototype.undo,Gs.prototype.canUndo=Gs.prototype.canUndo,Gs.prototype.clear=Gs.prototype.clear,Gs.className="Transaction";function Br(){this.Pt=new un,this.Jd=!1,this.u=new mn().freeze(),this.Ce=-1,this.o=999,this.Fe=!1,this.Np=null,this.bi=0,this.j=!1,this.Ie=new mn().freeze(),this.hl=new mn,this.tt=!0,this.Dt=this.rq=this.Gt=this.Ft=!1}Br.prototype.toString=function(a){var y="UndoManager "+this.historyIndex+"<"+this.history.count+"<="+this.maxHistoryLength;y+="[";for(var x=this.nestedTransactionNames.count,b=0;ba.transactionLevel&&xi("Ending transaction without having started a transaction: "+x);var b=a.transactionLevel===1,E=a.currentTransaction;b&&y&&(a.isInternalTransaction||a.Ob("CommittingTransaction",x,E));var z=0;if(0=b&&(z=y.M(0),z!==null&&z.clear(),y.mb(0),a.Ce--)),b===0||y.count!==0&&y.get(y.count-1)===E||(y.add(E),a.Ce++),y.freeze()),a.isInternalTransaction||a.Ob("CommittedTransaction",x,E);else{a.Fe=!0;try{a.isEnabled&&E!==null&&(E.isComplete=!0,E.undo())}finally{a.isInternalTransaction||a.Ob("RolledBackTransaction",x,E),a.Fe=!1}E!==null&&E.clear()}return a.Np=null,a.isPendingClear&&a.clear(),a.isPendingClear=!1,a.isPendingUnmodified=!1,!0}if(a.isEnabled&&!y&&E!==null){for(a=z,x=E.changes,E=x.count-1;E>=a;E--)y=x.M(E),y!==null&&y.undo(),x.ka(),x.mb(E);x.freeze()}return!1}bt.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()}},Br.prototype.canUndo=function(){if(!this.isEnabled||0=this.transactionLevel&&!this.tt&&(a=a.diagram,a!==null&&a.pi===!1||xi("Change not within a transaction: "+x.toString()))}},Br.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},Jt.Object.defineProperties(Br.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.historyIndexE||Math.abs(y.y-a.y)>b},Jt.Object.defineProperties(Mo.prototype,{diagram:{get:function(){return this.H},set:function(a){a instanceof Be&&(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}}}),Mo.prototype.startTransaction=Mo.prototype.Ea,Mo.className="Tool";function br(){Mo.call(this),this.name="ToolManager",this.hb=new mn,this.ob=new mn,this.Hb=new mn,this.F=this.V=850,this.o=new Nn(2,2).ja(),this.Ha=5e3,this.ia=Wd,this.u=bc,this.Mp=this.j=null,this.zj=-1}We(br,Mo),br.prototype.initializeStandardTools=function(){},br.prototype.updateAdornments=function(a){var y=this.currentToolTip;if(y instanceof Oo&&this.Mp===a){var x=y.adornedObject;(a!==null?x.part===a:x===null)?this.showToolTip(y,x):this.hideToolTip()}},br.prototype.doMouseDown=function(){var a=this.diagram,y=a.lastInput;if(y.isTouchEvent&&this.gestureBehavior===yh&&(y.bubbles=!1),y.isMultiTouch){if(this.cancelWaitAfter(),this.gestureBehavior===Uh){y.bubbles=!0;return}if(this.gestureBehavior===yh)return;if(a.currentTool.canStartMultiTouch()){a.currentTool.standardPinchZoomStart();return}}for(var x=this.mouseDownTools.length,b=0;bE.right&&(x.x-=b.width+5/y.scale),x.xE.bottom?x.y-(b.height+5/y.scale):x.y+20/y.scale,x.yx.pointsCount)){var b=a.diagram;if(!b.isReadOnly){var E=a.Oe;if(E!==null){var z=null,tt=null;x.fromNode===null&&(z=Vf(a,x.i(0),!1),z!==null&&(tt=z.part));var ot=null,rt=null;x.toNode===null&&(ot=Vf(a,x.i(x.pointsCount-1),!0),ot!==null&&(rt=ot.part)),E.isValidLink(tt,z,rt,ot)?y?(x.defaultFromPoint=x.i(0),x.defaultToPoint=x.i(x.pointsCount-1),x.suspendsRouting=!1,x.fromNode=tt,z!==null&&(x.fromPortId=z.portId),x.toNode=rt,ot!==null&&(x.toPortId=ot.portId),x.fromPort!==b.Mx&&b.R("LinkRelinked",x,b.Mx),x.toPort!==b.Nx&&b.R("LinkRelinked",x,b.Nx)):Oi(E,tt,z,rt,ot):Oi(E,null,null,null,null)}}}}Dr.prototype.doDragOver=function(){};function Ph(a,y){var x=a.diagram;a.dragsLink&&al(a,!0),Yh(a);var b=a.findDragOverObject(y),E=x.lastInput;if(E.targetObject=b,b!==null){E.handled=!1;for(var z=b;z!==null;){var tt=z.mouseDrop;if(tt!==null&&(tt(E,z),E.handled))break;Kg(a,E,z),z=lf(z)}}else z=x.mouseDrop,z!==null&&z(E);if(a.isActive||Te!==null){for(E=(a.copiedParts||a.draggedParts).iterator;E.next();)z=E.key,z instanceof Dn&&z.linksConnected.each(function(ot){ot.suspendsRouting=!1});if(a.doDropOnto(y,b),a.isActive||Te!==null){for(a=Ye.alloc(),y=x.selection.iterator;y.next();)b=y.value,b instanceof Dn&&Xt(x,b,a);Ye.free(a)}}}function Kg(a,y,x){a=a.diagram,x=x.part,!a.handlesDragDropForTopLevelParts||!x.isTopLevel||x instanceof Fi||(x=a.mouseDrop,x!==null&&x(y))}function Xt(a,y,x){var b=!1;if(x=y.getAvoidableRect(x),a.viewportBounds.Re(x)&&(b=!0),a=a.Nu(x,function(E){return E.part},function(E){return E instanceof Ln},!0,function(E){return E instanceof Ln},b),a.count!==0)for(a=a.iterator;a.next();)x=a.value,!x.Td(y)&&x.isAvoiding&&x.bb()}Dr.prototype.doDropOnto=function(){},Dr.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()?(Hu(this,!1),_f(a,this.copiedParts),wu(this,this.copiedParts,!1),Yd(a,this.copiedParts)):this.mayMove()?(hu(this),wu(this,this.draggedParts,!0)):this.mayDragOut()?(Hu(this,!1),wu(this,this.copiedParts,!1)):hu(this),Lc(this,a.lastInput.documentPoint))}},Dr.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?(hu(this),Hu(this,!0),_f(a,this.copiedParts),wu(this,this.copiedParts,!1),Yd(a,this.copiedParts),this.copiedParts!==null&&(a.R("ChangingSelection",a.selection),a.clearSelection(!0),this.copiedParts.iteratorKeys.each(function(E){E.isSelected=!0}))):(y=!0,hu(this),this.mayMove()&&(wu(this,this.draggedParts,!0),Lc(this,a.lastInput.documentPoint))),this.Ym=!0,Ph(this,a.lastInput.documentPoint),this.isActive){var b=x?this.copiedParts.Lf():this.draggedParts.Lf();this.copiedParts=null,y&&ee(this),a.Ya(),Yd(a,this.draggedParts),this.transactionResult=x?"Copy":"Move",a.R(x?"SelectionCopied":"SelectionMoved",b)}this.stopTool(),x&&a.R("ChangedSelection",a.selection)}}},Dr.prototype.simulatedMouseMove=function(a,y,x){if(Te===null)return!1;var b=Te.diagram;x instanceof Be||(x=null);var E=Ve;return x!==E&&(E!==null&&E!==b&&(E.ug(),Te.isDragOutStarted=!1,E=E.toolManager.findTool("Dragging"),E!==null&&E.doSimulatedDragLeave()),Ve=x,x!==null&&x!==b&&(Zf(),E=x.toolManager.findTool("Dragging"),E!==null&&(ju.contains(E)||ju.add(E),E.doSimulatedDragEnter())),this.doUpdateCursor(null)),x===null||x===b||!x.allowDrop||x.isReadOnly||!x.allowInsert?!1:(b=x.toolManager.findTool("Dragging"),b!==null&&(a!==null&&(a.targetTouches!==void 0&&(0tt&&(tt=lt),ut>ot&&(ot=ut))}}for(b===1/0?z.h(0,0,0,0):z.h(b,E,tt-b,ot-E),b=z.x+z.width/2,E=z.y+z.height/2,Ye.free(z),z=a.Fr,tt=new ri,ot=Gt.alloc(),rt=y.iterator;rt.next();)lt=rt.value,lt instanceof Ln&<.canCopy()&&(ut=x.I(lt),ut!==null&&(ut.points=lt.points,Ed(ut,z.x-b,z.y-E),ut.suspendsRouting=!0,tt.add(ut,a.Pd())));for(y=y.iterator;y.next();)lt=y.value,lt.Zc()&<.canCopy()&&(rt=x.I(lt),rt!==null&&(lt=lt.location,ot.h(z.x-(b-lt.x),z.y-(E-lt.y)),rt.location=ot,rt.Va(),tt.add(rt,a.Pd(ot))));Gt.free(ot),a.copiedParts=tt,sf(a,tt.Lf()),a.draggedLink!==null&&(x=a.draggedLink,y=x.routeBounds,Ed(x,a.startPoint.x-(y.x+y.width/2),a.startPoint.y-(y.y+y.height/2))),a.doUpdateCursor(null)}}}Dr.prototype.doSimulatedDragOut=function(){var a=this.diagram;a.Ns=!1,this.mayCopy()||this.mayMove()?a.currentCursor="":a.currentCursor=this.nodropCursor,this.Bn=null},Dr.prototype.computeMove=function(a,y,x,b){return x=this.diagram,x!==null?x.computeMove(a,y,this.dragOptions,b):new Gt},Jt.Object.defineProperties(Dr.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}}}),Dr.prototype.getDraggingSource=Dr.prototype.Az;var Te=null,Ve=null;Dr.className="DraggingTool",ju=new mn,wo("draggingTool",function(){return this.findTool("Dragging")},function(a){this.gb("Dragging",a,this.mouseMoveTools)}),br.prototype.doCancel=function(){Te!==null&&Te.doCancel(),Mo.prototype.doCancel.call(this)};function He(){Mo.call(this),this.te=100,this.Ha=!1,this.u="pointer";var a=new Ln,y=new Ki;y.isPanelMain=!0,y.stroke="blue",a.add(y),y=new Ki,y.toArrow="Standard",y.fill="blue",y.stroke="blue",a.add(y),a.layerName="Tool",this.Ci=a,a=new Dn,y=new Ki,y.portId="",y.figure="Rectangle",y.fill=null,y.stroke="magenta",y.strokeWidth=2,y.desiredSize=Xo,a.add(y),a.selectable=!1,a.layerName="Tool",this.Bi=a,this.j=y,a=new Dn,y=new Ki,y.portId="",y.figure="Rectangle",y.fill=null,y.stroke="magenta",y.strokeWidth=2,y.desiredSize=Xo,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 ri,this.Of=this.gj=this.Pf=null}We(He,Mo),He.prototype.doStop=function(){this.diagram.ug(),this.originalToPort=this.originalToNode=this.originalFromPort=this.originalFromNode=this.originalLink=null,this.validPortsCache.clear(),this.targetPort=null},He.prototype.copyPortProperties=function(a,y,x,b,E){if(a!==null&&y!==null&&x!==null&&b!==null){var z=y.Df(),tt=Nn.alloc();tt.width=y.naturalBounds.width*z,tt.height=y.naturalBounds.height*z,b.desiredSize=tt,Nn.free(tt),E?(b.toSpot=y.toSpot,b.toEndSegmentLength=y.toEndSegmentLength):(b.fromSpot=y.fromSpot,b.fromEndSegmentLength=y.fromEndSegmentLength),x.locationSpot=Co,z=Gt.alloc(),x.location=y.ga(Co,z),Gt.free(z),b.angle=y.li(),this.portTargeted!==null&&this.portTargeted(a,y,x,b,E)}},He.prototype.setNoTargetPortProperties=function(a,y,x){y!==null&&(y.desiredSize=Xo,y.fromSpot=Qr,y.toSpot=Qr),a!==null&&(a.location=this.diagram.lastInput.documentPoint),this.portTargeted!==null&&this.portTargeted(null,null,a,y,x)},He.prototype.doMouseDown=function(){this.isActive&&this.doMouseMove()},He.prototype.doMouseMove=function(){if(this.isActive){var a=this.diagram;if(this.targetPort=this.findTargetPort(this.isForwards),this.targetPort!==null&&this.targetPort.part instanceof Dn){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)}},He.prototype.findValidLinkablePort=function(a,y){if(a===null)return null;var x=a.part;if(!(x instanceof Dn))return null;for(;a!==null;){var b=y?a.toLinkable:a.fromLinkable;if(b===!0&&(a.portId!==null||a instanceof Dn)&&(y?this.isValidTo(x,a):this.isValidFrom(x,a)))return a;if(b===!1)break;a=a.panel}return null},He.prototype.findTargetPort=function(a){var y=this.diagram,x=y.lastInput.documentPoint,b=this.portGravity;0>=b&&(b=.1);var E=this,z=y.og(x,b,function(ft){return E.findValidLinkablePort(ft,a)},null,!0);for(b=1/0,y=null,z=z.iterator;z.next();){var tt=z.value,ot=tt.part;if(ot instanceof Dn){var rt=tt.ga(Co,Gt.alloc()),lt=x.x-rt.x,ut=x.y-rt.y;Gt.free(rt),rt=lt*lt+ut*ut,rtx){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},He.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},He.prototype.isInSameNode=function(a,y){return a===null||y===null?!1:a===y?!0:(a=a.part,y=y.part,a!==null&&a===y)},He.prototype.isLinked=function(a,y){if(a===null||y===null)return!1;var x=a.part;if(!(x instanceof Dn))return!1;a=a.portId,a===null&&(a="");var b=y.part;if(!(b instanceof Dn))return!1;for(y=y.portId,y===null&&(y=""),y=b.Sd(y);y.next();)if(b=y.value,b.fromNode===x&&b.fromPortId===a)return!0;return!1},He.prototype.isValidLink=function(a,y,x,b){if(!this.isValidFrom(a,y)||!this.isValidTo(x,b)||!(y===null||b===null||(y.fromLinkableSelfNode&&b.toLinkableSelfNode||!this.isInSameNode(y,b))&&(y.fromLinkableDuplicates&&b.toLinkableDuplicates||!this.isLinked(y,b)))||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 E=a.linkValidation;if(E!==null&&!E(a,y,x,b,this.originalLink))return!1}return x!==null&&(E=x.linkValidation,E!==null&&!E(a,y,x,b,this.originalLink))?!1:(E=this.linkValidation,E!==null?E(a,y,x,b,this.originalLink):!0)},He.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 b=new un;return b.add(a),dn(this,x,y,b)};function dn(a,y,x,b){if(y===x)return!0;var E=y.fromNode;return E!==null&&E.isLinkLabel&&(b.add(E),dn(a,E.labeledLink,x,b))?!0:(y=y.toNode,!!(y!==null&&y.isLinkLabel&&(b.add(y),dn(a,y.labeledLink,x,b))))}He.prototype.isValidCycle=function(a,y,x){if(x===void 0&&(x=null),a===null||y===null)return this.isUnconnectedLinkValid;var b=this.diagram.validCycle;if(b!==pf){if(b===op){if(b=x||this.temporaryLink,b!==null&&!b.isTreeLink)return!0;for(b=y.linksConnected;b.next();){var E=b.value;if(E!==x&&E.isTreeLink&&E.toNode===y)return!1}return!fn(this,a,y,x,!0)}if(b===rp){if(b=x||this.temporaryLink,b!==null&&!b.isTreeLink)return!0;for(b=a.linksConnected;b.next();)if(E=b.value,E!==x&&E.isTreeLink&&E.fromNode===a)return!1;return!fn(this,a,y,x,!0)}if(b===ep)return a===y?a=!0:(b=new un,b.add(y),a=ln(this,b,a,y,x)),!a;if(b===np)return!fn(this,a,y,x,!1);if(b===ip)return a===y?a=!0:(b=new un,b.add(y),a=On(this,b,a,y,x)),!a}return!0};function fn(a,y,x,b,E){if(y===x)return!0;if(y===null||x===null)return!1;for(var z=y.linksConnected;z.next();){var tt=z.value;if(tt!==b&&(!E||tt.isTreeLink)&&tt.toNode===y&&(tt=tt.fromNode,tt!==y&&fn(a,tt,x,b,E)))return!0}return!1}function ln(a,y,x,b,E){if(x===b)return!0;if(x===null||b===null||y.contains(x))return!1;y.add(x);for(var z=x.linksConnected;z.next();){var tt=z.value;if(tt!==E&&tt.toNode===x&&(tt=tt.fromNode,tt!==x&&ln(a,y,tt,b,E)))return!0}return!1}function On(a,y,x,b,E){if(x===b)return!0;if(x===null||b===null||y.contains(x))return!1;y.add(x);for(var z=x.linksConnected;z.next();){var tt=z.value;if(tt!==E){var ot=tt.fromNode;if(tt=tt.toNode,ot=ot===x?tt:ot,ot!==x&&On(a,y,ot,b,E))return!0}}return!1}Jt.Object.defineProperties(He.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}}}),He.className="LinkingBaseTool";function Rn(){He.call(this),this.name="Linking",this.V={},this.F=null,this.K=In,this.Xd=null}We(Rn,He),Rn.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},Rn.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 Dn)))return null;var x=this.direction;if(x===In||x===pi){var b=this.findValidLinkablePort(y,!1);if(b!==null||this.startObject===a&&(b=a.port,this.findValidLinkablePort(b,!1)))return this.isForwards=!0,b}return(x===In||x===li)&&(y=this.findValidLinkablePort(y,!0),y!==null||this.startObject===a&&(y=a.port,this.findValidLinkablePort(y,!0)))?(this.isForwards=!1,y):null},Rn.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 Dn&&(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 Dn&&(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)},Rn.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()},Rn.prototype.doStop=function(){He.prototype.doStop.call(this),this.startObject=null},Rn.prototype.doMouseUp=function(){if(this.isActive){var a=this.diagram,y=this.transactionResult=null,x=null,b=null,E=null,z=null;try{var tt=this.targetPort=this.findTargetPort(this.isForwards);if(tt!==null){var ot=tt.part;ot instanceof Dn&&(this.isForwards?(this.originalFromNode!==null&&(y=this.originalFromNode,x=this.originalFromPort),b=ot,E=tt):(y=ot,x=tt,this.originalToNode!==null&&(b=this.originalToNode,E=this.originalToPort)))}else this.isForwards?this.originalFromNode!==null&&this.isUnconnectedLinkValid&&(y=this.originalFromNode,x=this.originalFromPort):this.originalToNode!==null&&this.isUnconnectedLinkValid&&(b=this.originalToNode,E=this.originalToPort);y!==null||b!==null?(z=this.insertLink(y,x,b,E),z!==null?(tt===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,b,E)):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)}}},Rn.prototype.isNewTreeLink=function(){var a=this.archetypeLinkData;if(a===null)return!0;if(a instanceof Ln)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)},Rn.prototype.insertLink=function(a,y,x,b){return this.diagram.partManager.insertLink(a,y,x,b)},Rn.prototype.doNoLink=function(){},Jt.Object.defineProperties(Rn.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 In=new Qe(Rn,"Either",0),pi=new Qe(Rn,"ForwardsOnly",0),li=new Qe(Rn,"BackwardsOnly",0);Rn.className="LinkingTool",Rn.Either=In,Rn.ForwardsOnly=pi,Rn.BackwardsOnly=li;function qn(){He.call(this),this.name="Relinking";var a=new Ki;a.figure="Diamond",a.desiredSize=Ir,a.fill="lightblue",a.stroke="dodgerblue",a.cursor=this.linkingCursor,a.segmentIndex=0,this.V=a,a=new Ki,a.figure="Diamond",a.desiredSize=Ir,a.fill="lightblue",a.stroke="dodgerblue",a.cursor=this.linkingCursor,a.segmentIndex=-1,this.Xd=a,this.F=null,this.Ew=new Ye}We(qn,He),qn.prototype.updateAdornments=function(a){if(a!==null&&a instanceof Ln){var y="RelinkFrom",x=null;if(a.isSelected&&!this.diagram.isReadOnly){var b=a.selectionObject;b!==null&&a.canRelinkFrom()&&a.actualBounds.w()&&a.isVisible()&&b.actualBounds.w()&&b.Ed()&&(x=a.Pj(y),x===null&&(x=this.makeAdornment(b,!1),a.bh(y,x)))}x===null&&a.Jf(y),y="RelinkTo",x=null,a.isSelected&&!this.diagram.isReadOnly&&(b=a.selectionObject,b!==null&&a.canRelinkTo()&&a.actualBounds.w()&&a.isVisible()&&b.actualBounds.w()&&b.Ed()&&(x=a.Pj(y),x===null?(x=this.makeAdornment(b,!0),a.bh(y,x)):x.v())),x===null&&a.Jf(y)}},qn.prototype.makeAdornment=function(a,y){var x=new Oo;return x.type=Pn.Link,y=y?this.toHandleArchetype:this.fromHandleArchetype,y!==null&&x.add(y.copy()),x.adornedObject=a,x},qn.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},qn.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 Oo&&x.adornedPart instanceof Ln))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&&0y.firstPickIndex+1&&x=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 t;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 Pn)for(a=a.elements;a.next();)this.updateResizeHandles(a.value,y)}},Ii.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},Ii.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))},Ii.prototype.doDeactivate=function(){var a=this.diagram;this.stopTransaction(),this.ue=this.handle=null,this.isActive=a.isMouseCaptured=!1},Ii.prototype.stopTransaction=function(){var a=this.diagram,y=Mo.prototype.stopTransaction.call(this);return y&&a.undoManager.transactionToUndo!==null&&a.undoManager.transactionToUndo.ak(),y},Ii.prototype.doCancel=function(){this.adornedObject!==null&&(this.adornedObject.desiredSize=this.originalDesiredSize,this.adornedObject.part.location=this.originalLocation),this.stopTool()},Ii.prototype.doMouseMove=function(){var a=this.diagram;if(this.isActive){var y=this.rt,x=this.qt,b=this.pt,E=this.adornedObject.qs(a.lastInput.documentPoint,Gt.alloc()),z=this.computeReshape();y=this.computeResize(E,this.handle.alignment,y,x,b,z),this.resize(y),a.bd(),Gt.free(E)}},Ii.prototype.doMouseUp=function(){var a=this.diagram;if(this.isActive){var y=this.rt,x=this.qt,b=this.pt,E=this.adornedObject.qs(a.lastInput.documentPoint,Gt.alloc()),z=this.computeReshape();y=this.computeResize(E,this.handle.alignment,y,x,b,z),this.resize(y),Gt.free(E),a.Ya(),this.transactionResult=this.name,a.R("PartResized",this.adornedObject,this.originalDesiredSize)}this.stopTool()},Ii.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 Fi){var b=new mn;if(b.add(a),!this.dragsMembers&&a.placeholder===null){var E=new st;E.dragsMembers=!1}y.moveParts(b,this.oppositePoint.copy().re(x),!0,E)}else a.location=a.location.copy().re(x).add(this.oppositePoint);y.bd()}},Ii.prototype.computeResize=function(a,y,x,b,E,z){y.Mc()&&(y=Co);var tt=this.adornedObject.naturalBounds,ot=tt.x,rt=tt.y,lt=tt.x+tt.width,ut=tt.y+tt.height,ft=1;if(!z){ft=tt.width;var vt=tt.height;0>=ft&&(ft=1),0>=vt&&(vt=1),ft=vt/ft}return vt=Gt.alloc(),Ce.No(a.x,a.y,ot,rt,E.width,E.height,vt),a=tt.copy(),0>=y.x?0>=y.y?(a.x=Math.max(vt.x,lt-b.width),a.x=Math.min(a.x,lt-x.width),a.width=Math.max(lt-a.x,x.width),a.y=Math.max(vt.y,ut-b.height),a.y=Math.min(a.y,ut-x.height),a.height=Math.max(ut-a.y,x.height),z||(1<=a.height/a.width?(a.height=Math.max(Math.min(ft*a.width,b.height),x.height),a.width=a.height/ft):(a.width=Math.max(Math.min(a.height/ft,b.width),x.width),a.height=ft*a.width),a.x=lt-a.width,a.y=ut-a.height)):1<=y.y?(a.x=Math.max(vt.x,lt-b.width),a.x=Math.min(a.x,lt-x.width),a.width=Math.max(lt-a.x,x.width),a.height=Math.max(Math.min(vt.y-rt,b.height),x.height),z||(1<=a.height/a.width?(a.height=Math.max(Math.min(ft*a.width,b.height),x.height),a.width=a.height/ft):(a.width=Math.max(Math.min(a.height/ft,b.width),x.width),a.height=ft*a.width),a.x=lt-a.width)):(a.x=Math.max(vt.x,lt-b.width),a.x=Math.min(a.x,lt-x.width),a.width=lt-a.x,z||(a.height=Math.max(Math.min(ft*a.width,b.height),x.height),a.width=a.height/ft,a.y=rt+.5*(ut-rt-a.height))):1<=y.x?0>=y.y?(a.width=Math.max(Math.min(vt.x-ot,b.width),x.width),a.y=Math.max(vt.y,ut-b.height),a.y=Math.min(a.y,ut-x.height),a.height=Math.max(ut-a.y,x.height),z||(1<=a.height/a.width?(a.height=Math.max(Math.min(ft*a.width,b.height),x.height),a.width=a.height/ft):(a.width=Math.max(Math.min(a.height/ft,b.width),x.width),a.height=ft*a.width),a.y=ut-a.height)):1<=y.y?(a.width=Math.max(Math.min(vt.x-ot,b.width),x.width),a.height=Math.max(Math.min(vt.y-rt,b.height),x.height),z||(1<=a.height/a.width?(a.height=Math.max(Math.min(ft*a.width,b.height),x.height),a.width=a.height/ft):(a.width=Math.max(Math.min(a.height/ft,b.width),x.width),a.height=ft*a.width))):(a.width=Math.max(Math.min(vt.x-ot,b.width),x.width),z||(a.height=Math.max(Math.min(ft*a.width,b.height),x.height),a.width=a.height/ft,a.y=rt+.5*(ut-rt-a.height))):0>=y.y?(a.y=Math.max(vt.y,ut-b.height),a.y=Math.min(a.y,ut-x.height),a.height=ut-a.y,z||(a.width=Math.max(Math.min(a.height/ft,b.width),x.width),a.height=ft*a.width,a.x=ot+.5*(lt-ot-a.width))):1<=y.y&&(a.height=Math.max(Math.min(vt.y-rt,b.height),x.height),z||(a.width=Math.max(Math.min(a.height/ft,b.width),x.width),a.height=ft*a.width,a.x=ot+.5*(lt-ot-a.width))),Gt.free(vt),a},Ii.prototype.computeReshape=function(){var a=hn;return this.adornedObject instanceof Ki&&(a=bv(this.adornedObject)),!(a===_n||this.diagram.lastInput.shift)},Ii.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},Ii.prototype.computeMaxSize=function(){var a=this.adornedObject.maxSize.copy(),y=this.maxSize;return!isNaN(y.width)&&y.widthx?x+=360:360<=x&&(x-=360),x=Math.round(45*Math.round(x/45));var b=this.handleDistance;return x===0?y.x=a.naturalBounds.width+b:x===45?(y.x=a.naturalBounds.width+b,y.y=a.naturalBounds.height+b):x===90?y.y=a.naturalBounds.height+b:x===135?(y.x=-b,y.y=a.naturalBounds.height+b):x===180?y.x=-b:x===225?(y.x=-b,y.y=-b):x===270?y.y=-b:x===315&&(y.x=a.naturalBounds.width+b,y.y=-b),a.ga(y)},mo.prototype.doDeactivate=function(){var a=this.diagram;this.stopTransaction(),this.ue=this.handle=null,this.kr=new Gt(NaN,NaN),this.isActive=a.isMouseCaptured=!1},mo.prototype.stopTransaction=function(){var a=this.diagram,y=Mo.prototype.stopTransaction.call(this);return y&&a.undoManager.transactionToUndo!==null&&a.undoManager.transactionToUndo.ak(),y},mo.prototype.doCancel=function(){this.diagram.delaysLayout=!1,this.rotate(this.originalAngle),this.stopTool()},mo.prototype.doMouseMove=function(){var a=this.diagram;this.isActive&&(a=this.computeRotate(a.lastInput.documentPoint),this.rotate(a))},mo.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()},mo.prototype.rotate=function(a){var y=this.adornedObject;if(y!==null){y.angle=a,y=y.part,y.Va();var x=y.locationObject,b=y.rotateObject;(x===b||x.rg(b))&&(x=this.Tn.copy(),y.location=x.re(this.rotationPoint).rotate(a-this.originalAngle).add(this.rotationPoint)),this.diagram.bd()}},mo.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&&0y-x&&(a=(Math.floor(a/y)+1)*y)),360<=a?a-=360:0>a&&(a+=360),a},Jt.Object.defineProperties(mo.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 Oo))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 Oo)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}}}),mo.className="RotatingTool",wo("rotatingTool",function(){return this.findTool("Rotating")},function(a){this.gb("Rotating",a,this.mouseDownTools)});function tr(){Mo.call(this),this.name="ClickSelecting"}We(tr,Mo),tr.prototype.canStart=function(){return!(!this.isEnabled||this.isBeyondDragSize())},tr.prototype.doMouseUp=function(){this.isActive&&(this.standardMouseSelect(),!this.standardMouseClick()&&this.diagram.lastInput.isTouchEvent&&this.diagram.toolManager.doToolTip()),this.stopTool()},tr.className="ClickSelectingTool";function ji(){Mo.call(this),this.name="Action",this.pk=null}We(ji,Mo),ji.prototype.canStart=function(){if(!this.isEnabled)return!1;var a=this.diagram,y=a.lastInput,x=a.ic(y.documentPoint,function(b){for(;b.panel!==null&&!b.isActionable;)b=b.panel;return b});return x!==null&&x.isActionable?(this.pk=x,a.Ck=a.ic(y.documentPoint,null,null),!0):!1},ji.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()},ji.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))}},ji.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()},ji.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())},ji.prototype.doStop=function(){this.pk=null},ji.className="ActionTool";function oo(){Mo.call(this),this.name="ClickCreating",this.Ri=null,this.o=!0,this.j=!1,this.mw=new Gt(0,0)}We(oo,Mo),oo.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)},oo.prototype.doMouseUp=function(){var a=this.diagram;this.isActive&&this.insertPart(a.lastInput.documentPoint),this.stopTool()},oo.prototype.insertPart=function(a){var y=this.diagram,x=this.archetypeNodeData;if(x===null)return null;var b=null;try{if(y.R("ChangingSelection",y.selection),this.Ea(this.name),x instanceof fi)x.Zc()&&(pu(x),b=x.copy(),b!==null&&y.add(b));else if(x!==null){var E=y.model.copyNodeData(x);Ae(E)&&(y.model.xf(E),b=y.Lc(E))}if(b!==null){var z=Gt.allocAt(a.x,a.y);this.isGridSnapEnabled&&Xf(this.diagram,b,a,z),b.location=z,y.allowSelect&&(y.clearSelection(!0),b.isSelected=!0),Gt.free(z)}y.Ya(),this.transactionResult=this.name,y.R("PartCreated",b)}finally{this.stopTransaction(),y.R("ChangedSelection",y.selection)}return b},Jt.Object.defineProperties(oo.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}}}),oo.className="ClickCreatingTool";function zi(){Mo.call(this),this.name="DragSelecting",this.Ik=175,this.o=!1;var a=new fi;a.layerName="Tool",a.selectable=!1;var y=new Ki;y.name="SHAPE",y.figure="Rectangle",y.fill=null,y.stroke="magenta",a.add(y),this.j=a}We(zi,Mo),zi.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.timestampE.right&&(x.x-=b.width+5/y.scale),x.xE.bottom&&(x.y-=b.height+5/y.scale),x.ya.lastInput.clickCount)):!1},Eo.prototype.doStart=function(){Ra=this,this.textBlock!==null&&this.doActivate()},Eo.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 fr&&(this.textBlock=y,y.part!==null)){a.animationManager.Cc(),this.isActive=!0,this.qa=er;var x=this.defaultTextEditor;y.textEditor!==null&&(x=y.textEditor),this.Zh=this.textBlock.copy();var b=new Ye(this.textBlock.ga(js),this.textBlock.ga(ka));a.tv(b),x.show(y,a,this),this.currentTextEditor=x}}}},Eo.prototype.doCancel=function(){this.stopTool()},Eo.prototype.doMouseUp=function(){this.canStart()&&this.doActivate()},Eo.prototype.doMouseDown=function(){this.isActive&&this.acceptText(qs)},Eo.prototype.acceptText=function(a){switch(a){case qs:this.qa===ia?this.currentTextEditor instanceof HTMLElement&&this.currentTextEditor.focus():(this.qa===er||this.qa===va||this.qa===Lr)&&(this.qa=Mr,Cs(this));break;case us:case Do:case Ho:(Do!==a||this.textBlock.isMultiline!==!0)&&(this.qa===er||this.qa===va||this.qa===Lr)&&(this.qa=Mr,Cs(this))}};function Cs(a){var y=a.textBlock,x=a.diagram,b=a.currentTextEditor;if(y!==null&&b!==null){var E=y.text,z="";b.valueFunction!==null&&(z=b.valueFunction()),a.isValidText(y,E,z)?(a.Ea(a.name),a.qa=ia,a.transactionResult=a.name,y.text=z,a.doSuccess(E,z),x!==null&&x.R("TextEdited",y,E),a.stopTransaction(),a.stopTool(),x!==null&&x.doFocus()):(a.qa=va,a.doError(E,z))}}Eo.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)},Eo.prototype.doSuccess=function(a,y){var x=this.textBlock;x.textEdited!==null&&x.textEdited(x,a,y)},Eo.prototype.doDeactivate=function(){var a=this.diagram;a!==null&&(this.qa=So,this.currentTextEditor!==null&&this.currentTextEditor.hide(a,this),this.textBlock=null,this.isActive=!1)},Eo.prototype.doStop=function(){Ra=null},Eo.prototype.isValidText=function(a,y,x){var b=this.textValidation;return b!==null&&!b(a,y,x)?!1:(b=a.textValidation,!!(b===null||b(a,y,x)))},Eo.prototype.Lx=function(a){var y=this.Zh;return y.text=a,y.measure(this.textBlock.Ih,1/0),y},Jt.Object.defineProperties(Eo.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)}}}),Eo.prototype.measureTemporaryTextBlock=Eo.prototype.Lx;var us=new Qe(Eo,"LostFocus",0),qs=new Qe(Eo,"MouseDown",1),Ho=new Qe(Eo,"Tab",2),Do=new Qe(Eo,"Enter",3),Go=new Qe(Eo,"SingleClick",0),yo=new Qe(Eo,"SingleClickSelected",1),Ar=new Qe(Eo,"DoubleClick",2),So=new Qe(Eo,"StateNone",0),er=new Qe(Eo,"StateActive",1),Lr=new Qe(Eo,"StateEditing",2),Mr=new Qe(Eo,"StateValidating",3),va=new Qe(Eo,"StateInvalid",4),ia=new Qe(Eo,"StateValidated",5),Ra=null;Eo.className="TextEditingTool",Eo.LostFocus=us,Eo.MouseDown=qs,Eo.Tab=Ho,Eo.Enter=Do,Eo.SingleClick=Go,Eo.SingleClickSelected=yo,Eo.DoubleClick=Ar,Eo.StateNone=So,Eo.StateActive=er,Eo.StateEditing=Lr,Eo.StateValidating=Mr,Eo.StateInvalid=va,Eo.StateValidated=ia,wo("textEditingTool",function(){return this.findTool("TextEditing")},function(a){this.gb("TextEditing",a,this.mouseUpTools)});function Wr(a){Sl||(ll(),Sl=!0),this.H=Wu,this.Ok=this.zb=this.vq=this.bc=!1,this.Qw=!0,this.Pk=Xl,this.Dm=!1,this.Gh=this.Jd=!0,this.Dg=600,this.cw=this.Ow=!1,this.Zd=new un,this.ce=new Ur,this.ce.Yd=this,this.Ei=new un,this.pu=new un,this.Sr=new un,this.pr=new un,a&&Object.assign(this,a)}Wr.prototype.Xe=function(a){this.H=a},Wr.prototype.canStart=function(){return!0};function ya(a,y){a.Jd&&a.canStart(y)&&(a.Zd.add(y),a.defaultAnimation.isAnimating&&a.Cc(),ra(a.H),a.zb=!0)}function Xs(a){if(a.Jd&&a.zb){var y=a.ce,x=a.H,b=a.Zd.contains("Model");b&&(a.Ok=!0,a.Pk===Xl?(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===Al&&y.vc.clear(),a.Qw=!!(a.Pk===_l&&x.du.D(x.pa)),x.R("InitialAnimationStarting",a)),b&&!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,b=y.vc.get(x),x.autoScale!==Ta&&b!==null&&(delete b.start.scale,delete b.end.scale),ue.requestAnimationFrame(function(){a.zb===!1||y.bc||(x.Gf("temporaryPixelRatio")&&wa(x),Ec(x),a.zb=!1,y.start(),y.bc&&(ns(a),x.Ya(),ih(y,0),qa(x,!0),$s(a),x.R("AnimationStarting",a)))}))}}function ua(a){return a.Zd.contains("Trigger")&&a.Zd.count===1}function Gu(a,y,x,b){a.isTicking||ua(a)||y instanceof Ln&&(y.fromNode!==null||y.toNode!==null)||a.ce.add(y,"position",x,b,!1)}bt=Wr.prototype,bt.fv=function(a){return this.ce.fv(a)},bt.Xu=function(a){return this.ce.Xu(a)};function Kr(a,y){function x(){if(0z?z+=360:rt+=360),z=E(x,z,rt-z,b)%360,tt=E(x,tt,lt-tt,b),ot=E(x,ot,ut-ot,b),x=E(x,a,y-a,b),"hsla("+z+", "+tt+"%, "+ot+"%, "+x+")"}function ll(){function a(x,b,E,z,tt,ot){x.position=new Gt(z(tt,b.x,E.x-b.x,ot),z(tt,b.y,E.y-b.y,ot))}var y=new ri;y.add("position:diagram",a),y.add("position",a),y.add("position:part",function(x,b,E,z,tt,ot){tta&&An(a,">= 1",Wr,"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}}}),Wr.prototype.stopAnimation=Wr.prototype.Cc;var Dl=null,Sl=!1,Xl=new Qe(Wr,"Default",1),_l=new Qe(Wr,"AnimateLocations",2),Al=new Qe(Wr,"None",3);Wr.className="AnimationManager",Wr.defineAnimationEffect=function(a,y){Sl||(ll(),Sl=!0),Dl.add(a,y)},Wr.Default=Xl,Wr.AnimateLocations=_l,Wr.None=Al;function Ur(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=Jl,this.Wk=this.ho=!1,this.cu=1,this.au=0,this.Gd=this.Dg=NaN,this.gw=0,this.dn=null,this.o=qo,this.vc=new ri,this.Tt=new ri,this.yl=new un,this.Ut=new un,this.dw=Sd,a&&Object.assign(this,a)}Ur.prototype.suspend=function(){this.Xk=!0},Ur.prototype.advanceTo=function(a,y){y&&(this.Xk=!1),this.ho&&a>=this.Gd&&(this.Wk=!0,a-=this.Gd),this.gw=a,Rl(this,!0),ns(this.Yd),qa(this.H),$s(this.Yd),this.H.redraw()};function Pa(a,y){if(a.Tt.clear(),a.Wk=!1,a.au=0,a.Gd=NaN,0a.cn?a.Gd:b-a.Qd;y&&(E=a.gw,Ea.cn&&(a.ho&&!a.Wk?(a.Qd=+new Date,a.cn=a.Qd+a.Gd,a.Wk=!0):a.Ml(!1))}}}function ih(a,y){for(var x=a.Gd,b=a.vc.iterator,E=a.Wk;b.next();){var z=b.key;if(!(z instanceof xe&&z.diagram===null)){var tt=b.value,ot=E?tt.end:tt.start;tt=E?tt.start:tt.end;var rt=Dl,lt;for(lt in tt)lt==="position"&&(tt["position:placeholder"]||tt["position:nodeCollapse"])||rt.get(lt)===null||rt.get(lt)(z,ot[lt],tt[lt],a.Lp,y,x,a)}}}bt.stop=function(){return this.bc?(this.Ml(!0),this):this},bt.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,ns(x);for(var b=this.vc,E=this.yl.iterator;E.next();)y.remove(E.value);for(E=this.Ut.iterator;E.next();)E.value.v();E=this.ho,b=b.iterator;for(var z=Dl;b.next();){var tt=b.key,ot=b.value,rt=E?ot.end:ot.start,lt=E?ot.start:ot.end,ut=ot.Ku,ft;for(ft in lt)if(z.get(ft)!==null){var vt=ft;!ot.Hu||vt!=="position:nodeCollapse"&&vt!=="position:placeholder"||(vt="position"),z.get(vt)(tt,rt[ft],ut[ft]!==void 0?ut[ft]:ot.Hu?rt[ft]:lt[ft],this.Lp,this.Gd,this.Gd,this)}ot.Hu&&ut.location!==void 0&&tt instanceof fi&&(tt.location=ut.location),ot.nv&&tt instanceof fi&&tt.Zb(!1)}if(y.As.clear(),Zd(y,!1),y.Ya(),y.N(),qa(y,!0),x.defaultAnimation===this){for(ft=x.pr.iterator;ft.next();)E=ft.value,E.Tg!==null&&(E.points=E.Tg,E.Tg=null);x.pr.clear()}qa(y,!0),this.isViewportUnconstrained&&(y.scrollMode=this.dw),$s(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())}},bt.Cj=function(a,y){var x=y.actualBounds,b=null;if(y instanceof Fi&&(b=y.placeholder),b!==null?(x=b.ga(js),b=b.padding,x.x+=b.left,x.y+=b.top,this.add(a,"position",x,a.position,!1)):this.add(a,"position",new Gt(x.x+x.width/2,x.y+x.height/2),a.position,!1),this.add(a,"scale",.01,a.scale,!1),a instanceof Fi)for(a=a.memberParts;a.next();)b=a.value,b instanceof Dn&&this.Cj(b,y)},bt.Aj=function(a,y){if(a.isVisible()){var x=null;if(y instanceof Fi&&(x=y.placeholder),x!==null){var b=x.ga(js);x=x.padding,b.x+=x.left,b.y+=x.top,this.add(a,"position:placeholder",a.position,b,!0)}else this.add(a,"position:nodeCollapse",a.position,y,!0);if(this.add(a,"scale",a.scale,.01,!0),b=this.vc,b.contains(a)&&(b.I(a).nv=!0),a instanceof Fi)for(a=a.memberParts;a.next();)b=a.value,b instanceof Dn&&this.Aj(b,y)}},bt.Ez=function(a){var y=this.Tt.get(a);return y===null&&(y={},this.Tt.add(a,y)),y},Jt.Object.defineProperties(Ur.prototype,{duration:{get:function(){return this.Dg},set:function(a){1>a&&An(a,">= 1",Ur,"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){0a?x/2*a*a+y:-x/2*(--a*(a-2)-1)+y}function Cu(a,y,x,b){return a===b?y+x:x*(-Math.pow(2,-10*a/b)+1)+y}Ur.className="Animation",Ur.EaseLinear=function(a,y,x,b){return x*a/b+y},Ur.EaseInOutQuad=Jl,Ur.EaseInQuad=function(a,y,x,b){return x*(a/=b)*a+y},Ur.EaseOutQuad=function(a,y,x,b){return-x*(a/=b)*(a-2)+y},Ur.EaseInExpo=function(a,y,x,b){return a===0?y:x*Math.pow(2,10*(a/b-1))+y},Ur.EaseOutExpo=Cu;function $u(a,y,x){this.start=a,this.end=y,this.Ku={},this.Hu=x,this.nv=!1}$u.className="AnimationState";function xl(a,y,x){this.xd=null,this.rf=a,this.so=x||hs,this.uk=null,y!==void 0&&(this.uk=y,x===void 0&&(this.so=oa))}xl.prototype.copy=function(){var a=new xl(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 Rr(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))}Jt.Object.defineProperties(xl.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 hs=new Qe(xl,"Default",1),oa=new Qe(xl,"Immediate",2),ds=new Qe(xl,"Bundled",3);xl.className="AnimationTrigger",xl.Default=hs,xl.Immediate=oa,xl.Bundled=ds;function Or(a){Po(this),this.H=null,this.Pa=new mn,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)}bt=Or.prototype,bt.clear=function(){for(var a=this.Pa,y=0;y=a)return y;for(var x=0,b=0,E=0,z=0,tt=0,ot=this.Pa.iterator;ot.next();){var rt=ot.value;rt instanceof Fi?E++:rt instanceof Dn?b++:rt instanceof Ln?z++:rt instanceof Oo?tt++:x++}if(ot="",0x.Oq||ot.height*E>x.Oq?y.gc(a,x):(E=y.actualBounds,z=y.naturalBounds,E.width===0||E.height===0||isNaN(E.x)||isNaN(E.y)||!y.isVisible()||(x=y.transform,y.areaBackground!==null&&(_r(y,a,y.areaBackground,!0,!0,z,E),a.fillRect(E.x,E.y,E.width,E.height)),y.areaBackground===null&&y.background===null&&(_r(y,a,"rgba(0,0,0,0.3)",!0,!1,z,E),a.fillRect(E.x,E.y,E.width,E.height)),y.background!==null&&(a.transform(x.m11,x.m12,x.m21,x.m22,x.dx,x.dy),_r(y,a,y.background,!0,!1,z,E),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)))))),b&&(a.restore(),a.Vc(!0))}},bt.g=function(a,y,x,b,E){var z=this.diagram;z!==null&&z.cb(Tr,a,this,y,x,b,E)},bt.oi=function(a,y,x){var b=this.Pa;if(y.Ig=this,this===null&&La(y),a>=b.count)a=b.count;else if(b.M(a)===y)return-1;return b.Gb(a,y),y.Vo(x),b=this.diagram,b!==null&&(x?b.N():b.oi(y)),du(this,a,y),a},bt.pc=function(a,y,x){if(!x&&y.layer!==this&&y.layer!==null)return y.layer.pc(a,y,x);var b=this.Pa;if(0>a||a>=b.length){if(a=b.indexOf(y),0>a)return-1}else if(b.M(a)!==y&&(a=b.indexOf(y),0>a))return-1;return y.Wo(x),b.mb(a),b=this.diagram,b!==null&&(x?b.N():b.pc(y)),y.Ig=null,La(y),a};function du(a,y,x){if(y=uf(a,y,x),x instanceof Fi&&x!==null&&isNaN(x.zOrder)){if(x.memberParts.count!==0){for(var b=-1,E=a.Pa.s,z=E.length,tt=0;ttb&&ot.containingGroup===x&&(b=tt,0<=y))break}!(0>b)&&b=E)return y;if(0>y&&(y=a.indexOf(x)),0>y)return-1;for(var z=y-1,tt=NaN;0<=z&&(tt=a.M(z).zOrder,!!isNaN(tt));)z--;for(var ot=y+1,rt=NaN;otb)for(;;){if(z===-1||tt<=b){if(z++,z===y)break;return a.mb(y),a.Gb(z,x),z}for(tt=NaN;0<=--z&&(tt=a.M(z).zOrder,isNaN(tt)););}else if(!isNaN(rt)&&rt=b){if(ot--,ot===y)break;return a.mb(y),a.Gb(ot,x),ot}for(rt=NaN;++ota||1=a)return y;for(var x=this.Wa.iterator;x.next();)y+=` `+x.value.toString(a-1);return y};function Mc(a,y){if(Yr){if(y!=null||ce("Diagram setup requires an argument DIV."),a.Ka!==null&&ce("Diagram has already completed setup."),typeof y=="string"?a.Ka=ue.document.getElementById(y):y instanceof HTMLDivElement?a.Ka=y:ce("No DIV or DIV id supplied: "+y),a.Ka===null&&ce("Invalid DIV id; could not get element with id: "+y),a.Ka.H!==void 0&&ce("Invalid div id; div already has a Diagram associated with it."),!a.ol&&ue.ResizeObserver){var x=gn(function(){a.$b()},250);a.ol=new ue.ResizeObserver(function(){x()}),a.ol.observe(a.Ka)}ue.getComputedStyle(a.Ka,null).position==="static"&&(a.Ka.style.position="relative"),y=5;var b="rgba(2"+y+"5, 255, 255, 0)";y--,a.Ka.style["-webkit-tap-highlight-color"]=b,a.Ka.innerHTML="",a.Ka.H=a,a.Ka.goDiagram=a,a.Ka.go=ue.go;var E=new gu(a);if(E.style!==void 0&&(E.style.position="absolute",E.style.top="0px",E.style.left="0px",ue.getComputedStyle(a.Ka,null).getPropertyValue("direction")==="rtl"&&(a.tn=!0),E.style.zIndex="2",E.style.userSelect="none",E.style.MozUserSelect="none",E.style.touchAction="none",E.style.letterSpacing="normal !important",E.style.wordSpacing="normal !important"),a.ta=E,a.ib=E.context,b=a.ib,a.Mb=a.computePixelRatio(),a.viewSize.w()||(a.Aa=a.Ka.clientWidth||1,a.ya=a.Ka.clientHeight||1),Bc(a,a.Aa,a.ya),a.Ka.insertBefore(E.Oa,a.Ka.firstChild),E=new gu(null),E.width=1,E.height=1,a.jw=E,a.oy=E.context,Yr){E=Gn("div");var z=Gn("div");E.style.position="absolute",E.style.overflow="auto",E.style.width=a.Aa+"px",E.style.height=a.ya+"px",E.style.zIndex="1",z.style.position="absolute",z.style.width="1px",z.style.height="1px",a.Ka.appendChild(E),E.appendChild(z),E.onscroll=Uf,E.addEventListener("pointerdown",cf),E.H=a,E.uy=!0,E.vy=!0,a.ku=E,a.hu=z}a.hk=gn(function(){a.Yh=null,a.N()},300),a.Ov=gn(function(){Ec(a)},250),a.preventDefault=function(tt){return tt.preventDefault(),!1},a.$j=function(tt){if(a.isEnabled){var ot=hl(a,tt,!0);ot.bubbles=!0;var rt=0,lt=0;ot.delta=0,tt.deltaX!==void 0?(tt.deltaX!==0&&(rt=0Math.abs(tt.deltaY)?-rt:-lt):tt.wheelDeltaX!==void 0?(tt.wheelDeltaX!==0&&(rt=0Math.abs(tt.wheelDeltaY)?-rt:-lt):tt.wheelDelta!==void 0&&tt.wheelDelta!==0&&(ot.delta=0ot||Math.abs(lt.y-tt.screenY)>ot)?a.yq++:a.yq=1,rt.clickCount=a.yq,a.tw=tt.timeStamp,a.uw.sg(tt.screenX,tt.screenY),a.doMouseDown(),tt.button===1?tt.preventDefault():jl(rt,tt)}},a.dk=function(tt){if(a.isEnabled){a.Vk=!0;var ot=a.oj;if(ot[0]===null||ot[0].pointerId!==tt.pointerId&&ot[0].pointerType===tt.pointerType){if(ot[1]!==null&&ot[1].pointerId===tt.pointerId){ot[1]=tt;return}if(ot[0]===null)ot[0]=tt;else return}else ot[0]=tt;if(ot[0].pointerId===tt.pointerId){ot=Tc(a,tt,!1,!1,!1,ot[1]!==null);var rt=ue.document.elementFromPoint(tt.clientX,tt.clientY)||null;rt!==null&&rt.shadowRoot!==void 0&&rt.shadowRoot!==null&&(rt=rt.shadowRoot.elementFromPoint(tt.clientX,tt.clientY));var lt=a,ut=tt;rt&&rt.H&&(ut=tt,lt=rt.H),ot.targetDiagram=lt,vd(a,ut,ot),ot.targetObject=null,a.doMouseMove(),jl(ot,tt)}}},a.fk=function(tt){if(a.isEnabled){a.Vk=!0;var ot=tt.pointerType==="touch"||tt.pointerType==="pen",rt=a.Yt;if(ot&&a.qu)delete rt[tt.pointerId],tt.preventDefault();else if(rt=a.oj,rt[0]===null||rt[0].pointerId!==tt.pointerId&&rt[0].pointerType===tt.pointerType)rt[1]!==null&&rt[1].pointerId===tt.pointerId&&(rt[1]=null);else{rt[0]=null,rt=Tc(a,tt,!1,!0,!0,!1);var lt=ue.document.elementFromPoint(tt.clientX,tt.clientY)||null;lt!==null&<.shadowRoot!==void 0&<.shadowRoot!==null&&(lt=lt.shadowRoot.elementFromPoint(tt.clientX,tt.clientY)),lt!==null&<.H instanceof Be&<.H!==a&&vd(lt.H,tt,rt),lt===null&&(lt=tt.target),vd(a,tt,rt),rt.clickCount=a.yq,rt.targetDiagram=Nc(tt,lt),rt.targetObject=null,a.doMouseUp(),jl(rt,tt),ot&&(a.wq=!1)}}},a.ek=function(tt){if(a.isEnabled){a.Vk=!1;var ot=a.Yt;ot[tt.pointerId]&&delete ot[tt.pointerId],ot=a.oj,ot[0]!==null&&ot[0].pointerId===tt.pointerId&&(ot[0]=null),ot[1]!==null&&ot[1].pointerId===tt.pointerId&&(ot[1]=null),tt.pointerType!=="touch"&&tt.pointerType!=="pen"&&(tt=a.currentTool,tt.cancelWaitAfter(),tt.standardMouseOver())}},a.ck=function(tt){var ot=a.oj;ot[0]!==null&&ot[0].pointerId===tt.pointerId?(ot[0]=null,a.wq=!1):ot[1]!==null&&ot[1].pointerId===tt.pointerId&&(ot[1]=null)},a.Vp=b.Z["d"+yf[1]+yf[2]+"wI"+zc.slice(1,5)]["b"+Fx.slice(1,y)](b.Z,vf,y,y),b.Vc(!0),Zg(a),a.nl==="svg"&&(y=a.pj.get("svg"),a.Ka.appendChild(y.Oa),a.ib=y.context)}}Be.prototype.addEventListener=function(a,y,x,b){a.addEventListener(y,x,{capture:b,passive:!1})},Be.prototype.removeEventListener=function(a,y,x,b){a.removeEventListener(y,x,{capture:b})};function Zg(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(ue,"resize",a.Ov,!1)}function wa(a){30Ct&&(this.position=Kt.h(-(y.scrollWidth-this.Aa)+zt-this.Aa/E+ut,this.position.y))),a.vy&&this.allowVerticalScroll&&(otOt&&(this.position=Kt.h(this.position.x,-(y.scrollHeight-this.ya)+a.scrollTop-this.ya/E+z))),Gt.free(Kt),this.vd=!0,this.Ee=this.qr=!1,b=this.documentBounds,E=this.viewportBounds,ut=b.right,Ct=E.right,z=b.bottom,Ot=E.bottom,tt=b.x,ft=E.x,ot=b.y,b=E.y,vt>=rt&&tt>=ft&&ut<=Ct&&(x.style.width="1px"),xt>=lt&&ot>=b&&z<=Ot&&(x.style.height="1px"))}},Be.prototype.computeBounds=function(a){return a===void 0&&(a=new Ye),ra(this),kc(this,a)};function kc(a,y){if(a.fixedBounds.w())return y.assign(a.fixedBounds),y.Co(a.yb),y;for(var x=!0,b=a.Wa.s,E=b.length,z=0;zx&&(y=x),ya.maxScale&&(y=a.maxScale),y):y===Jd?(y=rt>ot?(tt-a.Db)/b:(z-a.Db)/E,y>x&&(y=x),ya.maxScale&&(y=a.maxScale),y):a.scale}Be.prototype.zoomToFit=function(){var a=this.sj;this.sj=Sd,this.scale=pd(this,Hl),a!==Sd&&(zl(this,!1),ff(this,this.documentBounds,this.Aa/this.Ca,this.ya/this.Ca,this.zk,!1)),this.sj=a},bt=Be.prototype,bt.BA=function(a,y){y===void 0&&(y=Hl);var x=a.width,b=a.height;if(!(x===0||b===0||isNaN(x)&&isNaN(b))){var E=1;if(y===Hl||y===Jd)if(isNaN(x))E=this.viewportBounds.height*this.scale/b;else if(isNaN(b))E=this.viewportBounds.width*this.scale/x;else{E=this.Aa;var z=this.ya;E=y===Jd?z/b>E/x?(z-(this.Be?this.Db:0))/b:(E-(this.gf?this.Db:0))/x:Math.min(z/b,E/x)}this.scale=E,this.position=new Gt(a.x,a.y)}},bt.Jy=function(a,y){this.Va();var x=this.documentBounds,b=this.viewportBounds;this.position=new Gt(x.x+(a.x*x.width+a.offsetX)-(y.x*b.width-y.offsetX),x.y+(a.y*x.height+a.offsetY)-(y.y*b.height-y.offsetY))},bt.zz=function(a){if(a instanceof xe){this.eq=a;var y=Gt.alloc();this.fq=this.op(a.ga(js,y)),Gt.free(y)}else this.eq=null,this.fq=ks};function ff(a,y,x,b,E,z){var tt=Gt.allocAt(a.pa.x,a.pa.y),ot=tt.x,rt=tt.y;if(a.eq!==null){var lt=Gt.alloc();lt=a.eq.ga(js,lt),ot=lt.x-a.fq.x/a.scale,rt=lt.y-a.fq.y/a.scale,E=Qr,Gt.free(lt)}(z||a.scrollMode===Sd)&&(E.sb()&&(x>y.width&&(ot=y.x+(E.x*y.width+E.offsetX)-(E.x*x-E.offsetX)),b>y.height&&(rt=y.y+(E.y*y.height+E.offsetY)-(E.y*b-E.offsetY))),E=a.rj,z=x-y.width,xy.left?ot=y.left:oty.top?rt=y.top:rty;y++){var x=a.De.iterator;if(x===null||a.De.count===0)break;a.De=new un,a.Nv(x,a.De)}a.nodes.each(function(b){b instanceof Fi&&b.U&65536&&(b.U=b.U^65536)})}}bt.Nv=function(a,y){for(a.reset();a.next();){var x=a.value;!x.Zc()||x instanceof Fi||(x.si()?(x.measure(1/0,1/0),x.arrange()):y.add(x))}for(a.reset();a.next();)x=a.value,x instanceof Fi&&x.isVisible()&&Zr(this,x);for(a.reset();a.next();)x=a.value,x instanceof Ln&&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 Oo&&x.isVisible()&&(x.si()?(x.measure(1/0,1/0),x.arrange()):y.add(x))};function Zr(a,y){for(var x=Zn(),b=Zn(),E=y.memberParts;E.next();){var z=E.value;z.isVisible()&&(z instanceof Fi?($l(z)||ja(z)||qd(z))&&Zr(a,z):z instanceof Ln?z.fromNode===y||z.toNode===y?b.push(z):x.push(z):(z.measure(1/0,1/0),z.arrange()))}for(a=x.length,E=0;Eve&&(zt=Fn.left,te=Fn.right),Kt.height>De&&(re=Fn.top,he=Fn.bottom)):(zt=Fn.left,te=Fn.right,re=Fn.top,he=Fn.bottom);var Vn=Kt.width+zt+te,Wn=Kt.height+re+he;Fn=a.scale;var bn=Vn>rt/Fn,an=Wn>lt/Fn;if(!(z||a.gf||a.Be||bn||an))return!0;zt=Kt.x-zt,rt=ut.x,te=Kt.right+te,lt=ut.right+tt,re=Kt.y-re;var Ti=ut.y;Kt=Kt.bottom+he,ut=ut.bottom+ot;var Li="1px";if(he="1px",a.scrollMode===Sd&&(bn||an)&&(bn&&a.hasHorizontalScrollbar&&a.allowHorizontalScroll&&(bn=1,zt+1lt+1&&(bn=Math.max((te-lt)*Fn+a.Aa,bn)),ve+tt+1ut+1&&(bn=Math.max((Kt-ut)*Fn+a.ya,bn)),De+ot+1lt+1&&(tt=Math.max((te-lt)*Fn+a.Aa,tt)),ve+1ut+1&&(ot=Math.max((Kt-ut)*Fn+tt,ot)),De+1lt+1&&(y=a.position.x*Fn)),a.tn)switch(a.bu){case"negative":y=-(Ct.scrollWidth-y-Ct.clientWidth);break;case"reverse":y=Ct.scrollWidth-y-Ct.clientWidth}return Ct.scrollLeft=y,a.hasVerticalScrollbar&&a.allowVerticalScroll&&(De+1ut+1&&(Ct.scrollTop=a.position.y*Fn)),rt=a.Aa,lt=a.ya,Ct.style.width=rt+(a.gf?a.Db:0)+"px",Ct.style.height=lt+(a.Be?a.Db:0)+"px",x!==rt||b!==lt||a.animationManager.zb?(x=Ye.allocAt(E,ft,vt,xt),a.onViewportBoundsChanged(x,a.viewportBounds,Fn,z),Ye.free(x),!1):!0}bt=Be.prototype,bt.add=function(a){var y=a.diagram;if(y!==this&&(y!==null&&ce("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&&ce('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(es,"parts",y,null,a,null,x),y.isTemporary||this.Ya(),a.C(1),x=a.layerChanged,x!==null&&x(a,null,y)}},bt.oi=function(a){this.partManager.oi(a);var y=this;Wc(a,function(x){Dc(y,x)}),(a instanceof Oo||a instanceof Fi&&a.placeholder!==null)&&a.v(),a.data!==null&&Wc(a,function(x){ay(y.partManager,x)}),ja(a)!==!0&&qd(a)!==!0||this.De.add(a),RS(a,!0,this),jS(a)?(a.actualBounds.w()&&this.N(Vc(a,a.actualBounds)),this.Ya()):a.isVisible()&&a.actualBounds.w()&&this.N(Vc(a,a.actualBounds)),this.$b()},bt.pc=function(a){a.Ej(),this.partManager.pc(a);var y=this;a.data!==null&&Wc(a,function(x){ly(y.partManager,x,y)}),this.De.remove(a),jS(a)?(a.actualBounds.w()&&this.N(Vc(a,a.actualBounds)),this.Ya()):a.isVisible()&&a.actualBounds.w()&&this.N(Vc(a,a.actualBounds)),this.$b()},bt.remove=function(a){Ud(this,a,!0)};function Ud(a,y,x){var b=y.layer;b!==null&&b.diagram===a&&(y.isSelected=!1,y.isHighlighted=!1,y.C(2),x&&y.Lj(),x=b.pc(-1,y,!1),0<=x&&a.cb(Ps,"parts",b,y,null,x,null),a=y.layerChanged,a!==null&&a(y,b,null))}bt.Is=function(a,y){if(y===void 0&&(y=!1),en(a))for(var x=a.length,b=0;bb&&this.Ya(),this},bt.Cy=function(a,y){Ug(this,a,y),a.Xe(this);var x=this.Wa,b=x.indexOf(a);0<=b&&(x.remove(a),this.cc!==null&&this.cb(Ps,"layers",this,a,null,b,null));var E=x.count,z;for(z=0;zb&&this.Ya(),this},bt.kA=function(a){if(a.diagram!==this&&ce("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 b=y.value,E=b.layerName;E!==a.name?b.layerName=E:b.layerName=""}this.cc!==null&&this.cb(Ps,"layers",this,a,null,x,null),this.N(),this.Ya()}}},bt.Qj=function(a){for(var y=this.layers;y.next();){var x=y.value;if(x.name===a)return x}return null},bt.Yw=function(a){return this.pf===null&&(this.pf=new mn),this.pf.add(a),this.model.Pe(a),this},bt.mA=function(a){this.pf!==null&&(this.pf.remove(a),this.pf.count===0&&(this.pf=null)),this.model.ik(a)},bt.Pe=function(a){return this.zg===null&&(this.zg=new mn),this.zg.add(a),this},bt.ik=function(a){this.zg!==null&&(this.zg.remove(a),this.zg.count===0&&(this.zg=null))},bt.ds=function(a){if(this.skipsUndoManager||this.model.skipsUndoManager||this.model.undoManager.Tu(a),a.change!==Qa&&(this.isModified=!0),this.zg!==null)for(var y=this.zg,x=y.length,b=0;bft.Pa.indexOf(xt)&&ft.oi(vt,xt,Ct):(xt.isSelected=!1,xt.isHighlighted=!1,xt.Wb(),ft.pc(Ct?vt:-1,xt,Ct)))}else ft instanceof Be?typeof vt=="number"&&xt instanceof Or&&(y?(xt.Xe(this),this.Wa.Gb(vt,xt)):this.Wa.mb(vt)):ce("unknown ChangedEvent.Remove object: "+a.toString());this.isModified=!0}else b!==Qa&&ce("unknown ChangedEvent: "+a.toString())}finally{this.skipsModelSourceBindings=x}}},Be.prototype.Ea=function(a){return this.undoManager.Ea(a)},Be.prototype.eb=function(a){return this.undoManager.eb(a)},Be.prototype.Kf=function(){return this.undoManager.Kf()},Be.prototype.commit=function(a,y){y===void 0&&(y="");var x=this.skipsUndoManager;y===null&&(this.skipsUndoManager=!0,y=""),this.undoManager.Ea(y);var b=!1;try{a(this),b=!0}finally{b?this.undoManager.eb(y):this.undoManager.Kf(),this.skipsUndoManager=x}},Be.prototype.updateAllTargetBindings=function(a){this.partManager.updateAllTargetBindings(a)},Be.prototype.rp=function(){this.partManager.rp()};function Yg(a,y,x){var b=a.animationManager;if(a.vb||a.ld)a.Ca=x,sh(a),a.N(),a.Ee=!0,b.zb&&(ua(b)||b.ce.add(b.H,"scale",y,a.Ca));else if(a.ta===null)a.Ca=x,sh(a);else{a.vb=!0;var E=a.viewportBounds.copy(),z=a.Aa,tt=a.ya,ot=a.zoomPoint.x,rt=a.zoomPoint.y,lt=a.contentAlignment;isNaN(ot)&&(lt.$c()?lt.Hf(Bu)?ot=0:lt.Hf(Da)&&(ot=z-1):ot=lt.sb()?lt.x*(z-1):z/2),isNaN(rt)&&(lt.$c()?lt.Hf(Pu)?rt=0:lt.Hf(sl)&&(rt=tt-1):rt=lt.sb()?lt.y*(tt-1):tt/2),a.scaleComputation===null||a.animationManager.defaultAnimation.isAnimating||(x=a.scaleComputation(a,x)),xa.maxScale&&(x=a.maxScale),z=Gt.allocAt(a.pa.x+ot/y-ot/x,a.pa.y+rt/y-rt/x),a.position=z,Gt.free(z),a.Ca=x,sh(a),a.vb=!1,a.onViewportBoundsChanged(E,a.viewportBounds,y,!1),zl(a,!1),b.zb&&(ua(b)||b.ce.add(b.H,"scale",y,a.Ca))}}Be.prototype.onViewportBoundsChanged=function(a,y,x,b){if(!a.D(y)){b===void 0&&(b=!1),b||(this.Ee=!0),this.vd=!0;var E=this.layout;E===null||!E.isViewportSized||this.autoScale!==Ta||a.width===y.width&&a.height===y.height||E.C(),E=this.currentTool,this.Vk===!0&&E instanceof br&&(this.lastInput.documentPoint=this.Ps(this.lastInput.viewPoint),Wf(E,this)),this.vb||this.invalidateViewport(a,y),rh(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=b,this.R("ViewportBoundsChanged",this.fc,a),this.isVirtualized&&this.links.each(function(z){z.isAvoiding&&z.actualBounds.Yc(y)&&z.bb()})}};function rh(a,y){var x=a.fe;if(x!==null&&x.visible){for(var b=Nn.alloc(),E=1,z=1,tt=x.O.s,ot=tt.length,rt=0;rtut||(pv(lt.figure)?z=z*ut/Ce.vx(z,ut):E=E*ut/Ce.vx(E,ut))}if(tt=x.gridCellSize,b.h(z*tt.width,E*tt.height),y!==void 0)E=y.width,z=y.height,a=y.x,tt=y.y;else{if(y=Ye.alloc(),a=a.viewportBounds,y.h(a.x,a.y,a.width,a.height),!y.w()){Ye.free(y);return}E=y.width,z=y.height,a=y.x,tt=y.y,Ye.free(y)}x.width=E+2*b.width,x.height=z+2*b.height,y=Gt.alloc(),Ce.No(a,tt,0,0,b.width,b.height,y),y.offset(-b.width,-b.height),Nn.free(b),x.part.location=y,Gt.free(y)}}Be.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(),b=x.length,E=0;E=b&&!z.defaultAnimation.isAnimating&&!z.zb&&(y||ya(z,"Layout")),a.xh=!1;for(var tt=a.ai.iterator;tt.next();)qg(a,tt.value,y,b);E.isValidLayout||(!y||E.isRealtime||E.isRealtime===null||b===0?(E.doLayout(a),ra(a),E.isValidLayout=!0):a.xh=!0)}finally{y=a.undoManager.isInternalTransaction,b===0&&(a.eb("Layout"),a.undoManager.isInternalTransaction=!1),!y||b!==0&&b!==1||Xs(z),a.aa=x}}}function qg(a,y,x,b){if(y!==null){for(var E=y.gl.iterator;E.next();)qg(a,E.value,x,b);E=y.layout,E===null||E.isValidLayout||(!x||E.isRealtime||b===0?(y.rh=!y.location.w(),E.doLayout(y),y.C(32),Zr(a,y),E.isValidLayout=!0):a.xh=!0)}}bt.yz=function(){for(var a=new mn,y=this.nodes;y.next();){var x=y.value;x.isTopLevel&&x.kh()===null&&a.add(x)}return a.iterator};function ev(a){function y(E){var z=E.toLowerCase(),tt=new mn;x.add(E,tt),x.add(z,tt),b.add(E,E),b.add(z,E)}var x=new ri,b=new ri;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=b}function sm(a,y){var x=a.hw.I(y);return x!==null?x:a.hw.I(y.toLowerCase())}function Qf(a,y){var x=a.iw.I(y);if(x!==null||(x=a.iw.I(y.toLowerCase()),x!==null))return x;ce("Unknown DiagramEvent name: "+y)}bt.Bj=function(a,y){return a=Qf(this,a),a!==null&&a.add(y),this},bt.am=function(a,y){a=Qf(this,a),a!==null&&a.remove(y)},bt.R=function(a,y,x){var b=Qf(this,a),E=new Zh;if(E.diagram=this,a=sm(this,a),a!==null&&(E.name=a),y!==void 0&&(E.subject=y),x!==void 0&&(E.parameter=x),y=b.length,y===1)b.M(0)(E);else if(y!==0)for(b=b.Fa(),x=0;x=x.top&&0>=x.left&&0>=x.right&&0>=x.bottom)return y;var b=this.viewportBounds,E=this.scale;b=Ye.allocAt(0,0,b.width*E,b.height*E);var z=Gt.allocAt(0,0);if(a.x>=b.x&&a.xb.x+b.width-x.right&&this.allowHorizontalScroll&&(tt=Math.max(this.scrollHorizontalLineChange,1),tt|=0,z.x+=tt,a.x>b.x+b.width-x.right/2&&(z.x+=tt),a.x>b.x+b.width-x.right/4&&(z.x+=4*tt));return a.y>=b.y&&a.yb.y+b.height-x.bottom&&this.allowVerticalScroll&&(tt=Math.max(this.scrollVerticalLineChange,1),tt|=0,z.y+=tt,a.y>b.y+b.height-x.bottom/2&&(z.y+=tt),a.y>b.y+b.height-x.bottom/4&&(z.y+=4*tt)),z.Xa(qo)||(y=new Gt(y.x+z.x/E,y.y+z.y/E)),Ye.free(b),Gt.free(z),y},bt=Be.prototype,bt.Cs=function(){return null},bt.av=function(){return null},bt.bs=function(a,y){this.pj.add(a,y)},bt.Fu=function(a){(this.Pw=a)||this.nodes.each(function(y){y instanceof Fi&&(y.$p=null)})};function gf(a,y,x){function b(){var ut=+new Date;for(z=!0,tt.reset();tt.next();)if(!tt.value[0].al){z=!1;break}z||ut-lt>rt?y(x,E,ot):ue.requestAnimationFrame(b)}for(var E=x.callback,z=!0,tt=a.Og.iterator;tt.next();)if(!tt.value[0].al){z=!1;break}if(typeof E!="function"||z)return y(x,E,a);var ot=a,rt=x.callbackTimeout||300,lt=+new Date;return ue.requestAnimationFrame(function(){b()}),null}bt.Wz=function(a){return Yr?(a===void 0&&(a={}),a.returnType="Image",this.Jx(a)):null},bt.Jx=function(a){return a===void 0&&(a={}),gf(this,this.Xz,a)},bt.Xz=function(a,y,x){var b=lm(x,a,"canvas",null);if(b===null)return null;x=b.Z.canvas;var E=null;if(x!==null)switch(E=a.returnType,E===void 0?E="string":E=E.toLowerCase(),E){case zc+"data":E=b.getImageData(0,0,x.width,x.height);break;case zc:b=(a.document||document).createElement("img"),b.src=x.toDataURL(a.type,a.details),E=b;break;case"blob":return typeof y!="function"&&ce('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:E=x.toDataURL(a.type,a.details)}return typeof y=="function"?(y(E),null):E};function lm(a,y,x,b){if(a.animationManager.Cc(),a.bd(),a.ta===null)return null;typeof y!="object"&&ce("properties argument must be an Object.");var E=y.size||null,z=y.scale||null;y.scale!==void 0&&isNaN(y.scale)&&(z="NaN");var tt=y.maxSize;y.maxSize===void 0&&(tt=x==="SVG"?new Nn(1/0,1/0):new Nn(2e3,2e3));var ot=y.position||null,rt=y.parts||null,lt=y.padding===void 0?1:y.padding,ut=y.background||null,ft=y.omitTemporary;ft===void 0&&(ft=!0);var vt=y.document||document,xt=y.elementFinished||null,Ct=y.showTemporary;Ct===void 0&&(Ct=!ft),y=y.showGrid,y===void 0&&(y=Ct),E!==null&&isNaN(E.width)&&isNaN(E.height)&&(E=null),typeof lt=="number"?lt=new ci(lt):lt instanceof ci||ce("MakeImage padding must be a Margin or a number."),lt.left=Math.max(lt.left,0),lt.right=Math.max(lt.right,0),lt.top=Math.max(lt.top,0),lt.bottom=Math.max(lt.bottom,0),a.ib.Vc(!0),ft=new gu(null,vt,void 0,!0);var Ot=ft.context;if(!(E||z||rt||ot))return ft.width=a.Aa+Math.ceil(lt.left+lt.right),ft.height=a.ya+Math.ceil(lt.top+lt.bottom),x==="SVG"?b===null?null:(b.resize(ft.width,ft.height,ft.width,ft.height),b.ownerDocument=vt,b.hs=xt,Ss(a,b.context,lt,new Nn(ft.width,ft.height),a.Ca,a.pa,rt,ut,Ct,y),b.context):(a.Xm=!1,Ss(a,Ot,lt,new Nn(ft.width,ft.height),a.Ca,a.pa,rt,ut,Ct,y),a.Xm=!0,ft.context);var Kt=a.Pp,zt=a.documentBounds.copy();if(zt.Fv(a.yb),Ct)for(var te=a.Wa.s,re=te.length,he=0;heKt?(z=Kt,E=zt.width,zt=zt.height):(E=tt.width,zt=tt.height)):(E=zt.width*z,zt=zt.height*z):(z=Kt,E=zt.width,zt=zt.height),lt!==null?(E+=ot,zt+=re):lt=new ci(0),tt!==null&&(Kt=tt.width,tt=tt.height,isNaN(Kt)&&(Kt=2e3),isNaN(tt)&&(tt=2e3),isFinite(Kt)&&(E=Math.min(E,Kt)),isFinite(tt)&&(zt=Math.min(zt,tt))),ft.width=Math.ceil(E),ft.height=Math.ceil(zt),x==="SVG"?b===null?null:(b.resize(ft.width,ft.height,ft.width,ft.height),b.ownerDocument=vt,b.hs=xt,Ss(a,b.context,lt,new Nn(Math.ceil(E),Math.ceil(zt)),z,te,rt,ut,Ct,y),b.context):(a.Xm=!1,Ss(a,Ot,lt,new Nn(Math.ceil(E),Math.ceil(zt)),z,te,rt,ut,Ct,y),a.Xm=!0,ft.context)}Jt.Object.defineProperties(Be.prototype,{renderer:{get:function(){return this.nl},set:function(a){this instanceof pt||(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 ah(this,ue.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 ah(this,ue.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(ue,"resize",this.Ov,!1),this.removeEventListener(ue,"wheel",this.$j,!0),Wu===this&&(Wu=null)):this.ui===null&&(this.hf=!1),this.Ka=null,a!==null&&((y=a.H)&&(y.div=null),Mc(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||1a&&An(a,">= 0",Be,"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&&An(a,">= 0",Be,"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 b=y.style.cursor;y.style.cursor=a,x.style.cursor=a,y.style.cursor===b&&(y.style.cursor="-webkit-"+a,x.style.cursor="-webkit-"+a,y.style.cursor===b&&(y.style.cursor="-moz-"+a,x.style.cursor="-moz-"+a,y.style.cursor===b&&(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= 0",Be,"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||om(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&&ce("Do not replace a Diagram.model while a transaction is in progress."),this.animationManager.Cc(!0);var x=gd(this,!0);this.hf=!1,this.fn=!0,this.Ce=-2,this.kg=!1;var b=this.vb;this.vb=!0,ya(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=Xg(this.cc.type);for(var E=0;Ethis.scale&&(this.scale=a)):An(a,"> 0",Be,"minScale"))}},maxScale:{get:function(){return this.Mt},set:function(a){var y=this.Mt;y!==a&&(0 0",Be,"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),zl(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 ci(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&&ce("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();)yp(a.value)}},treeCollapsePolicy:{get:function(){return this.uu},set:function(a){var y=this.uu;y!==a&&(a!==xd&&a!==bs&&a!==ig&&ce("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 Nn(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 ci(a));var y=this.xp;y.D(a)||(this.xp=a=a.J(),this.Ya(),this.g("autoScrollRegion",y,a))}}}),Jt.Object.defineProperties(Be,{licenseKey:{get:function(){return sp.jc()},set:function(a){sp.add(a.replace(/\s/g,""))}},version:{get:function(){return Rc}}}),Be.prototype.makeImageData=Be.prototype.Jx,Be.prototype.makeImage=Be.prototype.Wz,Be.prototype.cacheGroupExternalLinks=Be.prototype.Fu,Be.prototype.addRenderer=Be.prototype.bs,Be.prototype.makeSVG=Be.prototype.av,Be.prototype.makeSvg=Be.prototype.Cs,Be.prototype.stopAutoScroll=Be.prototype.ug,Be.prototype.doAutoScroll=Be.prototype.gs,Be.prototype.isUnoccupied=Be.prototype.Yj,Be.prototype.raiseDiagramEvent=Be.prototype.R,Be.prototype.removeDiagramListener=Be.prototype.am,Be.prototype.addDiagramListener=Be.prototype.Bj,Be.prototype.findTreeRoots=Be.prototype.yz,Be.prototype.layoutDiagram=Be.prototype.Uz,Be.prototype.findTopLevelGroups=Be.prototype.qz,Be.prototype.findTopLevelNodesAndLinks=Be.prototype.rz,Be.prototype.ensureBounds=Be.prototype.Va,Be.prototype.findLinksByExample=Be.prototype.ls,Be.prototype.findNodesByExample=Be.prototype.ms,Be.prototype.findLinkForData=Be.prototype.Kc,Be.prototype.findNodeForData=Be.prototype.ii,Be.prototype.findPartForData=Be.prototype.Lc,Be.prototype.findLinkForKey=Be.prototype.findLinkForKey,Be.prototype.findNodeForKey=Be.prototype.Vb,Be.prototype.findPartForKey=Be.prototype.findPartForKey,Be.prototype.rebuildParts=Be.prototype.Wd,Be.prototype.transformViewToDoc=Be.prototype.Ps,Be.prototype.transformRectDocToView=Be.prototype.zA,Be.prototype.transformDocToView=Be.prototype.op,Be.prototype.centerRect=Be.prototype.es,Be.prototype.scrollToRect=Be.prototype.tv,Be.prototype.scroll=Be.prototype.scroll,Be.prototype.highlightCollection=Be.prototype.Jz,Be.prototype.highlight=Be.prototype.Iz,Be.prototype.selectCollection=Be.prototype.rA,Be.prototype.select=Be.prototype.select,Be.prototype.updateAllRelationshipsFromData=Be.prototype.rp,Be.prototype.updateAllTargetBindings=Be.prototype.updateAllTargetBindings,Be.prototype.commit=Be.prototype.commit,Be.prototype.rollbackTransaction=Be.prototype.Kf,Be.prototype.commitTransaction=Be.prototype.eb,Be.prototype.startTransaction=Be.prototype.Ea,Be.prototype.raiseChanged=Be.prototype.g,Be.prototype.raiseChangedEvent=Be.prototype.cb,Be.prototype.removeChangedListener=Be.prototype.ik,Be.prototype.addChangedListener=Be.prototype.Pe,Be.prototype.removeModelChangedListener=Be.prototype.mA,Be.prototype.addModelChangedListener=Be.prototype.Yw,Be.prototype.findLayer=Be.prototype.Qj,Be.prototype.removeLayer=Be.prototype.kA,Be.prototype.addLayerAfter=Be.prototype.Cy,Be.prototype.addLayerBefore=Be.prototype.Ww,Be.prototype.addLayer=Be.prototype.Al,Be.prototype.moveParts=Be.prototype.moveParts,Be.prototype.copyParts=Be.prototype.Kj,Be.prototype.removeParts=Be.prototype.Is,Be.prototype.remove=Be.prototype.remove,Be.prototype.add=Be.prototype.add,Be.prototype.clearDelayedGeometries=Be.prototype.bx,Be.prototype.setProperties=Be.prototype.nm,Be.prototype.attach=Be.prototype.Du,Be.prototype.set=Be.prototype.set,Be.prototype.resetInputOptions=Be.prototype.Sx,Be.prototype.setInputOption=Be.prototype.sA,Be.prototype.getInputOption=Be.prototype.Ql,Be.prototype.resetRenderingHints=Be.prototype.Tx,Be.prototype.setRenderingHint=Be.prototype.Xx,Be.prototype.getRenderingHint=Be.prototype.Gf,Be.prototype.maybeUpdate=Be.prototype.bd,Be.prototype.requestUpdate=Be.prototype.$b,Be.prototype.delayInitialization=Be.prototype.Xy,Be.prototype.isUpdateRequested=Be.prototype.Pz,Be.prototype.invalidateDocumentBounds=Be.prototype.Ya,Be.prototype.findObjectsNear=Be.prototype.og,Be.prototype.findPartsNear=Be.prototype.mz,Be.prototype.findObjectsIn=Be.prototype.Cf,Be.prototype.findPartsIn=Be.prototype.ux,Be.prototype.findObjectsAt=Be.prototype.ji,Be.prototype.findPartsAt=Be.prototype.lz,Be.prototype.findObjectAt=Be.prototype.ic,Be.prototype.findPartAt=Be.prototype.Ol,Be.prototype.focusObject=Be.prototype.zz,Be.prototype.alignDocument=Be.prototype.Jy,Be.prototype.zoomToRect=Be.prototype.BA,Be.prototype.zoomToFit=Be.prototype.zoomToFit,Be.prototype.diagramScroll=Be.prototype.kx,Be.prototype.focus=Be.prototype.focus;var ng=new ri,um=null,Yr=ue.document!==void 0,Ac=null,_d="",Ta=new Qe(Be,"None",0),Hl=new Qe(Be,"Uniform",1),Jd=new Qe(Be,"UniformToFill",2),pf=new Qe(Be,"CycleAll",10),ep=new Qe(Be,"CycleNotDirected",11),np=new Qe(Be,"CycleNotDirectedFast",12),ip=new Qe(Be,"CycleNotUndirected",13),op=new Qe(Be,"CycleDestinationTree",14),rp=new Qe(Be,"CycleSourceTree",15),Sd=new Qe(Be,"DocumentScroll",1),mf=new Qe(Be,"InfiniteScroll",2),xd=new Qe(Be,"TreeParentCollapsed",21),bs=new Qe(Be,"AllParentsCollapsed",22),ig=new Qe(Be,"AnyParentsCollapsed",23),sp=new mn,Rc="2.3.10",zc="image",vf=null,hm=!1;function Ca(){if(Yr){var a=ue.document.createElement("canvas"),y=a.getContext("2d"),x=sn("7ca11abfd022028846");y[x]=sn("398c3597c01238");for(var b=["5da73c80a36455d7038e4972187c3cae51fd22",Je.Dx+"4ae6247590da4bb21c324ba3a84e385776",Yi.xF+"fb236cdfda5de14c134ba1a95a2d4c7cc6f93c1387",Ce.za],E=1;5>E;E++)y[sn("7ca11abfd7330390")](sn(b[E-1]),10,15*E);for(y[x]=sn("39f046ebb36e4b"),x=1;5>x;x++)y[sn("7ca11abfd7330390")](sn(b[x-1]),10,15*x);(b.length!==4||b[0][0]!=="5"||b[3][0]!=="7")&&(Yi.prototype.Cd=Yi.prototype.Eu),vf=a}}Be.className="Diagram",Be.fromDiv=function(a){var y=a;return typeof a=="string"&&(y=ue.document.getElementById(a)),y instanceof HTMLDivElement&&y.H instanceof Be?y.H:null},Be.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},Be.useDOM=function(a){Yr=a?ue.document!==void 0:!1},Be.isUsingDOM=function(){return Yr},Be.None=Ta,Be.Uniform=Hl,Be.UniformToFill=Jd,Be.CycleAll=pf,Be.CycleNotDirected=ep,Be.CycleNotDirectedFast=np,Be.CycleNotUndirected=ip,Be.CycleDestinationTree=op,Be.CycleSourceTree=rp,Be.DocumentScroll=Sd,Be.InfiniteScroll=mf,Be.TreeParentCollapsed=xd,Be.AllParentsCollapsed=bs,Be.AnyParentsCollapsed=ig;function dm(){this.wy=null,this.j="zz@orderNum",this._tk==="63ad05bbe23a1786468a4c741b6d2"?this.Rc=this.j=!0:this.Rc=null}function jc(a,y){if(y.ib.setTransform(y.Mb,0,0,y.Mb,0,0),y.ib.yc(),a.Rc===null)t:{y="f";var x=ue[sn("76a715b2f73f148a")][sn("72ba13b5")]||"";if(a.Rc=!0,Yr){var b=Be[sn("76a115b6ed251eaf4692")];if(b)for(var E=sp.iterator;E.next()&&(b=E.value,b=sn(b).split(sn("39e9")),!(6>b.length));){var z=sn(b[1]).split(".");if(b[4]!=="7da71ca0")break;var tt=sn(Je[sn("6cae19")]).split(".");if(z[0]>tt[0]||z[0]===tt[0]&&z[1]>=tt[1]){var ot=ue[sn("74a900bae4370f8b51")][sn("6fbb13a1c2311e8a57")].toLowerCase();if(tt=ot[sn("73a612b6fb191d")](sn("3aad1ab6e022098b4dc4")),z=sn(b[2]),-1tt&&z!==sn("7da71ca0ad381e90")&&(tt=y[sn("73a612b6fb191d")](sn("76a715b2ef3e149757"))),0>tt&&(tt=y[sn("73a612b6fb191d")](sn("76a715b2ef3e149757"))),0>tt&&(tt=y[sn("73a612b6fb191d")](sn("2bfa41fdb3784bca12"))),0>tt&&(tt=x[sn("73a612b6fb191d")](sn("7baa19a6f76c1988428554"))),a.Rc=!(0<=tt&&ttot),!a.Rc)))break;if(z[0]==="#"){tt=ue.document.createElement("div");for(var rt=b[0].replace(/[A-Za-z]/g,"");4>rt.length;)rt+="9";if(ot=rt,rt=rt.substr(rt.length-4),b="",b+=["gsh","gsf"][parseInt(rt.substr(0,1),10)%2],b+=["Header","Background","Display","Feedback"][parseInt(rt.substr(0,1),10)%4],tt[sn("79a417a0f0181a8946")]=b,ue.document[sn("78a712aa")]){ue.document[sn("78a712aa")][sn("7bb806b6ed32388c4a875b")](tt),rt=ue.getComputedStyle(tt).getPropertyValue(sn("78a704b7e62456904c9b12701b6532a8"));var lt=ue.getComputedStyle(tt).getPropertyValue(sn("75b817b0ea2202"));if(ue.document[sn("78a712aa")][sn("68ad1bbcf533388c4a875b")](tt),rt){if(tt=ue[sn("77a902b0eb1b1e804a8a")],lt==="0."+parseInt(ot,10)%100||rt.indexOf(parseInt(z[1]+z[2],16))!==-1&&rt.indexOf(parseInt(z[3]+z[4],16))!==-1){a.Rc=!1;break}else if(tt&&tt(sn("32ae19a1e0331fc94084537c067a67fa59f1386b89d006")).matches)for(b="."+b,z=0;zb.updateDelay?b.N():b.o||(b.o=!0,setTimeout(function(){return b.redraw()},b.updateDelay))},x.Of=function(){b.observed!==null&&At(b)},x.autoScale=Hl,x.vb=!1,y&&Object.assign(x,y),x}We(pt,Be),pt.prototype.computePixelRatio=function(){return 1},pt.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(ql(this),this.ql===null){var x=new gu(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),Mt(this)}finally{this.ta=a,this.ib=y}}}Be.prototype.redraw.call(this)},pt.prototype.gc=function(){if(this.Ka===null&&ce("No div specified"),this.ta===null&&ce("No canvas specified"),!(this.ta instanceof ah)&&(Dv(this.box),this.Fc)){var a=this.observed;if(a!==null&&!a.animationManager.defaultAnimation.isAnimating&&a.pi){ql(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?Mt(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,b=0;ba&&(a=0),this.ia!==a&&(this.ia=a)}}}),pt.className="Overview";function Ut(){Dr.call(this),this.j=null}We(Ut,Dr),Ut.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.timestampy.maxScale||(y.scale=a))},Wt.prototype.canDecreaseZoom=function(a){a===void 0&&(a=1/this.zoomFactor);var y=this.diagram;return y.autoScale!==Ta?!1:(a=y.scale*a,ay.maxScale?!1:y.allowZoom)},Wt.prototype.increaseZoom=function(a){a===void 0&&(a=this.zoomFactor);var y=this.diagram;y.autoScale===Ta&&(a=y.scale*a,ay.maxScale||(y.scale=a))},Wt.prototype.canIncreaseZoom=function(a){a===void 0&&(a=this.zoomFactor);var y=this.diagram;return y.autoScale!==Ta?!1:(a=y.scale*a,ay.maxScale?!1:y.allowZoom)},Wt.prototype.resetZoom=function(a){a===void 0&&(a=this.defaultScale);var y=this.diagram;ay.maxScale||(y.scale=a)},Wt.prototype.canResetZoom=function(a){a===void 0&&(a=this.defaultScale);var y=this.diagram;return ay.maxScale?!1:y.allowZoom},Wt.prototype.zoomToFit=function(){var a=this.diagram,y=a.animationManager;y.Cc(),a.redraw();var x=a.position,b=a.scale;ya(y,"Zoom To Fit"),this.isZoomToFitRestoreEnabled&&b===this.Au&&!isNaN(this.Jt)&&a.documentBounds.D(this.yu)?(a.scale=this.Jt,a.position=this.sw,this.Au=NaN,this.yu=lo):(this.Jt=b,this.sw=x.copy(),a.zoomToFit(),this.Au=a.scale,this.yu=a.documentBounds.copy()),Xs(y)},Wt.prototype.canZoomToFit=function(){return this.diagram.allowZoom},Wt.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(rt){this.cg=null}a===null&&(0a&&(a+=360)),a},bt.Df=function(){if(!(this.l&4096))return this.Kk;var a=this.Ca;return this.panel!==null?a*this.panel.Df():a},bt.qs=function(a,y){return y===void 0&&(y=new Gt),y.assign(a),this.oe.Cd(y),y},bt.rs=function(a,y,x){return this.Sj(a.x,a.y,y.x,y.y,x)},bt.Sj=function(a,y,x,b,E){var z=this.transform,tt=1/(z.m11*z.m22-z.m12*z.m21),ot=z.m22*tt,rt=-z.m12*tt,lt=-z.m21*tt,ut=z.m11*tt,ft=tt*(z.m21*z.dy-z.m22*z.dx),vt=tt*(z.m12*z.dx-z.m11*z.dy);return this.areaBackground!==null?(z=this.actualBounds,Ce.Ff(z.left,z.top,z.right,z.bottom,a,y,x,b,E)):(tt=a*ot+y*lt+ft,a=a*rt+y*ut+vt,y=x*ot+b*lt+ft,x=x*rt+b*ut+vt,E.h(0,0),b=this.naturalBounds,x=Ce.Ff(0,0,b.width,b.height,tt,a,y,x,E),E.transform(z),x)},xe.prototype.measure=function(a,y,x,b){if($l(this)!==!1){var E=this.Kg,z=E.right+E.left;E=E.top+E.bottom,a=Math.max(a-z,0),y=Math.max(y-E,0),x=Math.max((x||0)-z,0),b=Math.max((b||0)-E,0),z=this.angle,E=this.desiredSize;var tt=this.kq();z===90||z===270?(a=isFinite(E.height)?E.height+tt:a,y=isFinite(E.width)?E.width+tt:y):(a=isFinite(E.width)?E.width+tt:a,y=isFinite(E.height)?E.height+tt:y),E=x||0,tt=b||0;var ot=this instanceof Pn;switch(el(this,!0)){case hn:tt=E=0,ot&&(y=a=1/0);break;case Sn:isFinite(a)&&a>x&&(E=a),isFinite(y)&&y>b&&(tt=y);break;case ai:isFinite(a)&&a>x&&(E=a),tt=0,ot&&(y=1/0);break;case vi:isFinite(y)&&y>b&&(tt=y),E=0,ot&&(a=1/0)}ot=this.maxSize;var rt=this.minSize;E>ot.width&&rt.widthot.height&&rt.heighta.height||this.Cb>a.width))&&(x=!0)),this.l=x?this.l|256:this.l&-257,this.Ib.w()||ce("Non-real actualBounds has been set. Object "+this+", actualBounds: "+this.Ib.toString()),this.Xl(z,this.Ib),Mh(this,!1),Ye.free(z)},bt=xe.prototype,bt.eh=function(){};function Oa(a,y,x,b,E){if(a.Ib.h(y,x,b,E),!a.desiredSize.w()){var z=a.uc;x=a.Kg,y=x.right+x.left;var tt=x.top+x.bottom;switch(x=z.width+y,z=z.height+tt,b+=y,E+=tt,y=el(a,!0),x===b&&z===E&&(y=hn),y){case hn:(x>b||z>E)&&(Ls(a,!0),a.measure(x>b?b:x,z>E?E:z,0,0));break;case Sn:Ls(a,!0),a.measure(b,E,0,0);break;case ai:Ls(a,!0),a.measure(b,z,0,0);break;case vi:Ls(a,!0),a.measure(x,E,0,0)}}}bt.Xl=function(a,y){var x=this.part;x!==null&&x.diagram!==null&&(x.selectionObject!==this&&x.resizeObject!==this&&x.rotateObject!==this||zv(x,!0),this.N(),uu(a,y)||(x.oh(),this.Pn(x)))},bt.Pn=function(a){this.portId!==null&&(zv(a,!0),a instanceof Dn&&WS(a,this))},bt.gc=function(a,y){if(!tu(this,a,y)&&this.visible){var x=this.opacity;if(x!==0){var b=1;x!==1&&(b=a.globalAlpha,a.globalAlpha=b*x);var E="";this.filter!==""&&(E=a.filter,a.filter=this.filter);var z=this instanceof Pn&&Cd(this),tt=this.Ib;if(z){var ot=this.Ib,rt=this.dc,lt=this.areaBackground,ut=this.Ma;lt===null&&ut===null||a.yc(),lt!==null&&(_r(this,a,lt,!0,!0,rt,ot),lt instanceof _o&<.type===iu?(a.beginPath(),a.rect(ot.x,ot.y,ot.width,ot.height),a.ng(lt)):a.fillRect(ot.x,ot.y,ot.width,ot.height)),ut!==null&&(_r(this,a,ut,!0,!1,rt,ot),ut instanceof _o&&ut.type===iu?(a.beginPath(),a.rect(ot.x,ot.y,ot.width,ot.height),a.ng(ut)):a.fillRect(ot.x,ot.y,ot.width,ot.height)),this.hh(a,y)}if(!z&&(z||tt.width!==0&&tt.height!==0&&!isNaN(tt.x)&&!isNaN(tt.y))){z=this.transform,ot=this.panel,this.l&4096&&sa(this),lt=this.part,rt=!1;var ft=0;lt&&y.Gf("drawShadows")&&(rt=lt.isShadowed)&&(ut=lt.shadowOffset,ft=Math.max(ut.y,ut.x)*y.scale*y.Mb),ut=this.Dd();var vt;if(!(vt=y.$i||!ut)){var xt=this.naturalBounds;vt=this.wh;var Ct=vt.m11,Ot=vt.m21,Kt=vt.dx,zt=vt.m12,te=vt.m22,re=vt.dy,he,ve=he=0;vt=he*Ct+ve*Ot+Kt;var De=he*zt+ve*te+re;he=xt.width+ft,ve=0;var Fn=he*Ct+ve*Ot+Kt;he=he*zt+ve*te+re,ve=Math.min(vt,Fn);var Vn=Math.min(De,he),Wn=Math.max(vt+0,Fn)-ve,bn=Math.max(De+0,he)-Vn;vt=ve,De=Vn,he=xt.width+ft,ve=xt.height+ft,Fn=he*Ct+ve*Ot+Kt,he=he*zt+ve*te+re,ve=Math.min(vt,Fn),Vn=Math.min(De,he),Wn=Math.max(vt+Wn,Fn)-ve,bn=Math.max(De+bn,he)-Vn,vt=ve,De=Vn,he=0,ve=xt.height+ft,Fn=he*Ct+ve*Ot+Kt,he=he*zt+ve*te+re,ve=Math.min(vt,Fn),Vn=Math.min(De,he),Wn=Math.max(vt+Wn,Fn)-ve,bn=Math.max(De+bn,he)-Vn,vt=ve,De=Vn,ft=y.viewportBounds,xt=ft.x,Ct=ft.y,vt=!(vt>ft.width+xt||xt>Wn+vt||De>ft.height+Ct||Ct>bn+De)}if(vt){if(vt=(this.l&256)!==0,a.clipInsteadOfFill&&(vt=!1),this instanceof fr&&(a.font=this.font),vt){if(De=ot.se()?ot.naturalBounds:ot.actualBounds,Wn=Math.max(tt.x,De.x),bn=Math.max(tt.y,De.y),ft=Math.min(tt.right,De.right)-Wn,xt=Math.min(tt.bottom,De.bottom)-bn,Ct=this.tb,Ct!==null&&(Wn=Ct.x,bn=Ct.y,ft=Ct.width,xt=Ct.height),Wn>tt.width+tt.x||tt.x>De.width+De.x){x!==1&&(a.globalAlpha=b),this.filter!==""&&(a.filter=E);return}a.save(),a.beginPath(),a.rect(Wn,bn,ft,xt),a.clip()}if(ut){if(!lt.isVisible()){x!==1&&(a.globalAlpha=b),this.filter!==""&&(a.filter=E);return}rt&&(De=lt.shadowOffset,a.Ev(De.x*y.scale*this.scale*y.Mb,De.y*y.scale*this.scale*y.Mb,lt.shadowBlur),Qh(a),a.shadowColor=lt.shadowColor)}rt&&this.shadowVisible===!0?Qh(a):rt&&this.shadowVisible===!1&&Eh(a),lt=this.naturalBounds,this.areaBackground!==null&&(a.yc(),Gl(this,a,lt,tt)),a.transform(z.m11,z.m12,z.m21,z.m22,z.dx,z.dy),rt&&ta(this,ot)&&this.shadowVisible===null&&Eh(a),this.Ma!==null&&(a.yc(),dl(this,a,lt,tt)),rt&&(this.Ma!==null||this.areaBackground!==null||ta(this,ot))?(Lu(this,!0),this.shadowVisible===null&&Eh(a)):Lu(this,!1),this.hh(a,y),rt&&this.l&512&&Qh(a),ut&&rt&&Eh(a),vt&&(a.restore(),a.Vc(this instanceof Pn)),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=b),this.filter!==""&&(a.filter=E)}}};function ta(a,y){return y===null?!1:(Cd(y)&&(y=y.panel),(y.l&512)!==0||(y.type===Pn.Auto||y.type===Pn.Spot)&&y.Pb()!==a)}bt.Dv=function(){};function Gl(a,y,x,b){_r(a,y,a.areaBackground,!0,!0,x,b),a.areaBackground instanceof _o&&a.areaBackground.type===iu?(y.beginPath(),y.rect(b.x,b.y,b.width,b.height),y.ng(a.areaBackground)):y.fillRect(b.x,b.y,b.width,b.height)}function dl(a,y,x,b){var E=a.kq(),z=x.x,tt=x.y,ot=x.width+E,rt=x.height+E;_r(a,y,a.Ma,!0,!1,x,b),a.Ma instanceof _o&&a.Ma.type===iu?(y.beginPath(),y.rect(z-E/2,tt-E/2,ot,rt),y.ng(a.Ma)):y.fillRect(z-E/2,tt-E/2,ot,rt)}function ba(a,y,x){for(var b=y.O.s,E=b.length,z=-1,tt=0;ttE)&&ce("Must specify non-negative integer row for RowColumnDefinition "+y+", not: "+E),a.isRow=!0,a.index=E):y.column!==void 0&&(E=y.column,(E==null||E===1/0||isNaN(E)||0>E)&&ce("Must specify non-negative integer column for RowColumnDefinition "+y+", not: "+E),a.isRow=!1,a.index=E),E=new bi;for(x in y)x!=="row"&&x!=="column"&&(E[x]=y[x]);Ql(a,E)}else Ql(a,y);else ce('Unknown initializer "'+y+'" for object being constructed by GraphObject.make: '+a)}function Pd(a,y){og.add(a,y)}function cm(a,y,x){x===void 0&&(x=null);var b=a[1];if(typeof x=="function"?x(b):typeof b=="string")return a.splice(1,1),b;if(y===void 0)throw Error("no "+(typeof x=="function"?"satisfactory":"string")+" argument for GraphObject builder "+a[0]);return y}Jt.Object.defineProperties(xe.prototype,{bindingId:{get:function(){return this.A!==null?this.A.zp:-1},set:function(a){this.bindingId!==a&&(this.A===null&&(this.A=new xf),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 xf),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 xf),this.A.wm=a)}},shadowVisible:{get:function(){return this.A!==null?this.A.Ci:null},set:function(a){var y=this.shadowVisible;y!==a&&(Xi(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&&(Xi(this),this.A.Hb=a,this.g("enabledChanged",y,a))}},segmentOrientation:{get:function(){return this.Ua!==null?this.Ua.rr:$a},set:function(a){var y=this.segmentOrientation;y!==a&&(this.Ua===null&&(this.Ua=new Qd),this.Ua.rr=a,this.v(),this.g("segmentOrientation",y,a),a===$a&&(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 Qd),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:1a||1=a&&ce("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,Uy(this),this.v(),this.g("angle",y,a)))}},desiredSize:{get:function(){return this.jd},set:function(a){var y=a.width,x=a.height,b=this.jd,E=b.width,z=b.height;(E===y||isNaN(E)&&isNaN(y))&&(z===x||isNaN(z)&&isNaN(x))||(this.jd=a=a.J(),this.v(),this instanceof Ki&&this.qc(),this.g("desiredSize",b,a),fa(this)&&(a=this.part,a!==null&&(yr(this,a,"width"),yr(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 Nn(a,this.jd.height).freeze(),this.v(),this instanceof Ki&&this.qc(),this.g("desiredSize",y,a),fa(this)&&(a=this.part,a!==null&&yr(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 Nn(this.jd.width,a).freeze(),this.v(),this instanceof Ki&&this.qc(),this.g("desiredSize",y,a),fa(this)&&(a=this.part,a!==null&&yr(this,a,"height")))}},minSize:{get:function(){return this.A!==null?this.A.u:Zi},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(),Xi(this),this.A.u=a,this.v(),this.g("minSize",y,a))}},maxSize:{get:function(){return this.A!==null?this.A.o:Ns},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(),Xi(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 ci(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&&sa(this),this.Ab}},oe:{get:function(){return this.l&4096&&sa(this),this.wh}},animationTriggers:{get:function(){return this.A!==null?this.A.hb:null},set:function(a){this.animationTriggers!==a&&(Xi(this),this.A.hb=a)}},reshapingBehavior:{get:function(){return this.A!==null?this.A.Pf:hn},set:function(a){this.reshapingBehavior!==a&&(Xi(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()&&ce("GraphObject.alignment for "+this+" must be a real Spot or Spot.Default, not: "+a),this.Jb=a=a.J(),za(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&&An(a,">= 0",xe,"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&&An(a,">= 1",xe,"columnSpan"),Xi(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&&An(a,">= 0",xe,"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&&An(a,">= 1",xe,"rowSpan"),Xi(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&&(Xi(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 Dn||ce("Cannot set portID on a Link: "+a),y!==null&&x!==null&&$v(x,this),this.Yn=a,a!==null&&x!==null&&(x.Te=!0,VS(x,this)),this.g("portId",y,a)}}},toSpot:{get:function(){return this.ba!==null?this.ba.yj:Qr},set:function(a){var y=this.toSpot;y.D(a)||(a=a.J(),this.Xc(),this.ba.yj=a,this.g("toSpot",y,a),Hc(this))}},toEndSegmentLength:{get:function(){return this.ba!==null?this.ba.wj:10},set:function(a){var y=this.toEndSegmentLength;y!==a&&(0>a&&An(a,">= 0",xe,"toEndSegmentLength"),this.Xc(),this.ba.wj=a,this.g("toEndSegmentLength",y,a),Hc(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),Hc(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&&An(a,">= 0",xe,"toMaxLinks"),this.Xc(),this.ba.Ur=a,this.g("toMaxLinks",y,a))}},fromSpot:{get:function(){return this.ba!==null?this.ba.Xi:Qr},set:function(a){var y=this.fromSpot;y.D(a)||(a=a.J(),this.Xc(),this.ba.Xi=a,this.g("fromSpot",y,a),Hc(this))}},fromEndSegmentLength:{get:function(){return this.ba!==null?this.ba.Vi:10},set:function(a){var y=this.fromEndSegmentLength;y!==a&&(0>a&&An(a,">= 0",xe,"fromEndSegmentLength"),this.Xc(),this.ba.Vi=a,this.g("fromEndSegmentLength",y,a),Hc(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),Hc(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&&An(a,">= 0",xe,"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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(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&&(Xi(this),this.A.Ch=a,this.g("contextMenu",y,a))}}}),xe.prototype.trigger=xe.prototype.Jv,xe.prototype.findBindingPanel=xe.prototype.ih,xe.prototype.findTemplateBinder=xe.prototype.pz,xe.prototype.setProperties=xe.prototype.nm,xe.prototype.apply=xe.prototype.apply,xe.prototype.attach=xe.prototype.Du,xe.prototype.set=xe.prototype.set,xe.prototype.isEnabledObject=xe.prototype.If,xe.prototype.isVisibleObject=xe.prototype.Ed,xe.prototype.isContainedBy=xe.prototype.rg,xe.prototype.getNearestIntersectionPoint=xe.prototype.rs,xe.prototype.getLocalPoint=xe.prototype.qs,xe.prototype.getDocumentScale=xe.prototype.Df,xe.prototype.getDocumentAngle=xe.prototype.li,xe.prototype.getDocumentBounds=xe.prototype.mi,xe.prototype.getDocumentPoint=xe.prototype.ga,xe.prototype.intersectsRect=xe.prototype.Yc,xe.prototype.containedInRect=xe.prototype.fh,xe.prototype.containsRect=xe.prototype.Re,xe.prototype.containsPoint=xe.prototype.ca,xe.prototype.raiseChanged=xe.prototype.g,xe.prototype.raiseChangedEvent=xe.prototype.cb,xe.prototype.addCopyProperty=xe.prototype.Vw;var og=null;xe.className="GraphObject",og=new ri,Pd("Button",function(){function a(x,b){return x.diagram.ic(x.documentPoint,function(E){for(;E.panel!==null&&!E.isActionable;)E=E.panel;return E},function(E){return E===b})!==null}var y=nu(Pn,Pn.Auto,{isActionable:!0,enabledChanged:function(x,b){if(x instanceof Pn){var E=x.fb("ButtonBorder");E!==null&&(E.fill=b?x._buttonFillNormal:x._buttonFillDisabled)}},cursor:"pointer",_buttonFillNormal:"#F5F5F5",_buttonStrokeNormal:"#BDBDBD",_buttonFillOver:"#E0E0E0",_buttonStrokeOver:"#9E9E9E",_buttonFillPressed:"#BDBDBD",_buttonStrokePressed:"#9E9E9E",_buttonFillDisabled:"#E5E5E5"},nu(Ki,{name:"ButtonBorder",figure:"RoundedRectangle",spot1:new ei(0,0,2.76142374915397,2.761423749153969),spot2:new ei(1,1,-2.76142374915397,-2.761423749153969),parameter1:2,parameter2:2,fill:"#F5F5F5",stroke:"#BDBDBD"}));return y.mouseEnter=function(x,b){if(b.If()&&b instanceof Pn&&(x=b.fb("ButtonBorder"),x instanceof Ki)){var E=b._buttonFillOver;b._buttonFillNormal=x.fill,x.fill=E,E=b._buttonStrokeOver,b._buttonStrokeNormal=x.stroke,x.stroke=E}},y.mouseLeave=function(x,b){b.If()&&b instanceof Pn&&(x=b.fb("ButtonBorder"),x instanceof Ki&&(x.fill=b._buttonFillNormal,x.stroke=b._buttonStrokeNormal))},y.actionDown=function(x,b){if(b.If()&&b instanceof Pn&&b._buttonFillPressed!==null&&x.button===0){var E=b.fb("ButtonBorder");if(E instanceof Ki){x=x.diagram;var z=x.skipsUndoManager;x.skipsUndoManager=!0;var tt=b._buttonFillPressed;b._buttonFillOver=E.fill,E.fill=tt,tt=b._buttonStrokePressed,b._buttonStrokeOver=E.stroke,E.stroke=tt,x.skipsUndoManager=z}}},y.actionUp=function(x,b){if(b.If()&&b instanceof Pn&&b._buttonFillPressed!==null&&x.button===0){var E=b.fb("ButtonBorder");if(E instanceof Ki){var z=x.diagram,tt=z.skipsUndoManager;z.skipsUndoManager=!0,a(x,b)?(E.fill=b._buttonFillOver,E.stroke=b._buttonStrokeOver):(E.fill=b._buttonFillNormal,E.stroke=b._buttonStrokeNormal),z.skipsUndoManager=tt}}},y.actionCancel=function(x,b){if(b.If()&&b instanceof Pn&&b._buttonFillPressed!==null){var E=b.fb("ButtonBorder");if(E instanceof Ki){var z=x.diagram,tt=z.skipsUndoManager;z.skipsUndoManager=!0,a(x,b)?(E.fill=b._buttonFillOver,E.stroke=b._buttonStrokeOver):(E.fill=b._buttonFillNormal,E.stroke=b._buttonStrokeNormal),z.skipsUndoManager=tt}}},y.actionMove=function(x,b){if(b.If()&&b instanceof Pn&&b._buttonFillPressed!==null){var E=x.diagram;if(E.firstInput.button===0&&(E.currentTool.standardMouseOver(),a(x,b)&&(x=b.fb("ButtonBorder"),x instanceof Ki))){var z=E.skipsUndoManager;E.skipsUndoManager=!0;var tt=b._buttonFillPressed;x.fill!==tt&&(x.fill=tt),tt=b._buttonStrokePressed,x.stroke!==tt&&(x.stroke=tt),E.skipsUndoManager=z}}},y}),Pd("TreeExpanderButton",function(){var a=nu("Button",{_treeExpandedFigure:"MinusLine",_treeCollapsedFigure:"PlusLine"},nu(Ki,{name:"ButtonIcon",figure:"MinusLine",stroke:"#424242",strokeWidth:2,desiredSize:Ir},new cs("figure","isTreeExpanded",function(y,x){return x=x.panel,y?x._treeExpandedFigure:x._treeCollapsedFigure}).cp()),{visible:!1},new cs("visible","isTreeLeaf",function(y){return!y}).cp());return a.click=function(y,x){if(x=x.part,x instanceof Oo&&(x=x.adornedPart),x instanceof Dn){var b=x.diagram;if(b!==null){if(b=b.commandHandler,x.isTreeExpanded){if(!b.canCollapseTree(x))return}else if(!b.canExpandTree(x))return;y.handled=!0,x.isTreeExpanded?b.collapseTree(x):b.expandTree(x)}}},a}),Pd("SubGraphExpanderButton",function(){var a=nu("Button",{_subGraphExpandedFigure:"MinusLine",_subGraphCollapsedFigure:"PlusLine"},nu(Ki,{name:"ButtonIcon",figure:"MinusLine",stroke:"#424242",strokeWidth:2,desiredSize:Ir},new cs("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 Oo&&(x=x.adornedPart),x instanceof Fi){var b=x.diagram;if(b!==null){if(b=b.commandHandler,x.isSubGraphExpanded){if(!b.canCollapseSubGraph(x))return}else if(!b.canExpandSubGraph(x))return;y.handled=!0,x.isSubGraphExpanded?b.collapseSubGraph(x):b.expandSubGraph(x)}}},a}),Pd("ToolTip",function(){return nu(Oo,Pn.Auto,{isShadowed:!0,shadowColor:"rgba(0, 0, 0, .4)",shadowOffset:new Gt(0,3),shadowBlur:5},nu(Ki,{name:"Border",figure:"RoundedRectangle",parameter1:1,parameter2:1,fill:"#F5F5F5",stroke:"#F0F0F0",spot1:new ei(0,0,4,6),spot2:new ei(1,1,-4,-4)}))}),Pd("ContextMenu",function(){return nu(Oo,Pn.Vertical,{background:"#F5F5F5",isShadowed:!0,shadowColor:"rgba(0, 0, 0, .4)",shadowOffset:new Gt(0,3),shadowBlur:5},new cs("background","",function(a){return a.adornedPart!==null&&a.placeholder!==null?null:"#F5F5F5"}))}),Pd("ContextMenuButton",function(){var a=nu("Button");a.stretch=ai;var y=a.fb("ButtonBorder");return y instanceof Ki&&(y.figure="Rectangle",y.strokeWidth=0,y.spot1=new ei(0,0,2,3),y.spot2=new ei(1,1,-2,-2)),a}),Pd("PanelExpanderButton",function(a){var y=cm(a,"COLLAPSIBLE"),x=nu("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},nu(Ki,{name:"ButtonIcon",strokeWidth:2},new cs("geometryString","visible",function(b){return b?x._buttonExpandedFigure:x._buttonCollapsedFigure}).cp(y)));return a=x.fb("ButtonBorder"),a instanceof Ki&&(a.stroke=null,a.fill="rgba(0, 0, 0, 0)"),x.click=function(b,E){var z=E.diagram;if(z!==null&&!z.isReadOnly){var tt=E.ih();tt===null&&(tt=E.part),tt!==null&&(E=tt.fb(y),E!==null&&(b.handled=!0,z.Ea("Collapse/Expand Panel"),E.visible=!E.visible,z.eb("Collapse/Expand Panel")))}},x}),Pd("CheckBoxButton",function(a){var y=cm(a);return a=nu("Button",{desiredSize:new Nn(14,14)},nu(Ki,{name:"ButtonIcon",geometryString:"M0 0 M0 8.85 L4.9 13.75 16.2 2.45 M16.2 16.2",strokeWidth:2,stretch:Sn,geometryStretch:_n,visible:!1},y!==""?new cs("visible",y).Kx():[])),a.click=function(x,b){if(b instanceof Pn){var E=x.diagram;if(!(E===null||E.isReadOnly||y!==""&&E.model.isReadOnly)){x.handled=!0;var z=b.fb("ButtonIcon");E.Ea("checkbox"),z.visible=!z.visible,typeof b._doClick=="function"&&b._doClick(x,b),E.eb("checkbox")}}},a}),Pd("CheckBox",function(a){a=cm(a),a=nu("CheckBoxButton",a,{name:"Button",isActionable:!1,margin:new ci(0,1,0,0)});var y=nu(Pn,"Horizontal",a,{isActionable:!0,cursor:a.cursor,margin:new ci(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}),xe.None=hn=new Qe(xe,"None",0),xe.Default=Di=new Qe(xe,"Default",0),xe.Vertical=vi=new Qe(xe,"Vertical",4),xe.Horizontal=ai=new Qe(xe,"Horizontal",5),xe.Fill=Sn=new Qe(xe,"Fill",3),xe.Uniform=_n=new Qe(xe,"Uniform",1),xe.UniformToFill=uo=new Qe(xe,"UniformToFill",2),xe.FlipVertical=Ji=new Qe(xe,"FlipVertical",1),xe.FlipHorizontal=Lo=new Qe(xe,"FlipHorizontal",2),xe.FlipBoth=or=new Qe(xe,"FlipBoth",3),xe.make=nu,xe.getBuilders=function(){var a=new ri,y;for(y in og)if(y!==y.toLowerCase()){var x=og.I(y);typeof x=="function"&&a.add(y,x)}return a.freeze(),a},xe.defineBuilder=Pd,xe.build=function(a,y,x){for(var b=[],E=2;Ea&&(a+=360),a!==0){if(this.translate(y,x),a===90){a=0;var b=1}else a===180?(a=-1,b=0):a===270?(a=0,b=-1):(b=a*Math.PI/180,a=Math.cos(b),b=Math.sin(b));var E=this.ha[1]*a+this.ha[3]*b,z=this.ha[0]*-b+this.ha[2]*a,tt=this.ha[1]*-b+this.ha[3]*a;this.ha[0]=this.ha[0]*a+this.ha[2]*b,this.ha[1]=E,this.ha[2]=z,this.ha[3]=tt,this.translate(-y,-x)}},Gc.className="STransform";function Pf(a){this.type=a,this.r2=this.y2=this.x2=this.r1=this.y1=this.x1=0,this.gx=[],this.pattern=null}Pf.prototype.addColorStop=function(a,y){this.gx.push({offset:a,color:y})},Pf.className="SGradient";function ah(a,y,x){this.ownerDocument=a=y===void 0?ue.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 Pl(this,x)}ah.prototype.resize=function(a,y,x,b){return this.width!==a||this.height!==y?(this.width=a,this.height=y,this.style.width=x+"px",this.style.height=b+"px",this.Oa.setAttributeNS(null,"width",x+"px"),this.Oa.setAttributeNS(null,"height",b+"px"),this.Oa.setAttributeNS(null,"viewBox","0 0 "+x+" "+b),this.context.ww.firstElementChild.setAttributeNS(null,"width",x+"px"),this.context.ww.firstElementChild.setAttributeNS(null,"height",b+"px"),!0):!1},ah.prototype.Ud=function(a,y,x){if(a=this.ownerDocument.createElementNS(this.cA,a),Ae(y))for(var b in y)a.setAttributeNS(b==="href"?"http://www.w3.org/1999/xlink":"",b,y[b]);return x!==void 0&&(a.textContent=x),a},ah.prototype.getBoundingClientRect=function(){return this.Oa.getBoundingClientRect()},ah.prototype.focus=function(){this.Oa.focus()},ah.prototype.mx=function(){this.ownerDocument=null},Jt.Object.defineProperties(ah.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}}}),ah.className="SVGSurface";function Pl(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 Gc,this.j=fm(this),this.Nj=fm(this,"gojs-diagram"),this.Hl=this.ti=null;var x=Hr++,b=this.Ud("clipPath",{id:"mainClip"+x});b.appendChild(this.Ud("rect",{x:0,y:0,width:a.width,height:a.height})),this.ww=b,this.svg.appendChild(this.j),this.j.appendChild(this.Nj),this.svg.appendChild(b),this.j.setAttributeNS(null,"clip-path","url(#mainClip"+x+")"),this.eA={},this.isTemporary=!!y,this.filter="",this.bk=null}function Yy(a,y,x,b,E,z,tt){a.Nj===void 0?lp(a,y,x,b,E,z,tt):a.Nj.setAttribute("transform","matrix("+y+", "+x+", "+b+", "+E+", "+z+", "+tt+")")}bt=Pl.prototype,bt.arc=function(a,y,x,b,E,z,tt,ot){var rt=2*Math.PI,lt=rt-1e-6,ut=x*Math.cos(b),ft=x*Math.sin(b),vt=a+ut,xt=y+ft,Ct=z?0:1;b=z?b-E:E-b,(1e-6b&&(b=b%rt+rt),b>lt?(this.path.push(["A",x,x,0,1,Ct,a-ut,y-ft]),this.path.push(["A",x,x,0,1,Ct,vt,xt])):1e-6=Math.PI),Ct,a+x*Math.cos(E),y+x*Math.sin(E)])},bt.beginPath=function(){this.path=[],this.Yl={stroke:"none",fill:"none"}},bt.Se=function(a){this.addPath(this.path,this.rb,a||0)},bt.bezierCurveTo=function(a,y,x,b,E,z){this.path.push(["C",a,y,x,b,E,z])},bt.clearRect=function(){},bt.clip=function(){this.Yl.clipPath=!0},bt.closePath=function(){this.path.push(["z"])},bt.createLinearGradient=function(a,y,x,b){var E=new Pf("linear");return E.x1=a,E.y1=y,E.x2=x,E.y2=b,E},bt.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 b="PATTERN"+Hr++,E={x:0,y:0,width:a.width,height:a.height,href:y};return a=this.Ud("pattern",{width:a.width,height:a.height,id:b,patternUnits:"userSpaceOnUse"}),a.appendChild(this.Ud(zc,E)),this.svg.appendChild(a),x[y]=b,"url(#"+b+")"},bt.createRadialGradient=function(a,y,x,b,E,z){var tt=new Pf("radial");return tt.x1=a,tt.y1=y,tt.r1=x,tt.x2=b,tt.y2=E,tt.r2=z,tt};function Xy(a,y,x,b,E,z,tt,ot,rt){b=ot/b,E=rt/E,z===0&&tt===0||a.rb.translate(z,tt),b===1&&E===1||a.rb.scale(b,E),y===0&&x===0||a.rb.translate(-y,-x)}bt.drawImage=function(a,y,x,b,E,z,tt,ot,rt){var lt="";a instanceof HTMLCanvasElement&&(lt=a.toDataURL()),a instanceof HTMLImageElement&&(lt=a.getAttribute("src"));var ut=a instanceof HTMLImageElement?a.naturalWidth:a.width;a=a instanceof HTMLImageElement?a.naturalHeight:a.height,b===void 0&&(z=y,tt=x,ot=b=ut,rt=E=a),b=b||0,E=E||0,ot=ot||0,rt=rt||0,Xy(this,y,x,b,E,z||0,tt||0,ot,rt),z={x:0,y:0,width:ut||b,height:a||E,href:lt},Ce.$(b,ot)&&Ce.$(E,rt)?lt.toLowerCase().indexOf(".svg")===-1&<.toLowerCase().indexOf("data:image/svg")===-1&&(z.preserveAspectRatio="xMidYMid slice"):z.preserveAspectRatio="none",(y!==0||x!==0||b!==ut||E!==a)&&(b+=y,E+=x,z["clip-path"]="path('M "+y+","+x+" L "+b+" "+x+" L "+b+" "+E+" L "+y+" "+E+" z')"),rg(this,zc,z,this.rb),this.addElement(zc,z)},bt.fill=function(a){a&&(this.Yl["fill-rule"]="evenodd"),iv(this,this.Yl)},bt.ng=function(a,y){this.clipInsteadOfFill?this.clip():this.fill(y)},bt.fillRect=function(a,y,x,b){a=[a,y,x,b],a={x:a[0],y:a[1],width:a[2],height:a[3]},rg(this,"fill",a,this.rb),this.addElement("rect",a)},bt.ox=function(a,y,x,b){a={x:a,y,width:x,height:b},rg(this,"fill",a,this.rb),iv(this,a),this.svg.prepend(this.Ud("rect",a))},bt.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},rg(this,"fill",y,this.rb),this.addElement("text",y,a[0])},bt.lineTo=function(a,y){this.path.push(["L",a,y])},bt.moveTo=function(a,y){this.path.push(["M",a,y])},bt.quadraticCurveTo=function(a,y,x,b){this.path.push(["Q",a,y,x,b])},bt.rect=function(a,y,x,b){this.path.push(["M",a,y],["L",a+x,y],["L",a+x,y+b],["L",a,y+b],["z"])},bt.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},bt.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;yut.offset?1:-1}),E=0;Ex?(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)},bt.jk=function(){this.Hm||this.stroke()},bt.Ev=function(a,y,x){this.Ar=a,this.Br=y,this.Vg=x},bt.js=function(a,y){var x=this.Z;x.setLineDash!==void 0&&(x.setLineDash(a),x.lineDashOffset=y)},bt.fs=function(){var a=this.Z;a.setLineDash!==void 0&&(a.setLineDash(mx),a.lineDashOffset=0)},bt.Vc=function(a){a&&(this.dt=""),this.ct=this.et=""},bt.Hs=function(){},Jt.Object.defineProperties($c.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([]);$c.className="CanvasSurfaceContext";function up(){this.F=this.o=this.u=this.j=0}up.className="ColorNumbers";function _o(a,y){ug||(hv(),ug=!0),Po(this),this._isFrozen=!1,a===void 0?(this.na=wd,this.xk="black"):typeof a=="string"?(this.na=wd,this.xk=a):(this.na=a,this.xk="black"),a=this.na,a===td?(this.Qd=vl,this.Lk=_a):this.Lk=a===iu?this.Qd=Co:this.Qd=Qr,this.Gr=0,this.Xp=NaN,this.xe=this.cr=this.we=null,this.ft=this.yk=0,y&&Object.assign(this,y)}_o.prototype.copy=function(){var a=new _o;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},bt=_o.prototype,bt.freeze=function(){return this._isFrozen=!0,this.we!==null&&this.we.freeze(),this},bt.ka=function(){return Object.isFrozen(this)&&ce("cannot thaw constant: "+this),this._isFrozen=!1,this.we!==null&&this.we.ka(),this},bt.qb=function(a){a.classType===_o&&(this.type=a)},bt.toString=function(){var a="Brush(";if(this.type===wd)a+=this.color;else if(a=this.type===td?a+"Linear ":this.type===iu?a+"Radial ":this.type===hg?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+")"},bt.addColorStop=function(a,y){return this._isFrozen&&vn(this),(typeof a!="number"||!isFinite(a)||1a)&&An(a,"0 <= loc <= 1",_o,"addColorStop:loc"),this.we===null&&(this.we=new ri),this.we.add(a,y),this.na===wd&&(this.type=td),this.xe=null,this},bt.Vz=function(a,y){if(this._isFrozen&&vn(this),a=a===void 0||typeof a!="number"?.2:a,y=y===void 0?dg:y,this.type===wd)qh(this.color),this.color=ag(a,y);else if((this.type===td||this.type===iu)&&this.colorStops!==null)for(var x=this.colorStops.iterator;x.next();)qh(x.value),this.addColorStop(x.key,ag(a,y));return this};function qy(a,y,x){return y=y===void 0||typeof y!="number"?.2:y,x=x===void 0?dg:x,qh(a),ag(y,x)}bt.Wy=function(a,y){if(this._isFrozen&&vn(this),a=a===void 0||typeof a!="number"?.2:a,y=y===void 0?dg:y,this.type===wd)qh(this.color),this.color=ag(-a,y);else if((this.type===td||this.type===iu)&&this.colorStops!==null)for(var x=this.colorStops.iterator;x.next();)qh(x.value),this.addColorStop(x.key,ag(-a,y));return this};function tS(a,y,x){return y=y===void 0||typeof y!="number"?.2:y,x=x===void 0?dg:x,qh(a),ag(-y,x)}function rv(a,y,x){qh(a),a=mr.j;var b=mr.u,E=mr.o,z=mr.F;return qh(y),x===void 0&&(x=.5),"rgba("+Math.round((mr.j-a)*x+a)+", "+Math.round((mr.u-b)*x+b)+", "+Math.round((mr.o-E)*x+E)+", "+Math.round((mr.F-z)*x+z)+")"}bt.Gx=function(){if(this.type===wd)return sg(this.color);if((this.type===td||this.type===iu)&&this.colorStops!==null){var a=this.colorStops;if(this.type===iu)return sg(a.first().value);if(a.get(.5)!==null)return sg(a.get(.5));if(a.count===2)return a=a.Fa(),sg(rv(a[0].value,a[1].value));for(var y=a.iterator,x=-1,b=-1,E=1,z=1;y.next();){var tt=y.key,ot=Math.abs(.5-y.key);E>z&&ot=E&&otb&&(z=x,x=b,b=z,z=E),E=b-x,sg(rv(a.get(x),a.get(b),1-z/E))}return!1};function sg(a){return a?a instanceof _o?a.Gx():(qh(a),128>(299*mr.j+587*mr.u+114*mr.o)/1e3):!1}function ag(a,y){switch(y){case dg:y=100*av(mr.j);var x=100*av(mr.u),b=100*av(mr.o);return Ha.j=.4124564*y+.3575761*x+.1804375*b,Ha.u=.2126729*y+.7151522*x+.072175*b,Ha.o=.0193339*y+.119192*x+.9503041*b,Ha.F=mr.F,y=uv(Ha.j/lg[0]),x=uv(Ha.u/lg[1]),b=uv(Ha.o/lg[2]),kh.j=116*x-16,kh.u=500*(y-x),kh.o=200*(x-b),kh.F=Ha.F,kh.j=Math.min(100,Math.max(0,kh.j+100*a)),a=(kh.j+16)/116,y=a-kh.o/200,Ha.j=lg[0]*eS(kh.u/500+a),Ha.u=lg[1]*(kh.j>pm*dv?Math.pow(a,3):kh.j/pm),Ha.o=lg[2]*eS(y),Ha.F=kh.F,a=-.969266*Ha.j+1.8760108*Ha.u+.041556*Ha.o,y=.0556434*Ha.j+-.2040259*Ha.u+1.0572252*Ha.o,mr.j=255*lv((3.2404542*Ha.j+-1.5371385*Ha.u+-.4985314*Ha.o)/100),mr.u=255*lv(a/100),mr.o=255*lv(y/100),mr.F=Ha.F,mr.j=Math.round(mr.j),255mr.j&&(mr.j=0),mr.u=Math.round(mr.u),255mr.u&&(mr.u=0),mr.o=Math.round(mr.o),255mr.o&&(mr.o=0),"rgba("+mr.j+", "+mr.u+", "+mr.o+", "+mr.F+")";case nS:return sv(),Wl.o=Math.min(100,Math.max(0,Wl.o+100*a)),"hsla("+Wl.j+", "+Wl.u+"%, "+Wl.o+"%, "+Wl.F+")";default:ce("Unknown color space: "+y)}}function qh(a){ug||(hv(),ug=!0);var y=cv;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,mr.j=a[0],mr.u=a[1],mr.o=a[2],mr.F=a[3]/255):(y.fillStyle="#FFFFFF",y.fillStyle=a,mr.j=0,mr.u=0,mr.o=0,mr.F=1)}}function sv(){var a=mr.j/255,y=mr.u/255,x=mr.o/255,b=Math.max(a,y,x),E=Math.min(a,y,x),z=b-E;if(E=(b+E)/2,z===0)var tt=a=0;else{switch(b){case a:tt=(y-x)/z%6;break;case y:tt=(x-a)/z+2;break;case x:tt=(a-y)/z+4}tt*=60,0>tt&&(tt+=360),a=z/(1-Math.abs(2*E-1))}Wl.j=Math.round(tt),Wl.u=Math.round(100*a),Wl.o=Math.round(100*E),Wl.F=mr.F}function av(a){return a/=255,.04045>=a?a/12.92:Math.pow((a+.055)/1.055,2.4)}function lv(a){return .0031308>=a?12.92*a:1.055*Math.pow(a,1/2.4)-.055}function uv(a){return a>dv?Math.pow(a,1/3):(pm*a+16)/116}function eS(a){var y=a*a*a;return y>dv?y:(116*a-16)/pm}function wf(a,y){typeof a!="string"&&(a instanceof _o||ce("Value for "+y+" must be a color string or a Brush, not "+a))}function hv(){cv=Yr?new gu(null,void 0,{willReadFrequently:!0}).context:null}Jt.Object.defineProperties(_o.prototype,{type:{get:function(){return this.na},set:function(a){this._isFrozen&&vn(this,a),this.na=a,this.start.Mc()&&(a===td?this.start=vl:a===iu&&(this.start=Co)),this.end.Mc()&&(a===td?this.end=_a:a===iu&&(this.end=Co)),this.xe=null}},color:{get:function(){return this.xk},set:function(a){this._isFrozen&&vn(this,a),this.xk=a,this.xe=null}},start:{get:function(){return this.Qd},set:function(a){this._isFrozen&&vn(this,a),this.Qd=a.J(),this.xe=null}},end:{get:function(){return this.Lk},set:function(a){this._isFrozen&&vn(this,a),this.Lk=a.J(),this.xe=null}},startRadius:{get:function(){return this.Gr},set:function(a){this._isFrozen&&vn(this,a),0>a&&An(a,">= zero",_o,"startRadius"),this.Gr=a,this.xe=null}},endRadius:{get:function(){return this.Xp},set:function(a){this._isFrozen&&vn(this,a),0>a&&An(a,">= zero",_o,"endRadius"),this.Xp=a,this.xe=null}},colorStops:{get:function(){return this.we},set:function(a){this._isFrozen&&vn(this,a),this.we=a,this.xe=null}},pattern:{get:function(){return this.cr},set:function(a){this._isFrozen&&vn(this,a),this.cr=a,this.xe=null}}}),_o.prototype.isDark=_o.prototype.Gx,_o.prototype.darkenBy=_o.prototype.Wy,_o.prototype.lightenBy=_o.prototype.Vz,_o.prototype.addColorStop=_o.prototype.addColorStop;var dv=216/24389,pm=24389/27,lg=[95.047,100,108.883],cv=null,mr=new up,Wl=new up,Ha=new up,kh=new up,ug=!1;_o.className="Brush";var wd;_o.Solid=wd=new Qe(_o,"Solid",0);var td;_o.Linear=td=new Qe(_o,"Linear",1);var iu;_o.Radial=iu=new Qe(_o,"Radial",2);var hg;_o.Pattern=hg=new Qe(_o,"Pattern",4);var dg;_o.Lab=dg=new Qe(_o,"Lab",5);var nS;_o.HSL=nS=new Qe(_o,"HSL",6),_o.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 b=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>b.length&&(b="0"+b),2>a.length&&(a="0"+a),"#"+y+b+a},_o.isValidColor=function(a){if(a==="black")return!0;if(a==="")return!1;ug||(hv(),ug=!0);var y=cv;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)},_o.lighten=function(a){return qy(a)},_o.lightenBy=qy,_o.darken=function(a){return tS(a)},_o.darkenBy=tS,_o.mix=rv,_o.isDark=sg;function Rs(){this.xa="Base"}Rs.prototype.measure=function(){},Rs.prototype.Yz=function(a,y,x,b,E){a.measure(y,x,b,E)},Rs.prototype.arrange=function(){},Rs.prototype.Ly=function(a,y,x,b,E,z){a.arrange(y,x,b,E,z)},Rs.prototype.iA=function(a){a.Uj()},Rs.prototype.gc=function(){},Jt.Object.defineProperties(Rs.prototype,{name:{get:function(){return this.xa},set:function(a){this.xa=a}},classType:{get:function(){return Pn}}}),Rs.prototype.remeasureObject=Rs.prototype.iA,Rs.prototype.arrangeElement=Rs.prototype.Ly,Rs.prototype.measureElement=Rs.prototype.Yz,Rs.className="PanelLayout";function mm(){this.xa="Base"}We(mm,Rs),mm.prototype.measure=function(a,y,x,b,E,z,tt){var ot=b.length;a=ed(a);for(var rt=0;rtVn&&(Us=Math.max(Vn-fc,0));var K0=an.oa===0;an.oc=an.oc+Us,an.actual=an.oa+Us,Vn=Math.max(Vn-(Us+(K0?fc:0)),0)}if(fl.columnSpan===1&&(Ba===hn||Ba===vi)){an=a.Eb(Ia);var Jp=an.Wc();Us=Math.max(Jc-an.actual,0),Us+Jp>Fn&&(Us=Math.max(Fn-Jp,0));var Hy=an.oa===0;an.oc=an.oc+Us,an.actual=an.oa+Us,Fn=Math.max(Fn-(Us+(Hy?Jp:0)),0)}cc&&fl.Uj()}}}}}hi(te);var Rh=0,od=0;z=a.columnCount;for(var Df=0;Df=a.rowCount);Rd++)an=a.Fb(qr.row+Rd),Us=0,Us=Ba===Sn||Ba===vi?Math.max(an.minimum,Qu[qr.row+Rd]===0?an.maximum:Math.min(Qu[qr.row+Rd],an.maximum)):Math.max(an.minimum,isNaN(an.Hc)?an.maximum:Math.min(an.Hc,an.maximum)),ad.height+=Us,El+=an.minimum;for(var xu=1;xu=a.columnCount);xu++)an=a.Eb(qr.column+xu),Us=0,Us=Ba===Sn||Ba===ai?Math.max(an.minimum,lu[qr.column+xu]===0?an.maximum:Math.min(lu[qr.column+xu],an.maximum)):Math.max(an.minimum,isNaN(an.Hc)?an.maximum:Math.min(an.Hc,an.maximum)),ad.width+=Us,Y0+=an.minimum;la.width+=ad.width,la.height+=ad.height;var Gg=qr.margin,yc=Gg.right+Gg.left,qp=Gg.top+Gg.bottom;qr.measure(la.width,la.height,Y0,El);for(var $g=qr.measuredBounds,fh=Math.max($g.width+yc,0),ef=Math.max($g.height+qp,0),Sc=0,Wg=0;Wg=a.rowCount);Wg++)an=a.Fb(qr.row+Wg),Sc+=an.total||0;if(Sc=zd)&&!(qr.row+ld>=a.rowCount);ld++){an=a.Fb(qr.row+ld);var Hd=an.oa||0,nf=jd(qr,an,jh);an.actual=Math.min(an.maximum,Hd+nf),an.oa!==Hd&&(zd-=an.oa-Hd)}for(;0qu&&(an.actual=Math.min(an.maximum,qu+zd),an.oa!==qu&&(zd-=an.oa-qu)),an.index===0)break;an=a.Fb(an.index-1)}}for(var zf=0,Gd=0;Gd=a.columnCount);Gd++)an=a.Eb(qr.column+Gd),zf+=an.total||0;if(zf=jf)&&!(qr.column+of>=a.columnCount);of++){an=a.Eb(qr.column+of);var tm=an.oa||0,Wy=ud(qr,an,$y);an.actual=Math.min(an.maximum,tm+Wy),an.oa!==tm&&(jf-=an.oa-tm)}for(;0X0&&(an.actual=Math.min(an.maximum,X0+jf),an.oa!==X0&&(jf-=an.oa-X0)),an.index===0)break;an=a.Eb(an.index-1)}}}}hi(re),Nn.free(ad),Nn.free(la),Qu!==void 0&&hi(Qu),lu!==void 0&&hi(lu);var Hf=0,Gf=0,_0=a.desiredSize,gx=a.maxSize;Ba=el(a,!0);var em=od=Rh=0,nm=0;z=a.columnCount;for(var J0=0;J0=a.rowCount);an++){var Ti=a.Fb(te+an);Ti.oa!==0&&(zt.height+=Ti.total)}for(an=1;an=a.columnCount);an++)Ti=a.Eb(he+an),Ti.oa!==0&&(zt.width+=Ti.total);var Li=ve.oa+zt.width,Ro=re.oa+zt.height;an=ot,Ti=rt;var dr=Li,Vs=Ro,Js=ot,Fa=rt,Us=Li,Id=Ro;ot+Li>x.width&&(Us=Math.max(x.width-ot,0)),rt+Ro>x.height&&(Id=Math.max(x.height-rt,0));var fs=Wn.alignment;if(fs.Xb()){fs=a.defaultAlignment,fs.sb()||(fs=Co);var Xu=fs.x,Ia=fs.y,Bd=fs.offsetX;fs=fs.offsetY;var Vl=ve.alignment,yu=re.alignment;Vl.sb()&&(Xu=Vl.x,Bd=Vl.offsetX),yu.sb()&&(Ia=yu.y,fs=yu.offsetY)}else Xu=fs.x,Ia=fs.y,Bd=fs.offsetX,fs=fs.offsetY;(isNaN(Xu)||isNaN(Ia))&&(Ia=Xu=.5,fs=Bd=0),Vl=bn.width,yu=bn.height;var bl=Wn.margin,fl=bl.left+bl.right,cc=bl.top+bl.bottom,_u=Ku(Wn,re,ve,!1);!isNaN(Wn.desiredSize.width)||_u!==Sn&&_u!==ai||(Vl=Math.max(Li-fl,0)),!isNaN(Wn.desiredSize.height)||_u!==Sn&&_u!==vi||(yu=Math.max(Ro-cc,0)),Li=Wn.maxSize,Ro=Wn.minSize,Vl=Math.min(Li.width,Vl),yu=Math.min(Li.height,yu),Vl=Math.max(Ro.width,Vl),yu=Math.max(Ro.height,yu),Li=yu+cc,an+=dr*Xu-(Vl+fl)*Xu+Bd+bl.left,Ti+=Vs*Ia-Li*Ia+fs+bl.top,Wn.visible&&(Ts(Js,Fa,Us,Id,an,Ti,bn.width,bn.height)?Wn.arrange(an,Ti,Vl,yu):Wn.arrange(an,Ti,Vl,yu,new Ye(Js,Fa,Us,Id)))}}}for(Nn.free(zt),a=0;a=x&&(x=1);var b=a.gridCellSize,E=b.width;b=b.height;var z=a.naturalBounds,tt=a.actualBounds,ot=z.width,rt=z.height,lt=Math.ceil(ot/E),ut=Math.ceil(rt/b),ft=a.gridOrigin,vt=ft.x;ft=ft.y,y.save(),y.beginPath(),y.rect(0,0,ot,rt),y.clip(),y.Se();for(var xt=[],Ct=a.O.s,Ot=Ct.length,Kt=0;Ktre)){zt=pv(zt.figure);for(var he=0;here&&te.push(ve))}}}}for(Ct=a.O.s,Ot=Ct.length,Kt=0;KtE*zt*x))){if(re=De.segmentIndex,(!isFinite(re)||isNaN(re))&&(re=0),0>re&&(re=zt-Math.min(-re,zt)),re=Math.round(re%zt),zt=De.opacity,he=1,zt!==1){if(zt===0)continue;he=y.globalAlpha,y.globalAlpha=he*zt}ve=xt[Kt];var Fn=!1,Vn=De.strokeDashArray;if(Vn!==null&&(Fn=!0,y.js(Vn,De.strokeDashOffset)),De.figure==="LineV"&&De.stroke!==null&&0y)return a%y===x;if(a%y!==x)return!1;y=b.length;for(var E=0;Eft)te.measure(1/0,1/0,0,0),re=te.measuredBounds,x.ed(re),xt.push(re);else{var he=te.segmentIndex,ve=te.segmentFraction,De=te.alignmentFocus;De.Mc()&&(De=Co);var Fn=te.segmentOrientation,Vn=te.segmentOffset;if(isNaN(he)){var Wn=rt.ua;re=Zn(),Wn.Qu(ve,re);var bn=Gt.allocAt(re[0],re[1]);if(bn.add(rt.i(0)),Wn.type===kn.j?bn.offset(-Wn.startX,-Wn.startY):(Wn=Wn.figures.first(),Wn!==null&&bn.offset(-Wn.startX,-Wn.startY)),Wn=re[2],Fn!==$a){var an=rt.computeAngle(te,Fn,Wn);te.Kb=an}an=bn.x-y.x;var Ti=bn.y-y.y;Gt.free(bn),hi(re)}else if(he<-ft||he>=ft)re=Gt.alloc(),rt.vg(),rt.computeMidPoint(re),Wn=rt.midAngle,Fn!==$a&&(an=rt.computeAngle(te,Fn,Wn),te.Kb=an),an=re.x-y.x,Ti=re.y-y.y,Gt.free(re);else{if(an=0,0<=he?(Ti=ut.M(he),re=heLi+10?0<=he?Wn.ab(Ti):Ti.ab(Wn):Li>bn+10?0<=he?re.ab(an):an.ab(re):0<=he?Wn.ab(an):an.ab(Wn)}else Wn=0<=he?Ti.ab(re):re.ab(Ti);Fn!==$a&&(an=rt.computeAngle(te,Fn,Wn),te.Kb=an),an=Ti.x+(re.x-Ti.x)*ve-y.x,Ti=Ti.y+(re.y-Ti.y)*ve-y.y}te.measure(1/0,1/0,0,0),re=te.measuredBounds,bn=te.naturalBounds;var Ro=0;te instanceof Ki&&(Ro=te.strokeWidth),Li=bn.width+Ro;var dr=bn.height+Ro;Ct.reset(),Ct.translate(-re.x,-re.y),Ct.scale(te.scale,te.scale),Ct.rotate(Fn===$a?te.angle:Wn,Li/2,dr/2),Fn!==Cp&&Fn!==Lp||Ct.rotate(90,Li/2,dr/2),Fn!==bp&&Fn!==Mp||Ct.rotate(-90,Li/2,dr/2),Fn===n0&&(45Wn||225Wn)&&Ct.rotate(-Wn,Li/2,dr/2),bn=new Ye(0,0,Li,dr),Ot.xi(bn,De),Ct.Ga(Ot),De=-Ot.x+Ro/2*te.scale,te=-Ot.y+Ro/2*te.scale,Kt.assign(Vn),Ro=isNaN(Vn.x);var Vs=isNaN(Vn.y);if(Ro||Vs){Li=Li/2+3,dr=dr/2+3;var Js=45<=Wn&&135>=Wn,Fa=225<=Wn&&315>=Wn;Fn===$a&&(Js||Fa)?(Kt.x=Vs?Li:Vn.y,Kt.y=Ro?dr:Vn.x,Js?0<=he||isNaN(he)&&.5>ve||!Ro||(Kt.y=-dr):Fa&&((0<=he||isNaN(he)&&.5>ve)&&Ro&&(Kt.y=-dr),Vs&&(Kt.x=-Li))):(Ro&&(Kt.x=0<=he||isNaN(he)&&.5>ve?Li:-Li),Vs&&(Kt.y=-dr),Kt.rotate(Wn))}else Kt.rotate(Wn);an+=Kt.x,Ti+=Kt.y,bn.set(re),bn.h(an+De,Ti+te,re.width,re.height),xt.push(bn),x.ed(bn)}}if(tt!==null)for(b=tt.labelNodes;b.next();)b.value.measure(1/0,1/0);a.jg=x,a.position.h(y.x+x.x,y.y+x.y),Ws(E,x.width||0,x.height||0),Yi.free(Ct),Gt.free(Ot),Gt.free(Kt)}}}},Mm.prototype.arrange=function(a,y){var x=y.length;if(a instanceof Oo||a instanceof Ln){var b=a,E=null;a instanceof Oo&&(E=a,b=E.adornedPart);var z=a instanceof Oo?null:b.path,tt=a.j;if(tt.length!==0){var ot=0;if(z!==null&&ot=x)Ct=Gt.alloc(),xt=ft,Kt=Ct,xt.vg(),xt.computeMidPoint(Kt),xt=ft.midAngle,lt!==$a&&(ft=ft.computeAngle(tt,lt,xt),tt.angle=ft),ft=Ct.x,Kt=Ct.y,Gt.free(Ct);else{if(Ot=0,0<=ot?(Ct=y.s[ot],Kt=otte+10?0<=ot?xt.ab(Ct):Ct.ab(xt):te>zt+10?0<=ot?Kt.ab(Ot):Ot.ab(Kt):0<=ot?xt.ab(Ot):Ot.ab(xt)}else xt=0<=ot?Ct.ab(Kt):Kt.ab(Ct);lt!==$a&&(ft=ft.computeAngle(tt,lt,xt),tt.angle=ft),ft=Ct.x+(Kt.x-Ct.x)*rt,Kt=Ct.y+(Kt.y-Ct.y)*rt}if(vt.ys())tt.location=new Gt(ft,Kt);else{vt.Mc()&&(vt=Co),Ct=Yi.alloc(),Ct.reset(),Ct.scale(tt.scale,tt.scale),Ct.rotate(tt.angle,0,0);var re=tt.naturalBounds;Ot=Ye.allocAt(0,0,re.width,re.height),zt=Gt.alloc(),zt.xi(Ot,vt),Ct.Ga(zt),vt=-zt.x,te=-zt.y;var he=re.width,ve=re.height;re=Gt.alloc(),re.assign(ut);var De=isNaN(ut.x),Fn=isNaN(ut.y);if(De||Fn){he=he/2+3,ve=ve/2+3;var Vn=45<=xt&&135>=xt,Wn=225<=xt&&315>=xt;lt===$a&&(Vn||Wn)?(re.x=Fn?he:ut.y,re.y=De?ve:ut.x,Vn?0<=ot||isNaN(ot)&&.5>rt||!De||(re.y=-ve):Wn&&((0<=ot||isNaN(ot)&&.5>rt)&&De&&(re.y=-ve),Fn&&(re.x=-he))):(De&&(re.x=0<=ot||isNaN(ot)&&.5>rt?he:-he),Fn&&(re.y=-ve),re.rotate(xt))}else re.rotate(xt);ft+=re.x,Kt+=re.y,Ct.pp(Ot),vt+=Ot.x,te+=Ot.y,ot=Gt.allocAt(ft+vt,Kt+te),tt.move(ot),Gt.free(ot),Gt.free(re),Gt.free(zt),Ye.free(Ot),Yi.free(Ct)}}E!==null?E.Ul(!1):b.Ul(!1),b=FS(a),a.location.h(a.position.x+b.x,a.position.y+b.y),Gt.free(b)}};function iS(a,y,x,b){if($l(b)!==!1){var E=b.strokeWidth;E===0&&a instanceof Oo&&a.type===Pn.Link&&a.adornedObject instanceof Ki&&(E=a.adornedObject.strokeWidth),E*=b.Ca,a instanceof Ln&&a.ua!==null?(a=a.geometry.bounds,b.Ge(a.x-E/2,a.y-E/2,a.width+E,a.height+E)):a instanceof Oo&&a.adornedPart.ua!==null?(a=a.adornedPart.ua.bounds,b.Ge(a.x-E/2,a.y-E/2,a.width+E,a.height+E)):b.Ge(-(E/2),-(E/2),y+E,x+E),E=b.desiredSize,E.w()||b.ua===null?b.dc.h(0,0,E.width,E.height):b.dc.assign(b.ua.bounds),Ls(b,!1)}}function dp(){this.xa="Base"}We(dp,Rs),dp.prototype.measure=function(a,y,x,b,E,z,tt){var ot=a.Pb();a.graduatedBounds=[];var rt=ot.margin,lt=rt.right+rt.left,ut=rt.top+rt.bottom;ot.measure(y,x,z,tt);var ft=ot.measuredBounds,vt=new Ye(-rt.left,-rt.top,Math.max(ft.width+lt,0),Math.max(ft.height+ut,0));a.graduatedBounds.push(vt),E.assign(vt);for(var xt=ot.geometry,Ct=ot.strokeWidth,Ot=xt.flattenedSegments,Kt=xt.flattenedLengths,zt=xt.flattenedTotalLength,te=Ot.length,re=0,he=0,ve=Zn(),De=0;DeLi&&(Li+=360),Vn.push(Li)}re=an,he=Ti}ve.push(Vn)}if(a.graduatedIntervals===null){for(var Ro=[],dr=a.O.s,Vs=dr.length,Js=0;JsId)){for(var fs=0;fsId&&Us.push(Ia)}}}}}a.graduatedIntervals=Ro}var Bd=a.graduatedIntervals,Vl=a.O.s,yu=Vl.length,bl=0,fl=0,cc=zt;a.graduatedMarks=[];for(var _u,Bg=0;Bg_p*Ba*zt/a.graduatedRange&&Ll.graduatedSkip===null)){var Bf=Kt[0][0],hh=0,gl=0;fl=zt*Ll.graduatedStart-1e-4,cc=zt*Ll.graduatedEnd+1e-4;var Jc=_p*Ba,Ml=a.graduatedTickBase;if(Mla.graduatedMin+Jc&&(Ml-=Math.floor((Ml-a.graduatedMin)/Jc)*Jc);for(var K0=Bd[Bg],Jp=Ml,Hy=1e-6*a.graduatedMax,Rh=1;Ml<=a.graduatedMax+Hy;Rh++){t:{for(var od=K0.length,Df=0;Df-Dg){var pc=!1;break t}}pc=!0}if(pc&&(Ml>a.graduatedMax&&(Ml=a.graduatedMax),Ll.graduatedSkip===null||Ll instanceof fr&&!Ll.graduatedSkip(Ml,Ll)||Ll instanceof Ki&&!Ll.graduatedSkip(Ml,Ll))&&(bl=(Ml-a.graduatedMin)*zt/a.graduatedRange,bl>zt&&(bl=zt),fl<=bl&&bl<=cc)){for(var zh=ve[hh][gl],Dd=Kt[hh][gl];hhBf&&glrd&&.4995rd?0rd||.9995Af){var Rg=1-Math.abs(.5-rd);zh=(Ju*Rg+ch*(1-Rg))%360;break t}}}zh=Ju}if(Ll instanceof fr){var Fu="";Ll.graduatedFunction!==null?(Fu=Ll.graduatedFunction(Ml,Ll),Fu=Fu!=null?Fu.toString():""):Fu=(+Ml.toFixed(2)).toString(),Fu!==""&&_u.push({$l:Ag,angle:zh,text:Fu})}else _u.push({$l:Ag,angle:zh})}Ml=Jp+Rh*Jc}}}a.graduatedMarks.push(_u)}hi(ve);var la=a.graduatedMarks;if(la!==null)for(var Qp=b.length,Ua=0;UaIu;Iu++){switch(Iu){case 0:ml.h(ad,Qu);break;case 1:ml.h(ad+zg,Qu);break;case 2:ml.h(ad,Qu+tf);break;case 3:ml.h(ad+zg,Qu+tf)}ml.rotate(qr+gs.angle),ml.offset(U0,Hg),jg===0&&Iu===0?lu.h(ml.x,ml.y,0,0):lu.Ye(ml),ml.offset(-U0,-Hg),ml.rotate(-qr-gs.angle)}Gt.free(ml),sd.graduatedBounds!==null&&sd.graduatedBounds.push(lu),Gr(Ad,lu.x,lu.y,lu.width,lu.height)}else if(gs instanceof fr){var Su=a,Y0=E;Su.temporaryTextBlock===null&&(Su.temporaryTextBlock=new fr);var El=Su.temporaryTextBlock;yS(El,gs);var Rd=gs.alignmentFocus;Rd.Mc()&&(Rd=vl);for(var xu=gs.segmentOrientation,Gg=gs.segmentOffset,yc=new Ye,qp=0,$g=0,fh=0,ef=0,Sc=0,Wg=Ya.length,zd=0;zdfh||225fh)&&qu.rotate(-fh,Hd/2,nf/2);var zf=Ye.allocAt(0,0,Hd,nf),Gd=Gt.alloc();Gd.xi(zf,Rd),qu.Ga(Gd);var jf=-Gd.x,$y=-Gd.y,ud=Gt.alloc();ud.assign(Gg),isNaN(ud.x)&&(ud.x=Hd/2+3),isNaN(ud.y)&&(ud.y=-(nf/2+3)),ud.rotate(fh),qp+=ud.x+jf,$g+=ud.y+$y;var of=new Ye(qp,$g,jd.width,jd.height),tm=new Ye(jd.x,jd.y,jd.width,jd.height),Wy=new Ye(ld.x,ld.y,ld.width,ld.height);jh.Sz=ef,jh.lineCount=El.lineCount,jh.lines=[El.Cb,El.Ih,El.df,El.Le,El.Qc,El.Qb,El.ze],jh.actualBounds=of,jh.measuredBounds=tm,jh.naturalBounds=Wy,zd===0?yc.assign(of):yc.ed(of),Gt.free(ud),Gt.free(Gd),Ye.free(zf),Yi.free(qu)}Su.graduatedBounds!==null&&Su.graduatedBounds.push(yc),Gr(Y0,yc.x,yc.y,yc.width,yc.height)}Ls(gs,!1)}}},dp.prototype.arrange=function(a,y,x){if(a.graduatedBounds!==null){var b=a.Pb(),E=a.graduatedMarks;if(E!==null){var z=a.graduatedBounds,tt=0,ot=z[tt];tt++,b!==null&&b.arrange(ot.x-x.x,ot.y-x.y,ot.width,ot.height);for(var rt=y.length,lt=0;lt=tt&&(tt=1);for(var ot=z.actualBounds,rt=a.O.s,lt=a.graduatedMarks,ut=rt.length,ft=0;fta.graduatedTickUnit*vt.interval*z.geometry.flattenedTotalLength/a.graduatedRange*tt&&vt.graduatedSkip===null)){var Ot=vt.measuredBounds,Kt=vt.strokeWidth*vt.scale,zt=vt.alignmentFocus;zt.Mc()&&(zt=vl);for(var te=0;tett.height)continue}else if(lt.position>tt.width)continue;var ut=lt.separatorStrokeWidth;isNaN(ut)&&(ut=x?a.defaultRowSeparatorStrokeWidth:a.defaultColumnSeparatorStrokeWidth);var ft=lt.separatorStroke;if(ft===null&&(ft=x?a.defaultRowSeparatorStroke:a.defaultColumnSeparatorStroke),ut!==0&&ft!==null){_r(a,y,ft,!1,!1,tt,z),ft=!1;var vt=lt.separatorDashArray;vt===null&&(vt=x?a.defaultRowSeparatorDashArray:a.defaultColumnSeparatorDashArray),vt!==null&&(ft=!0,y.js(vt,0)),y.beginPath(),vt=lt.position+ut,x?vt>tt.height&&(ut-=vt-tt.height):vt>tt.width&&(ut-=vt-tt.width),lt=lt.position+ut/2,y.lineWidth=ut,ut=a.yb,x?(lt+=ut.top,vt=tt.width-ut.right,y.moveTo(ut.left,lt),y.lineTo(vt,lt)):(lt+=ut.left,vt=tt.height-ut.bottom,y.moveTo(lt,ut.top),y.lineTo(lt,vt)),y.stroke(),y.Se(),ft&&y.fs()}}}}function Em(a,y,x,b,E){for(var z=b.length,tt=a.actualBounds,ot=a.naturalBounds,rt=rS(a,!0),lt=rS(a,!1),ut=0;utvt)){var xt=ft.Wc(),Ct=ft.separatorStrokeWidth;isNaN(Ct)&&(Ct=x?a.defaultRowSeparatorStrokeWidth:a.defaultColumnSeparatorStrokeWidth);var Ot=ft.separatorStroke;Ot===null&&(Ot=x?a.defaultRowSeparatorStroke:a.defaultColumnSeparatorStroke),(Ot===null||ft.index===(x?rt:lt))&&(Ct=0),xt-=Ct,Ct=ft.position+Ct,xt+=ft.actual,Ct+xt>vt&&(xt=vt-Ct),0>=xt||(vt=a.yb,_r(a,y,ft.background,!0,!1,ot,tt),x?y.fillRect(vt.left,Ct+vt.top,tt.width-(vt.left+vt.right),xt):y.fillRect(Ct+vt.left,vt.top,xt,tt.height-(vt.top+vt.bottom)))}}}}function rS(a,y){for(var x=y?a.rowCount:a.columnCount,b=0;bb&&E.set(Ct),Gt.free(Ct)),Gt.free(ut),z&&E.transform(tt),lt},bt.Gj=function(){for(var a=this.O.s,y=a.length,x=0;xx||z>b)&&(this.v(),this.measure(y>x?x:y,z>b?b:z,0,0));break;case Sn:this.v(!0),this.measure(x+ot,b+tt,0,0);break;case ai:this.v(!0),this.measure(x+ot,z+tt,0,0);break;case vi:this.v(!0),this.measure(y+ot,b+tt,0,0)}}this.na.arrange(this,E,this.jg)}},bt.gh=function(a){var y=this.naturalBounds,x=ed(this);if(Ts(0,0,y.width,y.height,a.x,a.y)){y=this.O.s;for(var b=y.length,E=Gt.allocAt(0,0);b--;){var z=y[b];if((z.visible||z===x)&&(ao(E.set(a),z.transform),z.ca(E)))return Gt.free(E),!0}return Gt.free(E),!(this.Ma===null&&this.areaBackground===null)}return!1},bt.ks=function(a){if(this.bindingId===a)return this;for(var y=this.O.s,x=y.length,b=0;bvt.width||ft.y>vt.height||0>ft.x+ft.width||0>ft.y+ft.height||(ft=ut,ut=ut instanceof Pn?ut:null,vt=Yi.alloc(),vt.set(tt),(ut!==null?ut.Cf(a,y,x,b,E,vt):Zs(ft,a,b,vt))&&(y!==null&&(ft=y(ft)),ft===null||x!==null&&!x(ft)||E.add(ft)),Yi.free(vt))}}return z===void 0&&Yi.free(tt),b}return z===void 0&&Yi.free(tt),!1};function mv(a,y,x,b){for(var E=a.O.s,z=E.length;z--;){var tt=E[z];if(tt.visible){var ot=tt.actualBounds,rt=a.naturalBounds;ot.x>rt.width||ot.y>rt.height||0>ot.x+ot.width||0>ot.y+ot.height||(tt instanceof Pn&&mv(tt,y,x,b),y!==null&&(tt=y(tt)),tt===null||x!==null&&!x(tt)||b.add(tt))}}}bt.og=function(a,y,x,b,E,z){if(this.pickable===!1)return!1;x===void 0&&(x=null),b===void 0&&(b=null);var tt=this.naturalBounds,ot=this.se(),rt=ot?a:ao(Gt.allocAt(a.x,a.y),this.transform),lt=ot?y:ao(Gt.allocAt(y.x,y.y),this.transform),ut=rt.Bf(lt),ft=0Kt.width||Ot.y>Kt.height||0>Ot.x+Ot.width||0>Ot.y+Ot.height))&&(Ct.se()?(Ot=Ct.transform,ao(rt.set(a),Ot),ao(lt.set(y),Ot)):(rt.set(a),lt.set(y)),Ot=Ct,Ct=Ct instanceof Pn?Ct:null,(Ct!==null?Ct.og(rt,lt,x,b,E,z):Ot.tx(rt,lt,E))&&(x!==null&&(Ot=x(Ot)),Ot===null||b!==null&&!b(Ot)||z.add(Ot)))}}Gt.free(rt),Gt.free(lt)}return E?ft:tt}return!1};function vv(a){var y=null;return a instanceof Ki&&(y=a.spot1,y===Wo&&(y=null),a=a.geometry,a!==null&&y===null&&(y=a.spot1)),y===null&&(y=js),y}function yv(a){var y=null;return a instanceof Ki&&(y=a.spot2,y===Wo&&(y=null),a=a.geometry,a!==null&&y===null&&(y=a.spot2)),y===null&&(y=ka),y}bt.add=function(a){for(var y=[],x=0;x=E.count&&a>=E.count)return;E.mb(z),b=z}else ce("element "+y.toString()+" has panel "+x.toString()+" but is not contained by it.")}(0>a||a>E.count)&&(a=E.count),E.Gb(a,y),(a===0||y.isPanelMain)&&(this.$g=null),$l(this)||this.v(),y.v(!1),y.portId!==null?this.Te=!0:y instanceof Pn&&y.Te===!0&&(this.Te=!0),this.graduatedIntervals=null,this.If()||Nm(this,y,!1),x=this.part,x!==null&&(x.Rh=null,x.ag=NaN,this.Te&&x instanceof Dn&&(x.Te=!0),x.Te&&x instanceof Dn&&(x.wc=null),E=this.diagram,E!==null&&E.undoManager.isUndoingRedoing||(b!==-1&&x.cb(Ps,"elements",this,y,null,b,null),x.cb(es,"elements",this,null,y,null,a)))};function Sv(a,y){a.l=y?a.l|16777216:a.l&-16777217}bt.remove=function(a){for(var y=this.O.s,x=y.length,b=-1,E=0;Ea&&An(a,">= 0",Pn,"getRowDefinition:idx"),a=Math.round(a);var y=this.rowDefs;if(y[a]===void 0){var x=new Ms;x.wi(this),x.isRow=!0,x.index=a,y[a]=x,this.cb(es,"rowdefs",this,null,x,null,a)}return y[a]},bt.oA=function(a){if(0>a&&An(a,">= 0",Pn,"removeRowDefinition:idx"),this.rowCount!==0){a=Math.round(a);var y=this.rowDefs,x=y[a];if(x){y[a]=void 0;for(var b=y.length-1;0<=b&&y[b--]===void 0;)y.length--;this.cb(Ps,"rowdefs",this,x,null,a,null),this.v()}}};function hS(a,y,x){var b=a.rowDefs;if(!(0>y)){if(b[y]=x instanceof Ms?x:void 0,!x)for(y=b.length-1;0<=y&&b[y--]===void 0;)b.length--;a.v()}}bt.Eb=function(a){0>a&&An(a,">= 0",Pn,"getColumnDefinition:idx"),a=Math.round(a);var y=this.colDefs;if(y[a]===void 0){var x=new Ms;x.wi(this),x.isRow=!1,x.index=a,y[a]=x,this.cb(es,"coldefs",this,null,x,null,a)}return y[a]},bt.jA=function(a){if(0>a&&An(a,">= 0",Pn,"removeColumnDefinition:idx"),this.columnCount!==0){a=Math.round(a);var y=this.colDefs,x=y[a];if(x){y[a]=void 0;for(var b=y.length-1;0<=b&&y[b--]===void 0;)y.length--;this.cb(Ps,"coldefs",this,x,null,a,null),this.v()}}};function dS(a,y,x){var b=a.colDefs;if(!(0>y)){if(b[y]=x instanceof Ms?x:void 0,!x)for(y=b.length-1;0<=y&&b[y--]===void 0;)b.length--;a.v()}}bt.Gy=function(a){var y=null;return a.isRow?y=this.Fb(a.index):a.isRow||(y=this.Eb(a.index)),y&&Tm(y,a),this},bt.Hy=function(a,y){return(a=this.Fb(a))&&Tm(a,new Ms(y)),this},bt.By=function(a,y){return(a=this.Eb(a))&&Tm(a,new Ms(y)),this},bt.nz=function(a){if(0>a||this.type!==Pn.Table||this.rowCount===0)return-1;for(var y=0,x=this.rowDefs,b=x.length,E=this.topIndex;Ea||this.type!==Pn.Table||this.columnCount===0)return-1;for(var y=0,x=this.colDefs,b=x.length,E=this.leftIndex;Ea;)this.pc(this.O.length-1,!1);fS(this,this.itemArray)};function fS(a,y){var x=cp(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 b=0;bx)){var E=Pv(a,y);if(E=wv(a,E),E!==null){if(pu(E),E=E.copy(),E.l&16777216){var z=a.ih();z!==null&&Sv(z,!0)}typeof y=="object"&&(a.ge===null&&(a.ge=new ri),a.ge.add(y,E)),z=x+cp(a),a.Gb(z,E),b&&(E.ub=y,xv(a,z,x),E.ub=null),E.data=y}}}function xv(a,y,x){for(a=a.O;ya&&An(a,">= 0",Pn,"padding"),a=new ci(a)):(0>a.left&&An(a.left,">= 0",Pn,"padding:value.left"),0>a.right&&An(a.right,">= 0",Pn,"padding:value.right"),0>a.top&&An(a.top,">= 0",Pn,"padding:value.top"),0>a.bottom&&An(a.bottom,">= 0",Pn,"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:Sa},set:function(a){typeof a=="number"&&(a=new ci(a));var y=this.defaultSeparatorPadding;y.D(a)||(a=a.J(),this.T===null&&(this.T=new ou),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 _o)&&(a instanceof _o&&a.freeze(),this.T===null&&(this.T=new ou),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 ou),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,b=0,E=0;Ea)&&ce("Panel.topIndex must be greater than zero and a real number, not: "+a),this.T===null&&(this.T=new ou),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)&&ce("Panel.leftIndex must be greater than zero and a real number, not: "+a),this.T===null&&(this.T=new ou),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 fi&&!(this instanceof Oo);pu(this),this.ub=a;var b=this.diagram;b!==null&&(x?(x=b.partManager,this instanceof Ln?(y!==null&&x.bf.remove(y),a!==null&&x.bf.add(a,this)):this instanceof fi&&(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),b!==null&&b.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 xf),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&&ay(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 ri}var y=this.itemTemplateMap.I("");y!==a&&((a instanceof fi||a.isPanelMain)&&ce("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(););Xi(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&&(Xi(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 Fi&&(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&&Nm(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))}}}),Jt.Object.defineProperties(Pn,{Position:{get:function(){return Mu.I("Position")}},Horizontal:{get:function(){return Mu.I("Horizontal")}},Vertical:{get:function(){return Mu.I("Vertical")}},Spot:{get:function(){return Mu.I("Spot")}},Auto:{get:function(){return Mu.I("Auto")}},Table:{get:function(){return Mu.I("Table")}},Viewbox:{get:function(){return Mu.I("Viewbox")}},TableRow:{get:function(){return Mu.I("TableRow")}},TableColumn:{get:function(){return Mu.I("TableColumn")}},Link:{get:function(){return Mu.I("Link")}},Grid:{get:function(){return Mu.I("Grid")}},Graduated:{get:function(){return Mu.I("Graduated")}}}),Pn.prototype.rebuildItemElements=Pn.prototype.mv,Pn.prototype.findItemPanelForData=Pn.prototype.sx,Pn.prototype.updateTargetBindings=Pn.prototype.La,Pn.prototype.copyTemplate=Pn.prototype.Uy,Pn.prototype.graduatedValueForPoint=Pn.prototype.Gz,Pn.prototype.graduatedPointForValue=Pn.prototype.Fz,Pn.prototype.findColumnForLocalX=Pn.prototype.fz,Pn.prototype.findRowForLocalY=Pn.prototype.nz,Pn.prototype.addColumnDefinition=Pn.prototype.By,Pn.prototype.addRowDefinition=Pn.prototype.Hy,Pn.prototype.addRowColumnDefinition=Pn.prototype.Gy,Pn.prototype.removeColumnDefinition=Pn.prototype.jA,Pn.prototype.getColumnDefinition=Pn.prototype.Eb,Pn.prototype.removeRowDefinition=Pn.prototype.oA,Pn.prototype.getRowDefinition=Pn.prototype.Fb,Pn.prototype.removeAt=Pn.prototype.mb,Pn.prototype.remove=Pn.prototype.remove,Pn.prototype.insertAt=Pn.prototype.Gb,Pn.prototype.elt=Pn.prototype.M,Pn.prototype.add=Pn.prototype.add,Pn.prototype.findObject=Pn.prototype.fb,Pn.prototype.findInVisualTree=Pn.prototype.Nl,Pn.prototype.walkVisualTreeFrom=Pn.prototype.qm,Pn.prototype.findMainElement=Pn.prototype.Pb;var gS=!1,pS=null,Mu=new ri;Pn.className="Panel",Pn.definePanelLayout=lh,lh("Position",new mm),lh("Vertical",new ym),lh("Auto",new xm),lh("Link",new Mm);function nd(){this.lq=0,this.F=100,this.ia=10,this.V=0,this.Zh=this.o=this.j=this.u=null}nd.prototype.copy=function(){var a=new nd;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},nd.className="GradPanelSettings";function ou(){this.Pc=[],this.Oc=[],this.j=this.ob=Fm,this.hb=this.Hb=0,this.Qp=Sa,this.Ha=1,this.V=this.ia=null,this.F=1,this.nb=this.o=this.u=null}ou.prototype.copy=function(a){for(var y=new ou,x=this.Pc,b=x.length,E=y.Pc,z=0;za&&An(a,">= 0",Ms,"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&&An(a,">= 0",Ms,"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))&&An(a,">= 0",Ms,"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&&An(a,">= 0",Ms,"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 ci(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&&wf(a,"RowColumnDefinition.separatorStroke"),a instanceof _o&&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,b=0,E=0;EE)){var z=b.measuredBounds,tt=Math.max(1,z.width);z=z.height;for(var ot=x[0],rt=x[1],lt,ut,ft,vt,xt,Ct,Ot=0,Kt=Zn(),zt=2;ztft&&(ft=1),E=x=ft,lt=tt/2,ut=lt!==0,zt=0,Ct=Kt[zt],ft=Ct[0],xt=Ct[1],vt=Ct[2],Ct=Ct[3];for(var te=0;.1<=Ot;){if(te===0&&(ut?(E=x,E-=lt,Ot-=lt,ut=!1):E=x,E===0&&(E=1)),E>Ot){hi(Kt);return}E>Ct?(te=E-Ct,E=Ct):te=0;var re=Math.sqrt(E*E/(1+vt*vt));if(0>ft&&(re=-re),ot+=re,rt+=vt*re,a.translate(ot,rt),a.rotate(xt),a.translate(-(tt/2),-(z/2)),te===0&&b.hh(a,y),a.translate(tt/2,z/2),a.rotate(-xt),a.translate(-ot,-rt),Ot-=E,Ct-=E,te!==0){if(zt++,zt===Kt.length){hi(Kt);return}Ct=Kt[zt],ft=Ct[0],xt=Ct[1],vt=Ct[2],Ct=Ct[3],E=te}}hi(Kt)}}bt.hh=function(a,y){var x=this.xc,b=this.Ui;if(x!==null||b!==null){var E=this.ua;if(E!==null){a.yc();var z=this.actualBounds,tt=this.naturalBounds;b!==null&&_r(this,a,b,!0,!1,tt,z);var ot=this.part,rt=this.ig;if(x===null||rt!==0||ot===null||!this.isPanelMain&&ot.Pb()!==this||(rt=ot.type===Pn.Link&&ot instanceof Oo&&ot.category==="Selection"&&ot.adornedObject instanceof Ki&&ot.adornedPart.Pb()===ot.adornedObject?ot.adornedObject.strokeWidth:0),rt===0&&(x=null),x!==null&&rt!==0&&(_r(this,a,x,!1,!1,tt,z),a.lineWidth=rt,a.lineJoin=this.strokeJoin,a.lineCap=this.strokeCap,a.miterLimit=this.strokeMiterLimit),z=!1,ot&&y.Gf("drawShadows")&&(z=ot.isShadowed),a.Il===!1&&(z=!1),ot=!0,x===null||b!==null&&b!=="transparent"||(ot=!1),tt=!1,rt=this.strokeDashArray,rt!==null&&(tt=!0,a.js(rt,this.strokeDashOffset)),E.type===kn.j)a.beginPath(),a.moveTo(E.startX,E.startY),a.lineTo(E.endX,E.endY),x!==null&&a.jk(),a.Se();else if(E.type===kn.u){var lt=E.startX;rt=E.startY;var ut=E.endX,ft=E.endY;E=Math.min(lt,ut);var vt=Math.min(rt,ft);lt=Math.abs(ut-lt),rt=Math.abs(ft-rt),a.beginPath(),a.rect(E,vt,lt,rt),b!==null&&a.ng(b),x!==null&&(ot&&z&&Eh(a),a.jk(),ot&&z&&Qh(a)),a.Se()}else if(E.type===kn.F)lt=E.startX,rt=E.startY,ut=E.endX,ft=E.endY,E=Math.abs(ut-lt)/2,vt=Math.abs(ft-rt)/2,lt=Math.min(lt,ut)+E,rt=Math.min(rt,ft)+vt,a.beginPath(),a.moveTo(lt,rt-vt),a.bezierCurveTo(lt+Ce.wg*E,rt-vt,lt+E,rt-Ce.wg*vt,lt+E,rt),a.bezierCurveTo(lt+E,rt+Ce.wg*vt,lt+Ce.wg*E,rt+vt,lt,rt+vt),a.bezierCurveTo(lt-Ce.wg*E,rt+vt,lt-E,rt+Ce.wg*vt,lt-E,rt),a.bezierCurveTo(lt-E,rt-Ce.wg*vt,lt-Ce.wg*E,rt-vt,lt,rt-vt),a.closePath(),b!==null&&a.ng(b),x!==null&&(ot&&z&&Eh(a),a.jk(),ot&&z&&Qh(a)),a.Se();else if(E.type===kn.o)for(E=E.figures,rt=E.length,vt=0;vtOt.sweepAngle,xt!==null?xt.endX:lt.startX,xt!==null?xt.endY:lt.startY)}else if(xt=Ja(Ot,lt),Kt=xt.length,Kt===0)a.lineTo(Ot.centerX,Ot.centerY);else for(var zt=0;zt(x.startX-x.endX)*(a.x-x.endX)+(x.startY-x.endY)*(a.y-x.endY)||0>b)?!1:(Ye.free(z),Ce.Yb(x.startX,x.startY,x.endX,x.endY,E,a.x,a.y));if(x.type===kn.u){y=x.startX;var tt=x.startY,ot=x.endX;if(x=x.endY,z.x=Math.min(y,ot),z.y=Math.min(tt,x),z.width=Math.abs(ot-y),z.height=Math.abs(x-tt),this.fill===null){if(z.Bc(-b,-b),z.ca(a))return Ye.free(z),!1;z.Bc(b,b)}return this.stroke!==null&&z.Bc(E,E),a=z.ca(a),Ye.free(z),a}if(x.type===kn.F){tt=x.startX,E=x.startY,ot=x.endX;var rt=x.endY;if(x=Math.min(tt,ot),y=Math.min(E,rt),tt=Math.abs(ot-tt)/2,E=Math.abs(rt-E)/2,x=a.x-(x+tt),y=a.y-(y+E),this.fill===null){if(tt-=b,E-=b,0>=tt||0>=E||1>=x*x/(tt*tt)+y*y/(E*E))return Ye.free(z),!1;tt+=b,E+=b}return this.stroke!==null&&(tt+=b,E+=b),Ye.free(z),0>=tt||0>=E?!1:1>=x*x/(tt*tt)+y*y/(E*E)}if(x.type===kn.o)return Ye.free(z),this.fill===null?nh(x,a.x,a.y,E):Ru(x,a,E,1=this.strokeWidth)ut=Ce.Ve(lt.startX,lt.startY,lt.endX,lt.endY,z,tt,ot,rt,E);else{if(lt.startX===lt.endX?(b=ft,ut=0):(y=(lt.endY-lt.startY)/(lt.endX-lt.startX),ut=ft/Math.sqrt(1+y*y),b=ut*y),y=Zn(),a=new Gt,Ce.Ve(lt.startX+b,lt.startY+ut,lt.endX+b,lt.endY+ut,z,tt,ot,rt,a)&&y.push(a),a=new Gt,Ce.Ve(lt.startX-b,lt.startY-ut,lt.endX-b,lt.endY-ut,z,tt,ot,rt,a)&&y.push(a),a=new Gt,Ce.Ve(lt.startX+b,lt.startY+ut,lt.startX-b,lt.startY-ut,z,tt,ot,rt,a)&&y.push(a),a=new Gt,Ce.Ve(lt.endX+b,lt.endY+ut,lt.endX-b,lt.endY-ut,z,tt,ot,rt,a)&&y.push(a),ot=y.length,ot===0)return hi(y),!1;for(ut=!0,rt=1/0,b=0;bMath.abs(x)){if(rt=tt-ut-x*(z-b),0>a*a*x*x+lt*lt-rt*rt){E.x=NaN,E.y=NaN,ut=!1;break t}ft=Math.sqrt(a*a*x*x+lt*lt-rt*rt),ot=(-(a*a*x*rt)+a*lt*ft)/(lt*lt+a*a*x*x)+b,a=(-(a*a*x*rt)-a*lt*ft)/(lt*lt+a*a*x*x)+b,lt=x*(ot-b)+rt+ut,rt=x*(a-b)+rt+ut,Math.abs((z-ot)*(z-ot))+Math.abs((tt-lt)*(tt-lt))ot){E.x=NaN,E.y=NaN,ut=!1;break t}rt=Math.sqrt(ot),ot=ut+rt,rt=ut-rt,Math.abs(ot-tt)Math.abs(Ct)?(Ot*=.5/Ct,Ct=.5):Ot!==0&&.5>Math.abs(Ot)&&(Ct*=.5/Ot,Ot=.5),zt-=Ct,te-=Ot;xt.contains(zt,te);)zt-=Ct,te-=Ot;for(E.x=ot,E.y=rt,Ot=0;Otx?a-x:x-a)<(y>b?y-b:b-y)?(a=ya||Ce.$(rt.y,a))&&(rt.yy||Ce.$(rt.x,y))&&(rt.x=a&&b<=y):(a=b&&x<=a)}bt.tx=function(a,y,x){function b(Kt,zt){for(var te=Kt.length,re=0;reE)return!0;return!1}if(x&&this.fill!==null&&this.gh(a,!0))return!0;var E=a.Bf(y),z=E;if(1.5=E||Ys(y,z,0,-ft)>=E||Ys(y,z,0,ft)>=E||Ys(y,z,ut,0)>=E)}else if(y.type===kn.o){if(lt=y.bounds,z=lt.x,ot=lt.y,rt=lt.x+lt.width,lt=lt.y+lt.height,a.x>rt&&a.xlt&&a.yE&&lr(a.x,a.y,z,ot,rt,ot)>E&&lr(a.x,a.y,rt,lt,z,lt)>E&&lr(a.x,a.y,rt,lt,rt,ot)>E)return!1;if(z=Math.sqrt(E),x){if(this.fill===null?nh(y,a.x,a.y,z):Ru(y,a,z,!0,!1))return!0}else{for(x=y.figures,y=0;yE)return!1;for(ot=z.segments.s,rt=ot.length,lt=0;ltE)return!1;break;case na:var vt=Zn();if(Ce.Qe(tt,ut,ft.point1X,ft.point1Y,ft.point2X,ft.point2Y,ft.endX,ft.endY,.8,vt),tt=b(vt,a),hi(vt),tt||(tt=ft.endX,ut=ft.endY,a.zd(tt,ut)>E))return!1;break;case yl:if(vt=Zn(),Ce.ep(tt,ut,ft.point1X,ft.point1Y,ft.endX,ft.endY,.8,vt),tt=b(vt,a),hi(vt),tt||(tt=ft.endX,ut=ft.endY,a.zd(tt,ut)>E))return!1;break;case os:case Bl:vt=ft.type===os?Ja(ft,z):Aa(ft,z,tt,ut);var xt=vt.length;if(xt===0){if(tt=ft.type===os?ft.centerX:ft.endX,ut=ft.type===os?ft.centerY:ft.endY,a.zd(tt,ut)>E)return!1;break}ft=null;for(var Ct=Zn(),Ot=0;Ot= 0",Ki,"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"?An(a,'"butt", "round", or "square"',Ki,"strokeCap"):(Kc(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"?An(a,'"miter", "bevel", or "round"',Ki,"strokeJoin"):(Kc(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){Kc(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,b=0,E=0;Ea?a=0:1a?a=0:1(ft*ft+ut*ut)*vt*vt&&(x=!0),y.ib!==a&&(x=!1),y.ib instanceof Pl&&(x=!1),y.Gf("textGreeking")===!1&&(x=!1),y=this.spacingAbove,ft=this.spacingBelow,this.flip){case Lo:a.translate(E,0),a.scale(-1,1);break;case Ji:a.translate(0,z),a.scale(1,-1);break;case or:a.translate(E,z),a.scale(-1,-1)}if(a.yc(),ut=this.Gc,vt=(y+tt+ft)*ut,z>vt&&(b=this.verticalAlignment,b=b.y*z-b.y*vt+b.offsetY),ut===1&&this.ze!==null)ft=this.Cb,ft>E&&(ft=E),this.Oj(this.ze,a,0,b+y,E,tt,ft,x,ot,rt,lt);else if(this.Qc!==null&&this.Qb!==null)for(vt=0;vtE&&(xt=E),b+=y,this.Oj(this.Qb[vt],a,0,b,E,tt,xt,x,ot,rt,lt),b+=tt+ft}switch(this.flip){case Lo:a.scale(-1,1),a.translate(-E,0);break;case Ji:a.scale(1,-1),a.translate(0,-z);break;case or:a.scale(-1,-1),a.translate(-E,-z)}}},bt.Oj=function(a,y,x,b,E,z,tt,ot,rt,lt,ut){var ft=0;if(ot)rt==="left"?ft=0:rt==="right"?ft=E-tt:rt==="center"&&(ft=(E-tt)/2),y.fillRect(x+ft,b+.25*z,tt,1);else{if(rt==="left"?ft=0:rt==="right"?ft=E:rt==="center"&&(ft=E/2),E=Dm!==null?Dm(this,z):.75*z,y.fillText(a,x+ft,b+E),a=z/20|0,a===0&&(a=1),rt==="right"?ft-=tt:rt==="center"&&(ft-=tt/2),lt){ot=Am!==null?Am(this,z):.8*z,rt=x+ft,lt=b+ot,E=x+ft+tt,ot=b+ot;var vt=a;y.beginPath(),y.lineWidth=vt,y.moveTo(rt,lt),y.lineTo(E,ot),y.stroke(),y.Se(),y instanceof Pl&&y.ad.classList.add("gojs-td")}ut&&(ut=b+z-z/2.2|0,a%2!==0&&(ut+=.5),b=x+ft,z=ut,x=x+ft+tt,tt=ut,ft=a,y.beginPath(),y.lineWidth=ft,y.moveTo(b,z),y.lineTo(x,tt),y.stroke(),y.Se(),y instanceof Pl&&y.ad.classList.add("gojs-td"))}},bt.kk=function(a,y,x){if(!xe.prototype.kk.call(this,a,y,x))return!1;if(_r(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=this.Qb.length))){for(this.l|=16777216,lt=this.Qb[rt],y=Math.max(1,a-y);Eu(lt)>y&&1a.maxLines&&(a.l|=16777216))}function Ev(a,y,x,b){var E=a.formatting===mp;E&&(y=y.trim());var z=0,tt=a.Ae,ot=a.spacingAbove+a.spacingBelow;ot=Math.max(0,pp(a)+ot);var rt=a.overflow===Rm?SS(tt):0;if(a.Gc>=a.maxLines)b!==null&&b.h(0,ot);else if(tt=y,a.wrap===kv){a.Le=1;var lt=Eu(y);if(rt===0||lt<=x)a.Cb=Math.max(a.Cb,lt),gp(a,y,a.Cb),b!==null&&b.h(lt,ot);else{for(z=fg(a,tt),tt=tt.substr(z.length),y=fg(a,tt),lt=Eu(z+y);0x&&1x;){var ft=1;for(lt=Eu(y.substr(0,ft)),ut=0;lt<=x;)ft++,ut=lt,lt=Eu(y.substr(0,ft));if(ft===1){var vt=lt;z=Math.max(z,lt)}else vt=ut,z=Math.max(z,ut);if(ft--,1>ft&&(ft=1),gp(a,y.substr(0,ft),vt),rt++,y=y.substr(ft),a.Gc+rt>a.maxLines)break}for(ut=fg(a,tt),lt=Eu(y+ut);0a.maxLines))break}a.Le=Math.min(a.maxLines,rt),a.Cb=Math.max(a.Cb,z),b!==null&&b.h(a.Cb,ot*a.Le)}}function fg(a,y){if(a.wrap===wS)return y.substr(0,1);for(var x=y.length,b=0,E=Sx;b=y.length?y:y.substr(0,b)}function Eu(a){return nl===null?8*a.length:nl.measureText(a).width}function pp(a){if(a.df!==null)return a.df;var y=a.Ae;if(nl===null){var x=16;return a.df=x}return Ov[y]!==void 0&&5e3>bS?x=Ov[y]:(x=1.3*nl.measureText("M").width,Ov[y]=x,bS++),a.df=x}function SS(a){if(nl===null)return 6;if(zm[a]!==void 0&&5e3>Fv)var y=zm[a];else y=nl.measureText(vp).width,zm[a]=y,Fv++;return y}function xS(a,y){var x=a.ec.replace(/\r\n/g,` `).replace(/\r/g,` `),b=a.spacingAbove+a.spacingBelow;if(b=Math.max(0,pp(a)+b),x.length===0)return a.Cb=0,a.Gc=1,b;if(!a.isMultiline){var E=x.indexOf(` `,0);0<=E&&(x=x.substr(0,E))}E=0;for(var z=a.Gc=0,tt,ot=!1;!ot;){if(tt=x.indexOf(` `,z),tt===-1&&(tt=x.length,ot=!0),z<=tt){if(z=x.substr(z,tt-z),a.wrap!==kv){a.Le=0;var rt=Nn.alloc();Ev(a,z,y,rt),E+=rt.height,Nn.free(rt),a.Gc+=a.Le}else Ev(a,z,y,null),E+=b,a.Gc++;a.Gc===a.maxLines&&(ot=!0)}z=tt+1}return a.Lq=E}Jt.Object.defineProperties(fr.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"||(uh(this),this.da.Or=a,this.N(),this.g("textAlign",y,a))}},flip:{get:function(){return this.da!==null?this.da.Xf:hn},set:function(a){var y=this.flip;y!==a&&(uh(this),this.da.Xf=a,this.N(),this.g("flip",y,a))}},verticalAlignment:{get:function(){return this.da!==null?this.da.Yr:Ks},set:function(a){var y=this.verticalAlignment;y.D(a)||(a=a.J(),uh(this),this.da.Yr=a,za(this),this.g("verticalAlignment",y,a))}},naturalBounds:{get:function(){if(!this.dc.w()){var a=Nn.alloc();Ev(this,this.ec,999999,a);var y=a.width;Nn.free(a),a=xS(this,y);var x=this.desiredSize;isNaN(x.width)||(y=x.width),isNaN(x.height)||(a=x.height),Ws(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:Nv},set:function(a){var y=this.wrap;y!==a&&(uh(this),this.da.$r=a,this.v(),this.g("wrap",y,a))}},overflow:{get:function(){return this.da!==null?this.da.$q:Tv},set:function(a){var y=this.overflow;y!==a&&(uh(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&&wf(a,"TextBlock.stroke"),a instanceof _o&&a.freeze(),this.xc=a,this.N(),this.g("stroke",y,a))}},lineCount:{get:function(){return this.Gc}},lineHeight:{get:function(){return pp(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&&(uh(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&&(uh(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 Th),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:1a?a=0:1=a&&An(a,"> 0",fr,"maxLines"),uh(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 Dm=null,Am=null,kv=new Qe(fr,"None",0),PS=new Qe(fr,"WrapFit",1),Nv=new Qe(fr,"WrapDesiredSize",2),wS=new Qe(fr,"WrapBreakAll",3),Tv=new Qe(fr,"OverflowClip",0),Rm=new Qe(fr,"OverflowEllipsis",1),mp=new Qe(fr,"FormatTrim",0),CS=new Qe(fr,"FormatNone",0),Sx=/[ \u200b\u00ad]/,Ov=new bi,bS=0,zm=new bi,Fv=0,vp="...",LS="",nl=null,jm=!1;fr.className="TextBlock";function Iv(){this.nc=!1,this.Hd=null,this.Xf=hn,this.gq=mp,this.Jq=1/0,this.$q=Tv,this.Er=this.Dr=0,this.Or="start",this.vj=this.Qr=this.Pr=null,this.Yr=Ks,this.$r=Nv}Iv.prototype.copy=function(){var a=new Iv;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},fr.getEllipsis=function(){return vp},fr.setEllipsis=function(a){vp=a,zm=new bi,Fv=0},fr.getBaseline=function(){return Dm},fr.setBaseline=function(a){Dm=a},fr.getUnderline=function(){return Am},fr.setUnderline=function(a){Am=a},fr.isValidFont=function(a){if(jm||(nl=Yr?new gu(null).context:null,jm=!0),nl===null)return!0;var y=nl.font;if(a===y||a==="10px sans-serif")return!0;nl.font="10px sans-serif",nl.font=a;var x=nl.font;if(x!=="10px sans-serif")return nl.font=y,!0;nl.font="19px serif";var b=nl.font;return nl.font=a,x=nl.font,nl.font=y,x!==b},fr.FormatNone=CS,fr.FormatTrim=mp,fr.None=kv,fr.OverflowClip=Tv,fr.OverflowEllipsis=Rm,fr.WrapBreakAll=wS,fr.WrapDesiredSize=Nv,fr.WrapFit=PS;function Th(){this.Tk=1,this.u=0,this.j=1,this.o=this.F=null}Th.prototype.copy=function(){var a=new Th;return a.Tk=this.Tk,a.u=this.u,a.j=this.j,a.F=this.F,a.o=this.o,a},Th.className="GradElementSettings";function il(a,y){xe.call(this),this.Eg=null,this.qo="",this.Xg=hr,this.Nk=Sn,this.Zg=this.Hd=null,this.Mk=Co,this.Xf=hn,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 gg;We(il,xe),il.prototype.cloneProtected=function(a){xe.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},il.prototype.qb=function(a){a===hn||a===_n||a===uo?this.imageStretch=a:xe.prototype.qb.call(this,a)},il.prototype.toString=function(){return"Picture("+this.source+")#"+$o(this)};function pg(a){a===void 0&&(a=""),a!==""?gg[a]&&(delete gg[a],Hm--):(gg=new bi,Hm=0)}function MS(a,y){y.qy||(y.Fq=function(x){y.sq=!0,y.ln=!1;var b=y.Bg.copy();if(b!=null){for(b=b.iterator;b.next();){var E=b.value;E.N();var z=y.getAttribute("src")||"",tt=E.Og.I(z);if(tt!==null)for(var ot=tt.length,rt=0;rt=b.width&&(z=z+Ct.offsetX+(ft*Ct.x-b.width*Ct.x)),vt>=b.height&&(tt=tt+Ct.offsetY+(vt*Ct.y-b.height*Ct.y)),rt=Math.min(b.width,ft),ot=Math.min(b.height,vt);break;case Sn:ft=b.width,vt=b.height;break;case _n:case uo:xt===_n?(xt=Math.min(b.height/vt,b.width/ft),ft*=xt,vt*=xt):xt===uo&&(xt=Math.max(b.height/vt,b.width/ft),ft*=xt,vt*=xt,ft>=b.width&&(z=(z+Ct.offsetX+(ft*Ct.x-b.width*Ct.x)/ft)*rt),vt>=b.height&&(tt=(tt+Ct.offsetY+(vt*Ct.y-b.height*Ct.y)/vt)*ot),rt*=1/(ft/b.width),ot*=1/(vt/b.height),ft=b.width,vt=b.height)}xt=this.Df()*y.scale;var Ot=ft*xt*vt*xt,Kt=rt*ot/Ot,zt=x.__goCache;xt=null;var te=xx;if(!E){if(x.sq&&zt!==void 0&&4te*te)for(zt.gi===null&&(kS(zt,4,lt,ut,x),kS(zt,16,lt,ut,x)),E=zt.gi,lt=E.length,ut=0;uta)&&(a=5),a=Math.min(a,y/3),a=Math.min(a,x/3);var b="rr"+y+","+x+","+a,E=Ce.Mf[b];if(E!==void 0)return E;var z=a*Ce.wg;return E=new kn().add(new Ds(a,0,!0).add(new No(cr,y-a,0)).add(new No(na,y,a,y-z,0,y,z)).add(new No(cr,y,x-a)).add(new No(na,y-a,x,y,x-z,y-z,x)).add(new No(cr,a,x)).add(new No(na,0,x-a,z,x,0,x-z)).add(new No(cr,0,a)).add(new No(na,a,0,0,z,z,0).close())),1E.x&&a.y>E.y&&a.rightE.x&&y.y>E.y&&y.right=x.maxSelectionCount)){this.G^=4096;var b=!1;if(x!==null){b=x.skipsUndoManager,x.skipsUndoManager=!0;var E=x.selection;E.ka(),a?E.add(this):E.remove(this),E.freeze()}this.g("isSelected",y,a),this.Wb(),a=this.selectionChanged,a!==null&&a(this),x!==null&&(x.$b(),x.skipsUndoManager=b)}}}},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&&(ol(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&&(ol(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&&(ol(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 Ln?(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&&(ol(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&&(ol(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&&(ol(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:Jr},set:function(a){var y=this.resizeCellSize;y.D(a)||(a=a.J(),ol(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&&(ol(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&&(ol(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:Wo},set:function(a){var y=this.rotationSpot;y.D(a)||(a=a.J(),ol(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&&ce("Cannot make a Group a member of itself: "+this.toString()),ce("Cannot make a Group indirectly contain itself: "+this.toString()+" already contains "+a.toString())),this.C(2);var x=this.diagram;if(y!==null?Zv(y,this):this instanceof Fi&&x!==null&&x.ai.remove(this),this.Ah=a,a!==null?Kv(a,this):this instanceof Fi&&x!==null&&x.ai.add(this),this.C(1),x!==null&&x.aa){var b=this.data,E=x.model;if(b!==null&&E.Xj()){var z=E.wa(a!==null?a.data:null);E.mp(b,z)}}if(b=this.containingGroupChanged,b!==null&&(E=!0,x!==null&&(E=x.aa,x.aa=!0),b(this,y,a),x!==null&&(x.aa=E)),this instanceof Fi){for(x=new un,ec(x,this,!0,0,!0),x=x.iterator;x.next();)if(b=x.value,b instanceof Dn)for(b=b.linksConnected;b.next();)yg(b.value)}if(this instanceof Dn){for(x=this.linksConnected;x.next();)yg(x.value);x=this.labeledLink,x!==null&&yg(x)}this.g("containingGroup",y,a),a!==null&&(y=a.layer,y!==null&&du(y,-1,a))}}else ce("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&&(ol(this),this.P.Kp=a,this.g("containingGroupChanged",y,a))}},isTopLevel:{get:function(){return!(this.containingGroup!==null||this instanceof Dn&&this.labeledLink!==null)}},layoutConditions:{get:function(){return this.P!==null?this.P.Cq:127},set:function(a){var y=this.layoutConditions;y!==a&&(ol(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&&(ol(this),this.P.Up=a,this.g("dragComputation",y,a))}},shadowOffset:{get:function(){return this.P!==null?this.P.zr:ms},set:function(a){var y=this.shadowOffset;y.D(a)||(a=a.J(),ol(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&&(ol(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&&(ol(this),this.P.Vg=a,this.N(),this.g("shadowBlur",y,a))}}}),fi.prototype.invalidateLayout=fi.prototype.C,fi.prototype.findCommonContainingGroup=fi.prototype.px,fi.prototype.isMemberOf=fi.prototype.Td,fi.prototype.findTopLevelPart=fi.prototype.sz,fi.prototype.findSubGraphLevel=fi.prototype.oz,fi.prototype.ensureBounds=fi.prototype.Va,fi.prototype.getDocumentBounds=fi.prototype.mi,fi.prototype.findObject=fi.prototype.fb,fi.prototype.moveTo=fi.prototype.moveTo,fi.prototype.invalidateAdornments=fi.prototype.Wb,fi.prototype.clearAdornments=fi.prototype.Ej,fi.prototype.removeAdornment=fi.prototype.Jf,fi.prototype.addAdornment=fi.prototype.bh,fi.prototype.findAdornment=fi.prototype.Pj,fi.prototype.updateTargetBindings=fi.prototype.La;var HS=!1;fi.className="Part",fi.LayoutNone=0,fi.LayoutAdded=1,fi.LayoutRemoved=2,fi.LayoutShown=4,fi.LayoutHidden=8,fi.LayoutNodeSized=16,fi.LayoutGroupLayout=32,fi.LayoutNodeReplaced=64,fi.LayoutStandard=127,fi.LayoutAll=16777215;function Oo(a,y){a===void 0||a instanceof Rs||typeof a=="string"?fi.call(this,a):(fi.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)}We(Oo,fi),Oo.prototype.toString=function(){var a=this.adornedPart;return"Adornment("+this.category+")"+(a!==null?a.toString():"")},Oo.prototype.updateRelationshipsFromData=function(){},Oo.prototype.Ul=function(a){var y=this.adornedObject,x=y==null?void 0:y.part;if(x instanceof Ln&&y instanceof Ki){y=x.path,x.Ul(a),a=y.geometry,x=this.O.s,y=x.length;for(var b=0;ba&&(a=1);var y=this.diagram;if(y!==null&&!y.Ue){y.Ue=!0;var x=new un;x.add(this),YS(this,x,y.isTreePathToChildren,a,y,this,y.treeCollapsePolicy===xd),y.Ue=!1}};function YS(a,y,x,b,E,z,tt){if(1a&&(a=2);var y=this.diagram;if(y!==null&&!y.Ue){y.Ue=!0;var x=new un;x.add(this),_S(this,x,y.isTreePathToChildren,a,y,this,y.treeCollapsePolicy===xd),y.Ue=!1}};function _S(a,y,x,b,E,z,tt){for(var ot=z===a?!1:a.isTreeExpanded,rt=x?a.Mo():a.Sd(),lt={};rt.next();){var ut=rt.value;if(ut.isTreeLink&&(ot||ut.fd||ut.bb(),ut=ut.To(a),ut!==null&&ut!==a&&!y.contains(ut))){if(y.add(ut),!ot){ut.Zb(!0),ut.oh();var ft=x?ut.Oo():ut.Po();lt.vv=a,ft.all(function(vt){return function(xt){return xt===vt.vv||!xt.isTreeExpanded}}(lt))&&E.Cj(ut,z)}(2E&&(E=ot.right),ot.bottom>z&&(z=ot.bottom)}}return isFinite(x)&&isFinite(b)?a.h(x,b,E-x,z-b):(y=y.location,a.h(y.x,y.y,0,0)),a},Jt.Object.defineProperties(Ga.prototype,{padding:{get:function(){return this.yb},set:function(a){typeof a=="number"&&(a=new ci(a));var y=this.yb;y.D(a)||(this.yb=a=a.J(),this.g("padding",y,a),this.v())}}}),Ga.className="Placeholder";function Ln(a){fi.call(this,Pn.Link),this.Qa=8,this.ef=null,this.ff="",this.uf=this.gn=null,this.vf="",this.uo=null,this.qk=$a,this.Om=0,this.Qm=$a,this.Rm=NaN,this.qj=_v,this.po=.5,this.wd=null,this.Nb=new mn().freeze(),this.Tg=this.Mg=null,this.ml=new Ye,this.ua=new kn,this.u=this.o=this.Sf=this.Wf=null,this.su=new Gt,this.cq=this.Mw=this.Lw=null,this.vt=NaN,this.ba=null,this.j=[],a&&Object.assign(this,a)}We(Ln,fi),Ln.prototype.cloneProtected=function(a){fi.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())},bt=Ln.prototype,bt.Af=function(a){fi.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&&wl(y),a=a.toPort,a!==null&&wl(a)},bt.qb=function(a){a.classType===Ln?(a.value&2)===2?this.routing=a:a===Kl||a===kd||a===xg?this.curve=a:a===Pp||a===qm||a===t0?this.adjusting=a:a!==_v&&a!==$a&&ce("Unknown Link enum value for a Link property: "+a):fi.prototype.qb.call(this,a)},bt.Xc=function(){this.ba===null&&(this.ba=new ap)},bt.si=function(){var a=this.fromNode;if(a!==null){var y=a.findVisibleNode();if(y!==null&&(a=y),ja(a)||qd(a))return!1}return a=this.toNode,!(a!==null&&(y=a.findVisibleNode(),y!==null&&(a=y),ja(a)||qd(a)))},bt.zv=function(){return!1},bt.Av=function(){},bt.Zc=function(){return!1},Ln.prototype.computeAngle=function(a,y,x){return Ln.computeAngle(y,x)},Ln.computeAngle=function(a,y){switch(a){default:case $a:a=0;break;case wp:a=y;break;case Cp:a=y+90;break;case bp:a=y-90;break;case Jv:a=y+180;break;case e0:a=Ce.bp(y),90a&&(a-=180);break;case Lp:a=Ce.bp(y+90),90a&&(a-=180);break;case Mp:a=Ce.bp(y-90),90a&&(a-=180);break;case n0:if(a=Ce.bp(y),45a||225a)return 0;90a&&(a-=180)}return Ce.bp(a)};function yg(a){var y=a.fromNode,x=a.toNode,b=null;if(y!==null?b=x!==null?y.px(x):y.containingGroup:x!==null?b=x.containingGroup:b=null,y=b,x=a.Ah,x!==y){x!==null&&Zv(x,a),a.Ah=y,y!==null&&Kv(y,a);var E=a.containingGroupChanged;if(E!==null){var z=!0,tt=a.diagram;tt!==null&&(z=tt.aa,tt.aa=!0),E(a,x,y),tt!==null&&(tt.aa=z)}!a.fd||a.Lw!==x&&a.Mw!==x||a.bb()}if(a.isLabeledLink)for(a=a.labelNodes;a.next();)a.value.containingGroup=b}bt=Ln.prototype,bt.oh=function(){var a=this.containingGroup;a!==null&&this.fromNode!==a&&this.toNode!==a&&a.computesBoundsIncludingLinks&&fi.prototype.oh.call(this)},bt.To=function(a){var y=this.fromNode;return a===y?this.toNode:y},bt.Cz=function(a){var y=this.fromPort;return a===y?this.toPort:y};function qS(a,y){a.wd===null&&(a.wd=new un),a.wd.add(y),a.v()}bt.Vo=function(a){if(fi.prototype.Vo.call(this,a),Uc(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 b=this.toPort;x===a&&b===y||Zm(x,this,b)}Sp(this)}},bt.Wo=function(a){if(fi.prototype.Wo.call(this,a),Uc(this)&&this.Xo(this.actualBounds),!a){a=this.ef;var y=null;a!==null&&(y=this.fromPort,Vm(a,this,y));var x=this.uf;if(x!==null){var b=this.toPort;x===a&&b===y||Vm(x,this,b)}xp(this)}},bt.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))},Ln.prototype.updateRelationshipsFromData=function(){if(this.data!==null){var a=this.diagram;a!==null&&a.partManager.updateRelationshipsFromData(this)}},Ln.prototype.move=function(a,y){var x=y?this.location:this.position,b=x.x;isNaN(b)&&(b=0);var E=x.y;for(isNaN(E)&&(E=0),b=a.x-b,E=a.y-E,y===!0?fi.prototype.move.call(this,a,!1):(a=Gt.allocAt(x.x+b,x.y+E),fi.prototype.move.call(this,a,!1),Gt.free(a)),Ed(this,b,E),a=this.labelNodes;a.next();)y=a.value,x=y.position,y.moveTo(x.x+b,x.y+E)},Ln.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},Ln.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},Ln.prototype.computeMidPoint=function(a){var y=this.pointsCount;if(y===0)return a.assign(ks),a;if(y===1)return a.assign(this.i(0)),a;if(y===2){var x=this.i(0),b=this.i(1);return a.h((x.x+b.x)/2,(x.y+b.y)/2),a}if(this.isOrthogonal&&(15<=this.computeCorner()||this.computeCurve()===Kl))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()===Kl){if(y===3){x=this.i(0),b=this.i(1);var E=this.i(2);return Ce.ax(x.x,x.y,b.x,b.y,b.x,b.y,E.x,E.y,a),a}if(b=(y-1)/3|0,x=3*(b/2|0),b%2===1){b=this.i(x),E=this.i(x+1);var z=this.i(x+2);x=this.i(x+3),Ce.ax(b.x,b.y,E.x,E.y,z.x,z.y,x.x,x.y,a)}else a.assign(this.i(x));return a}var tt=this.flattenedLengths;for(x=this.flattenedTotalLength,E=z=b=0;bx/2));)b+=E,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-b)):a.h(y.x,y.y+(x/2-b)):1>Math.abs(y.y-z.y)?y.x>z.x?a.h(y.x-(x/2-b),y.y):a.h(y.x+(x/2-b),y.y):(x=(x/2-b)/E,a.h(y.x+x*(z.x-y.x),y.y+x*(z.y-y.y))),a},Ln.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()===Kl))return this.ua.wx(.5);if(this.computeCurve()===Kl&&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 b=this.i(x+2);return x=this.i(x+3),Ce.My(a.x,a.y,y.x,y.y,b.x,b.y,x.x,x.y)}if(0b/2));)E+=z,x++;if(y=this.i(x),b=this.i(x+1),1>Math.abs(y.x-b.x)&&1>Math.abs(y.y-b.y)){if(0Math.abs(y.x-b.x))return y.y>b.y?270:90;if(1>Math.abs(y.y-b.y))return y.x>b.x?180:0}return y.ab(b)},bt=Ln.prototype,bt.i=function(a){return this.Nb.s[a]},bt.dd=function(a,y){this.Nb.cd(a,y)},bt.L=function(a,y,x){this.Nb.cd(a,new Gt(y,x))},bt.Kz=function(a,y){this.Nb.Gb(a,y)},bt.m=function(a,y,x){this.Nb.Gb(a,new Gt(y,x))},bt.ne=function(a){this.Nb.add(a)},bt.yf=function(a,y){this.Nb.add(new Gt(a,y))},bt.pv=function(a){this.Nb.mb(a)},bt.Fj=function(){this.Nb.clear()};function Ed(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 b=a.fd,E=new mn,z=a.Nb.iterator;z.next();){var tt=z.value;E.add(new Gt(tt.x+y,tt.y+x).freeze())}E.freeze(),z=a.Nb,a.Nb=E,tt=a.diagram,isNaN(y)||isNaN(x)||tt!==null&&tt.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),za(a)),b?Ym(a):(a.defaultFromPoint&&(a.defaultFromPoint=a.i(0)),a.defaultToPoint&&(a.defaultToPoint=a.i(a.pointsCount-1))),tt!==null&&tt.animationManager.zb&&vr(tt.animationManager,a,E),a.g("points",z,E)}}bt.uh=function(){this.Mg===null&&(this.Mg=this.Nb,this.Nb=this.Nb.copy())},bt.zf=function(){if(this.Mg!==null){for(var a=this.Mg,y=this.Nb,x=1/0,b=1/0,E=a.s,z=E.length,tt=0;ttlt&&(ft=-ft),Ot=(0>rt?-1:1)*ft+xt,Kt=ut*(Ot-xt)+Ct),xt=z.x+2*ot/3,Ct=z.y+2*rt/3;var zt=xt,te=Ct;Ce.B(rt,0)?te=0rt?-1:1)*ft+xt,te=ut*(zt-xt)+Ct),this.Fj(),this.ne(z),this.yf(Ot,Kt),this.yf(zt,te),this.ne(vt),this.dd(0,this.getLinkPoint(a,y,tt,!0,!1,b,E)),this.dd(3,this.getLinkPoint(b,E,x,!1,!1,a,y))}else z=b,vt=E,b=this.getLinkPoint(a,y,tt,!0,!1,z,vt),E=this.getLinkPoint(z,vt,x,!1,!1,a,y),this.hasCurviness()?(vt=E.x-b.x,x=E.y-b.y,tt=this.computeCurviness(),a=b.x+vt/2,y=b.y+x/2,z=a,ot=y,Ce.B(x,0)?ot=0tt&&(z=-z),z=(0>x?-1:1)*z+a,ot=vt*(z-a)+y),this.ne(b),this.yf(z,ot),this.ne(E)):(this.ne(b),this.ne(E),ot=Ye.alloc(),y.mi(ot),rt=ot.ca(E),vt.mi(ot),lt=ot.ca(b),(rt||lt)&&(tt=y.ga(_m(tt),new Gt),this.dd(0,this.getLinkPointFromPoint(a,y,tt,E,!0,tt)),x=vt.ga(_m(x),new Gt),this.dd(1,this.getLinkPointFromPoint(z,vt,x,b,!1,x))),Ye.free(ot))}else{ft=this.isAvoiding,vt&&(ut&&ft||lt)&&this.Fj();var re=lt?this.computeCurviness():0;ft=this.getLinkPoint(a,y,tt,!0,ut,b,E),xt=Ot=Ct=0,(ut||!ot||lt)&&(Kt=this.computeEndSegmentLength(a,y,tt,!0),xt=this.getLinkDirection(a,y,ft,tt,!0,ut,b,E),lt&&(ot||tt.D(x)||!ut&&tt.x+x.x===1&&tt.y+x.y===1)&&(xt-=ut?90:30,0>re&&(xt-=180)),0>xt?xt+=360:360<=xt&&(xt-=360),lt&&(Kt+=Math.abs(re)*(ut?1:2)),xt===0?Ct=Kt:xt===90?Ot=Kt:xt===180?Ct=-Kt:xt===270?Ot=-Kt:(Ct=Kt*Math.cos(xt*Math.PI/180),Ot=Kt*Math.sin(xt*Math.PI/180)),tt.Mc()&<&&(Kt=y.ga(Co,Gt.alloc()),zt=Gt.allocAt(Kt.x+1e3*Ct,Kt.y+1e3*Ot),this.getLinkPointFromPoint(a,y,Kt,zt,!0,ft),Gt.free(Kt),Gt.free(zt))),Kt=this.getLinkPoint(b,E,x,!1,ut,a,y);var he=te=zt=0;if(ut||!rt||lt){var ve=this.computeEndSegmentLength(b,E,x,!1);he=this.getLinkDirection(b,E,Kt,x,!1,ut,a,y),lt&&(rt||tt.D(x)||!ut&&tt.x+x.x===1&&tt.y+x.y===1)&&(he+=ut?0:30,0>re&&(he+=180)),0>he?he+=360:360<=he&&(he-=360),lt&&(ve+=Math.abs(re)*(ut?1:2)),he===0?zt=ve:he===90?te=ve:he===180?zt=-ve:he===270?te=-ve:(zt=ve*Math.cos(he*Math.PI/180),te=ve*Math.sin(he*Math.PI/180)),x.Mc()&<&&(x=E.ga(Co,Gt.alloc()),tt=Gt.allocAt(x.x+1e3*zt,x.y+1e3*te),this.getLinkPointFromPoint(b,E,x,tt,!1,Kt),Gt.free(x),Gt.free(tt))}x=ft,(ut||!ot||lt)&&(x=new Gt(ft.x+Ct,ft.y+Ot)),tt=Kt,(ut||!rt||lt)&&(tt=new Gt(Kt.x+zt,Kt.y+te)),!vt&&!ut&&ot&&3Math.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}Ln.prototype.getLinkPointFromPoint=function(a,y,x,b,E,z){if(z===void 0&&(z=new Gt),a===null||y===null)return z.assign(x),z;if(a.isVisible()||(E=a.findVisibleNode(),E!==null&&E!==a&&(y=E.port)),a=null,E=y.panel,E===null||E.se()||(E=E.panel),E===null){E=b.x,b=b.y;var tt=x.x;x=x.y}else{a=E.oe,E=1/(a.m11*a.m22-a.m12*a.m21),tt=a.m22*E;var ot=-a.m12*E,rt=-a.m21*E,lt=a.m11*E,ut=E*(a.m21*a.dy-a.m22*a.dx),ft=E*(a.m12*a.dx-a.m11*a.dy);E=b.x*tt+b.y*rt+ut,b=b.x*ot+b.y*lt+ft,tt=x.x*tt+x.y*rt+ut,x=x.x*ot+x.y*lt+ft}return y.Sj(E,b,tt,x,z),a!==null&&z.transform(a),z};function Xm(a,y){var x=y.Zn;return x===null&&(x=new Ef,x.port=y,x.node=y.part,y.Zn=x),a1(x,a)}Ln.prototype.getLinkPoint=function(a,y,x,b,E,z,tt,ot){if(ot===void 0&&(ot=new Gt),x.sb()&&!Sg(x))return y.ga(x,ot),ot;if(x.$c()){var rt=Xm(this,y);if(rt!==null){if(ot.assign(rt.Zo),E&&this.routing===e1){var lt=Xm(this,tt);if(lt!==null&&rt.Gl=ut.y&&a.y<=ut.y+ut.height?ot.y=a.y:(x.Hf(Pu)||x.Hf(sl))&&a.x>=ut.x&&a.x<=ut.x+ut.width&&(ot.x=a.x),Gt.free(rt),Gt.free(lt)}}return ot}}return x=y.ga(_m(x),Gt.alloc()),this.pointsCount>(E?6:2)?(tt=b?this.i(1):this.i(this.pointsCount-2),E&&(tt=Vv(x,tt.copy()))):(rt=this.computeSpot(!b,tt),z=Gt.alloc(),tt=tt.ga(_m(rt),z),E&&(tt=Vv(x,tt)),Gt.free(z)),this.getLinkPointFromPoint(a,y,x,tt,b,ot),Gt.free(x),ot},Ln.prototype.getLinkDirection=function(a,y,x,b,E,z,tt,ot){t:if(b.sb())var rt=b.x>b.y?b.x>1-b.y?0:b.x<1-b.y?270:315:b.x1-b.y?90:b.x<1-b.y?180:135:.5>b.x?225:.5(z?6:2)?(ot=E?this.i(1):this.i(this.pointsCount-2),ot=z?Vv(rt,ot.copy()):x):(x=Gt.alloc(),ot=ot.ga(Co,x),Gt.free(x)),x=Math.abs(ot.x-rt.x)>Math.abs(ot.y-rt.y)?ot.x>=rt.x?0:180:ot.y>=rt.y?90:270,Gt.free(rt),rt=x}return b.Mc()&&tt.Td(a)&&(rt+=180,360<=rt&&(rt-=360)),Sg(b)||(a=y.li(),a===0)||(45<=a&&135>a?rt+=90:135<=a&&225>a?rt+=180:225<=a&&315>a&&(rt+=270),360<=rt&&(rt-=360)),rt},Ln.prototype.computeEndSegmentLength=function(a,y,x,b){return y!==null&&x.$c()&&(a=Xm(this,y),a!==null)?a.Ju:(a=b?this.fromEndSegmentLength:this.toEndSegmentLength,y!==null&&isNaN(a)&&(a=b?y.fromEndSegmentLength:y.toEndSegmentLength),isNaN(a)&&(a=10),a)},Ln.prototype.computeSpot=function(a,y){return y===void 0&&(y=null),a?(a=y||this.fromPort,a===null?a=Co:(y=this.fromSpot,y.Xb()&&(y=a.fromSpot),a=y===Wo?Qr:y)):(a=y||this.toPort,a===null?a=Co:(y=this.toSpot,y.Xb()&&(y=a.toSpot),a=y===Wo?Qr:y)),a};function Sg(a){return a===Qr||a.x===.5&&a.y===.5}function _m(a){return a.x===.5&&a.y===.5?a:Co}Ln.prototype.computeOtherPoint=function(a,y){return this.computeAdjusting()!==$a&&4vt.width||ft.y>vt.height||0>ft.x+ft.width||0>ft.y+ft.height)){if(ft=Yi.alloc(),ft.set(tt),ut instanceof Pn)ot=ut.Cf(a,y,x,b,E,ft);else if(this.path===ut){if(ut instanceof Ki)if(ot=a,vt=b,ut.pickable===!1)ot=!1;else if(ft.multiply(ut.transform),vt)t:{var xt=ot,Ct=ft;if(ut.fh(xt,Ct))ot=!0;else{if(Ct===void 0&&(Ct=ut.transform,xt.Re(ut.actualBounds))){ot=!0;break t}ot=xt.left,vt=xt.right;var Ot=xt.top;xt=xt.bottom;var Kt=Gt.alloc(),zt=Gt.alloc(),te=Gt.alloc(),re=Yi.alloc();re.set(Ct),re.bv(ut.transform),re.Vj(),zt.x=vt,zt.y=Ot,zt.transform(re),Kt.x=ot,Kt.y=Ot,Kt.transform(re),Ct=!1,Zc(ut,Kt,zt,te)?Ct=!0:(Kt.x=vt,Kt.y=xt,Kt.transform(re),Zc(ut,Kt,zt,te)?Ct=!0:(zt.x=ot,zt.y=xt,zt.transform(re),Zc(ut,Kt,zt,te)?Ct=!0:(Kt.x=ot,Kt.y=Ot,Kt.transform(re),Zc(ut,Kt,zt,te)&&(Ct=!0)))),Yi.free(re),Gt.free(Kt),Gt.free(zt),Gt.free(te),ot=Ct}}else ot=ut.fh(ot,ft)}else ot=Zs(ut,a,b,ft);ot&&(vt=ut,y!==null&&(vt=y(ut)),vt&&(x===null||x(vt))&&E.add(vt)),Yi.free(ft)}}}return z===void 0&&Yi.free(tt),ot||this.background!==null||this.areaBackground!==null}return z===void 0&&Yi.free(tt),!1},Ln.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?Kl:this.curve},Ln.prototype.computeCorner=function(){if(this.curve===Kl)return 0;var a=this.corner;return(isNaN(a)||0>a)&&(a=10),a},Ln.prototype.findMidLabel=function(){for(var a=this.path,y=this.O.s,x=y.length,b=0;brt?-Math.PI/2:Math.PI/2;else ut=Math.atan(rt/Math.abs(ot)),0>ot&&(ut=Math.PI-ut);tt=y.x;var ft=y.y;ot=b.x-tt;var vt=b.y-ft;for(rt=Math.sqrt(ot*ot+vt*vt),Ce.$(ot,0)?vt=0>vt?-Math.PI/2:Math.PI/2:(vt=Math.atan(vt/Math.abs(ot)),0>ot&&(vt=Math.PI-vt)),lt=rt/lt,ut=vt-ut,this.dd(a,y),a+=1;art?-Math.PI/2:Math.PI/2:(rt=Math.atan(rt/Math.abs(ot)),0>ot&&(rt=Math.PI-rt)),ot=rt+ut,y*=lt,this.L(a,tt+y*Math.cos(ot),ft+y*Math.sin(ot)));this.dd(x,b)}}return!0;case t0:if(z=this.i(a),ft=this.i(x),!z.Xa(y)||!ft.Xa(b)){E=z.x,z=z.y,tt=ft.x,ft=ft.y,lt=(tt-E)*(tt-E)+(ft-z)*(ft-z),ot=y.x,ut=y.y,rt=b.x,vt=b.y;var xt=1;if(rt-ot!==0){var Ct=(vt-ut)/(rt-ot);xt=Math.sqrt(1+1/(Ct*Ct))}else Ct=9e9;for(this.dd(a,y),a+=1;ay?y+=360:360<=y&&(y-=360),0>b?b+=360:360<=b&&(b-=360);var tt=b;y=315<=y||45>y?0:45<=y&&135>y?90:135<=y&&225>y?180:270,b=315<=b||45>b?0:45<=b&&135>b?90:135<=b&&225>b?180:270;var ot=E.actualBounds.copy(),rt=z.actualBounds.copy();if(ot.w()&&rt.w()){ot.Bc(Ep,Ep),rt.Bc(Ep,Ep),ot.Ye(a),rt.Ye(x);var lt=Gt.alloc(),ut=Gt.alloc();y===0?x.x>a.x||b===270&&x.ya.x||b===90&&x.y>a.y&&rt.right>a.x?(lt.h(x.x,a.y),ut.h(x.x,(a.y+x.y)/2),b===180?(lt.x=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1),ut.x=lt.x,ut.y=x.y):b===270&&x.ya.y?(lt.x=a.xrt.bottom)?this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1):rt.right,ut.x=lt.x,ut.y=x.y):b===0&&a.xrt.top&&a.yot.bottom)&&(b===180&&(rt.ca(a)||ot.ca(x))?lt.y=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0):x.ya.y&&(b===180||b===270)&&(lt.y=this.computeMidOrthoPosition(a.x,ot.bottom,x.x,Math.min(x.y,rt.top),!0)),ut.x=x.x,ut.y=lt.y),lt.y>ot.top&<.y=ot.left&&x.x<=a.x||a.x<=rt.right&&a.x>=x.x?(b===90||b===270)&&(lt.h(Math.max((a.x+x.x)/2,a.x),a.y),ut.h(lt.x,x.y)):(lt.y=b===270||(b===0||b===180)&&x.ya.y&&rt.lefta.y?(lt.x=a.x>rt.right?this.computeMidOrthoPosition(a.x,a.y,rt.right,x.y,!1):a.x>rt.left&&(b===270&&a.yrt.bottom)?this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1):rt.left,ut.x=lt.x,ut.y=x.y):b===180&&a.x>rt.right&&a.y>rt.top&&a.yot.bottom)&&(b===0&&(rt.ca(a)||ot.ca(x))?lt.y=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0):x.ya.y&&(b===0||b===270)&&(lt.y=this.computeMidOrthoPosition(a.x,ot.bottom,x.x,Math.min(x.y,rt.top),!0)),ut.x=x.x,ut.y=lt.y),lt.y>ot.top&<.y=a.x||a.x>=rt.left&&a.x<=x.x?(b===90||b===270)&&(lt.h(Math.min((a.x+x.x)/2,a.x),a.y),ut.h(lt.x,x.y)):(lt.y=b===270||(b===0||b===180)&&x.ya.y||b===180&&x.xa.y||b===0&&x.x>a.x&&rt.bottom>a.y?(lt.h(a.x,x.y),ut.h((a.x+x.x)/2,x.y),b===270?(lt.y=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0),ut.x=x.x,ut.y=lt.y):b===180&&x.xa.x?(lt.y=a.yrt.right)?this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0):rt.bottom,ut.x=x.x,ut.y=lt.y):b===90&&a.yrt.left&&a.xot.right)&&(b===270&&(rt.ca(a)||ot.ca(x))?lt.x=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1):x.xa.x&&(b===270||b===180)&&(lt.x=this.computeMidOrthoPosition(ot.right,a.y,Math.min(x.x,rt.left),x.y,!1)),ut.x=lt.x,ut.y=x.y),lt.x>ot.left&<.x=ot.top&&x.y<=a.y||a.y<=rt.bottom&&a.y>=x.y?(b===0||b===180)&&(lt.h(a.x,Math.max((a.y+x.y)/2,a.y)),ut.h(x.x,lt.y)):(lt.x=b===180||(b===90||b===270)&&x.xa.x&&rt.top=a.x?(lt.y=a.y>rt.bottom?this.computeMidOrthoPosition(a.x,a.y,x.x,rt.bottom,!0):a.y>rt.top&&(b===180&&a.xrt.right)?this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!0):rt.top,ut.x=x.x,ut.y=lt.y):b===270&&a.y>rt.bottom&&a.x>rt.left&&a.xot.right)&&(b===90&&(rt.ca(a)||ot.ca(x))?lt.x=this.computeMidOrthoPosition(a.x,a.y,x.x,x.y,!1):x.xa.x&&(b===90||b===180)&&(lt.x=this.computeMidOrthoPosition(ot.right,a.y,Math.min(x.x,rt.left),x.y,!1)),ut.x=lt.x,ut.y=x.y),lt.x>ot.left&<.x=a.y||a.y>=rt.top&&a.y<=x.y?(b===0||b===180)&&(lt.h(a.x,Math.min((a.y+x.y)/2,a.y)),ut.h(x.x,lt.y)):(lt.x=b===180||(b===90||b===270)&&x.x=wg&&(o1(xt),ot.Bc(xt.Ho*xt.Hx,xt.Go*xt.Ix),r1(xt,a,y,ft,b,ot,!1),rt=Oh(xt,ft.x,ft.y)),!xt.abort&&rtthis.pointsCount?(y===0||y===180?(ot.x=a.x,ot.y=ft.y):(ot.x=ft.x,ot.y=a.y),this.L(2,ot.x,ot.y),this.m(3,ot.x,ot.y)):(tt=this.i(3),y===0||y===180?Ce.B(ot.x,tt.x)?(ot=y===0?Math.max(ot.x,a.x):Math.min(ot.x,a.x),this.L(2,ot,a.y),this.L(3,ot,tt.y)):Ce.B(ot.y,tt.y)?(Math.abs(a.y-ot.y)<=xt.Go/2&&(this.L(2,ot.x,a.y),this.L(3,tt.x,a.y)),this.m(2,ot.x,a.y)):this.L(2,a.x,ot.y):(y===90||y===270)&&(Ce.B(ot.y,tt.y)?(ot=y===90?Math.max(ot.y,a.y):Math.min(ot.y,a.y),this.L(2,a.x,ot),this.L(3,tt.x,ot)):Ce.B(ot.x,tt.x)?(Math.abs(a.x-ot.x)<=xt.Ho/2&&(this.L(2,a.x,ot.y),this.L(3,a.x,tt.y)),this.m(2,a.x,ot.y)):this.L(2,ot.x,a.y))),x!==null&&(a=this.i(1),tt=this.i(2),a.x!==tt.x&&a.y!==tt.y?y===0||y===180?this.m(2,a.x,tt.y):this.m(2,tt.x,a.y):y===0||y===180?this.m(2,E.x,x.y):this.m(2,x.x,E.y)),Ct!==null&&(b===0||b===180?this.yf(z.x,Ct.y):this.yf(Ct.x,z.y)),y=!0):y=!1}}}else y=!1;y||(this.ne(lt.copy()),this.ne(ut.copy())),Gt.free(lt),Gt.free(ut)}},Ln.prototype.computeMidOrthoPosition=function(a,y,x,b,E){var z=0;return!this.hasCurviness()||this.computeSpot(!0,this.fromPort).$c()||this.computeSpot(!1,this.toPort).$c()||(z=this.computeCurviness()),E?(y+b)/2+z:(a+x)/2+z};function Uv(a){if(a.diagram===null||!a.isAvoiding||!qf(a.diagram))return!1;var y=a.points.s,x=y.length;if(4>x)return!1;a=tg(a.diagram,!0,a.containingGroup,null);for(var b=1;bYc&&Oh(y,ut,ft)!==lt-1&&(Oh(y,x-ot,b)===lt-1?(E=180,ut=x-ot,ft=b):Oh(y,x+ot,b)===lt-1?(E=0,ut=x+ot,ft=b):Oh(y,x,b-rt)===lt-1?(E=270,ut=x,ft=b-rt):Oh(y,x,b+rt)===lt-1&&(E=90,ut=x,ft=b+rt));lt>Yc&&Oh(y,ut,ft)===lt-1;)x=ut,b=ft,E===0?ut+=ot:E===90?ft+=rt:E===180?ut-=ot:ft-=rt,--lt;z?lt>Yc&&(E===180||E===0?x=Math.floor(x/ot)*ot+ot/2:(E===90||E===270)&&(b=Math.floor(b/rt)*rt+rt/2)):(x=Math.floor(x/ot)*ot+ot/2,b=Math.floor(b/rt)*rt+rt/2),lt>Yc&&(z=E,tt=x,ut=b,E===0?(z=90,ut+=rt):E===90?(z=180,tt-=ot):E===180?(z=270,ut-=rt):E===270&&(z=0,tt+=ot),Oh(y,tt,ut)===lt-1?Yv(a,y,tt,ut,z,!1,z):(tt=x,ut=b,E===0?(z=270,ut-=rt):E===90?(z=0,tt+=ot):E===180?(z=90,ut+=rt):E===270&&(z=180,tt-=ot),Oh(y,tt,ut)===lt-1&&Yv(a,y,tt,ut,z,!1,z))),a.yf(x,b)}Ln.prototype.ez=function(a){var y=a.x;a=a.y;for(var x=this.i(0),b=this.i(1),E=lr(y,a,x.x,x.y,b.x,b.y),z=0,tt=1;ttthis.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,b=0;b=y&&(b=y-1),rt=this.i(b),z.x=Math.min(rt.x,z.x),z.y=Math.min(rt.y,z.y);b=z.x,rt=z.y}else{for(rt=0;rtKt?Ct>xt?(z.x=zt-re,z.y=xt-re,E.x=zt+Ot,E.y=xt+Ot):(z.x=zt-re,z.y=xt+re,E.x=zt+Ot,E.y=xt-Ot):Ct>xt?(z.x=zt+re,z.y=xt-re,E.x=zt-Ot,E.y=xt+Ot):(z.x=zt+re,z.y=xt+re,E.x=zt-Ot,E.y=xt-Ot)),Ce.$(Kt,zt)&&Ce.$(xt,Ct)&&(xt>vt?(te>zt?(z.x=zt-re,z.y=xt-re,E.x=zt+Ot):(z.x=zt+re,z.y=xt-re,E.x=zt-Ot),E.y=xt+Ot):(te>zt?(z.x=zt-re,z.y=xt+re,E.x=zt+Ot):(z.x=zt+re,z.y=xt+re,E.x=zt-Ot),E.y=xt-Ot)),(Ce.$(Kt,zt)&&Ce.$(zt,te)||Ce.$(vt,xt)&&Ce.$(xt,Ct))&&(Kt=.5*(Kt+te),vt=.5*(vt+Ct),z.x=Kt,z.y=vt,E.x=Kt,E.y=vt),(ft===1||ft===2&&Ce.$(tt.x,this.i(0).x)&&Ce.$(tt.y,this.i(0).y))&&(x.x=.5*(tt.x+lt.x),x.y=.5*(tt.y+lt.y)),bd(ot,x.x-b,x.y-rt,z.x-b,z.y-rt,lt.x-b,lt.y-rt),y.set(z),x.set(E),tt=lt}}lt=tt.x,tt=tt.y,ut=this.i(this.pointsCount-1),this.computeShortLength(!1)!==0&&(ut=Cf(this,ut.copy(),!1,qo)),lt=.5*(lt+ut.x),tt=.5*(tt+ut.y),bd(ot,E.x-b,E.y-rt,lt-b,tt-rt,ut.x-b,ut.y-rt),Gt.free(y),Gt.free(x),Gt.free(z),Gt.free(E)}else for(x=3;x=y&&(x=y-1),E=this.i(x-1),tt=this.i(x),x===y-1&&this.computeShortLength(!1)!==0&&(tt=Cf(this,tt.copy(),!1,qo)),bd(ot,z.x-b,z.y-rt,E.x-b,E.y-rt,tt.x-b,tt.y-rt);else{for(z=Gt.alloc(),z.assign(this.i(0)),E=Gt.alloc(),E.assign(z),tt=this.computeCorner(),ft=1,lt=0;ft=y-1){if(!z.D(ut))this.computeShortLength(!1)!==0&&(ut=Cf(this,ut.copy(),!1,qo)),bf(this,ot,-b,-rt,z,ut,x);else if(lt===0)for(ft=1;ftz.x?he=vt.x-Ct:he=vt.x+Ct,zt.y>vt.y?te=vt.y+re:te=vt.y-re,zt=Gt.allocAt(he,ve),bf(this,ot,ft,Kt,z,zt,Ot),Gt.free(zt),Gm(ot,vt.x+ft,vt.y+Kt,xt+ft,te+Kt),z.h(xt,te)}else Ce.B(z.x,vt.x)&&Ce.B(vt.y,zt.y)?(Ct=Math.min(tt,Math.abs(vt.y-E.y)/2),Ct=re=Math.min(Ct,Math.abs(zt.x-vt.x)/2),Ce.B(re,0)?(bf(this,ot,ft,Kt,z,vt,Ot),z.assign(vt)):(he=vt.x,ve=vt.y,xt=he,te=ve,vt.y>z.y?ve=vt.y-Ct:ve=vt.y+Ct,zt.x>vt.x?xt=vt.x+re:xt=vt.x-re,zt=Gt.allocAt(he,ve),bf(this,ot,ft,Kt,z,zt,Ot),Gt.free(zt),Gm(ot,vt.x+ft,vt.y+Kt,xt+ft,te+Kt),z.h(xt,te))):(bf(this,ot,ft,Kt,z,vt,Ot),z.assign(vt));E.assign(ut),ft=lt}Gt.free(z)}$m=ot}else ot=this.i(1).copy(),ot.x-=b,ot.y-=rt,this.computeShortLength(!0)!==0&&(E=Cf(this,E,!0,z)),this.computeShortLength(!1)!==0&&(ot=Cf(this,ot,!1,z)),a.type=kn.j,a.startX=E.x,a.startY=E.y,a.endX=ot.x,a.endY=ot.y;return this.lk=!0,a};function Jm(a,y,x,b){return a=x-a,isNaN(a)||a===1/0||a===-1/0?NaN:(0>a&&(a=-a),y=b-y,isNaN(y)||y===1/0||y===-1/0?NaN:(0>y&&(y=-y),Ce.$(a,0)?y:Ce.$(y,0)?a:Math.sqrt(a*a+y*y)))}function Cf(a,y,x,b){var E=a.pointsCount;if(2>E)return y;if(x){var z=a.i(1);if(x=z.x-b.x,z=z.y-b.y,b=Jm(y.x,y.y,x,z),b===0)return y;E=E===2?.5*b:b,a=a.computeShortLength(!0),a>E&&(a=E),E=a*(z-y.y)/b,y.x+=a*(x-y.x)/b,y.y+=E}else{if(z=a.i(E-2),x=z.x-b.x,z=z.y-b.y,b=Jm(y.x,y.y,x,z),b===0)return y;E=E===2?.5*b:b,a=a.computeShortLength(!1),a>E&&(a=E),E=a*(y.y-z)/b,y.x-=a*(y.x-x)/b,y.y-=E}return y}function Xv(a,y,x,b){for(var E=a.pointsCount,z=y;Ce.$(y.x,z.x)&&Ce.$(y.y,z.y);){if(x>=E)return E-1;z=a.i(x++)}if(!Ce.$(y.x,z.x)&&!Ce.$(y.y,z.y))return x-1;for(var tt=z;Ce.$(y.x,z.x)&&Ce.$(z.x,tt.x)&&(!b||(y.y>=z.y?z.y>=tt.y:z.y<=tt.y))||Ce.$(y.y,z.y)&&Ce.$(z.y,tt.y)&&(!b||(y.x>=z.x?z.x>=tt.x:z.x<=tt.x));){if(x>=E)return E-1;tt=a.i(x++)}return x-2}Ln.prototype.computeJumpLength=function(){return 10};function bf(a,y,x,b,E,z,tt){if(!tt&&Uc(a)){tt=a.computeJumpLength();var ot=tt/2,rt=[],lt=0;if(a.isVisible()&&(lt=Lx(a,E,z,rt)),0ft-tt);)lt--,ft=Math.max(ut-ot,z.x);ut=z.y-tt+b,ft+=x,xt=z.y+b,a.curve===kd?vg(y,ft,xt,!1):bd(y,vt,ut,ft,ut,ft,xt)}else if(Ce.B(E.x,z.x))if(E.yut-tt);)lt--,ut=Math.max(ft-ot,z.y);ft=z.x-tt+x,xt=z.x+x,ut+=b,a.curve===kd?vg(y,xt,ut,!1):bd(y,ft,vt,ft,ut,xt,ut)}}}y.lineTo(z.x+x,z.y+b)}function Lx(a,y,x,b){var E=a.diagram;if(E===null||y.D(x))return 0;for(E=E.layers;E.next();){var z=E.value;if(z!==null&&z.visible){z=z.Pa.s;for(var tt=z.length,ot=0;ottt.x&&ut.x>=lt.x||lt.xtt.y&&ut.y>=lt.y||lt.ytt&&Math.min(Ct,Ot)ut&&!Ce.B(Ct,Ot)){ot.x=ut,ot.y=tt,ut=!0;break t}}else if(Ce.B(ft,xt)&&Ce.B(Ct,Ot)&&Math.min(ut,vt)Ct&&Math.min(tt,Kt)ft&&!Ce.B(tt,Kt)){ot.x=Ct,ot.y=ft,ut=!0;break t}ot.x=0,ot.y=0,ut=!1}ut&&(E?x.push(ot.x):x.push(ot.y)),tt=lt}Gt.free(ot)}function Uc(a){return a=a.curve,a===xg||a===kd}function Qm(a,y){(y||Uc(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()))}Ln.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 b=!1;for(x=x.layers;x.next();){var E=x.value;if(E.visible){if(E===y){b=!0;var z=!1;E=E.Pa.s;for(var tt=E.length,ot=0;ota&&An(a,">= 0",Ln,"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:Wo},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&&wl(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&&An(a,">= 0",Ln,"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=b&&(z=b-1);var ot=this.i(z-1),rt=this.i(z);Ce.Dl(E.x,E.y,tt.x,tt.y,ot.x,ot.y,rt.x,rt.y,.5,a),y=Math.min(rt.x,y),x=Math.min(rt.y,x),E=rt}else for(E=this.i(0),z=this.i(1),y=Math.min(E.x,z.x),x=Math.min(E.y,z.y),a.h(E.x,E.y,0,0),a.Ye(z),E=2;Eb&&(b=-b)):Ce.$(b.y,E.y)?(b=E.x-b.x,0>b&&(b=-b)):b=Math.sqrt(b.Bf(E)),a.push(b)}}return this.cq}},flattenedTotalLength:{get:function(){var a=this.vt;if(isNaN(a)){for(var y=this.flattenedLengths,x=y.length,b=a=0;bthis.pointsCount)return this.lk=!0,this.ua;this.ua=this.makeGeometry()}return this.ua}},firstPickIndex:{get:function(){return 2>=this.pointsCount?0:this.isOrthogonal||!Sg(this.computeSpot(!0))?1:0}},lastPickIndex:{get:function(){var a=this.pointsCount;return a===0?0:2>=a?a-1:this.isOrthogonal||!Sg(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===kd||y===xg||a===kd||a===xg),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)}}}),Ln.prototype.invalidateOtherJumpOvers=Ln.prototype.Xo,Ln.prototype.findClosestSegment=Ln.prototype.ez,Ln.prototype.updateRoute=Ln.prototype.vg,Ln.prototype.invalidateRoute=Ln.prototype.bb,Ln.prototype.rollbackRoute=Ln.prototype.rv,Ln.prototype.commitRoute=Ln.prototype.zf,Ln.prototype.startRoute=Ln.prototype.uh,Ln.prototype.clearPoints=Ln.prototype.Fj,Ln.prototype.removePoint=Ln.prototype.pv,Ln.prototype.addPointAt=Ln.prototype.yf,Ln.prototype.addPoint=Ln.prototype.ne,Ln.prototype.insertPointAt=Ln.prototype.m,Ln.prototype.insertPoint=Ln.prototype.Kz,Ln.prototype.setPointAt=Ln.prototype.L,Ln.prototype.setPoint=Ln.prototype.dd,Ln.prototype.getPoint=Ln.prototype.i,Ln.prototype.getOtherPort=Ln.prototype.Cz,Ln.prototype.getOtherNode=Ln.prototype.To;var Lf=null,Mf=null,_v=new Qe(Ln,"Normal",1),Ex=new Qe(Ln,"Orthogonal",2),kx=new Qe(Ln,"AvoidsNodes",6),e1=new Qe(Ln,"AvoidsNodesStraight",7),$a=new Qe(Ln,"None",0),Kl=new Qe(Ln,"Bezier",9),kd=new Qe(Ln,"JumpGap",10),xg=new Qe(Ln,"JumpOver",11),Pp=new Qe(Ln,"End",17),qm=new Qe(Ln,"Scale",18),t0=new Qe(Ln,"Stretch",19),wp=new Qe(Ln,"OrientAlong",21),Cp=new Qe(Ln,"OrientPlus90",22),bp=new Qe(Ln,"OrientMinus90",23),Jv=new Qe(Ln,"OrientOpposite",24),e0=new Qe(Ln,"OrientUpright",25),Lp=new Qe(Ln,"OrientPlus90Upright",26),Mp=new Qe(Ln,"OrientMinus90Upright",27),n0=new Qe(Ln,"OrientUpright45",28),n1=16,i1=14,Ep=8;Ln.className="Link",Ln.Normal=_v,Ln.Orthogonal=Ex,Ln.AvoidsNodes=kx,Ln.AvoidsNodesStraight=e1,Ln.None=$a,Ln.Bezier=Kl,Ln.JumpGap=kd,Ln.JumpOver=xg,Ln.End=Pp,Ln.Scale=qm,Ln.Stretch=t0,Ln.OrientAlong=wp,Ln.OrientPlus90=Cp,Ln.OrientMinus90=bp,Ln.OrientOpposite=Jv,Ln.OrientUpright=e0,Ln.OrientPlus90Upright=Lp,Ln.OrientMinus90Upright=Mp,Ln.OrientUpright45=n0,Ln.EndSegmentStep=8,Ln.CurvinessStart=n1,Ln.SpacingMin=i1,Ln.OrthoShortCut=Ep;function i0(a,y,x,b){Po(this),this.Fe=this.qq=!1,this.Ds=a,this.Ox=y,this.cv=x,this.Px=b,this.links=[]}i0.prototype.Sl=function(){if(!this.qq){var a=this.links;0=a.width||0>=a.height)){var y=a.y,x=a.x+a.width,b=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((b+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=Yc&&(x[b]=Qv)}kp.prototype.Yj=function(a,y,x,b){if(a>this.En||a+xthis.Fn||y+ba&&(x+=a,a=0),0>y&&(E+=y,y=0),0>x||0>E)return!0;for(b=Math.min(a+x-1,this.di)|0,x=Math.min(y+E-1,this.ei)|0;a<=b;a++){E=this.ac[a];for(var z=y;z<=x;z++)if(E[z]===Nd)return!1}return!0};function Fh(a,y,x,b,E,z,tt,ot,rt){if(!(ytt||xrt)){var lt=y|0,ut=x|0,ft=a.ac[lt][ut];if(ft>=Yc&&ft=a.ac[lt][ut]);)a.ac[lt][ut]=ft,ft+=1,E?ut+=b:lt+=b;if(lt=E?ut:lt,E)if(0lt;x+=b)Fh(a,y,x,1,!E,z,tt,ot,rt),Fh(a,y,x,-1,!E,z,tt,ot,rt);else if(0lt;y+=b)Fh(a,y,x,1,!E,z,tt,ot,rt),Fh(a,y,x,-1,!E,z,tt,ot,rt)}}function o0(a,y,x,b,E,z,tt,ot,rt){y|=0,x|=0;var lt=Nd,ut=Yc;for(a.ac[y][x]=ut;lt===Nd&&y>z&&yot&&xz&&yot&&x=Math.abs(ot-lt)&&1>=Math.abs(rt-ut))a.abort=!0;else{var ft=z.x;b=z.y,y=z.x+z.width;var vt=z.y+z.height;ft-=a.Nd,ft/=a.rc,b-=a.Od,b/=a.sc,y-=a.Nd,y/=a.rc,vt-=a.Od,vt/=a.sc,z=Math.max(0,Math.min(a.di,ft|0)),y=Math.min(a.di,Math.max(0,y|0)),ft=Math.max(0,Math.min(a.ei,b|0)),vt=Math.min(a.ei,Math.max(0,vt|0)),b=a.ac,ot|=0,rt|=0,lt|=0,ut|=0;var xt=x===0||x===90?1:-1;if(x=x===90||x===270,b[ot][rt]===Nd?(o0(a,ot,rt,xt,x,z,y,ft,vt),o0(a,ot,rt,1,!x,z,y,ft,vt),o0(a,ot,rt,-1,!x,z,y,ft,vt)):o0(a,ot,rt,xt,x,ot,rt,ot,rt),b[lt][ut]===Nd?(r0(a,lt,ut,E===0||E===90?1:-1,E===90||E===270,z,y,ft,vt),r0(a,lt,ut,1,!(E===90||E===270),z,y,ft,vt),r0(a,lt,ut,-1,!(E===90||E===270),z,y,ft,vt)):r0(a,lt,ut,xt,x,lt,ut,lt,ut),x=Zn(),tt&&s1(a,lt,ut,E,ot,rt,x))for((x[0]!==lt||x[1]!==ut)&&(x.unshift(ut),x.unshift(lt)),(x[x.length-2]!==ot||x[x.length-1]!==rt)&&(x.push(ot),x.push(rt)),a=Yc,E=x[x.length-2],tt=x[x.length-1],b[E][tt]=a++,z=x.length-4;0<=z;z-=2)for(E=x[z+2],tt=x[z+3],y=x[z],lt=x[z+1];y>E?E++:ytt?tt++:ltE)ut--;else break;else if(ft>z)ft--;else break;var vt=ot[ut][ft];if(vt===0||vt===qv)break;rt=ut,lt=ft}for(;;){if(ut=b,ft=rt,vt=lt,b===0?vtz&&(ut=270,vt--):b===90?ftE&&(ut=180,ft--):b===180?vtz&&(ut=270,vt--):ftE&&(ut=180,ft--),ft=ot[ft][vt],ut!==b&&ft!==0&&ft!==qv){if(tt.push(rt),tt.push(lt),s1(a,rt,lt,ut,E,z,tt))return!0;tt.pop(),tt.pop()}if(ot[rt][lt]=qv,b===0){if(rt===y)return!1;rt--}else if(b===90){if(lt===x)return!1;lt--}else if(b===180){if(rt===y)return!1;rt++}else{if(lt===x)return!1;lt++}}}Jt.Object.defineProperties(kp.prototype,{bounds:{get:function(){return new Ye(this.Nd,this.Od,this.En-this.Nd,this.Fn-this.Od)}},Ho:{get:function(){return this.rc},set:function(a){0=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 90180+a&&x<=360-a?270:0;case 13:return 180a&&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 b&&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}Ef.prototype.Sl=function(){this.pe.length=0};function a1(a,y){var x=a.pe;if(x.length===0){t:if(!a.ap){x=a.ap,a.ap=!0;var b=null,E=a.node,z=E instanceof Fi?E:null;if(z===null||z.isSubGraphExpanded)var tt=E.isTreeExpanded?E.findLinksConnected(a.port.portId):E.qx();else{if(!z.actualBounds.w()){a.ap=x;break t}b=z,tt=b.Lu()}z=a.pe.length=0;var ot=a.port.ga(js,Gt.alloc()),rt=a.port.ga(ka,Gt.alloc());for(E=Ye.allocAt(ot.x,ot.y,0,0),E.Ye(rt),Gt.free(ot),Gt.free(rt),ot=Gt.allocAt(E.x+E.width/2,E.y+E.height/2),rt=a.port.li(),tt=tt.iterator;tt.next();){var lt=tt.value;if(lt.isVisible()&<.fromPort!==lt.toPort){var ut=lt.fromPort===a.port||lt.fromNode!==null&<.fromNode.Td(b),ft=lt.computeSpot(ut,a.port);if(ft.$c()&&(ut=ut?lt.toPort:lt.fromPort,ut!==null)){var vt=ut.part;if(vt!==null){var xt=vt.findVisibleNode();xt!==null&&xt!==vt&&(vt=xt,ut=vt.port),ut=lt.computeOtherPoint(vt,ut),vt=ot.ab(ut),vt-=rt,0>vt?vt+=360:360<=vt&&(vt-=360),ft=Nx(E,ft,vt,lt.isOrthogonal),ft===0?(ft=4,180vt&&(vt+=360)),xt=a.pe[z],xt===void 0?(xt=new ty(lt,vt,ft),a.pe[z]=xt):(xt.link=lt,xt.angle=vt,xt.Nc=ft),xt.hv.set(ut),z++}}}}for(Gt.free(ot),a.pe.sort(Ef.prototype.j),rt=a.pe.length,b=-1,z=ot=0;zMath.abs(Ot)?(te=Math.abs(Ot)/vt,vt=Math.abs(Ot)):te=1;break;case 2:xt>Math.abs(re)?(te=Math.abs(re)/xt,xt=Math.abs(re)):te=1;break;case 1:ft>Math.abs(Ot)?(te=Math.abs(Ot)/ft,ft=Math.abs(Ot)):te=1;break;default:case 4:ut>Math.abs(re)?(te=Math.abs(re)/ut,ut=Math.abs(re)):te=1}zt=0}var De=he.Zo;if(b===Wv){switch(he=he.link.computeThickness(),he*=te,De.set(ve),Ct){case 8:De.x=ve.x+Ot/2+vt/2-zt-he/2;break;case 2:De.y=ve.y+re/2+xt/2-zt-he/2;break;case 1:De.x=ve.x+Ot/2-ft/2+zt+he/2;break;default:case 4:De.y=ve.y+re/2-ut/2+zt+he/2}zt+=he}else{var Fn=.5;b===Um&&(Fn=(he.Uo+1)/(he.Gl+1)),De.x=ve.x+Ot*Fn,De.y=ve.y+re*Fn}}}for(Gt.free(ot),Gt.free(rt),Gt.free(tt),Gt.free(lt),ve=a.pe,z=0;zy.Nc?1:a.angley.angle?1:0},Ef.prototype.computeEndSegmentLength=function(a){var y=a.link,x=y.computeEndSegmentLength(this.node,this.port,Qr,y.fromPort===this.port),b=a.Uo;if(0>b)return x;var E=a.Gl;if(1>=E||!y.isOrthogonal)return x;y=a.hv;var z=a.Zo;return(a.Nc===2||a.Nc===8)&&(b=E-1-b),((a=a.Nc===2||a.Nc===4)?y.y=y-1?(z=0,b=x,E+=tt+20,tt=0):z++}},Er.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,b=this.arrangementOrigin.y,E=0,z=0,tt=this.network.vertexes.iterator;tt.next();){var ot=tt.value.node;if(!(ot===null||ot instanceof Ln)&&(Np(ot),this.rh(ot))){var rt=ot.measuredBounds,lt=rt.width;rt=rt.height,ot.moveTo(x,b),ot instanceof Fi&&(ot.rh=!1),x+=Math.max(lt,50)+20,z=Math.max(z,Math.max(rt,50)),E>=a-1?(E=0,x=y,b+=z+20,z=0):E++}}},Er.prototype.rh=function(a){return!!(!a.location.w()||a instanceof Fi&&a.rh)};function nc(a,y,x,b,E,z,tt,ot){for(x=x.iterator;x.next();){var rt=x.value;b&&!rt.isTopLevel||E!==null&&!E(rt)||!rt.canLayout()||(z&&rt instanceof Dn?rt.isLinkLabel||(rt instanceof Fi&&rt.layout===null?nc(a,y,rt.memberParts,!1,E,z,tt,ot):(Np(rt),y.add(rt))):tt&&rt instanceof Ln?y.add(rt):!ot||!rt.Zc()||rt instanceof Dn||(Np(rt),y.add(rt)))}}function Np(a){var y=a.actualBounds;(y.width===0||y.height===0||isNaN(y.width)||isNaN(y.height))&&a.Va()}Er.prototype.ni=function(a,y){var x=this.boundsComputation;return x!==null?(y||(y=new Ye),x(a,this,y)):y?(y.set(a.actualBounds),y):a.actualBounds},Er.prototype.ex=function(a){var y=new un;return a instanceof Be?(nc(this,y,a.nodes,!0,null,!0,!0,!0),nc(this,y,a.links,!0,null,!0,!0,!0),nc(this,y,a.parts,!0,null,!0,!0,!0)):a instanceof Fi?nc(this,y,a.memberParts,!1,null,!0,!0,!0):nc(this,y,a.iterator,!1,null,!0,!0,!0),y},Er.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(js),(isNaN(x.x)||isNaN(x.y))&&x.set(a),a=y.padding,x.x+=a.left,x.y+=a.top),x}return a},Jt.Object.defineProperties(Er.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())}}}),Er.prototype.collectParts=Er.prototype.ex,Er.prototype.getLayoutBounds=Er.prototype.ni,Er.prototype.invalidateLayout=Er.prototype.C,Er.className="Layout";function gr(a){Po(this),this.Sc=a,this.wf=new un,this.ye=new un,this.Es=new ri,this.zs=new ri}gr.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 un,this.ye=new un,this.Es=new ri,this.zs=new ri},gr.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,1y?1:0):1:y!==null?-1:0}Jt.Object.defineProperties(zs.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,b=y.width;y=y.height,this.o.h(b/2,y/2),this.j.h(a,x,b,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=Ye.alloc(),b=y.ni(a,x);y=b.x;var E=b.y,z=b.width;if(b=b.height,isNaN(y)&&(y=0),isNaN(E)&&(E=0),this.j.h(y,E,z,b),Ye.free(x),!(a instanceof Fi)&&(a=a.locationObject.ga(Co),a.w())){this.o.h(a.x-y,a.y-E);return}this.o.h(z/2,b/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 un,y=this.sourceEdges;y.next();)a.add(y.value.fromVertex);return a.iterator}},destinationVertexes:{get:function(){for(var a=new un,y=this.destinationEdges;y.next();)a.add(y.value.toVertex);return a.iterator}},vertexes:{get:function(){for(var a=new un,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 mn,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}}}),zs.prototype.deleteDestinationEdge=zs.prototype.Jl,zs.prototype.addDestinationEdge=zs.prototype.zl,zs.prototype.deleteSourceEdge=zs.prototype.Kl,zs.prototype.addSourceEdge=zs.prototype.Cl,zs.className="LayoutVertex",zs.standardComparer=oy,zs.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 "+(this.qd?this.qd.toString():"null"))),y},Cl.prototype.gm=function(){var a=this.kd;this.kd=this.qd,this.qd=a},Cl.prototype.commit=function(){},Cl.prototype.Ax=function(a){return this.qd===a?this.kd:this.kd===a?this.qd:null},Jt.Object.defineProperties(Cl.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)}}}),Cl.prototype.getOtherVertex=Cl.prototype.Ax,Cl.className="LayoutEdge";function aa(a){Er.call(this),this.isViewportSized=!0,this.yo=this.zo=NaN,this.yg=new Nn(NaN,NaN).freeze(),this.tf=new Nn(10,10).freeze(),this.Jb=Tp,this.Rb=a0,this.nd=Op,this.hd=u1,a&&Object.assign(this,a)}We(aa,Er),aa.prototype.cloneProtected=function(a){Er.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},aa.prototype.qb=function(a){a.classType===aa?a===Op||a===u0||a===ry||a===l0?this.sorting=a:a===a0||a===Zu?this.arrangement=a:a===Tp||a===s0?this.alignment=a:ce("Unknown enum value: "+a):Er.prototype.qb.call(this,a)},aa.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 b=x.value;if(!b.ph()||b.fromNode===null&&b.toNode===null){if(b.Va(),b instanceof Fi)for(b=b.memberParts;b.next();)y.remove(b.value)}else y.remove(b)}var E=y.Fa();if(E.length!==0){switch(this.sorting){case l0:E.reverse();break;case Op:E.sort(this.comparer);break;case u0:E.sort(this.comparer),E.reverse()}var z=this.wrappingColumn;isNaN(z)&&(z=0);var tt=this.wrappingWidth;switch(isNaN(tt)&&a!==null?(y=a.padding,tt=Math.max(a.viewportBounds.width-y.left-y.right,0)):tt=Math.max(this.wrappingWidth,0),0>=z&&0>=tt&&(z=1),y=this.spacing.width,isFinite(y)||(y=0),x=this.spacing.height,isFinite(x)||(x=0),a!==null&&a.Ea("Layout"),b=[],this.alignment){case s0:var ot=y,rt=x,lt=Ye.alloc(),ut=Math.max(this.cellSize.width,1);if(!isFinite(ut))for(var ft=ut=0;ftz-1||0tt)&&(b.push(new Ye(0,Ot,tt+ot,zt)),Kt=0,Ct=xt,Ot+=zt,zt=0),zt=Math.max(zt,De),vt){case Zu:he=-he.width;break;default:he=0}switch(re.moveTo(Ct+he,Ot),vt){case Zu:Ct-=ve;break;default:Ct+=ve}Kt++}b.push(new Ye(0,Ot,tt+ot,zt)),Ye.free(lt);break;case Tp:for(rt=tt,ut=z,ft=y,vt=x,tt=Ye.alloc(),xt=Math.max(this.cellSize.width,1),z=Ot=lt=0,ot=Gt.alloc(),Ct=0;Ct=lt&&(rt-=lt),lt=re=0,ve=Math.max(this.cellSize.height,1),he=z=0,De=!0,Kt=Gt.alloc(),Fn=0;Fnut-1||0rt){for(b.push(new Ye(0,De?te-z:te,rt+ft,he+z+vt)),Vn=0;Vnlt&&(z.width+=z.x-lt,z.x=lt);Ye.free(tt)}for(ot=z=tt=E=0;oty?1:0}Jt.Object.defineProperties(aa.prototype,{wrappingWidth:{get:function(){return this.zo},set:function(a){this.zo!==a&&(0ft)){var Ot=ft+cp(Ct);Ct.pc(Ot,!0),xv(Ct,Ot,ft)}}y.isModified=!0}}finally{y.aa=!0}}}}},Jo.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)},Jo.prototype.rp=function(){for(var a=this.H.model,y=new un,x=a.nodeDataArray,b=0;b=b)return"[]";var E=new di;E.add("["),x&&1b)return;Si(a.Tc,b)}Es(a,"nodeDataArray",Ps,"nodeDataArray",a,y,null,b,null),a.qp(y)}bt.nA=function(a){if(en(a))for(var y=a.length,x=0;xy&&(y=a.length),oi(a,y,x),Es(this,"",es,"",a,null,x,null,y)},bt.ov=function(a,y){y===void 0&&(y=-1),a===this.Tc&&ce("Model.removeArrayItem should not be called on the Model.nodeDataArray"),y===-1&&(y=a.length-1);var x=a[y];Si(a,y),Es(this,"",Ps,"",a,x,null,y,null)},bt.Ro=function(a){if(a===null)return"";var y=this.lj;if(y===""||(y=as(a,y),y===void 0))return"";if(typeof y=="string")return y;ce("getCategoryForNodeData found a non-string category for "+a+": "+y)},bt.jm=function(a,y){if(a!==null){var x=this.lj;if(x!=="")if(this.lb(a)){var b=as(a,x);b===void 0&&(b=""),b!==y&&(wr(a,x,y),Es(this,"nodeCategory",Tr,x,a,b,y))}else wr(a,x,y)}},bt.lm=function(a,y){this.jm(y,this.Ro(a))},bt.Tl=function(){return!1},bt.Wj=function(){return!1},bt.ri=function(){return!1},bt.xs=function(){return!1},bt.Xj=function(){return!1};function hy(){return new ti}function Ip(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 Ip(a,y.constructor);return typeof y}function dy(a){return ku[a]?ku[a]:ue.go!==void 0&&ue.go[a]?ue.go[a]:null}function as(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(b){}return x}function wr(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(b){}}Jt.Object.defineProperties(ti.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===""&&ce("Model.nodeKeyProperty may not be the empty string"),0"+Zl(this,E,!1)}return y},bt.Qv=function(a,y){this.linkKeyProperty===""&&ce("GraphLinksModel.linkKeyProperty must not be an empty string for .toIncrementalData() to succeed.");var x=ti.prototype.Qv.call(this,a,y),b=this,E=new un,z=new un,tt=new un,ot=this.vh;a.changes.each(function(ut){ut.model===b&&(ut.modelChange==="linkDataArray"?ut.change===es?E.add(ut.newValue):ut.change===Ps&&tt.add(ut.oldValue):b.Jc(ut.object)?z.add(ut.object):ut.object!==null&&(ut.object!==null&&ot&&ot.contains(ut.object)?ot.get(ut.object).each(function(ft){b.Jc(ft)&&z.add(ft)}):ut.object instanceof ti||b.lb(ut.object)||k1(b,ut.object).each(function(ft){z.add(ft)})))});var rt=this.il;rt.clear(),E.each(function(ut){rt.add(b.Ac(ut)),y||z.add(ut)});var lt=this.kl;return lt.clear(),tt.each(function(ut){lt.add(b.Ac(ut)),y&&z.add(ut)}),a=b.cloneDeep(z.Fa()),0b.indexOf(a.newValue)&&b.splice(x,0,a.newValue));return}}else if(a.change===Ps){if(x=a.oldParam,a.modelChange==="linkDataArray"){a=a.oldValue,Ae(a)&&typeof x=="number"&&(b=this.Ac(a),y?(this.$f.add(a),this.md[x]!==a&&this.md.splice(x,0,a),b!==void 0&&this.wb.add(b,a)):(this.$f.remove(a),this.md[x]===a&&this.md.splice(x,1),b!==void 0&&this.wb.remove(b)));return}if(a.modelChange==="linkLabelKeys"){b=this.Ef(a.object),Array.isArray(b)&&typeof x=="number"&&(y?0>b.indexOf(a.newValue)&&b.splice(x,0,a.newValue):(x=b.indexOf(a.newValue),0<=x&&b.splice(x,1)));return}}ti.prototype.changeState.call(this,a,y)}},bt=xo.prototype,bt.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),wr(x,this.nodeKeyProperty,a),this.xf(x))}return a}},bt.yx=function(a){return Zl(this,a,!0)},bt.wv=function(a,y){bg(this,a,y,!0)},bt.Bx=function(a){return Zl(this,a,!1)},bt.Bv=function(a,y){bg(this,a,y,!1)};function Zl(a,y,x){if(y!==null&&(a=x?a.lf:a.mf,a!==""&&(a=as(y,a),a!==void 0))){if(oc(a))return a;ce((x?"FromKey":"ToKey")+" value for link data "+y+" is not a number or a string: "+a)}}function bg(a,y,x,b){if(x===null&&(x=void 0),y!==null){var E=b?a.lf:a.mf;if(E!=="")if(x=a.Vl(x),a.Jc(y)){var z=as(y,E);z!==x&&(Uu(a,z,y),wr(y,E,x),a.hc(x)===null&&Vu(a,x,y),Es(a,b?"linkFromKey":"linkToKey",Tr,E,y,z,x),typeof E=="string"&&a.La(y,E))}else wr(y,E,x)}}bt.zx=function(a){return g0(this,a,!0)},bt.xv=function(a,y){Lg(this,a,y,!0)},bt.Cx=function(a){return g0(this,a,!1)},bt.Cv=function(a,y){Lg(this,a,y,!1)};function g0(a,y,x){return y===null||(a=x?a.ej:a.fj,a==="")?"":(y=as(y,a),y===void 0?"":y)}function Lg(a,y,x,b){if(y!==null){var E=b?a.ej:a.fj;if(E!=="")if(a.Jc(y)){var z=as(y,E);z===void 0&&(z=""),z!==x&&(wr(y,E,x),Es(a,b?"linkFromPortId":"linkToPortId",Tr,E,y,z,x),typeof E=="string"&&a.La(y,E))}else wr(y,E,x)}}bt.Ef=function(a){if(a===null)return p0;var y=this.je;return y===""?p0:(a=as(a,y),a===void 0?p0:a)},bt.Ls=function(a,y){if(a!==null){var x=this.je;if(x!=="")if(this.Jc(a)){var b=as(a,x);if(b===void 0&&(b=p0),b!==y){if(Array.isArray(b))for(var E=b.length,z=0;zE||(b.splice(E,1),this.Jc(a)&&(Uu(this,y,a),Es(this,"linkLabelKeys",Ps,x,a,y,null,E,null)))}else b!==void 0&&ce(x+" property is not an Array; cannot removeLabelKeyforLinkData: "+a)}}},bt.Ac=function(a){if(a!==null){var y=this.Jh;if(y!==""&&(y=as(a,y),y!==void 0)){if(oc(y))return y;ce("Key value for link data "+a+" is not a number or a string: "+y)}}},bt.Ks=function(a,y){if(a!==null){var x=this.Jh;if(x!=="")if(this.Jc(a)){var b=as(a,x);b!==y&&this.jh(y)===null&&(wr(a,x,y),b!==void 0&&this.wb.remove(b),this.wb.add(y,a),Es(this,"linkKey",Tr,x,a,b,y),typeof x=="string"&&this.La(a,x))}else wr(a,x,y)}},bt.jh=function(a){return a===null&&ce("GraphLinksModel.findLinkDataForKey:key must not be null"),a!==void 0&&oc(a)?this.wb.I(a):null},bt.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 b=this.cl;if(b!==null&&(x=b(this,a),x!=null&&!this.wb.contains(x))){wr(a,y,x);return}if(typeof x=="string"){for(b=2;this.wb.contains(x+b);)b++;wr(a,y,x+b)}else if(x===void 0||typeof x=="number"){for(x=-this.wb.count-1;this.wb.contains(x);)x--;wr(a,y,x)}}}}},bt.Jc=function(a){return a===null?!1:this.$f.contains(a)},bt.fi=function(a){a!==null&&(kr(a),this.Jc(a)||N1(this,a,!0))};function N1(a,y,x){if(a.linkKeyProperty!==""){var b=a.Ac(y);if(b!==void 0&&a.wb.I(b)===y)return;a.Bs(y),b=a.Ac(y),b===void 0&&ce("GraphLinksModel.makeLinkDataKeyUnique failed on "+y+". Data not added to model."),a.wb.add(b,y)}a.$f.add(y),b=null,x&&(b=a.md.length,a.md.splice(b,0,y)),Es(a,"linkDataArray",es,"linkDataArray",a,null,y,null,b),cy(a,y)}bt.Ey=function(a){if(Array.isArray(a))for(var y=a.length,x=0;xb)return;a.md.splice(b,1)}if(Es(a,"linkDataArray",Ps,"linkDataArray",a,y,null,b,null),x=Zl(a,y,!0),Uu(a,x,y),x=Zl(a,y,!1),Uu(a,x,y),b=a.Ef(y),Array.isArray(b))for(var E=b.length,z=0;z=a.count)a.count===1&&(a=a.first(),a.centerX=0,a.centerY=0);else{var y=new mn;y.addAll(a.iterator),a=new mn;var x=new mn,b=this.sort(y),E,z,tt=this.Jp,ot=this.arrangement,rt=this.nodeDiameterFormula,lt=this.radius;(!isFinite(lt)||0>=lt)&&(lt=NaN);var ut=this.aspectRatio;(!isFinite(ut)||0>=ut)&&(ut=1);var ft=this.startAngle;isFinite(ft)||(ft=0);var vt=this.sweepAngle;if((!isFinite(vt)||360vt)&&(vt=360),y=this.spacing,isFinite(y)||(y=NaN),ot===Tu&&rt===kf?ot=Nu:ot===Tu&&rt!==kf&&(ot=this.arrangement),(this.direction===Xc||this.direction===Mg)&&this.sorting!==Eg){for(rt=0;!(rt>=b.length)&&(a.add(b.M(rt)),!(rt+1>=b.length));rt+=2)x.add(b.M(rt+1));this.direction===Xc?(this.arrangement===Tu&&a.reverse(),b=new mn,b.addAll(a),b.addAll(x)):(this.arrangement===Tu&&x.reverse(),b=new mn,b.addAll(x),b.addAll(a))}rt=b.length;for(var xt=z=E=0;xtvt&&(xt===0||xt===b.length-1)&&(Ot/=2),E+=Ot,z++}if(isNaN(lt)||ot===Tu){if(isNaN(y)&&(y=6),ot!==Nu&&ot!==Tu){for(z=-1/0,tt=0;ttlt?(lt=E,z=lt*ut):tt=xt/(360<=vt?rt:rt-1)}if(this.kw=ot,this.lc=lt,this.Zm=ut,this.lw=ft,this.Wp=vt,this.Ti=y,this.me=z,this.Jp=tt,y=b,b=this.kw,ot=this.lc,lt=this.lw,ut=this.Wp,ft=this.Ti,vt=this.me,rt=this.Jp,this.direction!==Xc&&this.direction!==Mg||b!==Tu)if(this.direction===Xc||this.direction===Mg){switch(tt=0,b){case rc:tt=180*v0(this,ot,vt,lt,rt)/Math.PI;break;case Nu:rt=y=0,tt=a.first(),tt!==null&&(y=ac(tt,Math.PI/2)),tt=x.first(),tt!==null&&(rt=ac(tt,Math.PI/2)),tt=180*v0(this,ot,vt,lt,ft+(y+rt)/2)/Math.PI;break;case Td:tt=ut/y.length}if(this.direction===Xc){switch(b){case rc:Rp(this,a,lt,sc);break;case Nu:Ap(this,a,lt,sc);break;case Td:Dp(this,a,ut/2,lt,sc)}switch(b){case rc:Rp(this,x,lt+tt,Va);break;case Nu:Ap(this,x,lt+tt,Va);break;case Td:Dp(this,x,ut/2,lt+tt,Va)}}else{switch(b){case rc:Rp(this,x,lt,sc);break;case Nu:Ap(this,x,lt,sc);break;case Td:Dp(this,x,ut/2,lt,sc)}switch(b){case rc:Rp(this,a,lt+tt,Va);break;case Nu:Ap(this,a,lt+tt,Va);break;case Td:Dp(this,a,ut/2,lt+tt,Va)}}}else switch(b){case rc:Rp(this,y,lt,this.direction);break;case Nu:Ap(this,y,lt,this.direction);break;case Td:Dp(this,y,ut,lt,this.direction);break;case Tu:F1(this,y,ut,lt,this.direction)}else F1(this,y,ut,lt-ut/2,Va)}this.updateParts(),this.network=null,this.isValidLayout=!0};function Dp(a,y,x,b,E){var z=a.Wp,tt=a.lc;a=a.me,b=b*Math.PI/180,x=x*Math.PI/180;for(var ot=y.length,rt=0;rtx){for(z=b+(E===Va?z:-z);0>z;)z+=360;z%=360,180=ut.length-1));ft++)D1(a,rt,lt,ut,ft,E,z)||A1(a,rt,lt,ut,ft,E,z),rt=z.x,lt=z.y;if(Gt.free(z),a.mj++,!(23Math.abs(xt)?Math.abs(rt-z)<(ut[0].width+ut[ut.length-1].width)/2&&(tt=0):tt=0Math.abs(vt)?0:vt,rt=Math.abs(z)>Math.abs(ft)?0ft:0a.mj?a.lc-tt/(2*Math.PI):5>ut.length&&10=ft.length-1));vt++)D1(a,rt,lt,ft,vt,E,ut)||A1(a,rt,lt,ft,vt,E,ut),rt=ut.x,lt=ut.y;if(Gt.free(ut),a.mj++,!(23a.mj?a.lc-z/(2*Math.PI):a.lc-(0ot){if(z=y-a,z<-ot)return tt.x=z,tt.y=lt,!1;ut=!0}}else if(z=y-a,z<-ot){if(z=y+a,z>ot)return tt.x=z,tt.y=lt,!1;ut=!0}return lt=Math.sqrt(1-Math.min(1,z*z/(ot*ot)))*rt,0>x!==ut&&(lt=-lt),Math.abs(x-lt)>(b[E].height+b[E+1].height)/2?(tt.x=z,tt.y=lt,!1):(tt.x=z,tt.y=lt,!0)}function A1(a,y,x,b,E,z,tt){var ot=a.lc,rt=a.me,lt=0;if(a=(b[E].height+b[E+1].height)/2+a.Ti,b=!1,0<=y!=(z===Va)){if(z=x-a,z<-rt){if(z=x+a,z>rt){tt.x=lt,tt.y=z;return}b=!0}}else if(z=x+a,z>rt){if(z=x-a,z<-rt){tt.x=lt,tt.y=z;return}b=!0}lt=Math.sqrt(1-Math.min(1,z*z/(rt*rt)))*ot,0>y!==b&&(lt=-lt),tt.x=lt,tt.y=z}jr.prototype.commitLayout=function(){this.commitNodes(),this.isRouting&&this.commitLinks()},jr.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 Gt(0,0):(x.x=this.arrangementOrigin.x+this.lc,x.y=this.arrangementOrigin.y+this.me);for(var b=this.network.vertexes.iterator;b.next();){var E=b.value;E.x+=x.x,E.y+=x.y,E.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))},jr.prototype.commitLinks=function(){for(var a=this.network.edges.iterator;a.next();)a.value.commit()};function fy(a,y,x,b,E){var z=a.ty;if(.001>Math.abs(a.Zm-1))return b!==void 0&&E!==void 0?E*y:2*Math.PI*y;a=y>x?Math.sqrt(y*y-x*x)/y:Math.sqrt(x*x-y*y)/x;for(var tt=0,ot=b!==void 0&&E!==void 0?E/(z+1):Math.PI/(2*(z+1)),rt=0,lt=0;lt<=z;lt++){b!==void 0&&E!==void 0?rt=b+lt*E/z:rt=lt*Math.PI/(2*z);var ut=Math.sin(rt);tt+=Math.sqrt(1-a*a*ut*ut)*ot}return b!==void 0&&E!==void 0?(y>x?y:x)*tt:4*(y>x?y:x)*tt}function m0(a,y,x,b,E){return y/(b!==void 0&&E!==void 0?fy(a,1,x,b,E):fy(a,1,x))}function v0(a,y,x,b,E){if(.001>Math.abs(a.Zm-1))return E/y;var z=y>x?Math.sqrt(y*y-x*x)/y:Math.sqrt(x*x-y*y)/x,tt=0;a=2*Math.PI/(700*a.network.vertexes.count),y>x&&(b+=Math.PI/2);for(var ot=0;;ot++){var rt=Math.sin(b+ot*a);if(tt+=(y>x?y:x)*Math.sqrt(1-z*z*rt*rt)*a,tt>=E)return ot*a}}jr.prototype.sort=function(a){switch(this.sorting){case y0:break;case S0:a.reverse();break;case x0:a.sort(this.comparer);break;case P0:a.sort(this.comparer),a.reverse();break;case Eg:return this.ak(Ix(a));default:ce("Invalid sorting type.")}return a};function Ix(a){for(var y=[],x=0;xE&&(E=ot,z=tt)}else for(tt=0;ttE&&(E=ot,z=tt);for(x.add(a.M(z)),y[z]=-1,z=a.M(z),tt=z.sourceEdges;tt.next();)E=a.indexOf(tt.value.fromVertex),0>E||0<=y[E]&&y[E]++;for(z=z.destinationEdges;z.next();)E=a.indexOf(z.value.toVertex),0>E||0<=y[E]&&y[E]++}return x}jr.prototype.ak=function(a){for(var y=[],x=0;xy[x].indexOf(E)&&y[x].push(E);for(b=b.sourceEdges;b.next();)E=a.indexOf(b.value.fromVertex),E!==x&&0>y[x].indexOf(E)&&y[x].push(E)}for(z=[],x=0;xy[x[Ct]].indexOf(x[Ct===x.length-1?0:Ct+1])&&xt.push(Ct===x.length-1?0:Ct+1);if(xt.length===0)for(Ct=0;Ctx.indexOf(De)||vex.indexOf(De)||ve=Ot?ve+1:ve)),zt+=ve=Ot&&ve++,re>=Ot&&re++,ve>re&&(he=re,re=ve,ve=he),re-ve<(x.length+2)/2==(vext||xt===ut||(Ct=xt>ut?xt-ut:ut-xt,ft+=xttt-Ct?1:-1);x.splice(0>ft?ut:ut+1,0,rt),b.splice(ot,1),ot--}else z=!1;if(z)break;x.push(b[0]),b.splice(0,1)}for(y=0;y=a?this.ul=a:this.ul=360,this.C())}},arrangement:{get:function(){return this.Rb},set:function(a){this.Rb===a||a!==Tu&&a!==Nu&&a!==rc&&a!==Td||(this.Rb=a,this.C())}},direction:{get:function(){return this.K},set:function(a){this.K===a||a!==Va&&a!==sc&&a!==Xc&&a!==Mg||(this.K=a,this.C())}},sorting:{get:function(){return this.nd},set:function(a){this.nd===a||a!==y0&&a!==S0&&a!==x0&&!P0&&a!==Eg||(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!==w0&&a!==kf||(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 Nu=new Qe(jr,"ConstantSpacing",0),rc=new Qe(jr,"ConstantDistance",1),Td=new Qe(jr,"ConstantAngle",2),Tu=new Qe(jr,"Packed",3),Va=new Qe(jr,"Clockwise",4),sc=new Qe(jr,"Counterclockwise",5),Xc=new Qe(jr,"BidirectionalLeft",6),Mg=new Qe(jr,"BidirectionalRight",7),y0=new Qe(jr,"Forwards",8),S0=new Qe(jr,"Reverse",9),x0=new Qe(jr,"Ascending",10),P0=new Qe(jr,"Descending",11),Eg=new Qe(jr,"Optimized",12),w0=new Qe(jr,"Pythagorean",13),kf=new Qe(jr,"Circular",14);jr.className="CircularLayout",jr.ConstantSpacing=Nu,jr.ConstantDistance=rc,jr.ConstantAngle=Td,jr.Packed=Tu,jr.Clockwise=Va,jr.Counterclockwise=sc,jr.BidirectionalLeft=Xc,jr.BidirectionalRight=Mg,jr.Forwards=y0,jr.Reverse=S0,jr.Ascending=x0,jr.Descending=P0,jr.Optimized=Eg,jr.Pythagorean=w0,jr.Circular=kf;function zp(){this.Pl=-1/0,this.tm=this.mk=null}zp.prototype.compare=function(a,y){if(0this.Pl||Math.abs(a)a&&0ot?(E=vt.x+vt.width/2,z=vt.y+vt.height/2,lt[0]=new Gt(vt.x+vt.width+b.width,vt.y),lt[1]=new Gt(vt.x,vt.y+vt.height+b.height),ot=2):(rt=z1(lt,ot,E,z,vt.width,vt.height,b),ft=lt[rt],xt=new Gt(ft.x+vt.width+b.width,ft.y),vt=new Gt(ft.x,ft.y+vt.height+b.height),rt+1this.network.vertexes.count)return!1;for(var a=0,y=0,x=this.network.vertexes.first().bounds,b=this.network.vertexes.iterator;b.next();){if(b.value.bounds.Yc(x)&&(a++,2a.network.vertexes.count)return!1;for(a.ah=a.network.vertexes.Fa(),a=a.ah,a.sort(function(x,b){return x===null||b===null||x===b?0:b.Vd-x.Vd}),y=a.length-1;0<=y&&1>=a[y].Vd;)y--;return 1=tt))){for(var lt=ot=0,ut=rt.count-tt;utxt&&(xt=1),ot=Ce.sqrt((ot+xt+lt*lt*4/(tt*tt))/xt),tt=(ot-1)*ut/2,ot=(ot-1)*ft/2,E.bounds=new Ye(z-vt.x-tt,rt-vt.y-ot,ut+2*tt,ft+2*ot),E.focus=new Gt(vt.x+tt,vt.y+ot)}}return a.network=b,x}function Ax(a,y){for(var x=a.network.vertexes.iterator;x.next();){var b=x.value;if(b.network=y,b.We!==null){var E=b.We.M(b.sv);b.Vd=E.Rs;var z=E.Sv,tt=E.Tv;b.bounds=new Ye(b.centerX-z,b.centerY-tt,E.Ss,E.Qs),b.focus=new Gt(z,tt),b.sv--}}for(x=a.network.edges.iterator;x.next();)x.value.network=y;a.network=y}function Rx(a,y){var x=y.Hj;if(x!==null&&x.count!==0){var b=y.centerX,E=y.centerY,z=y.width,tt=y.height;y.We!==null&&0=ft.Vd?rt++:(ot=!0,lt++,tt+=Math.atan2(y.centerY-ft.centerY,y.centerX-ft.centerX))}if(rt!==0){for(0>1)+lt)*(ot%2===0?1:-1),rt.centerX=b+ut*Math.cos(ft),rt.centerY=E+ut*Math.sin(ft),ot++}}}}function z1(a,y,x,b,E,z,tt){var ot=9e19,rt=-1,lt=0;t:for(;ltut.y&&a[vt].x-ut.xut.x&&a[vt].y-ut.yy+z?(x=b+E-tt,a=a-y-z,Ce.sqrt(x*x+a*a)):a+xtt+ot?a>y+z?(x=b-tt-ot,a=a-y-z,Ce.sqrt(x*x+a*a)):a+xy+z?a-(y+z):a+x=y.length)return!1;var x=y[0];x.forceX=0,x.forceY=0;for(var b=x.centerX,E=b,z=x=x.centerY,tt=1;ttz-x)?y.sort(function(Ot,Kt){return Ot===null||Kt===null||Ot===Kt?0:Ot.centerX-Kt.centerX}):y.sort(function(Ot,Kt){return Ot===null||Kt===null||Ot===Kt?0:Ot.centerY-Kt.centerY}),x=a.Zf;var lt=b=ot=0;for(z=0;zx||lt-rt>x){if(E)break}else if(ut-xt>x||xt-ut>x){if(!E)break}else{var Ct=j1(tt,vt);1>Ct?(b=a.randomNumberGenerator,b===null&&(a.randomNumberGenerator=b=new b0),Ct=b.random(),ot=b.random(),rt>lt?(b=Math.abs(vt.bounds.right-tt.bounds.x),b=(1+b)*Ct):rtxt?(lt=Math.abs(vt.bounds.bottom-tt.bounds.y),lt=(1+lt)*ot):rtft?(ft=a.randomNumberGenerator,ft===null&&(a.randomNumberGenerator=ft=new b0),ot=ft.random(),ft=ft.random(),b=(b>rt?1:-1)*(1+(z.width>x.width?z.width:x.width))*ot,lt=(tt>ut?1:-1)*(1+(z.height>x.height?z.height:x.height))*ft):(ot=ot.stiffness*(ft-ot.length),b=(rt-b)/ft*ot,lt=(ut-tt)/ft*ot),x.forceX+=b,x.forceY+=lt,z.forceX-=b,z.forceY-=lt;for(E=b=0;Ea.epsilonDistance*a.epsilonDistance}pa.prototype.moveVertex=function(a){var y=a.forceX,x=a.forceY,b=this.moveLimit;return y<-b?y=-b:y>b&&(y=b),x<-b?x=-b:x>b&&(x=b),a.centerX+=y,a.centerY+=x,y*y+x*x},pa.prototype.moveFixedVertex=function(){},pa.prototype.commitLayout=function(){this.yv(),this.commitNodes(),this.isRouting&&this.commitLinks()},pa.prototype.yv=function(){if(this.setsPortSpots)for(var a=this.network.edges.iterator;a.next();){var y=a.value.link;y!==null&&(y.fromSpot=Wo,y.toSpot=Wo)}},pa.prototype.commitNodes=function(){var a=0,y=0;if(this.arrangesToOrigin){var x=Ye.alloc();this.computeBounds(this.network,x),y=this.arrangementOrigin,a=y.x-x.x,y=y.y-x.y,Ye.free(x)}x=Ye.alloc();for(var b=this.network.vertexes.iterator;b.next();){var E=b.value;(a!==0||y!==0)&&(x.assign(E.bounds),x.x+=a,x.y+=y,E.bounds=x),E.commit()}Ye.free(x)},pa.prototype.commitLinks=function(){for(var a=this.network.edges.iterator;a.next();)a.value.commit()},pa.prototype.springStiffness=function(a){return a=a.stiffness,isNaN(a)?this.Hk:a},pa.prototype.springLength=function(a){return a=a.length,isNaN(a)?this.Gk:a},pa.prototype.electricalCharge=function(a){return a=a.charge,isNaN(a)?this.Ek:a},pa.prototype.electricalFieldX=function(){return 0},pa.prototype.electricalFieldY=function(){return 0},pa.prototype.gravitationalMass=function(a){return a=a.mass,isNaN(a)?this.Fk:a},pa.prototype.gravitationalFieldX=function(){return 0},pa.prototype.gravitationalFieldY=function(){return 0},pa.prototype.isFixed=function(a){return a.isFixed},Jt.Object.defineProperties(pa.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&&0Ot&&0Ot&&0a[this.Md]&&(this.Iq=a[x]-1,this.Md=x),a[x]tt)for(var ut=tt+1;utrt;ut--)ft=b[ut],ft.near===lt&&ft.Dj===lt.Dj||ot++;var vt;if(0<=x)for(rt=b[tt].sourceEdgesArrayAccess,lt=0;ltOt||ft===Ot&&xt>Ct)&&ot++,Ktft||Ot===ft&&Ct>xt)&&ot++}}}if(0>=x){for(rt=b[tt].destinationEdgesArrayAccess,lt=0;ltOt||ft===Ot&&ut>Kt)&&ot++,Ctft||Ot===ft&&Kt>ut)&&ot++)}for(z[tt*E+tt]=ot,rt=tt+1;rt=x){for(ot=b[tt].destinationEdgesArrayAccess,re=b[rt].destinationEdgesArrayAccess,lt=0;lt=x&&(rt=ot.sourceEdgesArrayAccess);var lt=null;0<=x&&(lt=ot.destinationEdgesArrayAccess);var ut=0,ft=0,vt=ot.near;if(vt!==null&&vt.layer===ot.layer&&(ut+=vt.column-1,ft++),rt!==null)for(vt=0;vt=x&&(rt=ot.sourceEdgesArrayAccess);var lt=null;0<=x&&(lt=ot.destinationEdgesArrayAccess);var ut=0,ft=[],vt=ot.near;if(vt!==null&&vt.layer===ot.layer&&(ft[ut]=vt.column-1,ut++),ot=void 0,rt!==null)for(vt=0;vt>1,z[tt]=ut&1?ft[lt]:ft[lt-1]+ft[lt]>>1)}return uc(a,y,b),z}function $p(a,y,x,b,E,z){if(y.component===b){if(y.component=x,E)for(var tt=y.destinationEdges;tt.next();){var ot=tt.value,rt=ot.toVertex,lt=y.layer-rt.layer;ot=a.linkMinLength(ot),lt===ot&&$p(a,rt,x,b,E,z)}if(z)for(tt=y.sourceEdges;tt.next();)ot=tt.value,rt=ot.fromVertex,lt=rt.layer-y.layer,ot=a.linkMinLength(ot),lt===ot&&$p(a,rt,x,b,E,z)}}function my(a,y,x,b,E,z){if(y.component===b){if(y.component=x,E)for(var tt=y.destinationEdges;tt.next();)my(a,tt.value.toVertex,x,b,E,z);if(z)for(y=y.sourceEdges;y.next();)my(a,y.value.fromVertex,x,b,E,z)}}Qo.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,b=[];b.length=x+1;for(var E=a.vertexes.iterator;E.next();)E.value.valid=!0;for(;jx(a)!==null;){for(E=K1(a);E!==null;)b[x]=E,x--,E.valid=!1,E=K1(a);for(E=Z1(a);E!==null;)b[y]=E,y++,E.valid=!1,E=Z1(a);E=null;for(var z=0,tt=this.network.vertexes.iterator;tt.next();){var ot=tt.value;if(ot.valid){for(var rt=0,lt=ot.destinationEdges;lt.next();)lt.value.toVertex.valid&&rt++;lt=0;for(var ut=ot.sourceEdges;ut.next();)ut.value.fromVertex.valid&<++;(E===null||zy.toVertex.index&&(a.gm(y),y.rev=!0);break;case N0:for(b=this.network.vertexes.iterator;b.next();)a=b.value,a.Ll=-1,a.finish=-1;for(a=this.network.edges.iterator;a.next();)a.value.forest=!1;for(this.Kn=0,b.reset();b.next();)y=b.value,y.sourceEdges.count===0&&vy(this,y);for(b.reset();b.next();)y=b.value,y.Ll===-1&&vy(this,y);for(a.reset();a.next();)b=a.value,b.forest||(y=b.fromVertex,x=y.finish,E=b.toVertex,z=E.finish,E.Llb){if(0>b)for(y.reset();y.next();)y.value.layer-=b;for(b=[],y.reset();y.next();)x=y.value,E=b[x.layer],E===void 0?b[x.layer]=[x]:E.push(x);for(x=y=0;xtt&&$p(a,ot,0,-1,!0,!1)}for($p(a,y,1,-1,!0,!0);y.component!==0;){for(z=0,b=1/0,ot=0,rt=null,tt=a.network.vertexes.iterator;tt.next();){var lt=tt.value;if(lt.component===1){var ut=0,ft=!1,vt=lt.sourceEdgesArrayAccess;E=vt.length;for(var xt=0;xtz)&&!ut&&(ot=tt,z=lt)}if(0>b){for(x.reset();x.next();)b=x.value,b.component===1&&(b.layer-=E);y.component=0}else ot.component=0}}}function _1(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}Qo.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 O0: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&&J1(this,x);break;case wy: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 J1(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 b=0;bz.portFromColOffset&&(x=!0,y[b]=z,y[b+1]=E)}}for(x=0;xz.portToColOffset&&(b=!0,y[x]=z,y[x+1]=E)}for(x=0;x=tt;b--)z=mu(this,b,-1)||z;for(E=this.countCrossings(),E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=x;b>=tt;b--)z=mu(this,b,1)||z;for(E=this.countCrossings(),E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=tt;b<=x;b++)z=mu(this,b,1)||z;for(E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=tt;b<=x;b++)z=mu(this,b,-1)||z;for(E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=x;b>=tt;b--)z=mu(this,b,0)||z;for(E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=tt;b<=x;b++)z=mu(this,b,0)||z;E>=a?su(this,y):(a=E,y=rl(this))}break;default:case F0:for(x=this.Ia,tt=0,ot=a+1;(b=this.countCrossings())=tt;b--)z=mu(this,b,-1)||z;for(E=this.countCrossings(),E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=x;b>=tt;b--)z=mu(this,b,1)||z;for(E=this.countCrossings(),E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=tt;b<=x;b++)z=mu(this,b,1)||z;for(E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=tt;b<=x;b++)z=mu(this,b,-1)||z;for(E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=x;b>=tt;b--)z=mu(this,b,0)||z;for(E>=a?su(this,y):(a=E,y=rl(this)),z=!0;z;)for(z=!1,b=tt;b<=x;b++)z=mu(this,b,0)||z;E>=a?su(this,y):(a=E,y=rl(this))}}su(this,y)};function M0(a,y,x){var b=lc(a,y),E=a.tc[y],z=W1(a,y,x),tt=py(a,y,x);for(x=0;xz+1&&(vt+=4*(te-z),xt+=4*(te-(z+1)))}for(he=b[z].destinationEdges.iterator,he.reset();he.next();)if(te=he.value,re=te.toVertex,te.valid&&re.layer===y){for(te=0;b[te]!==re;)te++;te===z+1&&(xt+=1)}for(he=b[z+1].sourceEdges.iterator,he.reset();he.next();)if(te=he.value,re=te.fromVertex,te.valid&&re.layer===y){for(te=0;b[te]!==re;)te++;tez+1&&(vt+=4*(te-(z+1)),xt+=4*(te-z))}for(he=b[z+1].destinationEdges.iterator,he.reset();he.next();)if(te=he.value,re=te.toVertex,te.valid&&re.layer===y){for(te=0;b[te]!==re;)te++;te===z&&(vt+=1)}te=re=0,he=tt[b[z].index];var ve=ot[b[z].index],De=tt[b[z+1].index],Fn=ot[b[z+1].index];he!==-1&&(re+=Math.abs(he-Ct),te+=Math.abs(he-zt)),ve!==-1&&(re+=Math.abs(ve-Ct),te+=Math.abs(ve-zt)),De!==-1&&(re+=Math.abs(De-Ot),te+=Math.abs(De-Kt)),Fn!==-1&&(re+=Math.abs(Fn-Ot),te+=Math.abs(Fn-Kt)),(xt>1)+8*b;this.Ra*=8}if(this.bg&2)for(x=!0;x;){for(x=!1,y=this.Md+1;y<=this.Ia;y++)x=Ng(this,y,1)||x;for(y=this.Md-1;0<=y;y--)x=Ng(this,y,-1)||x;x=Ng(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&&(q1(this,-1),q1(this,1)),this.bg&2)for(x=!0;x;){for(x=!1,x=Ng(this,this.Md,0)||x,y=this.Md+1;y<=this.Ia;y++)x=Ng(this,y,0)||x;for(y=this.Md-1;0<=y;y--)x=Ng(this,y,0)||x}}else Wx(this)};function Ng(a,y,x){for(var b=!1;Hx(a,y,x);)b=!0;return b}function Hx(a,y,x){var b,E=lc(a,y),z=a.tc[y],tt=py(a,y,-1);if(0x)for(b=0;bb-1||ut-E[b-1].column-1>ft+a.nodeMinColumnSpace(E[b-1],!1)?xt=ut-1:xt=ut,ft=b+1>=z||E[b+1].column-ut-1>vt+a.nodeMinColumnSpace(E[b+1],!0)?ut+1:ut;var Ct=vt=0,Ot=0;if(0>=x)for(var Kt=E[b].sourceEdges.iterator;Kt.next();){var zt=Kt.value,te=zt.fromVertex;if(zt.valid&&te.layer!==y){var re=gy(zt),he=zt.portFromColOffset;zt=zt.portToColOffset,te=te.column,vt+=(Math.abs(ut+zt-(te+he))+1)*re,Ct+=(Math.abs(xt+zt-(te+he))+1)*re,Ot+=(Math.abs(ft+zt-(te+he))+1)*re}}if(0<=x)for(Kt=E[b].destinationEdges.iterator;Kt.next();)zt=Kt.value,te=zt.toVertex,zt.valid&&te.layer!==y&&(re=gy(zt),he=zt.portFromColOffset,zt=zt.portToColOffset,te=te.column,vt+=(Math.abs(ut+he-(te+zt))+1)*re,Ct+=(Math.abs(xt+he-(te+zt))+1)*re,Ot+=(Math.abs(ft+he-(te+zt))+1)*re);zt=he=re=0,Kt=tt[E[b].index],te=ot[E[b].index],Kt!==-1&&(re+=Math.abs(Kt-ut),he+=Math.abs(Kt-xt),zt+=Math.abs(Kt-ft)),te!==-1&&(re+=Math.abs(te-ut),he+=Math.abs(te-xt),zt+=Math.abs(te-ft)),Ct=tt[x]?ut=rt:lt<=tt[x]&&(ut=lt));ut!==ot&&(z=!0,b[x].column=ut)}uc(a,y,b),a.normalize()}function Gx(a,y){for(var x=!0,b=a.network.vertexes.iterator;b.next();){var E=b.value,z=a.nodeMinColumnSpace(E,!0),tt=a.nodeMinColumnSpace(E,!1);if(E.column-z<=y&&E.column+tt>=y){x=!1;break}}if(a=!1,x)for(b.reset();b.next();)x=b.value,x.column>y&&(--x.column,a=!0);return a}function $x(a,y){var x=y+1,b,E=[],z=[];for(b=0;b<=a.Ia;b++)E[b]=!1,z[b]=!1;for(var tt=a.network.vertexes.iterator;tt.next();){b=tt.value;var ot=b.column-a.nodeMinColumnSpace(b,!0),rt=b.column+a.nodeMinColumnSpace(b,!1);ot<=y&&rt>=y&&(E[b.layer]=!0),ot<=x&&rt>=x&&(z[b.layer]=!0)}for(ot=!0,x=!1,b=0;b<=a.Ia;b++)ot=ot&&!(E[b]&&z[b]);if(ot)for(tt.reset();tt.next();)a=tt.value,a.column>y&&(--a.column,x=!0);return x}function q1(a,y){for(var x=0;x<=a.Ra;x++)for(;Gx(a,x););for(a.normalize(),x=0;xz?su(a,E):tty)for(x=a.Ra;0<=x;x--)for(E=rl(a),z=L0(a),b=z+1;zz?su(a,E):ttx)for(b.reset();b.next();)E=b.value,E.column+a.nodeMinColumnSpace(E,!1)>=y&&(E.component=a.le);for(a.le++,b.reset();b.next();)y=b.value,y.component===-1&&(my(a,y,a.le,-1,!0,!0),a.le++);var z;for(y=[],z=0;zx)for(tt=a.Ra;0x)for(b.reset();b.next();)x=b.value,E[x.component]&&(x.column+=1)}function Wx(a){for(var y=Zn(),x=a.fl.length,b=0;b<=x;b++)y[b]=[];for(b=a.network.vertexes.iterator;b.next();){var E=b.value;y[x-E.layer][E.index]=E}x=new un,Kx(y,x);var z=null,tt=null,ot=null,rt=null,lt=(a.ve&1)!==0,ut=(a.ve&2)!==0,ft=(a.ve&4)!==0,vt=(a.ve&8)!==0;for(lt&&(a.verticalAlignment(y,x,!0),z=E0(a,y,!0,!1)),y.reverse(),ft&&(a.verticalAlignment(y,x,!1),ot=E0(a,y,!1,!1)),b=Ni(y),E=b.next();!E.done;E=b.next())E.value.reverse();vt&&(a.verticalAlignment(y,x,!1),rt=E0(a,y,!1,!0)),y.reverse(),ut&&(a.verticalAlignment(y,x,!0),tt=E0(a,y,!0,!0)),hi(y),a.u(z,tt,ot,rt),a.network.vertexes.each(function(xt){var Ct=Zn();lt&&Ct.push(z.get(xt)),ut&&Ct.push(tt.get(xt)),ft&&Ct.push(ot.get(xt)),vt&&Ct.push(rt.get(xt)),Ct.sort(function(Kt,zt){return Kt-zt});var Ot=Ct.length;Ot=(Ct[Math.floor((Ot-1)/2)]+Ct[Math.ceil((Ot-1)/2)])/2,hi(Ct),xt.zc=Ot})}function Kx(a,y){for(var x=a.length,b=1;but)&&y.add(ft);z++}E=ut}}}Qo.prototype.verticalAlignment=function(a,y,x){Zx(a),a=Ni(a);for(var b=a.next();!b.done;b=a.next()){var E=-1;b=Ni(b.value);for(var z=b.next();!z.done;z=b.next()){z=z.value;var tt=x?My(z):Yx(z),ot=tt.length;if(0=y[x].length)&&(tt=y[x][0],tt.sd===tt)){tt.sd.shift===1/0&&(tt.sd.shift=0),tt=x,ot=0;do{for(z=y[tt][ot];z.align!==z.root;)z=z.align,tt++,0a&&ce("Could not determine previous vertex in layer"),y[x][a-1]}Qo.prototype.u=function(a){for(var y=[],x=0;xtt;tt++)if(y[tt]){var ot=Vx(this,y[tt],b,E,tt);ottt;z={delta:z.delta},tt++)y[tt]&&(z.delta=tt===0||tt===2?b[x]-b[tt]:E[x]-E[tt],z.delta!==0&&y[tt].each(function(rt){return function(lt){lt.value+=rt.delta}}(z)));hi(b),hi(E)};function Vx(a,y,x,b,E){if(!y||y.count===0)return x[E]=0,b[E]=0,1/0;var z=1/0,tt=-1/0;return y.each(function(ot){var rt=ot.key;ot=ot.value,rt=a.K===90||a.K===270?rt.width:rt.height,ottt&&(tt=ot+rt)}),x[E]=z,b[E]=tt,tt-z}Qo.prototype.commitLayout=function(){if(this.setsPortSpots)for(var a=k0(this,!0),y=k0(this,!1),x=this.network.edges.iterator;x.next();){var b=x.value.link;b!==null&&(b.fromSpot=a,b.toSpot=y)}this.commitNodes(),this.Gu(),this.isRouting&&this.commitLinks()};function k0(a,y){return a.K===270?y?is:Bs:a.K===90?y?Bs:is:a.K===180?y?vs:Hs:y?Hs:vs}Qo.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 b=0;b<=this.Ia;b++){var E=x;0>=this.he[b]+this.Ld[b]&&(E=0),0=ft.bounds.bottom?(ft=ft.bounds.y+ft.bounds.height,y.m(Ot++,he,ft+De),y.m(Ot++,he,ft),y.m(Ot++,he,ft-re)):(y.m(Ot++,he,ve+De),y.m(Ot++,he,ve),y.m(Ot++,he,ve-re)):this.K===270?ve<=ft.bounds.y?(ft=ft.bounds.y,y.m(Ot++,he,ft-re),y.m(Ot++,he,ft),y.m(Ot++,he,ft+De)):(y.m(Ot++,he,ve-re),y.m(Ot++,he,ve),y.m(Ot++,he,ve+De)):this.K===0&&(he>=ft.bounds.right?(ft=ft.bounds.x+ft.bounds.width,y.m(Ot++,ft+De,ve),y.m(Ot++,ft,ve),y.m(Ot++,ft-re,ve)):(y.m(Ot++,he+De,ve),y.m(Ot++,he,ve),y.m(Ot++,he-re,ve)));else{y.m(Ot++,zt,te);var Fn=0;this.K===180||this.K===0?((this.K===180?he>=ft.bounds.right:he<=ft.bounds.x)&&(Fn=(this.K===0?-re:De)/2),y.m(Ot++,zt+Fn,ve)):((this.K===270?ve>=ft.bounds.bottom:ve<=ft.bounds.y)&&(Fn=(this.K===90?-re:De)/2),y.m(Ot++,he,te+Fn)),y.m(Ot++,he,ve)}}else re=Math.max(10,this.he[Kt.layer]),De=Math.max(10,this.Ld[Kt.layer]),vt?this.K===180?(y.m(Ot++,he-re-Ct,ve),y.m(Ot++,Math.min(he-re+Ct/2,he),ve),y.m(Ot++,he,ve),y.m(Ot++,he,ve),y.m(Ot++,Math.max(he+De-Ct/2,he),ve),y.m(Ot++,he+De+Ct,ve)):this.K===90?(y.m(Ot++,he,ve+De+Ct),y.m(Ot++,he,Math.max(ve+De-Ct/2,ve)),y.m(Ot++,he,ve),y.m(Ot++,he,ve),y.m(Ot++,he,Math.min(ve-re+Ct/2,ve)),y.m(Ot++,he,ve-re-Ct)):this.K===270?(y.m(Ot++,he,ve-re-Ct),y.m(Ot++,he,Math.min(ve-re+Ct/2,ve)),y.m(Ot++,he,ve),y.m(Ot++,he,ve),y.m(Ot++,he,Math.max(ve+De-Ct/2,ve)),y.m(Ot++,he,ve+De+Ct)):(y.m(Ot++,he+De+Ct,ve),y.m(Ot++,Math.max(he+De-Ct/2,he),ve),y.m(Ot++,he,ve),y.m(Ot++,he,ve),y.m(Ot++,Math.min(he-re+Ct/2,he),ve),y.m(Ot++,he-re-Ct,ve)):y.m(Ot++,he,ve)}ft=Kt}(ot===null||lt!==Qr||xt)&&(zt=y.i(Ot-1).x,te=y.i(Ot-1).y,he=y.i(Ot).x,ve=y.i(Ot).y,xt?(Ct=this.Ld[ut.layer],this.K===180||this.K===0?(xt=te,xt>=ut.bounds.y&&xt<=ut.bounds.bottom&&(this.K===180?he>=ut.bounds.x:he<=ut.bounds.right)&&(ft=ut.centerX+(this.K===180?-Ct:Ct),xt=ut.bounds.x&&xt<=ut.bounds.right&&(this.K===270?ve>=ut.bounds.y:ve<=ut.bounds.bottom)&&(ft=ut.centerY+(this.K===270?-Ct:Ct),xt=ut.bounds.x?(ft=ut.bounds.x+ut.bounds.width,y.L(Ot-2,ft,te),y.L(Ot-1,ft+De,te)):this.K===90&&ve<=ut.bounds.bottom?(ft=ut.bounds.y,y.L(Ot-2,zt,ft),y.L(Ot-1,zt,ft-re)):this.K===270&&ve>=ut.bounds.y?(ft=ut.bounds.y+ut.bounds.height,y.L(Ot-2,zt,ft),y.L(Ot-1,zt,ft+De)):this.K===0&&he<=ut.bounds.right&&(ft=ut.bounds.x,y.L(Ot-2,ft,te),y.L(Ot-1,ft-re,te))):(re=Math.max(10,this.he[ut.layer]),De=Math.max(10,this.Ld[ut.layer]),xt=0,this.K===180||this.K===0?((this.K===180?he<=ut.bounds.x:he>=ut.bounds.right)&&(xt=(this.K===0?De:-re)/2),y.m(Ot++,he+xt,te)):((this.K===270?ve<=ut.bounds.y:ve>=ut.bounds.bottom)&&(xt=(this.K===90?De:-re)/2),y.m(Ot++,zt,ve+xt)),y.m(Ot++,he,ve)))}else{for(;ut!==null&&ut!==ft;){for(re=Kt=null,ut=ut.destinationEdges.iterator;ut.next()&&(zt=ut.value,zt.link!==x.link||(Kt=zt.toVertex,re=zt.fromVertex,re.node!==null&&(re=null),Kt.node!==null)););if(Kt===null)break;Kt!==ft&&(zt=y.i(Ot-1).x,te=y.i(Ot-1).y,he=Kt.centerX,ve=Kt.centerY,xt?this.K===180||this.K===0?(re!==null?re.centerY:te)!==ve&&(re=this.Ta[Kt.layer]+this.Rf.x,Ot===y.firstPickIndex+1&&(re=this.K===0?Math.max(re,zt):Math.min(re,zt)),y.m(Ot++,re,te),y.m(Ot++,re,ve)):(re!==null?re.centerX:zt)!==he&&(re=this.Ta[Kt.layer]+this.Rf.y,Ot===y.firstPickIndex+1&&(re=this.K===90?Math.max(re,te):Math.min(re,te)),y.m(Ot++,zt,re),y.m(Ot++,he,re)):(re=Math.max(10,this.he[Kt.layer]),De=Math.max(10,this.Ld[Kt.layer]),vt?this.K===180?(y.m(Ot++,he+De+Ct,ve),y.m(Ot++,Math.max(he+De-Ct/2,he),ve),y.m(Ot++,he,ve),y.m(Ot++,he,ve),y.m(Ot++,Math.min(he-re+Ct/2,he),ve),y.m(Ot++,he-re-Ct,ve)):this.K===90?(y.m(Ot++,he,ve-re-Ct),y.m(Ot++,he,Math.min(ve-re+Ct/2,ve)),y.m(Ot++,he,ve),y.m(Ot++,he,ve),y.m(Ot++,he,Math.max(ve+De-Ct/2,ve)),y.m(Ot++,he,ve+De+Ct)):this.K===270?(y.m(Ot++,he,ve+De+Ct),y.m(Ot++,he,Math.max(ve+De-Ct/2,ve)),y.m(Ot++,he,ve),y.m(Ot++,he,ve),y.m(Ot++,he,Math.min(ve-re+Ct/2,ve)),y.m(Ot++,he,ve-re-Ct)):(y.m(Ot++,he-re-Ct,ve),y.m(Ot++,Math.min(he-re+Ct/2,he),ve),y.m(Ot++,he,ve),y.m(Ot++,he,ve),y.m(Ot++,Math.max(he+De-Ct/2,he),ve),y.m(Ot++,he+De+Ct,ve)):this.K===180?(y.m(Ot++,he+De,ve),y.m(Ot++,he-re,ve)):this.K===90?(y.m(Ot++,he,ve-re),y.m(Ot++,he,ve+De)):this.K===270?(y.m(Ot++,he,ve+De),y.m(Ot++,he,ve-re)):(y.m(Ot++,he-re,ve),y.m(Ot++,he+De,ve)))),ut=Kt}xt&&(zt=y.i(Ot-1).x,te=y.i(Ot-1).y,he=y.i(Ot).x,ve=y.i(Ot).y,this.K===180||this.K===0?te!==ve&&(re=this.K===0?Math.min(Math.max((he+zt)/2,this.Ta[ft.layer]+this.Rf.x),he):Math.max(Math.min((he+zt)/2,this.Ta[ft.layer]+this.Rf.x),he),y.m(Ot++,re,te),y.m(Ot++,re,ve)):zt!==he&&(re=this.K===90?Math.min(Math.max((ve+te)/2,this.Ta[ft.layer]+this.Rf.y),ve):Math.max(Math.min((ve+te)/2,this.Ta[ft.layer]+this.Rf.y),ve),y.m(Ot++,zt,re),y.m(Ot++,he,re)))}b!==null&&vt&&4<=y.pointsCount&&(tt!==null&&(tt=lt===Qr?y.getLinkPointFromPoint(E,tt,tt.ga(Co),y.i(3),!0):y.i(0),lt===Qr&&(lt=y.i(2),b=y.i(3),this.direction===90||this.direction===270?(y.L(1,(tt.x+lt.x)/2,lt.y),y.L(2,b.x,(lt.y+b.y)/2)):(y.L(1,lt.x,(tt.y+lt.y)/2),y.L(2,(lt.x+b.x)/2,b.y))),tt.w()||tt.set(E.actualBounds.center),y.L(0,tt.x,tt.y)),ot!==null&&(E=rt===Qr?y.getLinkPointFromPoint(z,ot,ot.ga(Co),y.i(y.pointsCount-4),!1):y.i(y.pointsCount-1),rt===Qr&&(ot=y.i(y.pointsCount-3),rt=y.i(y.pointsCount-4),this.direction===90||this.direction===270?(y.L(y.pointsCount-2,(E.x+ot.x)/2,ot.y),y.L(y.pointsCount-2,rt.x,(ot.y+rt.y)/2)):(y.L(y.pointsCount-2,ot.x,(E.y+ot.y)/2),y.L(y.pointsCount-3,(ot.x+rt.x)/2,rt.y))),E.w()||E.set(z.actualBounds.center),y.L(y.pointsCount-1,E.x,E.y))),y.zf(),x.commit()}}}this.avoidOrthogonalOverlaps()},Qo.prototype.avoidOrthogonalOverlaps=function(){if(!(0>=this.linkSpacing)){for(var a=new mn,y=this.network.edges.iterator;y.next();){var x=y.value.link;x!==null&&x.isOrthogonal&&!a.contains(x)&&a.add(x)}if(0z.y&&(ut=lt.y>z.y?0:tt.xz.x&&(ut=lt.x>z.x?0:tt.yy.layer?1:a.rdy.rd?1:a.Icy.Ic?1:0:0},bt.Ux=function(a,y){return a instanceof hc&&y instanceof hc&&a!==y?a.firsty.first||a.jy.j||a.rdy.rd?1:a.Icy.Ic?1:0:0},bt.Js=function(a,y){return a instanceof hc&&y instanceof hc&&a!==y?a.jcy.jc||a.jy.j||a.rdy.rd?1:a.Icy.Ic?1:0:0},bt.B=function(a,y){return a-=y,-1a},bt.zi=function(a,y,x,b){var E=a.length,z=b-x;if(!(1>=z))if((0>x||x>=E-1)&&ce("not in range 0 <= from < length: "+x),z===2)b=a[x],E=a[x+1],0=E)a.sort(y);else for(x=a.slice(0,b),x.sort(y),y=0;y=E)for(b=a.slice(x),b.sort(y),y=x;y=a.He.length){for(var b=[],E=0;Ea&&(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 N0=new Qe(Qo,"CycleDepthFirst",0),Sy=new Qe(Qo,"CycleGreedy",1),Wp=new Qe(Qo,"CycleFromLayers",2),T0=new Qe(Qo,"LayerOptimalLinkLength",0),xy=new Qe(Qo,"LayerLongestPathSink",1),Py=new Qe(Qo,"LayerLongestPathSource",2),O0=new Qe(Qo,"InitDepthFirstOut",0),wy=new Qe(Qo,"InitDepthFirstIn",1),Cy=new Qe(Qo,"InitNaive",2),by=new Qe(Qo,"AggressiveNone",0),F0=new Qe(Qo,"AggressiveLess",1),Ly=new Qe(Qo,"AggressiveMore",2),Ux=8;Qo.className="LayeredDigraphLayout",Qo.CycleDepthFirst=N0,Qo.CycleGreedy=Sy,Qo.CycleFromLayers=Wp,Qo.LayerOptimalLinkLength=T0,Qo.LayerLongestPathSink=xy,Qo.LayerLongestPathSource=Py,Qo.InitDepthFirstOut=O0,Qo.InitDepthFirstIn=wy,Qo.InitNaive=Cy,Qo.AggressiveNone=by,Qo.AggressiveLess=F0,Qo.AggressiveMore=Ly,Qo.PackNone=0,Qo.PackExpand=1,Qo.PackStraighten=2,Qo.PackMedian=4,Qo.PackAll=15,Qo.AlignNone=0,Qo.AlignUpperLeft=1,Qo.AlignUpperRight=2,Qo.AlignLowerLeft=4,Qo.AlignLowerRight=8,Qo.AlignAll=15;function hc(){this.index=this.Ic=this.rd=this.jc=this.first=this.layer=0,this.link=null,this.j=0}hc.className="SegInfo";function Tg(a){gr.call(this,a)}We(Tg,gr),Tg.prototype.createVertex=function(){return new au(this)},Tg.prototype.createEdge=function(){return new Kp(this)},Tg.className="LayeredDigraphNetwork";function au(a){zs.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}We(au,zs);function ix(a,y){return a.index-y.index}function I0(a,y){if(!a.$n){for(var x=[],b=Ni(a.destinationEdgesArrayAccess),E=b.next();!E.done;E=b.next())E=E.value,E.valid&&x.push(E);a.$n=x}for(a=Ni(a.$n),x=a.next();!x.done;x=a.next())if(x=x.value,x.toVertex===y)return x;ce("Unable to find destination edge to given vertex")}function My(a){if(!a.co){for(var y=[],x=Ni(a.sourceEdgesArrayAccess),b=x.next();!b.done;b=x.next())b=b.value,b.valid&&y.push(b.fromVertex);y.sort(ix),a.co=y}return a.co}function Yx(a){if(!a.ao){for(var y=[],x=Ni(a.destinationEdgesArrayAccess),b=x.next();!b.done;b=x.next())b=b.value,b.valid&&y.push(b.toVertex);y.sort(ix),a.ao=y}return a.ao}au.prototype.Cl=function(a){zs.prototype.Cl.call(this,a),this.bo=this.co=null},au.prototype.Kl=function(a){zs.prototype.Kl.call(this,a),this.bo=this.co=null},au.prototype.zl=function(a){zs.prototype.zl.call(this,a),this.$n=this.ao=null},au.prototype.Jl=function(a){zs.prototype.Jl.call(this,a),this.$n=this.ao=null},Jt.Object.defineProperties(au.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)}}}),au.prototype.deleteDestinationEdge=au.prototype.Jl,au.prototype.addDestinationEdge=au.prototype.zl,au.prototype.deleteSourceEdge=au.prototype.Kl,au.prototype.addSourceEdge=au.prototype.Cl,au.className="LayeredDigraphVertex";function Kp(a){Cl.call(this,a),this.j=this.ia=this.Ha=!1,this.V=this.u=NaN,this.F=this.o=0}We(Kp,Cl),Jt.Object.defineProperties(Kp.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)}}}),Kp.className="LayeredDigraphEdge";function ro(a){Er.call(this),this.Ub=new un,this.Wn=R0,this.ud=Ih,this.vo=j0,this.Bq=Ry,this.$v=[],this.td=!0,this.Rb=H0,this.$d=new Nn(10,10).freeze();var y=new If(this);this.W=new vu(y),this.Y=new vu(y),this.ru=[],a&&Object.assign(this,a)}We(ro,Er),ro.prototype.cloneProtected=function(a){Er.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)},ro.prototype.qb=function(a){a.classType===ro?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:ce("Unknown enum value: "+a):Er.prototype.qb.call(this,a)},ro.prototype.createNetwork=function(){return new If(this)},ro.prototype.makeNetwork=function(a){function y(b){if(b instanceof Dn)return!b.isLinkLabel&&b.category!=="Comment";if(b instanceof Ln){var E=b.fromNode;return E===null||E.isLinkLabel||E.category==="Comment"?!1:(b=b.toNode,!(b===null||b.isLinkLabel||b.category==="Comment"))}return!1}var x=this.createNetwork();return a instanceof Be?(x.lg(a.nodes,!0,y),x.lg(a.links,!0,y)):a instanceof Fi?x.lg(a.memberParts,!1,y):x.lg(a.iterator,!1,y),x},ro.prototype.doLayout=function(a){this.network===null&&(this.network=this.makeNetwork(a)),this.arrangement!==G0&&(this.arrangementOrigin=this.initialOrigin(this.arrangementOrigin));var y=this.diagram;if(y===null&&a instanceof Be&&(y=a),this.path===R0&&y!==null?this.ud=y.isTreePathToChildren?Ih:Of:this.ud=this.path===R0?Ih:this.path,0y.level)return!1;a.removeChild(x.parent,x)}return!0}ro.prototype.removeChild=function(a,y){if(a!==null&&y!==null){for(var x=a.children,b=0,E=0;EE?hx(this,a,tt,Li,zt,te):dx(this,a,tt,Li,zt,te),Li=te.x,zt=te.width,te=te.height;break;case Fd:for(he=0;heft&&(VnJs&&(Tf(a,-Js,0,Ti,Ro-1),A0(he,-Js,0),A0(ve,-Js,0),Js=0)}dr.S.h(Js,Wn),zt=Math.max(zt,De),te=Math.max(te,re+(bn===0?0:Ct)+Vs.height),Vn=De}else 0ft&&(WnJs&&(Tf(a,0,-Js,Ti,Ro-1),A0(he,0,-Js),A0(ve,0,-Js),Js=0)),dr.S.h(Vn,Js),te=Math.max(te,Fn),zt=Math.max(zt,re+(bn===0?0:Ct)+Vs.width),Wn=Fn;an++}switch(0lt&&(lt=0),135Ot&&(Ot=0),rt===id&&(ot+=vt/2+a.focus.y),tt+=b+x):y?(a.comments===null?b>zt&&(zt=Oy(rt,b-zt,0),tt=zt.x,ot=zt.y,zt=b,lt=0):zt=Ny(a,zt,lt),0>lt&&(tt-=lt,lt=0),135te&&(te=Oy(rt,0,Kt-te),tt=te.x,ot=te.y,te=Kt,Ot=0):te=Ty(a,te,Ot),0>Ot&&(ot-=Ot,Ot=0),tt+=b+x),0E[0].x?E[2].assign(E[1]):E[1].assign(E[2])),E[3].yE[0].x?E[3].assign(E[2]):E[2].assign(E[3])),bn[0].h(lt+b,0),bn[1].h(bn[0].x,Kt),bn[2].yE[0].y?E[2].assign(E[1]):E[1].assign(E[2])),E[3].xE[0].y?E[3].assign(E[2]):E[2].assign(E[3])),bn[0].h(0,Ot+Kt),bn[1].h(b,bn[0].y),bn[2].xb?hx(a,y,E,an,re,he):dx(a,y,E,an,re,he),an=he.x,re=he.width,he=he.height;break;case Fd:for(vt=0;vtvt&&(Devt&&(Fnft&&(ft=0),135zt&&(zt=0)),y.la.h(ft,zt),y.Da.h(re,he)}}ro.prototype.customAlignment=function(a,y,x,b,E){return[y,x,b,E]};function hx(a,y,x,b,E,z){var tt=x.length;if(tt===0)return new Ye(b,0,E,z);if(tt===1)return y=x[0],E=y.Da.width,z=y.Da.height,new Ye(b,0,E,z);for(var ot=y.nodeSpacing,rt=y.rowSpacing,lt=Ou(y)===90,ut=0,ft=0,vt=0,xt=0;xtlt&&(E-=lt),z=Math.max(z,Math.max(xt,vt)+a+tt.height),0>x.S.x&&(b=B0(y,x.S.x,!1,b,ot))):(x.S.h(E+a,b+ot/2-x.focus.y-x.la.y),E=Math.max(E,Math.max(Ct,ft)+a+tt.width),vt=b+ot/2-x.focus.y-x.la.y,z=Math.max(z,vt+tt.height),0>vt&&(z-=vt),0>x.S.y&&(b=B0(y,x.S.y,!0,b,ot)))),new Ye(b,0,E,z)}function dx(a,y,x,b,E,z){var tt=x.length;if(tt===0)return new Ye(b,0,E,z);if(tt===1)return x=x[0],E=x.Da.width,z=x.Da.height,new Ye(b,0,E,z);for(var ot=y.nodeSpacing,rt=y.rowSpacing,lt=Ou(y)===270,ut=0,ft=0,vt=0,xt=0;xtft&&(E-=ft),z=Math.max(z,Math.abs(Math.min(xt,vt))+a+ut.height),0>rt.S.x&&(b=B0(y,rt.S.x,!1,b,ot))):(rt.S.h(-E-ut.width-a,b+ot/2-rt.focus.y-rt.la.y),E=Math.max(E,Math.abs(Math.min(Ct,ft))+a+ut.width),vt=b+ot/2-rt.focus.y-rt.la.y,z=Math.max(z,vt+ut.height),0>vt&&(z-=vt),0>rt.S.y&&(b=B0(y,rt.S.y,!0,b,ot)))),y=0;yy&&(y=x+a.width),0>x&&(y-=x),y;case Bh:return a.width>y?a.width:y;case Dh:return 2*a.focus.x>y?a.width:y+a.width-2*a.focus.x;case Od:case Ah:return Math.max(a.width,Math.max(y,x+a.width)-Math.min(0,x));case Fd:return a.width-a.focus.x+a.nodeSpacing/2+y;case id:return Math.max(a.width,a.focus.x+a.nodeSpacing/2+y);default:return y}}function Ty(a,y,x){switch(a.alignment){case Ff:case Fg:return x+a.height>y&&(y=x+a.height),0>x&&(y-=x),y;case Bh:return a.height>y?a.height:y;case Dh:return 2*a.focus.y>y?a.height:y+a.height-2*a.focus.y;case Od:case Ah:return Math.max(a.height,Math.max(y,x+a.height)-Math.min(0,x));case Fd:return a.height-a.focus.y+a.nodeSpacing/2+y;case id:return Math.max(a.height,a.focus.y+a.nodeSpacing/2+y);default:return y}}function Oy(a,y,x){switch(a){case Fg:y/=2,x/=2;break;case Ff:y/=2,x/=2;break;case Bh:x=y=0;break;case Dh:break;default:ce("Unhandled alignment value "+a.toString())}return new Gt(y,x)}function _c(a,y,x,b,E,z){y=Oy(y,x,b),Tf(a,y.x,y.y,E,z)}function Tf(a,y,x,b,E){if(y!==0||x!==0)for(a=a.children;b<=E;b++){var z=a[b].S;z.x+=y,z.y+=x}}function D0(a,y,x,b){var E=y.parent;switch(a.ud){case Ih:for(a=y.sourceEdges;a.next();)y=a.value,y.fromVertex===E&&y.relativePoint.h(x,b);break;case Of:for(a=y.destinationEdges;a.next();)y=a.value,y.toVertex===E&&y.relativePoint.h(x,b);break;default:ce("Unhandled path value "+a.ud.toString())}}function A0(a,y,x){for(var b=0;bft.length||xt===null||2>xt.length))for(E=x=0;xlt&&z.yz.y&<y.length||x===null||2>x.length)b=null;else{for(ut=cl(a,y.length+x.length),b=z=rt=0;zrt;)lt=x[z++],ut[b++].h(lt.x+E,lt.y);for(x=cl(a,b),rt=0;rtft.length||z===null||2>z.length)E=null;else{for(ut=cl(a,ft.length+z.length),E=lt=x=0;xz;)rt=ft[x++],ut[E++].h(rt.x,rt.y);for(z=cl(a,E),x=0;xft.length||xt===null||2>xt.length))for(E=x=0;xrt&&z.xz.x&&rty.length||x===null||2>x.length)b=null;else{for(ut=cl(a,y.length+x.length),b=z=rt=0;zrt;)lt=x[z++],ut[b++].h(lt.x,lt.y+E);for(x=cl(a,b),rt=0;rtft.length||z===null||2>z.length)E=null;else{for(ut=cl(a,ft.length+z.length),E=lt=x=0;xz;)rt=ft[x++],ut[E++].h(rt.x,rt.y);for(z=cl(a,E),x=0;x=a?0:135>=a?90:225>=a?180:315>=a?270:0}ro.prototype.computeLayerSpacing=function(a){var y=Ou(a);y=y===90||y===270;var x=a.layerSpacing;if(0=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!==z0&&a!==Xp||(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!==Og&&a!==Vp&&a!==Up&&!Yp||(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!==z0&&a!==Xp||(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 R0=new Qe(ro,"PathDefault",-1),Ih=new Qe(ro,"PathDestination",0),Of=new Qe(ro,"PathSource",1),Og=new Qe(ro,"SortingForwards",10),Vp=new Qe(ro,"SortingReverse",11),Up=new Qe(ro,"SortingAscending",12),Yp=new Qe(ro,"SortingDescending",13),Fg=new Qe(ro,"AlignmentCenterSubtrees",20),Ff=new Qe(ro,"AlignmentCenterChildren",21),Bh=new Qe(ro,"AlignmentStart",22),Dh=new Qe(ro,"AlignmentEnd",23),Od=new Qe(ro,"AlignmentBus",24),Ah=new Qe(ro,"AlignmentBusBranching",25),Fd=new Qe(ro,"AlignmentTopLeftBus",26),id=new Qe(ro,"AlignmentBottomRightBus",27),z0=new Qe(ro,"CompactionNone",30),Xp=new Qe(ro,"CompactionBlock",31),j0=new Qe(ro,"StyleLayered",40),Iy=new Qe(ro,"StyleLastParents",41),By=new Qe(ro,"StyleAlternating",42),Dy=new Qe(ro,"StyleRootOnly",43),H0=new Qe(ro,"ArrangementVertical",50),Ay=new Qe(ro,"ArrangementHorizontal",51),G0=new Qe(ro,"ArrangementFixedRoots",52),Ry=new Qe(ro,"LayerIndividual",60),zy=new Qe(ro,"LayerSiblings",61),$0=new Qe(ro,"LayerUniform",62);ro.className="TreeLayout",ro.PathDefault=R0,ro.PathDestination=Ih,ro.PathSource=Of,ro.SortingForwards=Og,ro.SortingReverse=Vp,ro.SortingAscending=Up,ro.SortingDescending=Yp,ro.AlignmentCenterSubtrees=Fg,ro.AlignmentCenterChildren=Ff,ro.AlignmentStart=Bh,ro.AlignmentEnd=Dh,ro.AlignmentBus=Od,ro.AlignmentBusBranching=Ah,ro.AlignmentTopLeftBus=Fd,ro.AlignmentBottomRightBus=id,ro.CompactionNone=z0,ro.CompactionBlock=Xp,ro.StyleLayered=j0,ro.StyleLastParents=Iy,ro.StyleAlternating=By,ro.StyleRootOnly=Dy,ro.ArrangementVertical=H0,ro.ArrangementHorizontal=Ay,ro.ArrangementFixedRoots=G0,ro.LayerIndividual=Ry,ro.LayerSiblings=zy,ro.LayerUniform=$0;function If(a){gr.call(this,a)}We(If,gr),If.prototype.createVertex=function(){return new vu(this)},If.prototype.createEdge=function(){return new Ig(this)},If.className="TreeNetwork";function vu(a){zs.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 Gt(0,0),this.Da=new Nn(0,0),this.la=new Gt(0,0),this.im=this.hm=this.qA=!1,this.kp=this.Yo=null,this.nd=Og,this.hd=oy,this.Kb=0,this.Jb=Ff,this.Vq=this.Uq=0,this.Wq=20,this.ie=50,this.Aq=0,this.Hp=Xp,this.Ap=0,this.nr=25,this.Gp=this.mr=10,this.Fp=20,this.xr=!0,this.dr=Wo,this.wr=!0,this.Dp=Wo}We(vu,zs),vu.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)},Jt.Object.defineProperties(vu.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;xxt.y+x.rowIndent&&(z=Math.min(z,Math.max(ft.y,z-y.computeNodeIndent(x))))):x.alignment===Bh?(z=b.top+E.y,E.y===0&&ft.yxt.x+x.rowIndent&&(z=Math.min(z,Math.max(ft.x,z-y.computeNodeIndent(x))))):x.alignment===Bh?(z=b.left+E.x,E.x===0&&ft.xxt.y+x.rowIndent&&(z=Math.min(z,Math.max(ft.y,z-y.computeNodeIndent(x))))):x.alignment===Bh?(z=b.top+E.y,E.y===0&&ft.yxt.x+x.rowIndent&&(z=Math.min(z,Math.max(ft.x,z-y.computeNodeIndent(x))))):x.alignment===Bh?(z=b.left+E.x,E.x===0&&ft.x0&&Bt[Bt.length-1])||ge[0]!==6&&ge[0]!==2)){ae=0;continue}if(ge[0]===3&&(!Bt||ge[1]>Bt[0]&&ge[1]',"select"),this.addActionButton(Et,'',"delete"),this.uiStyleSettings.clearButtonVisible&&this.addActionButton(Et,'',"clear"),this.uiStyleSettings.undoButtonVisible&&this.addActionButton(Et,'',"undo"),this.uiStyleSettings.redoButtonVisible&&this.addActionButton(Et,'',"redo"),this.uiStyleSettings.zoomButtonVisible&&this.addActionButton(Et,'',"zoom"),this.uiStyleSettings.zoomButtonVisible&&this.uiStyleSettings.zoomOutButtonVisible&&this.addActionButton(Et,'',"zoom-out"),this.uiStyleSettings.notesButtonVisible&&this.addActionButton(Et,'',"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(yt){var ae=document.createElement("div");ae.className=""+St.toolbarButtonStyleClass.name,ae.setAttribute("data-type-name",yt.typeName),ae.innerHTML=yt.icon,ae.addEventListener("click",function(){St.markerToolbarButtonClicked(ae,yt)}),St.buttons.push(ae),St.markerButtons.push(ae)}),this.overflowButton=document.createElement("div"),this.overflowButton.className=this.toolbarButtonStyleClass.name+" "+(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name),this.overflowButton.innerHTML='',this.overflowButton.addEventListener("click",this.overflowButtonClicked),this.markerButtonBlock.appendChild(this.overflowButton));var Bt=document.createElement("div");Bt.className=this.toolbarBlockStyleClass.name,Bt.style.whiteSpace="nowrap",Bt.style.display=this.uiStyleSettings.resultButtonBlockVisible!==!1?"":"none",this.uiContainer.appendChild(Bt),this.addActionButton(Bt,'',"render"),this.addActionButton(Bt,'',"close"),this.markerjsContainer.appendChild(this.uiContainer),this.setSelectMode(),this.setCurrentMarker(),this.adjustLayout()},Rt.prototype.addButtonClickListener=function(Lt){this.buttonClickListeners.push(Lt)},Rt.prototype.removeButtonClickListener=function(Lt){this.buttonClickListeners.indexOf(Lt)>-1&&this.buttonClickListeners.splice(this.buttonClickListeners.indexOf(Lt),1)},Rt.prototype.setSelectMode=function(){this.resetButtonStyles(),this.setActiveButton(this.buttons[0])},Rt.prototype.adjustLayout=function(){if(this.markerButtons&&this.markerButtons.length>0){var Lt=Math.floor(this.markerButtonBlock.clientWidth/this.uiStyleSettings.toolbarHeight)-1;this.markerButtonBlock.innerHTML="",this.markerButtonOverflowBlock.innerHTML="";for(var St=0;St0&&this.buttonClickListeners.forEach(function(Et){return Et("marker",St)}),this.markerButtonOverflowBlock.style.display="none"},Rt.prototype.actionToolbarButtonClicked=function(Lt,St){this.buttonClickListeners&&this.buttonClickListeners.length>0&&this.buttonClickListeners.forEach(function(Et){return Et("action",St)}),this.markerButtonOverflowBlock.style.display="none",this.setActiveButton(this.buttons[0])},Rt.prototype.setActiveButton=function(Lt){this.resetButtonStyles(),Lt.className=Lt.className.replace(this.uiStyleSettings.toolbarButtonStyleColorsClassName?this.uiStyleSettings.toolbarButtonStyleColorsClassName:this.toolbarButtonStyleColorsClass.name,"").trim(),Lt.className+=" "+(this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName?this.uiStyleSettings.toolbarActiveButtonStyleColorsClassName:this.toolbarActiveButtonStyleColorsClass.name)},Rt.prototype.setActiveMarkerButton=function(Lt){var St=this.markerButtons.find(function(Et){return Et.getAttribute("data-type-name")===Lt});St&&this.setActiveButton(St)},Rt.prototype.setCurrentMarker=function(Lt){var St=this;this.currentMarker=Lt,this.buttons.filter(function(Et){return/delete|notes/.test(Et.getAttribute("data-action"))}).forEach(function(Et){St.currentMarker===void 0?(Et.style.fillOpacity="0.4",Et.style.pointerEvents="none"):(Et.style.fillOpacity="1",Et.style.pointerEvents="all")})},Rt}(),It=function(){function Rt(Lt,St,Et,Bt){this.panels=[],this.panelButtons=[],this.markerjsContainer=Lt,this.displayMode=St,this.uiStyleSettings=Et,this.styles=Bt,this.panelButtonClick=this.panelButtonClick.bind(this),this.addStyles()}return Rt.prototype.addStyles=function(){var Lt;this.toolboxStyleClass=this.styles.addClass(new ye("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 ye("toolbox_colors",` color: `+this.uiStyleSettings.toolboxColor+`; `));var St=this.uiStyleSettings.toolbarHeight/4;this.toolboxButtonRowStyleClass=this.styles.addClass(new ye("toolbox-button-row",` display: flex; cursor: default; box-sizing: content-box; `)),this.toolboxButtonRowStyleColorsClass=this.styles.addClass(new ye("toolbox-button-row_colors",` background-color: `+this.uiStyleSettings.toolbarBackgroundColor+`; `)),this.toolboxPanelRowStyleClass=this.styles.addClass(new ye("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 ye("toolbox-panel-row_colors",` background-color: `+((Lt=this.uiStyleSettings.toolboxBackgroundColor)!==null&&Lt!==void 0?Lt:this.uiStyleSettings.toolbarBackgroundHoverColor)+`; `)),this.toolboxButtonStyleClass=this.styles.addClass(new ye("toolbox_button",` display: inline-block; width: `+(this.uiStyleSettings.toolbarHeight-2*St)+`px; height: `+(this.uiStyleSettings.toolbarHeight-2*St)+`px; padding: `+St+`px; box-sizing: content-box; `)),this.toolboxButtonStyleColorsClass=this.styles.addClass(new ye("toolbox-button_colors",` fill: `+this.uiStyleSettings.toolbarColor+`; `)),this.toolboxActiveButtonStyleColorsClass=this.styles.addClass(new ye("toolbox-active-button_colors",` background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+`; fill: `+this.uiStyleSettings.toolbarColor+`; `)),this.styles.addRule(new Fe("."+this.toolboxButtonStyleColorsClass.name+":hover",` background-color: `+this.uiStyleSettings.toolbarBackgroundHoverColor+` `)),this.styles.addRule(new Fe("."+this.toolboxButtonStyleClass.name+" svg",` height: `+this.uiStyleSettings.toolbarHeight/2+`px; `))},Rt.prototype.show=function(Lt){var St;this.uiContainer=document.createElement("div"),this.uiContainer.style.visibility=Lt,this.uiContainer.className=this.toolboxStyleClass.name+" "+((St=this.uiStyleSettings.toolboxStyleColorsClassName)!==null&&St!==void 0?St:this.toolboxStyleColorsClass.name),this.markerjsContainer.appendChild(this.uiContainer)},Rt.prototype.setPanelButtons=function(Lt){var St,Et,Bt=this;this.panels=Lt,this.uiContainer!==void 0&&(this.uiContainer.innerHTML="",this.panelRow=document.createElement("div"),this.panelRow.className=this.toolboxPanelRowStyleClass.name+" "+((St=this.uiStyleSettings.toolboxPanelRowStyleColorsClassName)!==null&&St!==void 0?St:this.toolboxPanelRowStyleColorsClass.name),this.uiContainer.appendChild(this.panelRow),this.buttonRow=document.createElement("div"),this.buttonRow.className=this.toolboxButtonRowStyleClass.name+" "+((Et=this.uiStyleSettings.toolboxButtonRowStyleColorsClassName)!==null&&Et!==void 0?Et:this.toolboxButtonRowStyleColorsClass.name)+" ",this.uiContainer.appendChild(this.buttonRow),this.panelButtons.splice(0),this.panels.forEach(function(yt){var ae;yt.uiStyleSettings=Bt.uiStyleSettings;var Pe=document.createElement("div");Pe.className=Bt.toolboxButtonStyleClass.name+" "+((ae=Bt.uiStyleSettings.toolboxButtonStyleColorsClassName)!==null&&ae!==void 0?ae:Bt.toolboxButtonStyleColorsClass.name),Pe.innerHTML=yt.icon,Pe.title=yt.title,Pe.addEventListener("click",function(){Bt.panelButtonClick(yt)}),Bt.panelButtons.push(Pe),Bt.buttonRow.appendChild(Pe)}),this.displayMode==="inline"?this.panelRow.style.display="none":this.panelRow.style.visibility="hidden")},Rt.prototype.panelButtonClick=function(Lt){var St=this,Et=-1;if(Lt!==this.activePanel){Et=this.panels.indexOf(Lt),this.panelRow.innerHTML="";var Bt=Lt.getUi();Bt.style.margin=this.uiStyleSettings.toolbarHeight/4+"px",this.panelRow.appendChild(Bt),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=Lt}else this.activePanel=void 0,this.panelRow.className=this.panelRow.className.replace(this.styles.fadeInAnimationClassName,""),this.panelRow.className+=" "+this.styles.fadeOutAnimationClassName,setTimeout(function(){St.displayMode==="inline"?St.panelRow.style.display="none":St.panelRow.style.visibility="hidden"},200);this.panelButtons.forEach(function(yt,ae){var Pe,ne;yt.className=St.toolboxButtonStyleClass.name+" "+(ae===Et?""+((Pe=St.uiStyleSettings.toolboxActiveButtonStyleColorsClassName)!==null&&Pe!==void 0?Pe:St.toolboxActiveButtonStyleColorsClass.name):""+((ne=St.uiStyleSettings.toolboxButtonStyleColorsClassName)!==null&&ne!==void 0?ne:St.toolboxButtonStyleColorsClass.name))})},Rt}(),et=function(Rt,Lt){this.title=Rt,this.icon=Lt},nt=function(Rt){function Lt(St,Et,Bt,yt){var ae=Rt.call(this,St,yt||'')||this;return ae.colors=[],ae.addTransparent=!1,ae.colorBoxes=[],ae.colors=Et,ae.currentColor=Bt,ae.setCurrentColor=ae.setCurrentColor.bind(ae),ae.getColorBox=ae.getColorBox.bind(ae),ae}return Ht(Lt,Rt),Lt.prototype.getUi=function(){var St=this,Et=document.createElement("div");return Et.style.overflow="hidden",Et.style.whiteSpace="nowrap",this.colors.forEach(function(Bt){var yt=St.getColorBox(Bt);Et.appendChild(yt),St.colorBoxes.push(yt)}),Et},Lt.prototype.getColorBox=function(St){var Et=this,Bt=this.uiStyleSettings.toolbarHeight/4,yt=this.uiStyleSettings.toolbarHeight-Bt,ae=document.createElement("div");ae.style.display="inline-block",ae.style.boxSizing="content-box",ae.style.width=yt-2+"px",ae.style.height=yt-2+"px",ae.style.padding="1px",ae.style.marginRight="2px",ae.style.marginBottom="2px",ae.style.borderWidth="2px",ae.style.borderStyle="solid",ae.style.borderRadius=(yt+2)/2+"px",ae.style.borderColor=St===this.currentColor?this.uiStyleSettings.toolboxAccentColor:"transparent",ae.addEventListener("click",function(){Et.setCurrentColor(St,ae)});var Pe=document.createElement("div");return Pe.style.display="inline-block",Pe.style.width=yt-2+"px",Pe.style.height=yt-2+"px",Pe.style.backgroundColor=St,Pe.style.borderRadius=yt/2+"px",St==="transparent"&&(Pe.style.fill=this.uiStyleSettings.toolboxAccentColor,Pe.innerHTML=` `),ae.appendChild(Pe),ae},Lt.prototype.setCurrentColor=function(St,Et){var Bt=this;this.currentColor=St,this.colorBoxes.forEach(function(yt){yt.style.borderColor=yt===Et?Bt.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onColorChanged&&this.onColorChanged(St)},Lt}(et),dt=function(){function Rt(Lt,St,Et){this._state="new",this._isSelected=!1,this._container=Lt,this._overlayContainer=St,this.globalSettings=Et,this.stateChanged=this.stateChanged.bind(this),this.colorChanged=this.colorChanged.bind(this),this.fillColorChanged=this.fillColorChanged.bind(this)}return Object.defineProperty(Rt.prototype,"typeName",{get:function(){return Object.getPrototypeOf(this).constructor.typeName},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"container",{get:function(){return this._container},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"overlayContainer",{get:function(){return this._overlayContainer},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"state",{get:function(){return this._state},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"toolboxPanels",{get:function(){return[]},enumerable:!1,configurable:!0}),Rt.prototype.ownsTarget=function(Lt){return!1},Object.defineProperty(Rt.prototype,"isSelected",{get:function(){return this._isSelected},enumerable:!1,configurable:!0}),Rt.prototype.select=function(){this.container.style.cursor="move",this._isSelected=!0,this.manipulationStartState=this.getState()},Rt.prototype.deselect=function(){this.container.style.cursor="default",this._isSelected=!1,this.stateChanged()},Rt.prototype.pointerDown=function(Lt,St){},Rt.prototype.dblClick=function(Lt,St){},Rt.prototype.manipulate=function(Lt){},Rt.prototype.pointerUp=function(Lt){this.stateChanged()},Rt.prototype.dispose=function(){},Rt.prototype.addMarkerVisualToContainer=function(Lt){this.container.childNodes.length>0?this.container.insertBefore(Lt,this.container.childNodes[0]):this.container.appendChild(Lt)},Rt.prototype.getState=function(){return{typeName:Rt.typeName,state:this.state,notes:this.notes}},Rt.prototype.restoreState=function(Lt){this._state=Lt.state,this.notes=Lt.notes},Rt.prototype.scale=function(Lt,St){},Rt.prototype.colorChanged=function(Lt){this.onColorChanged&&this.onColorChanged(Lt),this.stateChanged()},Rt.prototype.fillColorChanged=function(Lt){this.onFillColorChanged&&this.onFillColorChanged(Lt),this.stateChanged()},Rt.prototype.stateChanged=function(){if(this.onStateChanged&&this.state!=="creating"&&this.state!=="new"){var Lt=this.getState();this.manipulationStartState!==void 0&&(this.manipulationStartState.state="select"),Lt.state="select",JSON.stringify(this.manipulationStartState)!=JSON.stringify(Lt)&&this.onStateChanged(this)}},Rt.typeName="MarkerBase",Rt}(),at=function(){function Rt(){this.findGripByVisual=this.findGripByVisual.bind(this)}return Rt.prototype.findGripByVisual=function(Lt){return this.topLeft.ownsTarget(Lt)?this.topLeft:this.topCenter.ownsTarget(Lt)?this.topCenter:this.topRight.ownsTarget(Lt)?this.topRight:this.centerLeft.ownsTarget(Lt)?this.centerLeft:this.centerRight.ownsTarget(Lt)?this.centerRight:this.bottomLeft.ownsTarget(Lt)?this.bottomLeft:this.bottomCenter.ownsTarget(Lt)?this.bottomCenter:this.bottomRight.ownsTarget(Lt)?this.bottomRight:void 0},Rt}(),gt=function(){function Rt(){this.GRIP_SIZE=10,this.visual=qt.createGroup(),this.visual.appendChild(qt.createCircle(1.5*this.GRIP_SIZE,[["fill","transparent"]])),this.visual.appendChild(qt.createCircle(this.GRIP_SIZE,[["fill","#cccccc"],["fill-opacity","0.7"],["stroke","#333333"],["stroke-width","2"],["stroke-opacity","0.7"]]))}return Rt.prototype.ownsTarget=function(Lt){return Lt===this.visual||Lt===this.visual.childNodes[0]||Lt===this.visual.childNodes[1]},Rt}(),mt=function(){function Rt(){}return Rt.toITransformMatrix=function(Lt){return{a:Lt.a,b:Lt.b,c:Lt.c,d:Lt.d,e:Lt.e,f:Lt.f}},Rt.toSVGMatrix=function(Lt,St){return Lt.a=St.a,Lt.b=St.b,Lt.c=St.c,Lt.d=St.d,Lt.e=St.e,Lt.f=St.f,Lt},Rt}(),Pt=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.left=0,yt.top=0,yt.width=0,yt.height=0,yt.defaultSize={x:50,y:20},yt.offsetX=0,yt.offsetY=0,yt.rotationAngle=0,yt.CB_DISTANCE=10,yt._suppressMarkerCreateEvent=!1,yt.container.transform.baseVal.appendItem(qt.createTransform()),yt.setupControlBox(),yt}return Ht(Lt,Rt),Object.defineProperty(Lt.prototype,"centerX",{get:function(){return this.left+this.width/2},enumerable:!1,configurable:!0}),Object.defineProperty(Lt.prototype,"centerY",{get:function(){return this.top+this.height/2},enumerable:!1,configurable:!0}),Object.defineProperty(Lt.prototype,"visual",{get:function(){return this._visual},set:function(St){this._visual=St;var Et=qt.createTransform();this._visual.transform.baseVal.appendItem(Et)},enumerable:!1,configurable:!0}),Lt.prototype.ownsTarget=function(St){return!!Rt.prototype.ownsTarget.call(this,St)||!!(this.controlGrips.findGripByVisual(St)!==void 0||this.rotatorGrip!==void 0&&this.rotatorGrip.ownsTarget(St))},Lt.prototype.pointerDown=function(St,Et){Rt.prototype.pointerDown.call(this,St,Et),this.state==="new"&&(this.left=St.x,this.top=St.y),this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.manipulationStartWidth=this.width,this.manipulationStartHeight=this.height;var Bt=this.unrotatePoint(St);if(this.manipulationStartX=Bt.x,this.manipulationStartY=Bt.y,this.offsetX=Bt.x-this.left,this.offsetY=Bt.y-this.top,this.state!=="new")if(this.select(),this.activeGrip=this.controlGrips.findGripByVisual(Et),this.activeGrip!==void 0)this._state="resize";else if(this.rotatorGrip!==void 0&&this.rotatorGrip.ownsTarget(Et)){this.activeGrip=this.rotatorGrip;var yt=this.rotatePoint({x:this.centerX,y:this.centerY});this.left=yt.x-this.width/2,this.top=yt.y-this.height/2,this.moveVisual({x:this.left,y:this.top});var ae=this.container.transform.baseVal.getItem(0);ae.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(ae,0),this.adjustControlBox(),this._state="rotate"}else this._state="move"},Lt.prototype.pointerUp=function(St){var Et=this.state;Rt.prototype.pointerUp.call(this,St),this.state==="creating"&&this.width<10&&this.height<10?(this.width=this.defaultSize.x,this.height=this.defaultSize.y):this.manipulate(St),this._state="select",Et==="creating"&&this.onMarkerCreated&&this._suppressMarkerCreateEvent===!1&&this.onMarkerCreated(this)},Lt.prototype.moveVisual=function(St){this.visual.style.transform="translate("+St.x+"px, "+St.y+"px)"},Lt.prototype.manipulate=function(St){var Et=this.unrotatePoint(St);this.state==="creating"?this.resize(St):this.state==="move"?(this.left=this.manipulationStartLeft+(Et.x-this.manipulationStartLeft)-this.offsetX,this.top=this.manipulationStartTop+(Et.y-this.manipulationStartTop)-this.offsetY,this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()):this.state==="resize"?this.resize(Et):this.state==="rotate"&&this.rotate(St)},Lt.prototype.resize=function(St){var Et=this.manipulationStartLeft,Bt=this.manipulationStartWidth,yt=this.manipulationStartTop,ae=this.manipulationStartHeight;switch(this.activeGrip){case this.controlGrips.bottomLeft:case this.controlGrips.centerLeft:case this.controlGrips.topLeft:Et=this.manipulationStartLeft+St.x-this.manipulationStartX,Bt=this.manipulationStartWidth+this.manipulationStartLeft-Et;break;case this.controlGrips.bottomRight:case this.controlGrips.centerRight:case this.controlGrips.topRight:case void 0:Bt=this.manipulationStartWidth+St.x-this.manipulationStartX}switch(this.activeGrip){case this.controlGrips.topCenter:case this.controlGrips.topLeft:case this.controlGrips.topRight:yt=this.manipulationStartTop+St.y-this.manipulationStartY,ae=this.manipulationStartHeight+this.manipulationStartTop-yt;break;case this.controlGrips.bottomCenter:case this.controlGrips.bottomLeft:case this.controlGrips.bottomRight:case void 0:ae=this.manipulationStartHeight+St.y-this.manipulationStartY}Bt>=0?(this.left=Et,this.width=Bt):(this.left=Et+Bt,this.width=-Bt),ae>=0?(this.top=yt,this.height=ae):(this.top=yt+ae,this.height=-ae),this.setSize()},Lt.prototype.setSize=function(){this.moveVisual({x:this.left,y:this.top}),this.adjustControlBox()},Lt.prototype.rotate=function(St){if(Math.abs(St.x-this.centerX)>.1){var Et=Math.sign(St.x-this.centerX);this.rotationAngle=180*Math.atan((St.y-this.centerY)/(St.x-this.centerX))/Math.PI+90*Et,this.applyRotation()}},Lt.prototype.applyRotation=function(){var St=this.container.transform.baseVal.getItem(0);St.setRotate(this.rotationAngle,this.centerX,this.centerY),this.container.transform.baseVal.replaceItem(St,0)},Lt.prototype.rotatePoint=function(St){if(this.rotationAngle===0)return St;var Et=this.container.getCTM(),Bt=qt.createPoint(St.x,St.y);return{x:(Bt=Bt.matrixTransform(Et)).x,y:Bt.y}},Lt.prototype.unrotatePoint=function(St){if(this.rotationAngle===0)return St;var Et=this.container.getCTM();Et=Et.inverse();var Bt=qt.createPoint(St.x,St.y);return{x:(Bt=Bt.matrixTransform(Et)).x,y:Bt.y}},Lt.prototype.select=function(){Rt.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},Lt.prototype.deselect=function(){Rt.prototype.deselect.call(this),this.controlBox.style.display="none"},Lt.prototype.setupControlBox=function(){this.controlBox=qt.createGroup();var St=qt.createTransform();St.setTranslate(-this.CB_DISTANCE/2,-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.appendItem(St),this.container.appendChild(this.controlBox),this.controlRect=qt.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=qt.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 at,this.addControlGrips(),this.controlBox.style.display="none"},Lt.prototype.adjustControlBox=function(){var St=this.controlBox.transform.baseVal.getItem(0);St.setTranslate(this.left-this.CB_DISTANCE/2,this.top-this.CB_DISTANCE/2),this.controlBox.transform.baseVal.replaceItem(St,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()},Lt.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()},Lt.prototype.createGrip=function(){var St=new gt;return St.visual.transform.baseVal.appendItem(qt.createTransform()),this.controlBox.appendChild(St.visual),St},Lt.prototype.positionGrips=function(){var St=this.controlGrips.topLeft.GRIP_SIZE,Et=-St/2,Bt=Et,yt=(this.width+this.CB_DISTANCE)/2-St/2,ae=(this.height+this.CB_DISTANCE)/2-St/2,Pe=this.height+this.CB_DISTANCE-St/2,ne=this.width+this.CB_DISTANCE-St/2;this.positionGrip(this.controlGrips.topLeft.visual,Et,Bt),this.positionGrip(this.controlGrips.topCenter.visual,yt,Bt),this.positionGrip(this.controlGrips.topRight.visual,ne,Bt),this.positionGrip(this.controlGrips.centerLeft.visual,Et,ae),this.positionGrip(this.controlGrips.centerRight.visual,ne,ae),this.positionGrip(this.controlGrips.bottomLeft.visual,Et,Pe),this.positionGrip(this.controlGrips.bottomCenter.visual,yt,Pe),this.positionGrip(this.controlGrips.bottomRight.visual,ne,Pe),this.rotatorGrip!==void 0&&this.positionGrip(this.rotatorGrip.visual,yt,Bt-3*this.CB_DISTANCE)},Lt.prototype.positionGrip=function(St,Et,Bt){var yt=St.transform.baseVal.getItem(0);yt.setTranslate(Et,Bt),St.transform.baseVal.replaceItem(yt,0)},Lt.prototype.hideControlBox=function(){this.controlBox.style.display="none"},Lt.prototype.showControlBox=function(){this.controlBox.style.display=""},Lt.prototype.getState=function(){return Object.assign({left:this.left,top:this.top,width:this.width,height:this.height,rotationAngle:this.rotationAngle,visualTransformMatrix:mt.toITransformMatrix(this.visual.transform.baseVal.getItem(0).matrix),containerTransformMatrix:mt.toITransformMatrix(this.container.transform.baseVal.getItem(0).matrix)},Rt.prototype.getState.call(this))},Lt.prototype.restoreState=function(St){Rt.prototype.restoreState.call(this,St);var Et=St;this.left=Et.left,this.top=Et.top,this.width=Et.width,this.height=Et.height,this.rotationAngle=Et.rotationAngle,this.visual.transform.baseVal.getItem(0).setMatrix(mt.toSVGMatrix(this.visual.transform.baseVal.getItem(0).matrix,Et.visualTransformMatrix)),this.container.transform.baseVal.getItem(0).setMatrix(mt.toSVGMatrix(this.container.transform.baseVal.getItem(0).matrix,Et.containerTransformMatrix))},Lt.prototype.scale=function(St,Et){Rt.prototype.scale.call(this,St,Et);var Bt=this.rotatePoint({x:this.left,y:this.top}),yt=this.unrotatePoint({x:Bt.x*St,y:Bt.y*Et});this.left=yt.x,this.top=yt.y,this.width=this.width*St,this.height=this.height*Et,this.adjustControlBox()},Lt}(dt),kt=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.fillColor="transparent",yt.strokeColor="transparent",yt.strokeWidth=0,yt.strokeDasharray="",yt.opacity=1,yt.setStrokeColor=yt.setStrokeColor.bind(yt),yt.setFillColor=yt.setFillColor.bind(yt),yt.setStrokeWidth=yt.setStrokeWidth.bind(yt),yt.setStrokeDasharray=yt.setStrokeDasharray.bind(yt),yt.createVisual=yt.createVisual.bind(yt),yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){return!(!Rt.prototype.ownsTarget.call(this,St)&&St!==this.visual)},Lt.prototype.createVisual=function(){this.visual=qt.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)},Lt.prototype.pointerDown=function(St,Et){Rt.prototype.pointerDown.call(this,St,Et),this.state==="new"&&(this.createVisual(),this.moveVisual(St),this._state="creating")},Lt.prototype.manipulate=function(St){Rt.prototype.manipulate.call(this,St)},Lt.prototype.resize=function(St){Rt.prototype.resize.call(this,St),this.setSize()},Lt.prototype.setSize=function(){Rt.prototype.setSize.call(this),qt.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]])},Lt.prototype.pointerUp=function(St){Rt.prototype.pointerUp.call(this,St),this.setSize()},Lt.prototype.setStrokeColor=function(St){this.strokeColor=St,this.visual&&qt.setAttributes(this.visual,[["stroke",this.strokeColor]]),this.colorChanged(St),this.stateChanged()},Lt.prototype.setFillColor=function(St){this.fillColor=St,this.visual&&qt.setAttributes(this.visual,[["fill",this.fillColor]]),this.stateChanged()},Lt.prototype.setStrokeWidth=function(St){this.strokeWidth=St,this.visual&&qt.setAttributes(this.visual,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},Lt.prototype.setStrokeDasharray=function(St){this.strokeDasharray=St,this.visual&&qt.setAttributes(this.visual,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},Lt.prototype.getState=function(){return Object.assign({fillColor:this.fillColor,strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,opacity:this.opacity},Rt.prototype.getState.call(this))},Lt.prototype.restoreState=function(St){var Et=St;this.fillColor=Et.fillColor,this.strokeColor=Et.strokeColor,this.strokeWidth=Et.strokeWidth,this.strokeDasharray=Et.strokeDasharray,this.opacity=Et.opacity,this.createVisual(),Rt.prototype.restoreState.call(this,St),this.setSize()},Lt.prototype.scale=function(St,Et){Rt.prototype.scale.call(this,St,Et),this.setSize()},Lt.title="Rectangle marker",Lt}(Pt),Tt=function(Rt){function Lt(St,Et,Bt,yt){var ae=Rt.call(this,St,yt||'')||this;return ae.widths=[],ae.widthBoxes=[],ae.widths=Et,ae.currentWidth=Bt,ae.setCurrentWidth=ae.setCurrentWidth.bind(ae),ae}return Ht(Lt,Rt),Lt.prototype.getUi=function(){var St=this,Et=document.createElement("div");return Et.style.display="flex",Et.style.overflow="hidden",Et.style.flexGrow="2",this.widths.forEach(function(Bt){var yt=document.createElement("div");yt.style.display="flex",yt.style.flexGrow="2",yt.style.alignItems="center",yt.style.justifyContent="space-between",yt.style.padding="5px",yt.style.borderWidth="2px",yt.style.borderStyle="solid",yt.style.borderColor=Bt===St.currentWidth?St.uiStyleSettings.toolboxAccentColor:"transparent",yt.addEventListener("click",function(){St.setCurrentWidth(Bt,yt)}),Et.appendChild(yt);var ae=document.createElement("div");ae.innerText=Bt.toString(),ae.style.marginRight="5px",yt.appendChild(ae);var Pe=document.createElement("div");Pe.style.minHeight="20px",Pe.style.flexGrow="2",Pe.style.display="flex",Pe.style.alignItems="center";var ne=document.createElement("hr");ne.style.minWidth="20px",ne.style.border="0px",ne.style.borderTop=Bt+"px solid "+St.uiStyleSettings.toolboxColor,ne.style.flexGrow="2",Pe.appendChild(ne),yt.appendChild(Pe),St.widthBoxes.push(yt)}),Et},Lt.prototype.setCurrentWidth=function(St,Et){var Bt=this;this.currentWidth=St,this.widthBoxes.forEach(function(yt){yt.style.borderColor=yt===Et?Bt.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onWidthChanged&&this.onWidthChanged(this.currentWidth)},Lt}(et),Dt=function(Rt){function Lt(St,Et,Bt,yt){var ae=Rt.call(this,St,yt||'')||this;return ae.styles=[],ae.styleBoxes=[],ae.styles=Et,ae.currentStyle=Bt,ae.setCurrentStyle=ae.setCurrentStyle.bind(ae),ae}return Ht(Lt,Rt),Lt.prototype.getUi=function(){var St=this,Et=document.createElement("div");return Et.style.display="flex",Et.style.overflow="hidden",Et.style.flexGrow="2",this.styles.forEach(function(Bt){var yt=document.createElement("div");yt.style.display="flex",yt.style.alignItems="center",yt.style.justifyContent="space-between",yt.style.padding="5px",yt.style.borderWidth="2px",yt.style.borderStyle="solid",yt.style.overflow="hidden",yt.style.maxWidth=100/St.styles.length-5+"%",yt.style.borderColor=Bt===St.currentStyle?St.uiStyleSettings.toolboxAccentColor:"transparent",yt.addEventListener("click",function(){St.setCurrentStyle(Bt,yt)}),Et.appendChild(yt);var ae=document.createElement("div");ae.style.minHeight="20px",ae.style.flexGrow="2",ae.style.overflow="hidden";var Pe=` `;ae.innerHTML=Pe,yt.appendChild(ae),St.styleBoxes.push(yt)}),Et},Lt.prototype.setCurrentStyle=function(St,Et){var Bt=this;this.currentStyle=St,this.styleBoxes.forEach(function(yt){yt.style.borderColor=yt===Et?Bt.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onStyleChanged&&this.onStyleChanged(this.currentStyle)},Lt}(et),$t=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.strokeColor=Bt.defaultColor,yt.strokeWidth=Bt.defaultStrokeWidth,yt.strokeDasharray=Bt.defaultStrokeDasharray,yt.strokePanel=new nt("Line color",Bt.defaultColorSet,Bt.defaultColor),yt.strokePanel.onColorChanged=yt.setStrokeColor,yt.strokeWidthPanel=new Tt("Line width",Bt.defaultStrokeWidths,Bt.defaultStrokeWidth),yt.strokeWidthPanel.onWidthChanged=yt.setStrokeWidth,yt.strokeStylePanel=new Dt("Line style",Bt.defaultStrokeDasharrays,Bt.defaultStrokeDasharray),yt.strokeStylePanel.onStyleChanged=yt.setStrokeDasharray,yt}return Ht(Lt,Rt),Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Rt.prototype.getState.call(this);return St.typeName=Lt.typeName,St},Lt.typeName="FrameMarker",Lt.title="Frame marker",Lt.icon='',Lt}(kt),ie=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"},Yt=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.x1=0,yt.y1=0,yt.x2=0,yt.y2=0,yt.defaultLength=50,yt.manipulationStartX=0,yt.manipulationStartY=0,yt.manipulationStartX1=0,yt.manipulationStartY1=0,yt.manipulationStartX2=0,yt.manipulationStartY2=0,yt.setupControlBox(),yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){return!!Rt.prototype.ownsTarget.call(this,St)||!(!this.grip1.ownsTarget(St)&&!this.grip2.ownsTarget(St))},Lt.prototype.pointerDown=function(St,Et){Rt.prototype.pointerDown.call(this,St,Et),this.manipulationStartX=St.x,this.manipulationStartY=St.y,this.state==="new"&&(this.x1=St.x,this.y1=St.y,this.x2=St.x,this.y2=St.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(Et)?this.activeGrip=this.grip1:this.grip2.ownsTarget(Et)?this.activeGrip=this.grip2:this.activeGrip=void 0,this.activeGrip?this._state="resize":this._state="move")},Lt.prototype.pointerUp=function(St){var Et=this.state;Rt.prototype.pointerUp.call(this,St),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(St),this._state="select",Et==="creating"&&this.onMarkerCreated&&this.onMarkerCreated(this)},Lt.prototype.adjustVisual=function(){},Lt.prototype.manipulate=function(St){this.state==="creating"?this.resize(St):this.state==="move"?(this.x1=this.manipulationStartX1+St.x-this.manipulationStartX,this.y1=this.manipulationStartY1+St.y-this.manipulationStartY,this.x2=this.manipulationStartX2+St.x-this.manipulationStartX,this.y2=this.manipulationStartY2+St.y-this.manipulationStartY,this.adjustVisual(),this.adjustControlBox()):this.state==="resize"&&this.resize(St)},Lt.prototype.resize=function(St){switch(this.activeGrip){case this.grip1:this.x1=St.x,this.y1=St.y;break;case this.grip2:case void 0:this.x2=St.x,this.y2=St.y}this.adjustVisual(),this.adjustControlBox()},Lt.prototype.select=function(){Rt.prototype.select.call(this),this.adjustControlBox(),this.controlBox.style.display=""},Lt.prototype.deselect=function(){Rt.prototype.deselect.call(this),this.controlBox.style.display="none"},Lt.prototype.setupControlBox=function(){this.controlBox=qt.createGroup(),this.container.appendChild(this.controlBox),this.addControlGrips(),this.controlBox.style.display="none"},Lt.prototype.adjustControlBox=function(){this.positionGrips()},Lt.prototype.addControlGrips=function(){this.grip1=this.createGrip(),this.grip2=this.createGrip(),this.positionGrips()},Lt.prototype.createGrip=function(){var St=new gt;return St.visual.transform.baseVal.appendItem(qt.createTransform()),this.controlBox.appendChild(St.visual),St},Lt.prototype.positionGrips=function(){var St=this.grip1.GRIP_SIZE;this.positionGrip(this.grip1.visual,this.x1-St/2,this.y1-St/2),this.positionGrip(this.grip2.visual,this.x2-St/2,this.y2-St/2)},Lt.prototype.positionGrip=function(St,Et,Bt){var yt=St.transform.baseVal.getItem(0);yt.setTranslate(Et,Bt),St.transform.baseVal.replaceItem(yt,0)},Lt.prototype.getState=function(){return Object.assign({x1:this.x1,y1:this.y1,x2:this.x2,y2:this.y2},Rt.prototype.getState.call(this))},Lt.prototype.restoreState=function(St){Rt.prototype.restoreState.call(this,St);var Et=St;this.x1=Et.x1,this.y1=Et.y1,this.x2=Et.x2,this.y2=Et.y2},Lt.prototype.scale=function(St,Et){Rt.prototype.scale.call(this,St,Et),this.x1=this.x1*St,this.y1=this.y1*Et,this.x2=this.x2*St,this.y2=this.y2*Et,this.adjustVisual(),this.adjustControlBox()},Lt}(dt),fe=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.strokeColor="transparent",yt.strokeWidth=0,yt.strokeDasharray="",yt.setStrokeColor=yt.setStrokeColor.bind(yt),yt.setStrokeWidth=yt.setStrokeWidth.bind(yt),yt.setStrokeDasharray=yt.setStrokeDasharray.bind(yt),yt.strokeColor=Bt.defaultColor,yt.strokeWidth=Bt.defaultStrokeWidth,yt.strokeDasharray=Bt.defaultStrokeDasharray,yt.strokePanel=new nt("Line color",Bt.defaultColorSet,Bt.defaultColor),yt.strokePanel.onColorChanged=yt.setStrokeColor,yt.strokeWidthPanel=new Tt("Line width",Bt.defaultStrokeWidths,Bt.defaultStrokeWidth),yt.strokeWidthPanel.onWidthChanged=yt.setStrokeWidth,yt.strokeStylePanel=new Dt("Line style",Bt.defaultStrokeDasharrays,Bt.defaultStrokeDasharray),yt.strokeStylePanel.onStyleChanged=yt.setStrokeDasharray,yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){return!(!Rt.prototype.ownsTarget.call(this,St)&&St!==this.visual&&St!==this.selectorLine&&St!==this.visibleLine)},Lt.prototype.createVisual=function(){this.visual=qt.createGroup(),this.selectorLine=qt.createLine(this.x1,this.y1,this.x2,this.y2,[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()]]),this.visibleLine=qt.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)},Lt.prototype.pointerDown=function(St,Et){Rt.prototype.pointerDown.call(this,St,Et),this.state==="new"&&(this.createVisual(),this.adjustVisual(),this._state="creating")},Lt.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()),qt.setAttributes(this.visibleLine,[["stroke",this.strokeColor]]),qt.setAttributes(this.visibleLine,[["stroke-width",this.strokeWidth.toString()]]),qt.setAttributes(this.visibleLine,[["stroke-dasharray",this.strokeDasharray.toString()]]))},Lt.prototype.setStrokeColor=function(St){this.strokeColor=St,this.adjustVisual(),this.colorChanged(St)},Lt.prototype.setStrokeWidth=function(St){this.strokeWidth=St,this.adjustVisual()},Lt.prototype.setStrokeDasharray=function(St){this.strokeDasharray=St,this.adjustVisual(),this.stateChanged()},Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray},Rt.prototype.getState.call(this));return St.typeName=Lt.typeName,St},Lt.prototype.restoreState=function(St){Rt.prototype.restoreState.call(this,St);var Et=St;this.strokeColor=Et.strokeColor,this.strokeWidth=Et.strokeWidth,this.strokeDasharray=Et.strokeDasharray,this.createVisual(),this.adjustVisual()},Lt.typeName="LineMarker",Lt.title="Line marker",Lt.icon='',Lt}(Yt),Zt=function(Rt){function Lt(St,Et,Bt,yt){var ae=Rt.call(this,St,yt||'')||this;return ae.fonts=[],ae.fontBoxes=[],ae.fonts=Et,ae.currentFont=Bt,ae.setCurrentFont=ae.setCurrentFont.bind(ae),ae}return Ht(Lt,Rt),Lt.prototype.getUi=function(){var St=this,Et=document.createElement("div");return Et.style.overflow="hidden",Et.style.flexGrow="2",this.fonts.forEach(function(Bt){var yt=document.createElement("div");yt.style.display="inline-block",yt.style.alignItems="center",yt.style.justifyContent="space-between",yt.style.padding="5px",yt.style.borderWidth="2px",yt.style.borderStyle="solid",yt.style.overflow="hidden",yt.style.maxWidth=100/St.fonts.length-5+"%",yt.style.borderColor=Bt===St.currentFont?St.uiStyleSettings.toolboxAccentColor:"transparent",yt.addEventListener("click",function(){St.setCurrentFont(Bt,yt)}),Et.appendChild(yt);var ae=document.createElement("div");ae.style.display="flex",ae.style.minHeight="20px",ae.style.flexGrow="2",ae.style.fontFamily=Bt,ae.style.overflow="hidden";var Pe=document.createElement("div");Pe.style.whiteSpace="nowrap",Pe.style.overflow="hidden",Pe.style.textOverflow="ellipsis",Pe.innerHTML="The quick brown fox jumps over the lazy dog",ae.appendChild(Pe),yt.appendChild(ae),St.fontBoxes.push(yt)}),Et},Lt.prototype.setCurrentFont=function(St,Et){var Bt=this;this.currentFont=St,this.fontBoxes.forEach(function(yt){yt.style.borderColor=yt===Et?Bt.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onFontChanged&&this.onFontChanged(this.currentFont)},Lt}(et),je=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.color="transparent",yt.padding=5,yt.DEFAULT_TEXT="\u8BF7\u8F93\u5165\u6587\u672C",yt.text=yt.DEFAULT_TEXT,yt.isMoved=!1,yt.color=Bt.defaultColor,yt.fontFamily=Bt.defaultFontFamily,yt.defaultSize={x:100,y:30},yt.setColor=yt.setColor.bind(yt),yt.setFont=yt.setFont.bind(yt),yt.renderText=yt.renderText.bind(yt),yt.sizeText=yt.sizeText.bind(yt),yt.textEditDivClicked=yt.textEditDivClicked.bind(yt),yt.showTextEditor=yt.showTextEditor.bind(yt),yt.setSize=yt.setSize.bind(yt),yt.positionTextEditor=yt.positionTextEditor.bind(yt),yt.colorPanel=new nt("Color",Bt.defaultColorSet,Bt.defaultColor),yt.colorPanel.onColorChanged=yt.setColor,yt.fontFamilyPanel=new Zt("Font",Bt.defaultFontFamilies,Bt.defaultFontFamily),yt.fontFamilyPanel.onFontChanged=yt.setFont,yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){if(Rt.prototype.ownsTarget.call(this,St)||St===this.visual||St===this.textElement||St===this.bgRectangle)return!0;var Et=!1;return this.textElement.childNodes.forEach(function(Bt){Bt===St&&(Et=!0)}),Et},Lt.prototype.createVisual=function(){this.visual=qt.createGroup(),this.bgRectangle=qt.createRect(1,1,[["fill","transparent"]]),this.visual.appendChild(this.bgRectangle),this.textElement=qt.createText([["fill",this.color],["font-family",this.fontFamily],["font-size","16px"],["x","0"],["y","0"]]),this.textElement.transform.baseVal.appendItem(qt.createTransform()),this.textElement.transform.baseVal.appendItem(qt.createTransform()),this.visual.appendChild(this.textElement),this.addMarkerVisualToContainer(this.visual),this.renderText()},Lt.prototype.pointerDown=function(St,Et){Rt.prototype.pointerDown.call(this,St,Et),this.isMoved=!1,this.pointerDownPoint=St,this.pointerDownTimestamp=Date.now(),this.state==="new"&&(this.createVisual(),this.moveVisual(St),this._state="creating")},Lt.prototype.renderText=function(){var St=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(Et){St.textElement.appendChild(qt.createTSpan(Et.trim()===""?" ":Et.trim(),[["x","0"],["dy","1.2em"]]))}),setTimeout(this.sizeText,10)}},Lt.prototype.getTextScale=function(){var St=this.textElement.getBBox(),Et=1;if(St.width>0&&St.height>0){var Bt=(1*this.width-this.width*this.padding*2/100)/St.width,yt=(1*this.height-this.height*this.padding*2/100)/St.height;Et=Math.min(Bt,yt)}return Et},Lt.prototype.getTextPosition=function(St){var Et=this.textElement.getBBox(),Bt=0,yt=0;return Et.width>0&&Et.height>0&&(Bt=(this.width-Et.width*St)/2,yt=this.height/2-Et.height*St/2),{x:Bt,y:yt}},Lt.prototype.sizeText=function(){var St=this.textElement.getBBox(),Et=this.getTextScale(),Bt=this.getTextPosition(Et);Bt.y-=St.y*Et,navigator.userAgent.indexOf("Edge/")>-1?this.textElement.style.transform="translate("+Bt.x+"px, "+Bt.y+"px) scale("+Et+", "+Et+")":(this.textElement.transform.baseVal.getItem(0).setTranslate(Bt.x,Bt.y),this.textElement.transform.baseVal.getItem(1).setScale(Et,Et))},Lt.prototype.manipulate=function(St){Rt.prototype.manipulate.call(this,St),this.pointerDownPoint!==void 0&&(this.isMoved=Math.abs(St.x-this.pointerDownPoint.x)>5||Math.abs(St.y-this.pointerDownPoint.y)>5)},Lt.prototype.resize=function(St){Rt.prototype.resize.call(this,St),this.isMoved=!0,this.setSize(),this.sizeText()},Lt.prototype.setSize=function(){Rt.prototype.setSize.call(this),this.visual&&this.bgRectangle&&(qt.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),qt.setAttributes(this.bgRectangle,[["width",this.width.toString()],["height",this.height.toString()]]))},Lt.prototype.pointerUp=function(St){var Et=this.state;Et==="creating"&&(this._suppressMarkerCreateEvent=!0),Rt.prototype.pointerUp.call(this,St),this.setSize(),(Et==="creating"||!this.isMoved&&Date.now()-this.pointerDownTimestamp>500)&&this.showTextEditor(),this.pointerDownPoint=void 0},Lt.prototype.showTextEditor=function(){var St=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(Et){Et.stopPropagation()}),this.textEditor.addEventListener("input",function(){for(var Et=Number.parseFloat(St.textEditor.style.fontSize);St.textEditor.clientWidth>=Number.parseInt(St.textEditor.style.maxWidth)&&Et>.9;)Et-=.1,St.textEditor.style.fontSize=Math.max(Et,.9)+"em"}),this.textEditor.addEventListener("keyup",function(Et){Et.cancelBubble=!0}),this.textEditor.addEventListener("paste",function(Et){if(Et.clipboardData){var Bt=Et.clipboardData.getData("text"),yt=window.getSelection();if(!yt.rangeCount)return!1;yt.deleteFromDocument(),yt.getRangeAt(0).insertNode(document.createTextNode(Bt)),Et.preventDefault()}}),this.textEditDiv.addEventListener("pointerup",function(){St.textEditDivClicked(St.textEditor.innerText)}),this.textEditDiv.appendChild(this.textEditor),this.overlayContainer.appendChild(this.textEditDiv),this.hideVisual(),this.textEditor.focus(),document.execCommand("selectAll")},Lt.prototype.positionTextEditor=function(){if(this.state==="edit")if(this.textEditor===void 0)this.showTextEditor();else{this.textElement.style.display="";var St=this.getTextScale(),Et=this.rotatePoint({x:this.left+this.width/2,y:this.top+this.height/2}),Bt=this.textElement.getBBox(),yt={x:Bt.width*St,y:Bt.height*St};Et.x-=yt.x/2,Et.y-=yt.y/2,this.textEditor.style.top=Et.y+"px",this.textEditor.style.left=Et.x+"px",this.textEditor.style.maxWidth=this.overlayContainer.offsetWidth-Et.x+"px",this.textEditor.style.fontSize=Math.max(16*St,12)+"px",this.textElement.style.display="none"}},Lt.prototype.textEditDivClicked=function(St){this.text=St.trim(),this.overlayContainer.innerHTML="",this.renderText(),this.showVisual(),this._suppressMarkerCreateEvent&&(this._suppressMarkerCreateEvent=!1,this.onMarkerCreated&&this.onMarkerCreated(this)),this.stateChanged()},Lt.prototype.select=function(){Rt.prototype.select.call(this),this.state==="edit"&&this.textEditDivClicked(this.textEditor.innerText)},Lt.prototype.deselect=function(){this.state==="edit"&&this.textEditDivClicked(this.textEditor.innerText),Rt.prototype.deselect.call(this)},Lt.prototype.dblClick=function(St,Et){Rt.prototype.dblClick.call(this,St,Et),this.showTextEditor()},Lt.prototype.setColor=function(St){this.textElement&&qt.setAttributes(this.textElement,[["fill",St]]),this.color=St,this.textEditor&&(this.textEditor.style.color=this.color),this.colorChanged(St)},Lt.prototype.setFont=function(St){this.textElement&&qt.setAttributes(this.textElement,[["font-family",St]]),this.fontFamily=St,this.textEditor&&(this.textEditor.style.fontFamily=this.fontFamily),this.renderText(),this.stateChanged()},Lt.prototype.hideVisual=function(){this.textElement.style.display="none",this.hideControlBox()},Lt.prototype.showVisual=function(){this.state==="edit"&&(this._state="select"),this.textElement.style.display="",this.showControlBox()},Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.colorPanel,this.fontFamilyPanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Object.assign({color:this.color,fontFamily:this.fontFamily,padding:this.padding,text:this.text},Rt.prototype.getState.call(this));return St.typeName=Lt.typeName,St},Lt.prototype.restoreState=function(St){var Et=St;this.color=Et.color,this.fontFamily=Et.fontFamily,this.padding=Et.padding,this.text=Et.text,this.createVisual(),Rt.prototype.restoreState.call(this,St),this.setSize()},Lt.prototype.scale=function(St,Et){Rt.prototype.scale.call(this,St,Et),this.setSize(),this.sizeText(),this.positionTextEditor()},Lt.typeName="TextMarker",Lt.title="Text marker",Lt.icon='',Lt}(Pt),me=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.color="transparent",yt.lineWidth=3,yt.drawing=!1,yt.pixelRatio=1,yt.color=Bt.defaultColor,yt.lineWidth=Bt.defaultStrokeWidth,yt.pixelRatio=Bt.freehandPixelRatio,yt.setColor=yt.setColor.bind(yt),yt.addCanvas=yt.addCanvas.bind(yt),yt.finishCreation=yt.finishCreation.bind(yt),yt.setLineWidth=yt.setLineWidth.bind(yt),yt.colorPanel=new nt("Color",Bt.defaultColorSet,Bt.defaultColor),yt.colorPanel.onColorChanged=yt.setColor,yt.lineWidthPanel=new Tt("Line width",Bt.defaultStrokeWidths,Bt.defaultStrokeWidth),yt.lineWidthPanel.onWidthChanged=yt.setLineWidth,yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){return!(!Rt.prototype.ownsTarget.call(this,St)&&St!==this.visual&&St!==this.drawingImage)},Lt.prototype.createVisual=function(){this.visual=qt.createGroup(),this.drawingImage=qt.createImage(),this.visual.appendChild(this.drawingImage);var St=qt.createTransform();this.visual.transform.baseVal.appendItem(St),this.addMarkerVisualToContainer(this.visual)},Lt.prototype.pointerDown=function(St,Et){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(St.x,St.y),this.drawing=!0):Rt.prototype.pointerDown.call(this,St,Et)},Lt.prototype.manipulate=function(St){this.state==="creating"?this.drawing&&(this.canvasContext.lineTo(St.x,St.y),this.canvasContext.stroke()):Rt.prototype.manipulate.call(this,St)},Lt.prototype.resize=function(St){Rt.prototype.resize.call(this,St),qt.setAttributes(this.visual,[["width",this.width.toString()],["height",this.height.toString()]]),qt.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]])},Lt.prototype.pointerUp=function(St){this._state==="creating"?this.drawing&&(this.canvasContext.closePath(),this.drawing=!1,this.globalSettings.newFreehandMarkerOnPointerUp&&this.finishCreation()):Rt.prototype.pointerUp.call(this,St)},Lt.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)},Lt.prototype.select=function(){this.state==="creating"&&this.finishCreation(),Rt.prototype.select.call(this)},Lt.prototype.deselect=function(){this.state==="creating"&&this.finishCreation(),Rt.prototype.deselect.call(this)},Lt.prototype.finishCreation=function(){for(var St=this.canvasContext.getImageData(0,0,this.canvasElement.width,this.canvasElement.height),Et=[this.canvasElement.width+1,this.canvasElement.height+1,-1,-1],Bt=Et[0],yt=Et[1],ae=Et[2],Pe=Et[3],ne=!1,_t=0;_t0&&(ne=!0,_tPe&&(Pe=_t),ge>ae&&(ae=ge));if(ne){this.left=Bt/this.pixelRatio,this.top=yt/this.pixelRatio,this.width=(ae-Bt)/this.pixelRatio,this.height=(Pe-yt)/this.pixelRatio;var pe=document.createElement("canvas");pe.width=ae-Bt,pe.height=Pe-yt,pe.getContext("2d").putImageData(this.canvasContext.getImageData(Bt,yt,ae-Bt,Pe-yt),0,0),this.drawingImgUrl=pe.toDataURL("image/png"),this.setDrawingImage(),this._state="select",this.onMarkerCreated&&this.onMarkerCreated(this)}this.overlayContainer.innerHTML=""},Lt.prototype.setDrawingImage=function(){qt.setAttributes(this.drawingImage,[["width",this.width.toString()],["height",this.height.toString()]]),qt.setAttributes(this.drawingImage,[["href",this.drawingImgUrl]]),this.moveVisual({x:this.left,y:this.top})},Lt.prototype.setColor=function(St){this.color=St,this.colorChanged(St)},Lt.prototype.setLineWidth=function(St){this.lineWidth=St},Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return this.state==="new"||this.state==="creating"?[this.colorPanel,this.lineWidthPanel]:[]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Object.assign({drawingImgUrl:this.drawingImgUrl},Rt.prototype.getState.call(this));return St.typeName=Lt.typeName,St},Lt.prototype.restoreState=function(St){this.createVisual(),Rt.prototype.restoreState.call(this,St),this.drawingImgUrl=St.drawingImgUrl,this.setDrawingImage()},Lt.prototype.scale=function(St,Et){Rt.prototype.scale.call(this,St,Et),this.setDrawingImage()},Lt.typeName="FreehandMarker",Lt.title="Freehand marker",Lt.icon='',Lt}(Pt),Xe=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Bt||'')||this;return yt.typeBoxes=[],yt.currentType=Et,yt.setCurrentType=yt.setCurrentType.bind(yt),yt}return Ht(Lt,Rt),Lt.prototype.getUi=function(){var St=this,Et=document.createElement("div");Et.style.display="flex",Et.style.overflow="hidden",Et.style.flexGrow="2";for(var Bt=function(Pe){var ne="both";switch(Pe){case 0:ne="both";break;case 1:ne="start";break;case 2:ne="end";break;case 3:ne="none"}var _t=document.createElement("div");if(_t.style.display="flex",_t.style.flexGrow="2",_t.style.alignItems="center",_t.style.justifyContent="space-between",_t.style.padding="5px",_t.style.borderWidth="2px",_t.style.borderStyle="solid",_t.style.borderColor=ne===yt.currentType?yt.uiStyleSettings.toolboxAccentColor:"transparent",_t.addEventListener("click",function(){St.setCurrentType(ne,_t)}),Et.appendChild(_t),ne==="both"||ne==="start"){var ge=document.createElement("div");ge.style.display="flex",ge.style.alignItems="center",ge.style.minHeight="20px",ge.innerHTML=` `,ge.style.marginLeft="5px",_t.appendChild(ge)}var pe=document.createElement("div");pe.style.display="flex",pe.style.alignItems="center",pe.style.minHeight="20px",pe.style.flexGrow="2";var le=document.createElement("hr");if(le.style.minWidth="20px",le.style.border="0px",le.style.borderTop="3px solid "+(yt.uiStyleSettings!==void 0?yt.uiStyleSettings.toolboxColor:"#eeeeee"),le.style.flexGrow="2",pe.appendChild(le),_t.appendChild(pe),ne==="both"||ne==="end"){var Me=document.createElement("div");Me.style.display="flex",Me.style.alignItems="center",Me.style.minHeight="20px",Me.innerHTML=` `,Me.style.marginRight="5px",_t.appendChild(Me)}yt.typeBoxes.push(_t)},yt=this,ae=0;ae<4;ae++)Bt(ae);return Et},Lt.prototype.setCurrentType=function(St,Et){var Bt=this;this.currentType=St,this.typeBoxes.forEach(function(yt){yt.style.borderColor=yt===Et?Bt.uiStyleSettings!==void 0?Bt.uiStyleSettings.toolboxAccentColor:"#3080c3":"transparent"}),this.onArrowTypeChanged&&this.onArrowTypeChanged(this.currentType)},Lt}(et),Se=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.arrowType="end",yt.arrowBaseHeight=10,yt.arrowBaseWidth=10,yt.getArrowPoints=yt.getArrowPoints.bind(yt),yt.setArrowType=yt.setArrowType.bind(yt),yt.arrowTypePanel=new Xe("Arrow type","end"),yt.arrowTypePanel.onArrowTypeChanged=yt.setArrowType,yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){return!(!Rt.prototype.ownsTarget.call(this,St)&&St!==this.arrow1&&St!==this.arrow2)},Lt.prototype.getArrowPoints=function(St,Et){var Bt=this.arrowBaseWidth+2*this.strokeWidth,yt=this.arrowBaseHeight+2*this.strokeWidth;return St-Bt/2+","+(Et+yt/2)+" "+St+","+(Et-yt/2)+" "+(St+Bt/2)+","+(Et+yt/2)},Lt.prototype.createTips=function(){this.arrow1=qt.createPolygon(this.getArrowPoints(this.x1,this.y1),[["fill",this.strokeColor]]),this.arrow1.transform.baseVal.appendItem(qt.createTransform()),this.visual.appendChild(this.arrow1),this.arrow2=qt.createPolygon(this.getArrowPoints(this.x2,this.y2),[["fill",this.strokeColor]]),this.arrow2.transform.baseVal.appendItem(qt.createTransform()),this.visual.appendChild(this.arrow2)},Lt.prototype.pointerDown=function(St,Et){Rt.prototype.pointerDown.call(this,St,Et),this.state==="creating"&&this.createTips()},Lt.prototype.adjustVisual=function(){if(Rt.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",qt.setAttributes(this.arrow1,[["points",this.getArrowPoints(this.x1,this.y1)],["fill",this.strokeColor]]),qt.setAttributes(this.arrow2,[["points",this.getArrowPoints(this.x2,this.y2)],["fill",this.strokeColor]]);var St=0;Math.abs(this.x1-this.x2)>.1&&(St=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2));var Et=this.arrow1.transform.baseVal.getItem(0);Et.setRotate(St,this.x1,this.y1),this.arrow1.transform.baseVal.replaceItem(Et,0);var Bt=this.arrow2.transform.baseVal.getItem(0);Bt.setRotate(St+180,this.x2,this.y2),this.arrow2.transform.baseVal.replaceItem(Bt,0)}},Lt.prototype.setArrowType=function(St){this.arrowType=St,this.adjustVisual(),this.stateChanged()},Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel,this.arrowTypePanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Object.assign({arrowType:this.arrowType},Rt.prototype.getState.call(this));return St.typeName=Lt.typeName,St},Lt.prototype.restoreState=function(St){Rt.prototype.restoreState.call(this,St);var Et=St;this.arrowType=Et.arrowType,this.createTips(),this.adjustVisual()},Lt.typeName="ArrowMarker",Lt.title="Arrow marker",Lt.icon='',Lt}(fe),Ie=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.fillColor=Bt.defaultFillColor,yt.strokeWidth=0,yt.fillPanel=new nt("Color",Bt.defaultColorSet,Bt.defaultFillColor),yt.fillPanel.onColorChanged=yt.setFillColor,yt}return Ht(Lt,Rt),Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.fillPanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Rt.prototype.getState.call(this);return St.typeName=Lt.typeName,St},Lt.typeName="CoverMarker",Lt.title="Cover marker",Lt.icon='',Lt}(kt),ze=function(Rt){function Lt(St,Et,Bt,yt){var ae=Rt.call(this,St,yt||'')||this;return ae.opacities=[],ae.opacityBoxes=[],ae.opacities=Et,ae.currentOpacity=Bt,ae.setCurrentOpacity=ae.setCurrentOpacity.bind(ae),ae}return Ht(Lt,Rt),Lt.prototype.getUi=function(){var St=this,Et=document.createElement("div");return Et.style.display="flex",Et.style.overflow="hidden",Et.style.flexGrow="2",Et.style.justifyContent="space-between",this.opacities.forEach(function(Bt){var yt=document.createElement("div");yt.style.display="flex",yt.style.alignItems="center",yt.style.justifyContent="center",yt.style.padding="5px",yt.style.borderWidth="2px",yt.style.borderStyle="solid",yt.style.borderColor=Bt===St.currentOpacity?St.uiStyleSettings.toolboxAccentColor:"transparent",yt.addEventListener("click",function(){St.setCurrentOpacity(Bt,yt)}),Et.appendChild(yt);var ae=document.createElement("div");ae.innerText=100*Bt+"%",yt.appendChild(ae),St.opacityBoxes.push(yt)}),Et},Lt.prototype.setCurrentOpacity=function(St,Et){var Bt=this;this.currentOpacity=St,this.opacityBoxes.forEach(function(yt){yt.style.borderColor=yt===Et?Bt.uiStyleSettings.toolboxAccentColor:"transparent"}),this.onOpacityChanged&&this.onOpacityChanged(this.currentOpacity)},Lt}(et),Ue=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.setOpacity=yt.setOpacity.bind(yt),yt.fillColor=Bt.defaultHighlightColor,yt.strokeWidth=0,yt.opacity=Bt.defaultHighlightOpacity,yt.fillPanel=new nt("Color",Bt.defaultColorSet,yt.fillColor),yt.fillPanel.onColorChanged=yt.setFillColor,yt.opacityPanel=new ze("Opacity",Bt.defaultOpacitySteps,yt.opacity),yt.opacityPanel.onOpacityChanged=yt.setOpacity,yt}return Ht(Lt,Rt),Lt.prototype.setOpacity=function(St){this.opacity=St,this.visual&&qt.setAttributes(this.visual,[["opacity",this.opacity.toString()]]),this.stateChanged()},Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.fillPanel,this.opacityPanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Rt.prototype.getState.call(this);return St.typeName=Lt.typeName,St},Lt.typeName="HighlightMarker",Lt.title="Highlight marker",Lt.icon='',Lt}(Ie),se='',jt='',$e=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.bgColor="transparent",yt.tipPosition={x:0,y:0},yt.tipBase1Position={x:0,y:0},yt.tipBase2Position={x:0,y:0},yt.tipMoving=!1,yt.color=Bt.defaultStrokeColor,yt.bgColor=Bt.defaultFillColor,yt.fontFamily=Bt.defaultFontFamily,yt.defaultSize={x:100,y:30},yt.setBgColor=yt.setBgColor.bind(yt),yt.getTipPoints=yt.getTipPoints.bind(yt),yt.positionTip=yt.positionTip.bind(yt),yt.setTipPoints=yt.setTipPoints.bind(yt),yt.colorPanel=new nt("Text color",Bt.defaultColorSet,yt.color,se),yt.colorPanel.onColorChanged=yt.setColor,yt.bgColorPanel=new nt("Fill color",Bt.defaultColorSet,yt.bgColor,jt),yt.bgColorPanel.onColorChanged=yt.setBgColor,yt.fontFamilyPanel=new Zt("Font",Bt.defaultFontFamilies,Bt.defaultFontFamily),yt.fontFamilyPanel.onFontChanged=yt.setFont,yt.tipGrip=new gt,yt.tipGrip.visual.transform.baseVal.appendItem(qt.createTransform()),yt.controlBox.appendChild(yt.tipGrip.visual),yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){return Rt.prototype.ownsTarget.call(this,St)||this.tipGrip.ownsTarget(St)||this.tip===St},Lt.prototype.createTip=function(){qt.setAttributes(this.bgRectangle,[["fill",this.bgColor],["rx","10px"]]),this.tip=qt.createPolygon(this.getTipPoints(),[["fill",this.bgColor]]),this.visual.appendChild(this.tip)},Lt.prototype.pointerDown=function(St,Et){this.state==="new"&&Rt.prototype.pointerDown.call(this,St,Et),this.state==="creating"?this.createTip():this.tipGrip.ownsTarget(Et)?(this.manipulationStartLeft=this.left,this.manipulationStartTop=this.top,this.tipMoving=!0):Rt.prototype.pointerDown.call(this,St,Et)},Lt.prototype.pointerUp=function(St){if(this.tipMoving)this.tipMoving=!1,this.isMoved=!0,Rt.prototype.pointerUp.call(this,St);else{var Et=this.state==="creating";Rt.prototype.pointerUp.call(this,St),this.setTipPoints(Et),this.positionTip()}},Lt.prototype.manipulate=function(St){if(this.tipMoving){var Et=this.unrotatePoint(St);this.tipPosition={x:Et.x-this.manipulationStartLeft,y:Et.y-this.manipulationStartTop},this.positionTip()}else Rt.prototype.manipulate.call(this,St)},Lt.prototype.setBgColor=function(St){this.bgRectangle&&this.tip&&(qt.setAttributes(this.bgRectangle,[["fill",St]]),qt.setAttributes(this.tip,[["fill",St]])),this.bgColor=St,this.fillColorChanged(St)},Lt.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},Lt.prototype.setTipPoints=function(St){St===void 0&&(St=!1);var Et=Math.min(this.height/2,15),Bt=this.height/5;St&&(this.tipPosition={x:Et+Bt/2,y:this.height+20});var yt=Math.atan(this.height/2/(this.width/2));this.tipPosition.x=this.width/2&&this.tipPosition.y=this.width/2&&this.tipPosition.y>=this.height/2?yt.1)){var St=180*Math.atan((this.y2-this.y1)/(this.x2-this.x1))/Math.PI+90*Math.sign(this.x1-this.x2),Et=this.tip1.transform.baseVal.getItem(0);Et.setRotate(St,this.x1,this.y1),this.tip1.transform.baseVal.replaceItem(Et,0);var Bt=this.tip2.transform.baseVal.getItem(0);Bt.setRotate(St+180,this.x2,this.y2),this.tip2.transform.baseVal.replaceItem(Bt,0)}},Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Rt.prototype.getState.call(this);return St.typeName=Lt.typeName,St},Lt.prototype.restoreState=function(St){Rt.prototype.restoreState.call(this,St),this.createTips(),this.adjustVisual()},Lt.typeName="MeasurementMarker",Lt.title="Measurement marker",Lt.icon='',Lt}(fe),Ne=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.strokePanel.colors=Bt.defaultColorSet,yt.fillColor="transparent",yt}return Ht(Lt,Rt),Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Rt.prototype.getState.call(this);return St.typeName=Lt.typeName,St},Lt.typeName="EllipseFrameMarker",Lt.title="Ellipse frame marker",Lt.icon='',Lt}(xn),Ze=function(){function Rt(){this.undoStack=[],this.redoStack=[]}return Object.defineProperty(Rt.prototype,"isUndoPossible",{get:function(){return this.undoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"isRedoPossible",{get:function(){return this.redoStack.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"undoStepCount",{get:function(){return this.undoStack.length},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"redoStepCount",{get:function(){return this.redoStack.length},enumerable:!1,configurable:!0}),Rt.prototype.addUndoStep=function(Lt){this.undoStack.length!==0&&JSON.stringify(this.undoStack[this.undoStack.length-1])===JSON.stringify(Lt)||(this.undoStack.push(Lt),JSON.stringify(this.lastRedoStep)!==JSON.stringify(Lt)&&this.redoStack.splice(0,this.redoStack.length))},Rt.prototype.replaceLastUndoStep=function(Lt){this.undoStack.length>0&&(this.undoStack[this.undoStack.length-1]=Lt)},Rt.prototype.getLastUndoStep=function(){return this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0},Rt.prototype.undo=function(){if(this.undoStack.length>1){var Lt=this.undoStack.pop();return Lt!==void 0&&this.redoStack.push(Lt),this.undoStack.length>0?this.undoStack[this.undoStack.length-1]:void 0}},Rt.prototype.redo=function(){return this.lastRedoStep=this.redoStack.pop(),this.lastRedoStep},Rt}(),rn=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.strokeColor="transparent",yt.strokeWidth=0,yt.strokeDasharray="",yt.curveX=0,yt.curveY=0,yt.manipulationStartCurveX=0,yt.manipulationStartCurveY=0,yt.setStrokeColor=yt.setStrokeColor.bind(yt),yt.setStrokeWidth=yt.setStrokeWidth.bind(yt),yt.setStrokeDasharray=yt.setStrokeDasharray.bind(yt),yt.positionGrips=yt.positionGrips.bind(yt),yt.addControlGrips=yt.addControlGrips.bind(yt),yt.adjustVisual=yt.adjustVisual.bind(yt),yt.setupControlBox=yt.setupControlBox.bind(yt),yt.resize=yt.resize.bind(yt),yt.strokeColor=Bt.defaultColor,yt.strokeWidth=Bt.defaultStrokeWidth,yt.strokeDasharray=Bt.defaultStrokeDasharray,yt.strokePanel=new nt("Line color",Bt.defaultColorSet,Bt.defaultColor),yt.strokePanel.onColorChanged=yt.setStrokeColor,yt.strokeWidthPanel=new Tt("Line width",Bt.defaultStrokeWidths,Bt.defaultStrokeWidth),yt.strokeWidthPanel.onWidthChanged=yt.setStrokeWidth,yt.strokeStylePanel=new Dt("Line style",Bt.defaultStrokeDasharrays,Bt.defaultStrokeDasharray),yt.strokeStylePanel.onStyleChanged=yt.setStrokeDasharray,yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){return!(!Rt.prototype.ownsTarget.call(this,St)&&St!==this.visual&&St!==this.selectorCurve&&St!==this.visibleCurve&&!this.curveGrip.ownsTarget(St))},Lt.prototype.getPathD=function(){return"M "+this.x1+" "+this.y1+" Q "+this.curveX+" "+this.curveY+", "+this.x2+" "+this.y2},Lt.prototype.createVisual=function(){this.visual=qt.createGroup(),this.selectorCurve=qt.createPath(this.getPathD(),[["stroke","transparent"],["stroke-width",(this.strokeWidth+10).toString()],["fill","transparent"]]),this.visibleCurve=qt.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)},Lt.prototype.pointerDown=function(St,Et){Rt.prototype.pointerDown.call(this,St,Et),this.manipulationStartCurveX=this.curveX,this.manipulationStartCurveY=this.curveY,this.state==="new"&&(this.curveX=St.x,this.curveY=St.y),this.state==="new"?(this.createVisual(),this.adjustVisual(),this._state="creating"):this.curveGrip.ownsTarget(Et)&&(this.activeGrip=this.curveGrip,this._state="resize")},Lt.prototype.adjustVisual=function(){this.selectorCurve&&this.visibleCurve&&(this.selectorCurve.setAttribute("d",this.getPathD()),this.visibleCurve.setAttribute("d",this.getPathD()),qt.setAttributes(this.visibleCurve,[["stroke",this.strokeColor]]),qt.setAttributes(this.visibleCurve,[["stroke-width",this.strokeWidth.toString()]]),qt.setAttributes(this.visibleCurve,[["stroke-dasharray",this.strokeDasharray.toString()]]))},Lt.prototype.setupControlBox=function(){Rt.prototype.setupControlBox.call(this),this.curveControlLine1=qt.createLine(this.x1,this.y1,this.curveX,this.curveY,[["stroke","black"],["stroke-width","1"],["stroke-opacity","0.5"],["stroke-dasharray","3, 2"]]),this.curveControlLine2=qt.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)},Lt.prototype.addControlGrips=function(){this.curveGrip=this.createGrip(),this.curveX=0,this.curveY=0,Rt.prototype.addControlGrips.call(this)},Lt.prototype.positionGrips=function(){Rt.prototype.positionGrips.call(this);var St=this.curveGrip.GRIP_SIZE;this.positionGrip(this.curveGrip.visual,this.curveX-St/2,this.curveY-St/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()))},Lt.prototype.manipulate=function(St){this.state==="move"&&(this.curveX=this.manipulationStartCurveX+St.x-this.manipulationStartX,this.curveY=this.manipulationStartCurveY+St.y-this.manipulationStartY),Rt.prototype.manipulate.call(this,St)},Lt.prototype.resize=function(St){this.activeGrip===this.curveGrip&&(this.curveX=St.x,this.curveY=St.y),Rt.prototype.resize.call(this,St),this.state==="creating"&&(this.curveX=this.x1+(this.x2-this.x1)/2,this.curveY=this.y1+(this.y2-this.y1)/2)},Lt.prototype.setStrokeColor=function(St){this.strokeColor=St,this.adjustVisual(),this.colorChanged(St)},Lt.prototype.setStrokeWidth=function(St){this.strokeWidth=St,this.adjustVisual()},Lt.prototype.setStrokeDasharray=function(St){this.strokeDasharray=St,this.adjustVisual()},Lt.prototype.scale=function(St,Et){this.curveX=this.curveX*St,this.curveY=this.curveY*Et,Rt.prototype.scale.call(this,St,Et)},Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.strokeWidthPanel,this.strokeStylePanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=Object.assign({strokeColor:this.strokeColor,strokeWidth:this.strokeWidth,strokeDasharray:this.strokeDasharray,curveX:this.curveX,curveY:this.curveY},Rt.prototype.getState.call(this));return St.typeName=Lt.typeName,St},Lt.prototype.restoreState=function(St){Rt.prototype.restoreState.call(this,St);var Et=St;this.strokeColor=Et.strokeColor,this.strokeWidth=Et.strokeWidth,this.strokeDasharray=Et.strokeDasharray,this.curveX=Et.curveX,this.curveY=Et.curveY,this.createVisual(),this.adjustVisual()},Lt.typeName="CurveMarker",Lt.title="Curve marker",Lt.icon='',Lt}(Yt),zn=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,Et,Bt)||this;return yt.fillColor="transparent",yt.strokeColor="transparent",yt.strokeWidth=0,yt.strokeDasharray="",yt.textColor="transparent",yt.fontSize="1rem",yt.isMoved=!1,yt.captionText="Caption",yt.PADDING=5,yt.captionBoxWidth=0,yt.captionBoxHeight=0,yt.strokeColor=Bt.defaultColor,yt.strokeWidth=Bt.defaultStrokeWidth,yt.strokeDasharray=Bt.defaultStrokeDasharray,yt.fillColor=Bt.defaultFillColor,yt.textColor=Bt.defaultStrokeColor,yt.fontFamily=Bt.defaultFontFamily,yt.fontSize=Bt.defaultCaptionFontSize,yt.captionText=Bt.defaultCaptionText,yt.setStrokeColor=yt.setStrokeColor.bind(yt),yt.setFillColor=yt.setFillColor.bind(yt),yt.setStrokeWidth=yt.setStrokeWidth.bind(yt),yt.setStrokeDasharray=yt.setStrokeDasharray.bind(yt),yt.createVisual=yt.createVisual.bind(yt),yt.sizeCaption=yt.sizeCaption.bind(yt),yt.setCaptionText=yt.setCaptionText.bind(yt),yt.showTextEditor=yt.showTextEditor.bind(yt),yt.positionTextEditor=yt.positionTextEditor.bind(yt),yt.finishTextEditing=yt.finishTextEditing.bind(yt),yt.setFont=yt.setFont.bind(yt),yt.setTextColor=yt.setTextColor.bind(yt),yt.strokePanel=new nt("Line color",Vt(Bt.defaultColorSet,["transparent"]),yt.strokeColor),yt.strokePanel.onColorChanged=yt.setStrokeColor,yt.fillPanel=new nt("Fill color",Vt(Bt.defaultColorSet,["transparent"]),yt.fillColor,jt),yt.fillPanel.onColorChanged=yt.setFillColor,yt.strokeWidthPanel=new Tt("Line width",Bt.defaultStrokeWidths,Bt.defaultStrokeWidth),yt.strokeWidthPanel.onWidthChanged=yt.setStrokeWidth,yt.strokeStylePanel=new Dt("Line style",Bt.defaultStrokeDasharrays,Bt.defaultStrokeDasharray),yt.strokeStylePanel.onStyleChanged=yt.setStrokeDasharray,yt.fontFamilyPanel=new Zt("Font",Bt.defaultFontFamilies,Bt.defaultFontFamily),yt.fontFamilyPanel.onFontChanged=yt.setFont,yt.textColorPanel=new nt("Text color",Bt.defaultColorSet,yt.textColor,se),yt.textColorPanel.onColorChanged=yt.setTextColor,yt}return Ht(Lt,Rt),Lt.prototype.ownsTarget=function(St){return!(!Rt.prototype.ownsTarget.call(this,St)&&St!==this.visual&&St!==this.frame&&St!==this.captionBg&&St!==this.captionElement)},Lt.prototype.createVisual=function(){this.visual=qt.createGroup(),this.addMarkerVisualToContainer(this.visual),this.captionBg=qt.createRect(1,1,[["fill",this.fillColor]]),this.visual.appendChild(this.captionBg),this.captionElement=qt.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=qt.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()},Lt.prototype.setCaptionText=function(St){this.captionText=St,this.captionElement.textContent=this.captionText,this.sizeCaption()},Lt.prototype.pointerDown=function(St,Et){Rt.prototype.pointerDown.call(this,St,Et),this.isMoved=!1,this.pointerDownPoint=St,this.pointerDownTimestamp=Date.now(),this.state==="new"&&(this.createVisual(),this.moveVisual(St),this._state="creating")},Lt.prototype.manipulate=function(St){Rt.prototype.manipulate.call(this,St),this.pointerDownPoint!==void 0&&(this.isMoved=Math.abs(St.x-this.pointerDownPoint.x)>5||Math.abs(St.y-this.pointerDownPoint.y)>5)},Lt.prototype.resize=function(St){Rt.prototype.resize.call(this,St),this.setSize()},Lt.prototype.sizeCaption=function(){var St=this.captionElement.getBBox();this.captionText.trim()!==""?(this.captionBoxWidth=St.width+2*this.PADDING,this.captionBoxHeight=St.height+2*this.PADDING):(this.captionBoxWidth=0,this.captionBoxHeight=0),qt.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')"]]),qt.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')"]])},Lt.prototype.showTextEditor=function(){var St=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(Et){Et.stopPropagation()}),this.textEditBox.addEventListener("keypress",function(Et){Et.key==="Enter"&&St.finishTextEditing(St.textEditBox.value)}),this.textEditBox.addEventListener("keyup",function(Et){Et.cancelBubble=!0}),this.textEditBox.addEventListener("blur",function(){St.finishTextEditing(St.textEditBox.value)}),this.textEditDiv.addEventListener("pointerup",function(){St.finishTextEditing(St.textEditBox.value)}),this.positionTextEditor(),this.textEditBox.focus()},Lt.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"))},Lt.prototype.finishTextEditing=function(St){this.setCaptionText(St.trim()),this.overlayContainer.innerHTML="",this.stateChanged()},Lt.prototype.setFont=function(St){this.captionElement&&qt.setAttributes(this.captionElement,[["font-family",St]]),this.fontFamily=St,this.textEditBox&&(this.textEditBox.style.fontFamily=this.fontFamily),this.sizeCaption(),this.stateChanged()},Lt.prototype.setTextColor=function(St){this.captionElement&&qt.setAttributes(this.captionElement,[["fill",St]]),this.textColor=St,this.textEditBox&&(this.textEditBox.style.color=this.textColor),this.stateChanged()},Lt.prototype.setSize=function(){Rt.prototype.setSize.call(this),qt.setAttributes(this.frame,[["width",this.width.toString()],["height",this.height.toString()]]),this.sizeCaption()},Lt.prototype.pointerUp=function(St){Rt.prototype.pointerUp.call(this,St),this.setSize(),!this.isMoved&&Date.now()-this.pointerDownTimestamp>500&&this.showTextEditor(),this.pointerDownPoint=void 0},Lt.prototype.dblClick=function(St,Et){Rt.prototype.dblClick.call(this,St,Et),this.showTextEditor()},Lt.prototype.setStrokeColor=function(St){this.strokeColor=St,this.frame&&qt.setAttributes(this.frame,[["stroke",this.strokeColor]]),this.colorChanged(St),this.stateChanged()},Lt.prototype.setFillColor=function(St){this.fillColor=St,this.captionBg&&qt.setAttributes(this.captionBg,[["fill",this.fillColor]]),this.fillColorChanged(St),this.stateChanged()},Lt.prototype.setStrokeWidth=function(St){this.strokeWidth=St,this.frame&&qt.setAttributes(this.frame,[["stroke-width",this.strokeWidth.toString()]]),this.stateChanged()},Lt.prototype.setStrokeDasharray=function(St){this.strokeDasharray=St,this.frame&&qt.setAttributes(this.frame,[["stroke-dasharray",this.strokeDasharray]]),this.stateChanged()},Object.defineProperty(Lt.prototype,"toolboxPanels",{get:function(){return[this.strokePanel,this.fillPanel,this.strokeWidthPanel,this.strokeStylePanel,this.fontFamilyPanel,this.textColorPanel]},enumerable:!1,configurable:!0}),Lt.prototype.getState=function(){var St=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},Rt.prototype.getState.call(this));return St.typeName=this.typeName,St},Lt.prototype.restoreState=function(St){var Et=St;this.fillColor=Et.fillColor,this.strokeColor=Et.strokeColor,this.strokeWidth=Et.strokeWidth,this.strokeDasharray=Et.strokeDasharray,this.textColor=Et.textColor,this.fontFamily=Et.fontFamily,this.captionText=Et.captionText,this.fontSize=Et.fontSize,this.createVisual(),Rt.prototype.restoreState.call(this,St),this.setSize()},Lt.prototype.scale=function(St,Et){Rt.prototype.scale.call(this,St,Et),this.setSize()},Lt.typeName="CaptionFrameMarker",Lt.title="Caption frame marker",Lt.icon='',Lt}(Pt),tn=function(){function Rt(Lt,St){St===void 0&&(St=!1),this.cancelable=!1,this._defaultPrevented=!1,this.markerArea=Lt,this.cancelable=St}return Object.defineProperty(Rt.prototype,"defaultPrevented",{get:function(){return this._defaultPrevented},enumerable:!1,configurable:!0}),Rt.prototype.preventDefault=function(){this._defaultPrevented=!0},Rt}(),Tn=function(Rt){function Lt(St,Et,Bt){var yt=Rt.call(this,St,!1)||this;return yt.dataUrl=Et,yt.state=Bt,yt}return Ht(Lt,Rt),Lt}(tn),we=function(Rt){function Lt(St,Et,Bt){Bt===void 0&&(Bt=!1);var yt=Rt.call(this,St,Bt)||this;return yt.marker=Et,yt}return Ht(Lt,Rt),Lt}(tn),Bn=function(){function Rt(){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 Rt.prototype.addEventListener=function(Lt,St){this[Lt].push(St)},Rt.prototype.removeEventListener=function(Lt,St){var Et=this[Lt].indexOf(St);Et>-1&&this[Lt].splice(Et,1)},Rt}(),Jn=function(){function Rt(Lt){this.touchPoints=0,this._availableMarkerTypes=this.DEFAULT_MARKER_TYPES,this.mode="select",this.markers=[],this.isDragging=!1,this.renderEventListeners=[],this.closeEventListeners=[],this.settings=new ie,this._isOpen=!1,this.undoRedoManager=new Ze,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 Bn,this._silentRenderMode=!1,this._isFocused=!1,this._instanceNo=Rt.instanceCounter++,this.styles=new Qt(this.instanceNo),this.uiStyleSettings=this.styles.settings,this.target=Lt,this.targetRoot=document.body,this.width=Lt.clientWidth,this.height=Lt.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(Rt.prototype,"ALL_MARKER_TYPES",{get:function(){return[$t,me,Se,je,Ne,xn,Ue,$e,En,Ie,fe,rn,zn]},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"DEFAULT_MARKER_TYPES",{get:function(){return[$t,me,Se,je,xn,Ue,$e]},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"BASIC_MARKER_TYPES",{get:function(){return[$t,me,Se,je,Ue]},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"availableMarkerTypes",{get:function(){return this._availableMarkerTypes},set:function(Lt){var St=this;this._availableMarkerTypes.splice(0),Lt.forEach(function(Et){if(typeof Et=="string"){var Bt=St.ALL_MARKER_TYPES.find(function(yt){return yt.typeName===Et});Bt!==void 0&&St._availableMarkerTypes.push(Bt)}else St._availableMarkerTypes.push(Et)})},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"currentMarker",{get:function(){return this._currentMarker},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"isOpen",{get:function(){return this._isOpen},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"isUndoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isUndoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"isRedoPossible",{get:function(){return!(!this.undoRedoManager||!this.undoRedoManager.isRedoPossible)},enumerable:!1,configurable:!0}),Object.defineProperty(Rt.prototype,"zoomLevel",{get:function(){return this._zoomLevel},set:function(Lt){this._zoomLevel=Lt,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(Rt.prototype,"instanceNo",{get:function(){return this._instanceNo},enumerable:!1,configurable:!0}),Rt.prototype.open=function(){this.setupResizeObserver(),this.setEditingTarget(),this.setTopLeft(),this.initMarkerCanvas(),this.initOverlay(),this.attachEvents(),this.settings.displayMode==="popup"&&this.onPopupTargetResize(),Nt.isLicensed||this.addLogo(),this._isOpen=!0,this._isFocused=!0},Rt.prototype.show=function(){var Lt=this;this.styles.styleSheetRoot===void 0&&be.styleSheetRoot!==void 0&&(this.styles.styleSheetRoot=be.styleSheetRoot),this.setWindowHeight(),this.showUI(),this.open(),this.eventListeners.show.forEach(function(St){return St(new tn(Lt))})},Rt.prototype.render=function(){return oe(this,void 0,void 0,function(){var Lt;return ke(this,function(St){switch(St.label){case 0:return this.setCurrentMarker(),(Lt=new Oe).naturalSize=this.renderAtNaturalSize,Lt.imageType=this.renderImageType,Lt.imageQuality=this.renderImageQuality,Lt.markersOnly=this.renderMarkersOnly,Lt.width=this.renderWidth,Lt.height=this.renderHeight,[4,Lt.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 1:return St.sent(),[4,Lt.rasterize(this.target instanceof HTMLImageElement?this.target:null,this.markerImage,this.renderTarget)];case 2:return[2,St.sent()]}})})},Rt.prototype.close=function(Lt){var St=this;if(Lt===void 0&&(Lt=!1),this.isOpen){var Et=!1;Lt||this.eventListeners.beforeclose.forEach(function(Bt){var yt=new tn(St,!0);Bt(yt),yt.defaultPrevented&&(Et=!0)}),Et||(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(Bt){return Bt(new tn(St))}),this.detachEvents(),this._isOpen=!1)}},Rt.prototype.addMarkersToToolbar=function(){for(var Lt,St=[],Et=0;Etthis.editorCanvas.clientHeight?this.editorCanvas.clientHeight*Lt:this.editorCanvas.clientWidth,Et=St',Lt.title="Powered by marker.js",Lt.style.display="grid",Lt.style.alignItems="center",Lt.style.justifyItems="center",Lt.style.padding="3px",Lt.style.width="20px",Lt.style.height="20px",this.logoUI.appendChild(Lt),this.editorCanvas.appendChild(this.logoUI),this.logoUI.style.position="absolute",this.logoUI.style.pointerEvents="all",this.positionLogo()},Rt.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")},Rt.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"},Rt.prototype.restoreOverflow=function(){document.body.style.overflow=this.bodyOverflowState,window.scroll({top:this.scrollYState,left:this.scrollXState})},Rt.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 Lt=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=Lt+"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 Re(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-1&&this.markers.splice(this.markers.indexOf(Lt),1),Lt.dispose()},Rt.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())},Rt.prototype.toolbarButtonClicked=function(Lt,St){if(Lt==="marker"&&St!==void 0)this.createNewMarker(St);else if(Lt==="action")switch(St){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()}},Rt.prototype.deleteSelectedMarker=function(){var Lt=this;if(this._currentMarker!==void 0){var St=!1;if(this.eventListeners.markerbeforedelete.forEach(function(Bt){var yt=new we(Lt,Lt._currentMarker,!0);Bt(yt),yt.defaultPrevented&&(St=!0)}),!St){var Et=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(Bt){return Bt(new we(Lt,Et))})}}},Rt.prototype.clear=function(){var Lt=this,St=!1;if(this.markers.length>0&&(this.eventListeners.markerbeforedelete.forEach(function(ae){var Pe=new we(Lt,void 0,!0);ae(Pe),Pe.defaultPrevented&&(St=!0)}),!St)){this.setCurrentMarker();for(var Et=function(ae){var Pe=Bt.markers[ae];Bt.setCurrentMarker(Bt.markers[ae]),Bt._currentMarker.dispose(),Bt.markerImage.removeChild(Bt._currentMarker.container),Bt.markers.splice(Bt.markers.indexOf(Bt._currentMarker),1),Bt.eventListeners.markerdelete.forEach(function(ne){return ne(new we(Lt,Pe))})},Bt=this,yt=this.markers.length-1;yt>=0;yt--)Et(yt);this.addUndoStep()}},Object.defineProperty(Rt.prototype,"isNotesAreaOpen",{get:function(){return this.notesArea!==void 0},enumerable:!1,configurable:!0}),Rt.prototype.showNotesEditor=function(){var Lt;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=(Lt=this._currentMarker.notes)!==null&&Lt!==void 0?Lt:"",this.overlayContainer.appendChild(this.notesArea))},Rt.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)},Rt.prototype.selectLastMarker=function(){this.markers.length>0?this.setCurrentMarker(this.markers[this.markers.length-1]):this.setCurrentMarker()},Rt.prototype.addUndoStep=function(){var Lt=this;if(this._currentMarker===void 0||this._currentMarker.state!=="edit"){var St=this.getState(),Et=this.undoRedoManager.getLastUndoStep();if(!Et||Et.width===St.width&&Et.height===St.height){var Bt=this.undoRedoManager.undoStepCount;this.undoRedoManager.addUndoStep(St),Bt1&&this.panTo({x:Lt.clientX,y:Lt.clientY}))},Rt.prototype.onPointerUp=function(Lt){this.touchPoints>0&&this.touchPoints--,this.touchPoints===0&&this.isDragging&&this._currentMarker!==void 0&&this._currentMarker.pointerUp(this.clientToLocalCoordinates(Lt.clientX,Lt.clientY)),this.isDragging=!1,this.addUndoStep()},Rt.prototype.onPointerOut=function(){this.touchPoints>0&&this.touchPoints--},Rt.prototype.onKeyUp=function(Lt){this._currentMarker===void 0||this.notesArea!==void 0||Lt.key!=="Delete"&&Lt.key!=="Backspace"||this.deleteSelectedMarker()},Rt.prototype.clientToLocalCoordinates=function(Lt,St){var Et=this.markerImage.getBoundingClientRect();return{x:(Lt-Et.left)/this.zoomLevel,y:(St-Et.top)/this.zoomLevel}},Rt.prototype.onWindowResize=function(){this.positionUI()},Rt.prototype.positionUI=function(){switch(this.setTopLeft(),this.settings.displayMode){case"inline":var Lt=this.target.getClientRects().item(0).y>this.styles.settings.toolbarHeight?this.target.offsetTop-this.styles.settings.toolbarHeight:0;this.coverDiv.style.top=Lt+"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()},Rt.prototype.addLicenseKey=function(Lt){Nt.addKey(Lt)},Rt.prototype.addEventListener=function(Lt,St){this.eventListeners.addEventListener(Lt,St)},Rt.prototype.removeEventListener=function(Lt,St){this.eventListeners.removeEventListener(Lt,St)},Rt.prototype.renderState=function(Lt){this._silentRenderMode=!0,this.settings.displayMode="inline",this.isOpen||this.show(),this.restoreState(Lt),this.startRenderAndClose(),this._silentRenderMode=!1},Object.defineProperty(Rt.prototype,"isFocused",{get:function(){return this._isFocused},enumerable:!1,configurable:!0}),Rt.prototype.focus=function(){var Lt=this;this._isFocused||(this.attachWindowEvents(),this._isFocused=!0,this._previousCurrentMarker!==void 0&&this.setCurrentMarker(this._previousCurrentMarker),this.eventListeners.focus.forEach(function(St){return St(new tn(Lt))}))},Rt.prototype.blur=function(){var Lt=this;this._isFocused&&(this.detachWindowEvents(),this._isFocused=!1,this._previousCurrentMarker=this._currentMarker,this.setCurrentMarker(),this.eventListeners.blur.forEach(function(St){return St(new tn(Lt))}))},Rt.instanceCounter=0,Rt}()},17115:function(Cn,cn,wt){"use strict";wt.d(cn,{ZP:function(){return Nt}});var Ft=wt(72071),Ht=wt(59301),oe=wt(47273),ke=0,Vt=(0,oe.Z)();function qt(){var Oe;return Vt?(Oe=ke,ke+=1):Oe="TEST_OR_SSR",Oe}function Nt(Oe){var be=Ht.useState(),Qt=(0,Ft.Z)(be,2),Fe=Qt[0],ye=Qt[1];return Ht.useEffect(function(){ye("rc_select_".concat(qt()))},[]),Oe||Fe}},77861:function(Cn,cn,wt){"use strict";wt.d(cn,{Ac:function(){return Me},Xo:function(){return Mi},Wx:function(){return Io},ZP:function(){return Mn},lk:function(){return Pt}});var Ft=wt(96663),Ht=wt(19127),oe=wt(90493),ke=wt(44127),Vt=wt(72071),qt=wt(6620),Nt=wt(20135),Oe=wt(18929),be=wt(48736),Qt=wt(59301),Fe=wt(92310),ye=wt.n(Fe),Re=wt(34280),It=wt(49658),et=wt(10228),nt=wt(8654),dt=function(ue){var Je=ue.className,gn=ue.customizeIcon,Xn=ue.customizeIconProps,Gn=ue.onMouseDown,ce=ue.onClick,vn=ue.children,An;return typeof gn=="function"?An=gn(Xn):An=gn,Qt.createElement("span",{className:Je,onMouseDown:function(Ae){Ae.preventDefault(),Gn&&Gn(Ae)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:ce,"aria-hidden":!0},An!==void 0?An:Qt.createElement("span",{className:ye()(Je.split(/\s+/).map(function(xi){return"".concat(xi,"-icon")}))},vn))},at=dt;function gt(Le,ue,Je,gn,Xn){var Gn=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,ce=arguments.length>6?arguments[6]:void 0,vn=arguments.length>7?arguments[7]:void 0,An=Qt.useMemo(function(){if((0,Nt.Z)(gn)==="object")return gn.clearIcon;if(Xn)return Xn},[gn,Xn]),xi=Qt.useMemo(function(){return!!(!Gn&&gn&&(Je.length||ce)&&!(vn==="combobox"&&ce===""))},[gn,Gn,Je.length,ce,vn]);return{allowClear:xi,clearIcon:Qt.createElement(at,{className:"".concat(Le,"-clear"),onMouseDown:ue,customizeIcon:An},"\xD7")}}var mt=Qt.createContext(null);function Pt(){return Qt.useContext(mt)}function kt(){var Le=arguments.length>0&&arguments[0]!==void 0?arguments[0]:10,ue=Qt.useState(!1),Je=(0,Vt.Z)(ue,2),gn=Je[0],Xn=Je[1],Gn=Qt.useRef(null),ce=function(){window.clearTimeout(Gn.current)};Qt.useEffect(function(){return ce},[]);var vn=function(xi,Ae){ce(),Gn.current=window.setTimeout(function(){Xn(xi),Ae&&Ae()},Le)};return[gn,vn,ce]}function Tt(){var Le=arguments.length>0&&arguments[0]!==void 0?arguments[0]:250,ue=Qt.useRef(null),Je=Qt.useRef(null);Qt.useEffect(function(){return function(){window.clearTimeout(Je.current)}},[]);function gn(Xn){(Xn||ue.current===null)&&(ue.current=Xn),window.clearTimeout(Je.current),Je.current=window.setTimeout(function(){ue.current=null},Le)}return[function(){return ue.current},gn]}function Dt(Le,ue,Je,gn){var Xn=Qt.useRef(null);Xn.current={open:ue,triggerOpen:Je,customizedTrigger:gn},Qt.useEffect(function(){function Gn(ce){var vn;if(!((vn=Xn.current)!==null&&vn!==void 0&&vn.customizedTrigger)){var An=ce.target;An.shadowRoot&&ce.composed&&(An=ce.composedPath()[0]||An),Xn.current.open&&Le().filter(function(xi){return xi}).every(function(xi){return!xi.contains(An)&&xi!==An})&&Xn.current.triggerOpen(!1)}}return window.addEventListener("mousedown",Gn),function(){return window.removeEventListener("mousedown",Gn)}},[])}var $t=wt(26112),ie=wt(11780),Yt=function(ue,Je){var gn,Xn,Gn=ue.prefixCls,ce=ue.id,vn=ue.inputElement,An=ue.disabled,xi=ue.tabIndex,Ae=ue.autoFocus,en=ue.autoComplete,ui=ue.editable,oi=ue.activeDescendantId,Si=ue.value,Zn=ue.maxLength,hi=ue.onKeyDown,Qn=ue.onMouseDown,Ci=ue.onChange,so=ue.onPaste,wo=ue.onCompositionStart,sn=ue.onCompositionEnd,Bo=ue.open,Vo=ue.attrs,io=vn||Qt.createElement("input",null),Qe=io,Hn=Qe.ref,di=Qe.props,bi=di.onKeyDown,yi=di.onChange,Qi=di.onMouseDown,co=di.onCompositionStart,Ri=di.onCompositionEnd,Hi=di.style;return(0,be.Kp)(!("maxLength"in io.props),"Passing 'maxLength' to input element directly may not work because input in BaseSelect is controlled."),io=Qt.cloneElement(io,(0,ke.Z)((0,ke.Z)((0,ke.Z)({type:"search"},di),{},{id:ce,ref:(0,nt.sQ)(Je,Hn),disabled:An,tabIndex:xi,autoComplete:en||"off",autoFocus:Ae,className:ye()("".concat(Gn,"-selection-search-input"),(gn=io)===null||gn===void 0||(Xn=gn.props)===null||Xn===void 0?void 0:Xn.className),role:"combobox","aria-label":"Search","aria-expanded":Bo||!1,"aria-haspopup":"listbox","aria-owns":"".concat(ce,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(ce,"_list"),"aria-activedescendant":Bo?oi:void 0},Vo),{},{value:ui?Si:"",maxLength:Zn,readOnly:!ui,unselectable:ui?null:"on",style:(0,ke.Z)((0,ke.Z)({},Hi),{},{opacity:ui?null:0}),onKeyDown:function(mn){hi(mn),bi&&bi(mn)},onMouseDown:function(mn){Qn(mn),Qi&&Qi(mn)},onChange:function(mn){Ci(mn),yi&&yi(mn)},onCompositionStart:function(mn){wo(mn),co&&co(mn)},onCompositionEnd:function(mn){sn(mn),Ri&&Ri(mn)},onPaste:so})),io},fe=Qt.forwardRef(Yt);fe.displayName="Input";var Zt=fe;function je(Le){return Array.isArray(Le)?Le:Le!==void 0?[Le]:[]}var me=typeof window!="undefined"&&window.document&&window.document.documentElement,Xe=me;function Se(Le){return Le!=null}function Ie(Le){return!Le&&Le!==0}function ze(Le){return["string","number"].includes((0,Nt.Z)(Le))}function Ue(Le){var ue=void 0;return Le&&(ze(Le.title)?ue=Le.title.toString():ze(Le.label)&&(ue=Le.label.toString())),ue}function se(Le,ue){Xe?Qt.useLayoutEffect(Le,ue):Qt.useEffect(Le,ue)}function jt(Le){var ue;return(ue=Le.key)!==null&&ue!==void 0?ue:Le.value}var $e=function(ue){ue.preventDefault(),ue.stopPropagation()},xn=function(ue){var Je=ue.id,gn=ue.prefixCls,Xn=ue.values,Gn=ue.open,ce=ue.searchValue,vn=ue.autoClearSearchValue,An=ue.inputRef,xi=ue.placeholder,Ae=ue.disabled,en=ue.mode,ui=ue.showSearch,oi=ue.autoFocus,Si=ue.autoComplete,Zn=ue.activeDescendantId,hi=ue.tabIndex,Qn=ue.removeIcon,Ci=ue.maxTagCount,so=ue.maxTagTextLength,wo=ue.maxTagPlaceholder,sn=wo===void 0?function(qo){return"+ ".concat(qo.length," ...")}:wo,Bo=ue.tagRender,Vo=ue.onToggleOpen,io=ue.onRemove,Qe=ue.onInputChange,Hn=ue.onInputPaste,di=ue.onInputKeyDown,bi=ue.onInputMouseDown,yi=ue.onInputCompositionStart,Qi=ue.onInputCompositionEnd,co=Qt.useRef(null),Ri=(0,Qt.useState)(0),Hi=(0,Vt.Z)(Ri,2),fo=Hi[0],mn=Hi[1],Uo=(0,Qt.useState)(!1),un=(0,Vt.Z)(Uo,2),Po=un[0],kr=un[1],$o="".concat(gn,"-selection"),Hr=Gn||en==="multiple"&&vn===!1||en==="tags"?ce:"",xr=en==="tags"||en==="multiple"&&vn===!1||ui&&(Gn||Po);se(function(){mn(co.current.scrollWidth)},[Hr]);function Wi(qo,Sr,ps,ms,ks){return Qt.createElement("span",{className:ye()("".concat($o,"-item"),(0,oe.Z)({},"".concat($o,"-item-disabled"),ps)),title:Ue(qo)},Qt.createElement("span",{className:"".concat($o,"-item-content")},Sr),ms&&Qt.createElement(at,{className:"".concat($o,"-item-remove"),onMouseDown:$e,onClick:ks,customizeIcon:Qn},"\xD7"))}function Ui(qo,Sr,ps,ms,ks){var po=function(Ko){$e(Ko),Vo(!Gn)};return Qt.createElement("span",{onMouseDown:po},Bo({label:Sr,value:qo,disabled:ps,closable:ms,onClose:ks}))}function ko(qo){var Sr=qo.disabled,ps=qo.label,ms=qo.value,ks=!Ae&&!Sr,po=ps;if(typeof so=="number"&&(typeof ps=="string"||typeof ps=="number")){var to=String(po);to.length>so&&(po="".concat(to.slice(0,so),"..."))}var Ko=function(lr){lr&&lr.stopPropagation(),io(qo)};return typeof Bo=="function"?Ui(ms,po,Sr,ks,Ko):Wi(qo,po,Sr,ks,Ko)}function Yo(qo){var Sr=typeof sn=="function"?sn(qo):sn;return Wi({title:Sr},Sr,!1)}var ri=Qt.createElement("div",{className:"".concat($o,"-search"),style:{width:fo},onFocus:function(){kr(!0)},onBlur:function(){kr(!1)}},Qt.createElement(Zt,{ref:An,open:Gn,prefixCls:gn,id:Je,inputElement:null,disabled:Ae,autoFocus:oi,autoComplete:Si,editable:xr,activeDescendantId:Zn,value:Hr,onKeyDown:di,onMouseDown:bi,onChange:Qe,onPaste:Hn,onCompositionStart:yi,onCompositionEnd:Qi,tabIndex:hi,attrs:(0,$t.Z)(ue,!0)}),Qt.createElement("span",{ref:co,className:"".concat($o,"-search-mirror"),"aria-hidden":!0},Hr,"\xA0")),Gt=Qt.createElement(ie.Z,{prefixCls:"".concat($o,"-overflow"),data:Xn,renderItem:ko,renderRest:Yo,suffix:ri,itemKey:jt,maxCount:Ci});return Qt.createElement(Qt.Fragment,null,Gt,!Xn.length&&!Hr&&Qt.createElement("span",{className:"".concat($o,"-placeholder")},xi))},En=xn,Ne=function(ue){var Je=ue.inputElement,gn=ue.prefixCls,Xn=ue.id,Gn=ue.inputRef,ce=ue.disabled,vn=ue.autoFocus,An=ue.autoComplete,xi=ue.activeDescendantId,Ae=ue.mode,en=ue.open,ui=ue.values,oi=ue.placeholder,Si=ue.tabIndex,Zn=ue.showSearch,hi=ue.searchValue,Qn=ue.activeValue,Ci=ue.maxLength,so=ue.onInputKeyDown,wo=ue.onInputMouseDown,sn=ue.onInputChange,Bo=ue.onInputPaste,Vo=ue.onInputCompositionStart,io=ue.onInputCompositionEnd,Qe=ue.title,Hn=Qt.useState(!1),di=(0,Vt.Z)(Hn,2),bi=di[0],yi=di[1],Qi=Ae==="combobox",co=Qi||Zn,Ri=ui[0],Hi=hi||"";Qi&&Qn&&!bi&&(Hi=Qn),Qt.useEffect(function(){Qi&&yi(!1)},[Qi,Qn]);var fo=Ae!=="combobox"&&!en&&!Zn?!1:!!Hi,mn=Qe===void 0?Ue(Ri):Qe,Uo=function(){if(Ri)return null;var Po=fo?{visibility:"hidden"}:void 0;return Qt.createElement("span",{className:"".concat(gn,"-selection-placeholder"),style:Po},oi)};return Qt.createElement(Qt.Fragment,null,Qt.createElement("span",{className:"".concat(gn,"-selection-search")},Qt.createElement(Zt,{ref:Gn,prefixCls:gn,id:Xn,open:en,inputElement:Je,disabled:ce,autoFocus:vn,autoComplete:An,editable:co,activeDescendantId:xi,value:Hi,onKeyDown:so,onMouseDown:wo,onChange:function(Po){yi(!0),sn(Po)},onPaste:Bo,onCompositionStart:Vo,onCompositionEnd:io,tabIndex:Si,attrs:(0,$t.Z)(ue,!0),maxLength:Qi?Ci:void 0})),!Qi&&Ri?Qt.createElement("span",{className:"".concat(gn,"-selection-item"),title:mn,style:fo?{visibility:"hidden"}:void 0},Ri.label):null,Uo())},Ze=Ne;function rn(Le){return![et.Z.ESC,et.Z.SHIFT,et.Z.BACKSPACE,et.Z.TAB,et.Z.WIN_KEY,et.Z.ALT,et.Z.META,et.Z.WIN_KEY_RIGHT,et.Z.CTRL,et.Z.SEMICOLON,et.Z.EQUALS,et.Z.CAPS_LOCK,et.Z.CONTEXT_MENU,et.Z.F1,et.Z.F2,et.Z.F3,et.Z.F4,et.Z.F5,et.Z.F6,et.Z.F7,et.Z.F8,et.Z.F9,et.Z.F10,et.Z.F11,et.Z.F12].includes(Le)}var zn=function(ue,Je){var gn=(0,Qt.useRef)(null),Xn=(0,Qt.useRef)(!1),Gn=ue.prefixCls,ce=ue.open,vn=ue.mode,An=ue.showSearch,xi=ue.tokenWithEnter,Ae=ue.autoClearSearchValue,en=ue.onSearch,ui=ue.onSearchSubmit,oi=ue.onToggleOpen,Si=ue.onInputKeyDown,Zn=ue.domRef;Qt.useImperativeHandle(Je,function(){return{focus:function(){gn.current.focus()},blur:function(){gn.current.blur()}}});var hi=Tt(0),Qn=(0,Vt.Z)(hi,2),Ci=Qn[0],so=Qn[1],wo=function(Hi){var fo=Hi.which;(fo===et.Z.UP||fo===et.Z.DOWN)&&Hi.preventDefault(),Si&&Si(Hi),fo===et.Z.ENTER&&vn==="tags"&&!Xn.current&&!ce&&(ui==null||ui(Hi.target.value)),rn(fo)&&oi(!0)},sn=function(){so(!0)},Bo=(0,Qt.useRef)(null),Vo=function(Hi){en(Hi,!0,Xn.current)!==!1&&oi(!0)},io=function(){Xn.current=!0},Qe=function(Hi){Xn.current=!1,vn!=="combobox"&&Vo(Hi.target.value)},Hn=function(Hi){var fo=Hi.target.value;if(xi&&Bo.current&&/[\r\n]/.test(Bo.current)){var mn=Bo.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");fo=fo.replace(mn,Bo.current)}Bo.current=null,Vo(fo)},di=function(Hi){var fo=Hi.clipboardData,mn=fo.getData("text");Bo.current=mn},bi=function(Hi){var fo=Hi.target;if(fo!==gn.current){var mn=document.body.style.msTouchAction!==void 0;mn?setTimeout(function(){gn.current.focus()}):gn.current.focus()}},yi=function(Hi){var fo=Ci();Hi.target!==gn.current&&!fo&&vn!=="combobox"&&Hi.preventDefault(),(vn!=="combobox"&&(!An||!fo)||!ce)&&(ce&&Ae!==!1&&en("",!0,!1),oi())},Qi={inputRef:gn,onInputKeyDown:wo,onInputMouseDown:sn,onInputChange:Hn,onInputPaste:di,onInputCompositionStart:io,onInputCompositionEnd:Qe},co=vn==="multiple"||vn==="tags"?Qt.createElement(En,(0,Ft.Z)({},ue,Qi)):Qt.createElement(Ze,(0,Ft.Z)({},ue,Qi));return Qt.createElement("div",{ref:Zn,className:"".concat(Gn,"-selector"),onClick:bi,onMouseDown:yi},co)},tn=Qt.forwardRef(zn);tn.displayName="Selector";var Tn=tn,we=wt(35593),Bn=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],Jn=function(ue){var Je=ue===!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"}}},Rt=function(ue,Je){var gn=ue.prefixCls,Xn=ue.disabled,Gn=ue.visible,ce=ue.children,vn=ue.popupElement,An=ue.animation,xi=ue.transitionName,Ae=ue.dropdownStyle,en=ue.dropdownClassName,ui=ue.direction,oi=ui===void 0?"ltr":ui,Si=ue.placement,Zn=ue.builtinPlacements,hi=ue.dropdownMatchSelectWidth,Qn=ue.dropdownRender,Ci=ue.dropdownAlign,so=ue.getPopupContainer,wo=ue.empty,sn=ue.getTriggerDOMNode,Bo=ue.onPopupVisibleChange,Vo=ue.onPopupMouseEnter,io=(0,qt.Z)(ue,Bn),Qe="".concat(gn,"-dropdown"),Hn=vn;Qn&&(Hn=Qn(vn));var di=Qt.useMemo(function(){return Zn||Jn(hi)},[Zn,hi]),bi=An?"".concat(Qe,"-").concat(An):xi,yi=typeof hi=="number",Qi=Qt.useMemo(function(){return yi?null:hi===!1?"minWidth":"width"},[hi,yi]),co=Ae;yi&&(co=(0,ke.Z)((0,ke.Z)({},co),{},{width:hi}));var Ri=Qt.useRef(null);return Qt.useImperativeHandle(Je,function(){return{getPopupElement:function(){return Ri.current}}}),Qt.createElement(we.Z,(0,Ft.Z)({},io,{showAction:Bo?["click"]:[],hideAction:Bo?["click"]:[],popupPlacement:Si||(oi==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:di,prefixCls:Qe,popupTransitionName:bi,popup:Qt.createElement("div",{ref:Ri,onMouseEnter:Vo},Hn),stretch:Qi,popupAlign:Ci,popupVisible:Gn,getPopupContainer:so,popupClassName:ye()(en,(0,oe.Z)({},"".concat(Qe,"-empty"),wo)),popupStyle:co,getTriggerDOMNode:sn,onPopupVisibleChange:Bo}),ce)},Lt=Qt.forwardRef(Rt);Lt.displayName="SelectTrigger";var St=Lt,Et=wt(4537);function Bt(Le,ue){var Je=Le.key,gn;return"value"in Le&&(gn=Le.value),Je!=null?Je:gn!==void 0?gn:"rc-index-key-".concat(ue)}function yt(Le,ue){var Je=Le||{},gn=Je.label,Xn=Je.value,Gn=Je.options,ce=Je.groupLabel,vn=gn||(ue?"children":"label");return{label:vn,value:Xn||"value",options:Gn||"options",groupLabel:ce||vn}}function ae(Le){var ue=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Je=ue.fieldNames,gn=ue.childrenAsData,Xn=[],Gn=yt(Je,!1),ce=Gn.label,vn=Gn.value,An=Gn.options,xi=Gn.groupLabel;function Ae(en,ui){en.forEach(function(oi){if(ui||!(An in oi)){var Si=oi[vn];Xn.push({key:Bt(oi,Xn.length),groupOption:ui,data:oi,label:oi[ce],value:Si})}else{var Zn=oi[xi];Zn===void 0&&gn&&(Zn=oi.label),Xn.push({key:Bt(oi,Xn.length),group:!0,data:oi,label:Zn}),Ae(oi[An],!0)}})}return Ae(Le,!1),Xn}function Pe(Le){var ue=(0,ke.Z)({},Le);return"props"in ue||Object.defineProperty(ue,"props",{get:function(){return(0,be.ZP)(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),ue}}),ue}function ne(Le,ue){if(!ue||!ue.length)return null;var Je=!1;function gn(Gn,ce){var vn=(0,Et.Z)(ce),An=vn[0],xi=vn.slice(1);if(!An)return[Gn];var Ae=Gn.split(An);return Je=Je||Ae.length>1,Ae.reduce(function(en,ui){return[].concat((0,Ht.Z)(en),(0,Ht.Z)(gn(ui,xi)))},[]).filter(function(en){return en})}var Xn=gn(Le,ue);return Je?Xn:null}var _t=["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","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],ge=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"];function pe(Le){return Le==="tags"||Le==="multiple"}var le=Qt.forwardRef(function(Le,ue){var Je,gn,Xn=Le.id,Gn=Le.prefixCls,ce=Le.className,vn=Le.showSearch,An=Le.tagRender,xi=Le.direction,Ae=Le.omitDomProps,en=Le.displayValues,ui=Le.onDisplayValuesChange,oi=Le.emptyOptions,Si=Le.notFoundContent,Zn=Si===void 0?"Not Found":Si,hi=Le.onClear,Qn=Le.mode,Ci=Le.disabled,so=Le.loading,wo=Le.getInputElement,sn=Le.getRawInputElement,Bo=Le.open,Vo=Le.defaultOpen,io=Le.onDropdownVisibleChange,Qe=Le.activeValue,Hn=Le.onActiveValueChange,di=Le.activeDescendantId,bi=Le.searchValue,yi=Le.autoClearSearchValue,Qi=Le.onSearch,co=Le.onSearchSplit,Ri=Le.tokenSeparators,Hi=Le.allowClear,fo=Le.suffixIcon,mn=Le.clearIcon,Uo=Le.OptionList,un=Le.animation,Po=Le.transitionName,kr=Le.dropdownStyle,$o=Le.dropdownClassName,Hr=Le.dropdownMatchSelectWidth,xr=Le.dropdownRender,Wi=Le.dropdownAlign,Ui=Le.placement,ko=Le.builtinPlacements,Yo=Le.getPopupContainer,ri=Le.showAction,Gt=ri===void 0?[]:ri,qo=Le.onFocus,Sr=Le.onBlur,ps=Le.onKeyUp,ms=Le.onKeyDown,ks=Le.onMouseDown,po=(0,qt.Z)(Le,_t),to=pe(Qn),Ko=(vn!==void 0?vn:to)||Qn==="combobox",ao=(0,ke.Z)({},po);ge.forEach(function(Wo){delete ao[Wo]}),Ae==null||Ae.forEach(function(Wo){delete ao[Wo]});var lr=Qt.useState(!1),Ys=(0,Vt.Z)(lr,2),qi=Ys[0],Ai=Ys[1];Qt.useEffect(function(){Ai((0,It.Z)())},[]);var Nn=Qt.useRef(null),Zi=Qt.useRef(null),Xo=Qt.useRef(null),zr=Qt.useRef(null),Ir=Qt.useRef(null),Vr=kt(),Ns=(0,Vt.Z)(Vr,3),Jr=Ns[0],ga=Ns[1],Qs=Ns[2];Qt.useImperativeHandle(ue,function(){var Wo,Cr;return{focus:(Wo=zr.current)===null||Wo===void 0?void 0:Wo.focus,blur:(Cr=zr.current)===null||Cr===void 0?void 0:Cr.blur,scrollTo:function(Ks){var Is;return(Is=Ir.current)===null||Is===void 0?void 0:Is.scrollTo(Ks)}}});var Ea=Qt.useMemo(function(){var Wo;if(Qn!=="combobox")return bi;var Cr=(Wo=en[0])===null||Wo===void 0?void 0:Wo.value;return typeof Cr=="string"||typeof Cr=="number"?String(Cr):""},[bi,Qn,en]),Ye=Qn==="combobox"&&typeof wo=="function"&&wo()||null,Ws=typeof sn=="function"&&sn(),gh=(0,nt.x1)(Zi,Ws==null||(Je=Ws.props)===null||Je===void 0?void 0:Je.ref),kl=Qt.useState(!1),uu=(0,Vt.Z)(kl,2),ts=uu[0],th=uu[1];(0,Re.Z)(function(){th(!0)},[]);var eh=(0,Oe.Z)(!1,{defaultValue:Vo,value:Bo}),Gr=(0,Vt.Z)(eh,2),Ts=Gr[0],Ul=Gr[1],lo=ts?Ts:!1,hr=!Zn&&oi;(Ci||hr&&lo&&Qn==="combobox")&&(lo=!1);var Zo=hr?!1:lo,ci=Qt.useCallback(function(Wo){var Cr=Wo!==void 0?Wo:!lo;Ci||(Ul(Cr),lo!==Cr&&(io==null||io(Cr)))},[Ci,lo,Ul,io]),Os=Qt.useMemo(function(){return(Ri||[]).some(function(Wo){return[` `,`\r `].includes(Wo)})},[Ri]),Fs=function(Cr,xa,Ks){var Is=!0,is=Cr;Hn==null||Hn(null);var vs=Ks?null:ne(Cr,Ri);return Qn!=="combobox"&&vs&&(is="",co==null||co(vs),ci(!1),Is=!1),Qi&&Ea!==is&&Qi(is,{source:xa?"typing":"effect"}),Is},Sa=function(Cr){!Cr||!Cr.trim()||Qi(Cr,{source:"submit"})};Qt.useEffect(function(){!lo&&!to&&Qn!=="combobox"&&Fs("",!1,!1)},[lo]),Qt.useEffect(function(){Ts&&Ci&&Ul(!1),Ci&&ga(!1)},[Ci]);var Nl=Tt(),Yl=(0,Vt.Z)(Nl,2),ei=Yl[0],Qr=Yl[1],js=function(Cr){var xa=ei(),Ks=Cr.which;if(Ks===et.Z.ENTER&&(Qn!=="combobox"&&Cr.preventDefault(),lo||ci(!0)),Qr(!!Ea),Ks===et.Z.BACKSPACE&&!xa&&to&&!Ea&&en.length){for(var Is=(0,Ht.Z)(en),is=null,vs=Is.length-1;vs>=0;vs-=1){var Hs=Is[vs];if(!Hs.disabled){Is.splice(vs,1),is=Hs;break}}is&&ui(Is,{type:"remove",values:[is]})}for(var Bs=arguments.length,Au=new Array(Bs>1?Bs-1:0),Il=1;Il1?xa-1:0),Is=1;Is1?vs-1:0),Bs=1;Bs1&&arguments[1]!==void 0?arguments[1]:!1;return(0,wn.Z)(Le).map(function(Je,gn){if(!Qt.isValidElement(Je)||!Je.type)return null;var Xn=Je,Gn=Xn.type.isSelectOptGroup,ce=Xn.key,vn=Xn.props,An=vn.children,xi=(0,qt.Z)(vn,Yn);return ue||!Gn?ni(Je):(0,ke.Z)((0,ke.Z)({key:"__RC_SELECT_GRP__".concat(ce===null?gn:ce,"__"),label:ce},xi),{},{options:Un(An)})}).filter(function(Je){return Je})}function gi(Le,ue,Je,gn,Xn){return Qt.useMemo(function(){var Gn=Le,ce=!Le;ce&&(Gn=Un(ue));var vn=new Map,An=new Map,xi=function(ui,oi,Si){Si&&typeof Si=="string"&&ui.set(oi[Si],oi)};function Ae(en){for(var ui=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,oi=0;oi1&&arguments[1]!==void 0?arguments[1]:1,Yo=Hn.length,ri=0;ri1&&arguments[1]!==void 0?arguments[1]:!1;fo(Ui);var Yo={source:ko?"keyboard":"mouse"},ri=Hn[Ui];if(!ri){Zn(null,-1,Yo);return}Zn(ri.value,Ui,Yo)};(0,Qt.useEffect)(function(){mn(hi!==!1?Qi(0):-1)},[Hn.length,xi]);var Uo=Qt.useCallback(function(Wi){return so.has(Wi)&&An!=="combobox"},[An,(0,Ht.Z)(so).toString(),so.size]);(0,Qt.useEffect)(function(){var Wi=setTimeout(function(){if(!vn&&ce&&so.size===1){var ko=Array.from(so)[0],Yo=Hn.findIndex(function(ri){var Gt=ri.data;return Gt.value===ko});Yo!==-1&&(mn(Yo),yi(Yo))}});if(ce){var Ui;(Ui=di.current)===null||Ui===void 0||Ui.scrollTo(void 0)}return function(){return clearTimeout(Wi)}},[ce,xi,Si.length]);var un=function(Ui){Ui!==void 0&&Qn(Ui,{selected:!so.has(Ui)}),vn||Ae(!1)};if(Qt.useImperativeHandle(Je,function(){return{onKeyDown:function(Ui){var ko=Ui.which,Yo=Ui.ctrlKey;switch(ko){case et.Z.N:case et.Z.P:case et.Z.UP:case et.Z.DOWN:{var ri=0;if(ko===et.Z.UP?ri=-1:ko===et.Z.DOWN?ri=1:Vi()&&Yo&&(ko===et.Z.N?ri=1:ko===et.Z.P&&(ri=-1)),ri!==0){var Gt=Qi(Hi+ri,ri);yi(Gt),mn(Gt,!0)}break}case et.Z.ENTER:{var qo=Hn[Hi];qo&&!qo.data.disabled?un(qo.value):un(void 0),ce&&Ui.preventDefault();break}case et.Z.ESC:Ae(!1),ce&&Ui.stopPropagation()}},onKeyUp:function(){},scrollTo:function(Ui){yi(Ui)}}}),Hn.length===0)return Qt.createElement("div",{role:"listbox",id:"".concat(Gn,"_list"),className:"".concat(Qe,"-empty"),onMouseDown:bi},en);var Po=Object.keys(wo).map(function(Wi){return wo[Wi]}),kr=function(Ui){return Ui.label};function $o(Wi,Ui){var ko=Wi.group;return{role:ko?"presentation":"option",id:"".concat(Gn,"_list_").concat(Ui)}}var Hr=function(Ui){var ko=Hn[Ui];if(!ko)return null;var Yo=ko.data||{},ri=Yo.value,Gt=ko.group,qo=(0,$t.Z)(Yo,!0),Sr=kr(ko);return ko?Qt.createElement("div",(0,Ft.Z)({"aria-label":typeof Sr=="string"&&!Gt?Sr:null},qo,{key:Ui},$o(ko,Ui),{"aria-selected":Uo(ri)}),ri):null},xr={role:"listbox",id:"".concat(Gn,"_list")};return Qt.createElement(Qt.Fragment,null,sn&&Qt.createElement("div",(0,Ft.Z)({},xr,{style:{height:0,width:0,overflow:"hidden"}}),Hr(Hi-1),Hr(Hi),Hr(Hi+1)),Qt.createElement(Kn.Z,{itemKey:"key",ref:di,data:Hn,height:Vo,itemHeight:io,fullHeight:!1,onMouseDown:bi,onScroll:ui,virtual:sn,direction:Bo,innerProps:sn?null:xr},function(Wi,Ui){var ko,Yo=Wi.group,ri=Wi.groupOption,Gt=Wi.data,qo=Wi.label,Sr=Wi.value,ps=Gt.key;if(Yo){var ms,ks=(ms=Gt.title)!==null&&ms!==void 0?ms:bt(qo)?qo.toString():void 0;return Qt.createElement("div",{className:ye()(Qe,"".concat(Qe,"-group")),title:ks},qo!==void 0?qo:ps)}var po=Gt.disabled,to=Gt.title,Ko=Gt.children,ao=Gt.style,lr=Gt.className,Ys=(0,qt.Z)(Gt,wi),qi=(0,$n.Z)(Ys,Po),Ai=Uo(Sr),Nn="".concat(Qe,"-option"),Zi=ye()(Qe,Nn,lr,(ko={},(0,oe.Z)(ko,"".concat(Nn,"-grouped"),ri),(0,oe.Z)(ko,"".concat(Nn,"-active"),Hi===Ui&&!po),(0,oe.Z)(ko,"".concat(Nn,"-disabled"),po),(0,oe.Z)(ko,"".concat(Nn,"-selected"),Ai),ko)),Xo=kr(Wi),zr=!Ci||typeof Ci=="function"||Ai,Ir=typeof Xo=="number"?Xo:Xo||Sr,Vr=bt(Ir)?Ir.toString():void 0;return to!==void 0&&(Vr=to),Qt.createElement("div",(0,Ft.Z)({},(0,$t.Z)(qi),sn?{}:$o(Wi,Ui),{"aria-selected":Ai,className:Zi,title:Vr,onMouseMove:function(){Hi===Ui||po||mn(Ui)},onClick:function(){po||un(Sr)},style:ao}),Qt.createElement("div",{className:"".concat(Nn,"-content")},Ir),Qt.isValidElement(Ci)||Ai,zr&&Qt.createElement(at,{className:"".concat(Qe,"-option-state"),customizeIcon:Ci,customizeIconProps:{isSelected:Ai}},Ai?"\u2713":null))}))},Ni=Qt.forwardRef(no);Ni.displayName="OptionList";var ho=Ni;function pr(Le){var ue=Le.mode,Je=Le.options,gn=Le.children,Xn=Le.backfill,Gn=Le.allowClear,ce=Le.placeholder,vn=Le.getInputElement,An=Le.showSearch,xi=Le.onSearch,Ae=Le.defaultOpen,en=Le.autoFocus,ui=Le.labelInValue,oi=Le.value,Si=Le.inputValue,Zn=Le.optionLabelProp,hi=isMultiple(ue),Qn=An!==void 0?An:hi||ue==="combobox",Ci=Je||convertChildrenToData(gn);if(warning(ue!=="tags"||Ci.every(function(Bo){return!Bo.disabled}),"Please avoid setting option to disabled in tags mode since user can always type text as tag."),ue==="tags"||ue==="combobox"){var so=Ci.some(function(Bo){return Bo.options?Bo.options.some(function(Vo){return typeof("value"in Vo?Vo.value:Vo.key)=="number"}):typeof("value"in Bo?Bo.value:Bo.key)=="number"});warning(!so,"`value` of Option should not use number type when `mode` is `tags` or `combobox`.")}if(warning(ue!=="combobox"||!Zn,"`combobox` mode not support `optionLabelProp`. Please set `value` on Option directly."),warning(ue==="combobox"||!Xn,"`backfill` only works with `combobox` mode."),warning(ue==="combobox"||!vn,"`getInputElement` only work with `combobox` mode."),noteOnce(ue!=="combobox"||!vn||!Gn||!ce,"Customize `getInputElement` should customize clear and placeholder logic instead of configuring `allowClear` and `placeholder`."),xi&&!Qn&&ue!=="combobox"&&ue!=="tags"&&warning(!1,"`onSearch` should work with `showSearch` instead of use alone."),noteOnce(!Ae||en,"`defaultOpen` makes Select open without focus which means it will not close by click outside. You can set `autoFocus` if needed."),oi!=null){var wo=toArray(oi);warning(!ui||wo.every(function(Bo){return _typeof(Bo)==="object"&&("key"in Bo||"value"in Bo)}),"`value` should in shape of `{ value: string | number, label?: ReactNode }` when you set `labelInValue` to `true`"),warning(!hi||Array.isArray(oi),"`value` should be array when `mode` is `multiple` or `tags`")}if(gn){var sn=null;toNodeArray(gn).some(function(Bo){if(!React.isValidElement(Bo)||!Bo.type)return!1;var Vo=Bo,io=Vo.type;if(io.isSelectOption)return!1;if(io.isSelectOptGroup){var Qe=toNodeArray(Bo.props.children).every(function(Hn){return!React.isValidElement(Hn)||!Bo.type||Hn.type.isSelectOption?!0:(sn=Hn.type,!1)});return!Qe}return sn=io,!0}),sn&&warning(!1,"`children` should be `Select.Option` or `Select.OptGroup` instead of `".concat(sn.displayName||sn.name||sn,"`.")),warning(Si===void 0,"`inputValue` is deprecated, please use `searchValue` instead.")}}function ar(Le,ue){if(Le){var Je=function gn(Xn){for(var Gn=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,ce=0;ce2&&arguments[2]!==void 0?arguments[2]:{},ci=Zo.source,Os=ci===void 0?"keyboard":ci;gh(hr),ce&&gn==="combobox"&&lo!==null&&Os==="keyboard"&&Qs(String(lo))},[ce,gn]),ts=function(hr,Zo,ci){var Os=function(){var Ol,Co=lr(hr);return[Hi?{label:Co==null?void 0:Co[$o.label],value:hr,key:(Ol=Co==null?void 0:Co.key)!==null&&Ol!==void 0?Ol:hr}:hr,Pe(Co)]};if(Zo&&oi){var Fs=Os(),Sa=(0,Vt.Z)(Fs,2),Nl=Sa[0],Yl=Sa[1];oi(Nl,Yl)}else if(!Zo&&Si&&ci!=="clear"){var ei=Os(),Qr=(0,Vt.Z)(ei,2),js=Qr[0],vl=Qr[1];Si(js,vl)}},th=mi(function(lo,hr){var Zo,ci=un?hr.selected:!0;ci?Zo=un?[].concat((0,Ht.Z)(ao),[lo]):[lo]:Zo=ao.filter(function(Os){return Os.value!==lo}),Vr(Zo),ts(lo,ci),gn==="combobox"?Qs(""):(!pe||ui)&&(Ui(""),Qs(""))}),eh=function(hr,Zo){Vr(hr);var ci=Zo.type,Os=Zo.values;(ci==="remove"||ci==="clear")&&Os.forEach(function(Fs){ts(Fs.value,!1,ci)})},Gr=function(hr,Zo){if(Ui(hr),Qs(null),Zo.source==="submit"){var ci=(hr||"").trim();if(ci){var Os=Array.from(new Set([].concat((0,Ht.Z)(qi),[ci])));Vr(Os),ts(ci,!0),Ui("")}return}Zo.source!=="blur"&&(gn==="combobox"&&Vr(hr),Ae==null||Ae(hr))},Ts=function(hr){var Zo=hr;gn!=="tags"&&(Zo=hr.map(function(Os){var Fs=ri.get(Os);return Fs==null?void 0:Fs.value}).filter(function(Os){return Os!==void 0}));var ci=Array.from(new Set([].concat((0,Ht.Z)(qi),(0,Ht.Z)(Zo))));Vr(ci),ci.forEach(function(Os){ts(Os,!0)})},Ul=Qt.useMemo(function(){var lo=Qe!==!1&&hi!==!1;return(0,ke.Z)((0,ke.Z)({},ko),{},{flattenOptions:Ir,onActiveValue:uu,defaultActiveFirstOption:kl,onSelect:th,menuItemSelectedIcon:io,rawValues:qi,fieldNames:$o,virtual:lo,direction:Hn,listHeight:bi,listItemHeight:Qi,childrenAsData:Po})},[ko,Ir,uu,kl,th,io,qi,$o,Qe,hi,bi,Qi,Po]);return Qt.createElement(ii.Provider,{value:Ul},Qt.createElement(Me,(0,Ft.Z)({},mn,{id:Uo,prefixCls:Gn,ref:ue,omitDomProps:nr,mode:gn,displayValues:Ys,onDisplayValuesChange:eh,direction:Hn,searchValue:Wi,onSearch:Gr,autoClearSearchValue:ui,onSearchSplit:Ts,dropdownMatchSelectWidth:hi,OptionList:ho,emptyOptions:!Ir.length,activeValue:ga,activeDescendantId:"".concat(Uo,"_list_").concat(Ws)})))}),Jt=We;Jt.Option=Io,Jt.OptGroup=Mi;var on=Jt,Mn=on},9296:function(Cn,cn,wt){"use strict";wt.r(cn),wt.d(cn,{ResizableTextArea:function(){return fe},default:function(){return Ie}});var Ft=wt(96663),Ht=wt(44127),oe=wt(90493),ke=wt(20135),Vt=wt(72071),qt=wt(6620),Nt=wt(19127),Oe=wt(92310),be=wt.n(Oe),Qt=wt(93681),Fe=wt(5643),ye=wt(18929),Re=wt(59301),It=wt(29301),et=wt(34280),nt=wt(16089),dt=` min-height:0 !important; max-height:none !important; height:0 !important; visibility:hidden !important; overflow:hidden !important; position:absolute !important; z-index:-1000 !important; top:0 !important; right:0 !important; pointer-events: none !important; `,at=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","font-variant","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing","word-break","white-space"],gt={},mt;function Pt(ze){var Ue=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,se=ze.getAttribute("id")||ze.getAttribute("data-reactid")||ze.getAttribute("name");if(Ue&>[se])return gt[se];var jt=window.getComputedStyle(ze),$e=jt.getPropertyValue("box-sizing")||jt.getPropertyValue("-moz-box-sizing")||jt.getPropertyValue("-webkit-box-sizing"),xn=parseFloat(jt.getPropertyValue("padding-bottom"))+parseFloat(jt.getPropertyValue("padding-top")),En=parseFloat(jt.getPropertyValue("border-bottom-width"))+parseFloat(jt.getPropertyValue("border-top-width")),Ne=at.map(function(rn){return"".concat(rn,":").concat(jt.getPropertyValue(rn))}).join(";"),Ze={sizingStyle:Ne,paddingSize:xn,borderSize:En,boxSizing:$e};return Ue&&se&&(gt[se]=Ze),Ze}function kt(ze){var Ue=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,se=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null,jt=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null;mt||(mt=document.createElement("textarea"),mt.setAttribute("tab-index","-1"),mt.setAttribute("aria-hidden","true"),document.body.appendChild(mt)),ze.getAttribute("wrap")?mt.setAttribute("wrap",ze.getAttribute("wrap")):mt.removeAttribute("wrap");var $e=Pt(ze,Ue),xn=$e.paddingSize,En=$e.borderSize,Ne=$e.boxSizing,Ze=$e.sizingStyle;mt.setAttribute("style","".concat(Ze,";").concat(dt)),mt.value=ze.value||ze.placeholder||"";var rn=void 0,zn=void 0,tn,Tn=mt.scrollHeight;if(Ne==="border-box"?Tn+=En:Ne==="content-box"&&(Tn-=xn),se!==null||jt!==null){mt.value=" ";var we=mt.scrollHeight-xn;se!==null&&(rn=we*se,Ne==="border-box"&&(rn=rn+xn+En),Tn=Math.max(rn,Tn)),jt!==null&&(zn=we*jt,Ne==="border-box"&&(zn=zn+xn+En),tn=Tn>zn?"":"hidden",Tn=Math.min(zn,Tn))}var Bn={height:Tn,overflowY:tn,resize:"none"};return rn&&(Bn.minHeight=rn),zn&&(Bn.maxHeight=zn),Bn}var Tt=["prefixCls","onPressEnter","defaultValue","value","autoSize","onResize","className","style","disabled","onChange","onInternalAutoSize"],Dt=0,$t=1,ie=2,Yt=Re.forwardRef(function(ze,Ue){var se=ze,jt=se.prefixCls,$e=se.onPressEnter,xn=se.defaultValue,En=se.value,Ne=se.autoSize,Ze=se.onResize,rn=se.className,zn=se.style,tn=se.disabled,Tn=se.onChange,we=se.onInternalAutoSize,Bn=(0,qt.Z)(se,Tt),Jn=(0,ye.Z)(xn,{value:En,postState:function(Mi){return Mi!=null?Mi:""}}),Rt=(0,Vt.Z)(Jn,2),Lt=Rt[0],St=Rt[1],Et=function(Mi){St(Mi.target.value),Tn==null||Tn(Mi)},Bt=Re.useRef();Re.useImperativeHandle(Ue,function(){return{textArea:Bt.current}});var yt=Re.useMemo(function(){return Ne&&(0,ke.Z)(Ne)==="object"?[Ne.minRows,Ne.maxRows]:[]},[Ne]),ae=(0,Vt.Z)(yt,2),Pe=ae[0],ne=ae[1],_t=!!Ne,ge=function(){try{if(document.activeElement===Bt.current){var Mi=Bt.current,eo=Mi.selectionStart,Io=Mi.selectionEnd,Ao=Mi.scrollTop;Bt.current.setSelectionRange(eo,Io),Bt.current.scrollTop=Ao}}catch($n){}},pe=Re.useState(ie),le=(0,Vt.Z)(pe,2),Me=le[0],nn=le[1],qe=Re.useState(),Ge=(0,Vt.Z)(qe,2),yn=Ge[0],wn=Ge[1],pn=function(){nn(Dt)};(0,et.Z)(function(){_t&&pn()},[En,Pe,ne,_t]),(0,et.Z)(function(){if(Me===Dt)nn($t);else if(Me===$t){var $i=kt(Bt.current,!1,Pe,ne);nn(ie),wn($i)}else ge()},[Me]);var Yn=Re.useRef(),ni=function(){nt.Z.cancel(Yn.current)},Un=function(Mi){Me===ie&&(Ze==null||Ze(Mi),Ne&&(ni(),Yn.current=(0,nt.Z)(function(){pn()})))};Re.useEffect(function(){return ni},[]);var gi=_t?yn:null,mi=(0,Ht.Z)((0,Ht.Z)({},zn),gi);return(Me===Dt||Me===$t)&&(mi.overflowY="hidden",mi.overflowX="hidden"),Re.createElement(It.Z,{onResize:Un,disabled:!(Ne||Ze)},Re.createElement("textarea",(0,Ft.Z)({},Bn,{ref:Bt,style:mi,className:be()(jt,rn,(0,oe.Z)({},"".concat(jt,"-disabled"),tn)),disabled:tn,value:Lt,onChange:Et})))}),fe=Yt,Zt=["defaultValue","value","onFocus","onBlur","onChange","allowClear","maxLength","onCompositionStart","onCompositionEnd","suffix","prefixCls","classes","showCount","className","style","disabled","hidden","classNames","styles","onResize"];function je(ze,Ue){return(0,Nt.Z)(ze||"").slice(0,Ue).join("")}function me(ze,Ue,se,jt){var $e=se;return ze?$e=je(se,jt):(0,Nt.Z)(Ue||"").lengthjt&&($e=Ue),$e}var Xe=Re.forwardRef(function(ze,Ue){var se,jt=ze.defaultValue,$e=ze.value,xn=ze.onFocus,En=ze.onBlur,Ne=ze.onChange,Ze=ze.allowClear,rn=ze.maxLength,zn=ze.onCompositionStart,tn=ze.onCompositionEnd,Tn=ze.suffix,we=ze.prefixCls,Bn=we===void 0?"rc-textarea":we,Jn=ze.classes,Rt=ze.showCount,Lt=ze.className,St=ze.style,Et=ze.disabled,Bt=ze.hidden,yt=ze.classNames,ae=ze.styles,Pe=ze.onResize,ne=(0,qt.Z)(ze,Zt),_t=(0,ye.Z)(jt,{value:$e,defaultValue:jt}),ge=(0,Vt.Z)(_t,2),pe=ge[0],le=ge[1],Me=(0,Re.useRef)(null),nn=Re.useState(!1),qe=(0,Vt.Z)(nn,2),Ge=qe[0],yn=qe[1],wn=Re.useState(!1),pn=(0,Vt.Z)(wn,2),Yn=pn[0],ni=pn[1],Un=Re.useRef(),gi=Re.useRef(0),mi=Re.useState(null),$i=(0,Vt.Z)(mi,2),Mi=$i[0],eo=$i[1],Io=function(){var _e;(_e=Me.current)===null||_e===void 0||_e.textArea.focus()};(0,Re.useImperativeHandle)(Ue,function(){return{resizableTextArea:Me.current,focus:Io,blur:function(){var _e;(_e=Me.current)===null||_e===void 0||_e.textArea.blur()}}}),(0,Re.useEffect)(function(){yn(function(nr){return!Et&&nr})},[Et]);var Ao=Number(rn)>0,$n=function(_e){ni(!0),Un.current=pe,gi.current=_e.currentTarget.selectionStart,zn==null||zn(_e)},Kn=function(_e){ni(!1);var We=_e.currentTarget.value;if(Ao){var Jt,on=gi.current>=rn+1||gi.current===((Jt=Un.current)===null||Jt===void 0?void 0:Jt.length);We=me(on,Un.current,We,rn)}We!==pe&&(le(We),(0,Fe.rJ)(_e.currentTarget,_e,Ne,We)),tn==null||tn(_e)},jn=function(_e){var We=_e.target.value;if(!Yn&&Ao){var Jt=_e.target.selectionStart>=rn+1||_e.target.selectionStart===We.length||!_e.target.selectionStart;We=me(Jt,pe,We,rn)}le(We),(0,Fe.rJ)(_e.currentTarget,_e,Ne,We)},ii=function(_e){var We=ne.onPressEnter,Jt=ne.onKeyDown;_e.key==="Enter"&&We&&We(_e),Jt==null||Jt(_e)},Vi=function(_e){yn(!0),xn==null||xn(_e)},wi=function(_e){yn(!1),En==null||En(_e)},bt=function(_e){var We;le(""),Io(),(0,Fe.rJ)((We=Me.current)===null||We===void 0?void 0:We.textArea,_e,Ne)},no=(0,Fe.D7)(pe);!Yn&&Ao&&$e==null&&(no=je(no,rn));var Ni=Tn,ho;if(Rt){var pr=(0,Nt.Z)(no).length;(0,ke.Z)(Rt)==="object"?ho=Rt.formatter({value:no,count:pr,maxLength:rn}):ho="".concat(pr).concat(Ao?" / ".concat(rn):""),Ni=Re.createElement(Re.Fragment,null,Ni,Re.createElement("span",{className:be()("".concat(Bn,"-data-count"),yt==null?void 0:yt.count),style:ae==null?void 0:ae.count},ho))}var ar=function(_e){var We;Pe==null||Pe(_e),(We=Me.current)!==null&&We!==void 0&&We.textArea.style.height&&eo(!0)},sr=!ne.autoSize&&!Rt&&!Ze,Fo=Re.createElement(Qt.BaseInput,{value:no,allowClear:Ze,handleReset:bt,suffix:Ni,prefixCls:Bn,classes:{affixWrapper:be()(Jn==null?void 0:Jn.affixWrapper,(se={},(0,oe.Z)(se,"".concat(Bn,"-show-count"),Rt),(0,oe.Z)(se,"".concat(Bn,"-textarea-allow-clear"),Ze),se))},disabled:Et,focused:Ge,className:Lt,style:(0,Ht.Z)((0,Ht.Z)({},St),Mi&&!sr?{height:"auto"}:{}),dataAttrs:{affixWrapper:{"data-count":typeof ho=="string"?ho:void 0}},hidden:Bt,inputElement:Re.createElement(fe,(0,Ft.Z)({},ne,{onKeyDown:ii,onChange:jn,onFocus:Vi,onBlur:wi,onCompositionStart:$n,onCompositionEnd:Kn,className:yt==null?void 0:yt.textarea,style:(0,Ht.Z)((0,Ht.Z)({},ae==null?void 0:ae.textarea),{},{resize:St==null?void 0:St.resize}),disabled:Et,prefixCls:Bn,onResize:ar,ref:Me}))});return Fo}),Se=Xe,Ie=Se},39417:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return $t}});var Ft=wt(96663),Ht=wt(90493),oe=wt(6620),ke=wt(44127),Vt=wt(52884),qt=wt(95727),Nt=wt(89866),Oe=wt(65711),be=wt(85745),Qt=wt(92310),Fe=wt.n(Qt),ye=wt(26112),Re=wt(59301),It=wt(39378),et=function(Yt){for(var fe=Yt.prefixCls,Zt=Yt.level,je=Yt.isStart,me=Yt.isEnd,Xe="".concat(fe,"-indent-unit"),Se=[],Ie=0;Ie0&&arguments[0]!==void 0?arguments[0]:[],Et=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],Bt=St.length,yt=Et.length;if(Math.abs(Bt-yt)!==1)return{add:!1,key:null};function ae(Pe,ne){var _t=new Map;Pe.forEach(function(pe){_t.set(pe,!0)});var ge=ne.filter(function(pe){return!_t.has(pe)});return ge.length===1?ge[0]:null}return Bt ").concat(Et);return Et}var rn=nt.forwardRef(function(St,Et){var Bt=St.prefixCls,yt=St.data,ae=St.selectable,Pe=St.checkable,ne=St.expandedKeys,_t=St.selectedKeys,ge=St.checkedKeys,pe=St.loadedKeys,le=St.loadingKeys,Me=St.halfCheckedKeys,nn=St.keyEntities,qe=St.disabled,Ge=St.dragging,yn=St.dragOverNodeKey,wn=St.dropPosition,pn=St.motion,Yn=St.height,ni=St.itemHeight,Un=St.virtual,gi=St.focusable,mi=St.activeItem,$i=St.focused,Mi=St.tabIndex,eo=St.onKeyDown,Io=St.onFocus,Ao=St.onBlur,$n=St.onActiveChange,Kn=St.onListChangeStart,jn=St.onListChangeEnd,ii=(0,Pt.Z)(St,Ie),Vi=nt.useRef(null),wi=nt.useRef(null);nt.useImperativeHandle(Et,function(){return{scrollTo:function(en){Vi.current.scrollTo(en)},getIndentWidth:function(){return wi.current.offsetWidth}}});var bt=nt.useState(ne),no=(0,mt.Z)(bt,2),Ni=no[0],ho=no[1],pr=nt.useState(yt),ar=(0,mt.Z)(pr,2),sr=ar[0],Fo=ar[1],nr=nt.useState(yt),_e=(0,mt.Z)(nr,2),We=_e[0],Jt=_e[1],on=nt.useState([]),Mn=(0,mt.Z)(on,2),Le=Mn[0],ue=Mn[1],Je=nt.useState(null),gn=(0,mt.Z)(Je,2),Xn=gn[0],Gn=gn[1],ce=nt.useRef(yt);ce.current=yt;function vn(){var Ae=ce.current;Fo(Ae),Jt(Ae),ue([]),Gn(null),jn()}(0,kt.Z)(function(){ho(ne);var Ae=Xe(Ni,ne);if(Ae.key!==null)if(Ae.add){var en=sr.findIndex(function(Qn){var Ci=Qn.key;return Ci===Ae.key}),ui=En(Se(sr,yt,Ae.key),Un,Yn,ni),oi=sr.slice();oi.splice(en+1,0,xn),Jt(oi),ue(ui),Gn("show")}else{var Si=yt.findIndex(function(Qn){var Ci=Qn.key;return Ci===Ae.key}),Zn=En(Se(yt,sr,Ae.key),Un,Yn,ni),hi=yt.slice();hi.splice(Si+1,0,xn),Jt(hi),ue(Zn),Gn("hide")}else sr!==yt&&(Fo(yt),Jt(yt))},[ne,yt]),nt.useEffect(function(){Ge||vn()},[Ge]);var An=pn?We:yt,xi={expandedKeys:ne,selectedKeys:_t,loadedKeys:pe,loadingKeys:le,checkedKeys:ge,halfCheckedKeys:Me,dragOverNodeKey:yn,dropPosition:wn,keyEntities:nn};return nt.createElement(nt.Fragment,null,$i&&mi&&nt.createElement("span",{style:ze,"aria-live":"assertive"},Ze(mi)),nt.createElement("div",null,nt.createElement("input",{style:ze,disabled:gi===!1||qe,tabIndex:gi!==!1?Mi:null,onKeyDown:eo,onFocus:Io,onBlur:Ao,value:"",onChange:Ue,"aria-label":"for screen reader"})),nt.createElement("div",{className:"".concat(Bt,"-treenode"),"aria-hidden":!0,style:{position:"absolute",pointerEvents:"none",visibility:"hidden",height:0,overflow:"hidden",border:0,padding:0}},nt.createElement("div",{className:"".concat(Bt,"-indent")},nt.createElement("div",{ref:wi,className:"".concat(Bt,"-indent-unit")}))),nt.createElement(Tt.Z,(0,Ft.Z)({},ii,{data:An,itemKey:Ne,height:Yn,fullHeight:!1,virtual:Un,itemHeight:ni,prefixCls:"".concat(Bt,"-list"),ref:Vi,onVisibleChange:function(en,ui){var oi=new Set(en),Si=ui.filter(function(Zn){return!oi.has(Zn)});Si.some(function(Zn){return Ne(Zn)===se})&&vn()}}),function(Ae){var en=Ae.pos,ui=(0,Ft.Z)({},(gt(Ae.data),Ae.data)),oi=Ae.title,Si=Ae.key,Zn=Ae.isStart,hi=Ae.isEnd,Qn=(0,Yt.km)(Si,en);delete ui.key,delete ui.children;var Ci=(0,Yt.H8)(Qn,xi);return nt.createElement(me,(0,Ft.Z)({},ui,Ci,{title:oi,active:!!mi&&Si===mi.key,pos:en,data:Ae.data,isStart:Zn,isEnd:hi,motion:pn,motionNodes:Si===se?Le:null,motionType:Xn,onMotionStart:Kn,onMotionEnd:vn,treeNodeRequiredProps:xi,onMouseMove:function(){$n(null)}}))}))});rn.displayName="NodeList";var zn=rn,tn=wt(35654),Tn=wt(90782),we=wt(67841),Bn=10,Jn=function(St){(0,be.Z)(Bt,St);var Et=(0,Qt.Z)(Bt);function Bt(){var yt;(0,qt.Z)(this,Bt);for(var ae=arguments.length,Pe=new Array(ae),ne=0;ne2&&arguments[2]!==void 0?arguments[2]:!1,Me=yt.state,nn=Me.dragChildrenKeys,qe=Me.dropPosition,Ge=Me.dropTargetKey,yn=Me.dropTargetPos,wn=Me.dropAllowed;if(wn){var pn=yt.props.onDrop;if(yt.setState({dragOverNodeKey:null}),yt.cleanDragState(),Ge!==null){var Yn=(0,ke.Z)((0,ke.Z)({},(0,Yt.H8)(Ge,yt.getTreeNodeRequiredProps())),{},{active:((pe=yt.getActiveItem())===null||pe===void 0?void 0:pe.key)===Ge,data:(0,we.Z)(yt.state.keyEntities,Ge).node}),ni=nn.indexOf(Ge)!==-1;(0,et.ZP)(!ni,"Can not drop to dragNode's children node. This is a bug of rc-tree. Please report an issue.");var Un=(0,tn.yx)(yn),gi={event:_t,node:(0,Yt.F)(Yn),dragNode:yt.dragNode?(0,Yt.F)(yt.dragNode.props):null,dragNodesKeys:[yt.dragNode.props.eventKey].concat(nn),dropToGap:qe!==0,dropPosition:qe+Number(Un[Un.length-1])};le||pn==null||pn(gi),yt.dragNode=null}}},yt.cleanDragState=function(){var _t=yt.state.draggingNodeKey;_t!==null&&yt.setState({draggingNodeKey:null,dropPosition:null,dropContainerKey:null,dropTargetKey:null,dropLevelOffset:null,dropAllowed:!0,dragOverNodeKey:null}),yt.dragStartMousePosition=null,yt.currentMouseOverDroppableNodeKey=null},yt.triggerExpandActionExpand=function(_t,ge){var pe=yt.state,le=pe.expandedKeys,Me=pe.flattenNodes,nn=ge.expanded,qe=ge.key,Ge=ge.isLeaf;if(!(Ge||_t.shiftKey||_t.metaKey||_t.ctrlKey)){var yn=Me.filter(function(pn){return pn.key===qe})[0],wn=(0,Yt.F)((0,ke.Z)((0,ke.Z)({},(0,Yt.H8)(qe,yt.getTreeNodeRequiredProps())),{},{data:yn.data}));yt.setExpandedKeys(nn?(0,tn._5)(le,qe):(0,tn.L0)(le,qe)),yt.onNodeExpand(_t,wn)}},yt.onNodeClick=function(_t,ge){var pe=yt.props,le=pe.onClick,Me=pe.expandAction;Me==="click"&&yt.triggerExpandActionExpand(_t,ge),le==null||le(_t,ge)},yt.onNodeDoubleClick=function(_t,ge){var pe=yt.props,le=pe.onDoubleClick,Me=pe.expandAction;Me==="doubleClick"&&yt.triggerExpandActionExpand(_t,ge),le==null||le(_t,ge)},yt.onNodeSelect=function(_t,ge){var pe=yt.state.selectedKeys,le=yt.state,Me=le.keyEntities,nn=le.fieldNames,qe=yt.props,Ge=qe.onSelect,yn=qe.multiple,wn=ge.selected,pn=ge[nn.key],Yn=!wn;Yn?yn?pe=(0,tn.L0)(pe,pn):pe=[pn]:pe=(0,tn._5)(pe,pn);var ni=pe.map(function(Un){var gi=(0,we.Z)(Me,Un);return gi?gi.node:null}).filter(function(Un){return Un});yt.setUncontrolledState({selectedKeys:pe}),Ge==null||Ge(pe,{event:"select",selected:Yn,node:ge,selectedNodes:ni,nativeEvent:_t.nativeEvent})},yt.onNodeCheck=function(_t,ge,pe){var le=yt.state,Me=le.keyEntities,nn=le.checkedKeys,qe=le.halfCheckedKeys,Ge=yt.props,yn=Ge.checkStrictly,wn=Ge.onCheck,pn=ge.key,Yn,ni={event:"check",node:ge,checked:pe,nativeEvent:_t.nativeEvent};if(yn){var Un=pe?(0,tn.L0)(nn,pn):(0,tn._5)(nn,pn),gi=(0,tn._5)(qe,pn);Yn={checked:Un,halfChecked:gi},ni.checkedNodes=Un.map(function(Ao){return(0,we.Z)(Me,Ao)}).filter(function(Ao){return Ao}).map(function(Ao){return Ao.node}),yt.setUncontrolledState({checkedKeys:Un})}else{var mi=(0,Tn.S)([].concat((0,Vt.Z)(nn),[pn]),!0,Me),$i=mi.checkedKeys,Mi=mi.halfCheckedKeys;if(!pe){var eo=new Set($i);eo.delete(pn);var Io=(0,Tn.S)(Array.from(eo),{checked:!1,halfCheckedKeys:Mi},Me);$i=Io.checkedKeys,Mi=Io.halfCheckedKeys}Yn=$i,ni.checkedNodes=[],ni.checkedNodesPositions=[],ni.halfCheckedKeys=Mi,$i.forEach(function(Ao){var $n=(0,we.Z)(Me,Ao);if($n){var Kn=$n.node,jn=$n.pos;ni.checkedNodes.push(Kn),ni.checkedNodesPositions.push({node:Kn,pos:jn})}}),yt.setUncontrolledState({checkedKeys:$i},!1,{halfCheckedKeys:Mi})}wn==null||wn(Yn,ni)},yt.onNodeLoad=function(_t){var ge=_t.key,pe=new Promise(function(le,Me){yt.setState(function(nn){var qe=nn.loadedKeys,Ge=qe===void 0?[]:qe,yn=nn.loadingKeys,wn=yn===void 0?[]:yn,pn=yt.props,Yn=pn.loadData,ni=pn.onLoad;if(!Yn||Ge.indexOf(ge)!==-1||wn.indexOf(ge)!==-1)return null;var Un=Yn(_t);return Un.then(function(){var gi=yt.state.loadedKeys,mi=(0,tn.L0)(gi,ge);ni==null||ni(mi,{event:"load",node:_t}),yt.setUncontrolledState({loadedKeys:mi}),yt.setState(function($i){return{loadingKeys:(0,tn._5)($i.loadingKeys,ge)}}),le()}).catch(function(gi){if(yt.setState(function($i){return{loadingKeys:(0,tn._5)($i.loadingKeys,ge)}}),yt.loadingRetryTimes[ge]=(yt.loadingRetryTimes[ge]||0)+1,yt.loadingRetryTimes[ge]>=Bn){var mi=yt.state.loadedKeys;(0,et.ZP)(!1,"Retry for `loadData` many times but still failed. No more retry."),yt.setUncontrolledState({loadedKeys:(0,tn.L0)(mi,ge)}),le()}Me(gi)}),{loadingKeys:(0,tn.L0)(wn,ge)}})});return pe.catch(function(){}),pe},yt.onNodeMouseEnter=function(_t,ge){var pe=yt.props.onMouseEnter;pe==null||pe({event:_t,node:ge})},yt.onNodeMouseLeave=function(_t,ge){var pe=yt.props.onMouseLeave;pe==null||pe({event:_t,node:ge})},yt.onNodeContextMenu=function(_t,ge){var pe=yt.props.onRightClick;pe&&(_t.preventDefault(),pe({event:_t,node:ge}))},yt.onFocus=function(){var _t=yt.props.onFocus;yt.setState({focused:!0});for(var ge=arguments.length,pe=new Array(ge),le=0;le1&&arguments[1]!==void 0?arguments[1]:!1,pe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:null;if(!yt.destroyed){var le=!1,Me=!0,nn={};Object.keys(_t).forEach(function(qe){if(qe in yt.props){Me=!1;return}le=!0,nn[qe]=_t[qe]}),le&&(!ge||Me)&&yt.setState((0,ke.Z)((0,ke.Z)({},nn),pe))}},yt.scrollTo=function(_t){yt.listRef.current.scrollTo(_t)},yt}return(0,Nt.Z)(Bt,[{key:"componentDidMount",value:function(){this.destroyed=!1,this.onUpdated()}},{key:"componentDidUpdate",value:function(){this.onUpdated()}},{key:"onUpdated",value:function(){var ae=this.props.activeKey;ae!==void 0&&ae!==this.state.activeKey&&(this.setState({activeKey:ae}),ae!==null&&this.scrollTo({key:ae}))}},{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 ae,Pe=this.state,ne=Pe.focused,_t=Pe.flattenNodes,ge=Pe.keyEntities,pe=Pe.draggingNodeKey,le=Pe.activeKey,Me=Pe.dropLevelOffset,nn=Pe.dropContainerKey,qe=Pe.dropTargetKey,Ge=Pe.dropPosition,yn=Pe.dragOverNodeKey,wn=Pe.indent,pn=this.props,Yn=pn.prefixCls,ni=pn.className,Un=pn.style,gi=pn.showLine,mi=pn.focusable,$i=pn.tabIndex,Mi=$i===void 0?0:$i,eo=pn.selectable,Io=pn.showIcon,Ao=pn.icon,$n=pn.switcherIcon,Kn=pn.draggable,jn=pn.checkable,ii=pn.checkStrictly,Vi=pn.disabled,wi=pn.motion,bt=pn.loadData,no=pn.filterTreeNode,Ni=pn.height,ho=pn.itemHeight,pr=pn.virtual,ar=pn.titleRender,sr=pn.dropIndicatorRender,Fo=pn.onContextMenu,nr=pn.onScroll,_e=pn.direction,We=pn.rootClassName,Jt=pn.rootStyle,on=(0,It.Z)(this.props,{aria:!0,data:!0}),Mn;return Kn&&((0,oe.Z)(Kn)==="object"?Mn=Kn:typeof Kn=="function"?Mn={nodeDraggable:Kn}:Mn={}),nt.createElement(dt.k.Provider,{value:{prefixCls:Yn,selectable:eo,showIcon:Io,icon:Ao,switcherIcon:$n,draggable:Mn,draggingNodeKey:pe,checkable:jn,checkStrictly:ii,disabled:Vi,keyEntities:ge,dropLevelOffset:Me,dropContainerKey:nn,dropTargetKey:qe,dropPosition:Ge,dragOverNodeKey:yn,indent:wn,direction:_e,dropIndicatorRender:sr,loadData:bt,filterTreeNode:no,titleRender:ar,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}},nt.createElement("div",{role:"tree",className:ye()(Yn,ni,We,(ae={},(0,Ht.Z)(ae,"".concat(Yn,"-show-line"),gi),(0,Ht.Z)(ae,"".concat(Yn,"-focused"),ne),(0,Ht.Z)(ae,"".concat(Yn,"-active-focused"),le!==null),ae)),style:Jt},nt.createElement(zn,(0,Ft.Z)({ref:this.listRef,prefixCls:Yn,style:Un,data:_t,disabled:Vi,selectable:eo,checkable:!!jn,motion:wi,dragging:pe!==null,height:Ni,itemHeight:ho,virtual:pr,focusable:mi,focused:ne,tabIndex:Mi,activeItem:this.getActiveItem(),onFocus:this.onFocus,onBlur:this.onBlur,onKeyDown:this.onKeyDown,onActiveChange:this.onActiveChange,onListChangeStart:this.onListChangeStart,onListChangeEnd:this.onListChangeEnd,onContextMenu:Fo,onScroll:nr},this.getTreeNodeRequiredProps(),on))))}}],[{key:"getDerivedStateFromProps",value:function(ae,Pe){var ne=Pe.prevProps,_t={prevProps:ae};function ge(mi){return!ne&&mi in ae||ne&&ne[mi]!==ae[mi]}var pe,le=Pe.fieldNames;if(ge("fieldNames")&&(le=(0,Yt.w$)(ae.fieldNames),_t.fieldNames=le),ge("treeData")?pe=ae.treeData:ge("children")&&((0,et.ZP)(!1,"`children` of Tree is deprecated. Please use `treeData` instead."),pe=(0,Yt.zn)(ae.children)),pe){_t.treeData=pe;var Me=(0,Yt.I8)(pe,{fieldNames:le});_t.keyEntities=(0,ke.Z)((0,Ht.Z)({},se,$e),Me.keyEntities)}var nn=_t.keyEntities||Pe.keyEntities;if(ge("expandedKeys")||ne&&ge("autoExpandParent"))_t.expandedKeys=ae.autoExpandParent||!ne&&ae.defaultExpandParent?(0,tn.r7)(ae.expandedKeys,nn):ae.expandedKeys;else if(!ne&&ae.defaultExpandAll){var qe=(0,ke.Z)({},nn);delete qe[se],_t.expandedKeys=Object.keys(qe).map(function(mi){return qe[mi].key})}else!ne&&ae.defaultExpandedKeys&&(_t.expandedKeys=ae.autoExpandParent||ae.defaultExpandParent?(0,tn.r7)(ae.defaultExpandedKeys,nn):ae.defaultExpandedKeys);if(_t.expandedKeys||delete _t.expandedKeys,pe||_t.expandedKeys){var Ge=(0,Yt.oH)(pe||Pe.treeData,_t.expandedKeys||Pe.expandedKeys,le);_t.flattenNodes=Ge}if(ae.selectable&&(ge("selectedKeys")?_t.selectedKeys=(0,tn.BT)(ae.selectedKeys,ae):!ne&&ae.defaultSelectedKeys&&(_t.selectedKeys=(0,tn.BT)(ae.defaultSelectedKeys,ae))),ae.checkable){var yn;if(ge("checkedKeys")?yn=(0,tn.E6)(ae.checkedKeys)||{}:!ne&&ae.defaultCheckedKeys?yn=(0,tn.E6)(ae.defaultCheckedKeys)||{}:pe&&(yn=(0,tn.E6)(ae.checkedKeys)||{checkedKeys:Pe.checkedKeys,halfCheckedKeys:Pe.halfCheckedKeys}),yn){var wn=yn,pn=wn.checkedKeys,Yn=pn===void 0?[]:pn,ni=wn.halfCheckedKeys,Un=ni===void 0?[]:ni;if(!ae.checkStrictly){var gi=(0,Tn.S)(Yn,!0,nn);Yn=gi.checkedKeys,Un=gi.halfCheckedKeys}_t.checkedKeys=Yn,_t.halfCheckedKeys=Un}}return ge("loadedKeys")&&(_t.loadedKeys=ae.loadedKeys),_t}}]),Bt}(nt.Component);Jn.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:at,allowDrop:function(){return!0},expandAction:!1},Jn.TreeNode=$t.Z;var Rt=Jn,Lt=Rt},35654:function(Cn,cn,wt){"use strict";wt.d(cn,{BT:function(){return nt},E6:function(){return gt},L0:function(){return Qt},OM:function(){return et},_5:function(){return be},r7:function(){return mt},wA:function(){return ye},yx:function(){return Fe}});var Ft=wt(19127),Ht=wt(20135),oe=wt(48736),ke=wt(59301),Vt=wt(39417),qt=wt(67841),Nt=wt(71430),Oe=null;function be(Pt,kt){if(!Pt)return[];var Tt=Pt.slice(),Dt=Tt.indexOf(kt);return Dt>=0&&Tt.splice(Dt,1),Tt}function Qt(Pt,kt){var Tt=(Pt||[]).slice();return Tt.indexOf(kt)===-1&&Tt.push(kt),Tt}function Fe(Pt){return Pt.split("-")}function ye(Pt,kt){var Tt=[],Dt=(0,qt.Z)(kt,Pt);function $t(){var ie=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];ie.forEach(function(Yt){var fe=Yt.key,Zt=Yt.children;Tt.push(fe),$t(Zt)})}return $t(Dt.children),Tt}function Re(Pt){if(Pt.parent){var kt=Fe(Pt.pos);return Number(kt[kt.length-1])===Pt.parent.children.length-1}return!1}function It(Pt){var kt=Fe(Pt.pos);return Number(kt[kt.length-1])===0}function et(Pt,kt,Tt,Dt,$t,ie,Yt,fe,Zt,je){var me,Xe=Pt.clientX,Se=Pt.clientY,Ie=Pt.target.getBoundingClientRect(),ze=Ie.top,Ue=Ie.height,se=(je==="rtl"?-1:1)*((($t==null?void 0:$t.x)||0)-Xe),jt=(se-12)/Dt,$e=(0,qt.Z)(fe,Tt.props.eventKey);if(Se-1.5?ie({dragNode:Bn,dropNode:Jn,dropPosition:1})?tn=1:Rt=!1:ie({dragNode:Bn,dropNode:Jn,dropPosition:0})?tn=0:ie({dragNode:Bn,dropNode:Jn,dropPosition:1})?tn=1:Rt=!1:ie({dragNode:Bn,dropNode:Jn,dropPosition:1})?tn=1:Rt=!1,{dropPosition:tn,dropLevelOffset:Tn,dropTargetKey:$e.key,dropTargetPos:$e.pos,dragOverNodeKey:zn,dropContainerKey:tn===0?null:((me=$e.parent)===null||me===void 0?void 0:me.key)||null,dropAllowed:Rt}}function nt(Pt,kt){if(Pt){var Tt=kt.multiple;return Tt?Pt.slice():Pt.length?[Pt[0]]:Pt}}var dt=function(kt){return kt};function at(Pt,kt){if(!Pt)return[];var Tt=kt||{},Dt=Tt.processProps,$t=Dt===void 0?dt:Dt,ie=Array.isArray(Pt)?Pt:[Pt];return ie.map(function(Yt){var fe=Yt.children,Zt=_objectWithoutProperties(Yt,Oe),je=at(fe,kt);return React.createElement(TreeNode,_extends({key:Zt.key},$t(Zt)),je)})}function gt(Pt){if(!Pt)return null;var kt;if(Array.isArray(Pt))kt={checkedKeys:Pt,halfCheckedKeys:void 0};else if((0,Ht.Z)(Pt)==="object")kt={checkedKeys:Pt.checked||void 0,halfCheckedKeys:Pt.halfChecked||void 0};else return(0,oe.ZP)(!1,"`checkedKeys` is not an array or an object"),null;return kt}function mt(Pt,kt){var Tt=new Set;function Dt($t){if(!Tt.has($t)){var ie=(0,qt.Z)(kt,$t);if(ie){Tt.add($t);var Yt=ie.parent,fe=ie.node;fe.disabled||Yt&&Dt(Yt.key)}}}return(Pt||[]).forEach(function($t){Dt($t)}),(0,Ft.Z)(Tt)}},90782:function(Cn,cn,wt){"use strict";wt.d(cn,{S:function(){return Nt}});var Ft=wt(48736),Ht=wt(67841);function oe(Oe,be){var Qt=new Set;return Oe.forEach(function(Fe){be.has(Fe)||Qt.add(Fe)}),Qt}function ke(Oe){var be=Oe||{},Qt=be.disabled,Fe=be.disableCheckbox,ye=be.checkable;return!!(Qt||Fe)||ye===!1}function Vt(Oe,be,Qt,Fe){for(var ye=new Set(Oe),Re=new Set,It=0;It<=Qt;It+=1){var et=be.get(It)||new Set;et.forEach(function(gt){var mt=gt.key,Pt=gt.node,kt=gt.children,Tt=kt===void 0?[]:kt;ye.has(mt)&&!Fe(Pt)&&Tt.filter(function(Dt){return!Fe(Dt.node)}).forEach(function(Dt){ye.add(Dt.key)})})}for(var nt=new Set,dt=Qt;dt>=0;dt-=1){var at=be.get(dt)||new Set;at.forEach(function(gt){var mt=gt.parent,Pt=gt.node;if(!(Fe(Pt)||!gt.parent||nt.has(gt.parent.key))){if(Fe(gt.parent.node)){nt.add(mt.key);return}var kt=!0,Tt=!1;(mt.children||[]).filter(function(Dt){return!Fe(Dt.node)}).forEach(function(Dt){var $t=Dt.key,ie=ye.has($t);kt&&!ie&&(kt=!1),!Tt&&(ie||Re.has($t))&&(Tt=!0)}),kt&&ye.add(mt.key),Tt&&Re.add(mt.key),nt.add(mt.key)}})}return{checkedKeys:Array.from(ye),halfCheckedKeys:Array.from(oe(Re,ye))}}function qt(Oe,be,Qt,Fe,ye){for(var Re=new Set(Oe),It=new Set(be),et=0;et<=Fe;et+=1){var nt=Qt.get(et)||new Set;nt.forEach(function(mt){var Pt=mt.key,kt=mt.node,Tt=mt.children,Dt=Tt===void 0?[]:Tt;!Re.has(Pt)&&!It.has(Pt)&&!ye(kt)&&Dt.filter(function($t){return!ye($t.node)}).forEach(function($t){Re.delete($t.key)})})}It=new Set;for(var dt=new Set,at=Fe;at>=0;at-=1){var gt=Qt.get(at)||new Set;gt.forEach(function(mt){var Pt=mt.parent,kt=mt.node;if(!(ye(kt)||!mt.parent||dt.has(mt.parent.key))){if(ye(mt.parent.node)){dt.add(Pt.key);return}var Tt=!0,Dt=!1;(Pt.children||[]).filter(function($t){return!ye($t.node)}).forEach(function($t){var ie=$t.key,Yt=Re.has(ie);Tt&&!Yt&&(Tt=!1),!Dt&&(Yt||It.has(ie))&&(Dt=!0)}),Tt||Re.delete(Pt.key),Dt&&It.add(Pt.key),dt.add(Pt.key)}})}return{checkedKeys:Array.from(Re),halfCheckedKeys:Array.from(oe(It,Re))}}function Nt(Oe,be,Qt,Fe){var ye=[],Re;Fe?Re=Fe:Re=ke;var It=new Set(Oe.filter(function(at){var gt=!!(0,Ht.Z)(Qt,at);return gt||ye.push(at),gt})),et=new Map,nt=0;Object.keys(Qt).forEach(function(at){var gt=Qt[at],mt=gt.level,Pt=et.get(mt);Pt||(Pt=new Set,et.set(mt,Pt)),Pt.add(gt),nt=Math.max(nt,mt)}),(0,Ft.ZP)(!ye.length,"Tree missing follow keys: ".concat(ye.slice(0,100).map(function(at){return"'".concat(at,"'")}).join(", ")));var dt;return be===!0?dt=Vt(It,et,nt,Re):dt=qt(It,be.halfCheckedKeys,et,nt,Re),dt}},67841:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Ft}});function Ft(Ht,oe){return Ht[oe]}},71430:function(Cn,cn,wt){"use strict";wt.d(cn,{F:function(){return mt},H8:function(){return gt},I8:function(){return at},km:function(){return ye},oH:function(){return nt},w$:function(){return Re},zn:function(){return et}});var Ft=wt(20135),Ht=wt(19127),oe=wt(44127),ke=wt(6620),Vt=wt(11592),qt=wt(2738),Nt=wt(48736),Oe=wt(67841),be=["children"];function Qt(Pt,kt){return"".concat(Pt,"-").concat(kt)}function Fe(Pt){return Pt&&Pt.type&&Pt.type.isTreeNode}function ye(Pt,kt){return Pt!=null?Pt:kt}function Re(Pt){var kt=Pt||{},Tt=kt.title,Dt=kt._title,$t=kt.key,ie=kt.children,Yt=Tt||"title";return{title:Yt,_title:Dt||[Yt],key:$t||"key",children:ie||"children"}}function It(Pt,kt){var Tt=new Map;function Dt($t){var ie=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";($t||[]).forEach(function(Yt){var fe=Yt[kt.key],Zt=Yt[kt.children];warning(fe!=null,"Tree node must have a certain key: [".concat(ie).concat(fe,"]"));var je=String(fe);warning(!Tt.has(je)||fe===null||fe===void 0,"Same 'key' exist in the Tree: ".concat(je)),Tt.set(je,!0),Dt(Zt,"".concat(ie).concat(je," > "))})}Dt(Pt)}function et(Pt){function kt(Tt){var Dt=(0,Vt.Z)(Tt);return Dt.map(function($t){if(!Fe($t))return(0,Nt.ZP)(!$t,"Tree/TreeNode can only accept TreeNode as children."),null;var ie=$t.key,Yt=$t.props,fe=Yt.children,Zt=(0,ke.Z)(Yt,be),je=(0,oe.Z)({key:ie},Zt),me=kt(fe);return me.length&&(je.children=me),je}).filter(function($t){return $t})}return kt(Pt)}function nt(Pt,kt,Tt){var Dt=Re(Tt),$t=Dt._title,ie=Dt.key,Yt=Dt.children,fe=new Set(kt===!0?[]:kt),Zt=[];function je(me){var Xe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;return me.map(function(Se,Ie){for(var ze=Qt(Xe?Xe.pos:"0",Ie),Ue=ye(Se[ie],ze),se,jt=0;jt<$t.length;jt+=1){var $e=$t[jt];if(Se[$e]!==void 0){se=Se[$e];break}}var xn=(0,oe.Z)((0,oe.Z)({},(0,qt.Z)(Se,[].concat((0,Ht.Z)($t),[ie,Yt]))),{},{title:se,key:Ue,parent:Xe,pos:ze,children:null,data:Se,isStart:[].concat((0,Ht.Z)(Xe?Xe.isStart:[]),[Ie===0]),isEnd:[].concat((0,Ht.Z)(Xe?Xe.isEnd:[]),[Ie===me.length-1])});return Zt.push(xn),kt===!0||fe.has(Ue)?xn.children=je(Se[Yt]||[],xn):xn.children=[],xn})}return je(Pt),Zt}function dt(Pt,kt,Tt){var Dt={};(0,Ft.Z)(Tt)==="object"?Dt=Tt:Dt={externalGetKey:Tt},Dt=Dt||{};var $t=Dt,ie=$t.childrenPropName,Yt=$t.externalGetKey,fe=$t.fieldNames,Zt=Re(fe),je=Zt.key,me=Zt.children,Xe=ie||me,Se;Yt?typeof Yt=="string"?Se=function(Ue){return Ue[Yt]}:typeof Yt=="function"&&(Se=function(Ue){return Yt(Ue)}):Se=function(Ue,se){return ye(Ue[je],se)};function Ie(ze,Ue,se,jt){var $e=ze?ze[Xe]:Pt,xn=ze?Qt(se.pos,Ue):"0",En=ze?[].concat((0,Ht.Z)(jt),[ze]):[];if(ze){var Ne=Se(ze,xn),Ze={node:ze,index:Ue,pos:xn,key:Ne,parentPos:se.node?se.pos:null,level:se.level+1,nodes:En};kt(Ze)}$e&&$e.forEach(function(rn,zn){Ie(rn,zn,{node:ze,pos:xn,level:se?se.level+1:-1},En)})}Ie(null)}function at(Pt){var kt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Tt=kt.initWrapper,Dt=kt.processEntity,$t=kt.onProcessFinished,ie=kt.externalGetKey,Yt=kt.childrenPropName,fe=kt.fieldNames,Zt=arguments.length>2?arguments[2]:void 0,je=ie||Zt,me={},Xe={},Se={posEntities:me,keyEntities:Xe};return Tt&&(Se=Tt(Se)||Se),dt(Pt,function(Ie){var ze=Ie.node,Ue=Ie.index,se=Ie.pos,jt=Ie.key,$e=Ie.parentPos,xn=Ie.level,En=Ie.nodes,Ne={node:ze,nodes:En,index:Ue,key:jt,pos:se,level:xn},Ze=ye(jt,se);me[se]=Ne,Xe[Ze]=Ne,Ne.parent=me[$e],Ne.parent&&(Ne.parent.children=Ne.parent.children||[],Ne.parent.children.push(Ne)),Dt&&Dt(Ne,Se)},{externalGetKey:je,childrenPropName:Yt,fieldNames:fe}),$t&&$t(Se),Se}function gt(Pt,kt){var Tt=kt.expandedKeys,Dt=kt.selectedKeys,$t=kt.loadedKeys,ie=kt.loadingKeys,Yt=kt.checkedKeys,fe=kt.halfCheckedKeys,Zt=kt.dragOverNodeKey,je=kt.dropPosition,me=kt.keyEntities,Xe=(0,Oe.Z)(me,Pt),Se={eventKey:Pt,expanded:Tt.indexOf(Pt)!==-1,selected:Dt.indexOf(Pt)!==-1,loaded:$t.indexOf(Pt)!==-1,loading:ie.indexOf(Pt)!==-1,checked:Yt.indexOf(Pt)!==-1,halfChecked:fe.indexOf(Pt)!==-1,pos:String(Xe?Xe.pos:""),dragOver:Zt===Pt&&je===0,dragOverGapTop:Zt===Pt&&je===-1,dragOverGapBottom:Zt===Pt&&je===1};return Se}function mt(Pt){var kt=Pt.data,Tt=Pt.expanded,Dt=Pt.selected,$t=Pt.checked,ie=Pt.loaded,Yt=Pt.loading,fe=Pt.halfChecked,Zt=Pt.dragOver,je=Pt.dragOverGapTop,me=Pt.dragOverGapBottom,Xe=Pt.pos,Se=Pt.active,Ie=Pt.eventKey,ze=(0,oe.Z)((0,oe.Z)({},kt),{},{expanded:Tt,selected:Dt,checked:$t,loaded:ie,loading:Yt,halfChecked:fe,dragOver:Zt,dragOverGapTop:je,dragOverGapBottom:me,pos:Xe,active:Se,key:Ie});return"props"in ze||Object.defineProperty(ze,"props",{get:function(){return(0,Nt.ZP)(!1,"Second param return from event is node data instead of TreeNode instance. Please read value directly instead of reading from `props`."),Pt}}),ze}},8224:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Ht}});var Ft=wt(4676);function Ht(oe,ke,Vt,qt){var Nt=Ft.unstable_batchedUpdates?function(be){Ft.unstable_batchedUpdates(Vt,be)}:Vt;return oe!=null&&oe.addEventListener&&oe.addEventListener(ke,Nt,qt),{remove:function(){oe!=null&&oe.removeEventListener&&oe.removeEventListener(ke,Nt,qt)}}}},55468:function(Cn,cn,wt){"use strict";wt.d(cn,{g1:function(){return Fe},os:function(){return Re}});var Ft=/margin|padding|width|height|max|min|offset/,Ht={left:!0,top:!0},oe={cssFloat:1,styleFloat:1,float:1};function ke(It){return It.nodeType===1?It.ownerDocument.defaultView.getComputedStyle(It,null):{}}function Vt(It,et,nt){if(et=et.toLowerCase(),nt==="auto"){if(et==="height")return It.offsetHeight;if(et==="width")return It.offsetWidth}return et in Ht||(Ht[et]=Ft.test(et)),Ht[et]?parseFloat(nt)||0:nt}function qt(It,et){var nt=arguments.length,dt=ke(It);return et=oe[et]?"cssFloat"in It.style?"cssFloat":"styleFloat":et,nt===1?dt:Vt(It,et,dt[et]||It.style[et])}function Nt(It,et,nt){var dt=arguments.length;if(et=oe[et]?"cssFloat"in It.style?"cssFloat":"styleFloat":et,dt===3)return typeof nt=="number"&&Ft.test(et)&&(nt="".concat(nt,"px")),It.style[et]=nt,nt;for(var at in et)et.hasOwnProperty(at)&&Nt(It,at,et[at]);return ke(It)}function Oe(It){return It===document.body?document.documentElement.clientWidth:It.offsetWidth}function be(It){return It===document.body?window.innerHeight||document.documentElement.clientHeight:It.offsetHeight}function Qt(){var It=Math.max(document.documentElement.scrollWidth,document.body.scrollWidth),et=Math.max(document.documentElement.scrollHeight,document.body.scrollHeight);return{width:It,height:et}}function Fe(){var It=document.documentElement.clientWidth,et=window.innerHeight||document.documentElement.clientHeight;return{width:It,height:et}}function ye(){return{scrollLeft:Math.max(document.documentElement.scrollLeft,document.body.scrollLeft),scrollTop:Math.max(document.documentElement.scrollTop,document.body.scrollTop)}}function Re(It){var et=It.getBoundingClientRect(),nt=document.documentElement;return{left:et.left+(window.pageXOffset||nt.scrollLeft)-(nt.clientLeft||document.body.clientLeft||0),top:et.top+(window.pageYOffset||nt.scrollTop)-(nt.clientTop||document.body.clientTop||0)}}},24514:function(Cn,cn,wt){"use strict";wt.d(cn,{G:function(){return ke}});var Ft=wt(47273),Ht=function(qt){if((0,Ft.Z)()&&window.document.documentElement){var Nt=Array.isArray(qt)?qt:[qt],Oe=window.document.documentElement;return Nt.some(function(be){return be in Oe.style})}return!1},oe=function(qt,Nt){if(!Ht(qt))return!1;var Oe=document.createElement("div"),be=Oe.style[qt];return Oe.style[qt]=Nt,Oe.style[qt]!==be};function ke(Vt,qt){return!Array.isArray(Vt)&&qt!==void 0?oe(Vt,qt):Ht(Vt)}},24916:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Jn}});var Ft=wt(96663),Ht=wt(20135),oe=wt(44127),ke=wt(90493),Vt=wt(72071),qt=wt(6620),Nt=wt(92310),Oe=wt.n(Nt),be=wt(29301),Qt=wt(70425),Fe=wt(34280),ye=wt(59301),Re=wt(4676),It=ye.forwardRef(function(Rt,Lt){var St=Rt.height,Et=Rt.offsetY,Bt=Rt.offsetX,yt=Rt.children,ae=Rt.prefixCls,Pe=Rt.onInnerResize,ne=Rt.innerProps,_t=Rt.rtl,ge=Rt.extra,pe={},le={display:"flex",flexDirection:"column"};return Et!==void 0&&(pe={height:St,position:"relative",overflow:"hidden"},le=(0,oe.Z)((0,oe.Z)({},le),{},(0,ke.Z)((0,ke.Z)((0,ke.Z)((0,ke.Z)((0,ke.Z)({transform:"translateY(".concat(Et,"px)")},_t?"marginRight":"marginLeft",-Bt),"position","absolute"),"left",0),"right",0),"top",0))),ye.createElement("div",{style:pe},ye.createElement(be.Z,{onResize:function(nn){var qe=nn.offsetHeight;qe&&Pe&&Pe()}},ye.createElement("div",(0,Ft.Z)({style:le,className:Oe()((0,ke.Z)({},"".concat(ae,"-holder-inner"),ae)),ref:Lt},ne),yt,ge)))});It.displayName="Filler";var et=It;function nt(Rt){var Lt=Rt.children,St=Rt.setRef,Et=ye.useCallback(function(Bt){St(Bt)},[]);return ye.cloneElement(Lt,{ref:Et})}function dt(Rt,Lt,St,Et,Bt,yt,ae,Pe){var ne=Pe.getKey;return Rt.slice(Lt,St+1).map(function(_t,ge){var pe=Lt+ge,le=ae(_t,pe,{style:{width:Et},offsetX:Bt}),Me=ne(_t);return ye.createElement(nt,{key:Me,setRef:function(qe){return yt(_t,qe)}},le)})}function at(Rt,Lt,St,Et){var Bt=St-Rt,yt=Lt-St,ae=Math.min(Bt,yt)*2;if(Et<=ae){var Pe=Math.floor(Et/2);return Et%2?St+Pe+1:St-Pe}return Bt>yt?St-(Et-yt):St+(Et-Bt)}function gt(Rt,Lt,St){var Et=Rt.length,Bt=Lt.length,yt,ae;if(Et===0&&Bt===0)return null;Et2&&arguments[2]!==void 0?arguments[2]:!1,pe=ne?_t<0&&Pe.current.left||_t>0&&Pe.current.right:_t<0&&Pe.current.top||_t>0&&Pe.current.bottom;return ge&&pe?(clearTimeout(yt.current),Bt.current=!1):(!pe||Bt.current)&&ae(),!Bt.current&&pe}};function $t(Rt,Lt,St,Et,Bt,yt,ae){var Pe=(0,ye.useRef)(0),ne=(0,ye.useRef)(null),_t=(0,ye.useRef)(null),ge=(0,ye.useRef)(!1),pe=Dt(Lt,St,Et,Bt);function le(wn,pn){if(Pt.Z.cancel(ne.current),!pe(!1,pn)){var Yn=wn;if(!Yn._virtualHandled)Yn._virtualHandled=!0;else return;Pe.current+=pn,_t.current=pn,Tt||Yn.preventDefault(),ne.current=(0,Pt.Z)(function(){var ni=ge.current?10:1;ae(Pe.current*ni,!1),Pe.current=0})}}function Me(wn,pn){ae(pn,!0),Tt||wn.preventDefault()}var nn=(0,ye.useRef)(null),qe=(0,ye.useRef)(null);function Ge(wn){if(Rt){Pt.Z.cancel(qe.current),qe.current=(0,Pt.Z)(function(){nn.current=null},2);var pn=wn.deltaX,Yn=wn.deltaY,ni=wn.shiftKey,Un=pn,gi=Yn;(nn.current==="sx"||!nn.current&&ni&&Yn&&!pn)&&(Un=Yn,gi=0,nn.current="sx");var mi=Math.abs(Un),$i=Math.abs(gi);nn.current===null&&(nn.current=yt&&mi>$i?"x":"y"),nn.current==="y"?le(wn,gi):Me(wn,Un)}}function yn(wn){Rt&&(ge.current=wn.detail===_t.current)}return[Ge,yn]}function ie(Rt,Lt,St,Et){var Bt=ye.useMemo(function(){return[new Map,[]]},[Rt,St.id,Et]),yt=(0,Vt.Z)(Bt,2),ae=yt[0],Pe=yt[1],ne=function(ge){var pe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ge,le=ae.get(ge),Me=ae.get(pe);if(le===void 0||Me===void 0)for(var nn=Rt.length,qe=Pe.length;qe0&&arguments[0]!==void 0?arguments[0]:!1;ge();var nn=function(){var yn=!1;Pe.current.forEach(function(wn,pn){if(wn&&wn.offsetParent){var Yn=wn.offsetHeight,ni=getComputedStyle(wn),Un=ni.marginTop,gi=ni.marginBottom,mi=me(Un),$i=me(gi),Mi=Yn+mi+$i;ne.current.get(pn)!==Mi&&(ne.current.set(pn,Mi),yn=!0)}}),yn&&ae(function(wn){return wn+1})};if(Me)nn();else{_t.current+=1;var qe=_t.current;Promise.resolve().then(function(){qe===_t.current&&nn()})}}function le(Me,nn){var qe=Rt(Me),Ge=Pe.current.get(qe);nn?(Pe.current.set(qe,nn),pe()):Pe.current.delete(qe),!Ge!=!nn&&(nn?Lt==null||Lt(Me):St==null||St(Me))}return(0,ye.useEffect)(function(){return ge},[]),[le,pe,ne.current,yt]}var Se=14/15;function Ie(Rt,Lt,St){var Et=(0,ye.useRef)(!1),Bt=(0,ye.useRef)(0),yt=(0,ye.useRef)(0),ae=(0,ye.useRef)(null),Pe=(0,ye.useRef)(null),ne,_t=function(Me){if(Et.current){var nn=Math.ceil(Me.touches[0].pageX),qe=Math.ceil(Me.touches[0].pageY),Ge=Bt.current-nn,yn=yt.current-qe,wn=Math.abs(Ge)>Math.abs(yn);wn?Bt.current=nn:yt.current=qe;var pn=St(wn,wn?Ge:yn,!1,Me);pn&&Me.preventDefault(),clearInterval(Pe.current),pn&&(Pe.current=setInterval(function(){wn?Ge*=Se:yn*=Se;var Yn=Math.floor(wn?Ge:yn);(!St(wn,Yn,!0)||Math.abs(Yn)<=.1)&&clearInterval(Pe.current)},16))}},ge=function(){Et.current=!1,ne()},pe=function(Me){ne(),Me.touches.length===1&&!Et.current&&(Et.current=!0,Bt.current=Math.ceil(Me.touches[0].pageX),yt.current=Math.ceil(Me.touches[0].pageY),ae.current=Me.target,ae.current.addEventListener("touchmove",_t,{passive:!1}),ae.current.addEventListener("touchend",ge,{passive:!0}))};ne=function(){ae.current&&(ae.current.removeEventListener("touchmove",_t),ae.current.removeEventListener("touchend",ge))},(0,Fe.Z)(function(){return Rt&&Lt.current.addEventListener("touchstart",pe,{passive:!0}),function(){var le;(le=Lt.current)===null||le===void 0||le.removeEventListener("touchstart",pe),ne(),clearInterval(Pe.current)}},[Rt])}function ze(Rt){return Math.floor(Math.pow(Rt,.5))}function Ue(Rt,Lt){var St="touches"in Rt?Rt.touches[0]:Rt;return St[Lt?"pageX":"pageY"]-window[Lt?"scrollX":"scrollY"]}function se(Rt,Lt,St){ye.useEffect(function(){var Et=Lt.current;if(Rt&&Et){var Bt=!1,yt,ae,Pe=function(){Pt.Z.cancel(yt)},ne=function le(){Pe(),yt=(0,Pt.Z)(function(){St(ae),le()})},_t=function(Me){if(!Me.target.draggable){var nn=Me;nn._virtualHandled||(nn._virtualHandled=!0,Bt=!0)}},ge=function(){Bt=!1,Pe()},pe=function(Me){if(Bt){var nn=Ue(Me,!1),qe=Et.getBoundingClientRect(),Ge=qe.top,yn=qe.bottom;if(nn<=Ge){var wn=Ge-nn;ae=-ze(wn),ne()}else if(nn>=yn){var pn=nn-yn;ae=ze(pn),ne()}else Pe()}};return Et.addEventListener("mousedown",_t),Et.ownerDocument.addEventListener("mouseup",ge),Et.ownerDocument.addEventListener("mousemove",pe),function(){Et.removeEventListener("mousedown",_t),Et.ownerDocument.removeEventListener("mouseup",ge),Et.ownerDocument.removeEventListener("mousemove",pe),Pe()}}},[Rt])}var jt=10;function $e(Rt,Lt,St,Et,Bt,yt,ae,Pe){var ne=ye.useRef(),_t=ye.useState(null),ge=(0,Vt.Z)(_t,2),pe=ge[0],le=ge[1];return(0,Fe.Z)(function(){if(pe&&pe.times=0;$n-=1){var Kn=Bt(Lt[$n]),jn=St.get(Kn);if(jn===void 0){wn=!0;break}if(Ao-=jn,Ao<=0)break}switch(ni){case"top":Yn=gi-Ge;break;case"bottom":Yn=mi-yn+Ge;break;default:{var ii=Rt.current.scrollTop,Vi=ii+yn;giVi&&(pn="bottom")}}Yn!==null&&ae(Yn),Yn!==pe.lastTop&&(wn=!0)}wn&&le((0,oe.Z)((0,oe.Z)({},pe),{},{times:pe.times+1,targetAlign:pn,lastTop:Yn}))}},[pe,Rt.current]),function(Me){if(Me==null){Pe();return}if(Pt.Z.cancel(ne.current),typeof Me=="number")ae(Me);else if(Me&&(0,Ht.Z)(Me)==="object"){var nn,qe=Me.align;"index"in Me?nn=Me.index:nn=Lt.findIndex(function(wn){return Bt(wn)===Me.key});var Ge=Me.offset,yn=Ge===void 0?0:Ge;le({times:0,index:nn,offset:yn,originAlign:qe})}}}var xn=ye.forwardRef(function(Rt,Lt){var St=Rt.prefixCls,Et=Rt.rtl,Bt=Rt.scrollOffset,yt=Rt.scrollRange,ae=Rt.onStartMove,Pe=Rt.onStopMove,ne=Rt.onScroll,_t=Rt.horizontal,ge=Rt.spinSize,pe=Rt.containerSize,le=Rt.style,Me=Rt.thumbStyle,nn=Rt.showScrollBar,qe=ye.useState(!1),Ge=(0,Vt.Z)(qe,2),yn=Ge[0],wn=Ge[1],pn=ye.useState(null),Yn=(0,Vt.Z)(pn,2),ni=Yn[0],Un=Yn[1],gi=ye.useState(null),mi=(0,Vt.Z)(gi,2),$i=mi[0],Mi=mi[1],eo=!Et,Io=ye.useRef(),Ao=ye.useRef(),$n=ye.useState(nn),Kn=(0,Vt.Z)($n,2),jn=Kn[0],ii=Kn[1],Vi=ye.useRef(),wi=function(){nn===!0||nn===!1||(clearTimeout(Vi.current),ii(!0),Vi.current=setTimeout(function(){ii(!1)},3e3))},bt=yt-pe||0,no=pe-ge||0,Ni=ye.useMemo(function(){if(Bt===0||bt===0)return 0;var Jt=Bt/bt;return Jt*no},[Bt,bt,no]),ho=function(on){on.stopPropagation(),on.preventDefault()},pr=ye.useRef({top:Ni,dragging:yn,pageY:ni,startTop:$i});pr.current={top:Ni,dragging:yn,pageY:ni,startTop:$i};var ar=function(on){wn(!0),Un(Ue(on,_t)),Mi(pr.current.top),ae(),on.stopPropagation(),on.preventDefault()};ye.useEffect(function(){var Jt=function(ue){ue.preventDefault()},on=Io.current,Mn=Ao.current;return on.addEventListener("touchstart",Jt,{passive:!1}),Mn.addEventListener("touchstart",ar,{passive:!1}),function(){on.removeEventListener("touchstart",Jt),Mn.removeEventListener("touchstart",ar)}},[]);var sr=ye.useRef();sr.current=bt;var Fo=ye.useRef();Fo.current=no,ye.useEffect(function(){if(yn){var Jt,on=function(ue){var Je=pr.current,gn=Je.dragging,Xn=Je.pageY,Gn=Je.startTop;Pt.Z.cancel(Jt);var ce=Io.current.getBoundingClientRect(),vn=pe/(_t?ce.width:ce.height);if(gn){var An=(Ue(ue,_t)-Xn)*vn,xi=Gn;!eo&&_t?xi-=An:xi+=An;var Ae=sr.current,en=Fo.current,ui=en?xi/en:0,oi=Math.ceil(ui*Ae);oi=Math.max(oi,0),oi=Math.min(oi,Ae),Jt=(0,Pt.Z)(function(){ne(oi,_t)})}},Mn=function(){wn(!1),Pe()};return window.addEventListener("mousemove",on,{passive:!0}),window.addEventListener("touchmove",on,{passive:!0}),window.addEventListener("mouseup",Mn,{passive:!0}),window.addEventListener("touchend",Mn,{passive:!0}),function(){window.removeEventListener("mousemove",on),window.removeEventListener("touchmove",on),window.removeEventListener("mouseup",Mn),window.removeEventListener("touchend",Mn),Pt.Z.cancel(Jt)}}},[yn]),ye.useEffect(function(){return wi(),function(){clearTimeout(Vi.current)}},[Bt]),ye.useImperativeHandle(Lt,function(){return{delayHidden:wi}});var nr="".concat(St,"-scrollbar"),_e={position:"absolute",visibility:jn?null:"hidden"},We={position:"absolute",background:"rgba(0, 0, 0, 0.5)",borderRadius:99,cursor:"pointer",userSelect:"none"};return _t?(_e.height=8,_e.left=0,_e.right=0,_e.bottom=0,We.height="100%",We.width=ge,eo?We.left=Ni:We.right=Ni):(_e.width=8,_e.top=0,_e.bottom=0,eo?_e.right=0:_e.left=0,We.width="100%",We.height=ge,We.top=Ni),ye.createElement("div",{ref:Io,className:Oe()(nr,(0,ke.Z)((0,ke.Z)((0,ke.Z)({},"".concat(nr,"-horizontal"),_t),"".concat(nr,"-vertical"),!_t),"".concat(nr,"-visible"),jn)),style:(0,oe.Z)((0,oe.Z)({},_e),le),onMouseDown:ho,onMouseMove:wi},ye.createElement("div",{ref:Ao,className:Oe()("".concat(nr,"-thumb"),(0,ke.Z)({},"".concat(nr,"-thumb-moving"),yn)),style:(0,oe.Z)((0,oe.Z)({},We),Me),onMouseDown:ar}))}),En=xn,Ne=20;function Ze(){var Rt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,Lt=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,St=Rt/Lt*Rt;return isNaN(St)&&(St=0),St=Math.max(St,Ne),Math.floor(St)}var rn=["prefixCls","className","height","itemHeight","fullHeight","style","data","children","itemKey","virtual","direction","scrollWidth","component","onScroll","onVirtualScroll","onVisibleChange","innerProps","extraRender","styles","showScrollBar"],zn=[],tn={overflowY:"auto",overflowAnchor:"none"};function Tn(Rt,Lt){var St=Rt.prefixCls,Et=St===void 0?"rc-virtual-list":St,Bt=Rt.className,yt=Rt.height,ae=Rt.itemHeight,Pe=Rt.fullHeight,ne=Pe===void 0?!0:Pe,_t=Rt.style,ge=Rt.data,pe=Rt.children,le=Rt.itemKey,Me=Rt.virtual,nn=Rt.direction,qe=Rt.scrollWidth,Ge=Rt.component,yn=Ge===void 0?"div":Ge,wn=Rt.onScroll,pn=Rt.onVirtualScroll,Yn=Rt.onVisibleChange,ni=Rt.innerProps,Un=Rt.extraRender,gi=Rt.styles,mi=Rt.showScrollBar,$i=mi===void 0?"optional":mi,Mi=(0,qt.Z)(Rt,rn),eo=ye.useCallback(function(po){return typeof le=="function"?le(po):po==null?void 0:po[le]},[le]),Io=Xe(eo,null,null),Ao=(0,Vt.Z)(Io,4),$n=Ao[0],Kn=Ao[1],jn=Ao[2],ii=Ao[3],Vi=!!(Me!==!1&&yt&&ae),wi=ye.useMemo(function(){return Object.values(jn.maps).reduce(function(po,to){return po+to},0)},[jn.id,jn.maps]),bt=Vi&&ge&&(Math.max(ae*ge.length,wi)>yt||!!qe),no=nn==="rtl",Ni=Oe()(Et,(0,ke.Z)({},"".concat(Et,"-rtl"),no),Bt),ho=ge||zn,pr=(0,ye.useRef)(),ar=(0,ye.useRef)(),sr=(0,ye.useRef)(),Fo=(0,ye.useState)(0),nr=(0,Vt.Z)(Fo,2),_e=nr[0],We=nr[1],Jt=(0,ye.useState)(0),on=(0,Vt.Z)(Jt,2),Mn=on[0],Le=on[1],ue=(0,ye.useState)(!1),Je=(0,Vt.Z)(ue,2),gn=Je[0],Xn=Je[1],Gn=function(){Xn(!0)},ce=function(){Xn(!1)},vn={getKey:eo};function An(po){We(function(to){var Ko;typeof po=="function"?Ko=po(to):Ko=po;var ao=Qi(Ko);return pr.current.scrollTop=ao,ao})}var xi=(0,ye.useRef)({start:0,end:ho.length}),Ae=(0,ye.useRef)(),en=mt(ho,eo),ui=(0,Vt.Z)(en,1),oi=ui[0];Ae.current=oi;var Si=ye.useMemo(function(){if(!Vi)return{scrollHeight:void 0,start:0,end:ho.length-1,offset:void 0};if(!bt){var po;return{scrollHeight:((po=ar.current)===null||po===void 0?void 0:po.offsetHeight)||0,start:0,end:ho.length-1,offset:void 0}}for(var to=0,Ko,ao,lr,Ys=ho.length,qi=0;qi=_e&&Ko===void 0&&(Ko=qi,ao=to),Xo>_e+yt&&lr===void 0&&(lr=qi),to=Xo}return Ko===void 0&&(Ko=0,ao=0,lr=Math.ceil(yt/ae)),lr===void 0&&(lr=ho.length-1),lr=Math.min(lr+1,ho.length-1),{scrollHeight:to,start:Ko,end:lr,offset:ao}},[bt,Vi,_e,ho,ii,yt]),Zn=Si.scrollHeight,hi=Si.start,Qn=Si.end,Ci=Si.offset;xi.current.start=hi,xi.current.end=Qn,ye.useLayoutEffect(function(){var po=jn.getRecord();if(po.size===1){var to=Array.from(po)[0],Ko=ho[hi];if(Ko){var ao=eo(Ko);if(ao===to){var lr=jn.get(to),Ys=lr-ae;An(function(qi){return qi+Ys})}}}jn.resetRecord()},[Zn]);var so=ye.useState({width:0,height:yt}),wo=(0,Vt.Z)(so,2),sn=wo[0],Bo=wo[1],Vo=function(to){Bo({width:to.offsetWidth,height:to.offsetHeight})},io=(0,ye.useRef)(),Qe=(0,ye.useRef)(),Hn=ye.useMemo(function(){return Ze(sn.width,qe)},[sn.width,qe]),di=ye.useMemo(function(){return Ze(sn.height,Zn)},[sn.height,Zn]),bi=Zn-yt,yi=(0,ye.useRef)(bi);yi.current=bi;function Qi(po){var to=po;return Number.isNaN(yi.current)||(to=Math.min(to,yi.current)),to=Math.max(to,0),to}var co=_e<=0,Ri=_e>=bi,Hi=Mn<=0,fo=Mn>=qe,mn=Dt(co,Ri,Hi,fo),Uo=function(){return{x:no?-Mn:Mn,y:_e}},un=(0,ye.useRef)(Uo()),Po=(0,Qt.useEvent)(function(po){if(pn){var to=(0,oe.Z)((0,oe.Z)({},Uo()),po);(un.current.x!==to.x||un.current.y!==to.y)&&(pn(to),un.current=to)}});function kr(po,to){var Ko=po;to?((0,Re.flushSync)(function(){Le(Ko)}),Po()):An(Ko)}function $o(po){var to=po.currentTarget.scrollTop;to!==_e&&An(to),wn==null||wn(po),Po()}var Hr=function(to){var Ko=to,ao=qe?qe-sn.width:0;return Ko=Math.max(Ko,0),Ko=Math.min(Ko,ao),Ko},xr=(0,Qt.useEvent)(function(po,to){to?((0,Re.flushSync)(function(){Le(function(Ko){var ao=Ko+(no?-po:po);return Hr(ao)})}),Po()):An(function(Ko){var ao=Ko+po;return ao})}),Wi=$t(Vi,co,Ri,Hi,fo,!!qe,xr),Ui=(0,Vt.Z)(Wi,2),ko=Ui[0],Yo=Ui[1];Ie(Vi,pr,function(po,to,Ko,ao){var lr=ao;return mn(po,to,Ko)?!1:!lr||!lr._virtualHandled?(lr&&(lr._virtualHandled=!0),ko({preventDefault:function(){},deltaX:po?to:0,deltaY:po?0:to}),!0):!1}),se(bt,pr,function(po){An(function(to){return to+po})}),(0,Fe.Z)(function(){function po(Ko){var ao=co&&Ko.detail<0,lr=Ri&&Ko.detail>0;Vi&&!ao&&!lr&&Ko.preventDefault()}var to=pr.current;return to.addEventListener("wheel",ko,{passive:!1}),to.addEventListener("DOMMouseScroll",Yo,{passive:!0}),to.addEventListener("MozMousePixelScroll",po,{passive:!1}),function(){to.removeEventListener("wheel",ko),to.removeEventListener("DOMMouseScroll",Yo),to.removeEventListener("MozMousePixelScroll",po)}},[Vi,co,Ri]),(0,Fe.Z)(function(){if(qe){var po=Hr(Mn);Le(po),Po({x:po})}},[sn.width,qe]);var ri=function(){var to,Ko;(to=io.current)===null||to===void 0||to.delayHidden(),(Ko=Qe.current)===null||Ko===void 0||Ko.delayHidden()},Gt=$e(pr,ho,jn,ae,eo,function(){return Kn(!0)},An,ri);ye.useImperativeHandle(Lt,function(){return{nativeElement:sr.current,getScrollInfo:Uo,scrollTo:function(to){function Ko(ao){return ao&&(0,Ht.Z)(ao)==="object"&&("left"in ao||"top"in ao)}Ko(to)?(to.left!==void 0&&Le(Hr(to.left)),Gt(to.top)):Gt(to)}}}),(0,Fe.Z)(function(){if(Yn){var po=ho.slice(hi,Qn+1);Yn(po,ho)}},[hi,Qn,ho]);var qo=ie(ho,eo,jn,ae),Sr=Un==null?void 0:Un({start:hi,end:Qn,virtual:bt,offsetX:Mn,offsetY:Ci,rtl:no,getSize:qo}),ps=dt(ho,hi,Qn,qe,Mn,$n,pe,vn),ms=null;yt&&(ms=(0,oe.Z)((0,ke.Z)({},ne?"height":"maxHeight",yt),tn),Vi&&(ms.overflowY="hidden",qe&&(ms.overflowX="hidden"),gn&&(ms.pointerEvents="none")));var ks={};return no&&(ks.dir="rtl"),ye.createElement("div",(0,Ft.Z)({ref:sr,style:(0,oe.Z)((0,oe.Z)({},_t),{},{position:"relative"}),className:Ni},ks,Mi),ye.createElement(be.Z,{onResize:Vo},ye.createElement(yn,{className:"".concat(Et,"-holder"),style:ms,ref:pr,onScroll:$o,onMouseEnter:ri},ye.createElement(et,{prefixCls:Et,height:Zn,offsetX:Mn,offsetY:Ci,scrollWidth:qe,onInnerResize:Kn,ref:ar,innerProps:ni,rtl:no,extra:Sr},ps))),bt&&Zn>yt&&ye.createElement(En,{ref:io,prefixCls:Et,scrollOffset:_e,scrollRange:Zn,rtl:no,onScroll:kr,onStartMove:Gn,onStopMove:ce,spinSize:di,containerSize:sn.height,style:gi==null?void 0:gi.verticalScrollBar,thumbStyle:gi==null?void 0:gi.verticalScrollBarThumb,showScrollBar:$i}),bt&&qe>sn.width&&ye.createElement(En,{ref:Qe,prefixCls:Et,scrollOffset:Mn,scrollRange:qe,rtl:no,onScroll:kr,onStartMove:Gn,onStopMove:ce,spinSize:Hn,containerSize:sn.width,horizontal:!0,style:gi==null?void 0:gi.horizontalScrollBar,thumbStyle:gi==null?void 0:gi.horizontalScrollBarThumb,showScrollBar:$i}))}var we=ye.forwardRef(Tn);we.displayName="List";var Bn=we,Jn=Bn},93314:function(Cn){"use strict";Cn.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMwAAACaCAYAAADl9acYAAAAAXNSR0IArs4c6QAAIABJREFUeF7tXQd4U1Ubfs/NaJtO9kzLahFQEJkiUBBFUFFkCCjiAAVFERT5FREQQQXBBcpysWRP2RtkKRsEOphNodCZdDfjnv85CU2TZt2bhABNDw9PmtzvrO+c957xLQIP0pkz1yrQIEmwwcDzHhTj91klEo7jpcG5zetWUJdmRjmPvTM9GI9JgSGvadOoLE9KJJ5kPp2YXLtZdO1kT8ooz2vigCNelvPYezPEG7z0CDAn4pJqPvJA5A3vdcl/S3LEy3Iee29OeIOX5YDx3nh4VFI5YDxin6DM5YARxKb7g6gcMHd+nMoBc+d57LKGhCQ1ZURBCoVL2nKCO8sBZWW50x1TOWDuLP8FlV4OGEFs8glROWB8wmbPKikHjGf882bucsB4k5t3qKxywNwhxrpRbJkGTOx0ehlA3d9e5VEtzA3ulGe55zmg1QOfrCVo34BgQGvr5rLDRl4RRZG+5NjBESBc4FHw1LlrCAuPsCo0JjKi7J5hYqfTXADBq4byCJLf82Nf3kA3OfD9LgKdgeCzZ4CUTJ1VKQFyKQgpmeMSjiKvQC+oplspN/wOMDcBVFv0Bo+KwYJ4VE50H3Jg7j6CWzkEX74A3MrSgTfeKZpSaBCHcAVn/JunBHlFPDR5BkG9LMjPt7mZLOtbskQADea9wqOW9coqiGHlRPcHBxYcJriQQvB9P+v2cqCwWFxgoOJk6JeTNX4HmJMAHv6xP4/6VXw/+OxNx/bM/pIohdUE9VW/VxwjOHiJYO5A6xolpGSpYW3jIW4w/A8wM+h+UHSY2pvHgzV9NXymeor0wPc7Cf7XzWJ/4Nsm+Ly2LzZx+OwZ3yuVbzhNsPEMwcI3rM8wMikHiURi5gNbbQoKrc84zpjkj2eYzQC6f96DomUd305ctrp8tp5gSk/f1utzlFhUOHYthy9f8D1gdpwnWHiEYOVQ6zNM6QM/AY+CImHnF9YtfwTMCgB9P+5G0SHa9xP3bk2gT9cBU3r6Hjp95nBYNcz3gDlwkRhX843vlfS59PmFHfjFzgC/2pJ1nEEnEIpIAG+834Wia2Ox7PJ8wt0twLz7J8Gsl3zf316zCVYPsz5oe85F1yUcu0YwcQPBjlElZyjL8wsrQeyBn+XxK8DETqefgyACFCPe6kjxfDPfT6C7BpilBLMG+L6/A34h+P1VikCZ60nuTYpzN4AxqznjCqPOMZ1RSp9f2OVLYZH1lbOrNvjVlswIGEAKYOyrj1K82NL3E+huAWbEMnbFSn1+Qzd4AcE3fajPZV6X04D3lnHGM4xOawKFJwLLYiD5H2AoCkHwJQMLA42v090CzJjVBBN7UCh8rN3AgDrqCYq6lX3L6RQ1MGQRhwWvA7UrALbnFzCJjOhG+d2WjFCkUYKZPZpSDIv1PWDGrycY34NCahI0+yxN/Ivg3c4UlUN8VqWxok/XEfRrSdG0tm/rzcoHBv7KYc5AILqqLWDcOb/45RmGEFyhFL8/0Yga33y+Tl9uJhjxOEVIoG9rnrqVKSJSRFb0fb3tG1A81sC39TLRSu85HL57Eaii0Bm3oqEKqZXSJaUURUxTU0Tyuy0ZAc5SYCUbxE+6+x4w3+0kGNiWooqP3/Qz9xB0bUTRsLqI2eEFUlbvA9WBJxv5ltdMit9jFocpLwB1InQIkBEQTmLUHStOBoMBOr24K2+/AwwPHOKArS2iKCY9VzKIg34jyMgTv6f1wpwqL8JLHKgUTLHwjZIxZTKg0V2Bzg2tLzvYBYA75xe/25J1mkEnGAzYyXE40KQmMK23uLeLN8b1j0ME7epTxFTzRmnCy/jzXyCqIny+NVryDzFeKfd+xLcrDOMMO8MMfgx45iFrOZA7AstiTvvVoZ91usM3tClHcLpeZWDmAN8DZtlRgkY1KJr5+BC87hQQLAeebCwcZN6gXH6MgG2P+rfyDmD+WLoV8xZugkIRiNh2TTHghcfRoF4tFBZpkXgpGQ81rmdu9puLOLzwMPBYPR1Cgzw/v7CC/WpLxjrc/jtaT2LApRrhwC+DfA+Y9aeI0dKzbT3vTCChk3r7eaBABzzfTGgO79CtPUmM9b7U2jv9bf3kOyjSlihLcoSg93MdkZ2Th227j2Hoq8/inTeeNzZ+xFIOsTHAsw/pAeL5+cUvAdPuG1pVRnArQgEsGex7wGw7RxAgBTo19M4EEjqtD1wEkrPYm15oDu/QbfkPSM0hHsu8du0/gSnfLkFGVrbThjFLynULJ6FOZHUw2RNbyd/qUJLFHZV+ywr9aksWO4Ou0BK8KueRz/bVq++CUuD+RGbhB3R/0LeAOZEEnFIRvPGYb+vdGw+cvU7w3uOe1dv+mfeRk5svCMUfvz8AA3o9jgkbCJQVgPe7lGTz5MDvj4f+VXs/JH1ip1PmAkHy17u8z42bjl4lxjf9C809m0CCZo4FUVwKsDPOJLz0ZTp6Fdh6jtnWe1bvuCm/4q/tRwQ1/b03e2LIwGfw1RaCkADg425AOvPkYCHZd0cG43dbsk4zaDFgWHiHcG85wjBQoEhnMhAzf5r/Jihkf9/+fjXDtDXqGA108+Eqcy0DYAfwMU95NnEFzVgLovibwK8HCab19qze61s24Pf5K7A5KwB5vHM1CblMij9m/Q87rtc1jsek54CMPIBayGD0BgP0ImUw/gwYFiqjllhHGAcvAkuPcijU8cgv0KGgSGv8LNJqweu1MOh14A3ss+S78W+Dzuo3RsPoTy0YgIjQALFz0C36tBzg570EE3p4NnHFVn5TA0zaSPDzy57Vu2bIS6jF67BDHYBHgnVI0kow+6ZjLyZNm9RD+35jkZINfNO7ZIVhEn+e16NQ6157/OqWjJ1h9n1IXoydTi8AeGD+KzxqinCEsfkswfBJC2HQacXOG7v0B+e9CGXVUK+U5aoQdm5iE3eqh296R/XoDEBu0e3/hcz3FzF+Z292trI91Zgav7N2tKrDrrfFTdgTI4dAl61BipZDDXYINRCMvBrusNvBikAMHT8LTM3/pwElK4xMAuQV6uBuKK4yA5hEVfY8SvmmHCETGyjDtzqbQLHf0KMgaCnWEcaW/whGT1mAHHZP6oW09bueaFy3khdKcl0EO+y+v4xgphs2MWxbs+K46bLCDIoi6+9iVLKY4PbTp8UB5t8h/UB53qimz1aJA9lyLExz7H1vyMCnUa15L/x9EfhtkIk/nh74y9ShPz5JnUGA26qFZIdcTofWqR5xxd5Uip1O9wDoJNYRxs4LBB9PXYxUdaHrGSqAYuWUp9GmSQ0BlN4h8cTq8qVfOGgKStpBeAoJb4DEYPrPsU89b/5e/LvEYPubLCIQX06NEtWpfwa/yA4h0FEgqVCK71OCUeTARdLLfbpg9PAXsfGsBBtOA0uHmKpyV0PZsqFl5lo5QaXWgRqNw4pTHiEYGa2M+KX0yMROpxsA9BDrCGNvAsG4GcuQdMt45eJx+nXsk3iyNbOY9k161wOry8/GqZCr1t4GBA/O3T0Nm7gSDl/89IBRHiU0nRk3CgU3knEmT4pZN51rrjI5TN2oGmCOMP44BKx7B8jINemP8ZRCK2Y5LNXAMrMlS0hSpwKw9TRGME+XHf5ekybEfPCInU7/BDBArCOMw5cIPvt+JRJUGqHj7JRu2rsd0P+JGBuanELTTVpwwO3/cnjFxNcTwMz95hquxud5pd+skIEfR6NJA+F2y6o1S3Fj4xpj/X9lBmK7OsDuChMUKMf+v36AXC4Fc4QxYwew/X0gM8/k5VKvN0BvcF9gfc8CJuGWuh4twgoQnJSBzK+nDP+3eLTsBahJSNL8DdD29kaUAFsDSU4vpVJp3FTETqdzAbwl1hHGySSCCTPX41RimlcmzthBrTCsV1Obss5cJ2hWXQupTIoiHUW+1nRYZkcn5kRbTzlIOQq5hBmimfRu2RwoeU4gl5rAFiI3Odpmb/NRK0zXu+zgKzZtWZWK/VvTxWZzSP/EK5HoEivcxsFQWIBzk8caVxmWmMT+g6thNlfMg/p1xYfv9DXSMEcYEzYAu247wnBXQ9myE/fslixRpf6FUgw2N5bgDChmk6Lw33MMqkqlg8JeVKmn8hRjHI0QIdgbiJynGWhiZ9AZoPhgaEeK50Q4wmDCvwmzt+HwGe8EcH67V1N8MshWV4UBpnlNLQID3Lcn5nkKrZ6iUEex4azEqC08di0BW1XDgsTP+2NHsrH6F+/0m9Xetns1PN9b3IWHPi8XyetXIOPoEeg1WbhYKMGK9CCoiiSoWq0SnuvWzqhLVuyoz+wI411mmi3epZI9Lt2zgElIUht9INtpdDJPMUsSGf59NCFFxc8TknI6AoZ9LqbCmj+V4X33zMAEAOMHtaXoJ0KLVpUJjJuzD3v+vSh+xtnJ0ffxaMwY0dHuCtO8pg6BAcK3LI4axCTai/4hRsBM3kww5DGK6o5vYx32S52pw9QxbEi8k6o2DMeoj2q5VVhqNnB29JsI0TP5M6Dj5Gg7dwmkpVZOsyOMtyg4joDyBhRq3d+Osbru3S2ZSp0LCmf+9ZM5CUY3qBWx3LREUy5RpbkKQOl0FAimvrksPAME08Q6wmD74DGz/8H2A/+5NdClM8U2r4VFE7rZBcwjtXQIkHsOGLbSLP7XBJhvdxD0fJiinhs+pVk5n41IBM/UFryQSHggvpxRooovpsgdFwjoD8MQri3ZIso/XYzm9a2FwDfUAFPxX/AaRYSCeCR/KW7fvQuYJE0RQF3vSQh2UQn3bsOaYXEJSZrPADrJBfP5BceCVx+4LO0r1hGG3gC8//Np/LXrmJjxdUhbv1YE9vzU22eAmbOPBRmieNCNFzvP8/jhaxVSL3vn4M9zBJN/bgSZgJsyplZ0KQ24oSZgq8vmE4V4+9hrkNIS8O5uPhbNOz+CprWpWRhd7Ahj9svMYM871rT38pbM/q2XvelHoeU4bpxBgt+Jjr8MAqfi80NXZEW/H1UEuOMIY/zCRPyxZr9XABMSJMP5pbelahYlsjNMi1p6402Pp8lyhWEhIBpVp2hdV1yp6nwgPAhYvzQF/+zOEpfZCfXgz6LRIMrxKsq0B5YcKsL6UxRFvBygelBdLjhZGMCx/RfTKWMCUGZzbAClvJEmtiGH97oEGLdhzBHGjL4UDyvLOmBUmn9AaamAay7GimAXgdErzG1RlX36k9el+PlgsPFtK9YRxtwtNzBl7havTZoLywYhuJRbSCNgauvBlAg9TQYDjyVHOeOWbOVxoEoo0Mn2JttpNZvOcmhfn0KTXoTr8TlITSnCrRSt8TMvV7gj79KVPDskCo+1tb/rZkLScavzcTlTARBrZUu+MB1coHNHZ8rQXEzvH4T+8yWY9DzQrj6QptFDzzRlPUj37JbM5pZMeCfZK5CNgsPt3PlbEny3LwSlHWEIqWLzcTWGfbFaCKkgml0zeyNaaa3QdqcAs+msSa2k+4OCmmYm2nyWQ98W9idabo4eqSla3EopMn6m3mRgKkJ6KlM6dV5Plz418ES3CjZE7Ar9w2X5UGXbv3bmC1NBAiqBEOf34zFhKlzLq40PuxK0i8qFutBzRdd7FjDx1zSDCKELxA2tmZoyyztqqc9tUdDlDAm+2hUCdxxhHIwrwOAJy5EvIkSCsz78Nq4rnmhpfU/BANOytgEydwQmpSpjQro/b68we+JNArzej4jjKouz0q+luDwGAzWCxnI1Kr0qPfpEZTzXv6pVwUzf6+MVBTiX6vi+hxoKQfUF4AJswWZZGF+UCUN2IsYMaINnbcVd4jp0m/qePcNcvJlTldcaUm5vVN3qnKNM1zUcJm4LhTuOMP65qMWYGWtxJcU76jGT3nwUrz1j7ZnCCBilAbLS96RucIFJtv88ZpLD/HMZSEgFXmkrrqANp2yjEYsroYRar6f44I3zxh9qNwnH8FHWNxBLj2ix6F85SKltmGV9lBrAF6RConCuh8fotCn7MSC2Fob3ELkPddDBexYwrL2JSZqtFPQpdwfHUT7mf+zjTWFwxxHG8St6zPhtCw6cZXcSnqdhLzTF2FethZcMMK2UBki9DBgmbz18mYAJbMUk5shiYBsxORzT5ucZ8PHbcUaC4OpBGDe55AbiShqP9/40gHLOt058UZbxXMPJnQuUKK+DLi8DEs0R/PJBLIIVwjULHPXgnt2SsQbHq7JeIJSYFIi8mNgeeeT6cFRQAItFOsL4L5li0do9WLrLriK06FZ2e7QO5v3PwugcgDcBo9MbsPT2CnMxFcYwdiNFuMhlKjcs/J23AMMEoONHJhj5JA2T44tvS2TTo5cX4kKqY5X9YuYacq9CEhzlMngmr8uGQasFLUpDPcUV/DCiKwrcNBwrrvueBsyKFVTSvG32aQraRPRMdJKBWaa+vSrcqNAo1hEGsyD8Y/1R/LzmjFea1EBZAbtn9rIqywiYSB5Siecey3U6A5YeN23JmCCPORIcK8IWhV0ps1Wpj8hzjyPmsDPN5P+ZNCWInMOXPz9g/PtgohZfbpEZ3SE5TxSGXBUkIa61vPnCDLCzFEuGrOMY1q02Xunq2VS6p7dkrKOJ17N7UAPP1PG9moatCoOBJ9go0hEGe+P+vC4e3yw84JX2VAoLxMmFL9sApnUkD4kXAKPV6bHsuNQIGDb5p28nmCwixmZSJnA5jeCZh1x3NzfpKi7M/xlFGRmo0qoNqnfohPAG1mcH1dUCfDP+sqkwjuCreY2Mf478swiJGa6V3Az518EFVgHhXMu0DYUZ4G8Dhuqy0Sg0EfM+8myHf88DhjEzIUmzAaA9XA+ZcIqR60KRp+XgjiOM3Sdu4s0vtyAkSIrgQCmCg6QIYZ+BMuPf7Dfzs9vP2bPi34ICZTh2szJ6NM41HuyrV7f2G8tWmNZRPCSc5yuMJWCYGcjHawm+7Sv8DPPfdSBfS9C5oWveHhg+GFqNyfRBEhgIeWgY2kz7AZysRDh5KT4fP0y5vZ0lwBdzGoO9FwbOK4S6KMDpCkP1eaD6fCNghCSDNhe8zmTsVznrMD59XIGa7Wx194SUVUxzT2/JihuZmJJThWoNZ0HgNY/EH28MRUY+B7GOMFibcrJzkJuXB3Z1zXHc7U9ivNlh0mX2aXpm/7ekLA57E6R44zHm5slWAs0A0ybKpDDoaWLhHJafMK0wLIm1ujx0iYD56WgrQO3ryuplSN6xzajkqM83+RCr1aUrol95A5zUJIT971QO5n2bZPybXYRNntsYvx4guLJrL1qkbsD2moOQHP6wlUskRkt5PfiCm5AEC/exa9DmgNcVoVL2KQy59RsqhAQg6tPvwAU5U1F0zvH7AjCsC4mqnE6UGpitvsfSJ0IIHb8lmNzIlkCsIwxPJzDLf10NrDtJMNyBjzDvAkaH5SdkbgOGOf5oVAN4sKawnl+YOwspf+81EzPIh9VvgCbvfoDAKlVx9JAai+ZcNz4PVBBE9W+M07uPo9/laeBgknSeC22ObbVeQ06QCRzselivuQhZBNveCX+JGAoyEZEThyE3fkIYNa00yh69UPdF6y2wsJ6ZqO6LLZl5pUlW9wHFMkrh6mTokgdf7QzG5UwpxDrCcFmwAAImPPztIMHorva3RkbA1GEhGoRPDkfVMj/EVoARaabM2vliCxj9QQtJ1GDAtU3rcGPXDmjVWWDfWWJbtHp9BiCwRScU6KQICJRg4VEp4g8ex4tXvrFSpGT0JxXNsKraIEgVFaHLuQ5ZSE1wAeLsEioRFZ5PnAVlTok5hiQwCG1+mAupwr1V5r4CDGNkgkrzEij93Znqi5CB/XafAhduySDWEYaQsl3RFGiB6Tsce4NkgGlbx+WtqatqjM9ZlOAVJ0tWmPeWEvzYX3gYcOY9cuKzsLE1EVK5oagQJ7/4DDlXS67gZTVqI6dlXxwNaIXrJ06j75UZkFhoHbNyK7Zqh2E3usHAlCupDgFhtSAJEmdsxsqJqZSHevmJaHPoC6vm1nvpNdTu7t6R+L4DjAk06t7M+tKuDb+QkQTw00EFTl2XQawjDIHFOyVj6h+frSeY4uC2it1MRVXgIeUIpBLTWcjdxMJArDgpN2/JPlpF8PlzwoPDjl9v0vZ1N2k1apz+ehJyVaZzS3HimUMKIoWUWrusqtDqUTR46308/bUKekghU1QBkbq+PbPXPkNuEog8DAOS5+ABzVEzSWj9GDSf+JVbXbovAcNs+oODFYSjsp8oqCm2gcj06z9BOHJNbjTZ7RDt/oQQWa2ZXEw0ZWY1yYzYGdCYuj5L7AJNwgBlvHRgj3mjnfvtx0YlS/Zcp9dj6wU5nmpiysccdLMYm5UECr3HruHwQ3/P+KPLzcWZ6VOQfdG5xWbVzl0R9fJgEI7DjO0Eu85rQSTuH1lbV45HbmYSzl1OR+2im4g0ZEJpyETdAC26zpnv1tDdt4AptulPNJ1rplMKUY6uFh8PxL5LARDrCMMtLtvJJAYw3qqTlcOCw7JYLUoBwWHZWWvBIYJxz3jeAiZxv7R0AZJ3bIetdT1B7T4voebTPc0VMbe2G08Wur26sII+6JyD5x4JQU6+FkfOp+DA2es4fO4GsvO1qFk5BE3qVEaTupWNn9G1K0AmILT1fQ8YxhhKqfTi9ewBoPQjSiFAxAasOh2AbfGBRr0qMY4wPJ86phLuFmBm7ibo2oSioYAL+uPXgKvpBIMe9VavgctnE5C7fyuyz58Bc2oRVKMWaj7XBxVbWGuELjxMsOxIAYjUtaqMo9Z90CkHz7WwXkoNPMXZy2k4ePYGDvx3HVdSTHIjBqCVn7verJQJwBQzjKnzJyRlPcZJuJ6UxwsAHEoP/joXgA3nAiHWEYa3ps7dAgyTeTwSRdHcuecDYzdXHCN4oBrwaH3v9Fqr55GWmY2ICNe3XWtOEvyy17MVZmRsLnq2dH4bdv5qBt6Ytg3d29TDOAFvhjIFmNLDGp+c1UxCycs8xTu3jcrMJDvi5VhxOghiHWF4Z+rcvRXGGBy2EvCYABB8sZHggycpqoa6f+lgya/MXC20RUUIDXV9gGJueb/d5tkZ5r0OOejd2nldm/+5gkkLDuOzQe3QrY1r2+0yDZjiwbp4PUNJeelKSqlZSX3/ZRkWHVNArCMMbwFm/AaC8c9Qt65rPWkDCw7Lggw9YVLhcprWnCCoH5qKGmHUaC4tl8sgl0kgl7FPqWhdt6upuQiWc1AoXN96MSd849ez62/31YPeeSwHL7Z1DpixvxzA7hNJWP9lL1RmjgtcJL8ADOOBSkWDCqiGaQoYlYn+TZJh/hEF3HGE4YqpQp7/sC0PrzRPhYxPg9yQjmCkoTA/HUV5aZDq0wBZBQQ0my6kKFE028/BGODpOYHBYfPy8qDT6aDT6Y2flolpUxeDhznscAWkfxKzEFNDAbncteIk8xIzYinxSBj1VrtcvPSo4y0Zs0Z96qPVqFpBgcXjnhXEx/saMCZfZNmTQCjTmZCAEC0oUglPU3iOnDEYtCcb16nCrDaN6ZxKU1HK0xOEIOrMDSlmHnDPEYZLzhoKAW0aivLSQXRpCKRp4HTpKMxNAy1KN36XE+cRAHjKIb/pckhk7h967bXz70STao47wWHZ9bZebwJOMYDY38Zrb4vEtKwZeAKMq5IJSDKZFOuPpqFr8yqCNBjYDd3AXwwgnPu+2Qa3zccrjzleNY7G3cR7P+7G8+2jMWaAMH8r9zVg4pKynudA1jmawExnjKf8fwRkAwF+j46MuJSoyupEKdkdnyoh0/e65wjDUX1c3MdA3hUEEO+YL6fU+BwRNUQa07tAM7v5OpNM8LoXg8PqDXrotHrojUDSQafXgXmrKZ3i0uV4vKkwiT2TJ/WcqYWBBLp8PzkieK1NIV5r71iO8/2qE1i2O8542GeHfiHpvgbMRVX2RzzlpwnpKCGEOa76i5dynxCeTriaTvpP2RnqliMMhwC9MBaBBaeFNEcQTU7FvpDWeU0QrVCiCynA7jjHip9Cy3FFxxz/mVYi0//sPD2u5wWgXUOBSmkAXvtVj7R819s3R215ta0Orz/m2FVVnwkbkJyWa7xOZtfKQtJ9DZiEpKzXAfKbkI6W0JAiQrDyZjZ5adyWUM4dRxiO6qOqRVCkLRPXHCfUt2gjhLXw7jmGBYdl18Uf+Tg47K4LBCz0uZh6P1oJnL/p/qH/5dYGvNnBfv5rN7PRb9JGVAoLwoavrC1enQ3gfQ2YC1ey6kil3CV2lhE7S7MKuMIxf4UGuuMIw1FdhszjCLk6XmxTHNLrqRT5TVdAJnNfPaR04cbgsPsIJjzrmbqL2E4evgxsPy+uXubM7+Vfmbss9661X2lDMdhuABRgyc4LmLnmJGKbKfHlW8KNyu5rwLBBS0zSbKBuWGOyWCoj1rrnCMPRZNEX5SLk3ACmVih2PjmkV9WYiso1RHrec1I7i1HJ5Ct3Kjiso6rPXgeY9P6bPsKB2uSRWKSlZbjNy3FjhuOTD5kIzja9891OnEhMxVs9muHVbsL5e98DJu5ydkNOxh934enfhmPsUDl0ZRgCZUS0IwyHWzJmqPPfcATorrk9yKUzZld5DTKlKUCQNxLr98jlJhV/X6ZrmcBXmwnmDBReb2R0CxQWmiOaiG5uj+5dsOyPH23yMd2ybmNWg6nJfDv8cbRpLDzO6H0PGMaN2zYyi8Q6/Ru+Ogw6A8FfIh1hOBs5evE7KLJ3ih5cRxluSR5FWLNxXiuPFeRJ6D53G5KWC3y4gmDhG8IAw7Ssa9Vlpsrup8jaNXHh+A6bAnYcu4bPfjto/H3z1D4IZ5JcgalMAIb1NVGlHkwpmQ1QwRf3H6wPRU6Re44wHPHXcGMTQm7+LJD9rsnU+soIaO2ux1z75Yu163fdStcUuYXA6wsIVg4VBpjMLDUeaOrgAOK6OjNFcvwhVCiluzbh90PYdvQqqlcMxuovSjSkhRRbZgDDOnsxOaczpYaFlEKQp4Sxm0KQlidxyxGGI+Zqs+IRfuUDIbwXTJMWsxghIc79CAsu7C6Ndg0lAAAdVklEQVStMEws88Jsgg3DhQEmSXUdLdt55hLJuIKs/g2x7UvcdrJtWPcxq40q/h2bKfGViAM/K69MAYZ16NKlzHCDlHwBwr0FUKdr7efbQpCs8a4jjMKCfITHDQRH3d97l578qmqTUblWczGYcErLzjDT+/hej63HLA5r32YOCl135dyFeHTuahtsynVOa4qvPv8II4aVyLJOXUzFsG9NW+bXuz+EISK9lJc5wBSz69KNzEheLxlFQVnEIrvmUlN3B+NiuncdYWi1OsjjP0KQznvxIDVVh0Bem1kreCcZg8N2pwhzX4juVkN6zebwx+u8oHr/OXoCPXrZBpsSW/GAvj3wy6yvzdl+WnsKi3aYnKFPHtIBnZu79qBpWWeZBUxxJ69coYE6ae4zlOqfIyBPM59uxc++36/AuZvedYTBJNz6+OkIL3AVn1b40N8K6oawRu8Jz+CCcvImgiEdKKoLF7p7pe4B8zl8148XVO+uPQcwYNAwj+tt0iga/+4t0Z4a8MUms9HY0vE9ECnUHc7tlpR5wFhyfA+l0lqq7L4A/QlAhTmHgnA8We51Rxh5FxejcvZSjwe7uIAk/cOo0nqK18qbsYPghebUGO7Dl+n1Pzh89iwvqN71G7fhzbc/9Lh5LALCzr+PQVMkR2w0Na4u566m49J1tVElRqyDEb8CTDH3LyblPMhTw67fjwZVPXTV+44wspP2oVq6IBU3QRPiprYWwtvOE0QrhGj2PoKO0dSoR+fL9O5SDm/H8oLq/XP5Gowc7R2tic9/XIlNyU2wY5RH1gJGVvklYFjHL6k0Ty85EbhxV6KceNsRRuatS6h1fYTX5mK+IQR5TZcbDb+8kVhw2MY1KFrV8UZpwsv4ZC3BCw8LC0o7/7fF+HRCydnDWS1FOSmQh1S363aX5XtlxGTEBfbCxveAIMFCB/s1+i1gGDsGL9Cvvpgm6eVtRxgZGZmomTQYHNUKn01OKHlIcEG5AfWE+eB2WefKY0DVMCDWO0G5XNZXTMDOTu3qUzxuinDhNH0/cx6+nGYrpS+diflxLkhPgFRRGfIQ+wzq9OxA5DUei5VDgYruObw0V+vXgOn8LR3L85jibUcY6iw1KiV9CLnhpqt5Ieg5DxkOV16PRyKFyTBcFbrxDPNZJj44rKtyXT1nvsYaVqeC4k1OmfoDfpjl2ncYb9CiMOOS0edyUOVoEGM4cuvUuGkrBHdbgIVvALWs4++6arLNc78GTOx0yq6efvS2I4zs7ByEJY1HkNYUactZ4kkg9FwE9JIKMEgijH8bjN/Z36bftCQcudLaeKC6q9KEPd8dB2Tliw8OK6x0x1Q/7SWoGkrRt4XrksZN/Brzfl3skpB59S9IN13hy0KrQxZkK+ANCQ1Do7ePYO5AoIF1DFqX5Zcm8G/AfENfB8Fv3naEkZubi6CkbxCou2yc9CZARJgBwcCRVlgZV3KC0aSmAhwnQYBcYowHI5FIwIN9MjPfkt/shcUQPdq3Mxy5DLDwfQNFBod1t77ifMyxuVxCBdX7wZgJWLzUdXh3Zh7NtmSgPCQBIQgIt+8/qtmw3fj5zep4yDoGregu+TVgOk2nTNl8pbcdYeTnFyA9U2MMDhQYIIFcwoGTSGCgnHHLECTnIJVIMG2H1BjywtcCRBYc9shlgrdEBocVPbtKZVjyDwGLLyqk3mHvjsGa9ZtdV0k4FGZdBa/NM/JbUcX+wSy692z8PDoWAjwpOa3TvwEzjXajHLa0b0DxSXfvnA9cj3AJxfe7TG5bq4aKyeU5bWIqsOkswcguvu3zyuPE6IBDSL2DBr+Hrdv3uOxshVqNkZqwH7q8NCNtYKUG4CS2V2G1OozE7ClvoZOHFx3+DZjptD0F/m4RRTHpOd9OHja4c/cRdHuQGh3r+TKxScuMuXz9kmDRmM/dgKB6+wwYgv0HjrhkS6+Bb2PlbzNQpDbZILEtGdualU4VH3gaX0/92ii89HZSVpY7NQllzvOLfYG7W7d7Nqe3a/NGA1hR7WfQZhKKU0yAN62396wkhTKFyUPa1qVo6KXDvNB62YH/2x0EXzzv/cnjrA07zhPsT4SgepkeGdMnc5V++nE6Phz/PTITmEIlhSykOmQK24M/W3mmzV2Lpxp7f5z9BjCPT6P1DRwuetMRhqsBtnzOnFHEVAMeVvp24hbpmata4lHcFzH9LKZl8TJXn4Cgep98+kWcPmtSknSWVi/7BZNmrsc/G2eC1xVAqqgEeYjtVRjhpPji1wN49qE7x+uYyAi7C4E3XvA+XWFU6Vo1ABsP2MzJwvDlMnjTEYarAbZ8zrYoVUKBR+vduUF01J67YUR2OhmYs49g9suu+9uhy/OIT2DyFedpz/bVWLXtFL77/F3o8zMhCQxHQJh9nZ/RU5diYJc7p95QZgCTnKHLppTaHK3Zm3bwYhkqKIDFg72/VLsabLZFYbYhnRu6nkCuyhL7/G4AJuEWwKT9QsyUWz3WDdeSkl1268zR3ThwLgtDBzyFIo0KnDwYgRH2VfYrP/jCzKTdX3pPZ8ll60wE990Kk5yhi6OU2kSaZx5OBy2UIkDqPUcYAnloJDtwkSC7AHj6Dm4THK4wIoPDiumXI1pVJjBqBcGqYa5fEA+16IxbqaabL2cp+dJJ3MqRoGXL1si7cRKcNAiBFe2vIopqDZemn133kqsyvf38fgTMJkops4WxSUOWSFGoI9joRUcYQhl+SgUkZZK7EtBp3DpgsjhzdqHdckiXlQcMWcReTq4Bw+z5mV2/sxQcrMCVuH+NoQof7DwESf/+aTz4B1WyH8tDHl7zhDpxlwA9A4+7alXAfQcYVYb2V1C8YY8N7y6XQl1AsGoojyD3vZK6zWHm9siDmK9u13u3Mgrtb71GbZCbm+e0mbVq1cDJIyavMK99OAvrfp0IfVEOFJWj7earUKUG9mxZ45WuOzqv2Cv8vgNMcqZuCuXpWHudGb1GipvZxKuOMLwyIn5eSGSDR8AiQDtLDzZ+ALu3rTKSzPrzAMa//xK0OSlQVLHZfd8uhuDQ/p1QKDyPiFCmAaNK17KD3g/2mP/ZXxJcyeAw/xUeNT3UZPXzOe7V7tes2wx6vcFpme3btcaa5SbX2gfP56Dnk62NipiKqo7tB1at+BMPPdjE47a6kr1YVnD/rTAZ+r6U8ivscWnyVgnibnL4sT+P+l6yN/F4NMoLQLXIh2zizpRmy9PduuCP+ab3YE4h8OCjzyMzfrvDMwyjm/rVZPR8vofHHC7TgLmRpetoMFC7Ximm75TgVDJn1G96srHrw6jHnC4vQBAHqipd+zvu/2JP/Dhjsrm8zv0n4sSWHx3KYRjh0DcH44NRnt8sl2nApGTROnqD7oq9kZq1T4IjV0Q7/xc06OVE7nPg6DS2bXL+AqvW4hVEdvnEXEna2bW4uGY4pEGO99ZPPv4YZs3y3DNpmQYM42hyujaBAjbXJxvOcFhxggHGI+UD92dGeU67HDg6/SGAd36GqfHoMNTuULJaFGZexem5T4CTOL7ufCCmAf7dv0EQ11MyrWN6WmYq84C5lqEdyVF8J4hTlkQc+URZUSbMG4PowsVlSEhSO3zlBtm5+alR0UOPD+KaZ5fa0aQryM+3oi/d/ocfaYOCQudxQCeOHYUPRrxpLocZk8U0i8Wt1HSHLQ+Qy3Hj0jFjzE1Xya8Bw4IuJWfoFgJ42RWjip8TQlbVqijtbwz3dw8kfwJM23YdkaXWOOX6tMljMWzIQCuawW9/hJVrNznNt37Fr+jc8VGXI+rXgCnmjipT353w/Es80IIALDAIM56QMFBQSpmkLAUEJzmeX1qrSuBfLrnqQwJ/AkyXJ7sh+bo5ALZdLs+cPgmvDuxj9ezPFesxbETJucZexrfeeAnTv3QdQqTMAyY5TdeZEspcjdjXjfDm5Ka4REDerF1F5tos0Ev1+hNger7QGxfiLzrl3PyfpqJfb+sr4vSMTDR4qCOYy15HSVmrJs4ddx3Dp8wDRpWhvQQKYfGjvTGJCS4rK8nvPDhvt9WfADPwlUE4etx5ROpFv/6A55950mYkn+zxMv45etLpCB/esw5NGjm3Vy77gEnX+lyQIua2xFOM+hNghg8fjp17Djhl2aolc9C1i21A1x9//h3jJn3jNO+EsaPwocWFgT3isg+Y8hXGatzv51uyTz75GGvWb3E66Teu+h0dLYIlFRNfuapCs7bOgzG1a9MCW9ezKI+OU5kHTPkZxnrw72fAfP3VFPy+yK42k7mTOzf+idYt7cfB7PBkH6cmzsz/29ULhxAe5thlT5kHjOV0SUzKfp6CLwkMAnIjJjLcyo3bRZV6Kk8xxpyPIjsmqiQgYkKS5jpAzfauBFzP6Miw9Z5urdzN709bsjmzZ+K7mb84ZdWBnavR9MFGdmm+/XE+Jn7pXOy2cP536NnD8UrkX4BRaSZQSieauUnIphhl+LNWoFJpFlFKSy7yCYmLUYabRyBBpdkISp8pzkMImRitDP/c3QnvaT5/AsyyJQswYcq3Tll29O+NaBht/45HyLZs0Et9MOvbSQ7r8DfArKOUPm/BjSkxkRFWl++JKvUuSvF4CSCwO1oZ0aX4e0KSmmn2fWoBmPXRynAf2ymW9MCfALNt8zqMGD3BKWDOHt2BKKVj36+du/XD8VNnHZZRu2YNnD+xqxwwjAOJKvU1SlHiDYGgT4wywspZb8I19QUQlBhPULokJqqCecVJUKl7g8JkocS0zQiSopURUZ6uFO7m9yfA/HtoL14Z8r5TViWe2Y9qVR2HUftp7kJ84iLGjLNVqsysMKcTk2s3i67t0KXIheTsSlJK0yilJRqVFPVjoiIuW59z1Ew5q8T9EsE3McoI85km4Zq6HgjMvn4IIVRPSJVGtcMy3J30nuTzJ8AkXjiJZ3uXRD+2xzdV/BGEhzsO1JlyMxWNHnncqRDzmymfYuhg+9pS3gKMq/kqZE54pBp85sy1CjRIEmww2BfnKoKC23NEsrzk/IKc/PycRjzTzrudQoLCAi3BwH6mlH6eV5Bjjo3HEUIUitALoDBfpfDU0C+/IM+5gEAIB9ygCVGEXXeUrawpX2bcvIx2jzuPHJ167SQCA5yHZevR9w3s+9uxy9mnn+qMZQtYyFPb5Awwaek3BcUBkEg4jhQY8po2jcpyY8gtprAnuV3kTVCpPwKFOcgkIdgbrYzobJntokrTgKfUKjY4B/RvEBlRAjTT1m4Ppehk0fIxMcoI51KxO9Q3f1phaFEmHmhuNWQ2XNWknHMYpq+YePGytXhnpPkYalNGSEgwkuIOQyq11V721grjjeng0QrjqgGJKs0SSqmF/ynyfUxk+CjLfAlJWR0BYmWFKZVyHevVDPvbmk7zHUBHFv9GCPkzWhkuWOPZVVvFPPcnwFQI5lE1qrlD9jA1/bSkUy7Zl52TiwYPdkBhUZFD2u0blqBta9u6/AcwSZrzFNR8PcxR8mqDqHCm2m9O8Uma/gTUKjY4R0h0A2W4lcbfxWuaQTyhC8yAAbkQHRne2OVI3QECfwIME7pWr9sC+QUFdjkZFhqK5MR/BHH5taEfOtUa+GT0u/hk9Ds2ZfkFYG7coIo8gyabUpiDHUqItGl9ZYjV/WJikmYUBbW66A+RhgfXrEmsLJsuqXIfMlD9mZIVBoZgSXhYaTpBI+chkb8BpknLJ6BKvmGXa1WrVMbFs/sFcXT7rv3o8/Iwh7SO1GT8AjCJydmPUp4/ZMGdwmhleCghRG+11VKpp4HiI4vfNDGRETbG4JRSaaJKk8Ni9ZhBw3HtomuHHRY0Wl4kEgsYL1bt9aJcWVyyCnv1HYBz5+x78K9Zswb27NwqqF16gwGxnZ9Eerr9y01mffnv4QNQKIIElceIfKl0y+q7Y2eY+CTNOwS05NqDkKMxyvDWpTmRqNIsppRanEXIhRgHW60ElYb5I21VXAYFGd4wMtxzTwqCh8dE6G+AGfzW2zhwwPLdV8KwunXqYOtm4VpKX0+bjt//cKxs+cu8n9Gh/WOCR6TMACZRlT2PUr7E0Jtw82KUYUNLcyL+mno3ISi5hiFkV4wy/Al7HEtQZc8F5d8q2ZZx86OVYebvgrnsIaG/Aeaj/43Fhr/smxs3bBiDDWtXCubohbg49OzVzyH9kMGv46MPzXc7LsstO4BJ0hyloC3Nkxt4JzoyYnZpDiRcU8eBwOxTlFK6uGFUhVfscSoxSf02BcwrCgE5Fh0Zbl5xXHLXSwRiAXM/ayuztn88/mv8PM/qrsbMyRbNH8KeLVYSAJdcZnKd/87H26Vr3uxB7NtmrR1d5s8w7LxxUZWdQ0Etzhvk0eja4TaSq4Qko4cFs5iYI9y0Bsqw/9kFTLKmLeWp+cxCQAobKMNszkUuR8xDAn8DzLTv5mDy1B/tcq1d25bYus4+mByxedacBRg7cardxxzH4VrcYSt1/zIPmMuqzKZ6ylnatRpCpPlhNWvWtLr5unmTBmdrNbmWnCOUjIqOCv/eHjdv3LihyNUrspmzjOLnUsI3q6esaL498xALgrL7G2B+W7gcI8fYVw5/PPYxrFvO3DcIT2npGWj4cGfo9Vb3P+YCmMSfSf6LU5kHTPy17FcJ4f8o2Y6R89GR4Taepy+pNNEGShOsAYN+0VERDi2WEpM05yioWf5CKfdaw6gws3xG+LC5T+lvgNmwaQcGDravgNm9a2csX2hfpcUZh/u/+i42b9ttl2T40Ffx1eclm4wyD5jEJM131FoqvyRaGW7tuMqo7pIVSynZa8k1Cr5jw8iKVlJ+y+elb9UIyPfRpbQH3IeCsJz+BphDR46jW0+7x0qj4RczABObNm7ZhZdef89uNmaMxozS/GaFSVSp91KKWAtufBQTGTG9NHcuXtf05w3WUn4CNIiOjHAYhTQhST0agFmHjBDsi1ZGlOiYiR05N+j9DTDxiZfRqoOVzZ+Za/369MD8WfbPI85Yq9Pp0fDhTmDumEondo5hZssRtzWgy/QKw1T5L6o0WZbq+pTiiYZRETYWQolJ2R9Q8DMsGRakDFcoCbGvhwEg/pq6CyEwO7MigKaBMrwCU/l3Y+67lcXfAMNC9tVp1M4ur159uQ9mznBsLemMwWMnTMOsueaduxXp0j9m4ZluJpvCMg2YxCR1fQqY9cDYRA4MC6usDCc2r5KEJDVbKdiKUZzUMZERFZwxWaXSVCwE0i1tbFytSm6hwkkmR4Cxp9rPirnfr5WZM75KymYwGGw99Qr1XmmPnefjEtG2k6UxbgmV5TmmbAMmWd2H8jBLsgjBtWhlhN1wuglJmiWAlTbz+Rg7lwOlmZ2oUl+lFGaLS8Khb3TtCLNFprcBUro8fwMM6z/zYpmaZutc/L23X8eUCZaaTeK437l7Pxw/aWu+3Oyhxvh7h2lIyzZgktRTKGCOY0kI1kUrI+xaICUkqZl715LzB8WumKgIu1J+y2FIVKnXUgqzTT8BvoyOjHBsbCFuDF1SiwWMywLvIoEQXTLWvB49+yAhwcpsydjqYUOHYNT79g/vQrq1bPkqTPj8CxtSdo759/DfCA1lLrcdp/te0p+g0myCRWhx5jGmYVQFu5f4CSpNHCg1S/kJIYuileGDXDE6/lrWBOY5xkxHyOYYZbjZq4yr/J4+90fAvPbGWzh8xFaNf8S772D4OzYaT4JZnJubi/Ydu9gNqTF39kx0irX1qGlZuM8Bc+PGZa86k8jVVzwGwOwRQQLD4CCpxq5LkFxDxXOgCC5mAOEwO5jLdHnlUqAP72KA5FcLxqWHSDPNajiCR8tNwlx9xav2sjo6w9ymTeCobjTR3bpjQlaDvLbddjnrptAV5oPRH2PTZlsPmLVrVv1q7+bf57rJSmO2Zu36TM3LLzArmAVWqo+qD/dD96c6Y1T3CiASx/F1JNpku9t9T9rjLO8d01a+Uw0uL/fucCCoSqPvCYGN9JJS8n5B2nn7ejMCmxpUpUl7TsL9HRHdBVWbD0CYspXRNZA+Lz394IQq91SI4HLACBxUfydTVGs8FpROseUDHZafGufRCtNxOh1nyM+YKFVUMqs86fLSaW7y0U1n5j/teahlLw5eOWC8yMyyXJSiWqMhoLBRGiOUvpaXFueRalLsdPongAGMfwUZl6G4sARtcw4e/XrXNhv7qbvN43sCMGcSUyy1Asw8aRpdw+gcw9FzMcwrLktMnnLaEg4oqjV8DpSzsRSjPAYUpF9Y5gmvOs2gbXke069tm8A9l7enaYNQWXCAhKMNK4ZFdl6yxqHfO0/qdDfvPQEYdxtfns93HIj9xpBm0BVUpgYteH0ReL0W1FAEWXDl/w5+VvEhIS1JSbli98VYnLdGjbr7furWZVGYXDawYlAAgmTSMY8vXn1XXGk56k+ZBYw3ViV7TLvXVipXk1DIRHZGwyYxex47nf4LwJ6xXuK+0cR5CDERjdjzWs8IXsvdvJRTGDDt7HXt9QLtmIJbF34QUcQdJS2zgLmjXPPHwmu2UCj0+SxYr1XiCN8l91a8fT19kXwqBv9Xg975fuHZaw9reZN6YLWqlfYe2rGoRO4motxiwIvI4pS0HDDe4qSflDPrqS5aA6UyAtAR23dz3u52gyffH3vj9HYWrcE0Nyl0lCOjC255dnXtrXaWA8ZbnPSTcna/3PsyBa0LILPLkjWVvN3tyk2emp+fljTEVC5N43j0zU2Ps/KM6u06xZRXDhgx3Cqnxe6Xe12gYKFJSF6XJaudK3qJ5xdRVG3ETNvZJcI5nqPPFt6ME629IL5a4TnKNGAopfLkbIRIDAgBj2BQnUJPiUIqQRD7JNSgAIgCBIGUkkCOIIAHH0gIFwBKAkH5QEogJwRyUCKn4OWEcDJCIQeBnFLIACoFAfOgLQX7TnH7O5UCHAdQCQjhQKkEIKbvAGf8m4DAFAqEEGIcCnLbbMH4m3FDAtDbtj70dtADCmb7w/6B8gB4gBiMfxNiAGW/se8sogLRg0IPYvyvA2D6DqIn7DuFlhJoKeV1BJwWhGophZZQaEG4QhBaSClfxIEr/HbR1mZrli2unp/8X6tcHW92bhJdv/6cLRvW/AIiyweHPIMEubXDkEsI0QqfhibK4KqNXqEA86hxOF9X1B1Zl5mDlHsq3dOASU2lIQYZKuv0usrgSCUJIRUBvgLlSQVKEMGBhPOgEaB8OEDCKBBGYAyJEUKBEAI2ocuTOxw4dfoMzp0/j/j4RJw5+x/i4uJZGBKbotq0boWFf9jGwKSAjgDMwUkuBXIIkA3QbBBOw4GoeVANoVATjmYBXJaB0syWrR79SSaX33rhuef7zpr2P/u+ad3pjBfz3BXAUEq5lCzUNhj0dQmhUQBRArQWBalBCGoAtBqlqAZAuM9QLzKlvCjgzaHDceCgydslc+Eqk8nNoSiYIRn7r9PpUCEiAn/vMxvAepN1BYTgFkBuUYoUApoCEBYcWEUpuSaRSK/UqIBkQghbZX2W7jhgKKWylCx9WwOPdoTQhylIE0IRbemzzGe9La+oTHGA+aWjBIkE9Byl5JSEw6EaFaRHCCFs+3lH0h0FTHK6bjIFhoNtm8pTOQd8wgGiJsBPtSvLrAIPe6vqOw8YguGg5YDx1oCVl+OCA4SoCb1PAcO6Zt6SAe0IpQ9TigcBRANwHhSxfGaUc8A1B1g4s0RC8B8l5JQE9/mWzFF/iw/9hOjrGkCiYKDmQz9AaxKCqpSSagAtP/S7njRllIIUEELZgT+VgqZwIDeMh34JUUlAr1FaRg/9noxm8bUy1esq6+1cK5vORiS8/FrZEy7fmbzOrpUBqgGImhCoCUqulaU8zSBSWbpEh/SqVYmVz+0700rxpd7RM4z45ng3hz3BJSREoadQSDkSZKBQgPIKUAeCS8IHMiElE16aBZeAnICTWQouCYHUJMQ0Ci9vCy6JlIJKOJOAkqNMcGkrwCTMFJdYCCwtBZilBZbsO5NWwiQPoaUFlsQouGQSS8oTkzCzRHAJGIWVtLTgEryOAtpiwSUTWjJhJqi14JKnKCKEFoKgEITLlxDk63laICXIh4Hme0Nw6d3RvzOl/R8AdGoXzom1qQAAAABJRU5ErkJggg=="},16722:function(Cn,cn,wt){"use strict";wt.d(cn,{Z:function(){return Oe}});const Ft=be=>typeof be=="object"&&be!=null&&be.nodeType===1,Ht=(be,Qt)=>(!Qt||be!=="hidden")&&be!=="visible"&&be!=="clip",oe=(be,Qt)=>{if(be.clientHeight{const Re=(It=>{if(!It.ownerDocument||!It.ownerDocument.defaultView)return null;try{return It.ownerDocument.defaultView.frameElement}catch(et){return null}})(ye);return!!Re&&(Re.clientHeightItQt||It>be&&et=Qt&&nt>=Fe?It-be-ye:et>Qt&&ntFe?et-Qt+Re:0,Vt=be=>{const Qt=be.parentElement;return Qt==null?be.getRootNode().host||null:Qt},qt=(be,Qt)=>{var Fe,ye,Re,It;if(typeof document=="undefined")return[];const{scrollMode:et,block:nt,inline:dt,boundary:at,skipOverflowHiddenElements:gt}=Qt,mt=typeof at=="function"?at:En=>En!==at;if(!Ft(be))throw new TypeError("Invalid target");const Pt=document.scrollingElement||document.documentElement,kt=[];let Tt=be;for(;Ft(Tt)&&mt(Tt);){if(Tt=Vt(Tt),Tt===Pt){kt.push(Tt);break}Tt!=null&&Tt===document.body&&oe(Tt)&&!oe(document.documentElement)||Tt!=null&&oe(Tt,gt)&&kt.push(Tt)}const Dt=(ye=(Fe=window.visualViewport)==null?void 0:Fe.width)!=null?ye:innerWidth,$t=(It=(Re=window.visualViewport)==null?void 0:Re.height)!=null?It:innerHeight,{scrollX:ie,scrollY:Yt}=window,{height:fe,width:Zt,top:je,right:me,bottom:Xe,left:Se}=be.getBoundingClientRect(),{top:Ie,right:ze,bottom:Ue,left:se}=(En=>{const Ne=window.getComputedStyle(En);return{top:parseFloat(Ne.scrollMarginTop)||0,right:parseFloat(Ne.scrollMarginRight)||0,bottom:parseFloat(Ne.scrollMarginBottom)||0,left:parseFloat(Ne.scrollMarginLeft)||0}})(be);let jt=nt==="start"||nt==="nearest"?je-Ie:nt==="end"?Xe+Ue:je+fe/2-Ie+Ue,$e=dt==="center"?Se+Zt/2-se+ze:dt==="end"?me+ze:Se-se;const xn=[];for(let En=0;En=0&&Se>=0&&Xe<=$t&&me<=Dt&&(Ne===Pt&&!oe(Ne)||je>=zn&&Xe<=Tn&&Se>=we&&me<=tn))return xn;const Bn=getComputedStyle(Ne),Jn=parseInt(Bn.borderLeftWidth,10),Rt=parseInt(Bn.borderTopWidth,10),Lt=parseInt(Bn.borderRightWidth,10),St=parseInt(Bn.borderBottomWidth,10);let Et=0,Bt=0;const yt="offsetWidth"in Ne?Ne.offsetWidth-Ne.clientWidth-Jn-Lt:0,ae="offsetHeight"in Ne?Ne.offsetHeight-Ne.clientHeight-Rt-St:0,Pe="offsetWidth"in Ne?Ne.offsetWidth===0?0:rn/Ne.offsetWidth:0,ne="offsetHeight"in Ne?Ne.offsetHeight===0?0:Ze/Ne.offsetHeight:0;if(Pt===Ne)Et=nt==="start"?jt:nt==="end"?jt-$t:nt==="nearest"?ke(Yt,Yt+$t,$t,Rt,St,Yt+jt,Yt+jt+fe,fe):jt-$t/2,Bt=dt==="start"?$e:dt==="center"?$e-Dt/2:dt==="end"?$e-Dt:ke(ie,ie+Dt,Dt,Jn,Lt,ie+$e,ie+$e+Zt,Zt),Et=Math.max(0,Et+Yt),Bt=Math.max(0,Bt+ie);else{Et=nt==="start"?jt-zn-Rt:nt==="end"?jt-Tn+St+ae:nt==="nearest"?ke(zn,Tn,Ze,Rt,St+ae,jt,jt+fe,fe):jt-(zn+Ze/2)+ae/2,Bt=dt==="start"?$e-we-Jn:dt==="center"?$e-(we+rn/2)+yt/2:dt==="end"?$e-tn+Lt+yt:ke(we,tn,rn,Jn,Lt+yt,$e,$e+Zt,Zt);const{scrollLeft:_t,scrollTop:ge}=Ne;Et=ne===0?0:Math.max(0,Math.min(ge+Et/ne,Ne.scrollHeight-Ze/ne+ae)),Bt=Pe===0?0:Math.max(0,Math.min(_t+Bt/Pe,Ne.scrollWidth-rn/Pe+yt)),jt+=ge-Et,$e+=_t-Bt}xn.push({el:Ne,top:Et,left:Bt})}return xn},Nt=be=>be===!1?{block:"end",inline:"nearest"}:(Qt=>Qt===Object(Qt)&&Object.keys(Qt).length!==0)(be)?be:{block:"start",inline:"nearest"};function Oe(be,Qt){if(!be.isConnected||!(Re=>{let It=Re;for(;It&&It.parentNode;){if(It.parentNode===document)return!0;It=It.parentNode instanceof ShadowRoot?It.parentNode.host:It.parentNode}return!1})(be))return;const Fe=(Re=>{const It=window.getComputedStyle(Re);return{top:parseFloat(It.scrollMarginTop)||0,right:parseFloat(It.scrollMarginRight)||0,bottom:parseFloat(It.scrollMarginBottom)||0,left:parseFloat(It.scrollMarginLeft)||0}})(be);if((Re=>typeof Re=="object"&&typeof Re.behavior=="function")(Qt))return Qt.behavior(qt(be,Qt));const ye=typeof Qt=="boolean"||Qt==null?void 0:Qt.behavior;for(const{el:Re,top:It,left:et}of qt(be,Nt(Qt))){const nt=It-Fe.top+Fe.bottom,dt=et-Fe.left+Fe.right;Re.scroll({top:nt,left:dt,behavior:ye})}}}}]);