umd.js 324 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407
  1. !function (t, e) {
  2. "object" == typeof exports && "undefined" != typeof module ? e(exports) : "function" == typeof define && define.amd ? define(["exports"], e) : e((t = "undefined" != typeof globalThis ? globalThis : t || self).canvg = {})
  3. }(this, (function (t) {
  4. "use strict";
  5. var e = "undefined" != typeof globalThis ? globalThis : "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof self ? self : {};
  6. function r(t, e, r) {
  7. return t(r = {
  8. path: e, exports: {}, require: function (t, e) {
  9. return function () {
  10. throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")
  11. }(null == e && r.path)
  12. }
  13. }, r.exports), r.exports
  14. }
  15. var n = function (t) {
  16. return t && t.Math == Math && t
  17. },
  18. i = n("object" == typeof globalThis && globalThis) || n("object" == typeof window && window) || n("object" == typeof self && self) || n("object" == typeof e && e) || function () {
  19. return this
  20. }() || Function("return this")(), a = function (t) {
  21. try {
  22. return !!t()
  23. } catch (t) {
  24. return !0
  25. }
  26. }, o = !a((function () {
  27. return 7 != Object.defineProperty({}, 1, {
  28. get: function () {
  29. return 7
  30. }
  31. })[1]
  32. })), u = {}.propertyIsEnumerable, s = Object.getOwnPropertyDescriptor, c = {
  33. f: s && !u.call({1: 2}, 1) ? function (t) {
  34. var e = s(this, t);
  35. return !!e && e.enumerable
  36. } : u
  37. }, l = function (t, e) {
  38. return {enumerable: !(1 & t), configurable: !(2 & t), writable: !(4 & t), value: e}
  39. }, f = {}.toString, h = function (t) {
  40. return f.call(t).slice(8, -1)
  41. }, p = "".split, y = a((function () {
  42. return !Object("z").propertyIsEnumerable(0)
  43. })) ? function (t) {
  44. return "String" == h(t) ? p.call(t, "") : Object(t)
  45. } : Object, v = function (t) {
  46. if (null == t) throw TypeError("Can't call method on " + t);
  47. return t
  48. }, g = function (t) {
  49. return y(v(t))
  50. }, d = function (t) {
  51. return "object" == typeof t ? null !== t : "function" == typeof t
  52. }, m = function (t, e) {
  53. if (!d(t)) return t;
  54. var r, n;
  55. if (e && "function" == typeof (r = t.toString) && !d(n = r.call(t))) return n;
  56. if ("function" == typeof (r = t.valueOf) && !d(n = r.call(t))) return n;
  57. if (!e && "function" == typeof (r = t.toString) && !d(n = r.call(t))) return n;
  58. throw TypeError("Can't convert object to primitive value")
  59. }, x = {}.hasOwnProperty, b = function (t, e) {
  60. return x.call(t, e)
  61. }, w = i.document, S = d(w) && d(w.createElement), A = function (t) {
  62. return S ? w.createElement(t) : {}
  63. }, k = !o && !a((function () {
  64. return 7 != Object.defineProperty(A("div"), "a", {
  65. get: function () {
  66. return 7
  67. }
  68. }).a
  69. })), T = Object.getOwnPropertyDescriptor, O = {
  70. f: o ? T : function (t, e) {
  71. if (t = g(t), e = m(e, !0), k) try {
  72. return T(t, e)
  73. } catch (t) {
  74. }
  75. if (b(t, e)) return l(!c.f.call(t, e), t[e])
  76. }
  77. }, P = /#|\.prototype\./, E = function (t, e) {
  78. var r = M[C(t)];
  79. return r == R || r != N && ("function" == typeof e ? a(e) : !!e)
  80. }, C = E.normalize = function (t) {
  81. return String(t).replace(P, ".").toLowerCase()
  82. }, M = E.data = {}, N = E.NATIVE = "N", R = E.POLYFILL = "P", _ = E, D = {}, V = function (t) {
  83. if ("function" != typeof t) throw TypeError(String(t) + " is not a function");
  84. return t
  85. }, L = function (t, e, r) {
  86. if (V(t), void 0 === e) return t;
  87. switch (r) {
  88. case 0:
  89. return function () {
  90. return t.call(e)
  91. };
  92. case 1:
  93. return function (r) {
  94. return t.call(e, r)
  95. };
  96. case 2:
  97. return function (r, n) {
  98. return t.call(e, r, n)
  99. };
  100. case 3:
  101. return function (r, n, i) {
  102. return t.call(e, r, n, i)
  103. }
  104. }
  105. return function () {
  106. return t.apply(e, arguments)
  107. }
  108. }, I = function (t) {
  109. if (!d(t)) throw TypeError(String(t) + " is not an object");
  110. return t
  111. }, j = Object.defineProperty, z = {
  112. f: o ? j : function (t, e, r) {
  113. if (I(t), e = m(e, !0), I(r), k) try {
  114. return j(t, e, r)
  115. } catch (t) {
  116. }
  117. if ("get" in r || "set" in r) throw TypeError("Accessors not supported");
  118. return "value" in r && (t[e] = r.value), t
  119. }
  120. }, F = o ? function (t, e, r) {
  121. return z.f(t, e, l(1, r))
  122. } : function (t, e, r) {
  123. return t[e] = r, t
  124. }, B = O.f, U = function (t) {
  125. var e = function (e, r, n) {
  126. if (this instanceof t) {
  127. switch (arguments.length) {
  128. case 0:
  129. return new t;
  130. case 1:
  131. return new t(e);
  132. case 2:
  133. return new t(e, r)
  134. }
  135. return new t(e, r, n)
  136. }
  137. return t.apply(this, arguments)
  138. };
  139. return e.prototype = t.prototype, e
  140. }, H = function (t, e) {
  141. var r, n, a, o, u, s, c, l, f = t.target, h = t.global, p = t.stat, y = t.proto,
  142. v = h ? i : p ? i[f] : (i[f] || {}).prototype, g = h ? D : D[f] || (D[f] = {}), d = g.prototype;
  143. for (a in e) r = !_(h ? a : f + (p ? "." : "#") + a, t.forced) && v && b(v, a), u = g[a], r && (s = t.noTargetGet ? (l = B(v, a)) && l.value : v[a]), o = r && s ? s : e[a], r && typeof u == typeof o || (c = t.bind && r ? L(o, i) : t.wrap && r ? U(o) : y && "function" == typeof o ? L(Function.call, o) : o, (t.sham || o && o.sham || u && u.sham) && F(c, "sham", !0), g[a] = c, y && (b(D, n = f + "Prototype") || F(D, n, {}), D[n][a] = o, t.real && d && !d[a] && F(d, a, o)))
  144. }, X = Math.ceil, Y = Math.floor, q = function (t) {
  145. return isNaN(t = +t) ? 0 : (t > 0 ? Y : X)(t)
  146. }, G = Math.min, Q = function (t) {
  147. return t > 0 ? G(q(t), 9007199254740991) : 0
  148. }, W = "__core-js_shared__", $ = i[W] || function (t, e) {
  149. try {
  150. F(i, t, e)
  151. } catch (r) {
  152. i[t] = e
  153. }
  154. return e
  155. }(W, {}), Z = r((function (t) {
  156. (t.exports = function (t, e) {
  157. return $[t] || ($[t] = void 0 !== e ? e : {})
  158. })("versions", []).push({version: "3.7.0", mode: "pure", copyright: "© 2020 Denis Pushkarev (zloirock.ru)"})
  159. })), K = 0, J = Math.random(), tt = function (t) {
  160. return "Symbol(" + String(void 0 === t ? "" : t) + ")_" + (++K + J).toString(36)
  161. }, et = !!Object.getOwnPropertySymbols && !a((function () {
  162. return !String(Symbol())
  163. })), rt = et && !Symbol.sham && "symbol" == typeof Symbol.iterator, nt = Z("wks"), it = i.Symbol,
  164. at = rt ? it : it && it.withoutSetter || tt, ot = function (t) {
  165. return b(nt, t) || (et && b(it, t) ? nt[t] = it[t] : nt[t] = at("Symbol." + t)), nt[t]
  166. }, ut = ot("match"), st = function (t) {
  167. if (function (t) {
  168. var e;
  169. return d(t) && (void 0 !== (e = t[ut]) ? !!e : "RegExp" == h(t))
  170. }(t)) throw TypeError("The method doesn't accept regular expressions");
  171. return t
  172. }, ct = ot("match"), lt = function (t) {
  173. var e = /./;
  174. try {
  175. "/./"[t](e)
  176. } catch (r) {
  177. try {
  178. return e[ct] = !1, "/./"[t](e)
  179. } catch (t) {
  180. }
  181. }
  182. return !1
  183. }, ft = "".startsWith, ht = Math.min, pt = lt("startsWith");
  184. H({target: "String", proto: !0, forced: !pt}, {
  185. startsWith: function (t) {
  186. var e = String(v(this));
  187. st(t);
  188. var r = Q(ht(arguments.length > 1 ? arguments[1] : void 0, e.length)), n = String(t);
  189. return ft ? ft.call(e, n, r) : e.slice(r, r + n.length) === n
  190. }
  191. });
  192. var yt = function (t) {
  193. return D[t + "Prototype"]
  194. }, vt = yt("String").startsWith, gt = String.prototype, dt = function (t) {
  195. var e = t.startsWith;
  196. return "string" == typeof t || t === gt || t instanceof String && e === gt.startsWith ? vt : e
  197. }, mt = "\t\n\v\f\r                 \u2028\u2029\ufeff", xt = "[" + mt + "]", bt = RegExp("^" + xt + xt + "*"),
  198. wt = RegExp(xt + xt + "*$"), St = function (t) {
  199. return function (e) {
  200. var r = String(v(e));
  201. return 1 & t && (r = r.replace(bt, "")), 2 & t && (r = r.replace(wt, "")), r
  202. }
  203. }, At = {start: St(1), end: St(2), trim: St(3)}, kt = At.trim, Tt = i.parseFloat,
  204. Ot = 1 / Tt(mt + "-0") != -1 / 0 ? function (t) {
  205. var e = kt(String(t)), r = Tt(e);
  206. return 0 === r && "-" == e.charAt(0) ? -0 : r
  207. } : Tt;
  208. H({global: !0, forced: parseFloat != Ot}, {parseFloat: Ot});
  209. var Pt, Et, Ct = D.parseFloat, Mt = function (t) {
  210. return Object(v(t))
  211. }, Nt = Array.isArray || function (t) {
  212. return "Array" == h(t)
  213. }, Rt = ot("species"), _t = function (t, e) {
  214. var r;
  215. return Nt(t) && ("function" != typeof (r = t.constructor) || r !== Array && !Nt(r.prototype) ? d(r) && null === (r = r[Rt]) && (r = void 0) : r = void 0), new (void 0 === r ? Array : r)(0 === e ? 0 : e)
  216. }, Dt = [].push, Vt = function (t) {
  217. var e = 1 == t, r = 2 == t, n = 3 == t, i = 4 == t, a = 6 == t, o = 5 == t || a;
  218. return function (u, s, c, l) {
  219. for (var f, h, p = Mt(u), v = y(p), g = L(s, c, 3), d = Q(v.length), m = 0, x = l || _t, b = e ? x(u, d) : r ? x(u, 0) : void 0; d > m; m++) if ((o || m in v) && (h = g(f = v[m], m, p), t)) if (e) b[m] = h; else if (h) switch (t) {
  220. case 3:
  221. return !0;
  222. case 5:
  223. return f;
  224. case 6:
  225. return m;
  226. case 2:
  227. Dt.call(b, f)
  228. } else if (i) return !1;
  229. return a ? -1 : n || i ? i : b
  230. }
  231. }, Lt = {forEach: Vt(0), map: Vt(1), filter: Vt(2), some: Vt(3), every: Vt(4), find: Vt(5), findIndex: Vt(6)},
  232. It = function (t) {
  233. return "function" == typeof t ? t : void 0
  234. }, jt = function (t, e) {
  235. return arguments.length < 2 ? It(D[t]) || It(i[t]) : D[t] && D[t][e] || i[t] && i[t][e]
  236. }, zt = jt("navigator", "userAgent") || "", Ft = i.process, Bt = Ft && Ft.versions, Ut = Bt && Bt.v8;
  237. Ut ? Et = (Pt = Ut.split("."))[0] + Pt[1] : zt && (!(Pt = zt.match(/Edge\/(\d+)/)) || Pt[1] >= 74) && (Pt = zt.match(/Chrome\/(\d+)/)) && (Et = Pt[1]);
  238. var Ht = Et && +Et, Xt = ot("species"), Yt = function (t) {
  239. return Ht >= 51 || !a((function () {
  240. var e = [];
  241. return (e.constructor = {})[Xt] = function () {
  242. return {foo: 1}
  243. }, 1 !== e[t](Boolean).foo
  244. }))
  245. }, qt = Object.defineProperty, Gt = {}, Qt = function (t) {
  246. throw t
  247. }, Wt = function (t, e) {
  248. if (b(Gt, t)) return Gt[t];
  249. e || (e = {});
  250. var r = [][t], n = !!b(e, "ACCESSORS") && e.ACCESSORS, i = b(e, 0) ? e[0] : Qt, u = b(e, 1) ? e[1] : void 0;
  251. return Gt[t] = !!r && !a((function () {
  252. if (n && !o) return !0;
  253. var t = {length: -1};
  254. n ? qt(t, 1, {enumerable: !0, get: Qt}) : t[1] = 1, r.call(t, i, u)
  255. }))
  256. }, $t = Lt.map, Zt = Yt("map"), Kt = Wt("map");
  257. H({target: "Array", proto: !0, forced: !Zt || !Kt}, {
  258. map: function (t) {
  259. return $t(this, t, arguments.length > 1 ? arguments[1] : void 0)
  260. }
  261. });
  262. var Jt = yt("Array").map, te = Array.prototype, ee = function (t) {
  263. var e = t.map;
  264. return t === te || t instanceof Array && e === te.map ? Jt : e
  265. };
  266. function re(t) {
  267. return t.replace(/(?!\u3000)\s+/gm, " ")
  268. }
  269. function ne(t) {
  270. return t.replace(/^[\n \t]+/, "")
  271. }
  272. function ie(t) {
  273. return t.replace(/[\n \t]+$/, "")
  274. }
  275. function ae(t) {
  276. var e = (t || "").match(/-?(\d+(?:\.\d*(?:[eE][+-]?\d+)?)?|\.\d+)(?=\D|$)/gm) || [];
  277. return ee(e).call(e, Ct)
  278. }
  279. var oe = /^[A-Z-]+$/;
  280. function ue(t) {
  281. return oe.test(t) ? t.toLowerCase() : t
  282. }
  283. function se(t) {
  284. var e = t.match(/url\(('([^']+)'|"([^"]+)"|([^'"\)]+))\)/) || [];
  285. return e[2] || e[3] || e[4]
  286. }
  287. function ce(t) {
  288. if (!dt(t).call(t, "rgb")) return t;
  289. var e = 3;
  290. return t.replace(/\d+(\.\d+)?/g, (function (t, r) {
  291. return e-- && r ? String(Math.round(Ct(t))) : t
  292. }))
  293. }
  294. H({target: "Array", stat: !0}, {isArray: Nt});
  295. var le = D.Array.isArray, fe = le;
  296. var he = function (t) {
  297. if (fe(t)) return t
  298. }, pe = {}, ye = Function.toString;
  299. "function" != typeof $.inspectSource && ($.inspectSource = function (t) {
  300. return ye.call(t)
  301. });
  302. var ve, ge, de, me = $.inspectSource, xe = i.WeakMap, be = "function" == typeof xe && /native code/.test(me(xe)),
  303. we = Z("keys"), Se = function (t) {
  304. return we[t] || (we[t] = tt(t))
  305. }, Ae = {}, ke = i.WeakMap;
  306. if (be) {
  307. var Te = $.state || ($.state = new ke), Oe = Te.get, Pe = Te.has, Ee = Te.set;
  308. ve = function (t, e) {
  309. return e.facade = t, Ee.call(Te, t, e), e
  310. }, ge = function (t) {
  311. return Oe.call(Te, t) || {}
  312. }, de = function (t) {
  313. return Pe.call(Te, t)
  314. }
  315. } else {
  316. var Ce = Se("state");
  317. Ae[Ce] = !0, ve = function (t, e) {
  318. return e.facade = t, F(t, Ce, e), e
  319. }, ge = function (t) {
  320. return b(t, Ce) ? t[Ce] : {}
  321. }, de = function (t) {
  322. return b(t, Ce)
  323. }
  324. }
  325. var Me, Ne, Re, _e = {
  326. set: ve, get: ge, has: de, enforce: function (t) {
  327. return de(t) ? ge(t) : ve(t, {})
  328. }, getterFor: function (t) {
  329. return function (e) {
  330. var r;
  331. if (!d(e) || (r = ge(e)).type !== t) throw TypeError("Incompatible receiver, " + t + " required");
  332. return r
  333. }
  334. }
  335. }, De = !a((function () {
  336. function t() {
  337. }
  338. return t.prototype.constructor = null, Object.getPrototypeOf(new t) !== t.prototype
  339. })), Ve = Se("IE_PROTO"), Le = Object.prototype, Ie = De ? Object.getPrototypeOf : function (t) {
  340. return t = Mt(t), b(t, Ve) ? t[Ve] : "function" == typeof t.constructor && t instanceof t.constructor ? t.constructor.prototype : t instanceof Object ? Le : null
  341. }, je = (ot("iterator"), !1);
  342. [].keys && ("next" in (Re = [].keys()) ? (Ne = Ie(Ie(Re))) !== Object.prototype && (Me = Ne) : je = !0), null == Me && (Me = {});
  343. var ze, Fe = {IteratorPrototype: Me, BUGGY_SAFARI_ITERATORS: je}, Be = Math.max, Ue = Math.min,
  344. He = function (t, e) {
  345. var r = q(t);
  346. return r < 0 ? Be(r + e, 0) : Ue(r, e)
  347. }, Xe = function (t) {
  348. return function (e, r, n) {
  349. var i, a = g(e), o = Q(a.length), u = He(n, o);
  350. if (t && r != r) {
  351. for (; o > u;) if ((i = a[u++]) != i) return !0
  352. } else for (; o > u; u++) if ((t || u in a) && a[u] === r) return t || u || 0;
  353. return !t && -1
  354. }
  355. }, Ye = {includes: Xe(!0), indexOf: Xe(!1)}, qe = Ye.indexOf, Ge = function (t, e) {
  356. var r, n = g(t), i = 0, a = [];
  357. for (r in n) !b(Ae, r) && b(n, r) && a.push(r);
  358. for (; e.length > i;) b(n, r = e[i++]) && (~qe(a, r) || a.push(r));
  359. return a
  360. },
  361. Qe = ["constructor", "hasOwnProperty", "isPrototypeOf", "propertyIsEnumerable", "toLocaleString", "toString", "valueOf"],
  362. We = Object.keys || function (t) {
  363. return Ge(t, Qe)
  364. }, $e = o ? Object.defineProperties : function (t, e) {
  365. I(t);
  366. for (var r, n = We(e), i = n.length, a = 0; i > a;) z.f(t, r = n[a++], e[r]);
  367. return t
  368. }, Ze = jt("document", "documentElement"), Ke = Se("IE_PROTO"), Je = function () {
  369. }, tr = function (t) {
  370. return "<script>" + t + "</" + "script>"
  371. }, er = function () {
  372. try {
  373. ze = document.domain && new ActiveXObject("htmlfile")
  374. } catch (t) {
  375. }
  376. var t, e;
  377. er = ze ? function (t) {
  378. t.write(tr("")), t.close();
  379. var e = t.parentWindow.Object;
  380. return t = null, e
  381. }(ze) : ((e = A("iframe")).style.display = "none", Ze.appendChild(e), e.src = String("javascript:"), (t = e.contentWindow.document).open(), t.write(tr("document.F=Object")), t.close(), t.F);
  382. for (var r = Qe.length; r--;) delete er.prototype[Qe[r]];
  383. return er()
  384. };
  385. Ae[Ke] = !0;
  386. var rr = Object.create || function (t, e) {
  387. var r;
  388. return null !== t ? (Je.prototype = I(t), r = new Je, Je.prototype = null, r[Ke] = t) : r = er(), void 0 === e ? r : $e(r, e)
  389. }, nr = {};
  390. nr[ot("toStringTag")] = "z";
  391. var ir = "[object z]" === String(nr), ar = ot("toStringTag"), or = "Arguments" == h(function () {
  392. return arguments
  393. }()), ur = ir ? h : function (t) {
  394. var e, r, n;
  395. return void 0 === t ? "Undefined" : null === t ? "Null" : "string" == typeof (r = function (t, e) {
  396. try {
  397. return t[e]
  398. } catch (t) {
  399. }
  400. }(e = Object(t), ar)) ? r : or ? h(e) : "Object" == (n = h(e)) && "function" == typeof e.callee ? "Arguments" : n
  401. }, sr = ir ? {}.toString : function () {
  402. return "[object " + ur(this) + "]"
  403. }, cr = z.f, lr = ot("toStringTag"), fr = function (t, e, r, n) {
  404. if (t) {
  405. var i = r ? t : t.prototype;
  406. b(i, lr) || cr(i, lr, {configurable: !0, value: e}), n && !ir && F(i, "toString", sr)
  407. }
  408. }, hr = Fe.IteratorPrototype, pr = function () {
  409. return this
  410. }, yr = Object.setPrototypeOf || ("__proto__" in {} ? function () {
  411. var t, e = !1, r = {};
  412. try {
  413. (t = Object.getOwnPropertyDescriptor(Object.prototype, "__proto__").set).call(r, []), e = r instanceof Array
  414. } catch (t) {
  415. }
  416. return function (r, n) {
  417. return I(r), function (t) {
  418. if (!d(t) && null !== t) throw TypeError("Can't set " + String(t) + " as a prototype")
  419. }(n), e ? t.call(r, n) : r.__proto__ = n, r
  420. }
  421. }() : void 0), vr = function (t, e, r, n) {
  422. n && n.enumerable ? t[e] = r : F(t, e, r)
  423. }, gr = Fe.IteratorPrototype, dr = Fe.BUGGY_SAFARI_ITERATORS, mr = ot("iterator"), xr = "keys", br = "values",
  424. wr = "entries", Sr = function () {
  425. return this
  426. }, Ar = function (t, e, r, n, i, a, o) {
  427. !function (t, e, r) {
  428. var n = e + " Iterator";
  429. t.prototype = rr(hr, {next: l(1, r)}), fr(t, n, !1, !0), pe[n] = pr
  430. }(r, e, n);
  431. var u, s, c, f = function (t) {
  432. if (t === i && g) return g;
  433. if (!dr && t in y) return y[t];
  434. switch (t) {
  435. case xr:
  436. case br:
  437. case wr:
  438. return function () {
  439. return new r(this, t)
  440. }
  441. }
  442. return function () {
  443. return new r(this)
  444. }
  445. }, h = e + " Iterator", p = !1, y = t.prototype, v = y[mr] || y["@@iterator"] || i && y[i],
  446. g = !dr && v || f(i), d = "Array" == e && y.entries || v;
  447. if (d && (u = Ie(d.call(new t)), gr !== Object.prototype && u.next && (fr(u, h, !0, !0), pe[h] = Sr)), i == br && v && v.name !== br && (p = !0, g = function () {
  448. return v.call(this)
  449. }), o && y[mr] !== g && F(y, mr, g), pe[e] = g, i) if (s = {
  450. values: f(br),
  451. keys: a ? g : f(xr),
  452. entries: f(wr)
  453. }, o) for (c in s) (dr || p || !(c in y)) && vr(y, c, s[c]); else H({target: e, proto: !0, forced: dr || p}, s);
  454. return s
  455. }, kr = "Array Iterator", Tr = _e.set, Or = _e.getterFor(kr);
  456. Ar(Array, "Array", (function (t, e) {
  457. Tr(this, {type: kr, target: g(t), index: 0, kind: e})
  458. }), (function () {
  459. var t = Or(this), e = t.target, r = t.kind, n = t.index++;
  460. return !e || n >= e.length ? (t.target = void 0, {value: void 0, done: !0}) : "keys" == r ? {
  461. value: n,
  462. done: !1
  463. } : "values" == r ? {value: e[n], done: !1} : {value: [n, e[n]], done: !1}
  464. }), "values");
  465. pe.Arguments = pe.Array;
  466. var Pr = ot("toStringTag");
  467. for (var Er in {
  468. CSSRuleList: 0,
  469. CSSStyleDeclaration: 0,
  470. CSSValueList: 0,
  471. ClientRectList: 0,
  472. DOMRectList: 0,
  473. DOMStringList: 0,
  474. DOMTokenList: 1,
  475. DataTransferItemList: 0,
  476. FileList: 0,
  477. HTMLAllCollection: 0,
  478. HTMLCollection: 0,
  479. HTMLFormElement: 0,
  480. HTMLSelectElement: 0,
  481. MediaList: 0,
  482. MimeTypeArray: 0,
  483. NamedNodeMap: 0,
  484. NodeList: 1,
  485. PaintRequestList: 0,
  486. Plugin: 0,
  487. PluginArray: 0,
  488. SVGLengthList: 0,
  489. SVGNumberList: 0,
  490. SVGPathSegList: 0,
  491. SVGPointList: 0,
  492. SVGStringList: 0,
  493. SVGTransformList: 0,
  494. SourceBufferList: 0,
  495. StyleSheetList: 0,
  496. TextTrackCueList: 0,
  497. TextTrackList: 0,
  498. TouchList: 0
  499. }) {
  500. var Cr = i[Er], Mr = Cr && Cr.prototype;
  501. Mr && ur(Mr) !== Pr && F(Mr, Pr, Er), pe[Er] = pe.Array
  502. }
  503. var Nr = function (t) {
  504. return function (e, r) {
  505. var n, i, a = String(v(e)), o = q(r), u = a.length;
  506. return o < 0 || o >= u ? t ? "" : void 0 : (n = a.charCodeAt(o)) < 55296 || n > 56319 || o + 1 === u || (i = a.charCodeAt(o + 1)) < 56320 || i > 57343 ? t ? a.charAt(o) : n : t ? a.slice(o, o + 2) : i - 56320 + (n - 55296 << 10) + 65536
  507. }
  508. }, Rr = {codeAt: Nr(!1), charAt: Nr(!0)}.charAt, _r = "String Iterator", Dr = _e.set, Vr = _e.getterFor(_r);
  509. Ar(String, "String", (function (t) {
  510. Dr(this, {type: _r, string: String(t), index: 0})
  511. }), (function () {
  512. var t, e = Vr(this), r = e.string, n = e.index;
  513. return n >= r.length ? {value: void 0, done: !0} : (t = Rr(r, n), e.index += t.length, {value: t, done: !1})
  514. }));
  515. var Lr = ot("iterator"), Ir = function (t) {
  516. if (null != t) return t[Lr] || t["@@iterator"] || pe[ur(t)]
  517. }, jr = function (t) {
  518. var e = Ir(t);
  519. if ("function" != typeof e) throw TypeError(String(t) + " is not iterable");
  520. return I(e.call(t))
  521. }, zr = ot("iterator"), Fr = function (t) {
  522. var e = Object(t);
  523. return void 0 !== e[zr] || "@@iterator" in e || pe.hasOwnProperty(ur(e))
  524. }, Br = function (t, e, r) {
  525. var n = m(e);
  526. n in t ? z.f(t, n, l(0, r)) : t[n] = r
  527. }, Ur = ot("isConcatSpreadable"), Hr = 9007199254740991, Xr = "Maximum allowed index exceeded",
  528. Yr = Ht >= 51 || !a((function () {
  529. var t = [];
  530. return t[Ur] = !1, t.concat()[0] !== t
  531. })), qr = Yt("concat"), Gr = function (t) {
  532. if (!d(t)) return !1;
  533. var e = t[Ur];
  534. return void 0 !== e ? !!e : Nt(t)
  535. };
  536. H({target: "Array", proto: !0, forced: !Yr || !qr}, {
  537. concat: function (t) {
  538. var e, r, n, i, a, o = Mt(this), u = _t(o, 0), s = 0;
  539. for (e = -1, n = arguments.length; e < n; e++) if (Gr(a = -1 === e ? o : arguments[e])) {
  540. if (s + (i = Q(a.length)) > Hr) throw TypeError(Xr);
  541. for (r = 0; r < i; r++, s++) r in a && Br(u, s, a[r])
  542. } else {
  543. if (s >= Hr) throw TypeError(Xr);
  544. Br(u, s++, a)
  545. }
  546. return u.length = s, u
  547. }
  548. });
  549. var Qr = Qe.concat("length", "prototype"), Wr = {
  550. f: Object.getOwnPropertyNames || function (t) {
  551. return Ge(t, Qr)
  552. }
  553. }, $r = Wr.f, Zr = {}.toString,
  554. Kr = "object" == typeof window && window && Object.getOwnPropertyNames ? Object.getOwnPropertyNames(window) : [],
  555. Jr = {
  556. f: function (t) {
  557. return Kr && "[object Window]" == Zr.call(t) ? function (t) {
  558. try {
  559. return $r(t)
  560. } catch (t) {
  561. return Kr.slice()
  562. }
  563. }(t) : $r(g(t))
  564. }
  565. }, tn = {f: Object.getOwnPropertySymbols}, en = {f: ot}, rn = z.f, nn = function (t) {
  566. var e = D.Symbol || (D.Symbol = {});
  567. b(e, t) || rn(e, t, {value: en.f(t)})
  568. }, an = Lt.forEach, on = Se("hidden"), un = "Symbol", sn = ot("toPrimitive"), cn = _e.set, ln = _e.getterFor(un),
  569. fn = Object.prototype, hn = i.Symbol, pn = jt("JSON", "stringify"), yn = O.f, vn = z.f, gn = Jr.f, dn = c.f,
  570. mn = Z("symbols"), xn = Z("op-symbols"), bn = Z("string-to-symbol-registry"),
  571. wn = Z("symbol-to-string-registry"), Sn = Z("wks"), An = i.QObject,
  572. kn = !An || !An.prototype || !An.prototype.findChild, Tn = o && a((function () {
  573. return 7 != rr(vn({}, "a", {
  574. get: function () {
  575. return vn(this, "a", {value: 7}).a
  576. }
  577. })).a
  578. })) ? function (t, e, r) {
  579. var n = yn(fn, e);
  580. n && delete fn[e], vn(t, e, r), n && t !== fn && vn(fn, e, n)
  581. } : vn, On = function (t, e) {
  582. var r = mn[t] = rr(hn.prototype);
  583. return cn(r, {type: un, tag: t, description: e}), o || (r.description = e), r
  584. }, Pn = rt ? function (t) {
  585. return "symbol" == typeof t
  586. } : function (t) {
  587. return Object(t) instanceof hn
  588. }, En = function (t, e, r) {
  589. t === fn && En(xn, e, r), I(t);
  590. var n = m(e, !0);
  591. return I(r), b(mn, n) ? (r.enumerable ? (b(t, on) && t[on][n] && (t[on][n] = !1), r = rr(r, {enumerable: l(0, !1)})) : (b(t, on) || vn(t, on, l(1, {})), t[on][n] = !0), Tn(t, n, r)) : vn(t, n, r)
  592. }, Cn = function (t, e) {
  593. I(t);
  594. var r = g(e), n = We(r).concat(_n(r));
  595. return an(n, (function (e) {
  596. o && !Mn.call(r, e) || En(t, e, r[e])
  597. })), t
  598. }, Mn = function (t) {
  599. var e = m(t, !0), r = dn.call(this, e);
  600. return !(this === fn && b(mn, e) && !b(xn, e)) && (!(r || !b(this, e) || !b(mn, e) || b(this, on) && this[on][e]) || r)
  601. }, Nn = function (t, e) {
  602. var r = g(t), n = m(e, !0);
  603. if (r !== fn || !b(mn, n) || b(xn, n)) {
  604. var i = yn(r, n);
  605. return !i || !b(mn, n) || b(r, on) && r[on][n] || (i.enumerable = !0), i
  606. }
  607. }, Rn = function (t) {
  608. var e = gn(g(t)), r = [];
  609. return an(e, (function (t) {
  610. b(mn, t) || b(Ae, t) || r.push(t)
  611. })), r
  612. }, _n = function (t) {
  613. var e = t === fn, r = gn(e ? xn : g(t)), n = [];
  614. return an(r, (function (t) {
  615. !b(mn, t) || e && !b(fn, t) || n.push(mn[t])
  616. })), n
  617. };
  618. if (et || (vr((hn = function () {
  619. if (this instanceof hn) throw TypeError("Symbol is not a constructor");
  620. var t = arguments.length && void 0 !== arguments[0] ? String(arguments[0]) : void 0, e = tt(t),
  621. r = function (t) {
  622. this === fn && r.call(xn, t), b(this, on) && b(this[on], e) && (this[on][e] = !1), Tn(this, e, l(1, t))
  623. };
  624. return o && kn && Tn(fn, e, {configurable: !0, set: r}), On(e, t)
  625. }).prototype, "toString", (function () {
  626. return ln(this).tag
  627. })), vr(hn, "withoutSetter", (function (t) {
  628. return On(tt(t), t)
  629. })), c.f = Mn, z.f = En, O.f = Nn, Wr.f = Jr.f = Rn, tn.f = _n, en.f = function (t) {
  630. return On(ot(t), t)
  631. }, o && vn(hn.prototype, "description", {
  632. configurable: !0, get: function () {
  633. return ln(this).description
  634. }
  635. })), H({global: !0, wrap: !0, forced: !et, sham: !et}, {Symbol: hn}), an(We(Sn), (function (t) {
  636. nn(t)
  637. })), H({target: un, stat: !0, forced: !et}, {
  638. for: function (t) {
  639. var e = String(t);
  640. if (b(bn, e)) return bn[e];
  641. var r = hn(e);
  642. return bn[e] = r, wn[r] = e, r
  643. }, keyFor: function (t) {
  644. if (!Pn(t)) throw TypeError(t + " is not a symbol");
  645. if (b(wn, t)) return wn[t]
  646. }, useSetter: function () {
  647. kn = !0
  648. }, useSimple: function () {
  649. kn = !1
  650. }
  651. }), H({target: "Object", stat: !0, forced: !et, sham: !o}, {
  652. create: function (t, e) {
  653. return void 0 === e ? rr(t) : Cn(rr(t), e)
  654. }, defineProperty: En, defineProperties: Cn, getOwnPropertyDescriptor: Nn
  655. }), H({target: "Object", stat: !0, forced: !et}, {
  656. getOwnPropertyNames: Rn,
  657. getOwnPropertySymbols: _n
  658. }), H({
  659. target: "Object", stat: !0, forced: a((function () {
  660. tn.f(1)
  661. }))
  662. }, {
  663. getOwnPropertySymbols: function (t) {
  664. return tn.f(Mt(t))
  665. }
  666. }), pn) {
  667. var Dn = !et || a((function () {
  668. var t = hn();
  669. return "[null]" != pn([t]) || "{}" != pn({a: t}) || "{}" != pn(Object(t))
  670. }));
  671. H({target: "JSON", stat: !0, forced: Dn}, {
  672. stringify: function (t, e, r) {
  673. for (var n, i = [t], a = 1; arguments.length > a;) i.push(arguments[a++]);
  674. if (n = e, (d(e) || void 0 !== t) && !Pn(t)) return Nt(e) || (e = function (t, e) {
  675. if ("function" == typeof n && (e = n.call(this, t, e)), !Pn(e)) return e
  676. }), i[1] = e, pn.apply(null, i)
  677. }
  678. })
  679. }
  680. hn.prototype[sn] || F(hn.prototype, sn, hn.prototype.valueOf), fr(hn, un), Ae[on] = !0, nn("asyncIterator"), nn("hasInstance"), nn("isConcatSpreadable"), nn("iterator"), nn("match"), nn("matchAll"), nn("replace"), nn("search"), nn("species"), nn("split"), nn("toPrimitive"), nn("toStringTag"), nn("unscopables"), fr(i.JSON, "JSON", !0);
  681. var Vn = D.Symbol;
  682. nn("asyncDispose"), nn("dispose"), nn("observable"), nn("patternMatch"), nn("replaceAll");
  683. var Ln = Vn;
  684. var In = function (t, e) {
  685. if (void 0 !== Ln && Fr(Object(t))) {
  686. var r = [], n = !0, i = !1, a = void 0;
  687. try {
  688. for (var o, u = jr(t); !(n = (o = u.next()).done) && (r.push(o.value), !e || r.length !== e); n = !0) ;
  689. } catch (t) {
  690. i = !0, a = t
  691. } finally {
  692. try {
  693. n || null == u.return || u.return()
  694. } finally {
  695. if (i) throw a
  696. }
  697. }
  698. return r
  699. }
  700. }, jn = function (t) {
  701. var e = t.return;
  702. if (void 0 !== e) return I(e.call(t)).value
  703. }, zn = function (t, e, r, n) {
  704. try {
  705. return n ? e(I(r)[0], r[1]) : e(r)
  706. } catch (e) {
  707. throw jn(t), e
  708. }
  709. }, Fn = ot("iterator"), Bn = Array.prototype, Un = function (t) {
  710. return void 0 !== t && (pe.Array === t || Bn[Fn] === t)
  711. }, Hn = ot("iterator"), Xn = !1;
  712. try {
  713. var Yn = 0, qn = {
  714. next: function () {
  715. return {done: !!Yn++}
  716. }, return: function () {
  717. Xn = !0
  718. }
  719. };
  720. qn[Hn] = function () {
  721. return this
  722. }, Array.from(qn, (function () {
  723. throw 2
  724. }))
  725. } catch (t) {
  726. }
  727. var Gn = function (t, e) {
  728. if (!e && !Xn) return !1;
  729. var r = !1;
  730. try {
  731. var n = {};
  732. n[Hn] = function () {
  733. return {
  734. next: function () {
  735. return {done: r = !0}
  736. }
  737. }
  738. }, t(n)
  739. } catch (t) {
  740. }
  741. return r
  742. }, Qn = !Gn((function (t) {
  743. Array.from(t)
  744. }));
  745. H({target: "Array", stat: !0, forced: Qn}, {
  746. from: function (t) {
  747. var e, r, n, i, a, o, u = Mt(t), s = "function" == typeof this ? this : Array, c = arguments.length,
  748. l = c > 1 ? arguments[1] : void 0, f = void 0 !== l, h = Ir(u), p = 0;
  749. if (f && (l = L(l, c > 2 ? arguments[2] : void 0, 2)), null == h || s == Array && Un(h)) for (r = new s(e = Q(u.length)); e > p; p++) o = f ? l(u[p], p) : u[p], Br(r, p, o); else for (a = (i = h.call(u)).next, r = new s; !(n = a.call(i)).done; p++) o = f ? zn(i, l, [n.value, p], !0) : n.value, Br(r, p, o);
  750. return r.length = p, r
  751. }
  752. });
  753. var Wn = D.Array.from, $n = Wn, Zn = Yt("slice"), Kn = Wt("slice", {ACCESSORS: !0, 0: 0, 1: 2}), Jn = ot("species"),
  754. ti = [].slice, ei = Math.max;
  755. H({target: "Array", proto: !0, forced: !Zn || !Kn}, {
  756. slice: function (t, e) {
  757. var r, n, i, a = g(this), o = Q(a.length), u = He(t, o), s = He(void 0 === e ? o : e, o);
  758. if (Nt(a) && ("function" != typeof (r = a.constructor) || r !== Array && !Nt(r.prototype) ? d(r) && null === (r = r[Jn]) && (r = void 0) : r = void 0, r === Array || void 0 === r)) return ti.call(a, u, s);
  759. for (n = new (void 0 === r ? Array : r)(ei(s - u, 0)), i = 0; u < s; u++, i++) u in a && Br(n, i, a[u]);
  760. return n.length = i, n
  761. }
  762. });
  763. var ri = yt("Array").slice, ni = Array.prototype, ii = function (t) {
  764. var e = t.slice;
  765. return t === ni || t instanceof Array && e === ni.slice ? ri : e
  766. }, ai = ii;
  767. var oi = function (t, e) {
  768. (null == e || e > t.length) && (e = t.length);
  769. for (var r = 0, n = new Array(e); r < e; r++) n[r] = t[r];
  770. return n
  771. };
  772. var ui = function (t, e) {
  773. var r;
  774. if (t) {
  775. if ("string" == typeof t) return oi(t, e);
  776. var n = ai(r = Object.prototype.toString.call(t)).call(r, 8, -1);
  777. return "Object" === n && t.constructor && (n = t.constructor.name), "Map" === n || "Set" === n ? $n(t) : "Arguments" === n || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ? oi(t, e) : void 0
  778. }
  779. };
  780. var si = function () {
  781. throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")
  782. };
  783. var ci = function (t, e) {
  784. return he(t) || In(t, e) || ui(t, e) || si()
  785. }, li = /(\[[^\]]+\])/g, fi = /(#[^\s\+>~\.\[:]+)/g, hi = /(\.[^\s\+>~\.\[:]+)/g,
  786. pi = /(::[^\s\+>~\.\[:]+|:first-line|:first-letter|:before|:after)/gi, yi = /(:[\w-]+\([^\)]*\))/gi,
  787. vi = /(:[^\s\+>~\.\[:]+)/g, gi = /([^\s\+>~\.\[:]+)/g;
  788. function di(t, e) {
  789. var r = t.match(e);
  790. return r ? [t.replace(e, " "), r.length] : [t, 0]
  791. }
  792. function mi(t) {
  793. var e = [0, 0, 0], r = t.replace(/:not\(([^\)]*)\)/g, " $1 ").replace(/{[\s\S]*/gm, " "), n = 0,
  794. i = di(r, li), a = ci(i, 2);
  795. r = a[0], n = a[1], e[1] += n;
  796. var o = di(r, fi), u = ci(o, 2);
  797. r = u[0], n = u[1], e[0] += n;
  798. var s = di(r, hi), c = ci(s, 2);
  799. r = c[0], n = c[1], e[1] += n;
  800. var l = di(r, pi), f = ci(l, 2);
  801. r = f[0], n = f[1], e[2] += n;
  802. var h = di(r, yi), p = ci(h, 2);
  803. r = p[0], n = p[1], e[1] += n;
  804. var y = di(r, vi), v = ci(y, 2);
  805. r = v[0], n = v[1], e[1] += n;
  806. var g = di(r = r.replace(/[\*\s\+>~]/g, " ").replace(/[#\.]/g, " "), gi), d = ci(g, 2);
  807. return r = d[0], n = d[1], e[2] += n, e.join("")
  808. }
  809. var xi = 1e-8;
  810. function bi(t) {
  811. return Math.sqrt(Math.pow(t[0], 2) + Math.pow(t[1], 2))
  812. }
  813. function wi(t, e) {
  814. return (t[0] * e[0] + t[1] * e[1]) / (bi(t) * bi(e))
  815. }
  816. function Si(t, e) {
  817. return (t[0] * e[1] < t[1] * e[0] ? -1 : 1) * Math.acos(wi(t, e))
  818. }
  819. function Ai(t) {
  820. return t * t * t
  821. }
  822. function ki(t) {
  823. return 3 * t * t * (1 - t)
  824. }
  825. function Ti(t) {
  826. return 3 * t * (1 - t) * (1 - t)
  827. }
  828. function Oi(t) {
  829. return (1 - t) * (1 - t) * (1 - t)
  830. }
  831. function Pi(t) {
  832. return t * t
  833. }
  834. function Ei(t) {
  835. return 2 * t * (1 - t)
  836. }
  837. function Ci(t) {
  838. return (1 - t) * (1 - t)
  839. }
  840. H({target: "Object", stat: !0, forced: !o, sham: !o}, {defineProperty: z.f});
  841. var Mi = r((function (t) {
  842. var e = D.Object, r = t.exports = function (t, r, n) {
  843. return e.defineProperty(t, r, n)
  844. };
  845. e.defineProperty.sham && (r.sham = !0)
  846. })), Ni = Mi;
  847. H({target: "Object", stat: !0, forced: !o, sham: !o}, {defineProperties: $e});
  848. var Ri = r((function (t) {
  849. var e = D.Object, r = t.exports = function (t, r) {
  850. return e.defineProperties(t, r)
  851. };
  852. e.defineProperties.sham && (r.sham = !0)
  853. })), _i = jt("Reflect", "ownKeys") || function (t) {
  854. var e = Wr.f(I(t)), r = tn.f;
  855. return r ? e.concat(r(t)) : e
  856. };
  857. H({target: "Object", stat: !0, sham: !o}, {
  858. getOwnPropertyDescriptors: function (t) {
  859. for (var e, r, n = g(t), i = O.f, a = _i(n), o = {}, u = 0; a.length > u;) void 0 !== (r = i(n, e = a[u++])) && Br(o, e, r);
  860. return o
  861. }
  862. });
  863. var Di = D.Object.getOwnPropertyDescriptors, Vi = function (t, e) {
  864. var r = [][t];
  865. return !!r && a((function () {
  866. r.call(null, e || function () {
  867. throw 1
  868. }, 1)
  869. }))
  870. }, Li = Lt.forEach, Ii = Vi("forEach"), ji = Wt("forEach"), zi = Ii && ji ? [].forEach : function (t) {
  871. return Li(this, t, arguments.length > 1 ? arguments[1] : void 0)
  872. };
  873. H({target: "Array", proto: !0, forced: [].forEach != zi}, {forEach: zi});
  874. var Fi = yt("Array").forEach, Bi = Array.prototype, Ui = {DOMTokenList: !0, NodeList: !0}, Hi = function (t) {
  875. var e = t.forEach;
  876. return t === Bi || t instanceof Array && e === Bi.forEach || Ui.hasOwnProperty(ur(t)) ? Fi : e
  877. }, Xi = O.f, Yi = a((function () {
  878. Xi(1)
  879. }));
  880. H({target: "Object", stat: !0, forced: !o || Yi, sham: !o}, {
  881. getOwnPropertyDescriptor: function (t, e) {
  882. return Xi(g(t), e)
  883. }
  884. });
  885. var qi = r((function (t) {
  886. var e = D.Object, r = t.exports = function (t, r) {
  887. return e.getOwnPropertyDescriptor(t, r)
  888. };
  889. e.getOwnPropertyDescriptor.sham && (r.sham = !0)
  890. })), Gi = qi, Qi = Lt.filter, Wi = Yt("filter"), $i = Wt("filter");
  891. H({target: "Array", proto: !0, forced: !Wi || !$i}, {
  892. filter: function (t) {
  893. return Qi(this, t, arguments.length > 1 ? arguments[1] : void 0)
  894. }
  895. });
  896. var Zi = yt("Array").filter, Ki = Array.prototype, Ji = function (t) {
  897. var e = t.filter;
  898. return t === Ki || t instanceof Array && e === Ki.filter ? Zi : e
  899. }, ta = D.Object.getOwnPropertySymbols, ea = a((function () {
  900. We(1)
  901. }));
  902. H({target: "Object", stat: !0, forced: ea}, {
  903. keys: function (t) {
  904. return We(Mt(t))
  905. }
  906. });
  907. var ra = D.Object.keys, na = r((function (t) {
  908. var e = function (t) {
  909. var e, r = Object.prototype, n = r.hasOwnProperty, i = "function" == typeof Symbol ? Symbol : {},
  910. a = i.iterator || "@@iterator", o = i.asyncIterator || "@@asyncIterator",
  911. u = i.toStringTag || "@@toStringTag";
  912. function s(t, e, r) {
  913. return Object.defineProperty(t, e, {value: r, enumerable: !0, configurable: !0, writable: !0}), t[e]
  914. }
  915. try {
  916. s({}, "")
  917. } catch (t) {
  918. s = function (t, e, r) {
  919. return t[e] = r
  920. }
  921. }
  922. function c(t, e, r, n) {
  923. var i = e && e.prototype instanceof g ? e : g, a = Object.create(i.prototype), o = new E(n || []);
  924. return a._invoke = function (t, e, r) {
  925. var n = f;
  926. return function (i, a) {
  927. if (n === p) throw new Error("Generator is already running");
  928. if (n === y) {
  929. if ("throw" === i) throw a;
  930. return M()
  931. }
  932. for (r.method = i, r.arg = a; ;) {
  933. var o = r.delegate;
  934. if (o) {
  935. var u = T(o, r);
  936. if (u) {
  937. if (u === v) continue;
  938. return u
  939. }
  940. }
  941. if ("next" === r.method) r.sent = r._sent = r.arg; else if ("throw" === r.method) {
  942. if (n === f) throw n = y, r.arg;
  943. r.dispatchException(r.arg)
  944. } else "return" === r.method && r.abrupt("return", r.arg);
  945. n = p;
  946. var s = l(t, e, r);
  947. if ("normal" === s.type) {
  948. if (n = r.done ? y : h, s.arg === v) continue;
  949. return {value: s.arg, done: r.done}
  950. }
  951. "throw" === s.type && (n = y, r.method = "throw", r.arg = s.arg)
  952. }
  953. }
  954. }(t, r, o), a
  955. }
  956. function l(t, e, r) {
  957. try {
  958. return {type: "normal", arg: t.call(e, r)}
  959. } catch (t) {
  960. return {type: "throw", arg: t}
  961. }
  962. }
  963. t.wrap = c;
  964. var f = "suspendedStart", h = "suspendedYield", p = "executing", y = "completed", v = {};
  965. function g() {
  966. }
  967. function d() {
  968. }
  969. function m() {
  970. }
  971. var x = {};
  972. x[a] = function () {
  973. return this
  974. };
  975. var b = Object.getPrototypeOf, w = b && b(b(C([])));
  976. w && w !== r && n.call(w, a) && (x = w);
  977. var S = m.prototype = g.prototype = Object.create(x);
  978. function A(t) {
  979. ["next", "throw", "return"].forEach((function (e) {
  980. s(t, e, (function (t) {
  981. return this._invoke(e, t)
  982. }))
  983. }))
  984. }
  985. function k(t, e) {
  986. function r(i, a, o, u) {
  987. var s = l(t[i], t, a);
  988. if ("throw" !== s.type) {
  989. var c = s.arg, f = c.value;
  990. return f && "object" == typeof f && n.call(f, "__await") ? e.resolve(f.__await).then((function (t) {
  991. r("next", t, o, u)
  992. }), (function (t) {
  993. r("throw", t, o, u)
  994. })) : e.resolve(f).then((function (t) {
  995. c.value = t, o(c)
  996. }), (function (t) {
  997. return r("throw", t, o, u)
  998. }))
  999. }
  1000. u(s.arg)
  1001. }
  1002. var i;
  1003. this._invoke = function (t, n) {
  1004. function a() {
  1005. return new e((function (e, i) {
  1006. r(t, n, e, i)
  1007. }))
  1008. }
  1009. return i = i ? i.then(a, a) : a()
  1010. }
  1011. }
  1012. function T(t, r) {
  1013. var n = t.iterator[r.method];
  1014. if (n === e) {
  1015. if (r.delegate = null, "throw" === r.method) {
  1016. if (t.iterator.return && (r.method = "return", r.arg = e, T(t, r), "throw" === r.method)) return v;
  1017. r.method = "throw", r.arg = new TypeError("The iterator does not provide a 'throw' method")
  1018. }
  1019. return v
  1020. }
  1021. var i = l(n, t.iterator, r.arg);
  1022. if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, v;
  1023. var a = i.arg;
  1024. return a ? a.done ? (r[t.resultName] = a.value, r.next = t.nextLoc, "return" !== r.method && (r.method = "next", r.arg = e), r.delegate = null, v) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, v)
  1025. }
  1026. function O(t) {
  1027. var e = {tryLoc: t[0]};
  1028. 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e)
  1029. }
  1030. function P(t) {
  1031. var e = t.completion || {};
  1032. e.type = "normal", delete e.arg, t.completion = e
  1033. }
  1034. function E(t) {
  1035. this.tryEntries = [{tryLoc: "root"}], t.forEach(O, this), this.reset(!0)
  1036. }
  1037. function C(t) {
  1038. if (t) {
  1039. var r = t[a];
  1040. if (r) return r.call(t);
  1041. if ("function" == typeof t.next) return t;
  1042. if (!isNaN(t.length)) {
  1043. var i = -1, o = function r() {
  1044. for (; ++i < t.length;) if (n.call(t, i)) return r.value = t[i], r.done = !1, r;
  1045. return r.value = e, r.done = !0, r
  1046. };
  1047. return o.next = o
  1048. }
  1049. }
  1050. return {next: M}
  1051. }
  1052. function M() {
  1053. return {value: e, done: !0}
  1054. }
  1055. return d.prototype = S.constructor = m, m.constructor = d, d.displayName = s(m, u, "GeneratorFunction"), t.isGeneratorFunction = function (t) {
  1056. var e = "function" == typeof t && t.constructor;
  1057. return !!e && (e === d || "GeneratorFunction" === (e.displayName || e.name))
  1058. }, t.mark = function (t) {
  1059. return Object.setPrototypeOf ? Object.setPrototypeOf(t, m) : (t.__proto__ = m, s(t, u, "GeneratorFunction")), t.prototype = Object.create(S), t
  1060. }, t.awrap = function (t) {
  1061. return {__await: t}
  1062. }, A(k.prototype), k.prototype[o] = function () {
  1063. return this
  1064. }, t.AsyncIterator = k, t.async = function (e, r, n, i, a) {
  1065. void 0 === a && (a = Promise);
  1066. var o = new k(c(e, r, n, i), a);
  1067. return t.isGeneratorFunction(r) ? o : o.next().then((function (t) {
  1068. return t.done ? t.value : o.next()
  1069. }))
  1070. }, A(S), s(S, u, "Generator"), S[a] = function () {
  1071. return this
  1072. }, S.toString = function () {
  1073. return "[object Generator]"
  1074. }, t.keys = function (t) {
  1075. var e = [];
  1076. for (var r in t) e.push(r);
  1077. return e.reverse(), function r() {
  1078. for (; e.length;) {
  1079. var n = e.pop();
  1080. if (n in t) return r.value = n, r.done = !1, r
  1081. }
  1082. return r.done = !0, r
  1083. }
  1084. }, t.values = C, E.prototype = {
  1085. constructor: E, reset: function (t) {
  1086. if (this.prev = 0, this.next = 0, this.sent = this._sent = e, this.done = !1, this.delegate = null, this.method = "next", this.arg = e, this.tryEntries.forEach(P), !t) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = e)
  1087. }, stop: function () {
  1088. this.done = !0;
  1089. var t = this.tryEntries[0].completion;
  1090. if ("throw" === t.type) throw t.arg;
  1091. return this.rval
  1092. }, dispatchException: function (t) {
  1093. if (this.done) throw t;
  1094. var r = this;
  1095. function i(n, i) {
  1096. return u.type = "throw", u.arg = t, r.next = n, i && (r.method = "next", r.arg = e), !!i
  1097. }
  1098. for (var a = this.tryEntries.length - 1; a >= 0; --a) {
  1099. var o = this.tryEntries[a], u = o.completion;
  1100. if ("root" === o.tryLoc) return i("end");
  1101. if (o.tryLoc <= this.prev) {
  1102. var s = n.call(o, "catchLoc"), c = n.call(o, "finallyLoc");
  1103. if (s && c) {
  1104. if (this.prev < o.catchLoc) return i(o.catchLoc, !0);
  1105. if (this.prev < o.finallyLoc) return i(o.finallyLoc)
  1106. } else if (s) {
  1107. if (this.prev < o.catchLoc) return i(o.catchLoc, !0)
  1108. } else {
  1109. if (!c) throw new Error("try statement without catch or finally");
  1110. if (this.prev < o.finallyLoc) return i(o.finallyLoc)
  1111. }
  1112. }
  1113. }
  1114. }, abrupt: function (t, e) {
  1115. for (var r = this.tryEntries.length - 1; r >= 0; --r) {
  1116. var i = this.tryEntries[r];
  1117. if (i.tryLoc <= this.prev && n.call(i, "finallyLoc") && this.prev < i.finallyLoc) {
  1118. var a = i;
  1119. break
  1120. }
  1121. }
  1122. a && ("break" === t || "continue" === t) && a.tryLoc <= e && e <= a.finallyLoc && (a = null);
  1123. var o = a ? a.completion : {};
  1124. return o.type = t, o.arg = e, a ? (this.method = "next", this.next = a.finallyLoc, v) : this.complete(o)
  1125. }, complete: function (t, e) {
  1126. if ("throw" === t.type) throw t.arg;
  1127. return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), v
  1128. }, finish: function (t) {
  1129. for (var e = this.tryEntries.length - 1; e >= 0; --e) {
  1130. var r = this.tryEntries[e];
  1131. if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), P(r), v
  1132. }
  1133. }, catch: function (t) {
  1134. for (var e = this.tryEntries.length - 1; e >= 0; --e) {
  1135. var r = this.tryEntries[e];
  1136. if (r.tryLoc === t) {
  1137. var n = r.completion;
  1138. if ("throw" === n.type) {
  1139. var i = n.arg;
  1140. P(r)
  1141. }
  1142. return i
  1143. }
  1144. }
  1145. throw new Error("illegal catch attempt")
  1146. }, delegateYield: function (t, r, n) {
  1147. return this.delegate = {
  1148. iterator: C(t),
  1149. resultName: r,
  1150. nextLoc: n
  1151. }, "next" === this.method && (this.arg = e), v
  1152. }
  1153. }, t
  1154. }(t.exports);
  1155. try {
  1156. regeneratorRuntime = e
  1157. } catch (t) {
  1158. Function("r", "regeneratorRuntime = r")(e)
  1159. }
  1160. })), ia = function (t, e) {
  1161. this.stopped = t, this.result = e
  1162. }, aa = function (t, e, r) {
  1163. var n, i, a, o, u, s, c, l = r && r.that, f = !(!r || !r.AS_ENTRIES), h = !(!r || !r.IS_ITERATOR),
  1164. p = !(!r || !r.INTERRUPTED), y = L(e, l, 1 + f + p), v = function (t) {
  1165. return n && jn(n), new ia(!0, t)
  1166. }, g = function (t) {
  1167. return f ? (I(t), p ? y(t[0], t[1], v) : y(t[0], t[1])) : p ? y(t, v) : y(t)
  1168. };
  1169. if (h) n = t; else {
  1170. if ("function" != typeof (i = Ir(t))) throw TypeError("Target is not iterable");
  1171. if (Un(i)) {
  1172. for (a = 0, o = Q(t.length); o > a; a++) if ((u = g(t[a])) && u instanceof ia) return u;
  1173. return new ia(!1)
  1174. }
  1175. n = i.call(t)
  1176. }
  1177. for (s = n.next; !(c = s.call(n)).done;) {
  1178. try {
  1179. u = g(c.value)
  1180. } catch (t) {
  1181. throw jn(n), t
  1182. }
  1183. if ("object" == typeof u && u && u instanceof ia) return u
  1184. }
  1185. return new ia(!1)
  1186. }, oa = function (t, e) {
  1187. var r = this;
  1188. if (!(r instanceof oa)) return new oa(t, e);
  1189. yr && (r = yr(new Error(void 0), Ie(r))), void 0 !== e && F(r, "message", String(e));
  1190. var n = [];
  1191. return aa(t, n.push, {that: n}), F(r, "errors", n), r
  1192. };
  1193. oa.prototype = rr(Error.prototype, {
  1194. constructor: l(5, oa),
  1195. message: l(5, ""),
  1196. name: l(5, "AggregateError")
  1197. }), H({global: !0}, {AggregateError: oa});
  1198. var ua, sa, ca, la = i.Promise, fa = function (t, e, r) {
  1199. for (var n in e) r && r.unsafe && t[n] ? t[n] = e[n] : vr(t, n, e[n], r);
  1200. return t
  1201. }, ha = ot("species"), pa = function (t) {
  1202. var e = jt(t), r = z.f;
  1203. o && e && !e[ha] && r(e, ha, {
  1204. configurable: !0, get: function () {
  1205. return this
  1206. }
  1207. })
  1208. }, ya = function (t, e, r) {
  1209. if (!(t instanceof e)) throw TypeError("Incorrect " + (r ? r + " " : "") + "invocation");
  1210. return t
  1211. }, va = ot("species"), ga = function (t, e) {
  1212. var r, n = I(t).constructor;
  1213. return void 0 === n || null == (r = I(n)[va]) ? e : V(r)
  1214. }, da = /(iphone|ipod|ipad).*applewebkit/i.test(zt), ma = "process" == h(i.process), xa = i.location,
  1215. ba = i.setImmediate, wa = i.clearImmediate, Sa = i.process, Aa = i.MessageChannel, ka = i.Dispatch, Ta = 0,
  1216. Oa = {}, Pa = "onreadystatechange", Ea = function (t) {
  1217. if (Oa.hasOwnProperty(t)) {
  1218. var e = Oa[t];
  1219. delete Oa[t], e()
  1220. }
  1221. }, Ca = function (t) {
  1222. return function () {
  1223. Ea(t)
  1224. }
  1225. }, Ma = function (t) {
  1226. Ea(t.data)
  1227. }, Na = function (t) {
  1228. i.postMessage(t + "", xa.protocol + "//" + xa.host)
  1229. };
  1230. ba && wa || (ba = function (t) {
  1231. for (var e = [], r = 1; arguments.length > r;) e.push(arguments[r++]);
  1232. return Oa[++Ta] = function () {
  1233. ("function" == typeof t ? t : Function(t)).apply(void 0, e)
  1234. }, ua(Ta), Ta
  1235. }, wa = function (t) {
  1236. delete Oa[t]
  1237. }, ma ? ua = function (t) {
  1238. Sa.nextTick(Ca(t))
  1239. } : ka && ka.now ? ua = function (t) {
  1240. ka.now(Ca(t))
  1241. } : Aa && !da ? (ca = (sa = new Aa).port2, sa.port1.onmessage = Ma, ua = L(ca.postMessage, ca, 1)) : i.addEventListener && "function" == typeof postMessage && !i.importScripts && xa && "file:" !== xa.protocol && !a(Na) ? (ua = Na, i.addEventListener("message", Ma, !1)) : ua = Pa in A("script") ? function (t) {
  1242. Ze.appendChild(A("script")).onreadystatechange = function () {
  1243. Ze.removeChild(this), Ea(t)
  1244. }
  1245. } : function (t) {
  1246. setTimeout(Ca(t), 0)
  1247. });
  1248. var Ra, _a, Da, Va, La, Ia, ja, za, Fa = {set: ba, clear: wa}, Ba = O.f, Ua = Fa.set,
  1249. Ha = i.MutationObserver || i.WebKitMutationObserver, Xa = i.document, Ya = i.process, qa = i.Promise,
  1250. Ga = Ba(i, "queueMicrotask"), Qa = Ga && Ga.value;
  1251. Qa || (Ra = function () {
  1252. var t, e;
  1253. for (ma && (t = Ya.domain) && t.exit(); _a;) {
  1254. e = _a.fn, _a = _a.next;
  1255. try {
  1256. e()
  1257. } catch (t) {
  1258. throw _a ? Va() : Da = void 0, t
  1259. }
  1260. }
  1261. Da = void 0, t && t.enter()
  1262. }, !da && !ma && Ha && Xa ? (La = !0, Ia = Xa.createTextNode(""), new Ha(Ra).observe(Ia, {characterData: !0}), Va = function () {
  1263. Ia.data = La = !La
  1264. }) : qa && qa.resolve ? (ja = qa.resolve(void 0), za = ja.then, Va = function () {
  1265. za.call(ja, Ra)
  1266. }) : Va = ma ? function () {
  1267. Ya.nextTick(Ra)
  1268. } : function () {
  1269. Ua.call(i, Ra)
  1270. });
  1271. var Wa, $a, Za, Ka = Qa || function (t) {
  1272. var e = {fn: t, next: void 0};
  1273. Da && (Da.next = e), _a || (_a = e, Va()), Da = e
  1274. }, Ja = function (t) {
  1275. var e, r;
  1276. this.promise = new t((function (t, n) {
  1277. if (void 0 !== e || void 0 !== r) throw TypeError("Bad Promise constructor");
  1278. e = t, r = n
  1279. })), this.resolve = V(e), this.reject = V(r)
  1280. }, to = {
  1281. f: function (t) {
  1282. return new Ja(t)
  1283. }
  1284. }, eo = function (t, e) {
  1285. if (I(t), d(e) && e.constructor === t) return e;
  1286. var r = to.f(t);
  1287. return (0, r.resolve)(e), r.promise
  1288. }, ro = function (t) {
  1289. try {
  1290. return {error: !1, value: t()}
  1291. } catch (t) {
  1292. return {error: !0, value: t}
  1293. }
  1294. }, no = Fa.set, io = ot("species"), ao = "Promise", oo = _e.get, uo = _e.set, so = _e.getterFor(ao), co = la,
  1295. lo = i.TypeError, fo = i.document, ho = i.process, po = (jt("fetch"), to.f), yo = po,
  1296. vo = !!(fo && fo.createEvent && i.dispatchEvent), go = "function" == typeof PromiseRejectionEvent,
  1297. mo = "unhandledrejection", xo = _(ao, (function () {
  1298. if (!(me(co) !== String(co))) {
  1299. if (66 === Ht) return !0;
  1300. if (!ma && !go) return !0
  1301. }
  1302. if (!co.prototype.finally) return !0;
  1303. if (Ht >= 51 && /native code/.test(co)) return !1;
  1304. var t = co.resolve(1), e = function (t) {
  1305. t((function () {
  1306. }), (function () {
  1307. }))
  1308. };
  1309. return (t.constructor = {})[io] = e, !(t.then((function () {
  1310. })) instanceof e)
  1311. })), bo = xo || !Gn((function (t) {
  1312. co.all(t).catch((function () {
  1313. }))
  1314. })), wo = function (t) {
  1315. var e;
  1316. return !(!d(t) || "function" != typeof (e = t.then)) && e
  1317. }, So = function (t, e) {
  1318. if (!t.notified) {
  1319. t.notified = !0;
  1320. var r = t.reactions;
  1321. Ka((function () {
  1322. for (var n = t.value, i = 1 == t.state, a = 0; r.length > a;) {
  1323. var o, u, s, c = r[a++], l = i ? c.ok : c.fail, f = c.resolve, h = c.reject, p = c.domain;
  1324. try {
  1325. l ? (i || (2 === t.rejection && Oo(t), t.rejection = 1), !0 === l ? o = n : (p && p.enter(), o = l(n), p && (p.exit(), s = !0)), o === c.promise ? h(lo("Promise-chain cycle")) : (u = wo(o)) ? u.call(o, f, h) : f(o)) : h(n)
  1326. } catch (t) {
  1327. p && !s && p.exit(), h(t)
  1328. }
  1329. }
  1330. t.reactions = [], t.notified = !1, e && !t.rejection && ko(t)
  1331. }))
  1332. }
  1333. }, Ao = function (t, e, r) {
  1334. var n, a;
  1335. vo ? ((n = fo.createEvent("Event")).promise = e, n.reason = r, n.initEvent(t, !1, !0), i.dispatchEvent(n)) : n = {
  1336. promise: e,
  1337. reason: r
  1338. }, !go && (a = i["on" + t]) ? a(n) : t === mo && function (t, e) {
  1339. var r = i.console;
  1340. r && r.error && (1 === arguments.length ? r.error(t) : r.error(t, e))
  1341. }("Unhandled promise rejection", r)
  1342. }, ko = function (t) {
  1343. no.call(i, (function () {
  1344. var e, r = t.facade, n = t.value;
  1345. if (To(t) && (e = ro((function () {
  1346. ma ? ho.emit("unhandledRejection", n, r) : Ao(mo, r, n)
  1347. })), t.rejection = ma || To(t) ? 2 : 1, e.error)) throw e.value
  1348. }))
  1349. }, To = function (t) {
  1350. return 1 !== t.rejection && !t.parent
  1351. }, Oo = function (t) {
  1352. no.call(i, (function () {
  1353. var e = t.facade;
  1354. ma ? ho.emit("rejectionHandled", e) : Ao("rejectionhandled", e, t.value)
  1355. }))
  1356. }, Po = function (t, e, r) {
  1357. return function (n) {
  1358. t(e, n, r)
  1359. }
  1360. }, Eo = function (t, e, r) {
  1361. t.done || (t.done = !0, r && (t = r), t.value = e, t.state = 2, So(t, !0))
  1362. }, Co = function (t, e, r) {
  1363. if (!t.done) {
  1364. t.done = !0, r && (t = r);
  1365. try {
  1366. if (t.facade === e) throw lo("Promise can't be resolved itself");
  1367. var n = wo(e);
  1368. n ? Ka((function () {
  1369. var r = {done: !1};
  1370. try {
  1371. n.call(e, Po(Co, r, t), Po(Eo, r, t))
  1372. } catch (e) {
  1373. Eo(r, e, t)
  1374. }
  1375. })) : (t.value = e, t.state = 1, So(t, !1))
  1376. } catch (e) {
  1377. Eo({done: !1}, e, t)
  1378. }
  1379. }
  1380. };
  1381. xo && (co = function (t) {
  1382. ya(this, co, ao), V(t), Wa.call(this);
  1383. var e = oo(this);
  1384. try {
  1385. t(Po(Co, e), Po(Eo, e))
  1386. } catch (t) {
  1387. Eo(e, t)
  1388. }
  1389. }, (Wa = function (t) {
  1390. uo(this, {type: ao, done: !1, notified: !1, parent: !1, reactions: [], rejection: !1, state: 0, value: void 0})
  1391. }).prototype = fa(co.prototype, {
  1392. then: function (t, e) {
  1393. var r = so(this), n = po(ga(this, co));
  1394. return n.ok = "function" != typeof t || t, n.fail = "function" == typeof e && e, n.domain = ma ? ho.domain : void 0, r.parent = !0, r.reactions.push(n), 0 != r.state && So(r, !1), n.promise
  1395. }, catch: function (t) {
  1396. return this.then(void 0, t)
  1397. }
  1398. }), $a = function () {
  1399. var t = new Wa, e = oo(t);
  1400. this.promise = t, this.resolve = Po(Co, e), this.reject = Po(Eo, e)
  1401. }, to.f = po = function (t) {
  1402. return t === co || t === Za ? new $a(t) : yo(t)
  1403. }), H({global: !0, wrap: !0, forced: xo}, {Promise: co}), fr(co, ao, !1, !0), pa(ao), Za = jt(ao), H({
  1404. target: ao,
  1405. stat: !0,
  1406. forced: xo
  1407. }, {
  1408. reject: function (t) {
  1409. var e = po(this);
  1410. return e.reject.call(void 0, t), e.promise
  1411. }
  1412. }), H({target: ao, stat: !0, forced: !0}, {
  1413. resolve: function (t) {
  1414. return eo(this === Za ? co : this, t)
  1415. }
  1416. }), H({target: ao, stat: !0, forced: bo}, {
  1417. all: function (t) {
  1418. var e = this, r = po(e), n = r.resolve, i = r.reject, a = ro((function () {
  1419. var r = V(e.resolve), a = [], o = 0, u = 1;
  1420. aa(t, (function (t) {
  1421. var s = o++, c = !1;
  1422. a.push(void 0), u++, r.call(e, t).then((function (t) {
  1423. c || (c = !0, a[s] = t, --u || n(a))
  1424. }), i)
  1425. })), --u || n(a)
  1426. }));
  1427. return a.error && i(a.value), r.promise
  1428. }, race: function (t) {
  1429. var e = this, r = po(e), n = r.reject, i = ro((function () {
  1430. var i = V(e.resolve);
  1431. aa(t, (function (t) {
  1432. i.call(e, t).then(r.resolve, n)
  1433. }))
  1434. }));
  1435. return i.error && n(i.value), r.promise
  1436. }
  1437. }), H({target: "Promise", stat: !0}, {
  1438. allSettled: function (t) {
  1439. var e = this, r = to.f(e), n = r.resolve, i = r.reject, a = ro((function () {
  1440. var r = V(e.resolve), i = [], a = 0, o = 1;
  1441. aa(t, (function (t) {
  1442. var u = a++, s = !1;
  1443. i.push(void 0), o++, r.call(e, t).then((function (t) {
  1444. s || (s = !0, i[u] = {status: "fulfilled", value: t}, --o || n(i))
  1445. }), (function (t) {
  1446. s || (s = !0, i[u] = {status: "rejected", reason: t}, --o || n(i))
  1447. }))
  1448. })), --o || n(i)
  1449. }));
  1450. return a.error && i(a.value), r.promise
  1451. }
  1452. });
  1453. var Mo = "No one promise resolved";
  1454. H({target: "Promise", stat: !0}, {
  1455. any: function (t) {
  1456. var e = this, r = to.f(e), n = r.resolve, i = r.reject, a = ro((function () {
  1457. var r = V(e.resolve), a = [], o = 0, u = 1, s = !1;
  1458. aa(t, (function (t) {
  1459. var c = o++, l = !1;
  1460. a.push(void 0), u++, r.call(e, t).then((function (t) {
  1461. l || s || (s = !0, n(t))
  1462. }), (function (t) {
  1463. l || s || (l = !0, a[c] = t, --u || i(new (jt("AggregateError"))(a, Mo)))
  1464. }))
  1465. })), --u || i(new (jt("AggregateError"))(a, Mo))
  1466. }));
  1467. return a.error && i(a.value), r.promise
  1468. }
  1469. });
  1470. var No = !!la && a((function () {
  1471. la.prototype.finally.call({
  1472. then: function () {
  1473. }
  1474. }, (function () {
  1475. }))
  1476. }));
  1477. H({target: "Promise", proto: !0, real: !0, forced: No}, {
  1478. finally: function (t) {
  1479. var e = ga(this, jt("Promise")), r = "function" == typeof t;
  1480. return this.then(r ? function (r) {
  1481. return eo(e, t()).then((function () {
  1482. return r
  1483. }))
  1484. } : t, r ? function (r) {
  1485. return eo(e, t()).then((function () {
  1486. throw r
  1487. }))
  1488. } : t)
  1489. }
  1490. });
  1491. var Ro = D.Promise;
  1492. H({target: "Promise", stat: !0}, {
  1493. try: function (t) {
  1494. var e = to.f(this), r = ro(t);
  1495. return (r.error ? e.reject : e.resolve)(r.value), e.promise
  1496. }
  1497. });
  1498. var _o = Ro;
  1499. function Do(t, e, r, n, i, a, o) {
  1500. try {
  1501. var u = t[a](o), s = u.value
  1502. } catch (t) {
  1503. return void r(t)
  1504. }
  1505. u.done ? e(s) : _o.resolve(s).then(n, i)
  1506. }
  1507. var Vo = function (t) {
  1508. return function () {
  1509. var e = this, r = arguments;
  1510. return new _o((function (n, i) {
  1511. var a = t.apply(e, r);
  1512. function o(t) {
  1513. Do(a, n, i, o, u, "next", t)
  1514. }
  1515. function u(t) {
  1516. Do(a, n, i, o, u, "throw", t)
  1517. }
  1518. o(void 0)
  1519. }))
  1520. }
  1521. }, Lo = Mi;
  1522. var Io = function (t, e, r) {
  1523. return e in t ? Lo(t, e, {value: r, enumerable: !0, configurable: !0, writable: !0}) : t[e] = r, t
  1524. };
  1525. var jo = function (t, e) {
  1526. if (!(t instanceof e)) throw new TypeError("Cannot call a class as a function")
  1527. };
  1528. function zo(t, e) {
  1529. for (var r = 0; r < e.length; r++) {
  1530. var n = e[r];
  1531. n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Lo(t, n.key, n)
  1532. }
  1533. }
  1534. var Fo = function (t, e, r) {
  1535. return e && zo(t.prototype, e), r && zo(t, r), t
  1536. }, Bo = yt("Array").concat, Uo = Array.prototype, Ho = function (t) {
  1537. var e = t.concat;
  1538. return t === Uo || t instanceof Array && e === Uo.concat ? Bo : e
  1539. }, Xo = function (t) {
  1540. return function (e, r, n, i) {
  1541. V(r);
  1542. var a = Mt(e), o = y(a), u = Q(a.length), s = t ? u - 1 : 0, c = t ? -1 : 1;
  1543. if (n < 2) for (; ;) {
  1544. if (s in o) {
  1545. i = o[s], s += c;
  1546. break
  1547. }
  1548. if (s += c, t ? s < 0 : u <= s) throw TypeError("Reduce of empty array with no initial value")
  1549. }
  1550. for (; t ? s >= 0 : u > s; s += c) s in o && (i = r(i, o[s], s, a));
  1551. return i
  1552. }
  1553. }, Yo = {left: Xo(!1), right: Xo(!0)}.left, qo = Vi("reduce"), Go = Wt("reduce", {1: 0});
  1554. H({target: "Array", proto: !0, forced: !qo || !Go || !ma && Ht > 79 && Ht < 83}, {
  1555. reduce: function (t) {
  1556. return Yo(this, t, arguments.length, arguments.length > 1 ? arguments[1] : void 0)
  1557. }
  1558. });
  1559. var Qo = yt("Array").reduce, Wo = Array.prototype, $o = function (t) {
  1560. var e = t.reduce;
  1561. return t === Wo || t instanceof Array && e === Wo.reduce ? Qo : e
  1562. };
  1563. H({target: "Date", stat: !0}, {
  1564. now: function () {
  1565. return (new Date).getTime()
  1566. }
  1567. });
  1568. var Zo = D.Date.now, Ko = Lt.every, Jo = Vi("every"), tu = Wt("every");
  1569. H({target: "Array", proto: !0, forced: !Jo || !tu}, {
  1570. every: function (t) {
  1571. return Ko(this, t, arguments.length > 1 ? arguments[1] : void 0)
  1572. }
  1573. });
  1574. var eu = yt("Array").every, ru = Array.prototype, nu = function (t) {
  1575. var e = t.every;
  1576. return t === ru || t instanceof Array && e === ru.every ? eu : e
  1577. }, iu = Ro, au = [].slice, ou = {}, uu = function (t, e, r) {
  1578. if (!(e in ou)) {
  1579. for (var n = [], i = 0; i < e; i++) n[i] = "a[" + i + "]";
  1580. ou[e] = Function("C,a", "return new C(" + n.join(",") + ")")
  1581. }
  1582. return ou[e](t, r)
  1583. }, su = Function.bind || function (t) {
  1584. var e = V(this), r = au.call(arguments, 1), n = function () {
  1585. var i = r.concat(au.call(arguments));
  1586. return this instanceof n ? uu(e, i.length, i) : e.apply(t, i)
  1587. };
  1588. return d(e.prototype) && (n.prototype = e.prototype), n
  1589. };
  1590. H({target: "Function", proto: !0}, {bind: su});
  1591. var cu = yt("Function").bind, lu = Function.prototype, fu = function (t) {
  1592. var e = t.bind;
  1593. return t === lu || t instanceof Function && e === lu.bind ? cu : e
  1594. },
  1595. hu = "undefined" != typeof global ? global : "undefined" != typeof self ? self : "undefined" != typeof window ? window : {};
  1596. function pu() {
  1597. throw new Error("setTimeout has not been defined")
  1598. }
  1599. function yu() {
  1600. throw new Error("clearTimeout has not been defined")
  1601. }
  1602. var vu = pu, gu = yu;
  1603. function du(t) {
  1604. if (vu === setTimeout) return setTimeout(t, 0);
  1605. if ((vu === pu || !vu) && setTimeout) return vu = setTimeout, setTimeout(t, 0);
  1606. try {
  1607. return vu(t, 0)
  1608. } catch (e) {
  1609. try {
  1610. return vu.call(null, t, 0)
  1611. } catch (e) {
  1612. return vu.call(this, t, 0)
  1613. }
  1614. }
  1615. }
  1616. "function" == typeof hu.setTimeout && (vu = setTimeout), "function" == typeof hu.clearTimeout && (gu = clearTimeout);
  1617. var mu, xu = [], bu = !1, wu = -1;
  1618. function Su() {
  1619. bu && mu && (bu = !1, mu.length ? xu = mu.concat(xu) : wu = -1, xu.length && Au())
  1620. }
  1621. function Au() {
  1622. if (!bu) {
  1623. var t = du(Su);
  1624. bu = !0;
  1625. for (var e = xu.length; e;) {
  1626. for (mu = xu, xu = []; ++wu < e;) mu && mu[wu].run();
  1627. wu = -1, e = xu.length
  1628. }
  1629. mu = null, bu = !1, function (t) {
  1630. if (gu === clearTimeout) return clearTimeout(t);
  1631. if ((gu === yu || !gu) && clearTimeout) return gu = clearTimeout, clearTimeout(t);
  1632. try {
  1633. gu(t)
  1634. } catch (e) {
  1635. try {
  1636. return gu.call(null, t)
  1637. } catch (e) {
  1638. return gu.call(this, t)
  1639. }
  1640. }
  1641. }(t)
  1642. }
  1643. }
  1644. function ku(t, e) {
  1645. this.fun = t, this.array = e
  1646. }
  1647. ku.prototype.run = function () {
  1648. this.fun.apply(null, this.array)
  1649. };
  1650. function Tu() {
  1651. }
  1652. var Ou = Tu, Pu = Tu, Eu = Tu, Cu = Tu, Mu = Tu, Nu = Tu, Ru = Tu;
  1653. var _u = hu.performance || {}, Du = _u.now || _u.mozNow || _u.msNow || _u.oNow || _u.webkitNow || function () {
  1654. return (new Date).getTime()
  1655. };
  1656. var Vu = new Date;
  1657. for (var Lu = {
  1658. nextTick: function (t) {
  1659. var e = new Array(arguments.length - 1);
  1660. if (arguments.length > 1) for (var r = 1; r < arguments.length; r++) e[r - 1] = arguments[r];
  1661. xu.push(new ku(t, e)), 1 !== xu.length || bu || du(Au)
  1662. },
  1663. title: "browser",
  1664. browser: !0,
  1665. env: {},
  1666. argv: [],
  1667. version: "",
  1668. versions: {},
  1669. on: Ou,
  1670. addListener: Pu,
  1671. once: Eu,
  1672. off: Cu,
  1673. removeListener: Mu,
  1674. removeAllListeners: Nu,
  1675. emit: Ru,
  1676. binding: function (t) {
  1677. throw new Error("process.binding is not supported")
  1678. },
  1679. cwd: function () {
  1680. return "/"
  1681. },
  1682. chdir: function (t) {
  1683. throw new Error("process.chdir is not supported")
  1684. },
  1685. umask: function () {
  1686. return 0
  1687. },
  1688. hrtime: function (t) {
  1689. var e = .001 * Du.call(_u), r = Math.floor(e), n = Math.floor(e % 1 * 1e9);
  1690. return t && (r -= t[0], (n -= t[1]) < 0 && (r--, n += 1e9)), [r, n]
  1691. },
  1692. platform: "browser",
  1693. release: {},
  1694. config: {},
  1695. uptime: function () {
  1696. return (new Date - Vu) / 1e3
  1697. }
  1698. }, Iu = r((function (t) {
  1699. (function () {
  1700. var e, r, n, i, a, o;
  1701. "undefined" != typeof performance && null !== performance && performance.now ? t.exports = function () {
  1702. return performance.now()
  1703. } : null != Lu && Lu.hrtime ? (t.exports = function () {
  1704. return (e() - a) / 1e6
  1705. }, r = Lu.hrtime, i = (e = function () {
  1706. var t;
  1707. return 1e9 * (t = r())[0] + t[1]
  1708. })(), o = 1e9 * Lu.uptime(), a = i - o) : Date.now ? (t.exports = function () {
  1709. return Date.now() - n
  1710. }, n = Date.now()) : (t.exports = function () {
  1711. return (new Date).getTime() - n
  1712. }, n = (new Date).getTime())
  1713. }).call(e)
  1714. })), ju = "undefined" == typeof window ? e : window, zu = ["moz", "webkit"], Fu = "AnimationFrame", Bu = ju["request" + Fu], Uu = ju["cancel" + Fu] || ju["cancelRequest" + Fu], Hu = 0; !Bu && Hu < zu.length; Hu++) Bu = ju[zu[Hu] + "Request" + Fu], Uu = ju[zu[Hu] + "Cancel" + Fu] || ju[zu[Hu] + "CancelRequest" + Fu];
  1715. if (!Bu || !Uu) {
  1716. var Xu = 0, Yu = 0, qu = [];
  1717. Bu = function (t) {
  1718. if (0 === qu.length) {
  1719. var e = Iu(), r = Math.max(0, 16.666666666666668 - (e - Xu));
  1720. Xu = r + e, setTimeout((function () {
  1721. var t = qu.slice(0);
  1722. qu.length = 0;
  1723. for (var e = 0; e < t.length; e++) if (!t[e].cancelled) try {
  1724. t[e].callback(Xu)
  1725. } catch (t) {
  1726. setTimeout((function () {
  1727. throw t
  1728. }), 0)
  1729. }
  1730. }), Math.round(r))
  1731. }
  1732. return qu.push({handle: ++Yu, callback: t, cancelled: !1}), Yu
  1733. }, Uu = function (t) {
  1734. for (var e = 0; e < qu.length; e++) qu[e].handle === t && (qu[e].cancelled = !0)
  1735. }
  1736. }
  1737. var Gu = function (t) {
  1738. return Bu.call(ju, t)
  1739. };
  1740. Gu.cancel = function () {
  1741. Uu.apply(ju, arguments)
  1742. }, Gu.polyfill = function (t) {
  1743. t || (t = ju), t.requestAnimationFrame = Bu, t.cancelAnimationFrame = Uu
  1744. };
  1745. var Qu, Wu = At.trim;
  1746. H({
  1747. target: "String", proto: !0, forced: (Qu = "trim", a((function () {
  1748. return !!mt[Qu]() || "​…᠎" != "​…᠎"[Qu]() || mt[Qu].name !== Qu
  1749. })))
  1750. }, {
  1751. trim: function () {
  1752. return Wu(this)
  1753. }
  1754. });
  1755. var $u = yt("String").trim, Zu = String.prototype, Ku = function (t) {
  1756. var e = t.trim;
  1757. return "string" == typeof t || t === Zu || t instanceof String && e === Zu.trim ? $u : e
  1758. }, Ju = function (t) {
  1759. this.ok = !1, this.alpha = 1, "#" == t.charAt(0) && (t = t.substr(1, 6)), t = (t = t.replace(/ /g, "")).toLowerCase();
  1760. var e = {
  1761. aliceblue: "f0f8ff",
  1762. antiquewhite: "faebd7",
  1763. aqua: "00ffff",
  1764. aquamarine: "7fffd4",
  1765. azure: "f0ffff",
  1766. beige: "f5f5dc",
  1767. bisque: "ffe4c4",
  1768. black: "000000",
  1769. blanchedalmond: "ffebcd",
  1770. blue: "0000ff",
  1771. blueviolet: "8a2be2",
  1772. brown: "a52a2a",
  1773. burlywood: "deb887",
  1774. cadetblue: "5f9ea0",
  1775. chartreuse: "7fff00",
  1776. chocolate: "d2691e",
  1777. coral: "ff7f50",
  1778. cornflowerblue: "6495ed",
  1779. cornsilk: "fff8dc",
  1780. crimson: "dc143c",
  1781. cyan: "00ffff",
  1782. darkblue: "00008b",
  1783. darkcyan: "008b8b",
  1784. darkgoldenrod: "b8860b",
  1785. darkgray: "a9a9a9",
  1786. darkgreen: "006400",
  1787. darkkhaki: "bdb76b",
  1788. darkmagenta: "8b008b",
  1789. darkolivegreen: "556b2f",
  1790. darkorange: "ff8c00",
  1791. darkorchid: "9932cc",
  1792. darkred: "8b0000",
  1793. darksalmon: "e9967a",
  1794. darkseagreen: "8fbc8f",
  1795. darkslateblue: "483d8b",
  1796. darkslategray: "2f4f4f",
  1797. darkturquoise: "00ced1",
  1798. darkviolet: "9400d3",
  1799. deeppink: "ff1493",
  1800. deepskyblue: "00bfff",
  1801. dimgray: "696969",
  1802. dodgerblue: "1e90ff",
  1803. feldspar: "d19275",
  1804. firebrick: "b22222",
  1805. floralwhite: "fffaf0",
  1806. forestgreen: "228b22",
  1807. fuchsia: "ff00ff",
  1808. gainsboro: "dcdcdc",
  1809. ghostwhite: "f8f8ff",
  1810. gold: "ffd700",
  1811. goldenrod: "daa520",
  1812. gray: "808080",
  1813. green: "008000",
  1814. greenyellow: "adff2f",
  1815. honeydew: "f0fff0",
  1816. hotpink: "ff69b4",
  1817. indianred: "cd5c5c",
  1818. indigo: "4b0082",
  1819. ivory: "fffff0",
  1820. khaki: "f0e68c",
  1821. lavender: "e6e6fa",
  1822. lavenderblush: "fff0f5",
  1823. lawngreen: "7cfc00",
  1824. lemonchiffon: "fffacd",
  1825. lightblue: "add8e6",
  1826. lightcoral: "f08080",
  1827. lightcyan: "e0ffff",
  1828. lightgoldenrodyellow: "fafad2",
  1829. lightgrey: "d3d3d3",
  1830. lightgreen: "90ee90",
  1831. lightpink: "ffb6c1",
  1832. lightsalmon: "ffa07a",
  1833. lightseagreen: "20b2aa",
  1834. lightskyblue: "87cefa",
  1835. lightslateblue: "8470ff",
  1836. lightslategray: "778899",
  1837. lightsteelblue: "b0c4de",
  1838. lightyellow: "ffffe0",
  1839. lime: "00ff00",
  1840. limegreen: "32cd32",
  1841. linen: "faf0e6",
  1842. magenta: "ff00ff",
  1843. maroon: "800000",
  1844. mediumaquamarine: "66cdaa",
  1845. mediumblue: "0000cd",
  1846. mediumorchid: "ba55d3",
  1847. mediumpurple: "9370d8",
  1848. mediumseagreen: "3cb371",
  1849. mediumslateblue: "7b68ee",
  1850. mediumspringgreen: "00fa9a",
  1851. mediumturquoise: "48d1cc",
  1852. mediumvioletred: "c71585",
  1853. midnightblue: "191970",
  1854. mintcream: "f5fffa",
  1855. mistyrose: "ffe4e1",
  1856. moccasin: "ffe4b5",
  1857. navajowhite: "ffdead",
  1858. navy: "000080",
  1859. oldlace: "fdf5e6",
  1860. olive: "808000",
  1861. olivedrab: "6b8e23",
  1862. orange: "ffa500",
  1863. orangered: "ff4500",
  1864. orchid: "da70d6",
  1865. palegoldenrod: "eee8aa",
  1866. palegreen: "98fb98",
  1867. paleturquoise: "afeeee",
  1868. palevioletred: "d87093",
  1869. papayawhip: "ffefd5",
  1870. peachpuff: "ffdab9",
  1871. peru: "cd853f",
  1872. pink: "ffc0cb",
  1873. plum: "dda0dd",
  1874. powderblue: "b0e0e6",
  1875. purple: "800080",
  1876. rebeccapurple: "663399",
  1877. red: "ff0000",
  1878. rosybrown: "bc8f8f",
  1879. royalblue: "4169e1",
  1880. saddlebrown: "8b4513",
  1881. salmon: "fa8072",
  1882. sandybrown: "f4a460",
  1883. seagreen: "2e8b57",
  1884. seashell: "fff5ee",
  1885. sienna: "a0522d",
  1886. silver: "c0c0c0",
  1887. skyblue: "87ceeb",
  1888. slateblue: "6a5acd",
  1889. slategray: "708090",
  1890. snow: "fffafa",
  1891. springgreen: "00ff7f",
  1892. steelblue: "4682b4",
  1893. tan: "d2b48c",
  1894. teal: "008080",
  1895. thistle: "d8bfd8",
  1896. tomato: "ff6347",
  1897. turquoise: "40e0d0",
  1898. violet: "ee82ee",
  1899. violetred: "d02090",
  1900. wheat: "f5deb3",
  1901. white: "ffffff",
  1902. whitesmoke: "f5f5f5",
  1903. yellow: "ffff00",
  1904. yellowgreen: "9acd32"
  1905. };
  1906. t = e[t] || t;
  1907. for (var r = [{
  1908. re: /^rgba\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3}),\s*((?:\d?\.)?\d)\)$/,
  1909. example: ["rgba(123, 234, 45, 0.8)", "rgba(255,234,245,1.0)"],
  1910. process: function (t) {
  1911. return [parseInt(t[1]), parseInt(t[2]), parseInt(t[3]), parseFloat(t[4])]
  1912. }
  1913. }, {
  1914. re: /^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,
  1915. example: ["rgb(123, 234, 45)", "rgb(255,234,245)"],
  1916. process: function (t) {
  1917. return [parseInt(t[1]), parseInt(t[2]), parseInt(t[3])]
  1918. }
  1919. }, {
  1920. re: /^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,
  1921. example: ["#00ff00", "336699"],
  1922. process: function (t) {
  1923. return [parseInt(t[1], 16), parseInt(t[2], 16), parseInt(t[3], 16)]
  1924. }
  1925. }, {
  1926. re: /^([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/, example: ["#fb0", "f0f"], process: function (t) {
  1927. return [parseInt(t[1] + t[1], 16), parseInt(t[2] + t[2], 16), parseInt(t[3] + t[3], 16)]
  1928. }
  1929. }], n = 0; n < r.length; n++) {
  1930. var i = r[n].re, a = r[n].process, o = i.exec(t);
  1931. if (o) {
  1932. var u = a(o);
  1933. this.r = u[0], this.g = u[1], this.b = u[2], u.length > 3 && (this.alpha = u[3]), this.ok = !0
  1934. }
  1935. }
  1936. this.r = this.r < 0 || isNaN(this.r) ? 0 : this.r > 255 ? 255 : this.r, this.g = this.g < 0 || isNaN(this.g) ? 0 : this.g > 255 ? 255 : this.g, this.b = this.b < 0 || isNaN(this.b) ? 0 : this.b > 255 ? 255 : this.b, this.alpha = this.alpha < 0 ? 0 : this.alpha > 1 || isNaN(this.alpha) ? 1 : this.alpha, this.toRGB = function () {
  1937. return "rgb(" + this.r + ", " + this.g + ", " + this.b + ")"
  1938. }, this.toRGBA = function () {
  1939. return "rgba(" + this.r + ", " + this.g + ", " + this.b + ", " + this.alpha + ")"
  1940. }, this.toHex = function () {
  1941. var t = this.r.toString(16), e = this.g.toString(16), r = this.b.toString(16);
  1942. return 1 == t.length && (t = "0" + t), 1 == e.length && (e = "0" + e), 1 == r.length && (r = "0" + r), "#" + t + e + r
  1943. }, this.getHelpXML = function () {
  1944. for (var t = new Array, n = 0; n < r.length; n++) for (var i = r[n].example, a = 0; a < i.length; a++) t[t.length] = i[a];
  1945. for (var o in e) t[t.length] = o;
  1946. var u = document.createElement("ul");
  1947. u.setAttribute("id", "rgbcolor-examples");
  1948. for (n = 0; n < t.length; n++) try {
  1949. var s = document.createElement("li"), c = new RGBColor(t[n]), l = document.createElement("div");
  1950. l.style.cssText = "margin: 3px; border: 1px solid black; background:" + c.toHex() + "; color:" + c.toHex(), l.appendChild(document.createTextNode("test"));
  1951. var f = document.createTextNode(" " + t[n] + " -> " + c.toRGB() + " -> " + c.toHex());
  1952. s.appendChild(l), s.appendChild(f), u.appendChild(s)
  1953. } catch (t) {
  1954. }
  1955. return u
  1956. }
  1957. }, ts = function () {
  1958. function t(e, r, n) {
  1959. jo(this, t), this.document = e, this.name = r, this.value = n, this.isNormalizedColor = !1
  1960. }
  1961. return Fo(t, [{
  1962. key: "split", value: function () {
  1963. var e, r, n = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : " ", i = this.document,
  1964. a = this.name;
  1965. return ee(e = Ku(r = re(this.getString())).call(r).split(n)).call(e, (function (e) {
  1966. return new t(i, a, e)
  1967. }))
  1968. }
  1969. }, {
  1970. key: "hasValue", value: function (t) {
  1971. var e = this.value;
  1972. return null !== e && "" !== e && (t || 0 !== e) && void 0 !== e
  1973. }
  1974. }, {
  1975. key: "isString", value: function (t) {
  1976. var e = this.value, r = "string" == typeof e;
  1977. return r && t ? t.test(e) : r
  1978. }
  1979. }, {
  1980. key: "isUrlDefinition", value: function () {
  1981. return this.isString(/^url\(/)
  1982. }
  1983. }, {
  1984. key: "isPixels", value: function () {
  1985. if (!this.hasValue()) return !1;
  1986. var t = this.getString();
  1987. switch (!0) {
  1988. case/px$/.test(t):
  1989. case/^[0-9]+$/.test(t):
  1990. return !0;
  1991. default:
  1992. return !1
  1993. }
  1994. }
  1995. }, {
  1996. key: "setValue", value: function (t) {
  1997. return this.value = t, this
  1998. }
  1999. }, {
  2000. key: "getValue", value: function (t) {
  2001. return void 0 === t || this.hasValue() ? this.value : t
  2002. }
  2003. }, {
  2004. key: "getNumber", value: function (t) {
  2005. if (!this.hasValue()) return void 0 === t ? 0 : Ct(t);
  2006. var e = this.value, r = Ct(e);
  2007. return this.isString(/%$/) && (r /= 100), r
  2008. }
  2009. }, {
  2010. key: "getString", value: function (t) {
  2011. return void 0 === t || this.hasValue() ? void 0 === this.value ? "" : String(this.value) : String(t)
  2012. }
  2013. }, {
  2014. key: "getColor", value: function (t) {
  2015. var e = this.getString(t);
  2016. return this.isNormalizedColor || (this.isNormalizedColor = !0, e = ce(e), this.value = e), e
  2017. }
  2018. }, {
  2019. key: "getDpi", value: function () {
  2020. return 96
  2021. }
  2022. }, {
  2023. key: "getRem", value: function () {
  2024. return this.document.rootEmSize
  2025. }
  2026. }, {
  2027. key: "getEm", value: function () {
  2028. return this.document.emSize
  2029. }
  2030. }, {
  2031. key: "getUnits", value: function () {
  2032. return this.getString().replace(/[0-9\.\-]/g, "")
  2033. }
  2034. }, {
  2035. key: "getPixels", value: function (t) {
  2036. var e = arguments.length > 1 && void 0 !== arguments[1] && arguments[1];
  2037. if (!this.hasValue()) return 0;
  2038. var r = "boolean" == typeof t ? [void 0, t] : [t], n = ci(r, 2), i = n[0], a = n[1],
  2039. o = this.document.screen.viewPort;
  2040. switch (!0) {
  2041. case this.isString(/vmin$/):
  2042. return this.getNumber() / 100 * Math.min(o.computeSize("x"), o.computeSize("y"));
  2043. case this.isString(/vmax$/):
  2044. return this.getNumber() / 100 * Math.max(o.computeSize("x"), o.computeSize("y"));
  2045. case this.isString(/vw$/):
  2046. return this.getNumber() / 100 * o.computeSize("x");
  2047. case this.isString(/vh$/):
  2048. return this.getNumber() / 100 * o.computeSize("y");
  2049. case this.isString(/rem$/):
  2050. return this.getNumber() * this.getRem();
  2051. case this.isString(/em$/):
  2052. return this.getNumber() * this.getEm();
  2053. case this.isString(/ex$/):
  2054. return this.getNumber() * this.getEm() / 2;
  2055. case this.isString(/px$/):
  2056. return this.getNumber();
  2057. case this.isString(/pt$/):
  2058. return this.getNumber() * this.getDpi() * (1 / 72);
  2059. case this.isString(/pc$/):
  2060. return 15 * this.getNumber();
  2061. case this.isString(/cm$/):
  2062. return this.getNumber() * this.getDpi() / 2.54;
  2063. case this.isString(/mm$/):
  2064. return this.getNumber() * this.getDpi() / 25.4;
  2065. case this.isString(/in$/):
  2066. return this.getNumber() * this.getDpi();
  2067. case this.isString(/%$/) && a:
  2068. return this.getNumber() * this.getEm();
  2069. case this.isString(/%$/):
  2070. return this.getNumber() * o.computeSize(i);
  2071. default:
  2072. var u = this.getNumber();
  2073. return e && u < 1 ? u * o.computeSize(i) : u
  2074. }
  2075. }
  2076. }, {
  2077. key: "getMilliseconds", value: function () {
  2078. return this.hasValue() ? this.isString(/ms$/) ? this.getNumber() : 1e3 * this.getNumber() : 0
  2079. }
  2080. }, {
  2081. key: "getRadians", value: function () {
  2082. if (!this.hasValue()) return 0;
  2083. switch (!0) {
  2084. case this.isString(/deg$/):
  2085. return this.getNumber() * (Math.PI / 180);
  2086. case this.isString(/grad$/):
  2087. return this.getNumber() * (Math.PI / 200);
  2088. case this.isString(/rad$/):
  2089. return this.getNumber();
  2090. default:
  2091. return this.getNumber() * (Math.PI / 180)
  2092. }
  2093. }
  2094. }, {
  2095. key: "getDefinition", value: function () {
  2096. var t = this.getString(), e = t.match(/#([^\)'"]+)/);
  2097. return e && (e = e[1]), e || (e = t), this.document.definitions[e]
  2098. }
  2099. }, {
  2100. key: "getFillStyleDefinition", value: function (t, e) {
  2101. var r = this.getDefinition();
  2102. if (!r) return null;
  2103. if ("function" == typeof r.createGradient) return r.createGradient(this.document.ctx, t, e);
  2104. if ("function" == typeof r.createPattern) {
  2105. if (r.getHrefAttribute().hasValue()) {
  2106. var n = r.getAttribute("patternTransform");
  2107. r = r.getHrefAttribute().getDefinition(), n.hasValue() && r.getAttribute("patternTransform", !0).setValue(n.value)
  2108. }
  2109. return r.createPattern(this.document.ctx, t, e)
  2110. }
  2111. return null
  2112. }
  2113. }, {
  2114. key: "getTextBaseline", value: function () {
  2115. return this.hasValue() ? t.textBaselineMapping[this.getString()] : null
  2116. }
  2117. }, {
  2118. key: "addOpacity", value: function (e) {
  2119. for (var r = this.getColor(), n = r.length, i = 0, a = 0; a < n && ("," === r[a] && i++, 3 !== i); a++) ;
  2120. if (e.hasValue() && this.isString() && 3 !== i) {
  2121. var o = new Ju(r);
  2122. o.ok && (o.alpha = e.getNumber(), r = o.toRGBA())
  2123. }
  2124. return new t(this.document, this.name, r)
  2125. }
  2126. }], [{
  2127. key: "empty", value: function (e) {
  2128. return new t(e, "EMPTY", "")
  2129. }
  2130. }]), t
  2131. }();
  2132. ts.textBaselineMapping = {
  2133. baseline: "alphabetic",
  2134. "before-edge": "top",
  2135. "text-before-edge": "top",
  2136. middle: "middle",
  2137. central: "middle",
  2138. "after-edge": "bottom",
  2139. "text-after-edge": "bottom",
  2140. ideographic: "ideographic",
  2141. alphabetic: "alphabetic",
  2142. hanging: "hanging",
  2143. mathematical: "alphabetic"
  2144. };
  2145. var es = function () {
  2146. function t() {
  2147. jo(this, t), this.viewPorts = []
  2148. }
  2149. return Fo(t, [{
  2150. key: "clear", value: function () {
  2151. this.viewPorts = []
  2152. }
  2153. }, {
  2154. key: "setCurrent", value: function (t, e) {
  2155. this.viewPorts.push({width: t, height: e})
  2156. }
  2157. }, {
  2158. key: "removeCurrent", value: function () {
  2159. this.viewPorts.pop()
  2160. }
  2161. }, {
  2162. key: "getCurrent", value: function () {
  2163. var t = this.viewPorts;
  2164. return t[t.length - 1]
  2165. }
  2166. }, {
  2167. key: "computeSize", value: function (t) {
  2168. return "number" == typeof t ? t : "x" === t ? this.width : "y" === t ? this.height : Math.sqrt(Math.pow(this.width, 2) + Math.pow(this.height, 2)) / Math.sqrt(2)
  2169. }
  2170. }, {
  2171. key: "width", get: function () {
  2172. return this.getCurrent().width
  2173. }
  2174. }, {
  2175. key: "height", get: function () {
  2176. return this.getCurrent().height
  2177. }
  2178. }]), t
  2179. }(), rs = function () {
  2180. function t(e, r) {
  2181. jo(this, t), this.x = e, this.y = r
  2182. }
  2183. return Fo(t, [{
  2184. key: "angleTo", value: function (t) {
  2185. return Math.atan2(t.y - this.y, t.x - this.x)
  2186. }
  2187. }, {
  2188. key: "applyTransform", value: function (t) {
  2189. var e = this.x, r = this.y, n = e * t[0] + r * t[2] + t[4], i = e * t[1] + r * t[3] + t[5];
  2190. this.x = n, this.y = i
  2191. }
  2192. }], [{
  2193. key: "parse", value: function (e) {
  2194. var r = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : 0, n = ae(e), i = ci(n, 2),
  2195. a = i[0], o = void 0 === a ? r : a, u = i[1], s = void 0 === u ? r : u;
  2196. return new t(o, s)
  2197. }
  2198. }, {
  2199. key: "parseScale", value: function (e) {
  2200. var r = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : 1, n = ae(e), i = ci(n, 2),
  2201. a = i[0], o = void 0 === a ? r : a, u = i[1], s = void 0 === u ? o : u;
  2202. return new t(o, s)
  2203. }
  2204. }, {
  2205. key: "parsePath", value: function (e) {
  2206. for (var r = ae(e), n = r.length, i = [], a = 0; a < n; a += 2) i.push(new t(r[a], r[a + 1]));
  2207. return i
  2208. }
  2209. }]), t
  2210. }(), ns = function () {
  2211. function t(e) {
  2212. var r, n;
  2213. jo(this, t), this.screen = e, this.working = !1, this.events = [], this.eventElements = [], this.onClick = fu(r = this.onClick).call(r, this), this.onMouseMove = fu(n = this.onMouseMove).call(n, this)
  2214. }
  2215. return Fo(t, [{
  2216. key: "isWorking", value: function () {
  2217. return this.working
  2218. }
  2219. }, {
  2220. key: "start", value: function () {
  2221. if (!this.working) {
  2222. var t = this.screen, e = this.onClick, r = this.onMouseMove, n = t.ctx.canvas;
  2223. n.onclick = e, n.onmousemove = r, this.working = !0
  2224. }
  2225. }
  2226. }, {
  2227. key: "stop", value: function () {
  2228. if (this.working) {
  2229. var t = this.screen.ctx.canvas;
  2230. this.working = !1, t.onclick = null, t.onmousemove = null
  2231. }
  2232. }
  2233. }, {
  2234. key: "hasEvents", value: function () {
  2235. return this.working && this.events.length > 0
  2236. }
  2237. }, {
  2238. key: "runEvents", value: function () {
  2239. if (this.working) {
  2240. var t = this.screen, e = this.events, r = this.eventElements, n = t.ctx.canvas.style;
  2241. n && (n.cursor = ""), Hi(e).call(e, (function (t, e) {
  2242. for (var n = t.run, i = r[e]; i;) n(i), i = i.parent
  2243. })), this.events = [], this.eventElements = []
  2244. }
  2245. }
  2246. }, {
  2247. key: "checkPath", value: function (t, e) {
  2248. if (this.working && e) {
  2249. var r = this.events, n = this.eventElements;
  2250. Hi(r).call(r, (function (r, i) {
  2251. var a = r.x, o = r.y;
  2252. !n[i] && e.isPointInPath && e.isPointInPath(a, o) && (n[i] = t)
  2253. }))
  2254. }
  2255. }
  2256. }, {
  2257. key: "checkBoundingBox", value: function (t, e) {
  2258. if (this.working && e) {
  2259. var r = this.events, n = this.eventElements;
  2260. Hi(r).call(r, (function (r, i) {
  2261. var a = r.x, o = r.y;
  2262. !n[i] && e.isPointInBox(a, o) && (n[i] = t)
  2263. }))
  2264. }
  2265. }
  2266. }, {
  2267. key: "mapXY", value: function (t, e) {
  2268. for (var r = this.screen, n = r.window, i = r.ctx, a = new rs(t, e), o = i.canvas; o;) a.x -= o.offsetLeft, a.y -= o.offsetTop, o = o.offsetParent;
  2269. return n.scrollX && (a.x += n.scrollX), n.scrollY && (a.y += n.scrollY), a
  2270. }
  2271. }, {
  2272. key: "onClick", value: function (t) {
  2273. var e = this.mapXY((t || event).clientX, (t || event).clientY), r = e.x, n = e.y;
  2274. this.events.push({
  2275. type: "onclick", x: r, y: n, run: function (t) {
  2276. t.onClick && t.onClick()
  2277. }
  2278. })
  2279. }
  2280. }, {
  2281. key: "onMouseMove", value: function (t) {
  2282. var e = this.mapXY((t || event).clientX, (t || event).clientY), r = e.x, n = e.y;
  2283. this.events.push({
  2284. type: "onmousemove", x: r, y: n, run: function (t) {
  2285. t.onMouseMove && t.onMouseMove()
  2286. }
  2287. })
  2288. }
  2289. }]), t
  2290. }(), is = "undefined" != typeof window ? window : null,
  2291. as = "undefined" != typeof fetch ? fu(fetch).call(fetch, void 0) : null, os = function () {
  2292. function t(e) {
  2293. var r = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {}, n = r.fetch,
  2294. i = void 0 === n ? as : n, a = r.window, o = void 0 === a ? is : a;
  2295. jo(this, t), this.ctx = e, this.FRAMERATE = 30, this.MAX_VIRTUAL_PIXELS = 3e4, this.CLIENT_WIDTH = 800, this.CLIENT_HEIGHT = 600, this.viewPort = new es, this.mouse = new ns(this), this.animations = [], this.waits = [], this.frameDuration = 0, this.isReadyLock = !1, this.isFirstRender = !0, this.intervalId = null, this.window = o, this.fetch = i
  2296. }
  2297. return Fo(t, [{
  2298. key: "wait", value: function (t) {
  2299. this.waits.push(t)
  2300. }
  2301. }, {
  2302. key: "ready", value: function () {
  2303. return this.readyPromise ? this.readyPromise : iu.resolve()
  2304. }
  2305. }, {
  2306. key: "isReady", value: function () {
  2307. var t;
  2308. if (this.isReadyLock) return !0;
  2309. var e = nu(t = this.waits).call(t, (function (t) {
  2310. return t()
  2311. }));
  2312. return e && (this.waits = [], this.resolveReady && this.resolveReady()), this.isReadyLock = e, e
  2313. }
  2314. }, {
  2315. key: "setDefaults", value: function (t) {
  2316. t.strokeStyle = "rgba(0,0,0,0)", t.lineCap = "butt", t.lineJoin = "miter", t.miterLimit = 4
  2317. }
  2318. }, {
  2319. key: "setViewBox", value: function (t) {
  2320. var e = t.document, r = t.ctx, n = t.aspectRatio, i = t.width, a = t.desiredWidth, o = t.height,
  2321. u = t.desiredHeight, s = t.minX, c = void 0 === s ? 0 : s, l = t.minY, f = void 0 === l ? 0 : l,
  2322. h = t.refX, p = t.refY, y = t.clip, v = void 0 !== y && y, g = t.clipX, d = void 0 === g ? 0 : g,
  2323. m = t.clipY, x = void 0 === m ? 0 : m, b = re(n).replace(/^defer\s/, "").split(" "), w = ci(b, 2),
  2324. S = w[0] || "xMidYMid", A = w[1] || "meet", k = i / a, T = o / u, O = Math.min(k, T),
  2325. P = Math.max(k, T), E = a, C = u;
  2326. "meet" === A && (E *= O, C *= O), "slice" === A && (E *= P, C *= P);
  2327. var M = new ts(e, "refX", h), N = new ts(e, "refY", p), R = M.hasValue() && N.hasValue();
  2328. if (R && r.translate(-O * M.getPixels("x"), -O * N.getPixels("y")), v) {
  2329. var _ = O * d, D = O * x;
  2330. r.beginPath(), r.moveTo(_, D), r.lineTo(i, D), r.lineTo(i, o), r.lineTo(_, o), r.closePath(), r.clip()
  2331. }
  2332. if (!R) {
  2333. var V = "meet" === A && O === T, L = "slice" === A && P === T, I = "meet" === A && O === k,
  2334. j = "slice" === A && P === k;
  2335. /^xMid/.test(S) && (V || L) && r.translate(i / 2 - E / 2, 0), /YMid$/.test(S) && (I || j) && r.translate(0, o / 2 - C / 2), /^xMax/.test(S) && (V || L) && r.translate(i - E, 0), /YMax$/.test(S) && (I || j) && r.translate(0, o - C)
  2336. }
  2337. switch (!0) {
  2338. case"none" === S:
  2339. r.scale(k, T);
  2340. break;
  2341. case"meet" === A:
  2342. r.scale(O, O);
  2343. break;
  2344. case"slice" === A:
  2345. r.scale(P, P)
  2346. }
  2347. r.translate(-c, -f)
  2348. }
  2349. }, {
  2350. key: "start", value: function (t) {
  2351. var e = this, r = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {},
  2352. n = r.enableRedraw, i = void 0 !== n && n, a = r.ignoreMouse, o = void 0 !== a && a,
  2353. u = r.ignoreAnimation, s = void 0 !== u && u, c = r.ignoreDimensions, l = void 0 !== c && c,
  2354. f = r.ignoreClear, h = void 0 !== f && f, p = r.forceRedraw, y = r.scaleWidth, v = r.scaleHeight,
  2355. g = r.offsetX, d = r.offsetY, m = this.FRAMERATE, x = this.mouse, b = 1e3 / m;
  2356. if (this.frameDuration = b, this.readyPromise = new iu((function (t) {
  2357. e.resolveReady = t
  2358. })), this.isReady() && this.render(t, l, h, y, v, g, d), i) {
  2359. var w = Zo(), S = w, A = 0, k = function r() {
  2360. w = Zo(), (A = w - S) >= b && (S = w - A % b, e.shouldUpdate(s, p) && (e.render(t, l, h, y, v, g, d), x.runEvents())), e.intervalId = Gu(r)
  2361. };
  2362. o || x.start(), this.intervalId = Gu(k)
  2363. }
  2364. }
  2365. }, {
  2366. key: "stop", value: function () {
  2367. this.intervalId && (Gu.cancel(this.intervalId), this.intervalId = null), this.mouse.stop()
  2368. }
  2369. }, {
  2370. key: "shouldUpdate", value: function (t, e) {
  2371. if (!t) {
  2372. var r, n = this.frameDuration, i = $o(r = this.animations).call(r, (function (t, e) {
  2373. return e.update(n) || t
  2374. }), !1);
  2375. if (i) return !0
  2376. }
  2377. return !("function" != typeof e || !e()) || (!(this.isReadyLock || !this.isReady()) || !!this.mouse.hasEvents())
  2378. }
  2379. }, {
  2380. key: "render", value: function (t, e, r, n, i, a, o) {
  2381. var u = this.CLIENT_WIDTH, s = this.CLIENT_HEIGHT, c = this.viewPort, l = this.ctx,
  2382. f = this.isFirstRender, h = l.canvas;
  2383. c.clear(), h.width && h.height ? c.setCurrent(h.width, h.height) : c.setCurrent(u, s);
  2384. var p = t.getStyle("width"), y = t.getStyle("height");
  2385. !e && (f || "number" != typeof n && "number" != typeof i) && (p.hasValue() && (h.width = p.getPixels("x"), h.style && (h.style.width = "".concat(h.width, "px"))), y.hasValue() && (h.height = y.getPixels("y"), h.style && (h.style.height = "".concat(h.height, "px"))));
  2386. var v = h.clientWidth || h.width, g = h.clientHeight || h.height;
  2387. if (e && p.hasValue() && y.hasValue() && (v = p.getPixels("x"), g = y.getPixels("y")), c.setCurrent(v, g), "number" == typeof a && t.getAttribute("x", !0).setValue(a), "number" == typeof o && t.getAttribute("y", !0).setValue(o), "number" == typeof n || "number" == typeof i) {
  2388. var d, m, x = ae(t.getAttribute("viewBox").getString()), b = 0, w = 0;
  2389. if ("number" == typeof n) {
  2390. var S = t.getStyle("width");
  2391. S.hasValue() ? b = S.getPixels("x") / n : isNaN(x[2]) || (b = x[2] / n)
  2392. }
  2393. if ("number" == typeof i) {
  2394. var A = t.getStyle("height");
  2395. A.hasValue() ? w = A.getPixels("y") / i : isNaN(x[3]) || (w = x[3] / i)
  2396. }
  2397. b || (b = w), w || (w = b), t.getAttribute("width", !0).setValue(n), t.getAttribute("height", !0).setValue(i);
  2398. var k = t.getStyle("transform", !0, !0);
  2399. k.setValue(Ho(d = Ho(m = "".concat(k.getString(), " scale(")).call(m, 1 / b, ", ")).call(d, 1 / w, ")"))
  2400. }
  2401. r || l.clearRect(0, 0, v, g), t.render(l), f && (this.isFirstRender = !1)
  2402. }
  2403. }]), t
  2404. }();
  2405. os.defaultWindow = is, os.defaultFetch = as;
  2406. var us = os.defaultFetch, ss = "undefined" != typeof DOMParser ? DOMParser : null, cs = function () {
  2407. function t() {
  2408. var e = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, r = e.fetch,
  2409. n = void 0 === r ? us : r, i = e.DOMParser, a = void 0 === i ? ss : i;
  2410. jo(this, t), this.fetch = n, this.DOMParser = a
  2411. }
  2412. var e, r;
  2413. return Fo(t, [{
  2414. key: "parse", value: (r = Vo(na.mark((function t(e) {
  2415. return na.wrap((function (t) {
  2416. for (; ;) switch (t.prev = t.next) {
  2417. case 0:
  2418. if (!/^</.test(e)) {
  2419. t.next = 2;
  2420. break
  2421. }
  2422. return t.abrupt("return", this.parseFromString(e));
  2423. case 2:
  2424. return t.abrupt("return", this.load(e));
  2425. case 3:
  2426. case"end":
  2427. return t.stop()
  2428. }
  2429. }), t, this)
  2430. }))), function (t) {
  2431. return r.apply(this, arguments)
  2432. })
  2433. }, {
  2434. key: "parseFromString", value: function (t) {
  2435. var e = new this.DOMParser;
  2436. try {
  2437. return this.checkDocument(e.parseFromString(t, "image/svg+xml"))
  2438. } catch (r) {
  2439. return this.checkDocument(e.parseFromString(t, "text/xml"))
  2440. }
  2441. }
  2442. }, {
  2443. key: "checkDocument", value: function (t) {
  2444. var e = t.getElementsByTagName("parsererror")[0];
  2445. if (e) throw new Error(e.textContent);
  2446. return t
  2447. }
  2448. }, {
  2449. key: "load", value: (e = Vo(na.mark((function t(e) {
  2450. var r, n;
  2451. return na.wrap((function (t) {
  2452. for (; ;) switch (t.prev = t.next) {
  2453. case 0:
  2454. return t.next = 2, this.fetch(e);
  2455. case 2:
  2456. return r = t.sent, t.next = 5, r.text();
  2457. case 5:
  2458. return n = t.sent, t.abrupt("return", this.parseFromString(n));
  2459. case 7:
  2460. case"end":
  2461. return t.stop()
  2462. }
  2463. }), t, this)
  2464. }))), function (t) {
  2465. return e.apply(this, arguments)
  2466. })
  2467. }]), t
  2468. }(), ls = jt("Reflect", "construct"), fs = a((function () {
  2469. function t() {
  2470. }
  2471. return !(ls((function () {
  2472. }), [], t) instanceof t)
  2473. })), hs = !a((function () {
  2474. ls((function () {
  2475. }))
  2476. })), ps = fs || hs;
  2477. H({target: "Reflect", stat: !0, forced: ps, sham: ps}, {
  2478. construct: function (t, e) {
  2479. V(t), I(e);
  2480. var r = arguments.length < 3 ? t : V(arguments[2]);
  2481. if (hs && !fs) return ls(t, e, r);
  2482. if (t == r) {
  2483. switch (e.length) {
  2484. case 0:
  2485. return new t;
  2486. case 1:
  2487. return new t(e[0]);
  2488. case 2:
  2489. return new t(e[0], e[1]);
  2490. case 3:
  2491. return new t(e[0], e[1], e[2]);
  2492. case 4:
  2493. return new t(e[0], e[1], e[2], e[3])
  2494. }
  2495. var n = [null];
  2496. return n.push.apply(n, e), new (su.apply(t, n))
  2497. }
  2498. var i = r.prototype, a = rr(d(i) ? i : Object.prototype), o = Function.apply.call(t, a, e);
  2499. return d(o) ? o : a
  2500. }
  2501. });
  2502. var ys = D.Reflect.construct;
  2503. H({target: "Object", stat: !0, sham: !o}, {create: rr});
  2504. var vs = D.Object, gs = function (t, e) {
  2505. return vs.create(t, e)
  2506. };
  2507. H({target: "Object", stat: !0}, {setPrototypeOf: yr});
  2508. var ds = D.Object.setPrototypeOf, ms = r((function (t) {
  2509. function e(r, n) {
  2510. return t.exports = e = ds || function (t, e) {
  2511. return t.__proto__ = e, t
  2512. }, e(r, n)
  2513. }
  2514. t.exports = e
  2515. }));
  2516. var xs = function (t, e) {
  2517. if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function");
  2518. t.prototype = gs(e && e.prototype, {constructor: {value: t, writable: !0, configurable: !0}}), e && ms(t, e)
  2519. }, bs = en.f("iterator"), ws = r((function (t) {
  2520. function e(r) {
  2521. return t.exports = e = "function" == typeof Ln && "symbol" == typeof bs ? function (t) {
  2522. return typeof t
  2523. } : function (t) {
  2524. return t && "function" == typeof Ln && t.constructor === Ln && t !== Ln.prototype ? "symbol" : typeof t
  2525. }, e(r)
  2526. }
  2527. t.exports = e
  2528. }));
  2529. var Ss = function (t) {
  2530. if (void 0 === t) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
  2531. return t
  2532. };
  2533. var As = function (t, e) {
  2534. return !e || "object" !== ws(e) && "function" != typeof e ? Ss(t) : e
  2535. }, ks = a((function () {
  2536. Ie(1)
  2537. }));
  2538. H({target: "Object", stat: !0, forced: ks, sham: !De}, {
  2539. getPrototypeOf: function (t) {
  2540. return Ie(Mt(t))
  2541. }
  2542. });
  2543. var Ts = D.Object.getPrototypeOf, Os = r((function (t) {
  2544. function e(r) {
  2545. return t.exports = e = ds ? Ts : function (t) {
  2546. return t.__proto__ || Ts(t)
  2547. }, e(r)
  2548. }
  2549. t.exports = e
  2550. }));
  2551. var Ps = function (t) {
  2552. if (fe(t)) return oi(t)
  2553. };
  2554. var Es = function (t) {
  2555. if (void 0 !== Ln && Fr(Object(t))) return $n(t)
  2556. };
  2557. var Cs = function () {
  2558. throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")
  2559. };
  2560. var Ms = function (t) {
  2561. return Ps(t) || Es(t) || ui(t) || Cs()
  2562. }, Ns = Lt.some, Rs = Vi("some"), _s = Wt("some");
  2563. H({target: "Array", proto: !0, forced: !Rs || !_s}, {
  2564. some: function (t) {
  2565. return Ns(this, t, arguments.length > 1 ? arguments[1] : void 0)
  2566. }
  2567. });
  2568. var Ds = yt("Array").some, Vs = Array.prototype, Ls = function (t) {
  2569. var e = t.some;
  2570. return t === Vs || t instanceof Array && e === Vs.some ? Ds : e
  2571. }, Is = Ye.includes, js = Wt("indexOf", {ACCESSORS: !0, 1: 0});
  2572. H({target: "Array", proto: !0, forced: !js}, {
  2573. includes: function (t) {
  2574. return Is(this, t, arguments.length > 1 ? arguments[1] : void 0)
  2575. }
  2576. });
  2577. var zs = yt("Array").includes;
  2578. H({target: "String", proto: !0, forced: !lt("includes")}, {
  2579. includes: function (t) {
  2580. return !!~String(v(this)).indexOf(st(t), arguments.length > 1 ? arguments[1] : void 0)
  2581. }
  2582. });
  2583. var Fs = yt("String").includes, Bs = Array.prototype, Us = String.prototype, Hs = function (t) {
  2584. var e = t.includes;
  2585. return t === Bs || t instanceof Array && e === Bs.includes ? zs : "string" == typeof t || t === Us || t instanceof String && e === Us.includes ? Fs : e
  2586. }, Xs = Wn, Ys = function () {
  2587. function t(e, r) {
  2588. jo(this, t), this.type = "translate", this.point = null, this.point = rs.parse(r)
  2589. }
  2590. return Fo(t, [{
  2591. key: "apply", value: function (t) {
  2592. var e = this.point, r = e.x, n = e.y;
  2593. t.translate(r || 0, n || 0)
  2594. }
  2595. }, {
  2596. key: "unapply", value: function (t) {
  2597. var e = this.point, r = e.x, n = e.y;
  2598. t.translate(-1 * r || 0, -1 * n || 0)
  2599. }
  2600. }, {
  2601. key: "applyToPoint", value: function (t) {
  2602. var e = this.point, r = e.x, n = e.y;
  2603. t.applyTransform([1, 0, 0, 1, r || 0, n || 0])
  2604. }
  2605. }]), t
  2606. }(), qs = function () {
  2607. function t(e, r, n) {
  2608. jo(this, t), this.type = "rotate", this.angle = null, this.originX = null, this.originY = null, this.cx = 0, this.cy = 0;
  2609. var i = ae(r);
  2610. this.angle = new ts(e, "angle", i[0]), this.originX = n[0], this.originY = n[1], this.cx = i[1] || 0, this.cy = i[2] || 0
  2611. }
  2612. return Fo(t, [{
  2613. key: "apply", value: function (t) {
  2614. var e = this.cx, r = this.cy, n = this.originX, i = this.originY, a = this.angle,
  2615. o = e + n.getPixels("x"), u = r + i.getPixels("y");
  2616. t.translate(o, u), t.rotate(a.getRadians()), t.translate(-o, -u)
  2617. }
  2618. }, {
  2619. key: "unapply", value: function (t) {
  2620. var e = this.cx, r = this.cy, n = this.angle;
  2621. t.translate(e, r), t.rotate(-1 * n.getRadians()), t.translate(-e, -r)
  2622. }
  2623. }, {
  2624. key: "applyToPoint", value: function (t) {
  2625. var e = this.cx, r = this.cy, n = this.angle.getRadians();
  2626. t.applyTransform([1, 0, 0, 1, e || 0, r || 0]), t.applyTransform([Math.cos(n), Math.sin(n), -Math.sin(n), Math.cos(n), 0, 0]), t.applyTransform([1, 0, 0, 1, -e || 0, -r || 0])
  2627. }
  2628. }]), t
  2629. }(), Gs = function () {
  2630. function t(e, r) {
  2631. jo(this, t), this.type = "scale", this.scale = null;
  2632. var n = rs.parseScale(r);
  2633. 0 !== n.x && 0 !== n.y || (n.x = xi, n.y = xi), this.scale = n
  2634. }
  2635. return Fo(t, [{
  2636. key: "apply", value: function (t) {
  2637. var e = this.scale, r = e.x, n = e.y;
  2638. t.scale(r, n || r)
  2639. }
  2640. }, {
  2641. key: "unapply", value: function (t) {
  2642. var e = this.scale, r = e.x, n = e.y;
  2643. t.scale(1 / r, 1 / n || r)
  2644. }
  2645. }, {
  2646. key: "applyToPoint", value: function (t) {
  2647. var e = this.scale, r = e.x, n = e.y;
  2648. t.applyTransform([r || 0, 0, 0, n || 0, 0, 0])
  2649. }
  2650. }]), t
  2651. }(), Qs = function () {
  2652. function t(e, r) {
  2653. jo(this, t), this.type = "matrix", this.matrix = [], this.matrix = ae(r)
  2654. }
  2655. return Fo(t, [{
  2656. key: "apply", value: function (t) {
  2657. var e = this.matrix;
  2658. t.transform(e[0], e[1], e[2], e[3], e[4], e[5])
  2659. }
  2660. }, {
  2661. key: "unapply", value: function (t) {
  2662. var e = this.matrix, r = e[0], n = e[2], i = e[4], a = e[1], o = e[3], u = e[5],
  2663. s = 1 / (r * (1 * o - 0 * u) - n * (1 * a - 0 * u) + i * (0 * a - 0 * o));
  2664. t.transform(s * (1 * o - 0 * u), s * (0 * u - 1 * a), s * (0 * i - 1 * n), s * (1 * r - 0 * i), s * (n * u - i * o), s * (i * a - r * u))
  2665. }
  2666. }, {
  2667. key: "applyToPoint", value: function (t) {
  2668. t.applyTransform(this.matrix)
  2669. }
  2670. }]), t
  2671. }();
  2672. function Ws(t) {
  2673. var e = function () {
  2674. if ("undefined" == typeof Reflect || !ys) return !1;
  2675. if (ys.sham) return !1;
  2676. if ("function" == typeof Proxy) return !0;
  2677. try {
  2678. return Date.prototype.toString.call(ys(Date, [], (function () {
  2679. }))), !0
  2680. } catch (t) {
  2681. return !1
  2682. }
  2683. }();
  2684. return function () {
  2685. var r, n = Os(t);
  2686. if (e) {
  2687. var i = Os(this).constructor;
  2688. r = ys(n, arguments, i)
  2689. } else r = n.apply(this, arguments);
  2690. return As(this, r)
  2691. }
  2692. }
  2693. var $s = function (t) {
  2694. xs(r, t);
  2695. var e = Ws(r);
  2696. function r(t, n) {
  2697. var i;
  2698. return jo(this, r), (i = e.call(this, t, n)).type = "skew", i.angle = null, i.angle = new ts(t, "angle", n), i
  2699. }
  2700. return r
  2701. }(Qs);
  2702. function Zs(t) {
  2703. var e = function () {
  2704. if ("undefined" == typeof Reflect || !ys) return !1;
  2705. if (ys.sham) return !1;
  2706. if ("function" == typeof Proxy) return !0;
  2707. try {
  2708. return Date.prototype.toString.call(ys(Date, [], (function () {
  2709. }))), !0
  2710. } catch (t) {
  2711. return !1
  2712. }
  2713. }();
  2714. return function () {
  2715. var r, n = Os(t);
  2716. if (e) {
  2717. var i = Os(this).constructor;
  2718. r = ys(n, arguments, i)
  2719. } else r = n.apply(this, arguments);
  2720. return As(this, r)
  2721. }
  2722. }
  2723. var Ks = function (t) {
  2724. xs(r, t);
  2725. var e = Zs(r);
  2726. function r(t, n) {
  2727. var i;
  2728. return jo(this, r), (i = e.call(this, t, n)).type = "skewX", i.matrix = [1, 0, Math.tan(i.angle.getRadians()), 1, 0, 0], i
  2729. }
  2730. return r
  2731. }($s);
  2732. function Js(t) {
  2733. var e = function () {
  2734. if ("undefined" == typeof Reflect || !ys) return !1;
  2735. if (ys.sham) return !1;
  2736. if ("function" == typeof Proxy) return !0;
  2737. try {
  2738. return Date.prototype.toString.call(ys(Date, [], (function () {
  2739. }))), !0
  2740. } catch (t) {
  2741. return !1
  2742. }
  2743. }();
  2744. return function () {
  2745. var r, n = Os(t);
  2746. if (e) {
  2747. var i = Os(this).constructor;
  2748. r = ys(n, arguments, i)
  2749. } else r = n.apply(this, arguments);
  2750. return As(this, r)
  2751. }
  2752. }
  2753. var tc = function (t) {
  2754. xs(r, t);
  2755. var e = Js(r);
  2756. function r(t, n) {
  2757. var i;
  2758. return jo(this, r), (i = e.call(this, t, n)).type = "skewY", i.matrix = [1, Math.tan(i.angle.getRadians()), 0, 1, 0, 0], i
  2759. }
  2760. return r
  2761. }($s);
  2762. var ec = function () {
  2763. function t(e, r, n) {
  2764. var i = this;
  2765. jo(this, t), this.document = e, this.transforms = [];
  2766. var a = function (t) {
  2767. var e;
  2768. return Ku(e = re(t)).call(e).replace(/\)([a-zA-Z])/g, ") $1").replace(/\)(\s?,\s?)/g, ") ").split(/\s(?=[a-z])/)
  2769. }(r);
  2770. Hi(a).call(a, (function (e) {
  2771. if ("none" !== e) {
  2772. var r = function (t) {
  2773. var e = t.split("("), r = ci(e, 2), n = r[0], i = r[1];
  2774. return [Ku(n).call(n), Ku(i).call(i).replace(")", "")]
  2775. }(e), a = ci(r, 2), o = a[0], u = a[1], s = t.transformTypes[o];
  2776. void 0 !== s && i.transforms.push(new s(i.document, u, n))
  2777. }
  2778. }))
  2779. }
  2780. return Fo(t, [{
  2781. key: "apply", value: function (t) {
  2782. for (var e = this.transforms, r = e.length, n = 0; n < r; n++) e[n].apply(t)
  2783. }
  2784. }, {
  2785. key: "unapply", value: function (t) {
  2786. for (var e = this.transforms, r = e.length - 1; r >= 0; r--) e[r].unapply(t)
  2787. }
  2788. }, {
  2789. key: "applyToPoint", value: function (t) {
  2790. for (var e = this.transforms, r = e.length, n = 0; n < r; n++) e[n].applyToPoint(t)
  2791. }
  2792. }], [{
  2793. key: "fromElement", value: function (e, r) {
  2794. var n = r.getStyle("transform", !1, !0), i = r.getStyle("transform-origin", !1, !0).split(),
  2795. a = ci(i, 2), o = a[0], u = a[1], s = [o, void 0 === u ? o : u];
  2796. return n.hasValue() ? new t(e, n.getString(), s) : null
  2797. }
  2798. }]), t
  2799. }();
  2800. ec.transformTypes = {translate: Ys, rotate: qs, scale: Gs, matrix: Qs, skewX: Ks, skewY: tc};
  2801. var rc = function () {
  2802. function t(e, r) {
  2803. var n, i, a = this, o = arguments.length > 2 && void 0 !== arguments[2] && arguments[2];
  2804. if (jo(this, t), this.document = e, this.node = r, this.captureTextNodes = o, this.attributes = {}, this.styles = {}, this.stylesSpecificity = {}, this.animationFrozen = !1, this.animationFrozenValue = "", this.parent = null, this.children = [], r && 1 === r.nodeType) {
  2805. if (Hi(n = Xs(r.attributes)).call(n, (function (t) {
  2806. var r = ue(t.nodeName);
  2807. a.attributes[r] = new ts(e, r, t.value)
  2808. })), this.addStylesFromStyleDefinition(), this.getAttribute("style").hasValue()) {
  2809. var u, s = ee(u = this.getAttribute("style").getString().split(";")).call(u, (function (t) {
  2810. return Ku(t).call(t)
  2811. }));
  2812. Hi(s).call(s, (function (t) {
  2813. var r;
  2814. if (t) {
  2815. var n = ee(r = t.split(":")).call(r, (function (t) {
  2816. return Ku(t).call(t)
  2817. })), i = ci(n, 2), o = i[0], u = i[1];
  2818. a.styles[o] = new ts(e, o, u)
  2819. }
  2820. }))
  2821. }
  2822. var c = e.definitions, l = this.getAttribute("id");
  2823. l.hasValue() && (c[l.getValue()] || (c[l.getValue()] = this)), Hi(i = Xs(r.childNodes)).call(i, (function (t) {
  2824. if (1 === t.nodeType) a.addChild(t); else if (o && (3 === t.nodeType || 4 === t.nodeType)) {
  2825. var r = e.createTextNode(t);
  2826. r.getText().length > 0 && a.addChild(r)
  2827. }
  2828. }))
  2829. }
  2830. }
  2831. return Fo(t, [{
  2832. key: "getAttribute", value: function (t) {
  2833. var e = arguments.length > 1 && void 0 !== arguments[1] && arguments[1], r = this.attributes[t];
  2834. if (!r && e) {
  2835. var n = new ts(this.document, t, "");
  2836. return this.attributes[t] = n, n
  2837. }
  2838. return r || ts.empty(this.document)
  2839. }
  2840. }, {
  2841. key: "getHrefAttribute", value: function () {
  2842. for (var t in this.attributes) if ("href" === t || /:href$/.test(t)) return this.attributes[t];
  2843. return ts.empty(this.document)
  2844. }
  2845. }, {
  2846. key: "getStyle", value: function (t) {
  2847. var e = arguments.length > 1 && void 0 !== arguments[1] && arguments[1],
  2848. r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], n = this.styles[t];
  2849. if (n) return n;
  2850. var i = this.getAttribute(t);
  2851. if (i && i.hasValue()) return this.styles[t] = i, i;
  2852. if (!r) {
  2853. var a = this.parent;
  2854. if (a) {
  2855. var o = a.getStyle(t);
  2856. if (o && o.hasValue()) return o
  2857. }
  2858. }
  2859. if (e) {
  2860. var u = new ts(this.document, t, "");
  2861. return this.styles[t] = u, u
  2862. }
  2863. return n || ts.empty(this.document)
  2864. }
  2865. }, {
  2866. key: "render", value: function (t) {
  2867. if ("none" !== this.getStyle("display").getString() && "hidden" !== this.getStyle("visibility").getString()) {
  2868. if (t.save(), this.getStyle("mask").hasValue()) {
  2869. var e = this.getStyle("mask").getDefinition();
  2870. e && (this.applyEffects(t), e.apply(t, this))
  2871. } else if ("none" !== this.getStyle("filter").getValue("none")) {
  2872. var r = this.getStyle("filter").getDefinition();
  2873. r && (this.applyEffects(t), r.apply(t, this))
  2874. } else this.setContext(t), this.renderChildren(t), this.clearContext(t);
  2875. t.restore()
  2876. }
  2877. }
  2878. }, {
  2879. key: "setContext", value: function (t) {
  2880. }
  2881. }, {
  2882. key: "applyEffects", value: function (t) {
  2883. var e = ec.fromElement(this.document, this);
  2884. e && e.apply(t);
  2885. var r = this.getStyle("clip-path", !1, !0);
  2886. if (r.hasValue()) {
  2887. var n = r.getDefinition();
  2888. n && n.apply(t)
  2889. }
  2890. }
  2891. }, {
  2892. key: "clearContext", value: function (t) {
  2893. }
  2894. }, {
  2895. key: "renderChildren", value: function (t) {
  2896. var e;
  2897. Hi(e = this.children).call(e, (function (e) {
  2898. e.render(t)
  2899. }))
  2900. }
  2901. }, {
  2902. key: "addChild", value: function (e) {
  2903. var r, n = e instanceof t ? e : this.document.createElement(e);
  2904. n.parent = this, Hs(r = t.ignoreChildTypes).call(r, n.type) || this.children.push(n)
  2905. }
  2906. }, {
  2907. key: "matchesSelector", value: function (t) {
  2908. var e, r = this.node;
  2909. if ("function" == typeof r.matches) return r.matches(t);
  2910. var n = r.getAttribute("class");
  2911. return !(!n || "" === n) && Ls(e = n.split(" ")).call(e, (function (e) {
  2912. if (".".concat(e) === t) return !0
  2913. }))
  2914. }
  2915. }, {
  2916. key: "addStylesFromStyleDefinition", value: function () {
  2917. var t = this.document, e = t.styles, r = t.stylesSpecificity;
  2918. for (var n in e) if ("@" !== n[0] && this.matchesSelector(n)) {
  2919. var i = e[n], a = r[n];
  2920. if (i) for (var o in i) {
  2921. var u = this.stylesSpecificity[o];
  2922. void 0 === u && (u = "000"), a >= u && (this.styles[o] = i[o], this.stylesSpecificity[o] = a)
  2923. }
  2924. }
  2925. }
  2926. }, {
  2927. key: "removeStyles", value: function (t, e) {
  2928. return $o(e).call(e, (function (e, r) {
  2929. var n, i = t.getStyle(r);
  2930. if (!i.hasValue()) return e;
  2931. var a = i.getString();
  2932. return i.setValue(""), Ho(n = []).call(n, Ms(e), [[r, a]])
  2933. }), [])
  2934. }
  2935. }, {
  2936. key: "restoreStyles", value: function (t, e) {
  2937. Hi(e).call(e, (function (e) {
  2938. var r = ci(e, 2), n = r[0], i = r[1];
  2939. t.getStyle(n, !0).setValue(i)
  2940. }))
  2941. }
  2942. }]), t
  2943. }();
  2944. function nc(t) {
  2945. var e = function () {
  2946. if ("undefined" == typeof Reflect || !ys) return !1;
  2947. if (ys.sham) return !1;
  2948. if ("function" == typeof Proxy) return !0;
  2949. try {
  2950. return Date.prototype.toString.call(ys(Date, [], (function () {
  2951. }))), !0
  2952. } catch (t) {
  2953. return !1
  2954. }
  2955. }();
  2956. return function () {
  2957. var r, n = Os(t);
  2958. if (e) {
  2959. var i = Os(this).constructor;
  2960. r = ys(n, arguments, i)
  2961. } else r = n.apply(this, arguments);
  2962. return As(this, r)
  2963. }
  2964. }
  2965. rc.ignoreChildTypes = ["title"];
  2966. var ic = function (t) {
  2967. xs(r, t);
  2968. var e = nc(r);
  2969. function r(t, n, i) {
  2970. return jo(this, r), e.call(this, t, n, i)
  2971. }
  2972. return r
  2973. }(rc), ac = [].reverse, oc = [1, 2];
  2974. H({target: "Array", proto: !0, forced: String(oc) === String(oc.reverse())}, {
  2975. reverse: function () {
  2976. return Nt(this) && (this.length = this.length), ac.call(this)
  2977. }
  2978. });
  2979. var uc = yt("Array").reverse, sc = Array.prototype, cc = function (t) {
  2980. var e = t.reverse;
  2981. return t === sc || t instanceof Array && e === sc.reverse ? uc : e
  2982. }, lc = Ye.indexOf, fc = [].indexOf, hc = !!fc && 1 / [1].indexOf(1, -0) < 0, pc = Vi("indexOf"),
  2983. yc = Wt("indexOf", {ACCESSORS: !0, 1: 0});
  2984. H({target: "Array", proto: !0, forced: hc || !pc || !yc}, {
  2985. indexOf: function (t) {
  2986. return hc ? fc.apply(this, arguments) || 0 : lc(this, t, arguments.length > 1 ? arguments[1] : void 0)
  2987. }
  2988. });
  2989. var vc = yt("Array").indexOf, gc = Array.prototype, dc = function (t) {
  2990. var e = t.indexOf;
  2991. return t === gc || t instanceof Array && e === gc.indexOf ? vc : e
  2992. }, mc = qi;
  2993. H({target: "Reflect", stat: !0}, {
  2994. get: function t(e, r) {
  2995. var n, i, a = arguments.length < 3 ? e : arguments[2];
  2996. return I(e) === a ? e[r] : (n = O.f(e, r)) ? b(n, "value") ? n.value : void 0 === n.get ? void 0 : n.get.call(a) : d(i = Ie(e)) ? t(i, r, a) : void 0
  2997. }
  2998. });
  2999. var xc = D.Reflect.get;
  3000. var bc = function (t, e) {
  3001. for (; !Object.prototype.hasOwnProperty.call(t, e) && null !== (t = Os(t));) ;
  3002. return t
  3003. }, wc = r((function (t) {
  3004. function e(r, n, i) {
  3005. return "undefined" != typeof Reflect && xc ? t.exports = e = xc : t.exports = e = function (t, e, r) {
  3006. var n = bc(t, e);
  3007. if (n) {
  3008. var i = mc(n, e);
  3009. return i.get ? i.get.call(r) : i.value
  3010. }
  3011. }, e(r, n, i || r)
  3012. }
  3013. t.exports = e
  3014. }));
  3015. function Sc(t) {
  3016. var e = Ku(t).call(t);
  3017. return /^('|")/.test(e) ? e : '"'.concat(e, '"')
  3018. }
  3019. function Ac(t) {
  3020. if (!t) return "";
  3021. var e = Ku(t).call(t).toLowerCase();
  3022. switch (e) {
  3023. case"normal":
  3024. case"italic":
  3025. case"oblique":
  3026. case"inherit":
  3027. case"initial":
  3028. case"unset":
  3029. return e;
  3030. default:
  3031. return /^oblique\s+(-|)\d+deg$/.test(e) ? e : ""
  3032. }
  3033. }
  3034. function kc(t) {
  3035. if (!t) return "";
  3036. var e = Ku(t).call(t).toLowerCase();
  3037. switch (e) {
  3038. case"normal":
  3039. case"bold":
  3040. case"lighter":
  3041. case"bolder":
  3042. case"inherit":
  3043. case"initial":
  3044. case"unset":
  3045. return e;
  3046. default:
  3047. return /^[\d.]+$/.test(e) ? e : ""
  3048. }
  3049. }
  3050. var Tc = function () {
  3051. function t(e, r, n, i, a, o) {
  3052. jo(this, t);
  3053. var u = o ? "string" == typeof o ? t.parse(o) : o : {};
  3054. this.fontFamily = a || u.fontFamily, this.fontSize = i || u.fontSize, this.fontStyle = e || u.fontStyle, this.fontWeight = n || u.fontWeight, this.fontVariant = r || u.fontVariant
  3055. }
  3056. return Fo(t, [{
  3057. key: "toString", value: function () {
  3058. var t, e, r;
  3059. return Ku(t = [Ac(this.fontStyle), this.fontVariant, kc(this.fontWeight), this.fontSize, (e = this.fontFamily, "undefined" == typeof process ? e : ee(r = Ku(e).call(e).split(",")).call(r, Sc).join(","))].join(" ")).call(t)
  3060. }
  3061. }], [{
  3062. key: "parse", value: function () {
  3063. var e, r = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "",
  3064. n = arguments.length > 1 ? arguments[1] : void 0, i = "", a = "", o = "", u = "", s = "",
  3065. c = Ku(e = re(r)).call(e).split(" "),
  3066. l = {fontSize: !1, fontStyle: !1, fontWeight: !1, fontVariant: !1};
  3067. return Hi(c).call(c, (function (e) {
  3068. var r, n, c;
  3069. switch (!0) {
  3070. case!l.fontStyle && Hs(r = t.styles).call(r, e):
  3071. "inherit" !== e && (i = e), l.fontStyle = !0;
  3072. break;
  3073. case!l.fontVariant && Hs(n = t.variants).call(n, e):
  3074. "inherit" !== e && (a = e), l.fontStyle = !0, l.fontVariant = !0;
  3075. break;
  3076. case!l.fontWeight && Hs(c = t.weights).call(c, e):
  3077. "inherit" !== e && (o = e), l.fontStyle = !0, l.fontVariant = !0, l.fontWeight = !0;
  3078. break;
  3079. case!l.fontSize:
  3080. if ("inherit" !== e) {
  3081. var f = e.split("/"), h = ci(f, 1);
  3082. u = h[0]
  3083. }
  3084. l.fontStyle = !0, l.fontVariant = !0, l.fontWeight = !0, l.fontSize = !0;
  3085. break;
  3086. default:
  3087. "inherit" !== e && (s += e)
  3088. }
  3089. })), new t(i, a, o, u, s, n)
  3090. }
  3091. }]), t
  3092. }();
  3093. Tc.styles = "normal|italic|oblique|inherit", Tc.variants = "normal|small-caps|inherit", Tc.weights = "normal|bold|bolder|lighter|100|200|300|400|500|600|700|800|900|inherit";
  3094. var Oc = function () {
  3095. function t() {
  3096. var e = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : Number.NaN,
  3097. r = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : Number.NaN,
  3098. n = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : Number.NaN,
  3099. i = arguments.length > 3 && void 0 !== arguments[3] ? arguments[3] : Number.NaN;
  3100. jo(this, t), this.x1 = e, this.y1 = r, this.x2 = n, this.y2 = i, this.addPoint(e, r), this.addPoint(n, i)
  3101. }
  3102. return Fo(t, [{
  3103. key: "addPoint", value: function (t, e) {
  3104. void 0 !== t && ((isNaN(this.x1) || isNaN(this.x2)) && (this.x1 = t, this.x2 = t), t < this.x1 && (this.x1 = t), t > this.x2 && (this.x2 = t)), void 0 !== e && ((isNaN(this.y1) || isNaN(this.y2)) && (this.y1 = e, this.y2 = e), e < this.y1 && (this.y1 = e), e > this.y2 && (this.y2 = e))
  3105. }
  3106. }, {
  3107. key: "addX", value: function (t) {
  3108. this.addPoint(t, null)
  3109. }
  3110. }, {
  3111. key: "addY", value: function (t) {
  3112. this.addPoint(null, t)
  3113. }
  3114. }, {
  3115. key: "addBoundingBox", value: function (t) {
  3116. if (t) {
  3117. var e = t.x1, r = t.y1, n = t.x2, i = t.y2;
  3118. this.addPoint(e, r), this.addPoint(n, i)
  3119. }
  3120. }
  3121. }, {
  3122. key: "sumCubic", value: function (t, e, r, n, i) {
  3123. return Math.pow(1 - t, 3) * e + 3 * Math.pow(1 - t, 2) * t * r + 3 * (1 - t) * Math.pow(t, 2) * n + Math.pow(t, 3) * i
  3124. }
  3125. }, {
  3126. key: "bezierCurveAdd", value: function (t, e, r, n, i) {
  3127. var a = 6 * e - 12 * r + 6 * n, o = -3 * e + 9 * r - 9 * n + 3 * i, u = 3 * r - 3 * e;
  3128. if (0 !== o) {
  3129. var s = Math.pow(a, 2) - 4 * u * o;
  3130. if (!(s < 0)) {
  3131. var c = (-a + Math.sqrt(s)) / (2 * o);
  3132. 0 < c && c < 1 && (t ? this.addX(this.sumCubic(c, e, r, n, i)) : this.addY(this.sumCubic(c, e, r, n, i)));
  3133. var l = (-a - Math.sqrt(s)) / (2 * o);
  3134. 0 < l && l < 1 && (t ? this.addX(this.sumCubic(l, e, r, n, i)) : this.addY(this.sumCubic(l, e, r, n, i)))
  3135. }
  3136. } else {
  3137. if (0 === a) return;
  3138. var f = -u / a;
  3139. 0 < f && f < 1 && (t ? this.addX(this.sumCubic(f, e, r, n, i)) : this.addY(this.sumCubic(f, e, r, n, i)))
  3140. }
  3141. }
  3142. }, {
  3143. key: "addBezierCurve", value: function (t, e, r, n, i, a, o, u) {
  3144. this.addPoint(t, e), this.addPoint(o, u), this.bezierCurveAdd(!0, t, r, i, o), this.bezierCurveAdd(!1, e, n, a, u)
  3145. }
  3146. }, {
  3147. key: "addQuadraticCurve", value: function (t, e, r, n, i, a) {
  3148. var o = t + 2 / 3 * (r - t), u = e + 2 / 3 * (n - e), s = o + 1 / 3 * (i - t), c = u + 1 / 3 * (a - e);
  3149. this.addBezierCurve(t, e, o, s, u, c, i, a)
  3150. }
  3151. }, {
  3152. key: "isPointInBox", value: function (t, e) {
  3153. var r = this.x1, n = this.y1, i = this.x2, a = this.y2;
  3154. return r <= t && t <= i && n <= e && e <= a
  3155. }
  3156. }, {
  3157. key: "x", get: function () {
  3158. return this.x1
  3159. }
  3160. }, {
  3161. key: "y", get: function () {
  3162. return this.y1
  3163. }
  3164. }, {
  3165. key: "width", get: function () {
  3166. return this.x2 - this.x1
  3167. }
  3168. }, {
  3169. key: "height", get: function () {
  3170. return this.y2 - this.y1
  3171. }
  3172. }]), t
  3173. }();
  3174. function Pc(t) {
  3175. var e = function () {
  3176. if ("undefined" == typeof Reflect || !ys) return !1;
  3177. if (ys.sham) return !1;
  3178. if ("function" == typeof Proxy) return !0;
  3179. try {
  3180. return Date.prototype.toString.call(ys(Date, [], (function () {
  3181. }))), !0
  3182. } catch (t) {
  3183. return !1
  3184. }
  3185. }();
  3186. return function () {
  3187. var r, n = Os(t);
  3188. if (e) {
  3189. var i = Os(this).constructor;
  3190. r = ys(n, arguments, i)
  3191. } else r = n.apply(this, arguments);
  3192. return As(this, r)
  3193. }
  3194. }
  3195. var Ec = function (t) {
  3196. xs(r, t);
  3197. var e = Pc(r);
  3198. function r() {
  3199. var t;
  3200. return jo(this, r), (t = e.apply(this, arguments)).modifiedEmSizeStack = !1, t
  3201. }
  3202. return Fo(r, [{
  3203. key: "calculateOpacity", value: function () {
  3204. for (var t = 1, e = this; e;) {
  3205. var r = e.getStyle("opacity", !1, !0);
  3206. r.hasValue(!0) && (t *= r.getNumber()), e = e.parent
  3207. }
  3208. return t
  3209. }
  3210. }, {
  3211. key: "setContext", value: function (t) {
  3212. var e = arguments.length > 1 && void 0 !== arguments[1] && arguments[1];
  3213. if (!e) {
  3214. var r = this.getStyle("fill"), n = this.getStyle("fill-opacity"), i = this.getStyle("stroke"),
  3215. a = this.getStyle("stroke-opacity");
  3216. if (r.isUrlDefinition()) {
  3217. var o = r.getFillStyleDefinition(this, n);
  3218. o && (t.fillStyle = o)
  3219. } else if (r.hasValue()) {
  3220. "currentColor" === r.getString() && r.setValue(this.getStyle("color").getColor());
  3221. var u = r.getColor();
  3222. "inherit" !== u && (t.fillStyle = "none" === u ? "rgba(0,0,0,0)" : u)
  3223. }
  3224. if (n.hasValue()) {
  3225. var s = new ts(this.document, "fill", t.fillStyle).addOpacity(n).getColor();
  3226. t.fillStyle = s
  3227. }
  3228. if (i.isUrlDefinition()) {
  3229. var c = i.getFillStyleDefinition(this, a);
  3230. c && (t.strokeStyle = c)
  3231. } else if (i.hasValue()) {
  3232. "currentColor" === i.getString() && i.setValue(this.getStyle("color").getColor());
  3233. var l = i.getString();
  3234. "inherit" !== l && (t.strokeStyle = "none" === l ? "rgba(0,0,0,0)" : l)
  3235. }
  3236. if (a.hasValue()) {
  3237. var f = new ts(this.document, "stroke", t.strokeStyle).addOpacity(a).getString();
  3238. t.strokeStyle = f
  3239. }
  3240. var h = this.getStyle("stroke-width");
  3241. if (h.hasValue()) {
  3242. var p = h.getPixels();
  3243. t.lineWidth = p || xi
  3244. }
  3245. var y = this.getStyle("stroke-linecap"), v = this.getStyle("stroke-linejoin"),
  3246. g = this.getStyle("stroke-miterlimit"), d = this.getStyle("paint-order"),
  3247. m = this.getStyle("stroke-dasharray"), x = this.getStyle("stroke-dashoffset");
  3248. if (y.hasValue() && (t.lineCap = y.getString()), v.hasValue() && (t.lineJoin = v.getString()), g.hasValue() && (t.miterLimit = g.getNumber()), d.hasValue() && (t.paintOrder = d.getValue()), m.hasValue() && "none" !== m.getString()) {
  3249. var b = ae(m.getString());
  3250. void 0 !== t.setLineDash ? t.setLineDash(b) : void 0 !== t.webkitLineDash ? t.webkitLineDash = b : void 0 === t.mozDash || 1 === b.length && 0 === b[0] || (t.mozDash = b);
  3251. var w = x.getPixels();
  3252. void 0 !== t.lineDashOffset ? t.lineDashOffset = w : void 0 !== t.webkitLineDashOffset ? t.webkitLineDashOffset = w : void 0 !== t.mozDashOffset && (t.mozDashOffset = w)
  3253. }
  3254. }
  3255. if (this.modifiedEmSizeStack = !1, void 0 !== t.font) {
  3256. var S = this.getStyle("font"), A = this.getStyle("font-style"), k = this.getStyle("font-variant"),
  3257. T = this.getStyle("font-weight"), O = this.getStyle("font-size"),
  3258. P = this.getStyle("font-family"),
  3259. E = new Tc(A.getString(), k.getString(), T.getString(), O.hasValue() ? "".concat(O.getPixels(!0), "px") : "", P.getString(), Tc.parse(S.getString(), t.font));
  3260. A.setValue(E.fontStyle), k.setValue(E.fontVariant), T.setValue(E.fontWeight), O.setValue(E.fontSize), P.setValue(E.fontFamily), t.font = E.toString(), O.isPixels() && (this.document.emSize = O.getPixels(), this.modifiedEmSizeStack = !0)
  3261. }
  3262. e || (this.applyEffects(t), t.globalAlpha = this.calculateOpacity())
  3263. }
  3264. }, {
  3265. key: "clearContext", value: function (t) {
  3266. wc(Os(r.prototype), "clearContext", this).call(this, t), this.modifiedEmSizeStack && this.document.popEmSize()
  3267. }
  3268. }]), r
  3269. }(rc);
  3270. function Cc(t) {
  3271. var e = function () {
  3272. if ("undefined" == typeof Reflect || !ys) return !1;
  3273. if (ys.sham) return !1;
  3274. if ("function" == typeof Proxy) return !0;
  3275. try {
  3276. return Date.prototype.toString.call(ys(Date, [], (function () {
  3277. }))), !0
  3278. } catch (t) {
  3279. return !1
  3280. }
  3281. }();
  3282. return function () {
  3283. var r, n = Os(t);
  3284. if (e) {
  3285. var i = Os(this).constructor;
  3286. r = ys(n, arguments, i)
  3287. } else r = n.apply(this, arguments);
  3288. return As(this, r)
  3289. }
  3290. }
  3291. var Mc = function (t) {
  3292. xs(r, t);
  3293. var e = Cc(r);
  3294. function r(t, n, i) {
  3295. var a;
  3296. return jo(this, r), (a = e.call(this, t, n, (this instanceof r ? this.constructor : void 0) === r || i)).type = "text", a.x = 0, a.y = 0, a.measureCache = -1, a
  3297. }
  3298. return Fo(r, [{
  3299. key: "setContext", value: function (t) {
  3300. var e = arguments.length > 1 && void 0 !== arguments[1] && arguments[1];
  3301. wc(Os(r.prototype), "setContext", this).call(this, t, e);
  3302. var n = this.getStyle("dominant-baseline").getTextBaseline() || this.getStyle("alignment-baseline").getTextBaseline();
  3303. n && (t.textBaseline = n)
  3304. }
  3305. }, {
  3306. key: "initializeCoordinates", value: function (t) {
  3307. this.x = this.getAttribute("x").getPixels("x"), this.y = this.getAttribute("y").getPixels("y");
  3308. var e = this.getAttribute("dx"), r = this.getAttribute("dy");
  3309. e.hasValue() && (this.x += e.getPixels("x")), r.hasValue() && (this.y += r.getPixels("y")), this.x += this.getAnchorDelta(t, this, 0)
  3310. }
  3311. }, {
  3312. key: "getBoundingBox", value: function (t) {
  3313. var e, r = this;
  3314. if ("text" !== this.type) return this.getTElementBoundingBox(t);
  3315. this.initializeCoordinates(t);
  3316. var n = null;
  3317. return Hi(e = this.children).call(e, (function (e, i) {
  3318. var a = r.getChildBoundingBox(t, r, r, i);
  3319. n ? n.addBoundingBox(a) : n = a
  3320. })), n
  3321. }
  3322. }, {
  3323. key: "getFontSize", value: function () {
  3324. var t = this.document, e = this.parent, r = Tc.parse(t.ctx.font).fontSize;
  3325. return e.getStyle("font-size").getNumber(r)
  3326. }
  3327. }, {
  3328. key: "getTElementBoundingBox", value: function (t) {
  3329. var e = this.getFontSize();
  3330. return new Oc(this.x, this.y - e, this.x + this.measureText(t), this.y)
  3331. }
  3332. }, {
  3333. key: "getGlyph", value: function (t, e, r) {
  3334. var n = e[r], i = null;
  3335. if (t.isArabic) {
  3336. var a = e.length, o = e[r - 1], u = e[r + 1], s = "isolated";
  3337. (0 === r || " " === o) && r < a - 2 && " " !== u && (s = "terminal"), r > 0 && " " !== o && r < a - 2 && " " !== u && (s = "medial"), r > 0 && " " !== o && (r === a - 1 || " " === u) && (s = "initial"), void 0 !== t.glyphs[n] && ((i = t.glyphs[n][s]) || "glyph" !== t.glyphs[n].type || (i = t.glyphs[n]))
  3338. } else i = t.glyphs[n];
  3339. return i || (i = t.missingGlyph), i
  3340. }
  3341. }, {
  3342. key: "getText", value: function () {
  3343. return ""
  3344. }
  3345. }, {
  3346. key: "getTextFromNode", value: function (t) {
  3347. var e = t || this.node, r = Xs(e.parentNode.childNodes), n = dc(r).call(r, e), i = r.length - 1,
  3348. a = re(e.value || e.text || e.textContent || "");
  3349. return 0 === n && (a = ne(a)), n === i && (a = ie(a)), a
  3350. }
  3351. }, {
  3352. key: "renderChildren", value: function (t) {
  3353. var e, r = this;
  3354. if ("text" === this.type) {
  3355. this.initializeCoordinates(t), Hi(e = this.children).call(e, (function (e, n) {
  3356. r.renderChild(t, r, r, n)
  3357. }));
  3358. var n = this.document.screen.mouse;
  3359. n.isWorking() && n.checkBoundingBox(this, this.getBoundingBox(t))
  3360. } else this.renderTElementChildren(t)
  3361. }
  3362. }, {
  3363. key: "renderTElementChildren", value: function (t) {
  3364. var e = this.document, r = this.parent, n = this.getText(),
  3365. i = r.getStyle("font-family").getDefinition();
  3366. if (i) for (var a, o = i.fontFace.unitsPerEm, u = Tc.parse(e.ctx.font), s = r.getStyle("font-size").getNumber(u.fontSize), c = r.getStyle("font-style").getString(u.fontStyle), l = s / o, f = i.isRTL ? cc(a = n.split("")).call(a).join("") : n, h = ae(r.getAttribute("dx").getString()), p = f.length, y = 0; y < p; y++) {
  3367. var v = this.getGlyph(i, f, y);
  3368. t.translate(this.x, this.y), t.scale(l, -l);
  3369. var g = t.lineWidth;
  3370. t.lineWidth = t.lineWidth * o / s, "italic" === c && t.transform(1, 0, .4, 1, 0, 0), v.render(t), "italic" === c && t.transform(1, 0, -.4, 1, 0, 0), t.lineWidth = g, t.scale(1 / l, -1 / l), t.translate(-this.x, -this.y), this.x += s * (v.horizAdvX || i.horizAdvX) / o, void 0 === h[y] || isNaN(h[y]) || (this.x += h[y])
  3371. } else {
  3372. var d = this.x, m = this.y;
  3373. "stroke" === t.paintOrder ? (t.strokeStyle && t.strokeText(n, d, m), t.fillStyle && t.fillText(n, d, m)) : (t.fillStyle && t.fillText(n, d, m), t.strokeStyle && t.strokeText(n, d, m))
  3374. }
  3375. }
  3376. }, {
  3377. key: "getAnchorDelta", value: function (t, e, r) {
  3378. var n = this.getStyle("text-anchor").getString("start");
  3379. if ("start" !== n) {
  3380. for (var i = e.children, a = i.length, o = null, u = 0, s = r; s < a && (o = i[s], !(s > r && o.getAttribute("x").hasValue() || o.getAttribute("text-anchor").hasValue())); s++) u += o.measureTextRecursive(t);
  3381. return -1 * ("end" === n ? u : u / 2)
  3382. }
  3383. return 0
  3384. }
  3385. }, {
  3386. key: "adjustChildCoordinates", value: function (t, e, r, n) {
  3387. var i = r.children[n];
  3388. if ("function" != typeof i.measureText) return i;
  3389. t.save(), i.setContext(t, !0);
  3390. var a = i.getAttribute("x"), o = i.getAttribute("y"), u = i.getAttribute("dx"),
  3391. s = i.getAttribute("dy"), c = i.getAttribute("text-anchor").getString("start");
  3392. if (0 === n && "textNode" !== i.type && (a.hasValue() || a.setValue(e.getAttribute("x").getValue("0")), o.hasValue() || o.setValue(e.getAttribute("y").getValue("0")), u.hasValue() || u.setValue(e.getAttribute("dx").getValue("0")), s.hasValue() || s.setValue(e.getAttribute("dy").getValue("0"))), a.hasValue()) {
  3393. if (i.x = a.getPixels("x") + e.getAnchorDelta(t, r, n), "start" !== c) {
  3394. var l = i.measureTextRecursive(t);
  3395. i.x += -1 * ("end" === c ? l : l / 2)
  3396. }
  3397. u.hasValue() && (i.x += u.getPixels("x"))
  3398. } else {
  3399. if ("start" !== c) {
  3400. var f = i.measureTextRecursive(t);
  3401. e.x += -1 * ("end" === c ? f : f / 2)
  3402. }
  3403. u.hasValue() && (e.x += u.getPixels("x")), i.x = e.x
  3404. }
  3405. return e.x = i.x + i.measureText(t), o.hasValue() ? (i.y = o.getPixels("y"), s.hasValue() && (i.y += s.getPixels("y"))) : (s.hasValue() && (e.y += s.getPixels("y")), i.y = e.y), e.y = i.y, i.clearContext(t), t.restore(), i
  3406. }
  3407. }, {
  3408. key: "getChildBoundingBox", value: function (t, e, r, n) {
  3409. var i, a = this.adjustChildCoordinates(t, e, r, n);
  3410. if ("function" != typeof a.getBoundingBox) return null;
  3411. var o = a.getBoundingBox(t);
  3412. return o ? (Hi(i = a.children).call(i, (function (r, n) {
  3413. var i = e.getChildBoundingBox(t, e, a, n);
  3414. o.addBoundingBox(i)
  3415. })), o) : null
  3416. }
  3417. }, {
  3418. key: "renderChild", value: function (t, e, r, n) {
  3419. var i, a = this.adjustChildCoordinates(t, e, r, n);
  3420. a.render(t), Hi(i = a.children).call(i, (function (r, n) {
  3421. e.renderChild(t, e, a, n)
  3422. }))
  3423. }
  3424. }, {
  3425. key: "measureTextRecursive", value: function (t) {
  3426. var e;
  3427. return $o(e = this.children).call(e, (function (e, r) {
  3428. return e + r.measureTextRecursive(t)
  3429. }), this.measureText(t))
  3430. }
  3431. }, {
  3432. key: "measureText", value: function (t) {
  3433. var e = this.measureCache;
  3434. if (~e) return e;
  3435. var r = this.getText(), n = this.measureTargetText(t, r);
  3436. return this.measureCache = n, n
  3437. }
  3438. }, {
  3439. key: "measureTargetText", value: function (t, e) {
  3440. if (!e.length) return 0;
  3441. var r = this.parent, n = r.getStyle("font-family").getDefinition();
  3442. if (n) {
  3443. for (var i, a = this.getFontSize(), o = n.isRTL ? cc(i = e.split("")).call(i).join("") : e, u = ae(r.getAttribute("dx").getString()), s = o.length, c = 0, l = 0; l < s; l++) {
  3444. c += (this.getGlyph(n, o, l).horizAdvX || n.horizAdvX) * a / n.fontFace.unitsPerEm, void 0 === u[l] || isNaN(u[l]) || (c += u[l])
  3445. }
  3446. return c
  3447. }
  3448. if (!t.measureText) return 10 * e.length;
  3449. t.save(), this.setContext(t, !0);
  3450. var f = t.measureText(e).width;
  3451. return this.clearContext(t), t.restore(), f
  3452. }
  3453. }]), r
  3454. }(Ec);
  3455. function Nc(t) {
  3456. var e = function () {
  3457. if ("undefined" == typeof Reflect || !ys) return !1;
  3458. if (ys.sham) return !1;
  3459. if ("function" == typeof Proxy) return !0;
  3460. try {
  3461. return Date.prototype.toString.call(ys(Date, [], (function () {
  3462. }))), !0
  3463. } catch (t) {
  3464. return !1
  3465. }
  3466. }();
  3467. return function () {
  3468. var r, n = Os(t);
  3469. if (e) {
  3470. var i = Os(this).constructor;
  3471. r = ys(n, arguments, i)
  3472. } else r = n.apply(this, arguments);
  3473. return As(this, r)
  3474. }
  3475. }
  3476. var Rc = function (t) {
  3477. xs(r, t);
  3478. var e = Nc(r);
  3479. function r(t, n, i) {
  3480. var a;
  3481. return jo(this, r), (a = e.call(this, t, n, (this instanceof r ? this.constructor : void 0) === r || i)).type = "tspan", a.text = a.children.length > 0 ? "" : a.getTextFromNode(), a
  3482. }
  3483. return Fo(r, [{
  3484. key: "getText", value: function () {
  3485. return this.text
  3486. }
  3487. }]), r
  3488. }(Mc);
  3489. function _c(t) {
  3490. var e = function () {
  3491. if ("undefined" == typeof Reflect || !ys) return !1;
  3492. if (ys.sham) return !1;
  3493. if ("function" == typeof Proxy) return !0;
  3494. try {
  3495. return Date.prototype.toString.call(ys(Date, [], (function () {
  3496. }))), !0
  3497. } catch (t) {
  3498. return !1
  3499. }
  3500. }();
  3501. return function () {
  3502. var r, n = Os(t);
  3503. if (e) {
  3504. var i = Os(this).constructor;
  3505. r = ys(n, arguments, i)
  3506. } else r = n.apply(this, arguments);
  3507. return As(this, r)
  3508. }
  3509. }
  3510. var Dc = function (t) {
  3511. xs(r, t);
  3512. var e = _c(r);
  3513. function r() {
  3514. var t;
  3515. return jo(this, r), (t = e.apply(this, arguments)).type = "textNode", t
  3516. }
  3517. return r
  3518. }(Rc);
  3519. H({target: "Array", proto: !0}, {
  3520. fill: function (t) {
  3521. for (var e = Mt(this), r = Q(e.length), n = arguments.length, i = He(n > 1 ? arguments[1] : void 0, r), a = n > 2 ? arguments[2] : void 0, o = void 0 === a ? r : He(a, r); o > i;) e[i++] = t;
  3522. return e
  3523. }
  3524. });
  3525. var Vc = yt("Array").fill, Lc = Array.prototype, Ic = function (t) {
  3526. var e = t.fill;
  3527. return t === Lc || t instanceof Array && e === Lc.fill ? Vc : e
  3528. }, jc = function (t, e) {
  3529. return (jc = Object.setPrototypeOf || {__proto__: []} instanceof Array && function (t, e) {
  3530. t.__proto__ = e
  3531. } || function (t, e) {
  3532. for (var r in e) e.hasOwnProperty(r) && (t[r] = e[r])
  3533. })(t, e)
  3534. };
  3535. function zc(t, e) {
  3536. function r() {
  3537. this.constructor = t
  3538. }
  3539. jc(t, e), t.prototype = null === e ? Object.create(e) : (r.prototype = e.prototype, new r)
  3540. }
  3541. function Fc(t, e) {
  3542. var r = t[0], n = t[1];
  3543. return [r * Math.cos(e) - n * Math.sin(e), r * Math.sin(e) + n * Math.cos(e)]
  3544. }
  3545. function Bc() {
  3546. for (var t = [], e = 0; e < arguments.length; e++) t[e] = arguments[e];
  3547. for (var r = 0; r < t.length; r++) if ("number" != typeof t[r]) throw new Error("assertNumbers arguments[" + r + "] is not a number. " + typeof t[r] + " == typeof " + t[r]);
  3548. return !0
  3549. }
  3550. var Uc = Math.PI;
  3551. function Hc(t, e, r) {
  3552. t.lArcFlag = 0 === t.lArcFlag ? 0 : 1, t.sweepFlag = 0 === t.sweepFlag ? 0 : 1;
  3553. var n = t.rX, i = t.rY, a = t.x, o = t.y;
  3554. n = Math.abs(t.rX), i = Math.abs(t.rY);
  3555. var u = Fc([(e - a) / 2, (r - o) / 2], -t.xRot / 180 * Uc), s = u[0], c = u[1],
  3556. l = Math.pow(s, 2) / Math.pow(n, 2) + Math.pow(c, 2) / Math.pow(i, 2);
  3557. 1 < l && (n *= Math.sqrt(l), i *= Math.sqrt(l)), t.rX = n, t.rY = i;
  3558. var f = Math.pow(n, 2) * Math.pow(c, 2) + Math.pow(i, 2) * Math.pow(s, 2),
  3559. h = (t.lArcFlag !== t.sweepFlag ? 1 : -1) * Math.sqrt(Math.max(0, (Math.pow(n, 2) * Math.pow(i, 2) - f) / f)),
  3560. p = n * c / i * h, y = -i * s / n * h, v = Fc([p, y], t.xRot / 180 * Uc);
  3561. t.cX = v[0] + (e + a) / 2, t.cY = v[1] + (r + o) / 2, t.phi1 = Math.atan2((c - y) / i, (s - p) / n), t.phi2 = Math.atan2((-c - y) / i, (-s - p) / n), 0 === t.sweepFlag && t.phi2 > t.phi1 && (t.phi2 -= 2 * Uc), 1 === t.sweepFlag && t.phi2 < t.phi1 && (t.phi2 += 2 * Uc), t.phi1 *= 180 / Uc, t.phi2 *= 180 / Uc
  3562. }
  3563. function Xc(t, e, r) {
  3564. Bc(t, e, r);
  3565. var n = t * t + e * e - r * r;
  3566. if (0 > n) return [];
  3567. if (0 === n) return [[t * r / (t * t + e * e), e * r / (t * t + e * e)]];
  3568. var i = Math.sqrt(n);
  3569. return [[(t * r + e * i) / (t * t + e * e), (e * r - t * i) / (t * t + e * e)], [(t * r - e * i) / (t * t + e * e), (e * r + t * i) / (t * t + e * e)]]
  3570. }
  3571. var Yc, qc = Math.PI / 180;
  3572. function Gc(t, e, r) {
  3573. return (1 - r) * t + r * e
  3574. }
  3575. function Qc(t, e, r, n) {
  3576. return t + Math.cos(n / 180 * Uc) * e + Math.sin(n / 180 * Uc) * r
  3577. }
  3578. function Wc(t, e, r, n) {
  3579. var i = e - t, a = r - e, o = 3 * i + 3 * (n - r) - 6 * a, u = 6 * (a - i), s = 3 * i;
  3580. return Math.abs(o) < 1e-6 ? [-s / u] : function (t, e, r) {
  3581. void 0 === r && (r = 1e-6);
  3582. var n = t * t / 4 - e;
  3583. if (n < -r) return [];
  3584. if (n <= r) return [-t / 2];
  3585. var i = Math.sqrt(n);
  3586. return [-t / 2 - i, -t / 2 + i]
  3587. }(u / o, s / o, 1e-6)
  3588. }
  3589. function $c(t, e, r, n, i) {
  3590. var a = 1 - i;
  3591. return t * (a * a * a) + e * (3 * a * a * i) + r * (3 * a * i * i) + n * (i * i * i)
  3592. }
  3593. !function (t) {
  3594. function e() {
  3595. return i((function (t, e, r) {
  3596. return t.relative && (void 0 !== t.x1 && (t.x1 += e), void 0 !== t.y1 && (t.y1 += r), void 0 !== t.x2 && (t.x2 += e), void 0 !== t.y2 && (t.y2 += r), void 0 !== t.x && (t.x += e), void 0 !== t.y && (t.y += r), t.relative = !1), t
  3597. }))
  3598. }
  3599. function r() {
  3600. var t = NaN, e = NaN, r = NaN, n = NaN;
  3601. return i((function (i, a, o) {
  3602. return i.type & rl.SMOOTH_CURVE_TO && (i.type = rl.CURVE_TO, t = isNaN(t) ? a : t, e = isNaN(e) ? o : e, i.x1 = i.relative ? a - t : 2 * a - t, i.y1 = i.relative ? o - e : 2 * o - e), i.type & rl.CURVE_TO ? (t = i.relative ? a + i.x2 : i.x2, e = i.relative ? o + i.y2 : i.y2) : (t = NaN, e = NaN), i.type & rl.SMOOTH_QUAD_TO && (i.type = rl.QUAD_TO, r = isNaN(r) ? a : r, n = isNaN(n) ? o : n, i.x1 = i.relative ? a - r : 2 * a - r, i.y1 = i.relative ? o - n : 2 * o - n), i.type & rl.QUAD_TO ? (r = i.relative ? a + i.x1 : i.x1, n = i.relative ? o + i.y1 : i.y1) : (r = NaN, n = NaN), i
  3603. }))
  3604. }
  3605. function n() {
  3606. var t = NaN, e = NaN;
  3607. return i((function (r, n, i) {
  3608. if (r.type & rl.SMOOTH_QUAD_TO && (r.type = rl.QUAD_TO, t = isNaN(t) ? n : t, e = isNaN(e) ? i : e, r.x1 = r.relative ? n - t : 2 * n - t, r.y1 = r.relative ? i - e : 2 * i - e), r.type & rl.QUAD_TO) {
  3609. t = r.relative ? n + r.x1 : r.x1, e = r.relative ? i + r.y1 : r.y1;
  3610. var a = r.x1, o = r.y1;
  3611. r.type = rl.CURVE_TO, r.x1 = ((r.relative ? 0 : n) + 2 * a) / 3, r.y1 = ((r.relative ? 0 : i) + 2 * o) / 3, r.x2 = (r.x + 2 * a) / 3, r.y2 = (r.y + 2 * o) / 3
  3612. } else t = NaN, e = NaN;
  3613. return r
  3614. }))
  3615. }
  3616. function i(t) {
  3617. var e = 0, r = 0, n = NaN, i = NaN;
  3618. return function (a) {
  3619. if (isNaN(n) && !(a.type & rl.MOVE_TO)) throw new Error("path must start with moveto");
  3620. var o = t(a, e, r, n, i);
  3621. return a.type & rl.CLOSE_PATH && (e = n, r = i), void 0 !== a.x && (e = a.relative ? e + a.x : a.x), void 0 !== a.y && (r = a.relative ? r + a.y : a.y), a.type & rl.MOVE_TO && (n = e, i = r), o
  3622. }
  3623. }
  3624. function a(t, e, r, n, a, o) {
  3625. return Bc(t, e, r, n, a, o), i((function (i, u, s, c) {
  3626. var l = i.x1, f = i.x2, h = i.relative && !isNaN(c), p = void 0 !== i.x ? i.x : h ? 0 : u,
  3627. y = void 0 !== i.y ? i.y : h ? 0 : s;
  3628. function v(t) {
  3629. return t * t
  3630. }
  3631. i.type & rl.HORIZ_LINE_TO && 0 !== e && (i.type = rl.LINE_TO, i.y = i.relative ? 0 : s), i.type & rl.VERT_LINE_TO && 0 !== r && (i.type = rl.LINE_TO, i.x = i.relative ? 0 : u), void 0 !== i.x && (i.x = i.x * t + y * r + (h ? 0 : a)), void 0 !== i.y && (i.y = p * e + i.y * n + (h ? 0 : o)), void 0 !== i.x1 && (i.x1 = i.x1 * t + i.y1 * r + (h ? 0 : a)), void 0 !== i.y1 && (i.y1 = l * e + i.y1 * n + (h ? 0 : o)), void 0 !== i.x2 && (i.x2 = i.x2 * t + i.y2 * r + (h ? 0 : a)), void 0 !== i.y2 && (i.y2 = f * e + i.y2 * n + (h ? 0 : o));
  3632. var g = t * n - e * r;
  3633. if (void 0 !== i.xRot && (1 !== t || 0 !== e || 0 !== r || 1 !== n)) if (0 === g) delete i.rX, delete i.rY, delete i.xRot, delete i.lArcFlag, delete i.sweepFlag, i.type = rl.LINE_TO; else {
  3634. var d = i.xRot * Math.PI / 180, m = Math.sin(d), x = Math.cos(d), b = 1 / v(i.rX), w = 1 / v(i.rY),
  3635. S = v(x) * b + v(m) * w, A = 2 * m * x * (b - w), k = v(m) * b + v(x) * w,
  3636. T = S * n * n - A * e * n + k * e * e, O = A * (t * n + e * r) - 2 * (S * r * n + k * t * e),
  3637. P = S * r * r - A * t * r + k * t * t, E = (Math.atan2(O, T - P) + Math.PI) % Math.PI / 2,
  3638. C = Math.sin(E), M = Math.cos(E);
  3639. i.rX = Math.abs(g) / Math.sqrt(T * v(M) + O * C * M + P * v(C)), i.rY = Math.abs(g) / Math.sqrt(T * v(C) - O * C * M + P * v(M)), i.xRot = 180 * E / Math.PI
  3640. }
  3641. return void 0 !== i.sweepFlag && 0 > g && (i.sweepFlag = +!i.sweepFlag), i
  3642. }))
  3643. }
  3644. t.ROUND = function (t) {
  3645. function e(e) {
  3646. return Math.round(e * t) / t
  3647. }
  3648. return void 0 === t && (t = 1e13), Bc(t), function (t) {
  3649. return void 0 !== t.x1 && (t.x1 = e(t.x1)), void 0 !== t.y1 && (t.y1 = e(t.y1)), void 0 !== t.x2 && (t.x2 = e(t.x2)), void 0 !== t.y2 && (t.y2 = e(t.y2)), void 0 !== t.x && (t.x = e(t.x)), void 0 !== t.y && (t.y = e(t.y)), void 0 !== t.rX && (t.rX = e(t.rX)), void 0 !== t.rY && (t.rY = e(t.rY)), t
  3650. }
  3651. }, t.TO_ABS = e, t.TO_REL = function () {
  3652. return i((function (t, e, r) {
  3653. return t.relative || (void 0 !== t.x1 && (t.x1 -= e), void 0 !== t.y1 && (t.y1 -= r), void 0 !== t.x2 && (t.x2 -= e), void 0 !== t.y2 && (t.y2 -= r), void 0 !== t.x && (t.x -= e), void 0 !== t.y && (t.y -= r), t.relative = !0), t
  3654. }))
  3655. }, t.NORMALIZE_HVZ = function (t, e, r) {
  3656. return void 0 === t && (t = !0), void 0 === e && (e = !0), void 0 === r && (r = !0), i((function (n, i, a, o, u) {
  3657. if (isNaN(o) && !(n.type & rl.MOVE_TO)) throw new Error("path must start with moveto");
  3658. return e && n.type & rl.HORIZ_LINE_TO && (n.type = rl.LINE_TO, n.y = n.relative ? 0 : a), r && n.type & rl.VERT_LINE_TO && (n.type = rl.LINE_TO, n.x = n.relative ? 0 : i), t && n.type & rl.CLOSE_PATH && (n.type = rl.LINE_TO, n.x = n.relative ? o - i : o, n.y = n.relative ? u - a : u), n.type & rl.ARC && (0 === n.rX || 0 === n.rY) && (n.type = rl.LINE_TO, delete n.rX, delete n.rY, delete n.xRot, delete n.lArcFlag, delete n.sweepFlag), n
  3659. }))
  3660. }, t.NORMALIZE_ST = r, t.QT_TO_C = n, t.INFO = i, t.SANITIZE = function (t) {
  3661. void 0 === t && (t = 0), Bc(t);
  3662. var e = NaN, r = NaN, n = NaN, a = NaN;
  3663. return i((function (i, o, u, s, c) {
  3664. var l = Math.abs, f = !1, h = 0, p = 0;
  3665. if (i.type & rl.SMOOTH_CURVE_TO && (h = isNaN(e) ? 0 : o - e, p = isNaN(r) ? 0 : u - r), i.type & (rl.CURVE_TO | rl.SMOOTH_CURVE_TO) ? (e = i.relative ? o + i.x2 : i.x2, r = i.relative ? u + i.y2 : i.y2) : (e = NaN, r = NaN), i.type & rl.SMOOTH_QUAD_TO ? (n = isNaN(n) ? o : 2 * o - n, a = isNaN(a) ? u : 2 * u - a) : i.type & rl.QUAD_TO ? (n = i.relative ? o + i.x1 : i.x1, a = i.relative ? u + i.y1 : i.y2) : (n = NaN, a = NaN), i.type & rl.LINE_COMMANDS || i.type & rl.ARC && (0 === i.rX || 0 === i.rY || !i.lArcFlag) || i.type & rl.CURVE_TO || i.type & rl.SMOOTH_CURVE_TO || i.type & rl.QUAD_TO || i.type & rl.SMOOTH_QUAD_TO) {
  3666. var y = void 0 === i.x ? 0 : i.relative ? i.x : i.x - o,
  3667. v = void 0 === i.y ? 0 : i.relative ? i.y : i.y - u;
  3668. h = isNaN(n) ? void 0 === i.x1 ? h : i.relative ? i.x : i.x1 - o : n - o, p = isNaN(a) ? void 0 === i.y1 ? p : i.relative ? i.y : i.y1 - u : a - u;
  3669. var g = void 0 === i.x2 ? 0 : i.relative ? i.x : i.x2 - o,
  3670. d = void 0 === i.y2 ? 0 : i.relative ? i.y : i.y2 - u;
  3671. l(y) <= t && l(v) <= t && l(h) <= t && l(p) <= t && l(g) <= t && l(d) <= t && (f = !0)
  3672. }
  3673. return i.type & rl.CLOSE_PATH && l(o - s) <= t && l(u - c) <= t && (f = !0), f ? [] : i
  3674. }))
  3675. }, t.MATRIX = a, t.ROTATE = function (t, e, r) {
  3676. void 0 === e && (e = 0), void 0 === r && (r = 0), Bc(t, e, r);
  3677. var n = Math.sin(t), i = Math.cos(t);
  3678. return a(i, n, -n, i, e - e * i + r * n, r - e * n - r * i)
  3679. }, t.TRANSLATE = function (t, e) {
  3680. return void 0 === e && (e = 0), Bc(t, e), a(1, 0, 0, 1, t, e)
  3681. }, t.SCALE = function (t, e) {
  3682. return void 0 === e && (e = t), Bc(t, e), a(t, 0, 0, e, 0, 0)
  3683. }, t.SKEW_X = function (t) {
  3684. return Bc(t), a(1, 0, Math.atan(t), 1, 0, 0)
  3685. }, t.SKEW_Y = function (t) {
  3686. return Bc(t), a(1, Math.atan(t), 0, 1, 0, 0)
  3687. }, t.X_AXIS_SYMMETRY = function (t) {
  3688. return void 0 === t && (t = 0), Bc(t), a(-1, 0, 0, 1, t, 0)
  3689. }, t.Y_AXIS_SYMMETRY = function (t) {
  3690. return void 0 === t && (t = 0), Bc(t), a(1, 0, 0, -1, 0, t)
  3691. }, t.A_TO_C = function () {
  3692. return i((function (t, e, r) {
  3693. return rl.ARC === t.type ? function (t, e, r) {
  3694. var n, i, a, o;
  3695. t.cX || Hc(t, e, r);
  3696. for (var u = Math.min(t.phi1, t.phi2), s = Math.max(t.phi1, t.phi2) - u, c = Math.ceil(s / 90), l = new Array(c), f = e, h = r, p = 0; p < c; p++) {
  3697. var y = Gc(t.phi1, t.phi2, p / c), v = Gc(t.phi1, t.phi2, (p + 1) / c), g = v - y,
  3698. d = 4 / 3 * Math.tan(g * qc / 4),
  3699. m = [Math.cos(y * qc) - d * Math.sin(y * qc), Math.sin(y * qc) + d * Math.cos(y * qc)],
  3700. x = m[0], b = m[1], w = [Math.cos(v * qc), Math.sin(v * qc)], S = w[0], A = w[1],
  3701. k = [S + d * Math.sin(v * qc), A - d * Math.cos(v * qc)], T = k[0], O = k[1];
  3702. l[p] = {relative: t.relative, type: rl.CURVE_TO};
  3703. var P = function (e, r) {
  3704. var n = Fc([e * t.rX, r * t.rY], t.xRot), i = n[0], a = n[1];
  3705. return [t.cX + i, t.cY + a]
  3706. };
  3707. n = P(x, b), l[p].x1 = n[0], l[p].y1 = n[1], i = P(T, O), l[p].x2 = i[0], l[p].y2 = i[1], a = P(S, A), l[p].x = a[0], l[p].y = a[1], t.relative && (l[p].x1 -= f, l[p].y1 -= h, l[p].x2 -= f, l[p].y2 -= h, l[p].x -= f, l[p].y -= h), f = (o = [l[p].x, l[p].y])[0], h = o[1]
  3708. }
  3709. return l
  3710. }(t, t.relative ? 0 : e, t.relative ? 0 : r) : t
  3711. }))
  3712. }, t.ANNOTATE_ARCS = function () {
  3713. return i((function (t, e, r) {
  3714. return t.relative && (e = 0, r = 0), rl.ARC === t.type && Hc(t, e, r), t
  3715. }))
  3716. }, t.CLONE = function () {
  3717. return function (t) {
  3718. var e = {};
  3719. for (var r in t) e[r] = t[r];
  3720. return e
  3721. }
  3722. }, t.CALCULATE_BOUNDS = function () {
  3723. var t = e(), a = n(), o = r(), u = i((function (e, r, n) {
  3724. var i = o(a(t(function (t) {
  3725. var e = {};
  3726. for (var r in t) e[r] = t[r];
  3727. return e
  3728. }(e))));
  3729. function s(t) {
  3730. t > u.maxX && (u.maxX = t), t < u.minX && (u.minX = t)
  3731. }
  3732. function c(t) {
  3733. t > u.maxY && (u.maxY = t), t < u.minY && (u.minY = t)
  3734. }
  3735. if (i.type & rl.DRAWING_COMMANDS && (s(r), c(n)), i.type & rl.HORIZ_LINE_TO && s(i.x), i.type & rl.VERT_LINE_TO && c(i.y), i.type & rl.LINE_TO && (s(i.x), c(i.y)), i.type & rl.CURVE_TO) {
  3736. s(i.x), c(i.y);
  3737. for (var l = 0, f = Wc(r, i.x1, i.x2, i.x); l < f.length; l++) 0 < (P = f[l]) && 1 > P && s($c(r, i.x1, i.x2, i.x, P));
  3738. for (var h = 0, p = Wc(n, i.y1, i.y2, i.y); h < p.length; h++) 0 < (P = p[h]) && 1 > P && c($c(n, i.y1, i.y2, i.y, P))
  3739. }
  3740. if (i.type & rl.ARC) {
  3741. s(i.x), c(i.y), Hc(i, r, n);
  3742. for (var y = i.xRot / 180 * Math.PI, v = Math.cos(y) * i.rX, g = Math.sin(y) * i.rX, d = -Math.sin(y) * i.rY, m = Math.cos(y) * i.rY, x = i.phi1 < i.phi2 ? [i.phi1, i.phi2] : -180 > i.phi2 ? [i.phi2 + 360, i.phi1 + 360] : [i.phi2, i.phi1], b = x[0], w = x[1], S = function (t) {
  3743. var e = t[0], r = t[1], n = 180 * Math.atan2(r, e) / Math.PI;
  3744. return n < b ? n + 360 : n
  3745. }, A = 0, k = Xc(d, -v, 0).map(S); A < k.length; A++) (P = k[A]) > b && P < w && s(Qc(i.cX, v, d, P));
  3746. for (var T = 0, O = Xc(m, -g, 0).map(S); T < O.length; T++) {
  3747. var P;
  3748. (P = O[T]) > b && P < w && c(Qc(i.cY, g, m, P))
  3749. }
  3750. }
  3751. return e
  3752. }));
  3753. return u.minX = 1 / 0, u.maxX = -1 / 0, u.minY = 1 / 0, u.maxY = -1 / 0, u
  3754. }
  3755. }(Yc || (Yc = {}));
  3756. var Zc, Kc = function () {
  3757. function t() {
  3758. }
  3759. return t.prototype.round = function (t) {
  3760. return this.transform(Yc.ROUND(t))
  3761. }, t.prototype.toAbs = function () {
  3762. return this.transform(Yc.TO_ABS())
  3763. }, t.prototype.toRel = function () {
  3764. return this.transform(Yc.TO_REL())
  3765. }, t.prototype.normalizeHVZ = function (t, e, r) {
  3766. return this.transform(Yc.NORMALIZE_HVZ(t, e, r))
  3767. }, t.prototype.normalizeST = function () {
  3768. return this.transform(Yc.NORMALIZE_ST())
  3769. }, t.prototype.qtToC = function () {
  3770. return this.transform(Yc.QT_TO_C())
  3771. }, t.prototype.aToC = function () {
  3772. return this.transform(Yc.A_TO_C())
  3773. }, t.prototype.sanitize = function (t) {
  3774. return this.transform(Yc.SANITIZE(t))
  3775. }, t.prototype.translate = function (t, e) {
  3776. return this.transform(Yc.TRANSLATE(t, e))
  3777. }, t.prototype.scale = function (t, e) {
  3778. return this.transform(Yc.SCALE(t, e))
  3779. }, t.prototype.rotate = function (t, e, r) {
  3780. return this.transform(Yc.ROTATE(t, e, r))
  3781. }, t.prototype.matrix = function (t, e, r, n, i, a) {
  3782. return this.transform(Yc.MATRIX(t, e, r, n, i, a))
  3783. }, t.prototype.skewX = function (t) {
  3784. return this.transform(Yc.SKEW_X(t))
  3785. }, t.prototype.skewY = function (t) {
  3786. return this.transform(Yc.SKEW_Y(t))
  3787. }, t.prototype.xSymmetry = function (t) {
  3788. return this.transform(Yc.X_AXIS_SYMMETRY(t))
  3789. }, t.prototype.ySymmetry = function (t) {
  3790. return this.transform(Yc.Y_AXIS_SYMMETRY(t))
  3791. }, t.prototype.annotateArcs = function () {
  3792. return this.transform(Yc.ANNOTATE_ARCS())
  3793. }, t
  3794. }(), Jc = function (t) {
  3795. return " " === t || "\t" === t || "\r" === t || "\n" === t
  3796. }, tl = function (t) {
  3797. return "0".charCodeAt(0) <= t.charCodeAt(0) && t.charCodeAt(0) <= "9".charCodeAt(0)
  3798. }, el = function (t) {
  3799. function e() {
  3800. var e = t.call(this) || this;
  3801. return e.curNumber = "", e.curCommandType = -1, e.curCommandRelative = !1, e.canParseCommandOrComma = !0, e.curNumberHasExp = !1, e.curNumberHasExpDigits = !1, e.curNumberHasDecimal = !1, e.curArgs = [], e
  3802. }
  3803. return zc(e, t), e.prototype.finish = function (t) {
  3804. if (void 0 === t && (t = []), this.parse(" ", t), 0 !== this.curArgs.length || !this.canParseCommandOrComma) throw new SyntaxError("Unterminated command at the path end.");
  3805. return t
  3806. }, e.prototype.parse = function (t, e) {
  3807. var r = this;
  3808. void 0 === e && (e = []);
  3809. for (var n = function (t) {
  3810. e.push(t), r.curArgs.length = 0, r.canParseCommandOrComma = !0
  3811. }, i = 0; i < t.length; i++) {
  3812. var a = t[i],
  3813. o = !(this.curCommandType !== rl.ARC || 3 !== this.curArgs.length && 4 !== this.curArgs.length || 1 !== this.curNumber.length || "0" !== this.curNumber && "1" !== this.curNumber),
  3814. u = tl(a) && ("0" === this.curNumber && "0" === a || o);
  3815. if (!tl(a) || u) if ("e" !== a && "E" !== a) if ("-" !== a && "+" !== a || !this.curNumberHasExp || this.curNumberHasExpDigits) if ("." !== a || this.curNumberHasExp || this.curNumberHasDecimal || o) {
  3816. if (this.curNumber && -1 !== this.curCommandType) {
  3817. var s = Number(this.curNumber);
  3818. if (isNaN(s)) throw new SyntaxError("Invalid number ending at " + i);
  3819. if (this.curCommandType === rl.ARC) if (0 === this.curArgs.length || 1 === this.curArgs.length) {
  3820. if (0 > s) throw new SyntaxError('Expected positive number, got "' + s + '" at index "' + i + '"')
  3821. } else if ((3 === this.curArgs.length || 4 === this.curArgs.length) && "0" !== this.curNumber && "1" !== this.curNumber) throw new SyntaxError('Expected a flag, got "' + this.curNumber + '" at index "' + i + '"');
  3822. this.curArgs.push(s), this.curArgs.length === nl[this.curCommandType] && (rl.HORIZ_LINE_TO === this.curCommandType ? n({
  3823. type: rl.HORIZ_LINE_TO,
  3824. relative: this.curCommandRelative,
  3825. x: s
  3826. }) : rl.VERT_LINE_TO === this.curCommandType ? n({
  3827. type: rl.VERT_LINE_TO,
  3828. relative: this.curCommandRelative,
  3829. y: s
  3830. }) : this.curCommandType === rl.MOVE_TO || this.curCommandType === rl.LINE_TO || this.curCommandType === rl.SMOOTH_QUAD_TO ? (n({
  3831. type: this.curCommandType,
  3832. relative: this.curCommandRelative,
  3833. x: this.curArgs[0],
  3834. y: this.curArgs[1]
  3835. }), rl.MOVE_TO === this.curCommandType && (this.curCommandType = rl.LINE_TO)) : this.curCommandType === rl.CURVE_TO ? n({
  3836. type: rl.CURVE_TO,
  3837. relative: this.curCommandRelative,
  3838. x1: this.curArgs[0],
  3839. y1: this.curArgs[1],
  3840. x2: this.curArgs[2],
  3841. y2: this.curArgs[3],
  3842. x: this.curArgs[4],
  3843. y: this.curArgs[5]
  3844. }) : this.curCommandType === rl.SMOOTH_CURVE_TO ? n({
  3845. type: rl.SMOOTH_CURVE_TO,
  3846. relative: this.curCommandRelative,
  3847. x2: this.curArgs[0],
  3848. y2: this.curArgs[1],
  3849. x: this.curArgs[2],
  3850. y: this.curArgs[3]
  3851. }) : this.curCommandType === rl.QUAD_TO ? n({
  3852. type: rl.QUAD_TO,
  3853. relative: this.curCommandRelative,
  3854. x1: this.curArgs[0],
  3855. y1: this.curArgs[1],
  3856. x: this.curArgs[2],
  3857. y: this.curArgs[3]
  3858. }) : this.curCommandType === rl.ARC && n({
  3859. type: rl.ARC,
  3860. relative: this.curCommandRelative,
  3861. rX: this.curArgs[0],
  3862. rY: this.curArgs[1],
  3863. xRot: this.curArgs[2],
  3864. lArcFlag: this.curArgs[3],
  3865. sweepFlag: this.curArgs[4],
  3866. x: this.curArgs[5],
  3867. y: this.curArgs[6]
  3868. })), this.curNumber = "", this.curNumberHasExpDigits = !1, this.curNumberHasExp = !1, this.curNumberHasDecimal = !1, this.canParseCommandOrComma = !0
  3869. }
  3870. if (!Jc(a)) if ("," === a && this.canParseCommandOrComma) this.canParseCommandOrComma = !1; else if ("+" !== a && "-" !== a && "." !== a) if (u) this.curNumber = a, this.curNumberHasDecimal = !1; else {
  3871. if (0 !== this.curArgs.length) throw new SyntaxError("Unterminated command at index " + i + ".");
  3872. if (!this.canParseCommandOrComma) throw new SyntaxError('Unexpected character "' + a + '" at index ' + i + ". Command cannot follow comma");
  3873. if (this.canParseCommandOrComma = !1, "z" !== a && "Z" !== a) if ("h" === a || "H" === a) this.curCommandType = rl.HORIZ_LINE_TO, this.curCommandRelative = "h" === a; else if ("v" === a || "V" === a) this.curCommandType = rl.VERT_LINE_TO, this.curCommandRelative = "v" === a; else if ("m" === a || "M" === a) this.curCommandType = rl.MOVE_TO, this.curCommandRelative = "m" === a; else if ("l" === a || "L" === a) this.curCommandType = rl.LINE_TO, this.curCommandRelative = "l" === a; else if ("c" === a || "C" === a) this.curCommandType = rl.CURVE_TO, this.curCommandRelative = "c" === a; else if ("s" === a || "S" === a) this.curCommandType = rl.SMOOTH_CURVE_TO, this.curCommandRelative = "s" === a; else if ("q" === a || "Q" === a) this.curCommandType = rl.QUAD_TO, this.curCommandRelative = "q" === a; else if ("t" === a || "T" === a) this.curCommandType = rl.SMOOTH_QUAD_TO, this.curCommandRelative = "t" === a; else {
  3874. if ("a" !== a && "A" !== a) throw new SyntaxError('Unexpected character "' + a + '" at index ' + i + ".");
  3875. this.curCommandType = rl.ARC, this.curCommandRelative = "a" === a
  3876. } else e.push({type: rl.CLOSE_PATH}), this.canParseCommandOrComma = !0, this.curCommandType = -1
  3877. } else this.curNumber = a, this.curNumberHasDecimal = "." === a
  3878. } else this.curNumber += a, this.curNumberHasDecimal = !0; else this.curNumber += a; else this.curNumber += a, this.curNumberHasExp = !0; else this.curNumber += a, this.curNumberHasExpDigits = this.curNumberHasExp
  3879. }
  3880. return e
  3881. }, e.prototype.transform = function (t) {
  3882. return Object.create(this, {
  3883. parse: {
  3884. value: function (e, r) {
  3885. void 0 === r && (r = []);
  3886. for (var n = 0, i = Object.getPrototypeOf(this).parse.call(this, e); n < i.length; n++) {
  3887. var a = i[n], o = t(a);
  3888. Array.isArray(o) ? r.push.apply(r, o) : r.push(o)
  3889. }
  3890. return r
  3891. }
  3892. }
  3893. })
  3894. }, e
  3895. }(Kc), rl = function (t) {
  3896. function e(r) {
  3897. var n = t.call(this) || this;
  3898. return n.commands = "string" == typeof r ? e.parse(r) : r, n
  3899. }
  3900. return zc(e, t), e.prototype.encode = function () {
  3901. return e.encode(this.commands)
  3902. }, e.prototype.getBounds = function () {
  3903. var t = Yc.CALCULATE_BOUNDS();
  3904. return this.transform(t), t
  3905. }, e.prototype.transform = function (t) {
  3906. for (var e = [], r = 0, n = this.commands; r < n.length; r++) {
  3907. var i = t(n[r]);
  3908. Array.isArray(i) ? e.push.apply(e, i) : e.push(i)
  3909. }
  3910. return this.commands = e, this
  3911. }, e.encode = function (t) {
  3912. return function (t) {
  3913. var e = "";
  3914. Array.isArray(t) || (t = [t]);
  3915. for (var r = 0; r < t.length; r++) {
  3916. var n = t[r];
  3917. if (n.type === rl.CLOSE_PATH) e += "z"; else if (n.type === rl.HORIZ_LINE_TO) e += (n.relative ? "h" : "H") + n.x; else if (n.type === rl.VERT_LINE_TO) e += (n.relative ? "v" : "V") + n.y; else if (n.type === rl.MOVE_TO) e += (n.relative ? "m" : "M") + n.x + " " + n.y; else if (n.type === rl.LINE_TO) e += (n.relative ? "l" : "L") + n.x + " " + n.y; else if (n.type === rl.CURVE_TO) e += (n.relative ? "c" : "C") + n.x1 + " " + n.y1 + " " + n.x2 + " " + n.y2 + " " + n.x + " " + n.y; else if (n.type === rl.SMOOTH_CURVE_TO) e += (n.relative ? "s" : "S") + n.x2 + " " + n.y2 + " " + n.x + " " + n.y; else if (n.type === rl.QUAD_TO) e += (n.relative ? "q" : "Q") + n.x1 + " " + n.y1 + " " + n.x + " " + n.y; else if (n.type === rl.SMOOTH_QUAD_TO) e += (n.relative ? "t" : "T") + n.x + " " + n.y; else {
  3918. if (n.type !== rl.ARC) throw new Error('Unexpected command type "' + n.type + '" at index ' + r + ".");
  3919. e += (n.relative ? "a" : "A") + n.rX + " " + n.rY + " " + n.xRot + " " + +n.lArcFlag + " " + +n.sweepFlag + " " + n.x + " " + n.y
  3920. }
  3921. }
  3922. return e
  3923. }(t)
  3924. }, e.parse = function (t) {
  3925. var e = new el, r = [];
  3926. return e.parse(t, r), e.finish(r), r
  3927. }, e.CLOSE_PATH = 1, e.MOVE_TO = 2, e.HORIZ_LINE_TO = 4, e.VERT_LINE_TO = 8, e.LINE_TO = 16, e.CURVE_TO = 32, e.SMOOTH_CURVE_TO = 64, e.QUAD_TO = 128, e.SMOOTH_QUAD_TO = 256, e.ARC = 512, e.LINE_COMMANDS = e.LINE_TO | e.HORIZ_LINE_TO | e.VERT_LINE_TO, e.DRAWING_COMMANDS = e.HORIZ_LINE_TO | e.VERT_LINE_TO | e.LINE_TO | e.CURVE_TO | e.SMOOTH_CURVE_TO | e.QUAD_TO | e.SMOOTH_QUAD_TO | e.ARC, e
  3928. }(Kc),
  3929. nl = ((Zc = {})[rl.MOVE_TO] = 2, Zc[rl.LINE_TO] = 2, Zc[rl.HORIZ_LINE_TO] = 1, Zc[rl.VERT_LINE_TO] = 1, Zc[rl.CLOSE_PATH] = 0, Zc[rl.QUAD_TO] = 4, Zc[rl.SMOOTH_QUAD_TO] = 2, Zc[rl.CURVE_TO] = 6, Zc[rl.SMOOTH_CURVE_TO] = 4, Zc[rl.ARC] = 7, Zc);
  3930. function il(t) {
  3931. var e = function () {
  3932. if ("undefined" == typeof Reflect || !ys) return !1;
  3933. if (ys.sham) return !1;
  3934. if ("function" == typeof Proxy) return !0;
  3935. try {
  3936. return Date.prototype.toString.call(ys(Date, [], (function () {
  3937. }))), !0
  3938. } catch (t) {
  3939. return !1
  3940. }
  3941. }();
  3942. return function () {
  3943. var r, n = Os(t);
  3944. if (e) {
  3945. var i = Os(this).constructor;
  3946. r = ys(n, arguments, i)
  3947. } else r = n.apply(this, arguments);
  3948. return As(this, r)
  3949. }
  3950. }
  3951. var al = function (t) {
  3952. xs(r, t);
  3953. var e = il(r);
  3954. function r(t) {
  3955. var n;
  3956. return jo(this, r), (n = e.call(this, t.replace(/[+-.]\s+/g, "-").replace(/[^MmZzLlHhVvCcSsQqTtAae\d\s.,+-].*/g, ""))).control = null, n.start = null, n.current = null, n.command = null, n.commands = n.commands, n.i = -1, n.previousCommand = null, n.points = [], n.angles = [], n
  3957. }
  3958. return Fo(r, [{
  3959. key: "reset", value: function () {
  3960. this.i = -1, this.command = null, this.previousCommand = null, this.start = new rs(0, 0), this.control = new rs(0, 0), this.current = new rs(0, 0), this.points = [], this.angles = []
  3961. }
  3962. }, {
  3963. key: "isEnd", value: function () {
  3964. return this.i >= this.commands.length - 1
  3965. }
  3966. }, {
  3967. key: "next", value: function () {
  3968. var t = this.commands[++this.i];
  3969. return this.previousCommand = this.command, this.command = t, t
  3970. }
  3971. }, {
  3972. key: "getPoint", value: function () {
  3973. var t = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "x",
  3974. e = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : "y",
  3975. r = new rs(this.command[t], this.command[e]);
  3976. return this.makeAbsolute(r)
  3977. }
  3978. }, {
  3979. key: "getAsControlPoint", value: function (t, e) {
  3980. var r = this.getPoint(t, e);
  3981. return this.control = r, r
  3982. }
  3983. }, {
  3984. key: "getAsCurrentPoint", value: function (t, e) {
  3985. var r = this.getPoint(t, e);
  3986. return this.current = r, r
  3987. }
  3988. }, {
  3989. key: "getReflectedControlPoint", value: function () {
  3990. var t = this.previousCommand.type;
  3991. if (t !== rl.CURVE_TO && t !== rl.SMOOTH_CURVE_TO && t !== rl.QUAD_TO && t !== rl.SMOOTH_QUAD_TO) return this.current;
  3992. var e = this.current, r = e.x, n = e.y, i = this.control, a = i.x, o = i.y;
  3993. return new rs(2 * r - a, 2 * n - o)
  3994. }
  3995. }, {
  3996. key: "makeAbsolute", value: function (t) {
  3997. if (this.command.relative) {
  3998. var e = this.current, r = e.x, n = e.y;
  3999. t.x += r, t.y += n
  4000. }
  4001. return t
  4002. }
  4003. }, {
  4004. key: "addMarker", value: function (t, e, r) {
  4005. var n = this.points, i = this.angles;
  4006. r && i.length > 0 && !i[i.length - 1] && (i[i.length - 1] = n[n.length - 1].angleTo(r)), this.addMarkerAngle(t, e ? e.angleTo(t) : null)
  4007. }
  4008. }, {
  4009. key: "addMarkerAngle", value: function (t, e) {
  4010. this.points.push(t), this.angles.push(e)
  4011. }
  4012. }, {
  4013. key: "getMarkerPoints", value: function () {
  4014. return this.points
  4015. }
  4016. }, {
  4017. key: "getMarkerAngles", value: function () {
  4018. for (var t = this.angles, e = t.length, r = 0; r < e; r++) if (!t[r]) for (var n = r + 1; n < e; n++) if (t[n]) {
  4019. t[r] = t[n];
  4020. break
  4021. }
  4022. return t
  4023. }
  4024. }]), r
  4025. }(rl);
  4026. function ol(t) {
  4027. var e = function () {
  4028. if ("undefined" == typeof Reflect || !ys) return !1;
  4029. if (ys.sham) return !1;
  4030. if ("function" == typeof Proxy) return !0;
  4031. try {
  4032. return Date.prototype.toString.call(ys(Date, [], (function () {
  4033. }))), !0
  4034. } catch (t) {
  4035. return !1
  4036. }
  4037. }();
  4038. return function () {
  4039. var r, n = Os(t);
  4040. if (e) {
  4041. var i = Os(this).constructor;
  4042. r = ys(n, arguments, i)
  4043. } else r = n.apply(this, arguments);
  4044. return As(this, r)
  4045. }
  4046. }
  4047. var ul = function (t) {
  4048. xs(r, t);
  4049. var e = ol(r);
  4050. function r(t, n, i) {
  4051. var a;
  4052. return jo(this, r), (a = e.call(this, t, n, i)).type = "path", a.pathParser = null, a.pathParser = new al(a.getAttribute("d").getString()), a
  4053. }
  4054. return Fo(r, [{
  4055. key: "path", value: function (t) {
  4056. var e = this.pathParser, r = new Oc;
  4057. for (e.reset(), t && t.beginPath(); !e.isEnd();) switch (e.next().type) {
  4058. case al.MOVE_TO:
  4059. this.pathM(t, r);
  4060. break;
  4061. case al.LINE_TO:
  4062. this.pathL(t, r);
  4063. break;
  4064. case al.HORIZ_LINE_TO:
  4065. this.pathH(t, r);
  4066. break;
  4067. case al.VERT_LINE_TO:
  4068. this.pathV(t, r);
  4069. break;
  4070. case al.CURVE_TO:
  4071. this.pathC(t, r);
  4072. break;
  4073. case al.SMOOTH_CURVE_TO:
  4074. this.pathS(t, r);
  4075. break;
  4076. case al.QUAD_TO:
  4077. this.pathQ(t, r);
  4078. break;
  4079. case al.SMOOTH_QUAD_TO:
  4080. this.pathT(t, r);
  4081. break;
  4082. case al.ARC:
  4083. this.pathA(t, r);
  4084. break;
  4085. case al.CLOSE_PATH:
  4086. this.pathZ(t, r)
  4087. }
  4088. return r
  4089. }
  4090. }, {
  4091. key: "getBoundingBox", value: function (t) {
  4092. return this.path()
  4093. }
  4094. }, {
  4095. key: "getMarkers", value: function () {
  4096. var t = this.pathParser, e = t.getMarkerPoints(), r = t.getMarkerAngles();
  4097. return ee(e).call(e, (function (t, e) {
  4098. return [t, r[e]]
  4099. }))
  4100. }
  4101. }, {
  4102. key: "renderChildren", value: function (t) {
  4103. this.path(t), this.document.screen.mouse.checkPath(this, t);
  4104. var e = this.getStyle("fill-rule");
  4105. "" !== t.fillStyle && ("inherit" !== e.getString("inherit") ? Ic(t).call(t, e.getString()) : Ic(t).call(t)), "" !== t.strokeStyle && t.stroke();
  4106. var r = this.getMarkers();
  4107. if (r) {
  4108. var n = r.length - 1, i = this.getStyle("marker-start"), a = this.getStyle("marker-mid"),
  4109. o = this.getStyle("marker-end");
  4110. if (i.isUrlDefinition()) {
  4111. var u = i.getDefinition(), s = ci(r[0], 2), c = s[0], l = s[1];
  4112. u.render(t, c, l)
  4113. }
  4114. if (a.isUrlDefinition()) for (var f = a.getDefinition(), h = 1; h < n; h++) {
  4115. var p = ci(r[h], 2), y = p[0], v = p[1];
  4116. f.render(t, y, v)
  4117. }
  4118. if (o.isUrlDefinition()) {
  4119. var g = o.getDefinition(), d = ci(r[n], 2), m = d[0], x = d[1];
  4120. g.render(t, m, x)
  4121. }
  4122. }
  4123. }
  4124. }, {
  4125. key: "pathM", value: function (t, e) {
  4126. var n = this.pathParser, i = r.pathM(n).point, a = i.x, o = i.y;
  4127. n.addMarker(i), e.addPoint(a, o), t && t.moveTo(a, o)
  4128. }
  4129. }, {
  4130. key: "pathL", value: function (t, e) {
  4131. var n = this.pathParser, i = r.pathL(n), a = i.current, o = i.point, u = o.x, s = o.y;
  4132. n.addMarker(o, a), e.addPoint(u, s), t && t.lineTo(u, s)
  4133. }
  4134. }, {
  4135. key: "pathH", value: function (t, e) {
  4136. var n = this.pathParser, i = r.pathH(n), a = i.current, o = i.point, u = o.x, s = o.y;
  4137. n.addMarker(o, a), e.addPoint(u, s), t && t.lineTo(u, s)
  4138. }
  4139. }, {
  4140. key: "pathV", value: function (t, e) {
  4141. var n = this.pathParser, i = r.pathV(n), a = i.current, o = i.point, u = o.x, s = o.y;
  4142. n.addMarker(o, a), e.addPoint(u, s), t && t.lineTo(u, s)
  4143. }
  4144. }, {
  4145. key: "pathC", value: function (t, e) {
  4146. var n = this.pathParser, i = r.pathC(n), a = i.current, o = i.point, u = i.controlPoint,
  4147. s = i.currentPoint;
  4148. n.addMarker(s, u, o), e.addBezierCurve(a.x, a.y, o.x, o.y, u.x, u.y, s.x, s.y), t && t.bezierCurveTo(o.x, o.y, u.x, u.y, s.x, s.y)
  4149. }
  4150. }, {
  4151. key: "pathS", value: function (t, e) {
  4152. var n = this.pathParser, i = r.pathS(n), a = i.current, o = i.point, u = i.controlPoint,
  4153. s = i.currentPoint;
  4154. n.addMarker(s, u, o), e.addBezierCurve(a.x, a.y, o.x, o.y, u.x, u.y, s.x, s.y), t && t.bezierCurveTo(o.x, o.y, u.x, u.y, s.x, s.y)
  4155. }
  4156. }, {
  4157. key: "pathQ", value: function (t, e) {
  4158. var n = this.pathParser, i = r.pathQ(n), a = i.current, o = i.controlPoint, u = i.currentPoint;
  4159. n.addMarker(u, o, o), e.addQuadraticCurve(a.x, a.y, o.x, o.y, u.x, u.y), t && t.quadraticCurveTo(o.x, o.y, u.x, u.y)
  4160. }
  4161. }, {
  4162. key: "pathT", value: function (t, e) {
  4163. var n = this.pathParser, i = r.pathT(n), a = i.current, o = i.controlPoint, u = i.currentPoint;
  4164. n.addMarker(u, o, o), e.addQuadraticCurve(a.x, a.y, o.x, o.y, u.x, u.y), t && t.quadraticCurveTo(o.x, o.y, u.x, u.y)
  4165. }
  4166. }, {
  4167. key: "pathA", value: function (t, e) {
  4168. var n = this.pathParser, i = r.pathA(n), a = i.currentPoint, o = i.rX, u = i.rY, s = i.sweepFlag,
  4169. c = i.xAxisRotation, l = i.centp, f = i.a1, h = i.ad, p = 1 - s ? 1 : -1, y = f + p * (h / 2),
  4170. v = new rs(l.x + o * Math.cos(y), l.y + u * Math.sin(y));
  4171. if (n.addMarkerAngle(v, y - p * Math.PI / 2), n.addMarkerAngle(a, y - p * Math.PI), e.addPoint(a.x, a.y), t && !isNaN(f) && !isNaN(h)) {
  4172. var g = o > u ? o : u, d = o > u ? 1 : o / u, m = o > u ? u / o : 1;
  4173. t.translate(l.x, l.y), t.rotate(c), t.scale(d, m), t.arc(0, 0, g, f, f + h, Boolean(1 - s)), t.scale(1 / d, 1 / m), t.rotate(-c), t.translate(-l.x, -l.y)
  4174. }
  4175. }
  4176. }, {
  4177. key: "pathZ", value: function (t, e) {
  4178. r.pathZ(this.pathParser), t && e.x1 !== e.x2 && e.y1 !== e.y2 && t.closePath()
  4179. }
  4180. }], [{
  4181. key: "pathM", value: function (t) {
  4182. var e = t.getAsCurrentPoint();
  4183. return t.start = t.current, {point: e}
  4184. }
  4185. }, {
  4186. key: "pathL", value: function (t) {
  4187. return {current: t.current, point: t.getAsCurrentPoint()}
  4188. }
  4189. }, {
  4190. key: "pathH", value: function (t) {
  4191. var e = t.current, r = t.command, n = new rs((r.relative ? e.x : 0) + r.x, e.y);
  4192. return t.current = n, {current: e, point: n}
  4193. }
  4194. }, {
  4195. key: "pathV", value: function (t) {
  4196. var e = t.current, r = t.command, n = new rs(e.x, (r.relative ? e.y : 0) + r.y);
  4197. return t.current = n, {current: e, point: n}
  4198. }
  4199. }, {
  4200. key: "pathC", value: function (t) {
  4201. return {
  4202. current: t.current,
  4203. point: t.getPoint("x1", "y1"),
  4204. controlPoint: t.getAsControlPoint("x2", "y2"),
  4205. currentPoint: t.getAsCurrentPoint()
  4206. }
  4207. }
  4208. }, {
  4209. key: "pathS", value: function (t) {
  4210. return {
  4211. current: t.current,
  4212. point: t.getReflectedControlPoint(),
  4213. controlPoint: t.getAsControlPoint("x2", "y2"),
  4214. currentPoint: t.getAsCurrentPoint()
  4215. }
  4216. }
  4217. }, {
  4218. key: "pathQ", value: function (t) {
  4219. return {
  4220. current: t.current,
  4221. controlPoint: t.getAsControlPoint("x1", "y1"),
  4222. currentPoint: t.getAsCurrentPoint()
  4223. }
  4224. }
  4225. }, {
  4226. key: "pathT", value: function (t) {
  4227. var e = t.current, r = t.getReflectedControlPoint();
  4228. return t.control = r, {current: e, controlPoint: r, currentPoint: t.getAsCurrentPoint()}
  4229. }
  4230. }, {
  4231. key: "pathA", value: function (t) {
  4232. var e = t.current, r = t.command, n = r.rX, i = r.rY, a = r.xRot, o = r.lArcFlag, u = r.sweepFlag,
  4233. s = a * (Math.PI / 180), c = t.getAsCurrentPoint(),
  4234. l = new rs(Math.cos(s) * (e.x - c.x) / 2 + Math.sin(s) * (e.y - c.y) / 2, -Math.sin(s) * (e.x - c.x) / 2 + Math.cos(s) * (e.y - c.y) / 2),
  4235. f = Math.pow(l.x, 2) / Math.pow(n, 2) + Math.pow(l.y, 2) / Math.pow(i, 2);
  4236. f > 1 && (n *= Math.sqrt(f), i *= Math.sqrt(f));
  4237. var h = (o === u ? -1 : 1) * Math.sqrt((Math.pow(n, 2) * Math.pow(i, 2) - Math.pow(n, 2) * Math.pow(l.y, 2) - Math.pow(i, 2) * Math.pow(l.x, 2)) / (Math.pow(n, 2) * Math.pow(l.y, 2) + Math.pow(i, 2) * Math.pow(l.x, 2)));
  4238. isNaN(h) && (h = 0);
  4239. var p = new rs(h * n * l.y / i, h * -i * l.x / n),
  4240. y = new rs((e.x + c.x) / 2 + Math.cos(s) * p.x - Math.sin(s) * p.y, (e.y + c.y) / 2 + Math.sin(s) * p.x + Math.cos(s) * p.y),
  4241. v = Si([1, 0], [(l.x - p.x) / n, (l.y - p.y) / i]), g = [(l.x - p.x) / n, (l.y - p.y) / i],
  4242. d = [(-l.x - p.x) / n, (-l.y - p.y) / i], m = Si(g, d);
  4243. return wi(g, d) <= -1 && (m = Math.PI), wi(g, d) >= 1 && (m = 0), {
  4244. currentPoint: c,
  4245. rX: n,
  4246. rY: i,
  4247. sweepFlag: u,
  4248. xAxisRotation: s,
  4249. centp: y,
  4250. a1: v,
  4251. ad: m
  4252. }
  4253. }
  4254. }, {
  4255. key: "pathZ", value: function (t) {
  4256. t.current = t.start
  4257. }
  4258. }]), r
  4259. }(Ec);
  4260. function sl(t) {
  4261. var e = function () {
  4262. if ("undefined" == typeof Reflect || !ys) return !1;
  4263. if (ys.sham) return !1;
  4264. if ("function" == typeof Proxy) return !0;
  4265. try {
  4266. return Date.prototype.toString.call(ys(Date, [], (function () {
  4267. }))), !0
  4268. } catch (t) {
  4269. return !1
  4270. }
  4271. }();
  4272. return function () {
  4273. var r, n = Os(t);
  4274. if (e) {
  4275. var i = Os(this).constructor;
  4276. r = ys(n, arguments, i)
  4277. } else r = n.apply(this, arguments);
  4278. return As(this, r)
  4279. }
  4280. }
  4281. var cl = function (t) {
  4282. xs(r, t);
  4283. var e = sl(r);
  4284. function r() {
  4285. var t;
  4286. return jo(this, r), (t = e.apply(this, arguments)).type = "svg", t.root = !1, t
  4287. }
  4288. return Fo(r, [{
  4289. key: "setContext", value: function (t) {
  4290. var e = this.document, n = e.screen, i = e.window, a = t.canvas;
  4291. if (n.setDefaults(t), a.style && void 0 !== t.font && i && void 0 !== i.getComputedStyle) {
  4292. t.font = i.getComputedStyle(a).getPropertyValue("font");
  4293. var o = new ts(e, "fontSize", Tc.parse(t.font).fontSize);
  4294. o.hasValue() && (e.rootEmSize = o.getPixels("y"), e.emSize = e.rootEmSize)
  4295. }
  4296. this.getAttribute("x").hasValue() || this.getAttribute("x", !0).setValue(0), this.getAttribute("y").hasValue() || this.getAttribute("y", !0).setValue(0);
  4297. var u = n.viewPort, s = u.width, c = u.height;
  4298. this.getStyle("width").hasValue() || this.getStyle("width", !0).setValue("100%"), this.getStyle("height").hasValue() || this.getStyle("height", !0).setValue("100%"), this.getStyle("color").hasValue() || this.getStyle("color", !0).setValue("black");
  4299. var l = this.getAttribute("refX"), f = this.getAttribute("refY"), h = this.getAttribute("viewBox"),
  4300. p = h.hasValue() ? ae(h.getString()) : null,
  4301. y = !this.root && "visible" !== this.getStyle("overflow").getValue("hidden"), v = 0, g = 0, d = 0,
  4302. m = 0;
  4303. p && (v = p[0], g = p[1]), this.root || (s = this.getStyle("width").getPixels("x"), c = this.getStyle("height").getPixels("y"), "marker" === this.type && (d = v, m = g, v = 0, g = 0)), n.viewPort.setCurrent(s, c), this.node && this.getStyle("transform", !1, !0).hasValue() && !this.getStyle("transform-origin", !1, !0).hasValue() && this.getStyle("transform-origin", !0, !0).setValue("50% 50%"), wc(Os(r.prototype), "setContext", this).call(this, t), t.translate(this.getAttribute("x").getPixels("x"), this.getAttribute("y").getPixels("y")), p && (s = p[2], c = p[3]), e.setViewBox({
  4304. ctx: t,
  4305. aspectRatio: this.getAttribute("preserveAspectRatio").getString(),
  4306. width: n.viewPort.width,
  4307. desiredWidth: s,
  4308. height: n.viewPort.height,
  4309. desiredHeight: c,
  4310. minX: v,
  4311. minY: g,
  4312. refX: l.getValue(),
  4313. refY: f.getValue(),
  4314. clip: y,
  4315. clipX: d,
  4316. clipY: m
  4317. }), p && (n.viewPort.removeCurrent(), n.viewPort.setCurrent(s, c))
  4318. }
  4319. }, {
  4320. key: "clearContext", value: function (t) {
  4321. wc(Os(r.prototype), "clearContext", this).call(this, t), this.document.screen.viewPort.removeCurrent()
  4322. }
  4323. }, {
  4324. key: "resize", value: function (t) {
  4325. var e, r = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : t,
  4326. n = arguments.length > 2 && void 0 !== arguments[2] && arguments[2],
  4327. i = this.getAttribute("width", !0), a = this.getAttribute("height", !0),
  4328. o = this.getAttribute("viewBox"), u = this.getAttribute("style"), s = i.getNumber(0),
  4329. c = a.getNumber(0);
  4330. if (n) if ("string" == typeof n) this.getAttribute("preserveAspectRatio", !0).setValue(n); else {
  4331. var l = this.getAttribute("preserveAspectRatio");
  4332. l.hasValue() && l.setValue(l.getString().replace(/^\s*(\S.*\S)\s*$/, "$1"))
  4333. }
  4334. (i.setValue(t), a.setValue(r), o.hasValue()) || o.setValue(Ho(e = "0 0 ".concat(s || t, " ")).call(e, c || r));
  4335. if (u.hasValue()) {
  4336. var f = this.getStyle("width"), h = this.getStyle("height");
  4337. f.hasValue() && f.setValue("".concat(t, "px")), h.hasValue() && h.setValue("".concat(r, "px"))
  4338. }
  4339. }
  4340. }]), r
  4341. }(Ec);
  4342. function ll(t) {
  4343. var e = function () {
  4344. if ("undefined" == typeof Reflect || !ys) return !1;
  4345. if (ys.sham) return !1;
  4346. if ("function" == typeof Proxy) return !0;
  4347. try {
  4348. return Date.prototype.toString.call(ys(Date, [], (function () {
  4349. }))), !0
  4350. } catch (t) {
  4351. return !1
  4352. }
  4353. }();
  4354. return function () {
  4355. var r, n = Os(t);
  4356. if (e) {
  4357. var i = Os(this).constructor;
  4358. r = ys(n, arguments, i)
  4359. } else r = n.apply(this, arguments);
  4360. return As(this, r)
  4361. }
  4362. }
  4363. var fl = function (t) {
  4364. xs(r, t);
  4365. var e = ll(r);
  4366. function r() {
  4367. var t;
  4368. return jo(this, r), (t = e.apply(this, arguments)).type = "rect", t
  4369. }
  4370. return Fo(r, [{
  4371. key: "path", value: function (t) {
  4372. var e = this.getAttribute("x").getPixels("x"), r = this.getAttribute("y").getPixels("y"),
  4373. n = this.getStyle("width", !1, !0).getPixels("x"),
  4374. i = this.getStyle("height", !1, !0).getPixels("y"), a = this.getAttribute("rx"),
  4375. o = this.getAttribute("ry"), u = a.getPixels("x"), s = o.getPixels("y");
  4376. if (a.hasValue() && !o.hasValue() && (s = u), o.hasValue() && !a.hasValue() && (u = s), u = Math.min(u, n / 2), s = Math.min(s, i / 2), t) {
  4377. var c = (Math.sqrt(2) - 1) / 3 * 4;
  4378. t.beginPath(), i > 0 && n > 0 && (t.moveTo(e + u, r), t.lineTo(e + n - u, r), t.bezierCurveTo(e + n - u + c * u, r, e + n, r + s - c * s, e + n, r + s), t.lineTo(e + n, r + i - s), t.bezierCurveTo(e + n, r + i - s + c * s, e + n - u + c * u, r + i, e + n - u, r + i), t.lineTo(e + u, r + i), t.bezierCurveTo(e + u - c * u, r + i, e, r + i - s + c * s, e, r + i - s), t.lineTo(e, r + s), t.bezierCurveTo(e, r + s - c * s, e + u - c * u, r, e + u, r), t.closePath())
  4379. }
  4380. return new Oc(e, r, e + n, r + i)
  4381. }
  4382. }, {
  4383. key: "getMarkers", value: function () {
  4384. return null
  4385. }
  4386. }]), r
  4387. }(ul);
  4388. function hl(t) {
  4389. var e = function () {
  4390. if ("undefined" == typeof Reflect || !ys) return !1;
  4391. if (ys.sham) return !1;
  4392. if ("function" == typeof Proxy) return !0;
  4393. try {
  4394. return Date.prototype.toString.call(ys(Date, [], (function () {
  4395. }))), !0
  4396. } catch (t) {
  4397. return !1
  4398. }
  4399. }();
  4400. return function () {
  4401. var r, n = Os(t);
  4402. if (e) {
  4403. var i = Os(this).constructor;
  4404. r = ys(n, arguments, i)
  4405. } else r = n.apply(this, arguments);
  4406. return As(this, r)
  4407. }
  4408. }
  4409. var pl = function (t) {
  4410. xs(r, t);
  4411. var e = hl(r);
  4412. function r() {
  4413. var t;
  4414. return jo(this, r), (t = e.apply(this, arguments)).type = "circle", t
  4415. }
  4416. return Fo(r, [{
  4417. key: "path", value: function (t) {
  4418. var e = this.getAttribute("cx").getPixels("x"), r = this.getAttribute("cy").getPixels("y"),
  4419. n = this.getAttribute("r").getPixels();
  4420. return t && n > 0 && (t.beginPath(), t.arc(e, r, n, 0, 2 * Math.PI, !1), t.closePath()), new Oc(e - n, r - n, e + n, r + n)
  4421. }
  4422. }, {
  4423. key: "getMarkers", value: function () {
  4424. return null
  4425. }
  4426. }]), r
  4427. }(ul);
  4428. function yl(t) {
  4429. var e = function () {
  4430. if ("undefined" == typeof Reflect || !ys) return !1;
  4431. if (ys.sham) return !1;
  4432. if ("function" == typeof Proxy) return !0;
  4433. try {
  4434. return Date.prototype.toString.call(ys(Date, [], (function () {
  4435. }))), !0
  4436. } catch (t) {
  4437. return !1
  4438. }
  4439. }();
  4440. return function () {
  4441. var r, n = Os(t);
  4442. if (e) {
  4443. var i = Os(this).constructor;
  4444. r = ys(n, arguments, i)
  4445. } else r = n.apply(this, arguments);
  4446. return As(this, r)
  4447. }
  4448. }
  4449. var vl = function (t) {
  4450. xs(r, t);
  4451. var e = yl(r);
  4452. function r() {
  4453. var t;
  4454. return jo(this, r), (t = e.apply(this, arguments)).type = "ellipse", t
  4455. }
  4456. return Fo(r, [{
  4457. key: "path", value: function (t) {
  4458. var e = (Math.sqrt(2) - 1) / 3 * 4, r = this.getAttribute("rx").getPixels("x"),
  4459. n = this.getAttribute("ry").getPixels("y"), i = this.getAttribute("cx").getPixels("x"),
  4460. a = this.getAttribute("cy").getPixels("y");
  4461. return t && r > 0 && n > 0 && (t.beginPath(), t.moveTo(i + r, a), t.bezierCurveTo(i + r, a + e * n, i + e * r, a + n, i, a + n), t.bezierCurveTo(i - e * r, a + n, i - r, a + e * n, i - r, a), t.bezierCurveTo(i - r, a - e * n, i - e * r, a - n, i, a - n), t.bezierCurveTo(i + e * r, a - n, i + r, a - e * n, i + r, a), t.closePath()), new Oc(i - r, a - n, i + r, a + n)
  4462. }
  4463. }, {
  4464. key: "getMarkers", value: function () {
  4465. return null
  4466. }
  4467. }]), r
  4468. }(ul);
  4469. function gl(t) {
  4470. var e = function () {
  4471. if ("undefined" == typeof Reflect || !ys) return !1;
  4472. if (ys.sham) return !1;
  4473. if ("function" == typeof Proxy) return !0;
  4474. try {
  4475. return Date.prototype.toString.call(ys(Date, [], (function () {
  4476. }))), !0
  4477. } catch (t) {
  4478. return !1
  4479. }
  4480. }();
  4481. return function () {
  4482. var r, n = Os(t);
  4483. if (e) {
  4484. var i = Os(this).constructor;
  4485. r = ys(n, arguments, i)
  4486. } else r = n.apply(this, arguments);
  4487. return As(this, r)
  4488. }
  4489. }
  4490. var dl = function (t) {
  4491. xs(r, t);
  4492. var e = gl(r);
  4493. function r() {
  4494. var t;
  4495. return jo(this, r), (t = e.apply(this, arguments)).type = "line", t
  4496. }
  4497. return Fo(r, [{
  4498. key: "getPoints", value: function () {
  4499. return [new rs(this.getAttribute("x1").getPixels("x"), this.getAttribute("y1").getPixels("y")), new rs(this.getAttribute("x2").getPixels("x"), this.getAttribute("y2").getPixels("y"))]
  4500. }
  4501. }, {
  4502. key: "path", value: function (t) {
  4503. var e = this.getPoints(), r = ci(e, 2), n = r[0], i = n.x, a = n.y, o = r[1], u = o.x, s = o.y;
  4504. return t && (t.beginPath(), t.moveTo(i, a), t.lineTo(u, s)), new Oc(i, a, u, s)
  4505. }
  4506. }, {
  4507. key: "getMarkers", value: function () {
  4508. var t = this.getPoints(), e = ci(t, 2), r = e[0], n = e[1], i = r.angleTo(n);
  4509. return [[r, i], [n, i]]
  4510. }
  4511. }]), r
  4512. }(ul);
  4513. function ml(t) {
  4514. var e = function () {
  4515. if ("undefined" == typeof Reflect || !ys) return !1;
  4516. if (ys.sham) return !1;
  4517. if ("function" == typeof Proxy) return !0;
  4518. try {
  4519. return Date.prototype.toString.call(ys(Date, [], (function () {
  4520. }))), !0
  4521. } catch (t) {
  4522. return !1
  4523. }
  4524. }();
  4525. return function () {
  4526. var r, n = Os(t);
  4527. if (e) {
  4528. var i = Os(this).constructor;
  4529. r = ys(n, arguments, i)
  4530. } else r = n.apply(this, arguments);
  4531. return As(this, r)
  4532. }
  4533. }
  4534. var xl = function (t) {
  4535. xs(r, t);
  4536. var e = ml(r);
  4537. function r(t, n, i) {
  4538. var a;
  4539. return jo(this, r), (a = e.call(this, t, n, i)).type = "polyline", a.points = [], a.points = rs.parsePath(a.getAttribute("points").getString()), a
  4540. }
  4541. return Fo(r, [{
  4542. key: "path", value: function (t) {
  4543. var e = this.points, r = ci(e, 1)[0], n = r.x, i = r.y, a = new Oc(n, i);
  4544. return t && (t.beginPath(), t.moveTo(n, i)), Hi(e).call(e, (function (e) {
  4545. var r = e.x, n = e.y;
  4546. a.addPoint(r, n), t && t.lineTo(r, n)
  4547. })), a
  4548. }
  4549. }, {
  4550. key: "getMarkers", value: function () {
  4551. var t = this.points, e = t.length - 1, r = [];
  4552. return Hi(t).call(t, (function (n, i) {
  4553. i !== e && r.push([n, n.angleTo(t[i + 1])])
  4554. })), r.length > 0 && r.push([t[t.length - 1], r[r.length - 1][1]]), r
  4555. }
  4556. }]), r
  4557. }(ul);
  4558. function bl(t) {
  4559. var e = function () {
  4560. if ("undefined" == typeof Reflect || !ys) return !1;
  4561. if (ys.sham) return !1;
  4562. if ("function" == typeof Proxy) return !0;
  4563. try {
  4564. return Date.prototype.toString.call(ys(Date, [], (function () {
  4565. }))), !0
  4566. } catch (t) {
  4567. return !1
  4568. }
  4569. }();
  4570. return function () {
  4571. var r, n = Os(t);
  4572. if (e) {
  4573. var i = Os(this).constructor;
  4574. r = ys(n, arguments, i)
  4575. } else r = n.apply(this, arguments);
  4576. return As(this, r)
  4577. }
  4578. }
  4579. var wl = function (t) {
  4580. xs(r, t);
  4581. var e = bl(r);
  4582. function r() {
  4583. var t;
  4584. return jo(this, r), (t = e.apply(this, arguments)).type = "polygon", t
  4585. }
  4586. return Fo(r, [{
  4587. key: "path", value: function (t) {
  4588. var e = wc(Os(r.prototype), "path", this).call(this, t), n = ci(this.points, 1)[0], i = n.x, a = n.y;
  4589. return t && (t.lineTo(i, a), t.closePath()), e
  4590. }
  4591. }]), r
  4592. }(xl), Sl = O.f;
  4593. H({target: "Reflect", stat: !0}, {
  4594. deleteProperty: function (t, e) {
  4595. var r = Sl(I(t), e);
  4596. return !(r && !r.configurable) && delete t[e]
  4597. }
  4598. });
  4599. var Al = D.Reflect.deleteProperty;
  4600. function kl(t) {
  4601. var e = function () {
  4602. if ("undefined" == typeof Reflect || !ys) return !1;
  4603. if (ys.sham) return !1;
  4604. if ("function" == typeof Proxy) return !0;
  4605. try {
  4606. return Date.prototype.toString.call(ys(Date, [], (function () {
  4607. }))), !0
  4608. } catch (t) {
  4609. return !1
  4610. }
  4611. }();
  4612. return function () {
  4613. var r, n = Os(t);
  4614. if (e) {
  4615. var i = Os(this).constructor;
  4616. r = ys(n, arguments, i)
  4617. } else r = n.apply(this, arguments);
  4618. return As(this, r)
  4619. }
  4620. }
  4621. var Tl = function (t) {
  4622. xs(r, t);
  4623. var e = kl(r);
  4624. function r() {
  4625. var t;
  4626. return jo(this, r), (t = e.apply(this, arguments)).type = "pattern", t
  4627. }
  4628. return Fo(r, [{
  4629. key: "createPattern", value: function (t, e, r) {
  4630. var n = this.getStyle("width").getPixels("x", !0), i = this.getStyle("height").getPixels("y", !0),
  4631. a = new cl(this.document, null);
  4632. a.attributes.viewBox = new ts(this.document, "viewBox", this.getAttribute("viewBox").getValue()), a.attributes.width = new ts(this.document, "width", "".concat(n, "px")), a.attributes.height = new ts(this.document, "height", "".concat(i, "px")), a.attributes.transform = new ts(this.document, "transform", this.getAttribute("patternTransform").getValue()), a.children = this.children;
  4633. var o = this.document.createCanvas(n, i), u = o.getContext("2d"), s = this.getAttribute("x"),
  4634. c = this.getAttribute("y");
  4635. s.hasValue() && c.hasValue() && u.translate(s.getPixels("x", !0), c.getPixels("y", !0)), r.hasValue() ? this.styles["fill-opacity"] = r : Al(this.styles, "fill-opacity");
  4636. for (var l = -1; l <= 1; l++) for (var f = -1; f <= 1; f++) u.save(), a.attributes.x = new ts(this.document, "x", l * o.width), a.attributes.y = new ts(this.document, "y", f * o.height), a.render(u), u.restore();
  4637. return t.createPattern(o, "repeat")
  4638. }
  4639. }]), r
  4640. }(rc);
  4641. function Ol(t) {
  4642. var e = function () {
  4643. if ("undefined" == typeof Reflect || !ys) return !1;
  4644. if (ys.sham) return !1;
  4645. if ("function" == typeof Proxy) return !0;
  4646. try {
  4647. return Date.prototype.toString.call(ys(Date, [], (function () {
  4648. }))), !0
  4649. } catch (t) {
  4650. return !1
  4651. }
  4652. }();
  4653. return function () {
  4654. var r, n = Os(t);
  4655. if (e) {
  4656. var i = Os(this).constructor;
  4657. r = ys(n, arguments, i)
  4658. } else r = n.apply(this, arguments);
  4659. return As(this, r)
  4660. }
  4661. }
  4662. var Pl = function (t) {
  4663. xs(r, t);
  4664. var e = Ol(r);
  4665. function r() {
  4666. var t;
  4667. return jo(this, r), (t = e.apply(this, arguments)).type = "marker", t
  4668. }
  4669. return Fo(r, [{
  4670. key: "render", value: function (t, e, r) {
  4671. if (e) {
  4672. var n = e.x, i = e.y, a = this.getAttribute("orient").getValue("auto"),
  4673. o = this.getAttribute("markerUnits").getValue("strokeWidth");
  4674. t.translate(n, i), "auto" === a && t.rotate(r), "strokeWidth" === o && t.scale(t.lineWidth, t.lineWidth), t.save();
  4675. var u = new cl(this.document, null);
  4676. u.type = this.type, u.attributes.viewBox = new ts(this.document, "viewBox", this.getAttribute("viewBox").getValue()), u.attributes.refX = new ts(this.document, "refX", this.getAttribute("refX").getValue()), u.attributes.refY = new ts(this.document, "refY", this.getAttribute("refY").getValue()), u.attributes.width = new ts(this.document, "width", this.getAttribute("markerWidth").getValue()), u.attributes.height = new ts(this.document, "height", this.getAttribute("markerHeight").getValue()), u.attributes.overflow = new ts(this.document, "overflow", this.getAttribute("overflow").getValue()), u.attributes.fill = new ts(this.document, "fill", this.getAttribute("fill").getColor("black")), u.attributes.stroke = new ts(this.document, "stroke", this.getAttribute("stroke").getValue("none")), u.children = this.children, u.render(t), t.restore(), "strokeWidth" === o && t.scale(1 / t.lineWidth, 1 / t.lineWidth), "auto" === a && t.rotate(-r), t.translate(-n, -i)
  4677. }
  4678. }
  4679. }]), r
  4680. }(rc);
  4681. function El(t) {
  4682. var e = function () {
  4683. if ("undefined" == typeof Reflect || !ys) return !1;
  4684. if (ys.sham) return !1;
  4685. if ("function" == typeof Proxy) return !0;
  4686. try {
  4687. return Date.prototype.toString.call(ys(Date, [], (function () {
  4688. }))), !0
  4689. } catch (t) {
  4690. return !1
  4691. }
  4692. }();
  4693. return function () {
  4694. var r, n = Os(t);
  4695. if (e) {
  4696. var i = Os(this).constructor;
  4697. r = ys(n, arguments, i)
  4698. } else r = n.apply(this, arguments);
  4699. return As(this, r)
  4700. }
  4701. }
  4702. var Cl = function (t) {
  4703. xs(r, t);
  4704. var e = El(r);
  4705. function r() {
  4706. var t;
  4707. return jo(this, r), (t = e.apply(this, arguments)).type = "defs", t
  4708. }
  4709. return Fo(r, [{
  4710. key: "render", value: function () {
  4711. }
  4712. }]), r
  4713. }(rc);
  4714. function Ml(t) {
  4715. var e = function () {
  4716. if ("undefined" == typeof Reflect || !ys) return !1;
  4717. if (ys.sham) return !1;
  4718. if ("function" == typeof Proxy) return !0;
  4719. try {
  4720. return Date.prototype.toString.call(ys(Date, [], (function () {
  4721. }))), !0
  4722. } catch (t) {
  4723. return !1
  4724. }
  4725. }();
  4726. return function () {
  4727. var r, n = Os(t);
  4728. if (e) {
  4729. var i = Os(this).constructor;
  4730. r = ys(n, arguments, i)
  4731. } else r = n.apply(this, arguments);
  4732. return As(this, r)
  4733. }
  4734. }
  4735. var Nl = function (t) {
  4736. xs(r, t);
  4737. var e = Ml(r);
  4738. function r() {
  4739. var t;
  4740. return jo(this, r), (t = e.apply(this, arguments)).type = "g", t
  4741. }
  4742. return Fo(r, [{
  4743. key: "getBoundingBox", value: function (t) {
  4744. var e, r = new Oc;
  4745. return Hi(e = this.children).call(e, (function (e) {
  4746. r.addBoundingBox(e.getBoundingBox(t))
  4747. })), r
  4748. }
  4749. }]), r
  4750. }(Ec);
  4751. function Rl(t) {
  4752. var e = function () {
  4753. if ("undefined" == typeof Reflect || !ys) return !1;
  4754. if (ys.sham) return !1;
  4755. if ("function" == typeof Proxy) return !0;
  4756. try {
  4757. return Date.prototype.toString.call(ys(Date, [], (function () {
  4758. }))), !0
  4759. } catch (t) {
  4760. return !1
  4761. }
  4762. }();
  4763. return function () {
  4764. var r, n = Os(t);
  4765. if (e) {
  4766. var i = Os(this).constructor;
  4767. r = ys(n, arguments, i)
  4768. } else r = n.apply(this, arguments);
  4769. return As(this, r)
  4770. }
  4771. }
  4772. var _l = function (t) {
  4773. xs(r, t);
  4774. var e = Rl(r);
  4775. function r(t, n, i) {
  4776. var a;
  4777. jo(this, r), (a = e.call(this, t, n, i)).attributesToInherit = ["gradientUnits"], a.stops = [];
  4778. var o = Ss(a), u = o.stops, s = o.children;
  4779. return Hi(s).call(s, (function (t) {
  4780. "stop" === t.type && u.push(t)
  4781. })), a
  4782. }
  4783. return Fo(r, [{
  4784. key: "getGradientUnits", value: function () {
  4785. return this.getAttribute("gradientUnits").getString("objectBoundingBox")
  4786. }
  4787. }, {
  4788. key: "createGradient", value: function (t, e, r) {
  4789. var n = this, i = this;
  4790. this.getHrefAttribute().hasValue() && (i = this.getHrefAttribute().getDefinition(), this.inheritStopContainer(i));
  4791. var a = i.stops, o = this.getGradient(t, e);
  4792. if (!o) return this.addParentOpacity(r, a[a.length - 1].color);
  4793. if (Hi(a).call(a, (function (t) {
  4794. o.addColorStop(t.offset, n.addParentOpacity(r, t.color))
  4795. })), this.getAttribute("gradientTransform").hasValue()) {
  4796. var u = this.document, s = u.screen, c = s.MAX_VIRTUAL_PIXELS, l = s.viewPort,
  4797. f = ci(l.viewPorts, 1)[0], h = new fl(u, null);
  4798. h.attributes.x = new ts(u, "x", -c / 3), h.attributes.y = new ts(u, "y", -c / 3), h.attributes.width = new ts(u, "width", c), h.attributes.height = new ts(u, "height", c);
  4799. var p = new Nl(u, null);
  4800. p.attributes.transform = new ts(u, "transform", this.getAttribute("gradientTransform").getValue()), p.children = [h];
  4801. var y = new cl(u, null);
  4802. y.attributes.x = new ts(u, "x", 0), y.attributes.y = new ts(u, "y", 0), y.attributes.width = new ts(u, "width", f.width), y.attributes.height = new ts(u, "height", f.height), y.children = [p];
  4803. var v = u.createCanvas(f.width, f.height), g = v.getContext("2d");
  4804. return g.fillStyle = o, y.render(g), g.createPattern(v, "no-repeat")
  4805. }
  4806. return o
  4807. }
  4808. }, {
  4809. key: "inheritStopContainer", value: function (t) {
  4810. var e, r = this;
  4811. Hi(e = this.attributesToInherit).call(e, (function (e) {
  4812. !r.getAttribute(e).hasValue() && t.getAttribute(e).hasValue() && r.getAttribute(e, !0).setValue(t.getAttribute(e).getValue())
  4813. }))
  4814. }
  4815. }, {
  4816. key: "addParentOpacity", value: function (t, e) {
  4817. return t.hasValue() ? new ts(this.document, "color", e).addOpacity(t).getColor() : e
  4818. }
  4819. }]), r
  4820. }(rc);
  4821. function Dl(t) {
  4822. var e = function () {
  4823. if ("undefined" == typeof Reflect || !ys) return !1;
  4824. if (ys.sham) return !1;
  4825. if ("function" == typeof Proxy) return !0;
  4826. try {
  4827. return Date.prototype.toString.call(ys(Date, [], (function () {
  4828. }))), !0
  4829. } catch (t) {
  4830. return !1
  4831. }
  4832. }();
  4833. return function () {
  4834. var r, n = Os(t);
  4835. if (e) {
  4836. var i = Os(this).constructor;
  4837. r = ys(n, arguments, i)
  4838. } else r = n.apply(this, arguments);
  4839. return As(this, r)
  4840. }
  4841. }
  4842. var Vl = function (t) {
  4843. xs(r, t);
  4844. var e = Dl(r);
  4845. function r(t, n, i) {
  4846. var a;
  4847. return jo(this, r), (a = e.call(this, t, n, i)).type = "linearGradient", a.attributesToInherit.push("x1", "y1", "x2", "y2"), a
  4848. }
  4849. return Fo(r, [{
  4850. key: "getGradient", value: function (t, e) {
  4851. var r = "objectBoundingBox" === this.getGradientUnits(), n = r ? e.getBoundingBox(t) : null;
  4852. if (r && !n) return null;
  4853. this.getAttribute("x1").hasValue() || this.getAttribute("y1").hasValue() || this.getAttribute("x2").hasValue() || this.getAttribute("y2").hasValue() || (this.getAttribute("x1", !0).setValue(0), this.getAttribute("y1", !0).setValue(0), this.getAttribute("x2", !0).setValue(1), this.getAttribute("y2", !0).setValue(0));
  4854. var i = r ? n.x + n.width * this.getAttribute("x1").getNumber() : this.getAttribute("x1").getPixels("x"),
  4855. a = r ? n.y + n.height * this.getAttribute("y1").getNumber() : this.getAttribute("y1").getPixels("y"),
  4856. o = r ? n.x + n.width * this.getAttribute("x2").getNumber() : this.getAttribute("x2").getPixels("x"),
  4857. u = r ? n.y + n.height * this.getAttribute("y2").getNumber() : this.getAttribute("y2").getPixels("y");
  4858. return i === o && a === u ? null : t.createLinearGradient(i, a, o, u)
  4859. }
  4860. }]), r
  4861. }(_l);
  4862. function Ll(t) {
  4863. var e = function () {
  4864. if ("undefined" == typeof Reflect || !ys) return !1;
  4865. if (ys.sham) return !1;
  4866. if ("function" == typeof Proxy) return !0;
  4867. try {
  4868. return Date.prototype.toString.call(ys(Date, [], (function () {
  4869. }))), !0
  4870. } catch (t) {
  4871. return !1
  4872. }
  4873. }();
  4874. return function () {
  4875. var r, n = Os(t);
  4876. if (e) {
  4877. var i = Os(this).constructor;
  4878. r = ys(n, arguments, i)
  4879. } else r = n.apply(this, arguments);
  4880. return As(this, r)
  4881. }
  4882. }
  4883. var Il = function (t) {
  4884. xs(r, t);
  4885. var e = Ll(r);
  4886. function r(t, n, i) {
  4887. var a;
  4888. return jo(this, r), (a = e.call(this, t, n, i)).type = "radialGradient", a.attributesToInherit.push("cx", "cy", "r", "fx", "fy", "fr"), a
  4889. }
  4890. return Fo(r, [{
  4891. key: "getGradient", value: function (t, e) {
  4892. var r = "objectBoundingBox" === this.getGradientUnits(), n = e.getBoundingBox(t);
  4893. if (r && !n) return null;
  4894. this.getAttribute("cx").hasValue() || this.getAttribute("cx", !0).setValue("50%"), this.getAttribute("cy").hasValue() || this.getAttribute("cy", !0).setValue("50%"), this.getAttribute("r").hasValue() || this.getAttribute("r", !0).setValue("50%");
  4895. var i = r ? n.x + n.width * this.getAttribute("cx").getNumber() : this.getAttribute("cx").getPixels("x"),
  4896. a = r ? n.y + n.height * this.getAttribute("cy").getNumber() : this.getAttribute("cy").getPixels("y"),
  4897. o = i, u = a;
  4898. this.getAttribute("fx").hasValue() && (o = r ? n.x + n.width * this.getAttribute("fx").getNumber() : this.getAttribute("fx").getPixels("x")), this.getAttribute("fy").hasValue() && (u = r ? n.y + n.height * this.getAttribute("fy").getNumber() : this.getAttribute("fy").getPixels("y"));
  4899. var s = r ? (n.width + n.height) / 2 * this.getAttribute("r").getNumber() : this.getAttribute("r").getPixels(),
  4900. c = this.getAttribute("fr").getPixels();
  4901. return t.createRadialGradient(o, u, c, i, a, s)
  4902. }
  4903. }]), r
  4904. }(_l);
  4905. function jl(t) {
  4906. var e = function () {
  4907. if ("undefined" == typeof Reflect || !ys) return !1;
  4908. if (ys.sham) return !1;
  4909. if ("function" == typeof Proxy) return !0;
  4910. try {
  4911. return Date.prototype.toString.call(ys(Date, [], (function () {
  4912. }))), !0
  4913. } catch (t) {
  4914. return !1
  4915. }
  4916. }();
  4917. return function () {
  4918. var r, n = Os(t);
  4919. if (e) {
  4920. var i = Os(this).constructor;
  4921. r = ys(n, arguments, i)
  4922. } else r = n.apply(this, arguments);
  4923. return As(this, r)
  4924. }
  4925. }
  4926. var zl = function (t) {
  4927. xs(r, t);
  4928. var e = jl(r);
  4929. function r(t, n, i) {
  4930. var a;
  4931. jo(this, r), (a = e.call(this, t, n, i)).type = "stop";
  4932. var o = Math.max(0, Math.min(1, a.getAttribute("offset").getNumber())), u = a.getStyle("stop-opacity"),
  4933. s = a.getStyle("stop-color", !0);
  4934. return "" === s.getString() && s.setValue("#000"), u.hasValue() && (s = s.addOpacity(u)), a.offset = o, a.color = s.getColor(), a
  4935. }
  4936. return r
  4937. }(rc), Fl = yt("Array").values, Bl = Array.prototype, Ul = {DOMTokenList: !0, NodeList: !0}, Hl = function (t) {
  4938. var e = t.values;
  4939. return t === Bl || t instanceof Array && e === Bl.values || Ul.hasOwnProperty(ur(t)) ? Fl : e
  4940. };
  4941. function Xl(t) {
  4942. var e = function () {
  4943. if ("undefined" == typeof Reflect || !ys) return !1;
  4944. if (ys.sham) return !1;
  4945. if ("function" == typeof Proxy) return !0;
  4946. try {
  4947. return Date.prototype.toString.call(ys(Date, [], (function () {
  4948. }))), !0
  4949. } catch (t) {
  4950. return !1
  4951. }
  4952. }();
  4953. return function () {
  4954. var r, n = Os(t);
  4955. if (e) {
  4956. var i = Os(this).constructor;
  4957. r = ys(n, arguments, i)
  4958. } else r = n.apply(this, arguments);
  4959. return As(this, r)
  4960. }
  4961. }
  4962. var Yl = function (t) {
  4963. xs(r, t);
  4964. var e = Xl(r);
  4965. function r(t, n, i) {
  4966. var a;
  4967. return jo(this, r), (a = e.call(this, t, n, i)).type = "animate", a.duration = 0, a.initialValue = null, a.initialUnits = "", a.removed = !1, a.frozen = !1, t.screen.animations.push(Ss(a)), a.begin = a.getAttribute("begin").getMilliseconds(), a.maxDuration = a.begin + a.getAttribute("dur").getMilliseconds(), a.from = a.getAttribute("from"), a.to = a.getAttribute("to"), a.values = a.getAttribute("values"), Hl(a).hasValue() && Hl(a).setValue(Hl(a).getString().split(";")), a
  4968. }
  4969. return Fo(r, [{
  4970. key: "getProperty", value: function () {
  4971. var t = this.getAttribute("attributeType").getString(),
  4972. e = this.getAttribute("attributeName").getString();
  4973. return "CSS" === t ? this.parent.getStyle(e, !0) : this.parent.getAttribute(e, !0)
  4974. }
  4975. }, {
  4976. key: "calcValue", value: function () {
  4977. var t, e = this.initialUnits, r = this.getProgress(), n = r.progress, i = r.from, a = r.to,
  4978. o = i.getNumber() + (a.getNumber() - i.getNumber()) * n;
  4979. return "%" === e && (o *= 100), Ho(t = "".concat(o)).call(t, e)
  4980. }
  4981. }, {
  4982. key: "update", value: function (t) {
  4983. var e = this.parent, r = this.getProperty();
  4984. if (this.initialValue || (this.initialValue = r.getString(), this.initialUnits = r.getUnits()), this.duration > this.maxDuration) {
  4985. var n = this.getAttribute("fill").getString("remove");
  4986. if ("indefinite" === this.getAttribute("repeatCount").getString() || "indefinite" === this.getAttribute("repeatDur").getString()) this.duration = 0; else if ("freeze" !== n || this.frozen) {
  4987. if ("remove" === n && !this.removed) return this.removed = !0, r.setValue(e.animationFrozen ? e.animationFrozenValue : this.initialValue), !0
  4988. } else this.frozen = !0, e.animationFrozen = !0, e.animationFrozenValue = r.getString();
  4989. return !1
  4990. }
  4991. this.duration += t;
  4992. var i = !1;
  4993. if (this.begin < this.duration) {
  4994. var a = this.calcValue(), o = this.getAttribute("type");
  4995. if (o.hasValue()) {
  4996. var u, s = o.getString();
  4997. a = Ho(u = "".concat(s, "(")).call(u, a, ")")
  4998. }
  4999. r.setValue(a), i = !0
  5000. }
  5001. return i
  5002. }
  5003. }, {
  5004. key: "getProgress", value: function () {
  5005. var t = this.document, e = Hl(this),
  5006. r = {progress: (this.duration - this.begin) / (this.maxDuration - this.begin)};
  5007. if (e.hasValue()) {
  5008. var n = r.progress * (e.getValue().length - 1), i = Math.floor(n), a = Math.ceil(n);
  5009. r.from = new ts(t, "from", Ct(e.getValue()[i])), r.to = new ts(t, "to", Ct(e.getValue()[a])), r.progress = (n - i) / (a - i)
  5010. } else r.from = this.from, r.to = this.to;
  5011. return r
  5012. }
  5013. }]), r
  5014. }(rc), ql = At.trim, Gl = i.parseInt, Ql = /^[+-]?0[Xx]/,
  5015. Wl = 8 !== Gl(mt + "08") || 22 !== Gl(mt + "0x16") ? function (t, e) {
  5016. var r = ql(String(t));
  5017. return Gl(r, e >>> 0 || (Ql.test(r) ? 16 : 10))
  5018. } : Gl;
  5019. H({global: !0, forced: parseInt != Wl}, {parseInt: Wl});
  5020. var $l = D.parseInt;
  5021. function Zl(t) {
  5022. var e = function () {
  5023. if ("undefined" == typeof Reflect || !ys) return !1;
  5024. if (ys.sham) return !1;
  5025. if ("function" == typeof Proxy) return !0;
  5026. try {
  5027. return Date.prototype.toString.call(ys(Date, [], (function () {
  5028. }))), !0
  5029. } catch (t) {
  5030. return !1
  5031. }
  5032. }();
  5033. return function () {
  5034. var r, n = Os(t);
  5035. if (e) {
  5036. var i = Os(this).constructor;
  5037. r = ys(n, arguments, i)
  5038. } else r = n.apply(this, arguments);
  5039. return As(this, r)
  5040. }
  5041. }
  5042. var Kl = function (t) {
  5043. xs(r, t);
  5044. var e = Zl(r);
  5045. function r() {
  5046. var t;
  5047. return jo(this, r), (t = e.apply(this, arguments)).type = "animateColor", t
  5048. }
  5049. return Fo(r, [{
  5050. key: "calcValue", value: function () {
  5051. var t = this.getProgress(), e = t.progress, r = t.from, n = t.to, i = new Ju(r.getColor()),
  5052. a = new Ju(n.getColor());
  5053. if (i.ok && a.ok) {
  5054. var o, u, s = i.r + (a.r - i.r) * e, c = i.g + (a.g - i.g) * e, l = i.b + (a.b - i.b) * e;
  5055. return Ho(o = Ho(u = "rgb(".concat($l(s, 10), ", ")).call(u, $l(c, 10), ", ")).call(o, $l(l, 10), ")")
  5056. }
  5057. return this.getAttribute("from").getColor()
  5058. }
  5059. }]), r
  5060. }(Yl);
  5061. function Jl(t) {
  5062. var e = function () {
  5063. if ("undefined" == typeof Reflect || !ys) return !1;
  5064. if (ys.sham) return !1;
  5065. if ("function" == typeof Proxy) return !0;
  5066. try {
  5067. return Date.prototype.toString.call(ys(Date, [], (function () {
  5068. }))), !0
  5069. } catch (t) {
  5070. return !1
  5071. }
  5072. }();
  5073. return function () {
  5074. var r, n = Os(t);
  5075. if (e) {
  5076. var i = Os(this).constructor;
  5077. r = ys(n, arguments, i)
  5078. } else r = n.apply(this, arguments);
  5079. return As(this, r)
  5080. }
  5081. }
  5082. var tf = function (t) {
  5083. xs(r, t);
  5084. var e = Jl(r);
  5085. function r() {
  5086. var t;
  5087. return jo(this, r), (t = e.apply(this, arguments)).type = "animateTransform", t
  5088. }
  5089. return Fo(r, [{
  5090. key: "calcValue", value: function () {
  5091. var t = this.getProgress(), e = t.progress, r = t.from, n = t.to, i = ae(r.getString()),
  5092. a = ae(n.getString());
  5093. return ee(i).call(i, (function (t, r) {
  5094. return t + (a[r] - t) * e
  5095. })).join(" ")
  5096. }
  5097. }]), r
  5098. }(Yl), ef = le, rf = Ir, nf = Vn, af = ii;
  5099. function of(t, e) {
  5100. var r;
  5101. if (void 0 === nf || null == rf(t)) {
  5102. if (ef(t) || (r = function (t, e) {
  5103. var r;
  5104. if (!t) return;
  5105. if ("string" == typeof t) return uf(t, e);
  5106. var n = af(r = Object.prototype.toString.call(t)).call(r, 8, -1);
  5107. "Object" === n && t.constructor && (n = t.constructor.name);
  5108. if ("Map" === n || "Set" === n) return Xs(t);
  5109. if ("Arguments" === n || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return uf(t, e)
  5110. }(t)) || e && t && "number" == typeof t.length) {
  5111. r && (t = r);
  5112. var n = 0, i = function () {
  5113. };
  5114. return {
  5115. s: i, n: function () {
  5116. return n >= t.length ? {done: !0} : {done: !1, value: t[n++]}
  5117. }, e: function (t) {
  5118. throw t
  5119. }, f: i
  5120. }
  5121. }
  5122. throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")
  5123. }
  5124. var a, o = !0, u = !1;
  5125. return {
  5126. s: function () {
  5127. r = jr(t)
  5128. }, n: function () {
  5129. var t = r.next();
  5130. return o = t.done, t
  5131. }, e: function (t) {
  5132. u = !0, a = t
  5133. }, f: function () {
  5134. try {
  5135. o || null == r.return || r.return()
  5136. } finally {
  5137. if (u) throw a
  5138. }
  5139. }
  5140. }
  5141. }
  5142. function uf(t, e) {
  5143. (null == e || e > t.length) && (e = t.length);
  5144. for (var r = 0, n = new Array(e); r < e; r++) n[r] = t[r];
  5145. return n
  5146. }
  5147. function sf(t) {
  5148. var e = function () {
  5149. if ("undefined" == typeof Reflect || !ys) return !1;
  5150. if (ys.sham) return !1;
  5151. if ("function" == typeof Proxy) return !0;
  5152. try {
  5153. return Date.prototype.toString.call(ys(Date, [], (function () {
  5154. }))), !0
  5155. } catch (t) {
  5156. return !1
  5157. }
  5158. }();
  5159. return function () {
  5160. var r, n = Os(t);
  5161. if (e) {
  5162. var i = Os(this).constructor;
  5163. r = ys(n, arguments, i)
  5164. } else r = n.apply(this, arguments);
  5165. return As(this, r)
  5166. }
  5167. }
  5168. var cf = function (t) {
  5169. xs(r, t);
  5170. var e = sf(r);
  5171. function r(t, n, i) {
  5172. var a;
  5173. jo(this, r), (a = e.call(this, t, n, i)).type = "font", a.glyphs = {}, a.horizAdvX = a.getAttribute("horiz-adv-x").getNumber();
  5174. var o, u = t.definitions, s = of(Ss(a).children);
  5175. try {
  5176. for (s.s(); !(o = s.n()).done;) {
  5177. var c = o.value;
  5178. switch (c.type) {
  5179. case"font-face":
  5180. a.fontFace = c;
  5181. var l = c.getStyle("font-family");
  5182. l.hasValue() && (u[l.getString()] = Ss(a));
  5183. break;
  5184. case"missing-glyph":
  5185. a.missingGlyph = c;
  5186. break;
  5187. case"glyph":
  5188. var f = c;
  5189. f.arabicForm ? (a.isRTL = !0, a.isArabic = !0, void 0 === a.glyphs[f.unicode] && (a.glyphs[f.unicode] = {}), a.glyphs[f.unicode][f.arabicForm] = f) : a.glyphs[f.unicode] = f
  5190. }
  5191. }
  5192. } catch (t) {
  5193. s.e(t)
  5194. } finally {
  5195. s.f()
  5196. }
  5197. return a
  5198. }
  5199. return Fo(r, [{
  5200. key: "render", value: function () {
  5201. }
  5202. }]), r
  5203. }(rc);
  5204. function lf(t) {
  5205. var e = function () {
  5206. if ("undefined" == typeof Reflect || !ys) return !1;
  5207. if (ys.sham) return !1;
  5208. if ("function" == typeof Proxy) return !0;
  5209. try {
  5210. return Date.prototype.toString.call(ys(Date, [], (function () {
  5211. }))), !0
  5212. } catch (t) {
  5213. return !1
  5214. }
  5215. }();
  5216. return function () {
  5217. var r, n = Os(t);
  5218. if (e) {
  5219. var i = Os(this).constructor;
  5220. r = ys(n, arguments, i)
  5221. } else r = n.apply(this, arguments);
  5222. return As(this, r)
  5223. }
  5224. }
  5225. var ff = function (t) {
  5226. xs(r, t);
  5227. var e = lf(r);
  5228. function r(t, n, i) {
  5229. var a;
  5230. return jo(this, r), (a = e.call(this, t, n, i)).type = "font-face", a.ascent = a.getAttribute("ascent").getNumber(), a.descent = a.getAttribute("descent").getNumber(), a.unitsPerEm = a.getAttribute("units-per-em").getNumber(), a
  5231. }
  5232. return r
  5233. }(rc);
  5234. function hf(t) {
  5235. var e = function () {
  5236. if ("undefined" == typeof Reflect || !ys) return !1;
  5237. if (ys.sham) return !1;
  5238. if ("function" == typeof Proxy) return !0;
  5239. try {
  5240. return Date.prototype.toString.call(ys(Date, [], (function () {
  5241. }))), !0
  5242. } catch (t) {
  5243. return !1
  5244. }
  5245. }();
  5246. return function () {
  5247. var r, n = Os(t);
  5248. if (e) {
  5249. var i = Os(this).constructor;
  5250. r = ys(n, arguments, i)
  5251. } else r = n.apply(this, arguments);
  5252. return As(this, r)
  5253. }
  5254. }
  5255. var pf = function (t) {
  5256. xs(r, t);
  5257. var e = hf(r);
  5258. function r() {
  5259. var t;
  5260. return jo(this, r), (t = e.apply(this, arguments)).type = "missing-glyph", t.horizAdvX = 0, t
  5261. }
  5262. return r
  5263. }(ul);
  5264. function yf(t) {
  5265. var e = function () {
  5266. if ("undefined" == typeof Reflect || !ys) return !1;
  5267. if (ys.sham) return !1;
  5268. if ("function" == typeof Proxy) return !0;
  5269. try {
  5270. return Date.prototype.toString.call(ys(Date, [], (function () {
  5271. }))), !0
  5272. } catch (t) {
  5273. return !1
  5274. }
  5275. }();
  5276. return function () {
  5277. var r, n = Os(t);
  5278. if (e) {
  5279. var i = Os(this).constructor;
  5280. r = ys(n, arguments, i)
  5281. } else r = n.apply(this, arguments);
  5282. return As(this, r)
  5283. }
  5284. }
  5285. var vf = function (t) {
  5286. xs(r, t);
  5287. var e = yf(r);
  5288. function r(t, n, i) {
  5289. var a;
  5290. return jo(this, r), (a = e.call(this, t, n, i)).type = "glyph", a.horizAdvX = a.getAttribute("horiz-adv-x").getNumber(), a.unicode = a.getAttribute("unicode").getString(), a.arabicForm = a.getAttribute("arabic-form").getString(), a
  5291. }
  5292. return r
  5293. }(ul);
  5294. function gf(t) {
  5295. var e = function () {
  5296. if ("undefined" == typeof Reflect || !ys) return !1;
  5297. if (ys.sham) return !1;
  5298. if ("function" == typeof Proxy) return !0;
  5299. try {
  5300. return Date.prototype.toString.call(ys(Date, [], (function () {
  5301. }))), !0
  5302. } catch (t) {
  5303. return !1
  5304. }
  5305. }();
  5306. return function () {
  5307. var r, n = Os(t);
  5308. if (e) {
  5309. var i = Os(this).constructor;
  5310. r = ys(n, arguments, i)
  5311. } else r = n.apply(this, arguments);
  5312. return As(this, r)
  5313. }
  5314. }
  5315. var df = function (t) {
  5316. xs(r, t);
  5317. var e = gf(r);
  5318. function r() {
  5319. var t;
  5320. return jo(this, r), (t = e.apply(this, arguments)).type = "tref", t
  5321. }
  5322. return Fo(r, [{
  5323. key: "getText", value: function () {
  5324. var t = this.getHrefAttribute().getDefinition();
  5325. if (t) {
  5326. var e = t.children[0];
  5327. if (e) return e.getText()
  5328. }
  5329. return ""
  5330. }
  5331. }]), r
  5332. }(Mc);
  5333. function mf(t) {
  5334. var e = function () {
  5335. if ("undefined" == typeof Reflect || !ys) return !1;
  5336. if (ys.sham) return !1;
  5337. if ("function" == typeof Proxy) return !0;
  5338. try {
  5339. return Date.prototype.toString.call(ys(Date, [], (function () {
  5340. }))), !0
  5341. } catch (t) {
  5342. return !1
  5343. }
  5344. }();
  5345. return function () {
  5346. var r, n = Os(t);
  5347. if (e) {
  5348. var i = Os(this).constructor;
  5349. r = ys(n, arguments, i)
  5350. } else r = n.apply(this, arguments);
  5351. return As(this, r)
  5352. }
  5353. }
  5354. var xf = function (t) {
  5355. xs(r, t);
  5356. var e = mf(r);
  5357. function r(t, n, i) {
  5358. var a, o;
  5359. jo(this, r), (o = e.call(this, t, n, i)).type = "a";
  5360. var u = n.childNodes, s = u[0], c = u.length > 0 && nu(a = Xs(u)).call(a, (function (t) {
  5361. return 3 === t.nodeType
  5362. }));
  5363. return o.hasText = c, o.text = c ? o.getTextFromNode(s) : "", o
  5364. }
  5365. return Fo(r, [{
  5366. key: "getText", value: function () {
  5367. return this.text
  5368. }
  5369. }, {
  5370. key: "renderChildren", value: function (t) {
  5371. if (this.hasText) {
  5372. wc(Os(r.prototype), "renderChildren", this).call(this, t);
  5373. var e = this.document, n = this.x, i = this.y, a = e.screen.mouse,
  5374. o = new ts(e, "fontSize", Tc.parse(e.ctx.font).fontSize);
  5375. a.isWorking() && a.checkBoundingBox(this, new Oc(n, i - o.getPixels("y"), n + this.measureText(t), i))
  5376. } else if (this.children.length > 0) {
  5377. var u = new Nl(this.document, null);
  5378. u.children = this.children, u.parent = this, u.render(t)
  5379. }
  5380. }
  5381. }, {
  5382. key: "onClick", value: function () {
  5383. var t = this.document.window;
  5384. t && t.open(this.getHrefAttribute().getString())
  5385. }
  5386. }, {
  5387. key: "onMouseMove", value: function () {
  5388. this.document.ctx.canvas.style.cursor = "pointer"
  5389. }
  5390. }]), r
  5391. }(Mc), bf = !a((function () {
  5392. return Object.isExtensible(Object.preventExtensions({}))
  5393. })), wf = r((function (t) {
  5394. var e = z.f, r = tt("meta"), n = 0, i = Object.isExtensible || function () {
  5395. return !0
  5396. }, a = function (t) {
  5397. e(t, r, {value: {objectID: "O" + ++n, weakData: {}}})
  5398. }, o = t.exports = {
  5399. REQUIRED: !1, fastKey: function (t, e) {
  5400. if (!d(t)) return "symbol" == typeof t ? t : ("string" == typeof t ? "S" : "P") + t;
  5401. if (!b(t, r)) {
  5402. if (!i(t)) return "F";
  5403. if (!e) return "E";
  5404. a(t)
  5405. }
  5406. return t[r].objectID
  5407. }, getWeakData: function (t, e) {
  5408. if (!b(t, r)) {
  5409. if (!i(t)) return !0;
  5410. if (!e) return !1;
  5411. a(t)
  5412. }
  5413. return t[r].weakData
  5414. }, onFreeze: function (t) {
  5415. return bf && o.REQUIRED && i(t) && !b(t, r) && a(t), t
  5416. }
  5417. };
  5418. Ae[r] = !0
  5419. })), Sf = z.f, Af = Lt.forEach, kf = _e.set, Tf = _e.getterFor, Of = z.f, Pf = wf.fastKey, Ef = _e.set,
  5420. Cf = _e.getterFor, Mf = (function (t, e, r) {
  5421. var n, u = -1 !== t.indexOf("Map"), s = -1 !== t.indexOf("Weak"), c = u ? "set" : "add", l = i[t],
  5422. f = l && l.prototype, h = {};
  5423. if (o && "function" == typeof l && (s || f.forEach && !a((function () {
  5424. (new l).entries().next()
  5425. })))) {
  5426. n = e((function (e, r) {
  5427. kf(ya(e, n, t), {type: t, collection: new l}), null != r && aa(r, e[c], {that: e, AS_ENTRIES: u})
  5428. }));
  5429. var p = Tf(t);
  5430. Af(["add", "clear", "delete", "forEach", "get", "has", "set", "keys", "values", "entries"], (function (t) {
  5431. var e = "add" == t || "set" == t;
  5432. !(t in f) || s && "clear" == t || F(n.prototype, t, (function (r, n) {
  5433. var i = p(this).collection;
  5434. if (!e && s && !d(r)) return "get" == t && void 0;
  5435. var a = i[t](0 === r ? 0 : r, n);
  5436. return e ? this : a
  5437. }))
  5438. })), s || Sf(n.prototype, "size", {
  5439. configurable: !0, get: function () {
  5440. return p(this).collection.size
  5441. }
  5442. })
  5443. } else n = r.getConstructor(e, t, u, c), wf.REQUIRED = !0;
  5444. fr(n, t, !1, !0), h[t] = n, H({global: !0, forced: !0}, h), s || r.setStrong(n, t, u)
  5445. }("Map", (function (t) {
  5446. return function () {
  5447. return t(this, arguments.length ? arguments[0] : void 0)
  5448. }
  5449. }), {
  5450. getConstructor: function (t, e, r, n) {
  5451. var i = t((function (t, a) {
  5452. ya(t, i, e), Ef(t, {
  5453. type: e,
  5454. index: rr(null),
  5455. first: void 0,
  5456. last: void 0,
  5457. size: 0
  5458. }), o || (t.size = 0), null != a && aa(a, t[n], {that: t, AS_ENTRIES: r})
  5459. })), a = Cf(e), u = function (t, e, r) {
  5460. var n, i, u = a(t), c = s(t, e);
  5461. return c ? c.value = r : (u.last = c = {
  5462. index: i = Pf(e, !0),
  5463. key: e,
  5464. value: r,
  5465. previous: n = u.last,
  5466. next: void 0,
  5467. removed: !1
  5468. }, u.first || (u.first = c), n && (n.next = c), o ? u.size++ : t.size++, "F" !== i && (u.index[i] = c)), t
  5469. }, s = function (t, e) {
  5470. var r, n = a(t), i = Pf(e);
  5471. if ("F" !== i) return n.index[i];
  5472. for (r = n.first; r; r = r.next) if (r.key == e) return r
  5473. };
  5474. return fa(i.prototype, {
  5475. clear: function () {
  5476. for (var t = a(this), e = t.index, r = t.first; r;) r.removed = !0, r.previous && (r.previous = r.previous.next = void 0), delete e[r.index], r = r.next;
  5477. t.first = t.last = void 0, o ? t.size = 0 : this.size = 0
  5478. }, delete: function (t) {
  5479. var e = this, r = a(e), n = s(e, t);
  5480. if (n) {
  5481. var i = n.next, u = n.previous;
  5482. delete r.index[n.index], n.removed = !0, u && (u.next = i), i && (i.previous = u), r.first == n && (r.first = i), r.last == n && (r.last = u), o ? r.size-- : e.size--
  5483. }
  5484. return !!n
  5485. }, forEach: function (t) {
  5486. for (var e, r = a(this), n = L(t, arguments.length > 1 ? arguments[1] : void 0, 3); e = e ? e.next : r.first;) for (n(e.value, e.key, this); e && e.removed;) e = e.previous
  5487. }, has: function (t) {
  5488. return !!s(this, t)
  5489. }
  5490. }), fa(i.prototype, r ? {
  5491. get: function (t) {
  5492. var e = s(this, t);
  5493. return e && e.value
  5494. }, set: function (t, e) {
  5495. return u(this, 0 === t ? 0 : t, e)
  5496. }
  5497. } : {
  5498. add: function (t) {
  5499. return u(this, t = 0 === t ? 0 : t, t)
  5500. }
  5501. }), o && Of(i.prototype, "size", {
  5502. get: function () {
  5503. return a(this).size
  5504. }
  5505. }), i
  5506. }, setStrong: function (t, e, r) {
  5507. var n = e + " Iterator", i = Cf(e), a = Cf(n);
  5508. Ar(t, e, (function (t, e) {
  5509. Ef(this, {type: n, target: t, state: i(t), kind: e, last: void 0})
  5510. }), (function () {
  5511. for (var t = a(this), e = t.kind, r = t.last; r && r.removed;) r = r.previous;
  5512. return t.target && (t.last = r = r ? r.next : t.state.first) ? "keys" == e ? {
  5513. value: r.key,
  5514. done: !1
  5515. } : "values" == e ? {value: r.value, done: !1} : {
  5516. value: [r.key, r.value],
  5517. done: !1
  5518. } : (t.target = void 0, {value: void 0, done: !0})
  5519. }), r ? "entries" : "values", !r, !0), pa(e)
  5520. }
  5521. }), D.Map);
  5522. function Nf(t, e) {
  5523. var r;
  5524. if (void 0 === nf || null == rf(t)) {
  5525. if (ef(t) || (r = function (t, e) {
  5526. var r;
  5527. if (!t) return;
  5528. if ("string" == typeof t) return Rf(t, e);
  5529. var n = af(r = Object.prototype.toString.call(t)).call(r, 8, -1);
  5530. "Object" === n && t.constructor && (n = t.constructor.name);
  5531. if ("Map" === n || "Set" === n) return Xs(t);
  5532. if ("Arguments" === n || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return Rf(t, e)
  5533. }(t)) || e && t && "number" == typeof t.length) {
  5534. r && (t = r);
  5535. var n = 0, i = function () {
  5536. };
  5537. return {
  5538. s: i, n: function () {
  5539. return n >= t.length ? {done: !0} : {done: !1, value: t[n++]}
  5540. }, e: function (t) {
  5541. throw t
  5542. }, f: i
  5543. }
  5544. }
  5545. throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")
  5546. }
  5547. var a, o = !0, u = !1;
  5548. return {
  5549. s: function () {
  5550. r = jr(t)
  5551. }, n: function () {
  5552. var t = r.next();
  5553. return o = t.done, t
  5554. }, e: function (t) {
  5555. u = !0, a = t
  5556. }, f: function () {
  5557. try {
  5558. o || null == r.return || r.return()
  5559. } finally {
  5560. if (u) throw a
  5561. }
  5562. }
  5563. }
  5564. }
  5565. function Rf(t, e) {
  5566. (null == e || e > t.length) && (e = t.length);
  5567. for (var r = 0, n = new Array(e); r < e; r++) n[r] = t[r];
  5568. return n
  5569. }
  5570. function _f(t, e) {
  5571. var r = ra(t);
  5572. if (ta) {
  5573. var n = ta(t);
  5574. e && (n = Ji(n).call(n, (function (e) {
  5575. return Gi(t, e).enumerable
  5576. }))), r.push.apply(r, n)
  5577. }
  5578. return r
  5579. }
  5580. function Df(t) {
  5581. for (var e = 1; e < arguments.length; e++) {
  5582. var r, n = null != arguments[e] ? arguments[e] : {};
  5583. if (e % 2) Hi(r = _f(Object(n), !0)).call(r, (function (e) {
  5584. Io(t, e, n[e])
  5585. })); else if (Di) Ri(t, Di(n)); else {
  5586. var i;
  5587. Hi(i = _f(Object(n))).call(i, (function (e) {
  5588. Ni(t, e, Gi(n, e))
  5589. }))
  5590. }
  5591. }
  5592. return t
  5593. }
  5594. function Vf(t) {
  5595. var e = function () {
  5596. if ("undefined" == typeof Reflect || !ys) return !1;
  5597. if (ys.sham) return !1;
  5598. if ("function" == typeof Proxy) return !0;
  5599. try {
  5600. return Date.prototype.toString.call(ys(Date, [], (function () {
  5601. }))), !0
  5602. } catch (t) {
  5603. return !1
  5604. }
  5605. }();
  5606. return function () {
  5607. var r, n = Os(t);
  5608. if (e) {
  5609. var i = Os(this).constructor;
  5610. r = ys(n, arguments, i)
  5611. } else r = n.apply(this, arguments);
  5612. return As(this, r)
  5613. }
  5614. }
  5615. var Lf = function (t) {
  5616. xs(r, t);
  5617. var e = Vf(r);
  5618. function r(t, n, i) {
  5619. var a;
  5620. jo(this, r), (a = e.call(this, t, n, i)).type = "textPath", a.textWidth = 0, a.textHeight = 0, a.pathLength = -1, a.glyphInfo = null, a.letterSpacingCache = [], a.measuresCache = new Mf([["", 0]]);
  5621. var o = a.getHrefAttribute().getDefinition();
  5622. return a.text = a.getTextFromNode(), a.dataArray = a.parsePathData(o), a
  5623. }
  5624. return Fo(r, [{
  5625. key: "getText", value: function () {
  5626. return this.text
  5627. }
  5628. }, {
  5629. key: "path", value: function (t) {
  5630. var e = this.dataArray;
  5631. t && t.beginPath(), Hi(e).call(e, (function (e) {
  5632. var r = e.type, n = e.points;
  5633. switch (r) {
  5634. case al.LINE_TO:
  5635. t && t.lineTo(n[0], n[1]);
  5636. break;
  5637. case al.MOVE_TO:
  5638. t && t.moveTo(n[0], n[1]);
  5639. break;
  5640. case al.CURVE_TO:
  5641. t && t.bezierCurveTo(n[0], n[1], n[2], n[3], n[4], n[5]);
  5642. break;
  5643. case al.QUAD_TO:
  5644. t && t.quadraticCurveTo(n[0], n[1], n[2], n[3]);
  5645. break;
  5646. case al.ARC:
  5647. var i = ci(n, 8), a = i[0], o = i[1], u = i[2], s = i[3], c = i[4], l = i[5], f = i[6],
  5648. h = i[7], p = u > s ? u : s, y = u > s ? 1 : u / s, v = u > s ? s / u : 1;
  5649. t && (t.translate(a, o), t.rotate(f), t.scale(y, v), t.arc(0, 0, p, c, c + l, Boolean(1 - h)), t.scale(1 / y, 1 / v), t.rotate(-f), t.translate(-a, -o));
  5650. break;
  5651. case al.CLOSE_PATH:
  5652. t && t.closePath()
  5653. }
  5654. }))
  5655. }
  5656. }, {
  5657. key: "renderChildren", value: function (t) {
  5658. this.setTextData(t), t.save();
  5659. var e = this.parent.getStyle("text-decoration").getString(), r = this.getFontSize(), n = this.glyphInfo,
  5660. i = t.fillStyle;
  5661. "underline" === e && t.beginPath(), Hi(n).call(n, (function (n, i) {
  5662. var a = n.p0, o = n.p1, u = n.rotation, s = n.text;
  5663. t.save(), t.translate(a.x, a.y), t.rotate(u), t.fillStyle && t.fillText(s, 0, 0), t.strokeStyle && t.strokeText(s, 0, 0), t.restore(), "underline" === e && (0 === i && t.moveTo(a.x, a.y + r / 8), t.lineTo(o.x, o.y + r / 5))
  5664. })), "underline" === e && (t.lineWidth = r / 20, t.strokeStyle = i, t.stroke(), t.closePath()), t.restore()
  5665. }
  5666. }, {
  5667. key: "getLetterSpacingAt", value: function () {
  5668. var t = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : 0;
  5669. return this.letterSpacingCache[t] || 0
  5670. }
  5671. }, {
  5672. key: "findSegmentToFitChar", value: function (t, e, r, n, i, a, o, u, s) {
  5673. var c = a, l = this.measureText(t, u);
  5674. " " === u && "justify" === e && r < n && (l += (n - r) / i), s > -1 && (c += this.getLetterSpacingAt(s));
  5675. var f = this.textHeight / 20, h = this.getEquidistantPointOnPath(c, f, 0),
  5676. p = this.getEquidistantPointOnPath(c + l, f, 0), y = {p0: h, p1: p},
  5677. v = h && p ? Math.atan2(p.y - h.y, p.x - h.x) : 0;
  5678. if (o) {
  5679. var g = Math.cos(Math.PI / 2 + v) * o, d = Math.cos(-v) * o;
  5680. y.p0 = Df(Df({}, h), {}, {x: h.x + g, y: h.y + d}), y.p1 = Df(Df({}, p), {}, {
  5681. x: p.x + g,
  5682. y: p.y + d
  5683. })
  5684. }
  5685. return {offset: c += l, segment: y, rotation: v}
  5686. }
  5687. }, {
  5688. key: "measureText", value: function (t, e) {
  5689. var r = this.measuresCache, n = e || this.getText();
  5690. if (r.has(n)) return r.get(n);
  5691. var i = this.measureTargetText(t, n);
  5692. return r.set(n, i), i
  5693. }
  5694. }, {
  5695. key: "setTextData", value: function (t) {
  5696. var e, r = this;
  5697. if (!this.glyphInfo) {
  5698. var n = this.getText(), i = n.split(""), a = n.split(" ").length - 1,
  5699. o = ee(e = this.parent.getAttribute("dx").split()).call(e, (function (t) {
  5700. return t.getPixels("x")
  5701. })), u = this.parent.getAttribute("dy").getPixels("y"),
  5702. s = this.parent.getStyle("text-anchor").getString("start"), c = this.getStyle("letter-spacing"),
  5703. l = this.parent.getStyle("letter-spacing"), f = 0;
  5704. c.hasValue() && "inherit" !== c.getValue() ? c.hasValue() && "initial" !== c.getValue() && "unset" !== c.getValue() && (f = c.getPixels()) : f = l.getPixels();
  5705. var h = [], p = n.length;
  5706. this.letterSpacingCache = h;
  5707. for (var y = 0; y < p; y++) h.push(void 0 !== o[y] ? o[y] : f);
  5708. var v = $o(h).call(h, (function (t, e, r) {
  5709. return 0 === r ? 0 : t + e || 0
  5710. }), 0), g = this.measureText(t), d = Math.max(g + v, 0);
  5711. this.textWidth = g, this.textHeight = this.getFontSize(), this.glyphInfo = [];
  5712. var m = this.getPathLength(), x = this.getStyle("startOffset").getNumber(0) * m, b = 0;
  5713. "middle" !== s && "center" !== s || (b = -d / 2), "end" !== s && "right" !== s || (b = -d), b += x, Hi(i).call(i, (function (e, n) {
  5714. var o = r.findSegmentToFitChar(t, s, d, m, a, b, u, e, n), c = o.offset, l = o.segment,
  5715. f = o.rotation;
  5716. b = c, l.p0 && l.p1 && r.glyphInfo.push({text: i[n], p0: l.p0, p1: l.p1, rotation: f})
  5717. }))
  5718. }
  5719. }
  5720. }, {
  5721. key: "parsePathData", value: function (t) {
  5722. if (this.pathLength = -1, !t) return [];
  5723. var e = [], r = t.pathParser;
  5724. for (r.reset(); !r.isEnd();) {
  5725. var n = r.current, i = n ? n.x : 0, a = n ? n.y : 0, o = r.next(), u = o.type, s = [];
  5726. switch (o.type) {
  5727. case al.MOVE_TO:
  5728. this.pathM(r, s);
  5729. break;
  5730. case al.LINE_TO:
  5731. u = this.pathL(r, s);
  5732. break;
  5733. case al.HORIZ_LINE_TO:
  5734. u = this.pathH(r, s);
  5735. break;
  5736. case al.VERT_LINE_TO:
  5737. u = this.pathV(r, s);
  5738. break;
  5739. case al.CURVE_TO:
  5740. this.pathC(r, s);
  5741. break;
  5742. case al.SMOOTH_CURVE_TO:
  5743. u = this.pathS(r, s);
  5744. break;
  5745. case al.QUAD_TO:
  5746. this.pathQ(r, s);
  5747. break;
  5748. case al.SMOOTH_QUAD_TO:
  5749. u = this.pathT(r, s);
  5750. break;
  5751. case al.ARC:
  5752. s = this.pathA(r);
  5753. break;
  5754. case al.CLOSE_PATH:
  5755. ul.pathZ(r)
  5756. }
  5757. o.type !== al.CLOSE_PATH ? e.push({
  5758. type: u,
  5759. points: s,
  5760. start: {x: i, y: a},
  5761. pathLength: this.calcLength(i, a, u, s)
  5762. }) : e.push({type: al.CLOSE_PATH, points: [], pathLength: 0})
  5763. }
  5764. return e
  5765. }
  5766. }, {
  5767. key: "pathM", value: function (t, e) {
  5768. var r = ul.pathM(t).point, n = r.x, i = r.y;
  5769. e.push(n, i)
  5770. }
  5771. }, {
  5772. key: "pathL", value: function (t, e) {
  5773. var r = ul.pathL(t).point, n = r.x, i = r.y;
  5774. return e.push(n, i), al.LINE_TO
  5775. }
  5776. }, {
  5777. key: "pathH", value: function (t, e) {
  5778. var r = ul.pathH(t).point, n = r.x, i = r.y;
  5779. return e.push(n, i), al.LINE_TO
  5780. }
  5781. }, {
  5782. key: "pathV", value: function (t, e) {
  5783. var r = ul.pathV(t).point, n = r.x, i = r.y;
  5784. return e.push(n, i), al.LINE_TO
  5785. }
  5786. }, {
  5787. key: "pathC", value: function (t, e) {
  5788. var r = ul.pathC(t), n = r.point, i = r.controlPoint, a = r.currentPoint;
  5789. e.push(n.x, n.y, i.x, i.y, a.x, a.y)
  5790. }
  5791. }, {
  5792. key: "pathS", value: function (t, e) {
  5793. var r = ul.pathS(t), n = r.point, i = r.controlPoint, a = r.currentPoint;
  5794. return e.push(n.x, n.y, i.x, i.y, a.x, a.y), al.CURVE_TO
  5795. }
  5796. }, {
  5797. key: "pathQ", value: function (t, e) {
  5798. var r = ul.pathQ(t), n = r.controlPoint, i = r.currentPoint;
  5799. e.push(n.x, n.y, i.x, i.y)
  5800. }
  5801. }, {
  5802. key: "pathT", value: function (t, e) {
  5803. var r = ul.pathT(t), n = r.controlPoint, i = r.currentPoint;
  5804. return e.push(n.x, n.y, i.x, i.y), al.QUAD_TO
  5805. }
  5806. }, {
  5807. key: "pathA", value: function (t) {
  5808. var e = ul.pathA(t), r = e.rX, n = e.rY, i = e.sweepFlag, a = e.xAxisRotation, o = e.centp, u = e.a1,
  5809. s = e.ad;
  5810. return 0 === i && s > 0 && (s -= 2 * Math.PI), 1 === i && s < 0 && (s += 2 * Math.PI), [o.x, o.y, r, n, u, s, a, i]
  5811. }
  5812. }, {
  5813. key: "calcLength", value: function (t, e, r, n) {
  5814. var i = 0, a = null, o = null, u = 0;
  5815. switch (r) {
  5816. case al.LINE_TO:
  5817. return this.getLineLength(t, e, n[0], n[1]);
  5818. case al.CURVE_TO:
  5819. for (i = 0, a = this.getPointOnCubicBezier(0, t, e, n[0], n[1], n[2], n[3], n[4], n[5]), u = .01; u <= 1; u += .01) o = this.getPointOnCubicBezier(u, t, e, n[0], n[1], n[2], n[3], n[4], n[5]), i += this.getLineLength(a.x, a.y, o.x, o.y), a = o;
  5820. return i;
  5821. case al.QUAD_TO:
  5822. for (i = 0, a = this.getPointOnQuadraticBezier(0, t, e, n[0], n[1], n[2], n[3]), u = .01; u <= 1; u += .01) o = this.getPointOnQuadraticBezier(u, t, e, n[0], n[1], n[2], n[3]), i += this.getLineLength(a.x, a.y, o.x, o.y), a = o;
  5823. return i;
  5824. case al.ARC:
  5825. i = 0;
  5826. var s = n[4], c = n[5], l = n[4] + c, f = Math.PI / 180;
  5827. if (Math.abs(s - l) < f && (f = Math.abs(s - l)), a = this.getPointOnEllipticalArc(n[0], n[1], n[2], n[3], s, 0), c < 0) for (u = s - f; u > l; u -= f) o = this.getPointOnEllipticalArc(n[0], n[1], n[2], n[3], u, 0), i += this.getLineLength(a.x, a.y, o.x, o.y), a = o; else for (u = s + f; u < l; u += f) o = this.getPointOnEllipticalArc(n[0], n[1], n[2], n[3], u, 0), i += this.getLineLength(a.x, a.y, o.x, o.y), a = o;
  5828. return o = this.getPointOnEllipticalArc(n[0], n[1], n[2], n[3], l, 0), i += this.getLineLength(a.x, a.y, o.x, o.y)
  5829. }
  5830. return 0
  5831. }
  5832. }, {
  5833. key: "getPointOnLine", value: function (t, e, r, n, i) {
  5834. var a = arguments.length > 5 && void 0 !== arguments[5] ? arguments[5] : e,
  5835. o = arguments.length > 6 && void 0 !== arguments[6] ? arguments[6] : r, u = (i - r) / (n - e + xi),
  5836. s = Math.sqrt(t * t / (1 + u * u));
  5837. n < e && (s *= -1);
  5838. var c = u * s, l = null;
  5839. if (n === e) l = {x: a, y: o + c}; else if ((o - r) / (a - e + xi) === u) l = {
  5840. x: a + s,
  5841. y: o + c
  5842. }; else {
  5843. var f = 0, h = 0, p = this.getLineLength(e, r, n, i);
  5844. if (p < xi) return null;
  5845. var y = (a - e) * (n - e) + (o - r) * (i - r);
  5846. f = e + (y /= p * p) * (n - e), h = r + y * (i - r);
  5847. var v = this.getLineLength(a, o, f, h), g = Math.sqrt(t * t - v * v);
  5848. s = Math.sqrt(g * g / (1 + u * u)), n < e && (s *= -1), l = {x: f + s, y: h + (c = u * s)}
  5849. }
  5850. return l
  5851. }
  5852. }, {
  5853. key: "getPointOnPath", value: function (t) {
  5854. var e = this.getPathLength(), r = 0, n = null;
  5855. if (t < -5e-5 || t - 5e-5 > e) return null;
  5856. var i, a = Nf(this.dataArray);
  5857. try {
  5858. for (a.s(); !(i = a.n()).done;) {
  5859. var o = i.value;
  5860. if (!o || !(o.pathLength < 5e-5 || r + o.pathLength + 5e-5 < t)) {
  5861. var u = t - r, s = 0;
  5862. switch (o.type) {
  5863. case al.LINE_TO:
  5864. n = this.getPointOnLine(u, o.start.x, o.start.y, o.points[0], o.points[1], o.start.x, o.start.y);
  5865. break;
  5866. case al.ARC:
  5867. var c = o.points[4], l = o.points[5], f = o.points[4] + l;
  5868. if (s = c + u / o.pathLength * l, l < 0 && s < f || l >= 0 && s > f) break;
  5869. n = this.getPointOnEllipticalArc(o.points[0], o.points[1], o.points[2], o.points[3], s, o.points[6]);
  5870. break;
  5871. case al.CURVE_TO:
  5872. (s = u / o.pathLength) > 1 && (s = 1), n = this.getPointOnCubicBezier(s, o.start.x, o.start.y, o.points[0], o.points[1], o.points[2], o.points[3], o.points[4], o.points[5]);
  5873. break;
  5874. case al.QUAD_TO:
  5875. (s = u / o.pathLength) > 1 && (s = 1), n = this.getPointOnQuadraticBezier(s, o.start.x, o.start.y, o.points[0], o.points[1], o.points[2], o.points[3])
  5876. }
  5877. if (n) return n;
  5878. break
  5879. }
  5880. r += o.pathLength
  5881. }
  5882. } catch (t) {
  5883. a.e(t)
  5884. } finally {
  5885. a.f()
  5886. }
  5887. return null
  5888. }
  5889. }, {
  5890. key: "getLineLength", value: function (t, e, r, n) {
  5891. return Math.sqrt((r - t) * (r - t) + (n - e) * (n - e))
  5892. }
  5893. }, {
  5894. key: "getPathLength", value: function () {
  5895. var t;
  5896. -1 === this.pathLength && (this.pathLength = $o(t = this.dataArray).call(t, (function (t, e) {
  5897. return e.pathLength > 0 ? t + e.pathLength : t
  5898. }), 0));
  5899. return this.pathLength
  5900. }
  5901. }, {
  5902. key: "getPointOnCubicBezier", value: function (t, e, r, n, i, a, o, u, s) {
  5903. return {
  5904. x: u * Ai(t) + a * ki(t) + n * Ti(t) + e * Oi(t),
  5905. y: s * Ai(t) + o * ki(t) + i * Ti(t) + r * Oi(t)
  5906. }
  5907. }
  5908. }, {
  5909. key: "getPointOnQuadraticBezier", value: function (t, e, r, n, i, a, o) {
  5910. return {x: a * Pi(t) + n * Ei(t) + e * Ci(t), y: o * Pi(t) + i * Ei(t) + r * Ci(t)}
  5911. }
  5912. }, {
  5913. key: "getPointOnEllipticalArc", value: function (t, e, r, n, i, a) {
  5914. var o = Math.cos(a), u = Math.sin(a), s = r * Math.cos(i), c = n * Math.sin(i);
  5915. return {x: t + (s * o - c * u), y: e + (s * u + c * o)}
  5916. }
  5917. }, {
  5918. key: "buildEquidistantCache", value: function (t, e) {
  5919. var r = this.getPathLength(), n = e || .25, i = t || r / 100;
  5920. if (!this.equidistantCache || this.equidistantCache.step !== i || this.equidistantCache.precision !== n) {
  5921. this.equidistantCache = {step: i, precision: n, points: []};
  5922. for (var a = 0, o = 0; o <= r; o += n) {
  5923. var u = this.getPointOnPath(o), s = this.getPointOnPath(o + n);
  5924. u && s && ((a += this.getLineLength(u.x, u.y, s.x, s.y)) >= i && (this.equidistantCache.points.push({
  5925. x: u.x,
  5926. y: u.y,
  5927. distance: o
  5928. }), a -= i))
  5929. }
  5930. }
  5931. }
  5932. }, {
  5933. key: "getEquidistantPointOnPath", value: function (t, e, r) {
  5934. if (this.buildEquidistantCache(e, r), t < 0 || t - this.getPathLength() > 5e-5) return null;
  5935. var n = Math.round(t / this.getPathLength() * (this.equidistantCache.points.length - 1));
  5936. return this.equidistantCache.points[n] || null
  5937. }
  5938. }]), r
  5939. }(Mc);
  5940. function If(t) {
  5941. var e = function () {
  5942. if ("undefined" == typeof Reflect || !ys) return !1;
  5943. if (ys.sham) return !1;
  5944. if ("function" == typeof Proxy) return !0;
  5945. try {
  5946. return Date.prototype.toString.call(ys(Date, [], (function () {
  5947. }))), !0
  5948. } catch (t) {
  5949. return !1
  5950. }
  5951. }();
  5952. return function () {
  5953. var r, n = Os(t);
  5954. if (e) {
  5955. var i = Os(this).constructor;
  5956. r = ys(n, arguments, i)
  5957. } else r = n.apply(this, arguments);
  5958. return As(this, r)
  5959. }
  5960. }
  5961. var jf = function (t) {
  5962. xs(i, t);
  5963. var e, r, n = If(i);
  5964. function i(t, e, r) {
  5965. var a;
  5966. jo(this, i), (a = n.call(this, t, e, r)).type = "image", a.loaded = !1;
  5967. var o = a.getHrefAttribute().getString();
  5968. if (!o) return As(a);
  5969. var u = /\.svg$/.test(o);
  5970. return t.images.push(Ss(a)), u ? a.loadSvg(o) : a.loadImage(o), a.isSvg = u, a
  5971. }
  5972. return Fo(i, [{
  5973. key: "loadImage", value: (r = Vo(na.mark((function t(e) {
  5974. var r;
  5975. return na.wrap((function (t) {
  5976. for (; ;) switch (t.prev = t.next) {
  5977. case 0:
  5978. return t.prev = 0, t.next = 3, this.document.createImage(e);
  5979. case 3:
  5980. r = t.sent, this.image = r, t.next = 10;
  5981. break;
  5982. case 7:
  5983. t.prev = 7, t.t0 = t.catch(0), console.error('Error while loading image "'.concat(e, '":'), t.t0);
  5984. case 10:
  5985. this.loaded = !0;
  5986. case 11:
  5987. case"end":
  5988. return t.stop()
  5989. }
  5990. }), t, this, [[0, 7]])
  5991. }))), function (t) {
  5992. return r.apply(this, arguments)
  5993. })
  5994. }, {
  5995. key: "loadSvg", value: (e = Vo(na.mark((function t(e) {
  5996. var r, n;
  5997. return na.wrap((function (t) {
  5998. for (; ;) switch (t.prev = t.next) {
  5999. case 0:
  6000. return t.prev = 0, t.next = 3, this.document.fetch(e);
  6001. case 3:
  6002. return r = t.sent, t.next = 6, r.text();
  6003. case 6:
  6004. n = t.sent, this.image = n, t.next = 13;
  6005. break;
  6006. case 10:
  6007. t.prev = 10, t.t0 = t.catch(0), console.error('Error while loading image "'.concat(e, '":'), t.t0);
  6008. case 13:
  6009. this.loaded = !0;
  6010. case 14:
  6011. case"end":
  6012. return t.stop()
  6013. }
  6014. }), t, this, [[0, 10]])
  6015. }))), function (t) {
  6016. return e.apply(this, arguments)
  6017. })
  6018. }, {
  6019. key: "renderChildren", value: function (t) {
  6020. var e = this.document, r = this.image, n = this.loaded, i = this.getAttribute("x").getPixels("x"),
  6021. a = this.getAttribute("y").getPixels("y"), o = this.getStyle("width").getPixels("x"),
  6022. u = this.getStyle("height").getPixels("y");
  6023. if (n && r && o && u) {
  6024. if (t.save(), this.isSvg) e.canvg.forkString(t, this.image, {
  6025. ignoreMouse: !0,
  6026. ignoreAnimation: !0,
  6027. ignoreDimensions: !0,
  6028. ignoreClear: !0,
  6029. offsetX: i,
  6030. offsetY: a,
  6031. scaleWidth: o,
  6032. scaleHeight: u
  6033. }).render(); else {
  6034. var s = this.image;
  6035. t.translate(i, a), e.setViewBox({
  6036. ctx: t,
  6037. aspectRatio: this.getAttribute("preserveAspectRatio").getString(),
  6038. width: o,
  6039. desiredWidth: s.width,
  6040. height: u,
  6041. desiredHeight: s.height
  6042. }), this.loaded && (void 0 === s.complete || s.complete) && t.drawImage(s, 0, 0)
  6043. }
  6044. t.restore()
  6045. }
  6046. }
  6047. }, {
  6048. key: "getBoundingBox", value: function () {
  6049. var t = this.getAttribute("x").getPixels("x"), e = this.getAttribute("y").getPixels("y"),
  6050. r = this.getStyle("width").getPixels("x"), n = this.getStyle("height").getPixels("y");
  6051. return new Oc(t, e, t + r, e + n)
  6052. }
  6053. }]), i
  6054. }(Ec);
  6055. function zf(t) {
  6056. var e = function () {
  6057. if ("undefined" == typeof Reflect || !ys) return !1;
  6058. if (ys.sham) return !1;
  6059. if ("function" == typeof Proxy) return !0;
  6060. try {
  6061. return Date.prototype.toString.call(ys(Date, [], (function () {
  6062. }))), !0
  6063. } catch (t) {
  6064. return !1
  6065. }
  6066. }();
  6067. return function () {
  6068. var r, n = Os(t);
  6069. if (e) {
  6070. var i = Os(this).constructor;
  6071. r = ys(n, arguments, i)
  6072. } else r = n.apply(this, arguments);
  6073. return As(this, r)
  6074. }
  6075. }
  6076. var Ff = function (t) {
  6077. xs(r, t);
  6078. var e = zf(r);
  6079. function r() {
  6080. var t;
  6081. return jo(this, r), (t = e.apply(this, arguments)).type = "symbol", t
  6082. }
  6083. return Fo(r, [{
  6084. key: "render", value: function (t) {
  6085. }
  6086. }]), r
  6087. }(Ec), Bf = function () {
  6088. function t(e) {
  6089. jo(this, t), this.document = e, this.loaded = !1, e.fonts.push(this)
  6090. }
  6091. var e;
  6092. return Fo(t, [{
  6093. key: "load", value: (e = Vo(na.mark((function t(e, r) {
  6094. var n, i, a, o;
  6095. return na.wrap((function (t) {
  6096. for (; ;) switch (t.prev = t.next) {
  6097. case 0:
  6098. return t.prev = 0, i = this.document, t.next = 4, i.canvg.parser.load(r);
  6099. case 4:
  6100. a = t.sent, o = a.getElementsByTagName("font"), Hi(n = Xs(o)).call(n, (function (t) {
  6101. var r = i.createElement(t);
  6102. i.definitions[e] = r
  6103. })), t.next = 12;
  6104. break;
  6105. case 9:
  6106. t.prev = 9, t.t0 = t.catch(0), console.error('Error while loading font "'.concat(r, '":'), t.t0);
  6107. case 12:
  6108. this.loaded = !0;
  6109. case 13:
  6110. case"end":
  6111. return t.stop()
  6112. }
  6113. }), t, this, [[0, 9]])
  6114. }))), function (t, r) {
  6115. return e.apply(this, arguments)
  6116. })
  6117. }]), t
  6118. }();
  6119. function Uf(t) {
  6120. var e = function () {
  6121. if ("undefined" == typeof Reflect || !ys) return !1;
  6122. if (ys.sham) return !1;
  6123. if ("function" == typeof Proxy) return !0;
  6124. try {
  6125. return Date.prototype.toString.call(ys(Date, [], (function () {
  6126. }))), !0
  6127. } catch (t) {
  6128. return !1
  6129. }
  6130. }();
  6131. return function () {
  6132. var r, n = Os(t);
  6133. if (e) {
  6134. var i = Os(this).constructor;
  6135. r = ys(n, arguments, i)
  6136. } else r = n.apply(this, arguments);
  6137. return As(this, r)
  6138. }
  6139. }
  6140. var Hf = function (t) {
  6141. xs(r, t);
  6142. var e = Uf(r);
  6143. function r(t, n, i) {
  6144. var a, o;
  6145. jo(this, r), (o = e.call(this, t, n, i)).type = "style";
  6146. var u = re(ee(a = Xs(n.childNodes)).call(a, (function (t) {
  6147. return t.data
  6148. })).join("").replace(/(\/\*([^*]|[\r\n]|(\*+([^*\/]|[\r\n])))*\*+\/)|(^[\s]*\/\/.*)/gm, "").replace(/@import.*;/g, "")).split("}");
  6149. return Hi(u).call(u, (function (e) {
  6150. var r = Ku(e).call(e);
  6151. if (r) {
  6152. var n = r.split("{"), i = n[0].split(","), a = n[1].split(";");
  6153. Hi(i).call(i, (function (e) {
  6154. var r = Ku(e).call(e);
  6155. if (r) {
  6156. var n = t.styles[r] || {};
  6157. if (Hi(a).call(a, (function (e) {
  6158. var r, i, a = dc(e).call(e, ":"), o = Ku(r = e.substr(0, a)).call(r),
  6159. u = Ku(i = e.substr(a + 1, e.length - a)).call(i);
  6160. o && u && (n[o] = new ts(t, o, u))
  6161. })), t.styles[r] = n, t.stylesSpecificity[r] = mi(r), "@font-face" === r) {
  6162. var i = n["font-family"].getString().replace(/"|'/g, ""),
  6163. o = n.src.getString().split(",");
  6164. Hi(o).call(o, (function (e) {
  6165. if (dc(e).call(e, 'format("svg")') > 0) {
  6166. var r = se(e);
  6167. r && new Bf(t).load(i, r)
  6168. }
  6169. }))
  6170. }
  6171. }
  6172. }))
  6173. }
  6174. })), o
  6175. }
  6176. return r
  6177. }(rc);
  6178. function Xf(t) {
  6179. var e = function () {
  6180. if ("undefined" == typeof Reflect || !ys) return !1;
  6181. if (ys.sham) return !1;
  6182. if ("function" == typeof Proxy) return !0;
  6183. try {
  6184. return Date.prototype.toString.call(ys(Date, [], (function () {
  6185. }))), !0
  6186. } catch (t) {
  6187. return !1
  6188. }
  6189. }();
  6190. return function () {
  6191. var r, n = Os(t);
  6192. if (e) {
  6193. var i = Os(this).constructor;
  6194. r = ys(n, arguments, i)
  6195. } else r = n.apply(this, arguments);
  6196. return As(this, r)
  6197. }
  6198. }
  6199. Hf.parseExternalUrl = se;
  6200. var Yf = function (t) {
  6201. xs(r, t);
  6202. var e = Xf(r);
  6203. function r() {
  6204. var t;
  6205. return jo(this, r), (t = e.apply(this, arguments)).type = "use", t
  6206. }
  6207. return Fo(r, [{
  6208. key: "setContext", value: function (t) {
  6209. wc(Os(r.prototype), "setContext", this).call(this, t);
  6210. var e = this.getAttribute("x"), n = this.getAttribute("y");
  6211. e.hasValue() && t.translate(e.getPixels("x"), 0), n.hasValue() && t.translate(0, n.getPixels("y"))
  6212. }
  6213. }, {
  6214. key: "path", value: function (t) {
  6215. var e = this.element;
  6216. e && e.path(t)
  6217. }
  6218. }, {
  6219. key: "renderChildren", value: function (t) {
  6220. var e = this.document, r = this.element;
  6221. if (r) {
  6222. var n = r;
  6223. if ("symbol" === r.type && ((n = new cl(e, null)).attributes.viewBox = new ts(e, "viewBox", r.getAttribute("viewBox").getString()), n.attributes.preserveAspectRatio = new ts(e, "preserveAspectRatio", r.getAttribute("preserveAspectRatio").getString()), n.attributes.overflow = new ts(e, "overflow", r.getAttribute("overflow").getString()), n.children = r.children, r.styles.opacity = new ts(e, "opacity", this.calculateOpacity())), "svg" === n.type) {
  6224. var i = this.getStyle("width", !1, !0), a = this.getStyle("height", !1, !0);
  6225. i.hasValue() && (n.attributes.width = new ts(e, "width", i.getString())), a.hasValue() && (n.attributes.height = new ts(e, "height", a.getString()))
  6226. }
  6227. var o = n.parent;
  6228. n.parent = this, n.render(t), n.parent = o
  6229. }
  6230. }
  6231. }, {
  6232. key: "getBoundingBox", value: function (t) {
  6233. var e = this.element;
  6234. return e ? e.getBoundingBox(t) : null
  6235. }
  6236. }, {
  6237. key: "elementTransform", value: function () {
  6238. var t = this.document, e = this.element;
  6239. return ec.fromElement(t, e)
  6240. }
  6241. }, {
  6242. key: "element", get: function () {
  6243. return this._element || (this._element = this.getHrefAttribute().getDefinition()), this._element
  6244. }
  6245. }]), r
  6246. }(Ec);
  6247. function qf(t) {
  6248. var e = function () {
  6249. if ("undefined" == typeof Reflect || !ys) return !1;
  6250. if (ys.sham) return !1;
  6251. if ("function" == typeof Proxy) return !0;
  6252. try {
  6253. return Date.prototype.toString.call(ys(Date, [], (function () {
  6254. }))), !0
  6255. } catch (t) {
  6256. return !1
  6257. }
  6258. }();
  6259. return function () {
  6260. var r, n = Os(t);
  6261. if (e) {
  6262. var i = Os(this).constructor;
  6263. r = ys(n, arguments, i)
  6264. } else r = n.apply(this, arguments);
  6265. return As(this, r)
  6266. }
  6267. }
  6268. function Gf(t, e, r, n, i, a) {
  6269. return t[r * n * 4 + 4 * e + a]
  6270. }
  6271. function Qf(t, e, r, n, i, a, o) {
  6272. t[r * n * 4 + 4 * e + a] = o
  6273. }
  6274. function Wf(t, e, r) {
  6275. return t[e] * r
  6276. }
  6277. function $f(t, e, r, n) {
  6278. return e + Math.cos(t) * r + Math.sin(t) * n
  6279. }
  6280. var Zf = function (t) {
  6281. xs(r, t);
  6282. var e = qf(r);
  6283. function r(t, n, i) {
  6284. var a;
  6285. jo(this, r), (a = e.call(this, t, n, i)).type = "feColorMatrix";
  6286. var o = ae(a.getAttribute("values").getString());
  6287. switch (a.getAttribute("type").getString("matrix")) {
  6288. case"saturate":
  6289. var u = o[0];
  6290. o = [.213 + .787 * u, .715 - .715 * u, .072 - .072 * u, 0, 0, .213 - .213 * u, .715 + .285 * u, .072 - .072 * u, 0, 0, .213 - .213 * u, .715 - .715 * u, .072 + .928 * u, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1];
  6291. break;
  6292. case"hueRotate":
  6293. var s = o[0] * Math.PI / 180;
  6294. o = [$f(s, .213, .787, -.213), $f(s, .715, -.715, -.715), $f(s, .072, -.072, .928), 0, 0, $f(s, .213, -.213, .143), $f(s, .715, .285, .14), $f(s, .072, -.072, -.283), 0, 0, $f(s, .213, -.213, -.787), $f(s, .715, -.715, .715), $f(s, .072, .928, .072), 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1];
  6295. break;
  6296. case"luminanceToAlpha":
  6297. o = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, .2125, .7154, .0721, 0, 0, 0, 0, 0, 0, 1]
  6298. }
  6299. return a.matrix = o, a.includeOpacity = a.getAttribute("includeOpacity").hasValue(), a
  6300. }
  6301. return Fo(r, [{
  6302. key: "apply", value: function (t, e, r, n, i) {
  6303. for (var a = this.includeOpacity, o = this.matrix, u = t.getImageData(0, 0, n, i), s = 0; s < i; s++) for (var c = 0; c < n; c++) {
  6304. var l = Gf(u.data, c, s, n, 0, 0), f = Gf(u.data, c, s, n, 0, 1), h = Gf(u.data, c, s, n, 0, 2),
  6305. p = Gf(u.data, c, s, n, 0, 3),
  6306. y = Wf(o, 0, l) + Wf(o, 1, f) + Wf(o, 2, h) + Wf(o, 3, p) + Wf(o, 4, 1),
  6307. v = Wf(o, 5, l) + Wf(o, 6, f) + Wf(o, 7, h) + Wf(o, 8, p) + Wf(o, 9, 1),
  6308. g = Wf(o, 10, l) + Wf(o, 11, f) + Wf(o, 12, h) + Wf(o, 13, p) + Wf(o, 14, 1),
  6309. d = Wf(o, 15, l) + Wf(o, 16, f) + Wf(o, 17, h) + Wf(o, 18, p) + Wf(o, 19, 1);
  6310. a && (y = v = g = 0, d *= p / 255), Qf(u.data, c, s, n, 0, 0, y), Qf(u.data, c, s, n, 0, 1, v), Qf(u.data, c, s, n, 0, 2, g), Qf(u.data, c, s, n, 0, 3, d)
  6311. }
  6312. t.clearRect(0, 0, n, i), t.putImageData(u, 0, 0)
  6313. }
  6314. }]), r
  6315. }(rc);
  6316. function Kf(t) {
  6317. var e = function () {
  6318. if ("undefined" == typeof Reflect || !ys) return !1;
  6319. if (ys.sham) return !1;
  6320. if ("function" == typeof Proxy) return !0;
  6321. try {
  6322. return Date.prototype.toString.call(ys(Date, [], (function () {
  6323. }))), !0
  6324. } catch (t) {
  6325. return !1
  6326. }
  6327. }();
  6328. return function () {
  6329. var r, n = Os(t);
  6330. if (e) {
  6331. var i = Os(this).constructor;
  6332. r = ys(n, arguments, i)
  6333. } else r = n.apply(this, arguments);
  6334. return As(this, r)
  6335. }
  6336. }
  6337. var Jf = function (t) {
  6338. xs(r, t);
  6339. var e = Kf(r);
  6340. function r() {
  6341. var t;
  6342. return jo(this, r), (t = e.apply(this, arguments)).type = "mask", t
  6343. }
  6344. return Fo(r, [{
  6345. key: "apply", value: function (t, e) {
  6346. var n = this.document, i = this.getAttribute("x").getPixels("x"),
  6347. a = this.getAttribute("y").getPixels("y"), o = this.getStyle("width").getPixels("x"),
  6348. u = this.getStyle("height").getPixels("y");
  6349. if (!o && !u) {
  6350. var s, c = new Oc;
  6351. Hi(s = this.children).call(s, (function (e) {
  6352. c.addBoundingBox(e.getBoundingBox(t))
  6353. })), i = Math.floor(c.x1), a = Math.floor(c.y1), o = Math.floor(c.width), u = Math.floor(c.height)
  6354. }
  6355. var l = this.removeStyles(e, r.ignoreStyles), f = n.createCanvas(i + o, a + u), h = f.getContext("2d");
  6356. n.screen.setDefaults(h), this.renderChildren(h), new Zf(n, {
  6357. nodeType: 1,
  6358. childNodes: [],
  6359. attributes: [{nodeName: "type", value: "luminanceToAlpha"}, {
  6360. nodeName: "includeOpacity",
  6361. value: "true"
  6362. }]
  6363. }).apply(h, 0, 0, i + o, a + u);
  6364. var p = n.createCanvas(i + o, a + u), y = p.getContext("2d");
  6365. n.screen.setDefaults(y), e.render(y), y.globalCompositeOperation = "destination-in", y.fillStyle = h.createPattern(f, "no-repeat"), y.fillRect(0, 0, i + o, a + u), t.fillStyle = y.createPattern(p, "no-repeat"), t.fillRect(0, 0, i + o, a + u), this.restoreStyles(e, l)
  6366. }
  6367. }, {
  6368. key: "render", value: function (t) {
  6369. }
  6370. }]), r
  6371. }(rc);
  6372. Jf.ignoreStyles = ["mask", "transform", "clip-path"];
  6373. var th = jt("Reflect", "apply"), eh = Function.apply, rh = !a((function () {
  6374. th((function () {
  6375. }))
  6376. }));
  6377. H({target: "Reflect", stat: !0, forced: rh}, {
  6378. apply: function (t, e, r) {
  6379. return V(t), I(r), th ? th(t, e, r) : eh.call(t, e, r)
  6380. }
  6381. });
  6382. var nh = D.Reflect.apply;
  6383. H({target: "Reflect", stat: !0, sham: !De}, {
  6384. getPrototypeOf: function (t) {
  6385. return Ie(I(t))
  6386. }
  6387. });
  6388. var ih = D.Reflect.getPrototypeOf;
  6389. function ah(t) {
  6390. var e = function () {
  6391. if ("undefined" == typeof Reflect || !ys) return !1;
  6392. if (ys.sham) return !1;
  6393. if ("function" == typeof Proxy) return !0;
  6394. try {
  6395. return Date.prototype.toString.call(ys(Date, [], (function () {
  6396. }))), !0
  6397. } catch (t) {
  6398. return !1
  6399. }
  6400. }();
  6401. return function () {
  6402. var r, n = Os(t);
  6403. if (e) {
  6404. var i = Os(this).constructor;
  6405. r = ys(n, arguments, i)
  6406. } else r = n.apply(this, arguments);
  6407. return As(this, r)
  6408. }
  6409. }
  6410. var oh = function () {
  6411. }, uh = function (t) {
  6412. xs(r, t);
  6413. var e = ah(r);
  6414. function r() {
  6415. var t;
  6416. return jo(this, r), (t = e.apply(this, arguments)).type = "clipPath", t
  6417. }
  6418. return Fo(r, [{
  6419. key: "apply", value: function (t) {
  6420. var e, r = this.document, n = ih(t), i = t.beginPath, a = t.closePath;
  6421. n && (n.beginPath = oh, n.closePath = oh), nh(i, t, []), Hi(e = this.children).call(e, (function (e) {
  6422. if (void 0 !== e.path) {
  6423. var i = void 0 !== e.elementTransform ? e.elementTransform() : null;
  6424. i || (i = ec.fromElement(r, e)), i && i.apply(t), e.path(t), n && (n.closePath = a), i && i.unapply(t)
  6425. }
  6426. })), nh(a, t, []), t.clip(), n && (n.beginPath = i, n.closePath = a)
  6427. }
  6428. }, {
  6429. key: "render", value: function (t) {
  6430. }
  6431. }]), r
  6432. }(rc);
  6433. function sh(t) {
  6434. var e = function () {
  6435. if ("undefined" == typeof Reflect || !ys) return !1;
  6436. if (ys.sham) return !1;
  6437. if ("function" == typeof Proxy) return !0;
  6438. try {
  6439. return Date.prototype.toString.call(ys(Date, [], (function () {
  6440. }))), !0
  6441. } catch (t) {
  6442. return !1
  6443. }
  6444. }();
  6445. return function () {
  6446. var r, n = Os(t);
  6447. if (e) {
  6448. var i = Os(this).constructor;
  6449. r = ys(n, arguments, i)
  6450. } else r = n.apply(this, arguments);
  6451. return As(this, r)
  6452. }
  6453. }
  6454. var ch = function (t) {
  6455. xs(r, t);
  6456. var e = sh(r);
  6457. function r() {
  6458. var t;
  6459. return jo(this, r), (t = e.apply(this, arguments)).type = "filter", t
  6460. }
  6461. return Fo(r, [{
  6462. key: "apply", value: function (t, e) {
  6463. var n = this.document, i = this.children, a = e.getBoundingBox(t);
  6464. if (a) {
  6465. var o = 0, u = 0;
  6466. Hi(i).call(i, (function (t) {
  6467. var e = t.extraFilterDistance || 0;
  6468. o = Math.max(o, e), u = Math.max(u, e)
  6469. }));
  6470. var s = Math.floor(a.width), c = Math.floor(a.height), l = s + 2 * o, f = c + 2 * u;
  6471. if (!(l < 1 || f < 1)) {
  6472. var h = Math.floor(a.x), p = Math.floor(a.y), y = this.removeStyles(e, r.ignoreStyles),
  6473. v = n.createCanvas(l, f), g = v.getContext("2d");
  6474. n.screen.setDefaults(g), g.translate(-h + o, -p + u), e.render(g), Hi(i).call(i, (function (t) {
  6475. "function" == typeof t.apply && t.apply(g, 0, 0, l, f)
  6476. })), t.drawImage(v, 0, 0, l, f, h - o, p - u, l, f), this.restoreStyles(e, y)
  6477. }
  6478. }
  6479. }
  6480. }, {
  6481. key: "render", value: function (t) {
  6482. }
  6483. }]), r
  6484. }(rc);
  6485. function lh(t) {
  6486. var e = function () {
  6487. if ("undefined" == typeof Reflect || !ys) return !1;
  6488. if (ys.sham) return !1;
  6489. if ("function" == typeof Proxy) return !0;
  6490. try {
  6491. return Date.prototype.toString.call(ys(Date, [], (function () {
  6492. }))), !0
  6493. } catch (t) {
  6494. return !1
  6495. }
  6496. }();
  6497. return function () {
  6498. var r, n = Os(t);
  6499. if (e) {
  6500. var i = Os(this).constructor;
  6501. r = ys(n, arguments, i)
  6502. } else r = n.apply(this, arguments);
  6503. return As(this, r)
  6504. }
  6505. }
  6506. ch.ignoreStyles = ["filter", "transform", "clip-path"];
  6507. var fh = function (t) {
  6508. xs(r, t);
  6509. var e = lh(r);
  6510. function r(t, n, i) {
  6511. var a;
  6512. return jo(this, r), (a = e.call(this, t, n, i)).type = "feDropShadow", a.addStylesFromStyleDefinition(), a
  6513. }
  6514. return Fo(r, [{
  6515. key: "apply", value: function (t, e, r, n, i) {
  6516. }
  6517. }]), r
  6518. }(rc);
  6519. function hh(t) {
  6520. var e = function () {
  6521. if ("undefined" == typeof Reflect || !ys) return !1;
  6522. if (ys.sham) return !1;
  6523. if ("function" == typeof Proxy) return !0;
  6524. try {
  6525. return Date.prototype.toString.call(ys(Date, [], (function () {
  6526. }))), !0
  6527. } catch (t) {
  6528. return !1
  6529. }
  6530. }();
  6531. return function () {
  6532. var r, n = Os(t);
  6533. if (e) {
  6534. var i = Os(this).constructor;
  6535. r = ys(n, arguments, i)
  6536. } else r = n.apply(this, arguments);
  6537. return As(this, r)
  6538. }
  6539. }
  6540. var ph = function (t) {
  6541. xs(r, t);
  6542. var e = hh(r);
  6543. function r() {
  6544. var t;
  6545. return jo(this, r), (t = e.apply(this, arguments)).type = "feMorphology", t
  6546. }
  6547. return Fo(r, [{
  6548. key: "apply", value: function (t, e, r, n, i) {
  6549. }
  6550. }]), r
  6551. }(rc);
  6552. function yh(t) {
  6553. var e = function () {
  6554. if ("undefined" == typeof Reflect || !ys) return !1;
  6555. if (ys.sham) return !1;
  6556. if ("function" == typeof Proxy) return !0;
  6557. try {
  6558. return Date.prototype.toString.call(ys(Date, [], (function () {
  6559. }))), !0
  6560. } catch (t) {
  6561. return !1
  6562. }
  6563. }();
  6564. return function () {
  6565. var r, n = Os(t);
  6566. if (e) {
  6567. var i = Os(this).constructor;
  6568. r = ys(n, arguments, i)
  6569. } else r = n.apply(this, arguments);
  6570. return As(this, r)
  6571. }
  6572. }
  6573. var vh = function (t) {
  6574. xs(r, t);
  6575. var e = yh(r);
  6576. function r() {
  6577. var t;
  6578. return jo(this, r), (t = e.apply(this, arguments)).type = "feComposite", t
  6579. }
  6580. return Fo(r, [{
  6581. key: "apply", value: function (t, e, r, n, i) {
  6582. }
  6583. }]), r
  6584. }(rc);
  6585. function gh(t) {
  6586. return (gh = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (t) {
  6587. return typeof t
  6588. } : function (t) {
  6589. return t && "function" == typeof Symbol && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t
  6590. })(t)
  6591. }
  6592. var dh = [512, 512, 456, 512, 328, 456, 335, 512, 405, 328, 271, 456, 388, 335, 292, 512, 454, 405, 364, 328, 298, 271, 496, 456, 420, 388, 360, 335, 312, 292, 273, 512, 482, 454, 428, 405, 383, 364, 345, 328, 312, 298, 284, 271, 259, 496, 475, 456, 437, 420, 404, 388, 374, 360, 347, 335, 323, 312, 302, 292, 282, 273, 265, 512, 497, 482, 468, 454, 441, 428, 417, 405, 394, 383, 373, 364, 354, 345, 337, 328, 320, 312, 305, 298, 291, 284, 278, 271, 265, 259, 507, 496, 485, 475, 465, 456, 446, 437, 428, 420, 412, 404, 396, 388, 381, 374, 367, 360, 354, 347, 341, 335, 329, 323, 318, 312, 307, 302, 297, 292, 287, 282, 278, 273, 269, 265, 261, 512, 505, 497, 489, 482, 475, 468, 461, 454, 447, 441, 435, 428, 422, 417, 411, 405, 399, 394, 389, 383, 378, 373, 368, 364, 359, 354, 350, 345, 341, 337, 332, 328, 324, 320, 316, 312, 309, 305, 301, 298, 294, 291, 287, 284, 281, 278, 274, 271, 268, 265, 262, 259, 257, 507, 501, 496, 491, 485, 480, 475, 470, 465, 460, 456, 451, 446, 442, 437, 433, 428, 424, 420, 416, 412, 408, 404, 400, 396, 392, 388, 385, 381, 377, 374, 370, 367, 363, 360, 357, 354, 350, 347, 344, 341, 338, 335, 332, 329, 326, 323, 320, 318, 315, 312, 310, 307, 304, 302, 299, 297, 294, 292, 289, 287, 285, 282, 280, 278, 275, 273, 271, 269, 267, 265, 263, 261, 259],
  6593. mh = [9, 11, 12, 13, 13, 14, 14, 15, 15, 15, 15, 16, 16, 16, 16, 17, 17, 17, 17, 17, 17, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24];
  6594. function xh(t, e, r, n, i, a) {
  6595. if (!(isNaN(a) || a < 1)) {
  6596. a |= 0;
  6597. var o = function (t, e, r, n, i) {
  6598. if ("string" == typeof t && (t = document.getElementById(t)), !t || "object" !== gh(t) || !("getContext" in t)) throw new TypeError("Expecting canvas with `getContext` method in processCanvasRGB(A) calls!");
  6599. var a = t.getContext("2d");
  6600. try {
  6601. return a.getImageData(e, r, n, i)
  6602. } catch (t) {
  6603. throw new Error("unable to access image data: " + t)
  6604. }
  6605. }(t, e, r, n, i);
  6606. o = function (t, e, r, n, i, a) {
  6607. for (var o, u = t.data, s = 2 * a + 1, c = n - 1, l = i - 1, f = a + 1, h = f * (f + 1) / 2, p = new bh, y = p, v = 1; v < s; v++) y = y.next = new bh, v === f && (o = y);
  6608. y.next = p;
  6609. for (var g = null, d = null, m = 0, x = 0, b = dh[a], w = mh[a], S = 0; S < i; S++) {
  6610. y = p;
  6611. for (var A = u[x], k = u[x + 1], T = u[x + 2], O = u[x + 3], P = 0; P < f; P++) y.r = A, y.g = k, y.b = T, y.a = O, y = y.next;
  6612. for (var E = 0, C = 0, M = 0, N = 0, R = f * A, _ = f * k, D = f * T, V = f * O, L = h * A, I = h * k, j = h * T, z = h * O, F = 1; F < f; F++) {
  6613. var B = x + ((c < F ? c : F) << 2), U = u[B], H = u[B + 1], X = u[B + 2], Y = u[B + 3],
  6614. q = f - F;
  6615. L += (y.r = U) * q, I += (y.g = H) * q, j += (y.b = X) * q, z += (y.a = Y) * q, E += U, C += H, M += X, N += Y, y = y.next
  6616. }
  6617. g = p, d = o;
  6618. for (var G = 0; G < n; G++) {
  6619. var Q = z * b >> w;
  6620. if (u[x + 3] = Q, 0 !== Q) {
  6621. var W = 255 / Q;
  6622. u[x] = (L * b >> w) * W, u[x + 1] = (I * b >> w) * W, u[x + 2] = (j * b >> w) * W
  6623. } else u[x] = u[x + 1] = u[x + 2] = 0;
  6624. L -= R, I -= _, j -= D, z -= V, R -= g.r, _ -= g.g, D -= g.b, V -= g.a;
  6625. var $ = G + a + 1;
  6626. $ = m + ($ < c ? $ : c) << 2, L += E += g.r = u[$], I += C += g.g = u[$ + 1], j += M += g.b = u[$ + 2], z += N += g.a = u[$ + 3], g = g.next;
  6627. var Z = d, K = Z.r, J = Z.g, tt = Z.b, et = Z.a;
  6628. R += K, _ += J, D += tt, V += et, E -= K, C -= J, M -= tt, N -= et, d = d.next, x += 4
  6629. }
  6630. m += n
  6631. }
  6632. for (var rt = 0; rt < n; rt++) {
  6633. var nt = u[x = rt << 2], it = u[x + 1], at = u[x + 2], ot = u[x + 3], ut = f * nt, st = f * it,
  6634. ct = f * at, lt = f * ot, ft = h * nt, ht = h * it, pt = h * at, yt = h * ot;
  6635. y = p;
  6636. for (var vt = 0; vt < f; vt++) y.r = nt, y.g = it, y.b = at, y.a = ot, y = y.next;
  6637. for (var gt = n, dt = 0, mt = 0, xt = 0, bt = 0, wt = 1; wt <= a; wt++) {
  6638. x = gt + rt << 2;
  6639. var St = f - wt;
  6640. ft += (y.r = nt = u[x]) * St, ht += (y.g = it = u[x + 1]) * St, pt += (y.b = at = u[x + 2]) * St, yt += (y.a = ot = u[x + 3]) * St, bt += nt, dt += it, mt += at, xt += ot, y = y.next, wt < l && (gt += n)
  6641. }
  6642. x = rt, g = p, d = o;
  6643. for (var At = 0; At < i; At++) {
  6644. var kt = x << 2;
  6645. u[kt + 3] = ot = yt * b >> w, ot > 0 ? (ot = 255 / ot, u[kt] = (ft * b >> w) * ot, u[kt + 1] = (ht * b >> w) * ot, u[kt + 2] = (pt * b >> w) * ot) : u[kt] = u[kt + 1] = u[kt + 2] = 0, ft -= ut, ht -= st, pt -= ct, yt -= lt, ut -= g.r, st -= g.g, ct -= g.b, lt -= g.a, kt = rt + ((kt = At + f) < l ? kt : l) * n << 2, ft += bt += g.r = u[kt], ht += dt += g.g = u[kt + 1], pt += mt += g.b = u[kt + 2], yt += xt += g.a = u[kt + 3], g = g.next, ut += nt = d.r, st += it = d.g, ct += at = d.b, lt += ot = d.a, bt -= nt, dt -= it, mt -= at, xt -= ot, d = d.next, x += n
  6646. }
  6647. }
  6648. return t
  6649. }(o, 0, 0, n, i, a), t.getContext("2d").putImageData(o, e, r)
  6650. }
  6651. }
  6652. var bh = function t() {
  6653. !function (t, e) {
  6654. if (!(t instanceof e)) throw new TypeError("Cannot call a class as a function")
  6655. }(this, t), this.r = 0, this.g = 0, this.b = 0, this.a = 0, this.next = null
  6656. };
  6657. function wh(t) {
  6658. var e = function () {
  6659. if ("undefined" == typeof Reflect || !ys) return !1;
  6660. if (ys.sham) return !1;
  6661. if ("function" == typeof Proxy) return !0;
  6662. try {
  6663. return Date.prototype.toString.call(ys(Date, [], (function () {
  6664. }))), !0
  6665. } catch (t) {
  6666. return !1
  6667. }
  6668. }();
  6669. return function () {
  6670. var r, n = Os(t);
  6671. if (e) {
  6672. var i = Os(this).constructor;
  6673. r = ys(n, arguments, i)
  6674. } else r = n.apply(this, arguments);
  6675. return As(this, r)
  6676. }
  6677. }
  6678. var Sh = function (t) {
  6679. xs(r, t);
  6680. var e = wh(r);
  6681. function r(t, n, i) {
  6682. var a;
  6683. return jo(this, r), (a = e.call(this, t, n, i)).type = "feGaussianBlur", a.blurRadius = Math.floor(a.getAttribute("stdDeviation").getNumber()), a.extraFilterDistance = a.blurRadius, a
  6684. }
  6685. return Fo(r, [{
  6686. key: "apply", value: function (t, e, r, n, i) {
  6687. var a = this.document, o = this.blurRadius, u = a.window ? a.window.document.body : null, s = t.canvas;
  6688. s.id = a.getUniqueId(), u && (s.style.display = "none", u.appendChild(s)), xh(s, e, r, n, i, o), u && u.removeChild(s)
  6689. }
  6690. }]), r
  6691. }(rc);
  6692. function Ah(t) {
  6693. var e = function () {
  6694. if ("undefined" == typeof Reflect || !ys) return !1;
  6695. if (ys.sham) return !1;
  6696. if ("function" == typeof Proxy) return !0;
  6697. try {
  6698. return Date.prototype.toString.call(ys(Date, [], (function () {
  6699. }))), !0
  6700. } catch (t) {
  6701. return !1
  6702. }
  6703. }();
  6704. return function () {
  6705. var r, n = Os(t);
  6706. if (e) {
  6707. var i = Os(this).constructor;
  6708. r = ys(n, arguments, i)
  6709. } else r = n.apply(this, arguments);
  6710. return As(this, r)
  6711. }
  6712. }
  6713. var kh = function (t) {
  6714. xs(r, t);
  6715. var e = Ah(r);
  6716. function r() {
  6717. var t;
  6718. return jo(this, r), (t = e.apply(this, arguments)).type = "title", t
  6719. }
  6720. return r
  6721. }(rc);
  6722. function Th(t) {
  6723. var e = function () {
  6724. if ("undefined" == typeof Reflect || !ys) return !1;
  6725. if (ys.sham) return !1;
  6726. if ("function" == typeof Proxy) return !0;
  6727. try {
  6728. return Date.prototype.toString.call(ys(Date, [], (function () {
  6729. }))), !0
  6730. } catch (t) {
  6731. return !1
  6732. }
  6733. }();
  6734. return function () {
  6735. var r, n = Os(t);
  6736. if (e) {
  6737. var i = Os(this).constructor;
  6738. r = ys(n, arguments, i)
  6739. } else r = n.apply(this, arguments);
  6740. return As(this, r)
  6741. }
  6742. }
  6743. var Oh = function (t) {
  6744. xs(r, t);
  6745. var e = Th(r);
  6746. function r() {
  6747. var t;
  6748. return jo(this, r), (t = e.apply(this, arguments)).type = "desc", t
  6749. }
  6750. return r
  6751. }(rc), Ph = {
  6752. svg: cl,
  6753. rect: fl,
  6754. circle: pl,
  6755. ellipse: vl,
  6756. line: dl,
  6757. polyline: xl,
  6758. polygon: wl,
  6759. path: ul,
  6760. pattern: Tl,
  6761. marker: Pl,
  6762. defs: Cl,
  6763. linearGradient: Vl,
  6764. radialGradient: Il,
  6765. stop: zl,
  6766. animate: Yl,
  6767. animateColor: Kl,
  6768. animateTransform: tf,
  6769. font: cf,
  6770. "font-face": ff,
  6771. "missing-glyph": pf,
  6772. glyph: vf,
  6773. text: Mc,
  6774. tspan: Rc,
  6775. tref: df,
  6776. a: xf,
  6777. textPath: Lf,
  6778. image: jf,
  6779. g: Nl,
  6780. symbol: Ff,
  6781. style: Hf,
  6782. use: Yf,
  6783. mask: Jf,
  6784. clipPath: uh,
  6785. filter: ch,
  6786. feDropShadow: fh,
  6787. feMorphology: ph,
  6788. feComposite: vh,
  6789. feColorMatrix: Zf,
  6790. feGaussianBlur: Sh,
  6791. title: kh,
  6792. desc: Oh
  6793. };
  6794. function Eh(t, e) {
  6795. var r = ra(t);
  6796. if (ta) {
  6797. var n = ta(t);
  6798. e && (n = Ji(n).call(n, (function (e) {
  6799. return Gi(t, e).enumerable
  6800. }))), r.push.apply(r, n)
  6801. }
  6802. return r
  6803. }
  6804. function Ch() {
  6805. return (Ch = Vo(na.mark((function t(e) {
  6806. var r, n, i = arguments;
  6807. return na.wrap((function (t) {
  6808. for (; ;) switch (t.prev = t.next) {
  6809. case 0:
  6810. return r = i.length > 1 && void 0 !== i[1] && i[1], n = document.createElement("img"), r && (n.crossOrigin = "Anonymous"), t.abrupt("return", new iu((function (t, r) {
  6811. n.onload = function () {
  6812. t(n)
  6813. }, n.onerror = function () {
  6814. r()
  6815. }, n.src = e
  6816. })));
  6817. case 4:
  6818. case"end":
  6819. return t.stop()
  6820. }
  6821. }), t)
  6822. })))).apply(this, arguments)
  6823. }
  6824. var Mh = function () {
  6825. function t(e) {
  6826. var r, n, i = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {}, a = i.rootEmSize,
  6827. o = void 0 === a ? 12 : a, u = i.emSize, s = void 0 === u ? 12 : u, c = i.createCanvas,
  6828. l = void 0 === c ? t.createCanvas : c, f = i.createImage, h = void 0 === f ? t.createImage : f,
  6829. p = i.anonymousCrossOrigin;
  6830. jo(this, t), this.canvg = e, this.definitions = {}, this.styles = {}, this.stylesSpecificity = {}, this.images = [], this.fonts = [], this.emSizeStack = [], this.uniqueId = 0, this.screen = e.screen, this.rootEmSize = o, this.emSize = s, this.createCanvas = l, this.createImage = this.bindCreateImage(h, p), this.screen.wait(fu(r = this.isImagesLoaded).call(r, this)), this.screen.wait(fu(n = this.isFontsLoaded).call(n, this))
  6831. }
  6832. return Fo(t, [{
  6833. key: "bindCreateImage", value: function (t, e) {
  6834. return "boolean" == typeof e ? function (r, n) {
  6835. return t(r, "boolean" == typeof n ? n : e)
  6836. } : t
  6837. }
  6838. }, {
  6839. key: "popEmSize", value: function () {
  6840. this.emSizeStack.pop()
  6841. }
  6842. }, {
  6843. key: "getUniqueId", value: function () {
  6844. return "canvg".concat(++this.uniqueId)
  6845. }
  6846. }, {
  6847. key: "isImagesLoaded", value: function () {
  6848. var t;
  6849. return nu(t = this.images).call(t, (function (t) {
  6850. return t.loaded
  6851. }))
  6852. }
  6853. }, {
  6854. key: "isFontsLoaded", value: function () {
  6855. var t;
  6856. return nu(t = this.fonts).call(t, (function (t) {
  6857. return t.loaded
  6858. }))
  6859. }
  6860. }, {
  6861. key: "createDocumentElement", value: function (t) {
  6862. var e = this.createElement(t.documentElement);
  6863. return e.root = !0, e.addStylesFromStyleDefinition(), this.documentElement = e, e
  6864. }
  6865. }, {
  6866. key: "createElement", value: function (e) {
  6867. var r = e.nodeName.replace(/^[^:]+:/, ""), n = t.elementTypes[r];
  6868. return void 0 !== n ? new n(this, e) : new ic(this, e)
  6869. }
  6870. }, {
  6871. key: "createTextNode", value: function (t) {
  6872. return new Dc(this, t)
  6873. }
  6874. }, {
  6875. key: "setViewBox", value: function (t) {
  6876. this.screen.setViewBox(function (t) {
  6877. for (var e = 1; e < arguments.length; e++) {
  6878. var r, n = null != arguments[e] ? arguments[e] : {};
  6879. if (e % 2) Hi(r = Eh(Object(n), !0)).call(r, (function (e) {
  6880. Io(t, e, n[e])
  6881. })); else if (Di) Ri(t, Di(n)); else {
  6882. var i;
  6883. Hi(i = Eh(Object(n))).call(i, (function (e) {
  6884. Ni(t, e, Gi(n, e))
  6885. }))
  6886. }
  6887. }
  6888. return t
  6889. }({document: this}, t))
  6890. }
  6891. }, {
  6892. key: "window", get: function () {
  6893. return this.screen.window
  6894. }
  6895. }, {
  6896. key: "fetch", get: function () {
  6897. return this.screen.fetch
  6898. }
  6899. }, {
  6900. key: "ctx", get: function () {
  6901. return this.screen.ctx
  6902. }
  6903. }, {
  6904. key: "emSize", get: function () {
  6905. var t = this.emSizeStack;
  6906. return t[t.length - 1]
  6907. }, set: function (t) {
  6908. this.emSizeStack.push(t)
  6909. }
  6910. }]), t
  6911. }();
  6912. function Nh(t, e) {
  6913. var r = ra(t);
  6914. if (ta) {
  6915. var n = ta(t);
  6916. e && (n = Ji(n).call(n, (function (e) {
  6917. return Gi(t, e).enumerable
  6918. }))), r.push.apply(r, n)
  6919. }
  6920. return r
  6921. }
  6922. function Rh(t) {
  6923. for (var e = 1; e < arguments.length; e++) {
  6924. var r, n = null != arguments[e] ? arguments[e] : {};
  6925. if (e % 2) Hi(r = Nh(Object(n), !0)).call(r, (function (e) {
  6926. Io(t, e, n[e])
  6927. })); else if (Di) Ri(t, Di(n)); else {
  6928. var i;
  6929. Hi(i = Nh(Object(n))).call(i, (function (e) {
  6930. Ni(t, e, Gi(n, e))
  6931. }))
  6932. }
  6933. }
  6934. return t
  6935. }
  6936. Mh.createCanvas = function (t, e) {
  6937. var r = document.createElement("canvas");
  6938. return r.width = t, r.height = e, r
  6939. }, Mh.createImage = function (t) {
  6940. return Ch.apply(this, arguments)
  6941. }, Mh.elementTypes = Ph;
  6942. var _h = function () {
  6943. function t(e, r) {
  6944. var n = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : {};
  6945. jo(this, t), this.parser = new cs(n), this.screen = new os(e, n), this.options = n;
  6946. var i = new Mh(this, n), a = i.createDocumentElement(r);
  6947. this.document = i, this.documentElement = a
  6948. }
  6949. var e, r;
  6950. return Fo(t, [{
  6951. key: "fork", value: function (e, r) {
  6952. var n = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : {};
  6953. return t.from(e, r, Rh(Rh({}, this.options), n))
  6954. }
  6955. }, {
  6956. key: "forkString", value: function (e, r) {
  6957. var n = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : {};
  6958. return t.fromString(e, r, Rh(Rh({}, this.options), n))
  6959. }
  6960. }, {
  6961. key: "ready", value: function () {
  6962. return this.screen.ready()
  6963. }
  6964. }, {
  6965. key: "isReady", value: function () {
  6966. return this.screen.isReady()
  6967. }
  6968. }, {
  6969. key: "render", value: (r = Vo(na.mark((function t() {
  6970. var e, r = arguments;
  6971. return na.wrap((function (t) {
  6972. for (; ;) switch (t.prev = t.next) {
  6973. case 0:
  6974. return e = r.length > 0 && void 0 !== r[0] ? r[0] : {}, this.start(Rh({
  6975. enableRedraw: !0,
  6976. ignoreAnimation: !0,
  6977. ignoreMouse: !0
  6978. }, e)), t.next = 4, this.ready();
  6979. case 4:
  6980. this.stop();
  6981. case 5:
  6982. case"end":
  6983. return t.stop()
  6984. }
  6985. }), t, this)
  6986. }))), function () {
  6987. return r.apply(this, arguments)
  6988. })
  6989. }, {
  6990. key: "start", value: function () {
  6991. var t = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, e = this.documentElement,
  6992. r = this.screen, n = this.options;
  6993. r.start(e, Rh(Rh({enableRedraw: !0}, n), t))
  6994. }
  6995. }, {
  6996. key: "stop", value: function () {
  6997. this.screen.stop()
  6998. }
  6999. }, {
  7000. key: "resize", value: function (t) {
  7001. var e = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : t,
  7002. r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2];
  7003. this.documentElement.resize(t, e, r)
  7004. }
  7005. }], [{
  7006. key: "from", value: (e = Vo(na.mark((function e(r, n) {
  7007. var i, a, o, u = arguments;
  7008. return na.wrap((function (e) {
  7009. for (; ;) switch (e.prev = e.next) {
  7010. case 0:
  7011. return i = u.length > 2 && void 0 !== u[2] ? u[2] : {}, a = new cs(i), e.next = 4, a.parse(n);
  7012. case 4:
  7013. return o = e.sent, e.abrupt("return", new t(r, o, i));
  7014. case 6:
  7015. case"end":
  7016. return e.stop()
  7017. }
  7018. }), e)
  7019. }))), function (t, r) {
  7020. return e.apply(this, arguments)
  7021. })
  7022. }, {
  7023. key: "fromString", value: function (e, r) {
  7024. var n = arguments.length > 2 && void 0 !== arguments[2] ? arguments[2] : {}, i = new cs(n),
  7025. a = i.parseFromString(r);
  7026. return new t(e, a, n)
  7027. }
  7028. }]), t
  7029. }();
  7030. var Dh = Object.freeze({
  7031. __proto__: null, offscreen: function () {
  7032. var t = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : {}, e = t.DOMParser, r = {
  7033. window: null, ignoreAnimation: !0, ignoreMouse: !0, DOMParser: e, createCanvas: function (t, e) {
  7034. return new OffscreenCanvas(t, e)
  7035. }, createImage: function (t) {
  7036. return Vo(na.mark((function e() {
  7037. var r, n, i;
  7038. return na.wrap((function (e) {
  7039. for (; ;) switch (e.prev = e.next) {
  7040. case 0:
  7041. return e.next = 2, fetch(t);
  7042. case 2:
  7043. return r = e.sent, e.next = 5, r.blob();
  7044. case 5:
  7045. return n = e.sent, e.next = 8, createImageBitmap(n);
  7046. case 8:
  7047. return i = e.sent, e.abrupt("return", i);
  7048. case 10:
  7049. case"end":
  7050. return e.stop()
  7051. }
  7052. }), e)
  7053. })))()
  7054. }
  7055. };
  7056. return "undefined" == typeof DOMParser && void 0 !== e || Al(r, "DOMParser"), r
  7057. }, node: function (t) {
  7058. var e = t.DOMParser, r = t.canvas;
  7059. return {
  7060. window: null,
  7061. ignoreAnimation: !0,
  7062. ignoreMouse: !0,
  7063. DOMParser: e,
  7064. fetch: t.fetch,
  7065. createCanvas: r.createCanvas,
  7066. createImage: r.loadImage
  7067. }
  7068. }
  7069. });
  7070. t.AElement = xf, t.AnimateColorElement = Kl, t.AnimateElement = Yl, t.AnimateTransformElement = tf, t.BoundingBox = Oc, t.CB1 = Ai, t.CB2 = ki, t.CB3 = Ti, t.CB4 = Oi, t.Canvg = _h, t.CircleElement = pl, t.ClipPathElement = uh, t.DefsElement = Cl, t.DescElement = Oh, t.Document = Mh, t.Element = rc, t.EllipseElement = vl, t.FeColorMatrixElement = Zf, t.FeCompositeElement = vh, t.FeDropShadowElement = fh, t.FeGaussianBlurElement = Sh, t.FeMorphologyElement = ph, t.FilterElement = ch, t.Font = Tc, t.FontElement = cf, t.FontFaceElement = ff, t.GElement = Nl, t.GlyphElement = vf, t.GradientElement = _l, t.ImageElement = jf, t.LineElement = dl, t.LinearGradientElement = Vl, t.MarkerElement = Pl, t.MaskElement = Jf, t.Matrix = Qs, t.MissingGlyphElement = pf, t.Mouse = ns, t.PSEUDO_ZERO = xi, t.Parser = cs, t.PathElement = ul, t.PathParser = al, t.PatternElement = Tl, t.Point = rs, t.PolygonElement = wl, t.PolylineElement = xl, t.Property = ts, t.QB1 = Pi, t.QB2 = Ei, t.QB3 = Ci, t.RadialGradientElement = Il, t.RectElement = fl, t.RenderedElement = Ec, t.Rotate = qs, t.SVGElement = cl, t.SVGFontLoader = Bf, t.Scale = Gs, t.Screen = os, t.Skew = $s, t.SkewX = Ks, t.SkewY = tc, t.StopElement = zl, t.StyleElement = Hf, t.SymbolElement = Ff, t.TRefElement = df, t.TSpanElement = Rc, t.TextElement = Mc, t.TextPathElement = Lf, t.TitleElement = kh, t.Transform = ec, t.Translate = Ys, t.UnknownElement = ic, t.UseElement = Yf, t.ViewPort = es, t.compressSpaces = re, t.default = _h, t.getSelectorSpecificity = mi, t.normalizeAttributeName = ue, t.normalizeColor = ce, t.parseExternalUrl = se, t.presets = Dh, t.toNumbers = ae, t.trimLeft = ne, t.trimRight = ie, t.vectorMagnitude = bi, t.vectorsAngle = Si, t.vectorsRatio = wi, Object.defineProperty(t, "__esModule", {value: !0})
  7071. }));
  7072. //# sourceMappingURL=umd.js.map